diff --git a/.ci-operator.yaml b/.ci-operator.yaml
index a3628cf240..1d88a59fdf 100644
--- a/.ci-operator.yaml
+++ b/.ci-operator.yaml
@@ -1,4 +1,4 @@
build_root_image:
name: release
namespace: openshift
- tag: rhel-9-release-golang-1.25-openshift-4.22
+ tag: rhel-9-release-golang-1.26-openshift-5.0
diff --git a/Dockerfile.rhel b/Dockerfile.rhel
index ba9fd4b9c5..a92c916e08 100644
--- a/Dockerfile.rhel
+++ b/Dockerfile.rhel
@@ -1,10 +1,10 @@
-FROM registry.ci.openshift.org/ocp/builder:rhel-9-golang-1.25-openshift-4.22 AS builder
+FROM registry.ci.openshift.org/ocp/builder:rhel-9-golang-1.26-openshift-5.0 AS builder
WORKDIR /go/src/github.com/openshift/openshift-controller-manager
COPY . .
RUN make build --warn-undefined-variables \
&& gzip openshift-controller-manager-tests-ext
-FROM registry.ci.openshift.org/ocp/4.22:base-rhel9
+FROM registry.ci.openshift.org/ocp/5.0:base-rhel9
COPY --from=builder /go/src/github.com/openshift/openshift-controller-manager/openshift-controller-manager /usr/bin/
COPY --from=builder /go/src/github.com/openshift/openshift-controller-manager/openshift-controller-manager-tests-ext.gz /usr/bin/
LABEL io.k8s.display-name="OpenShift Controller Manager Command" \
diff --git a/go.mod b/go.mod
index 6a0253c6bf..187b52bef2 100644
--- a/go.mod
+++ b/go.mod
@@ -1,6 +1,6 @@
module github.com/openshift/openshift-controller-manager
-go 1.25.0
+go 1.26.0
require (
github.com/BurntSushi/toml v1.5.0
@@ -10,41 +10,41 @@ require (
github.com/google/go-cmp v0.7.0
github.com/google/uuid v1.6.0
github.com/openshift-eng/openshift-tests-extension v0.0.0-20260127124016-0fed2b824818
- github.com/openshift/api v0.0.0-20260306105915-ec7ab20aa8c4
- github.com/openshift/build-machinery-go v0.0.0-20251023084048-5d77c1a5e5af
- github.com/openshift/client-go v0.0.0-20260305174943-67b007d67537
- github.com/openshift/library-go v0.0.0-20260303171201-5d9eb6295ff6
+ github.com/openshift/api v0.0.0-20260813212709-d4bb0b443cb8
+ github.com/openshift/build-machinery-go v0.0.0-20260629141115-154a2b810491
+ github.com/openshift/client-go v0.0.0-20260810202730-ddca5e0b7146
+ github.com/openshift/library-go v0.0.0-20260814203017-a0584a625d6d
github.com/openshift/runtime-utils v0.0.0-20230921210328-7bdb5b9c177b
github.com/prometheus/client_golang v1.23.2
github.com/prometheus/client_model v0.6.2
- github.com/spf13/cobra v1.10.0
- golang.org/x/exp v0.0.0-20240719175910-8a7402abbf56
+ github.com/spf13/cobra v1.10.2
+ golang.org/x/exp v0.0.0-20251219203646-944ab1f22d93
gopkg.in/go-jose/go-jose.v2 v2.6.3
- k8s.io/api v0.35.2
- k8s.io/apimachinery v0.35.2
- k8s.io/apiserver v0.35.2
- k8s.io/client-go v1.5.2
- k8s.io/component-base v0.35.2
- k8s.io/controller-manager v0.35.2
- k8s.io/klog/v2 v2.130.1
- k8s.io/kubernetes v1.35.2
- k8s.io/utils v0.0.0-20251002143259-bc988d571ff4
+ k8s.io/api v0.36.3
+ k8s.io/apimachinery v0.36.3
+ k8s.io/apiserver v0.36.3
+ k8s.io/client-go v0.36.3
+ k8s.io/component-base v0.36.3
+ k8s.io/controller-manager v0.36.3
+ k8s.io/klog/v2 v2.140.0
+ k8s.io/kubernetes v1.36.3
+ k8s.io/utils v0.0.0-20260707023825-cf1189d6abe3
sigs.k8s.io/randfill v1.0.0
)
require (
- cel.dev/expr v0.24.0 // indirect
+ cel.dev/expr v0.25.1 // indirect
github.com/NYTimes/gziphandler v1.1.1 // indirect
github.com/antlr4-go/antlr/v4 v4.13.0 // indirect
github.com/asaskevich/govalidator v0.0.0-20230301143203-a9d515a09cc2 // indirect
github.com/beorn7/perks v1.0.1 // indirect
- github.com/cenkalti/backoff/v4 v4.3.0 // indirect
+ github.com/cenkalti/backoff/v5 v5.0.3 // indirect
github.com/cespare/xxhash/v2 v2.3.0 // indirect
github.com/containers/libtrust v0.0.0-20230121012942-c1716e8a8d01 // indirect
github.com/containers/ocicrypt v1.1.9 // indirect
github.com/containers/storage v1.53.0 // indirect
github.com/coreos/go-semver v0.3.1 // indirect
- github.com/coreos/go-systemd/v22 v22.5.0 // indirect
+ github.com/coreos/go-systemd/v22 v22.7.0 // indirect
github.com/cyberphone/json-canonicalization v0.0.0-20231217050601-ba74d44ecf5f // indirect
github.com/distribution/reference v0.6.0 // indirect
github.com/docker/distribution v2.8.3+incompatible // indirect
@@ -52,7 +52,7 @@ require (
github.com/docker/docker-credential-helpers v0.8.1 // indirect
github.com/docker/go-connections v0.5.0 // indirect
github.com/docker/go-units v0.5.0 // indirect
- github.com/emicklei/go-restful/v3 v3.12.2 // indirect
+ github.com/emicklei/go-restful/v3 v3.13.0 // indirect
github.com/felixge/fgprof v0.9.4 // indirect
github.com/felixge/httpsnoop v1.0.4 // indirect
github.com/fsnotify/fsnotify v1.9.0 // indirect
@@ -67,28 +67,37 @@ require (
github.com/go-openapi/runtime v0.26.0 // indirect
github.com/go-openapi/spec v0.20.9 // indirect
github.com/go-openapi/strfmt v0.22.2 // indirect
- github.com/go-openapi/swag v0.23.0 // indirect
+ github.com/go-openapi/swag v0.25.4 // indirect
+ github.com/go-openapi/swag/cmdutils v0.25.4 // indirect
+ github.com/go-openapi/swag/conv v0.25.4 // indirect
+ github.com/go-openapi/swag/fileutils v0.25.4 // indirect
+ github.com/go-openapi/swag/jsonname v0.25.4 // indirect
+ github.com/go-openapi/swag/jsonutils v0.25.4 // indirect
+ github.com/go-openapi/swag/loading v0.25.4 // indirect
+ github.com/go-openapi/swag/mangling v0.25.4 // indirect
+ github.com/go-openapi/swag/netutils v0.25.4 // indirect
+ github.com/go-openapi/swag/stringutils v0.25.4 // indirect
+ github.com/go-openapi/swag/typeutils v0.25.4 // indirect
+ github.com/go-openapi/swag/yamlutils v0.25.4 // indirect
github.com/go-openapi/validate v0.22.1 // indirect
github.com/gogo/protobuf v1.3.2 // indirect
github.com/golang/protobuf v1.5.4 // indirect
- github.com/google/btree v1.1.3 // indirect
github.com/google/cel-go v0.26.0 // indirect
github.com/google/gnostic-models v0.7.0 // indirect
github.com/google/go-containerregistry v0.19.0 // indirect
- github.com/google/pprof v0.0.0-20250403155104-27863c87afa6 // indirect
+ github.com/google/pprof v0.0.0-20260115054156-294ebfa9ad83 // indirect
github.com/gorilla/mux v1.8.1 // indirect
- github.com/grpc-ecosystem/go-grpc-prometheus v1.2.1-0.20210315223345-82c243799c99 // indirect
- github.com/grpc-ecosystem/grpc-gateway/v2 v2.26.3 // indirect
+ github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus v1.1.0 // indirect
+ github.com/grpc-ecosystem/go-grpc-middleware/v2 v2.3.3 // indirect
+ github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.7 // indirect
github.com/hashicorp/errwrap v1.1.0 // indirect
github.com/hashicorp/go-multierror v1.1.1 // indirect
github.com/inconshreveable/mousetrap v1.1.0 // indirect
- github.com/josharian/intern v1.0.0 // indirect
github.com/json-iterator/go v1.1.12 // indirect
github.com/klauspost/compress v1.18.0 // indirect
github.com/klauspost/pgzip v1.2.6 // indirect
github.com/kylelemons/godebug v1.1.0 // indirect
github.com/letsencrypt/boulder v0.0.0-20230907030200-6d76a0f91e1e // indirect
- github.com/mailru/easyjson v0.7.7 // indirect
github.com/mitchellh/mapstructure v1.5.0 // indirect
github.com/moby/sys/mountinfo v0.7.2 // indirect
github.com/moby/sys/user v0.4.0 // indirect
@@ -98,102 +107,104 @@ require (
github.com/oklog/ulid v1.3.1 // indirect
github.com/opencontainers/go-digest v1.0.0 // indirect
github.com/opencontainers/image-spec v1.1.1 // indirect
- github.com/opencontainers/runtime-spec v1.2.1 // indirect
+ github.com/opencontainers/runtime-spec v1.3.0 // indirect
github.com/pkg/errors v0.9.1 // indirect
github.com/pkg/profile v1.7.0 // indirect
github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect
github.com/proglottis/gpgme v0.1.3 // indirect
- github.com/prometheus/common v0.66.1 // indirect
- github.com/prometheus/procfs v0.16.1 // indirect
+ github.com/prometheus/common v0.67.5 // indirect
+ github.com/prometheus/procfs v0.19.2 // indirect
github.com/robfig/cron/v3 v3.0.1 // indirect
github.com/secure-systems-lab/go-securesystemslib v0.8.0 // indirect
github.com/sigstore/fulcio v1.4.3 // indirect
github.com/sigstore/rekor v1.2.2 // indirect
github.com/sigstore/sigstore v1.8.2 // indirect
github.com/sirupsen/logrus v1.9.3 // indirect
- github.com/spf13/pflag v1.0.9 // indirect
+ github.com/spf13/pflag v1.0.10 // indirect
github.com/stoewer/go-strcase v1.3.0 // indirect
github.com/syndtr/gocapability v0.0.0-20200815063812-42c35b437635 // indirect
github.com/titanous/rocacheck v0.0.0-20171023193734-afe73141d399 // indirect
github.com/ulikunitz/xz v0.5.11 // indirect
github.com/vbatts/tar-split v0.11.5 // indirect
github.com/x448/float16 v0.8.4 // indirect
- go.etcd.io/etcd/api/v3 v3.6.5 // indirect
- go.etcd.io/etcd/client/pkg/v3 v3.6.5 // indirect
- go.etcd.io/etcd/client/v3 v3.6.5 // indirect
+ go.etcd.io/etcd/api/v3 v3.6.8 // indirect
+ go.etcd.io/etcd/client/pkg/v3 v3.6.8 // indirect
+ go.etcd.io/etcd/client/v3 v3.6.8 // indirect
go.mongodb.org/mongo-driver v1.14.0 // indirect
- go.opentelemetry.io/auto/sdk v1.1.0 // indirect
- go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.60.0 // indirect
- go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.61.0 // indirect
- go.opentelemetry.io/otel v1.36.0 // indirect
- go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.34.0 // indirect
- go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.34.0 // indirect
- go.opentelemetry.io/otel/metric v1.36.0 // indirect
- go.opentelemetry.io/otel/sdk v1.36.0 // indirect
- go.opentelemetry.io/otel/trace v1.36.0 // indirect
- go.opentelemetry.io/proto/otlp v1.5.0 // indirect
+ go.opentelemetry.io/auto/sdk v1.2.1 // indirect
+ go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.65.0 // indirect
+ go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.65.0 // indirect
+ go.opentelemetry.io/otel v1.41.0 // indirect
+ go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.40.0 // indirect
+ go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.40.0 // indirect
+ go.opentelemetry.io/otel/metric v1.41.0 // indirect
+ go.opentelemetry.io/otel/sdk v1.40.0 // indirect
+ go.opentelemetry.io/otel/trace v1.41.0 // indirect
+ go.opentelemetry.io/proto/otlp v1.9.0 // indirect
go.uber.org/multierr v1.11.0 // indirect
- go.uber.org/zap v1.27.0 // indirect
+ go.uber.org/zap v1.27.1 // indirect
go.yaml.in/yaml/v2 v2.4.3 // indirect
go.yaml.in/yaml/v3 v3.0.4 // indirect
- golang.org/x/crypto v0.45.0 // indirect
- golang.org/x/net v0.47.0 // indirect
- golang.org/x/oauth2 v0.30.0 // indirect
- golang.org/x/sync v0.18.0 // indirect
- golang.org/x/sys v0.38.0 // indirect
- golang.org/x/term v0.37.0 // indirect
- golang.org/x/text v0.31.0 // indirect
- golang.org/x/time v0.9.0 // indirect
- google.golang.org/genproto/googleapis/api v0.0.0-20250303144028-a0af3efb3deb // indirect
- google.golang.org/genproto/googleapis/rpc v0.0.0-20250528174236-200df99c418a // indirect
- google.golang.org/grpc v1.72.2 // indirect
- google.golang.org/protobuf v1.36.8 // indirect
+ golang.org/x/crypto v0.53.0 // indirect
+ golang.org/x/net v0.56.0 // indirect
+ golang.org/x/oauth2 v0.34.0 // indirect
+ golang.org/x/sync v0.21.0 // indirect
+ golang.org/x/sys v0.46.0 // indirect
+ golang.org/x/term v0.44.0 // indirect
+ golang.org/x/text v0.39.0 // indirect
+ golang.org/x/time v0.15.0 // indirect
+ google.golang.org/genproto/googleapis/api v0.0.0-20260128011058-8636f8732409 // indirect
+ google.golang.org/genproto/googleapis/rpc v0.0.0-20260128011058-8636f8732409 // indirect
+ google.golang.org/grpc v1.79.3 // indirect
+ google.golang.org/protobuf v1.36.12-0.20260120151049-f2248ac996af // indirect
gopkg.in/evanphx/json-patch.v4 v4.13.0 // indirect
gopkg.in/inf.v0 v0.9.1 // indirect
gopkg.in/natefinch/lumberjack.v2 v2.2.1 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
- k8s.io/apiextensions-apiserver v0.35.1 // indirect
+ k8s.io/apiextensions-apiserver v0.36.2 // indirect
k8s.io/component-helpers v0.33.2 // indirect
- k8s.io/kms v0.35.2 // indirect
- k8s.io/kube-openapi v0.0.0-20250910181357-589584f1c912 // indirect
+ k8s.io/kms v0.36.3 // indirect
+ k8s.io/kube-openapi v0.0.0-20260519202549-bbf5c5577288 // indirect
k8s.io/kubelet v0.29.1 // indirect
- sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.31.2 // indirect
+ k8s.io/streaming v0.36.3 // indirect
+ sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.34.0 // indirect
sigs.k8s.io/json v0.0.0-20250730193827-2d320260d730 // indirect
- sigs.k8s.io/structured-merge-diff/v6 v6.3.0 // indirect
+ sigs.k8s.io/structured-merge-diff/v6 v6.3.3 // indirect
sigs.k8s.io/yaml v1.6.0 // indirect
)
replace (
// these are needed since k8s.io/kubernetes cites v0.0.0 for each of these k8s deps in its go.mod
- k8s.io/api => k8s.io/api v0.35.2
- k8s.io/apiextensions-apiserver => k8s.io/apiextensions-apiserver v0.35.2
- k8s.io/apimachinery => k8s.io/apimachinery v0.35.2
- k8s.io/apiserver => k8s.io/apiserver v0.35.2
- k8s.io/cli-runtime => k8s.io/cli-runtime v0.35.2
- k8s.io/client-go => k8s.io/client-go v0.35.2
- k8s.io/cloud-provider => k8s.io/cloud-provider v0.35.2
- k8s.io/cluster-bootstrap => k8s.io/cluster-bootstrap v0.35.2
- k8s.io/code-generator => k8s.io/code-generator v0.35.2
- k8s.io/component-base => k8s.io/component-base v0.35.2
- k8s.io/component-helpers => k8s.io/component-helpers v0.35.2
- k8s.io/controller-manager => k8s.io/controller-manager v0.35.2
- k8s.io/cri-api => k8s.io/cri-api v0.35.2
- k8s.io/csi-translation-lib => k8s.io/csi-translation-lib v0.35.2
- k8s.io/dynamic-resource-allocation => k8s.io/dynamic-resource-allocation v0.35.2
- k8s.io/endpointslice => k8s.io/endpointslice v0.35.2
- k8s.io/kms => k8s.io/kms v0.35.2
- k8s.io/kube-aggregator => k8s.io/kube-aggregator v0.35.2
- k8s.io/kube-controller-manager => k8s.io/kube-controller-manager v0.35.2
- k8s.io/kube-proxy => k8s.io/kube-proxy v0.35.2
- k8s.io/kube-scheduler => k8s.io/kube-scheduler v0.35.2
- k8s.io/kubectl => k8s.io/kubectl v0.35.2
- k8s.io/kubelet => k8s.io/kubelet v0.35.2
- k8s.io/kubernetes => k8s.io/kubernetes v1.35.2
- k8s.io/legacy-cloud-providers => k8s.io/legacy-cloud-providers v0.35.2
- k8s.io/metrics => k8s.io/metrics v0.35.2
- k8s.io/mount-utils => k8s.io/mount-utils v0.35.2
- k8s.io/pod-security-admission => k8s.io/pod-security-admission v0.35.2
- k8s.io/sample-apiserver => k8s.io/sample-apiserver v0.35.2
+ k8s.io/api => k8s.io/api v0.36.3
+ k8s.io/apiextensions-apiserver => k8s.io/apiextensions-apiserver v0.36.3
+ k8s.io/apimachinery => k8s.io/apimachinery v0.36.3
+ k8s.io/apiserver => k8s.io/apiserver v0.36.3
+ k8s.io/cli-runtime => k8s.io/cli-runtime v0.36.3
+ // temporary bump to release-1.36:HEAD to add the missing https://github.com/kubernetes/client-go/commit/f4108cdac6d8de448edbd1ace56e38bde257ff56
+ k8s.io/client-go => k8s.io/client-go v0.0.0-20260808041404-a92355f83186
+ k8s.io/cloud-provider => k8s.io/cloud-provider v0.36.3
+ k8s.io/cluster-bootstrap => k8s.io/cluster-bootstrap v0.36.3
+ k8s.io/code-generator => k8s.io/code-generator v0.36.3
+ k8s.io/component-base => k8s.io/component-base v0.36.3
+ k8s.io/component-helpers => k8s.io/component-helpers v0.36.3
+ k8s.io/controller-manager => k8s.io/controller-manager v0.36.3
+ k8s.io/cri-api => k8s.io/cri-api v0.36.3
+ k8s.io/csi-translation-lib => k8s.io/csi-translation-lib v0.36.3
+ k8s.io/dynamic-resource-allocation => k8s.io/dynamic-resource-allocation v0.36.3
+ k8s.io/endpointslice => k8s.io/endpointslice v0.36.3
+ k8s.io/kms => k8s.io/kms v0.36.3
+ k8s.io/kube-aggregator => k8s.io/kube-aggregator v0.36.3
+ k8s.io/kube-controller-manager => k8s.io/kube-controller-manager v0.36.3
+ k8s.io/kube-proxy => k8s.io/kube-proxy v0.36.3
+ k8s.io/kube-scheduler => k8s.io/kube-scheduler v0.36.3
+ k8s.io/kubectl => k8s.io/kubectl v0.36.3
+ k8s.io/kubelet => k8s.io/kubelet v0.36.3
+ k8s.io/kubernetes => k8s.io/kubernetes v1.36.3
+ k8s.io/legacy-cloud-providers => k8s.io/legacy-cloud-providers v0.36.3
+ k8s.io/metrics => k8s.io/metrics v0.36.3
+ k8s.io/mount-utils => k8s.io/mount-utils v0.36.3
+ k8s.io/pod-security-admission => k8s.io/pod-security-admission v0.36.3
+ k8s.io/sample-apiserver => k8s.io/sample-apiserver v0.36.3
)
replace (
diff --git a/go.sum b/go.sum
index 88551707a5..45bb4707f9 100644
--- a/go.sum
+++ b/go.sum
@@ -1,13 +1,10 @@
-cel.dev/expr v0.24.0 h1:56OvJKSH3hDGL0ml5uSxZmz3/3Pq4tJ+fb1unVLAFcY=
-cel.dev/expr v0.24.0/go.mod h1:hLPLo1W4QUmuYdA72RBX06QTs6MXw941piREPl3Yfiw=
-cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw=
+cel.dev/expr v0.25.1 h1:1KrZg61W6TWSxuNZ37Xy49ps13NUovb66QLprthtwi4=
+cel.dev/expr v0.25.1/go.mod h1:hrXvqGP6G6gyx8UAHSHJ5RGk//1Oj5nXQ2NI02Nrsg4=
dario.cat/mergo v1.0.0 h1:AGCNq9Evsj31mOgNPcLyXc+4PNABt905YmuqPYYpBWk=
dario.cat/mergo v1.0.0/go.mod h1:uNxQE+84aUszobStD9th8a29P2fMDhsBdgRYvZOxGmk=
github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU=
github.com/BurntSushi/toml v1.5.0 h1:W5quZX/G/csjUnuI8SUYlsHs9M38FC7znL0lIO+DvMg=
github.com/BurntSushi/toml v1.5.0/go.mod h1:ukJfTF/6rtPPRCnwkur4qwRxa8vTRFBF0uk2lLoLwho=
-github.com/Masterminds/semver/v3 v3.4.0 h1:Zog+i5UMtVoCU8oKka5P7i9q9HgrJeGzI9SA1Xbatp0=
-github.com/Masterminds/semver/v3 v3.4.0/go.mod h1:4V+yj/TJE1HU9XfppCwVMZq3I84lprf4nC11bSS5beM=
github.com/NYTimes/gziphandler v1.1.1 h1:ZUDjpQae29j0ryrS0u/B8HZfJBtBQHjqw2rQ2cqUQ3I=
github.com/NYTimes/gziphandler v1.1.1/go.mod h1:n/CVRwUEOgIxrgPvAQhUUr9oeUtvrhMomdKFjzJNB0c=
github.com/PuerkitoBio/purell v1.1.1/go.mod h1:c11w/QuzBsJSee3cPx9rAFu61PvFxuPbtSwDGJws/X0=
@@ -17,13 +14,12 @@ github.com/antlr4-go/antlr/v4 v4.13.0/go.mod h1:pfChB/xh/Unjila75QW7+VU4TSnWnnk9
github.com/asaskevich/govalidator v0.0.0-20200907205600-7a23bdc65eef/go.mod h1:WaHUgvxTVq04UNunO+XhnAqY/wQc+bxr74GqbsZ/Jqw=
github.com/asaskevich/govalidator v0.0.0-20230301143203-a9d515a09cc2 h1:DklsrG3dyBCFEj5IhUbnKptjxatkF07cF2ak3yi77so=
github.com/asaskevich/govalidator v0.0.0-20230301143203-a9d515a09cc2/go.mod h1:WaHUgvxTVq04UNunO+XhnAqY/wQc+bxr74GqbsZ/Jqw=
-github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q=
github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM=
github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw=
github.com/blang/semver/v4 v4.0.0 h1:1PFHFE6yCCTv8C1TeyNNarDzntLi7wMI5i/pzqYIsAM=
github.com/blang/semver/v4 v4.0.0/go.mod h1:IbckMUScFkM3pff0VJDNKRiT6TG/YpiHIM2yvyW5YoQ=
-github.com/cenkalti/backoff/v4 v4.3.0 h1:MyRJ/UdXutAwSAT+s3wNd7MfTIcy71VQueUuFK343L8=
-github.com/cenkalti/backoff/v4 v4.3.0/go.mod h1:Y3VNntkOUPxTVeUxJ/G5vcM//AlwfmyYozVcomhLiZE=
+github.com/cenkalti/backoff/v5 v5.0.3 h1:ZN+IMa753KfX5hd8vVaMixjnqRZ3y8CuJKRKj1xcsSM=
+github.com/cenkalti/backoff/v5 v5.0.3/go.mod h1:rkhZdG3JZukswDf7f0cwqPNk4K0sa+F97BxZthm/crw=
github.com/cespare/xxhash/v2 v2.3.0 h1:UL815xU9SqsFlibzuggzjXhog7bL6oX9BbNZnL2UFvs=
github.com/cespare/xxhash/v2 v2.3.0/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs=
github.com/chromedp/cdproto v0.0.0-20230802225258-3cf4e6d46a89/go.mod h1:GKljq0VrfU4D5yc+2qA6OVr8pmO/MBbPEWqWQ/oqGEs=
@@ -35,7 +31,6 @@ github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e/go.mod h1:nSuG5e5P
github.com/chzyer/readline v1.5.1/go.mod h1:Eh+b79XXUwfKfcPLepksvw2tcLE/Ct21YObkaSkeBlk=
github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU=
github.com/chzyer/test v1.0.0/go.mod h1:2JlltgoNkt4TW/z9V/IzDdFaMTM2JPIi26O1pF38GC8=
-github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw=
github.com/containerd/log v0.1.0 h1:TCJt7ioM2cr/tfR8GPbGf9/VRAX8D2B4PjzCpfX540I=
github.com/containerd/log v0.1.0/go.mod h1:VRRf09a7mHDIRezVKTRCrOq78v577GXq3bSa3EhrzVo=
github.com/containers/image/v5 v5.30.1 h1:AKrQMgOKI1oKx5FW5eoU2xoNyzACajHGx1O3qxobvFM=
@@ -48,8 +43,8 @@ github.com/containers/storage v1.53.0 h1:VSES3C/u1pxjTJIXvLrSmyP7OBtDky04oGu07Uv
github.com/containers/storage v1.53.0/go.mod h1:pujcoOSc+upx15Jirdkebhtd8uJiLwbSd/mYT6zDJK8=
github.com/coreos/go-semver v0.3.1 h1:yi21YpKnrx1gt5R+la8n5WgS0kCrsPp33dmEyHReZr4=
github.com/coreos/go-semver v0.3.1/go.mod h1:irMmmIw/7yzSRPWryHsK7EYSg09caPQL03VsM8rvUec=
-github.com/coreos/go-systemd/v22 v22.5.0 h1:RrqgGjYQKalulkV8NGVIfkXQf6YYmOyiJKk8iXXhfZs=
-github.com/coreos/go-systemd/v22 v22.5.0/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSVTIJ3seZv2GcEnc=
+github.com/coreos/go-systemd/v22 v22.7.0 h1:LAEzFkke61DFROc7zNLX/WA2i5J8gYqe0rSj9KI28KA=
+github.com/coreos/go-systemd/v22 v22.7.0/go.mod h1:xNUYtjHu2EDXbsxz1i41wouACIwT7Ybq9o0BQhMwD0w=
github.com/cpuguy83/go-md2man/v2 v2.0.6/go.mod h1:oOW0eioCTA6cOiMLiUPZOpcVxMig6NIQQ7OS05n1F4g=
github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E=
github.com/cyberphone/json-canonicalization v0.0.0-20231217050601-ba74d44ecf5f h1:eHnXnuK47UlSTOQexbzxAZfekVz6i+LKRdj1CU5DPaM=
@@ -76,8 +71,8 @@ github.com/docker/go-units v0.5.0 h1:69rxXcBk27SvSaaxTtLh/8llcHD8vYHT7WSdRZ/jvr4
github.com/docker/go-units v0.5.0/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk=
github.com/dustin/go-humanize v1.0.1 h1:GzkhY7T5VNhEkwH0PVJgjz+fX1rhBrR7pRT3mDkpeCY=
github.com/dustin/go-humanize v1.0.1/go.mod h1:Mu1zIs6XwVuF/gI1OepvI0qD18qycQx+mFykh5fBlto=
-github.com/emicklei/go-restful/v3 v3.12.2 h1:DhwDP0vY3k8ZzE0RunuJy8GhNpPL6zqLkDf9B/a0/xU=
-github.com/emicklei/go-restful/v3 v3.12.2/go.mod h1:6n3XBCmQQb25CM2LCACGz8ukIrRry+4bhvbpWn3mrbc=
+github.com/emicklei/go-restful/v3 v3.13.0 h1:C4Bl2xDndpU6nJ4bc1jXd+uTmYPVUwkD6bFY/oTyCes=
+github.com/emicklei/go-restful/v3 v3.13.0/go.mod h1:6n3XBCmQQb25CM2LCACGz8ukIrRry+4bhvbpWn3mrbc=
github.com/felixge/fgprof v0.9.3/go.mod h1:RdbpDgzqYVh/T9fPELJyV7EYJuHB55UTEULNun8eiPw=
github.com/felixge/fgprof v0.9.4 h1:ocDNwMFlnA0NU0zSB3I52xkO4sFXk80VK9lXjLClu88=
github.com/felixge/fgprof v0.9.4/go.mod h1:yKl+ERSa++RYOs32d8K6WEXCB4uXdLls4ZaZPpayhMM=
@@ -129,13 +124,39 @@ github.com/go-openapi/swag v0.19.5/go.mod h1:POnQmlKehdgb5mhVOsnJFsivZCEZ/vjK9gh
github.com/go-openapi/swag v0.19.15/go.mod h1:QYRuS/SOXUCsnplDa677K7+DxSOj6IPNl/eQntq43wQ=
github.com/go-openapi/swag v0.21.1/go.mod h1:QYRuS/SOXUCsnplDa677K7+DxSOj6IPNl/eQntq43wQ=
github.com/go-openapi/swag v0.22.3/go.mod h1:UzaqsxGiab7freDnrUUra0MwWfN/q7tE4j+VcZ0yl14=
-github.com/go-openapi/swag v0.23.0 h1:vsEVJDUo2hPJ2tu0/Xc+4noaxyEffXNIs3cOULZ+GrE=
-github.com/go-openapi/swag v0.23.0/go.mod h1:esZ8ITTYEsH1V2trKHjAN8Ai7xHb8RV+YSZ577vPjgQ=
+github.com/go-openapi/swag v0.25.4 h1:OyUPUFYDPDBMkqyxOTkqDYFnrhuhi9NR6QVUvIochMU=
+github.com/go-openapi/swag v0.25.4/go.mod h1:zNfJ9WZABGHCFg2RnY0S4IOkAcVTzJ6z2Bi+Q4i6qFQ=
+github.com/go-openapi/swag/cmdutils v0.25.4 h1:8rYhB5n6WawR192/BfUu2iVlxqVR9aRgGJP6WaBoW+4=
+github.com/go-openapi/swag/cmdutils v0.25.4/go.mod h1:pdae/AFo6WxLl5L0rq87eRzVPm/XRHM3MoYgRMvG4A0=
+github.com/go-openapi/swag/conv v0.25.4 h1:/Dd7p0LZXczgUcC/Ikm1+YqVzkEeCc9LnOWjfkpkfe4=
+github.com/go-openapi/swag/conv v0.25.4/go.mod h1:3LXfie/lwoAv0NHoEuY1hjoFAYkvlqI/Bn5EQDD3PPU=
+github.com/go-openapi/swag/fileutils v0.25.4 h1:2oI0XNW5y6UWZTC7vAxC8hmsK/tOkWXHJQH4lKjqw+Y=
+github.com/go-openapi/swag/fileutils v0.25.4/go.mod h1:cdOT/PKbwcysVQ9Tpr0q20lQKH7MGhOEb6EwmHOirUk=
+github.com/go-openapi/swag/jsonname v0.25.4 h1:bZH0+MsS03MbnwBXYhuTttMOqk+5KcQ9869Vye1bNHI=
+github.com/go-openapi/swag/jsonname v0.25.4/go.mod h1:GPVEk9CWVhNvWhZgrnvRA6utbAltopbKwDu8mXNUMag=
+github.com/go-openapi/swag/jsonutils v0.25.4 h1:VSchfbGhD4UTf4vCdR2F4TLBdLwHyUDTd1/q4i+jGZA=
+github.com/go-openapi/swag/jsonutils v0.25.4/go.mod h1:7OYGXpvVFPn4PpaSdPHJBtF0iGnbEaTk8AvBkoWnaAY=
+github.com/go-openapi/swag/jsonutils/fixtures_test v0.25.4 h1:IACsSvBhiNJwlDix7wq39SS2Fh7lUOCJRmx/4SN4sVo=
+github.com/go-openapi/swag/jsonutils/fixtures_test v0.25.4/go.mod h1:Mt0Ost9l3cUzVv4OEZG+WSeoHwjWLnarzMePNDAOBiM=
+github.com/go-openapi/swag/loading v0.25.4 h1:jN4MvLj0X6yhCDduRsxDDw1aHe+ZWoLjW+9ZQWIKn2s=
+github.com/go-openapi/swag/loading v0.25.4/go.mod h1:rpUM1ZiyEP9+mNLIQUdMiD7dCETXvkkC30z53i+ftTE=
+github.com/go-openapi/swag/mangling v0.25.4 h1:2b9kBJk9JvPgxr36V23FxJLdwBrpijI26Bx5JH4Hp48=
+github.com/go-openapi/swag/mangling v0.25.4/go.mod h1:6dxwu6QyORHpIIApsdZgb6wBk/DPU15MdyYj/ikn0Hg=
+github.com/go-openapi/swag/netutils v0.25.4 h1:Gqe6K71bGRb3ZQLusdI8p/y1KLgV4M/k+/HzVSqT8H0=
+github.com/go-openapi/swag/netutils v0.25.4/go.mod h1:m2W8dtdaoX7oj9rEttLyTeEFFEBvnAx9qHd5nJEBzYg=
+github.com/go-openapi/swag/stringutils v0.25.4 h1:O6dU1Rd8bej4HPA3/CLPciNBBDwZj9HiEpdVsb8B5A8=
+github.com/go-openapi/swag/stringutils v0.25.4/go.mod h1:GTsRvhJW5xM5gkgiFe0fV3PUlFm0dr8vki6/VSRaZK0=
+github.com/go-openapi/swag/typeutils v0.25.4 h1:1/fbZOUN472NTc39zpa+YGHn3jzHWhv42wAJSN91wRw=
+github.com/go-openapi/swag/typeutils v0.25.4/go.mod h1:Ou7g//Wx8tTLS9vG0UmzfCsjZjKhpjxayRKTHXf2pTE=
+github.com/go-openapi/swag/yamlutils v0.25.4 h1:6jdaeSItEUb7ioS9lFoCZ65Cne1/RZtPBZ9A56h92Sw=
+github.com/go-openapi/swag/yamlutils v0.25.4/go.mod h1:MNzq1ulQu+yd8Kl7wPOut/YHAAU/H6hL91fF+E2RFwc=
+github.com/go-openapi/testify/enable/yaml/v2 v2.0.2 h1:0+Y41Pz1NkbTHz8NngxTuAXxEodtNSI1WG1c/m5Akw4=
+github.com/go-openapi/testify/enable/yaml/v2 v2.0.2/go.mod h1:kme83333GCtJQHXQ8UKX3IBZu6z8T5Dvy5+CW3NLUUg=
+github.com/go-openapi/testify/v2 v2.0.2 h1:X999g3jeLcoY8qctY/c/Z8iBHTbwLz7R2WXd6Ub6wls=
+github.com/go-openapi/testify/v2 v2.0.2/go.mod h1:HCPmvFFnheKK2BuwSA0TbbdxJ3I16pjwMkYkP4Ywn54=
github.com/go-openapi/validate v0.22.1 h1:G+c2ub6q47kfX1sOBLwIQwzBVt8qmOAARyo/9Fqs9NU=
github.com/go-openapi/validate v0.22.1/go.mod h1:rjnrwK57VJ7A8xqfpAOEKRH8yQSGUriMu5/zuPSQ1hg=
github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY=
-github.com/go-task/slim-sprig/v3 v3.0.0 h1:sUs3vkvUymDpBKi3qH1YSqBQk9+9D/8M2mN1vB6EwHI=
-github.com/go-task/slim-sprig/v3 v3.0.0/go.mod h1:W848ghGpv3Qj3dhTPRyJypKRiqCdHZiAzKg9hl15HA8=
github.com/go-test/deep v1.1.0 h1:WOcxcdHcvdgThNXjw0t76K42FXTU7HpNQWHpA2HHNlg=
github.com/go-test/deep v1.1.0/go.mod h1:5C2ZWiW0ErCdrYzpqxLbTX7MG14M9iiw8DgHncVwcsE=
github.com/gobuffalo/attrs v0.0.0-20190224210810-a9411de4debd/go.mod h1:4duuawTqi2wkkpB4ePgWMaai6/Kc6WEz83bhFwpHzj0=
@@ -165,14 +186,10 @@ github.com/gobuffalo/syncx v0.0.0-20190224160051-33c29581e754/go.mod h1:HhnNqWY9
github.com/gobwas/httphead v0.1.0/go.mod h1:O/RXo79gxV8G+RqlR/otEwx4Q36zl9rqC5u12GKvMCM=
github.com/gobwas/pool v0.2.1/go.mod h1:q8bcK0KcYlCgd9e7WYLm9LpyS+YeLd8JVDW6WezmKEw=
github.com/gobwas/ws v1.2.1/go.mod h1:hRKAFb8wOxFROYNsT1bqfWnhX+b5MFeJM9r2ZSwg/KY=
-github.com/godbus/dbus/v5 v5.0.4/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA=
github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q=
github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q=
-github.com/golang-jwt/jwt/v5 v5.2.2 h1:Rl4B7itRWVtYIHFrSNd7vhTiz9UpLdi6gZhZ3wEeDy8=
-github.com/golang-jwt/jwt/v5 v5.2.2/go.mod h1:pqrtFR0X4osieyHYxtmOUWsAWrfe1Q5UVIyoH402zdk=
-github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q=
-github.com/golang/mock v1.1.1/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A=
-github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
+github.com/golang-jwt/jwt/v5 v5.3.0 h1:pv4AsKCKKZuqlgs5sUmn4x8UlGa0kEVt/puTpKx9vvo=
+github.com/golang-jwt/jwt/v5 v5.3.0/go.mod h1:fxCRLWMO43lRc8nhHWY6LGqRcf+1gQWArsqaEUEa5bE=
github.com/golang/protobuf v1.5.4 h1:i7eJL8qZTpSEXOPTxNKhASYpMn+8e5Q6AdndVa1dWek=
github.com/golang/protobuf v1.5.4/go.mod h1:lnTiLA8Wa4RWRcIUkrtSVa5nRhsEGBg48fD6rSs7xps=
github.com/golang/snappy v0.0.1/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q=
@@ -190,8 +207,8 @@ github.com/google/go-containerregistry v0.19.0/go.mod h1:u0qB2l7mvtWVR5kNcbFIhFY
github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg=
github.com/google/pprof v0.0.0-20211214055906-6f57359322fd/go.mod h1:KgnwoLYCZ8IQu3XUZ8Nc/bM9CCZFOyjUNOSygVozoDg=
github.com/google/pprof v0.0.0-20240227163752-401108e1b7e7/go.mod h1:czg5+yv1E0ZGTi6S6vVK1mke0fV+FaUhNGcd6VRS9Ik=
-github.com/google/pprof v0.0.0-20250403155104-27863c87afa6 h1:BHT72Gu3keYf3ZEu2J0b1vyeLSOYI8bm5wbJM/8yDe8=
-github.com/google/pprof v0.0.0-20250403155104-27863c87afa6/go.mod h1:boTsfXsheKC2y+lKOCMpSfarhxDeIzfZG1jqGcPl3cA=
+github.com/google/pprof v0.0.0-20260115054156-294ebfa9ad83 h1:z2ogiKUYzX5Is6zr/vP9vJGqPwcdqsWjOt+V8J7+bTc=
+github.com/google/pprof v0.0.0-20260115054156-294ebfa9ad83/go.mod h1:MxpfABSjhmINe3F1It9d+8exIHFvUqtLIRCdOGNXqiI=
github.com/google/uuid v1.1.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
github.com/google/uuid v1.6.0 h1:NIvaJDMOsjHA8n1jAhLSgzrAzy1Hgr+hNrb57e+94F0=
github.com/google/uuid v1.6.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
@@ -199,15 +216,12 @@ github.com/gorilla/mux v1.8.1 h1:TuBL49tXwgrFYWhqrNgrUNEY92u81SPhu7sTdzQEiWY=
github.com/gorilla/mux v1.8.1/go.mod h1:AKf9I4AEqPTmMytcMc0KkNouC66V3BtZ4qD5fmWSiMQ=
github.com/gorilla/websocket v1.5.4-0.20250319132907-e064f32e3674 h1:JeSE6pjso5THxAzdVpqr6/geYxZytqFMBCOtn/ujyeo=
github.com/gorilla/websocket v1.5.4-0.20250319132907-e064f32e3674/go.mod h1:r4w70xmWCQKmi1ONH4KIaBptdivuRPyosB9RmPlGEwA=
-github.com/grpc-ecosystem/go-grpc-middleware v1.4.0 h1:UH//fgunKIs4JdUbpDl1VZCDaL56wXCB/5+wF6uHfaI=
-github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus v1.0.1 h1:qnpSQwGEnkcRpTqNOIR6bJbR0gAorgP9CSALpRcKoAA=
-github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus v1.0.1/go.mod h1:lXGCsh6c22WGtjr+qGHj1otzZpV/1kwTMAqkwZsnWRU=
-github.com/grpc-ecosystem/go-grpc-middleware/v2 v2.3.0 h1:FbSCl+KggFl+Ocym490i/EyXF4lPgLoUtcSWquBM0Rs=
-github.com/grpc-ecosystem/go-grpc-middleware/v2 v2.3.0/go.mod h1:qOchhhIlmRcqk/O9uCo/puJlyo07YINaIqdZfZG3Jkc=
-github.com/grpc-ecosystem/go-grpc-prometheus v1.2.1-0.20210315223345-82c243799c99 h1:JYghRBlGCZyCF2wNUJ8W0cwaQdtpcssJ4CgC406g+WU=
-github.com/grpc-ecosystem/go-grpc-prometheus v1.2.1-0.20210315223345-82c243799c99/go.mod h1:3bDW6wMZJB7tiONtC/1Xpicra6Wp5GgbTbQWCbI5fkc=
-github.com/grpc-ecosystem/grpc-gateway/v2 v2.26.3 h1:5ZPtiqj0JL5oKWmcsq4VMaAW5ukBEgSGXEN89zeH1Jo=
-github.com/grpc-ecosystem/grpc-gateway/v2 v2.26.3/go.mod h1:ndYquD05frm2vACXE1nsccT4oJzjhw2arTS2cpUD1PI=
+github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus v1.1.0 h1:QGLs/O40yoNK9vmy4rhUGBVyMf1lISBGtXRpsu/Qu/o=
+github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus v1.1.0/go.mod h1:hM2alZsMUni80N33RBe6J0e423LB+odMj7d3EMP9l20=
+github.com/grpc-ecosystem/go-grpc-middleware/v2 v2.3.3 h1:B+8ClL/kCQkRiU82d9xajRPKYMrB7E0MbtzWVi1K4ns=
+github.com/grpc-ecosystem/go-grpc-middleware/v2 v2.3.3/go.mod h1:NbCUVmiS4foBGBHOYlCT25+YmGpJ32dZPi75pGEUpj4=
+github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.7 h1:X+2YciYSxvMQK0UZ7sg45ZVabVZBeBuvMkmuI2V3Fak=
+github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.7/go.mod h1:lW34nIZuQ8UDPdkon5fmfp2l3+ZkQ2me/+oecHYLOII=
github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4=
github.com/hashicorp/errwrap v1.1.0 h1:OxrOeh75EUXMY8TBjag2fzXGZ40LB6IKw45YeGUDY2I=
github.com/hashicorp/errwrap v1.1.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4=
@@ -223,7 +237,6 @@ github.com/jmhodges/clock v1.2.0/go.mod h1:qKjhA7x7u/lQpPB1XAqX1b1lCI/w3/fNuYpI/
github.com/joho/godotenv v1.3.0/go.mod h1:7hK45KPybAkOC6peb+G5yklZfMxEjkZhHbwpqxOKXbg=
github.com/jonboulle/clockwork v0.5.0 h1:Hyh9A8u51kptdkR+cqRpT1EebBwTn1oK9YfGYbdFz6I=
github.com/jonboulle/clockwork v0.5.0/go.mod h1:3mZlmanh0g2NDKO5TWZVJAfofYk64M7XN3SzBPjZF60=
-github.com/josharian/intern v1.0.0 h1:vlS4z54oSdjm0bgjRigI+G1HpF+tI+9rE5LLzOg8HmY=
github.com/josharian/intern v1.0.0/go.mod h1:5DoeVV0s6jJacbCEi61lwdGj/aVlrQvzHFFd8Hwg//Y=
github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnrnM=
github.com/json-iterator/go v1.1.12/go.mod h1:e30LSqwooZae/UwlEbR2852Gd8hjQvJoHmT4TnhNGBo=
@@ -254,11 +267,9 @@ github.com/letsencrypt/boulder v0.0.0-20230907030200-6d76a0f91e1e/go.mod h1:EAuq
github.com/mailru/easyjson v0.0.0-20190614124828-94de47d64c63/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc=
github.com/mailru/easyjson v0.0.0-20190626092158-b2ccc519800e/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc=
github.com/mailru/easyjson v0.7.6/go.mod h1:xzfreul335JAWq5oZzymOObrkdz5UnU4kGfJJLY9Nlc=
-github.com/mailru/easyjson v0.7.7 h1:UGYAvKxe3sBsEDzO8ZeWOSlIQfWFlxbzLZe7hwFURr0=
github.com/mailru/easyjson v0.7.7/go.mod h1:xzfreul335JAWq5oZzymOObrkdz5UnU4kGfJJLY9Nlc=
github.com/markbates/oncer v0.0.0-20181203154359-bf2de49a0be2/go.mod h1:Ld9puTsIW75CHf65OeIOkyKbteujpZVXDpWK6YGZbxE=
github.com/markbates/safe v1.0.1/go.mod h1:nAqgmRi7cY2nqMc92/bSEeQA+R4OheNU2T1kNSCBdG0=
-github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0=
github.com/mitchellh/mapstructure v1.3.3/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo=
github.com/mitchellh/mapstructure v1.4.1/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo=
github.com/mitchellh/mapstructure v1.5.0 h1:jeMsZIYE/09sWLaz43PL7Gy6RuMjD2eJVyuac5Z2hdY=
@@ -279,26 +290,24 @@ github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822/go.mod h1:+n7T8m
github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e/go.mod h1:zD1mROLANZcx1PVRCS0qkT7pwLkGfwJo4zjcN/Tysno=
github.com/oklog/ulid v1.3.1 h1:EGfNDEx6MqHz8B3uNV6QAib1UR2Lm97sHi3ocA6ESJ4=
github.com/oklog/ulid v1.3.1/go.mod h1:CirwcVhetQ6Lv90oh/F+FBtV6XMibvdAFo93nm5qn4U=
-github.com/onsi/ginkgo/v2 v2.27.2 h1:LzwLj0b89qtIy6SSASkzlNvX6WktqurSHwkk2ipF/Ns=
-github.com/onsi/ginkgo/v2 v2.27.2/go.mod h1:ArE1D/XhNXBXCBkKOLkbsb2c81dQHCRcF5zwn/ykDRo=
-github.com/onsi/gomega v1.38.2 h1:eZCjf2xjZAqe+LeWvKb5weQ+NcPwX84kqJ0cZNxok2A=
-github.com/onsi/gomega v1.38.2/go.mod h1:W2MJcYxRGV63b418Ai34Ud0hEdTVXq9NW9+Sx6uXf3k=
+github.com/onsi/gomega v1.39.1 h1:1IJLAad4zjPn2PsnhH70V4DKRFlrCzGBNrNaru+Vf28=
+github.com/onsi/gomega v1.39.1/go.mod h1:hL6yVALoTOxeWudERyfppUcZXjMwIMLnuSfruD2lcfg=
github.com/opencontainers/go-digest v1.0.0 h1:apOUWs51W5PlhuyGyz9FCeeBIOUDA/6nW8Oi/yOhh5U=
github.com/opencontainers/go-digest v1.0.0/go.mod h1:0JzlMkj0TRzQZfJkVvzbP0HBR3IKzErnv2BNG4W4MAM=
github.com/opencontainers/image-spec v1.1.1 h1:y0fUlFfIZhPF1W537XOLg0/fcx6zcHCJwooC2xJA040=
github.com/opencontainers/image-spec v1.1.1/go.mod h1:qpqAh3Dmcf36wStyyWU+kCeDgrGnAve2nCC8+7h8Q0M=
-github.com/opencontainers/runtime-spec v1.2.1 h1:S4k4ryNgEpxW1dzyqffOmhI1BHYcjzU8lpJfSlR0xww=
-github.com/opencontainers/runtime-spec v1.2.1/go.mod h1:jwyrGlmzljRJv/Fgzds9SsS/C5hL+LL3ko9hs6T5lQ0=
+github.com/opencontainers/runtime-spec v1.3.0 h1:YZupQUdctfhpZy3TM39nN9Ika5CBWT5diQ8ibYCRkxg=
+github.com/opencontainers/runtime-spec v1.3.0/go.mod h1:jwyrGlmzljRJv/Fgzds9SsS/C5hL+LL3ko9hs6T5lQ0=
github.com/openshift-eng/openshift-tests-extension v0.0.0-20260127124016-0fed2b824818 h1:jJLE/aCAqDf8U4wc3bE1IEKgIxbb0ICjCNVFA49x/8s=
github.com/openshift-eng/openshift-tests-extension v0.0.0-20260127124016-0fed2b824818/go.mod h1:6gkP5f2HL0meusT0Aim8icAspcD1cG055xxBZ9yC68M=
-github.com/openshift/api v0.0.0-20260306105915-ec7ab20aa8c4 h1:WJFsWIK6RgKablY+IXyIeTLPT2ZRHdHXYnG9Eq+9bhM=
-github.com/openshift/api v0.0.0-20260306105915-ec7ab20aa8c4/go.mod h1:pyVjK0nZ4sRs4fuQVQ4rubsJdahI1PB94LnQ8sGdvxo=
-github.com/openshift/build-machinery-go v0.0.0-20251023084048-5d77c1a5e5af h1:UiYYMi/CCV+kwWrXuXfuUSOY2yNXOpWpNVgHc6aLQlE=
-github.com/openshift/build-machinery-go v0.0.0-20251023084048-5d77c1a5e5af/go.mod h1:8jcm8UPtg2mCAsxfqKil1xrmRMI3a+XU2TZ9fF8A7TE=
-github.com/openshift/client-go v0.0.0-20260305174943-67b007d67537 h1:Wz5p/woz9klHVIT6yy8cC4tw95iE3gtWxmfhGCElawQ=
-github.com/openshift/client-go v0.0.0-20260305174943-67b007d67537/go.mod h1:7QeQMJHhEpcMankJSrwuMALpRRM1ADtaFyURHXyPSSQ=
-github.com/openshift/library-go v0.0.0-20260303171201-5d9eb6295ff6 h1:xjqy0OolrFdJ+ofI/aD0+2k9+MSk5anP5dXifFt539Q=
-github.com/openshift/library-go v0.0.0-20260303171201-5d9eb6295ff6/go.mod h1:D797O/ssKTNglbrGchjIguFq+DbyRYdeds5w4/VTrKM=
+github.com/openshift/api v0.0.0-20260813212709-d4bb0b443cb8 h1:SLdLnLLwLeQI5iJNOsRNYfb9mTme1G2FmmM2T7Nly44=
+github.com/openshift/api v0.0.0-20260813212709-d4bb0b443cb8/go.mod h1:k6qH5QOVa5GDln2VVm8Jz4NV3Z7R2SATHFLwGS6Wh3M=
+github.com/openshift/build-machinery-go v0.0.0-20260629141115-154a2b810491 h1:P/vZSEsUuAHMnf89gQ6FKIl9jsbPnNJ3gIBM43xn2Bg=
+github.com/openshift/build-machinery-go v0.0.0-20260629141115-154a2b810491/go.mod h1:8jcm8UPtg2mCAsxfqKil1xrmRMI3a+XU2TZ9fF8A7TE=
+github.com/openshift/client-go v0.0.0-20260810202730-ddca5e0b7146 h1:fX/gaOPiS2vrYGSAFSeqqoWjj32H+NbMmB5RDjwhCnU=
+github.com/openshift/client-go v0.0.0-20260810202730-ddca5e0b7146/go.mod h1:bhbP5y308NNbImrgArOc9611HIDAMcNWdCCO4tq5ob4=
+github.com/openshift/library-go v0.0.0-20260814203017-a0584a625d6d h1:LQ9jGH1GkmNFnFDBHeNLN5fmm/lyTgtzGNqHN1NG/dw=
+github.com/openshift/library-go v0.0.0-20260814203017-a0584a625d6d/go.mod h1:IrZbEK+wVUMEd+aXzYR2DCCh0p5IaQ7DvycYGP7qIYM=
github.com/openshift/runtime-utils v0.0.0-20230921210328-7bdb5b9c177b h1:oXzC1N6E9gw76/WH2gEA8GEHvuq09wuVQ9GoCuR8GF4=
github.com/openshift/runtime-utils v0.0.0-20230921210328-7bdb5b9c177b/go.mod h1:l9/qeKZuAmYUMl0yicJlbkPGDsIycGhwxOvOAWyaP0E=
github.com/orisano/pixelmatch v0.0.0-20220722002657-fb0b55479cde/go.mod h1:nZgzbfBr3hhjoZnS66nKrHmduYNpc34ny7RK4z5/HM0=
@@ -314,19 +323,14 @@ github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 h1:Jamvg5psRI
github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
github.com/proglottis/gpgme v0.1.3 h1:Crxx0oz4LKB3QXc5Ea0J19K/3ICfy3ftr5exgUK1AU0=
github.com/proglottis/gpgme v0.1.3/go.mod h1:fPbW/EZ0LvwQtH8Hy7eixhp1eF3G39dtx7GUN+0Gmy0=
-github.com/prometheus/client_golang v0.9.2/go.mod h1:OsXs2jCmiKlQ1lTBmv21f2mNfw4xf/QclQDMrYNZzcM=
github.com/prometheus/client_golang v1.23.2 h1:Je96obch5RDVy3FDMndoUsjAhG5Edi49h0RJWRi/o0o=
github.com/prometheus/client_golang v1.23.2/go.mod h1:Tb1a6LWHB3/SPIzCoaDXI4I8UHKeFTEQ1YCr+0Gyqmg=
-github.com/prometheus/client_model v0.0.0-20180712105110-5c3871d89910/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo=
-github.com/prometheus/client_model v0.0.0-20190129233127-fd36f4220a90/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA=
github.com/prometheus/client_model v0.6.2 h1:oBsgwpGs7iVziMvrGhE53c/GrLUsZdHnqNwqPLxwZyk=
github.com/prometheus/client_model v0.6.2/go.mod h1:y3m2F6Gdpfy6Ut/GBsUqTWZqCUvMVzSfMLjcu6wAwpE=
-github.com/prometheus/common v0.0.0-20181126121408-4724e9255275/go.mod h1:daVV7qP5qjZbuso7PdcryaAu0sAZbrN9i7WWcTMWvro=
-github.com/prometheus/common v0.66.1 h1:h5E0h5/Y8niHc5DlaLlWLArTQI7tMrsfQjHV+d9ZoGs=
-github.com/prometheus/common v0.66.1/go.mod h1:gcaUsgf3KfRSwHY4dIMXLPV0K/Wg1oZ8+SbZk/HH/dA=
-github.com/prometheus/procfs v0.0.0-20181204211112-1dc9a6cbc91a/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk=
-github.com/prometheus/procfs v0.16.1 h1:hZ15bTNuirocR6u0JZ6BAHHmwS1p8B4P6MRqxtzMyRg=
-github.com/prometheus/procfs v0.16.1/go.mod h1:teAbpZRB1iIAJYREa1LsoWUXykVXA1KlTmWl8x/U+Is=
+github.com/prometheus/common v0.67.5 h1:pIgK94WWlQt1WLwAC5j2ynLaBRDiinoAb86HZHTUGI4=
+github.com/prometheus/common v0.67.5/go.mod h1:SjE/0MzDEEAyrdr5Gqc6G+sXI67maCxzaT3A2+HqjUw=
+github.com/prometheus/procfs v0.19.2 h1:zUMhqEW66Ex7OXIiDkll3tl9a1ZdilUOd/F6ZXw4Vws=
+github.com/prometheus/procfs v0.19.2/go.mod h1:M0aotyiemPhBCM0z5w87kL22CxfcH05ZpYlu+b4J7mw=
github.com/robfig/cron/v3 v3.0.1 h1:WdRxkvbJztn8LMz/QEvLN5sBU+xKpSqwwUO1Pjr4qDs=
github.com/robfig/cron/v3 v3.0.1/go.mod h1:eQICP3HwyT7UooqI/z+Ov+PtYAWygg1TEWWzGIFLtro=
github.com/rogpeppe/go-internal v1.1.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4=
@@ -351,12 +355,12 @@ github.com/sirupsen/logrus v1.9.3/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVs
github.com/soheilhy/cmux v0.1.5 h1:jjzc5WVemNEDTLwv9tlmemhC73tI08BNOIGwBOo10Js=
github.com/soheilhy/cmux v0.1.5/go.mod h1:T7TcVDs9LWfQgPlPsdngu6I6QIoyIFZDDC6sNE1GqG0=
github.com/spf13/cobra v0.0.3/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3XqQ=
-github.com/spf13/cobra v1.10.0 h1:a5/WeUlSDCvV5a45ljW2ZFtV0bTDpkfSAj3uqB6Sc+0=
-github.com/spf13/cobra v1.10.0/go.mod h1:9dhySC7dnTtEiqzmqfkLj47BslqLCUPMXjG2lj/NgoE=
+github.com/spf13/cobra v1.10.2 h1:DMTTonx5m65Ic0GOoRY2c16WCbHxOOw6xxezuLaBpcU=
+github.com/spf13/cobra v1.10.2/go.mod h1:7C1pvHqHw5A4vrJfjNwvOdzYu0Gml16OCs2GRiTUUS4=
github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4=
-github.com/spf13/pflag v1.0.8/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg=
-github.com/spf13/pflag v1.0.9 h1:9exaQaMOCwffKiiiYk6/BndUBv+iRViNW+4lEMi0PvY=
github.com/spf13/pflag v1.0.9/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg=
+github.com/spf13/pflag v1.0.10 h1:4EBh2KAYBwaONj6b2Ye1GiHfwjqyROoF4RwYO+vPwFk=
+github.com/spf13/pflag v1.0.10/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg=
github.com/stoewer/go-strcase v1.3.0 h1:g0eASXYtp+yvN9fK8sH94oCIk0fau9uV1/ZdJ0AVEzs=
github.com/stoewer/go-strcase v1.3.0/go.mod h1:fAH5hQ5pehh+j3nZfvwdk2RgEgQjAoM8wodgtPmh1xo=
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
@@ -405,16 +409,16 @@ github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9de
github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
go.etcd.io/bbolt v1.4.3 h1:dEadXpI6G79deX5prL3QRNP6JB8UxVkqo4UPnHaNXJo=
go.etcd.io/bbolt v1.4.3/go.mod h1:tKQlpPaYCVFctUIgFKFnAlvbmB3tpy1vkTnDWohtc0E=
-go.etcd.io/etcd/api/v3 v3.6.5 h1:pMMc42276sgR1j1raO/Qv3QI9Af/AuyQUW6CBAWuntA=
-go.etcd.io/etcd/api/v3 v3.6.5/go.mod h1:ob0/oWA/UQQlT1BmaEkWQzI0sJ1M0Et0mMpaABxguOQ=
-go.etcd.io/etcd/client/pkg/v3 v3.6.5 h1:Duz9fAzIZFhYWgRjp/FgNq2gO1jId9Yae/rLn3RrBP8=
-go.etcd.io/etcd/client/pkg/v3 v3.6.5/go.mod h1:8Wx3eGRPiy0qOFMZT/hfvdos+DjEaPxdIDiCDUv/FQk=
-go.etcd.io/etcd/client/v3 v3.6.5 h1:yRwZNFBx/35VKHTcLDeO7XVLbCBFbPi+XV4OC3QJf2U=
-go.etcd.io/etcd/client/v3 v3.6.5/go.mod h1:ZqwG/7TAFZ0BJ0jXRPoJjKQJtbFo/9NIY8uoFFKcCyo=
-go.etcd.io/etcd/pkg/v3 v3.6.5 h1:byxWB4AqIKI4SBmquZUG1WGtvMfMaorXFoCcFbVeoxM=
-go.etcd.io/etcd/pkg/v3 v3.6.5/go.mod h1:uqrXrzmMIJDEy5j00bCqhVLzR5jEJIwDp5wTlLwPGOU=
-go.etcd.io/etcd/server/v3 v3.6.5 h1:4RbUb1Bd4y1WkBHmuF+cZII83JNQMuNXzyjwigQ06y0=
-go.etcd.io/etcd/server/v3 v3.6.5/go.mod h1:PLuhyVXz8WWRhzXDsl3A3zv/+aK9e4A9lpQkqawIaH0=
+go.etcd.io/etcd/api/v3 v3.6.8 h1:gqb1VN92TAI6G2FiBvWcqKtHiIjr4SU2GdXxTwyexbM=
+go.etcd.io/etcd/api/v3 v3.6.8/go.mod h1:qyQj1HZPUV3B5cbAL8scG62+fyz5dSxxu0w8pn28N6Q=
+go.etcd.io/etcd/client/pkg/v3 v3.6.8 h1:Qs/5C0LNFiqXxYf2GU8MVjYUEXJ6sZaYOz0zEqQgy50=
+go.etcd.io/etcd/client/pkg/v3 v3.6.8/go.mod h1:GsiTRUZE2318PggZkAo6sWb6l8JLVrnckTNfbG8PWtw=
+go.etcd.io/etcd/client/v3 v3.6.8 h1:B3G76t1UykqAOrbio7s/EPatixQDkQBevN8/mwiplrY=
+go.etcd.io/etcd/client/v3 v3.6.8/go.mod h1:MVG4BpSIuumPi+ELF7wYtySETmoTWBHVcDoHdVupwt8=
+go.etcd.io/etcd/pkg/v3 v3.6.8 h1:Xe+LIL974spy8b4nEx3H0KMr1ofq3r0kh6FbU3aw4es=
+go.etcd.io/etcd/pkg/v3 v3.6.8/go.mod h1:TRibVNe+FqJIe1abOAA1PsuQ4wqO87ZaOoprg09Tn8c=
+go.etcd.io/etcd/server/v3 v3.6.8 h1:U2strdSEy1U8qcSzRIdkYpvOPtBy/9i/IfaaCI9flZ4=
+go.etcd.io/etcd/server/v3 v3.6.8/go.mod h1:88dCtwUnSirkUoJbflQxxWXqtBSZa6lSG0Kuej+dois=
go.etcd.io/raft/v3 v3.6.0 h1:5NtvbDVYpnfZWcIHgGRk9DyzkBIXOi8j+DDp1IcnUWQ=
go.etcd.io/raft/v3 v3.6.0/go.mod h1:nLvLevg6+xrVtHUmVaTcTz603gQPHfh7kUAwV6YpfGo=
go.mongodb.org/mongo-driver v1.7.3/go.mod h1:NqaYOwnXWr5Pm7AOpO5QFxKJ503nbMse/R79oO62zWg=
@@ -422,34 +426,34 @@ go.mongodb.org/mongo-driver v1.7.5/go.mod h1:VXEWRZ6URJIkUq2SCAyapmhH0ZLRBP+FT4x
go.mongodb.org/mongo-driver v1.10.0/go.mod h1:wsihk0Kdgv8Kqu1Anit4sfK+22vSFbUrAVEYRhCXrA8=
go.mongodb.org/mongo-driver v1.14.0 h1:P98w8egYRjYe3XDjxhYJagTokP/H6HzlsnojRgZRd80=
go.mongodb.org/mongo-driver v1.14.0/go.mod h1:Vzb0Mk/pa7e6cWw85R4F/endUC3u0U9jGcNU603k65c=
-go.opentelemetry.io/auto/sdk v1.1.0 h1:cH53jehLUN6UFLY71z+NDOiNJqDdPRaXzTel0sJySYA=
-go.opentelemetry.io/auto/sdk v1.1.0/go.mod h1:3wSPjt5PWp2RhlCcmmOial7AvC4DQqZb7a7wCow3W8A=
-go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.60.0 h1:x7wzEgXfnzJcHDwStJT+mxOz4etr2EcexjqhBvmoakw=
-go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.60.0/go.mod h1:rg+RlpR5dKwaS95IyyZqj5Wd4E13lk/msnTS0Xl9lJM=
-go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.61.0 h1:F7Jx+6hwnZ41NSFTO5q4LYDtJRXBf2PD0rNBkeB/lus=
-go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.61.0/go.mod h1:UHB22Z8QsdRDrnAtX4PntOl36ajSxcdUMt1sF7Y6E7Q=
-go.opentelemetry.io/otel v1.36.0 h1:UumtzIklRBY6cI/lllNZlALOF5nNIzJVb16APdvgTXg=
-go.opentelemetry.io/otel v1.36.0/go.mod h1:/TcFMXYjyRNh8khOAO9ybYkqaDBb/70aVwkNML4pP8E=
-go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.34.0 h1:OeNbIYk/2C15ckl7glBlOBp5+WlYsOElzTNmiPW/x60=
-go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.34.0/go.mod h1:7Bept48yIeqxP2OZ9/AqIpYS94h2or0aB4FypJTc8ZM=
-go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.34.0 h1:tgJ0uaNS4c98WRNUEx5U3aDlrDOI5Rs+1Vifcw4DJ8U=
-go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.34.0/go.mod h1:U7HYyW0zt/a9x5J1Kjs+r1f/d4ZHnYFclhYY2+YbeoE=
-go.opentelemetry.io/otel/metric v1.36.0 h1:MoWPKVhQvJ+eeXWHFBOPoBOi20jh6Iq2CcCREuTYufE=
-go.opentelemetry.io/otel/metric v1.36.0/go.mod h1:zC7Ks+yeyJt4xig9DEw9kuUFe5C3zLbVjV2PzT6qzbs=
-go.opentelemetry.io/otel/sdk v1.36.0 h1:b6SYIuLRs88ztox4EyrvRti80uXIFy+Sqzoh9kFULbs=
-go.opentelemetry.io/otel/sdk v1.36.0/go.mod h1:+lC+mTgD+MUWfjJubi2vvXWcVxyr9rmlshZni72pXeY=
-go.opentelemetry.io/otel/sdk/metric v1.36.0 h1:r0ntwwGosWGaa0CrSt8cuNuTcccMXERFwHX4dThiPis=
-go.opentelemetry.io/otel/sdk/metric v1.36.0/go.mod h1:qTNOhFDfKRwX0yXOqJYegL5WRaW376QbB7P4Pb0qva4=
-go.opentelemetry.io/otel/trace v1.36.0 h1:ahxWNuqZjpdiFAyrIoQ4GIiAIhxAunQR6MUoKrsNd4w=
-go.opentelemetry.io/otel/trace v1.36.0/go.mod h1:gQ+OnDZzrybY4k4seLzPAWNwVBBVlF2szhehOBB/tGA=
-go.opentelemetry.io/proto/otlp v1.5.0 h1:xJvq7gMzB31/d406fB8U5CBdyQGw4P399D1aQWU/3i4=
-go.opentelemetry.io/proto/otlp v1.5.0/go.mod h1:keN8WnHxOy8PG0rQZjJJ5A2ebUoafqWp0eVQ4yIXvJ4=
+go.opentelemetry.io/auto/sdk v1.2.1 h1:jXsnJ4Lmnqd11kwkBV2LgLoFMZKizbCi5fNZ/ipaZ64=
+go.opentelemetry.io/auto/sdk v1.2.1/go.mod h1:KRTj+aOaElaLi+wW1kO/DZRXwkF4C5xPbEe3ZiIhN7Y=
+go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.65.0 h1:XmiuHzgJt067+a6kwyAzkhXooYVv3/TOw9cM2VfJgUM=
+go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.65.0/go.mod h1:KDgtbWKTQs4bM+VPUr6WlL9m/WXcmkCcBlIzqxPGzmI=
+go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.65.0 h1:7iP2uCb7sGddAr30RRS6xjKy7AZ2JtTOPA3oolgVSw8=
+go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.65.0/go.mod h1:c7hN3ddxs/z6q9xwvfLPk+UHlWRQyaeR1LdgfL/66l0=
+go.opentelemetry.io/otel v1.41.0 h1:YlEwVsGAlCvczDILpUXpIpPSL/VPugt7zHThEMLce1c=
+go.opentelemetry.io/otel v1.41.0/go.mod h1:Yt4UwgEKeT05QbLwbyHXEwhnjxNO6D8L5PQP51/46dE=
+go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.40.0 h1:QKdN8ly8zEMrByybbQgv8cWBcdAarwmIPZ6FThrWXJs=
+go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.40.0/go.mod h1:bTdK1nhqF76qiPoCCdyFIV+N/sRHYXYCTQc+3VCi3MI=
+go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.40.0 h1:DvJDOPmSWQHWywQS6lKL+pb8s3gBLOZUtw4N+mavW1I=
+go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.40.0/go.mod h1:EtekO9DEJb4/jRyN4v4Qjc2yA7AtfCBuz2FynRUWTXs=
+go.opentelemetry.io/otel/metric v1.41.0 h1:rFnDcs4gRzBcsO9tS8LCpgR0dxg4aaxWlJxCno7JlTQ=
+go.opentelemetry.io/otel/metric v1.41.0/go.mod h1:xPvCwd9pU0VN8tPZYzDZV/BMj9CM9vs00GuBjeKhJps=
+go.opentelemetry.io/otel/sdk v1.40.0 h1:KHW/jUzgo6wsPh9At46+h4upjtccTmuZCFAc9OJ71f8=
+go.opentelemetry.io/otel/sdk v1.40.0/go.mod h1:Ph7EFdYvxq72Y8Li9q8KebuYUr2KoeyHx0DRMKrYBUE=
+go.opentelemetry.io/otel/sdk/metric v1.40.0 h1:mtmdVqgQkeRxHgRv4qhyJduP3fYJRMX4AtAlbuWdCYw=
+go.opentelemetry.io/otel/sdk/metric v1.40.0/go.mod h1:4Z2bGMf0KSK3uRjlczMOeMhKU2rhUqdWNoKcYrtcBPg=
+go.opentelemetry.io/otel/trace v1.41.0 h1:Vbk2co6bhj8L59ZJ6/xFTskY+tGAbOnCtQGVVa9TIN0=
+go.opentelemetry.io/otel/trace v1.41.0/go.mod h1:U1NU4ULCoxeDKc09yCWdWe+3QoyweJcISEVa1RBzOis=
+go.opentelemetry.io/proto/otlp v1.9.0 h1:l706jCMITVouPOqEnii2fIAuO3IVGBRPV5ICjceRb/A=
+go.opentelemetry.io/proto/otlp v1.9.0/go.mod h1:xE+Cx5E/eEHw+ISFkwPLwCZefwVjY+pqKg1qcK03+/4=
go.uber.org/goleak v1.3.0 h1:2K3zAYmnTNqV73imy9J1T3WC+gmCePx2hEGkimedGto=
go.uber.org/goleak v1.3.0/go.mod h1:CoHD4mav9JJNrW/WLlf7HGZPjdw8EucARQHekz1X6bE=
go.uber.org/multierr v1.11.0 h1:blXXJkSxSSfBVBlC76pxqeO+LN3aDfLQo+309xJstO0=
go.uber.org/multierr v1.11.0/go.mod h1:20+QtiLqy0Nd6FdQB9TLXag12DsQkrbs3htMFfDN80Y=
-go.uber.org/zap v1.27.0 h1:aJMhYGrd5QSmlpLMr2MftRKl7t8J8PTZPA732ud/XR8=
-go.uber.org/zap v1.27.0/go.mod h1:GB2qFLM7cTU87MWRP2mPIjqfIDnGu+VIO4V/SdhGo2E=
+go.uber.org/zap v1.27.1 h1:08RqriUEv8+ArZRYSTXy1LeBScaMpVSTBhCeaZYfMYc=
+go.uber.org/zap v1.27.1/go.mod h1:GB2qFLM7cTU87MWRP2mPIjqfIDnGu+VIO4V/SdhGo2E=
go.yaml.in/yaml/v2 v2.4.3 h1:6gvOSjQoTB3vt1l+CU+tSyi/HOjfOjRLJ4YwYZGwRO0=
go.yaml.in/yaml/v2 v2.4.3/go.mod h1:zSxWcmIDjOzPXpjlTTbAsKokqkDNAVtZO0WOMiT90s8=
go.yaml.in/yaml/v3 v3.0.4 h1:tfq32ie2Jv2UxXFdLJdh3jXuOzWiL1fo0bu/FbuKpbc=
@@ -461,18 +465,12 @@ golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8U
golang.org/x/crypto v0.0.0-20200302210943-78000ba7a073/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4=
-golang.org/x/crypto v0.45.0 h1:jMBrvKuj23MTlT0bQEOBcAE0mjg8mK9RXFhRH6nyF3Q=
-golang.org/x/crypto v0.45.0/go.mod h1:XTGrrkGJve7CYK7J8PEww4aY7gM3qMCElcJQ8n8JdX4=
-golang.org/x/exp v0.0.0-20240719175910-8a7402abbf56 h1:2dVuKD2vS7b0QIHQbpyTISPd0LeHDbnYEryqj5Q1ug8=
-golang.org/x/exp v0.0.0-20240719175910-8a7402abbf56/go.mod h1:M4RDyNAINzryxdtnbRXRL/OHtkFuWGRjvuhBJpk2IlY=
-golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE=
+golang.org/x/crypto v0.53.0 h1:QZ4Muo8THX6CizN2vPPd5fBGHyogrdK9fG4wLPFUsto=
+golang.org/x/crypto v0.53.0/go.mod h1:DNLU434OwVakk9PzuwV8w62mAJpRJL3vsgcfp4Qnsio=
+golang.org/x/exp v0.0.0-20251219203646-944ab1f22d93 h1:fQsdNF2N+/YewlRZiricy4P1iimyPKZ/xwniHj8Q2a0=
+golang.org/x/exp v0.0.0-20251219203646-944ab1f22d93/go.mod h1:EPRbTFwzwjXj9NpYyyrvenVh9Y+GFeEvMNh7Xuz7xgU=
golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
-golang.org/x/mod v0.29.0 h1:HV8lRxZC4l2cr3Zq1LvtOsi/ThTgWnUk/y64QSs8GwA=
-golang.org/x/mod v0.29.0/go.mod h1:NyhrlYXJ2H4eJiRy/WDBO6HMqZQ6q9nk4JzS3NuCK+w=
-golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
-golang.org/x/net v0.0.0-20181201002055-351d144fa1fc/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
-golang.org/x/net v0.0.0-20190213061140-3a22650c66bd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
@@ -480,22 +478,18 @@ golang.org/x/net v0.0.0-20200226121028-0de0cce0169b/go.mod h1:z5CRVTTTmAJ677TzLL
golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU=
golang.org/x/net v0.0.0-20210421230115-4e50805a0758/go.mod h1:72T/g9IO56b78aLF+1Kcs5dz7/ng1VjMUvfKvpfy+jM=
golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
-golang.org/x/net v0.47.0 h1:Mx+4dIFzqraBXUugkia1OOvlD6LemFo1ALMHjrXDOhY=
-golang.org/x/net v0.47.0/go.mod h1:/jNxtkgq5yWUGYkaZGqo27cfGZ1c5Nen03aYrrKpVRU=
-golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U=
-golang.org/x/oauth2 v0.30.0 h1:dnDm7JmhM45NNpd8FDDeLhK6FwqbOf4MLCM9zb1BOHI=
-golang.org/x/oauth2 v0.30.0/go.mod h1:B++QgG3ZKulg6sRPGD/mqlHQs5rB3Ml9erfeDY7xKlU=
-golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
-golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
+golang.org/x/net v0.56.0 h1:Rw8j/hFzGvJUZwNBXnAtf5sVDVt+65SK2C7IxCxZt5o=
+golang.org/x/net v0.56.0/go.mod h1:D3Ku6r+V6JROoZK144D2XfMHFcMq/0zSfLelVTCFKec=
+golang.org/x/oauth2 v0.34.0 h1:hqK/t4AKgbqWkdkcAeI8XLmbK+4m4G5YeQRrmiotGlw=
+golang.org/x/oauth2 v0.34.0/go.mod h1:lzm5WQJQwKZ3nwavOZ3IS5Aulzxi68dUSgRHujetwEA=
golang.org/x/sync v0.0.0-20190227155943-e225da77a7e6/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
golang.org/x/sync v0.0.0-20190412183630-56d357773e84/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
-golang.org/x/sync v0.18.0 h1:kr88TuHDroi+UVf+0hZnirlk8o8T+4MrK6mr60WkH/I=
-golang.org/x/sync v0.18.0/go.mod h1:9KTHXmSnoGruLpwFjVSX0lNNA75CykiMECbovNTZqGI=
-golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
+golang.org/x/sync v0.21.0 h1:HLII4xRRTtCRkxYp4HNFF0Js/Og6q2i++KXbg0gHCwM=
+golang.org/x/sync v0.21.0/go.mod h1:9xrNwdLfx4jkKbNva9FpL6vEN7evnE43NNNJQ2LF3+0=
golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/sys v0.0.0-20190403152447-81d4e9dc473e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
@@ -512,21 +506,20 @@ golang.org/x/sys v0.0.0-20211007075335-d3039528d8ac/go.mod h1:oPkhp1MJrh7nUepCBc
golang.org/x/sys v0.0.0-20220310020820-b874c991c1a5/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
-golang.org/x/sys v0.38.0 h1:3yZWxaJjBmCWXqhN1qh02AkOnCQ1poK6oF+a7xWL6Gc=
-golang.org/x/sys v0.38.0/go.mod h1:OgkHotnGiDImocRcuBABYBEXf8A9a87e/uXjp9XT3ks=
+golang.org/x/sys v0.46.0 h1:noSf2Fq6F8DBgS+LysIkx7rIExoNHJsxOAtPp4rthXw=
+golang.org/x/sys v0.46.0/go.mod h1:4GL1E5IUh+htKOUEOaiffhrAeqysfVGipDYzABqnCmw=
golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
-golang.org/x/term v0.37.0 h1:8EGAD0qCmHYZg6J17DvsMy9/wJ7/D/4pV/wfnld5lTU=
-golang.org/x/term v0.37.0/go.mod h1:5pB4lxRNYYVZuTLmy8oR2BH8dflOR+IbTYFD8fi3254=
+golang.org/x/term v0.44.0 h1:0rLvDRCtNj0gZkyIXhCyOb2OAzEhLVqc4B+hrsBhrmc=
+golang.org/x/term v0.44.0/go.mod h1:7ze4MdzUzLXpSAoFP1H0bOI9aXDqveSvatT5vKcFh2Y=
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
golang.org/x/text v0.3.5/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ=
-golang.org/x/text v0.31.0 h1:aC8ghyu4JhP8VojJ2lEHBnochRno1sgL6nEi9WGFGMM=
-golang.org/x/text v0.31.0/go.mod h1:tKRAlv61yKIjGGHX/4tP1LTbc13YSec1pxVEWXzfoeM=
-golang.org/x/time v0.9.0 h1:EsRrnYcQiGH+5FfbgvV4AP7qEZstoyrHB0DzarOQ4ZY=
-golang.org/x/time v0.9.0/go.mod h1:3BpzKBy/shNhVucY/MWOyx10tF3SFh9QdLuxbVysPQM=
-golang.org/x/tools v0.0.0-20180828015842-6cd1fcedba52/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
+golang.org/x/text v0.39.0 h1:UbZz4pLOvn600D6Oh6GGEI6VAmndrEBLv8/6BEXzyus=
+golang.org/x/text v0.39.0/go.mod h1:3UwRclnC2g0TU9x8PZiyfOajCd1zaUNHF9cvqcQZ+ZM=
+golang.org/x/time v0.15.0 h1:bbrp8t3bGUeFOx08pvsMYRTCVSMk89u4tKbNOZbp88U=
+golang.org/x/time v0.15.0/go.mod h1:Y4YMaQmXwGQZoFaVFk4YpCt4FLQMYKZe9oeV/f4MSno=
golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
golang.org/x/tools v0.0.0-20190329151228-23e29df326fe/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs=
golang.org/x/tools v0.0.0-20190416151739-9c9e1878f421/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs=
@@ -535,23 +528,20 @@ golang.org/x/tools v0.0.0-20190531172133-b3315ee88b7d/go.mod h1:/rFqwRUd4F7ZHNgw
golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
golang.org/x/tools v0.0.0-20200619180055-7c47624df98f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE=
golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
-golang.org/x/tools v0.38.0 h1:Hx2Xv8hISq8Lm16jvBZ2VQf+RLmbd7wVUsALibYI/IQ=
-golang.org/x/tools v0.38.0/go.mod h1:yEsQ/d/YK8cjh0L6rZlY8tgtlKiBNTL14pGDJPJpYQs=
golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
-google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM=
-google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc=
-google.golang.org/genproto/googleapis/api v0.0.0-20250303144028-a0af3efb3deb h1:p31xT4yrYrSM/G4Sn2+TNUkVhFCbG9y8itM2S6Th950=
-google.golang.org/genproto/googleapis/api v0.0.0-20250303144028-a0af3efb3deb/go.mod h1:jbe3Bkdp+Dh2IrslsFCklNhweNTBgSYanP1UXhJDhKg=
-google.golang.org/genproto/googleapis/rpc v0.0.0-20250528174236-200df99c418a h1:v2PbRU4K3llS09c7zodFpNePeamkAwG3mPrAery9VeE=
-google.golang.org/genproto/googleapis/rpc v0.0.0-20250528174236-200df99c418a/go.mod h1:qQ0YXyHHx3XkvlzUtpXDkS29lDSafHMZBAZDc03LQ3A=
-google.golang.org/grpc v1.18.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs=
-google.golang.org/grpc v1.72.2 h1:TdbGzwb82ty4OusHWepvFWGLgIbNo1/SUynEN0ssqv8=
-google.golang.org/grpc v1.72.2/go.mod h1:wH5Aktxcg25y1I3w7H69nHfXdOG3UiadoBtjh3izSDM=
-google.golang.org/protobuf v1.36.8 h1:xHScyCOEuuwZEc6UtSOvPbAT4zRh0xcNRYekJwfqyMc=
-google.golang.org/protobuf v1.36.8/go.mod h1:fuxRtAxBytpl4zzqUh6/eyUujkJdNiuEkXntxiD/uRU=
+gonum.org/v1/gonum v0.16.0 h1:5+ul4Swaf3ESvrOnidPp4GZbzf0mxVQpDCYUQE7OJfk=
+gonum.org/v1/gonum v0.16.0/go.mod h1:fef3am4MQ93R2HHpKnLk4/Tbh/s0+wqD5nfa6Pnwy4E=
+google.golang.org/genproto/googleapis/api v0.0.0-20260128011058-8636f8732409 h1:merA0rdPeUV3YIIfHHcH4qBkiQAc1nfCKSI7lB4cV2M=
+google.golang.org/genproto/googleapis/api v0.0.0-20260128011058-8636f8732409/go.mod h1:fl8J1IvUjCilwZzQowmw2b7HQB2eAuYBabMXzWurF+I=
+google.golang.org/genproto/googleapis/rpc v0.0.0-20260128011058-8636f8732409 h1:H86B94AW+VfJWDqFeEbBPhEtHzJwJfTbgE2lZa54ZAQ=
+google.golang.org/genproto/googleapis/rpc v0.0.0-20260128011058-8636f8732409/go.mod h1:j9x/tPzZkyxcgEFkiKEEGxfvyumM01BEtsW8xzOahRQ=
+google.golang.org/grpc v1.79.3 h1:sybAEdRIEtvcD68Gx7dmnwjZKlyfuc61Dyo9pGXXkKE=
+google.golang.org/grpc v1.79.3/go.mod h1:KmT0Kjez+0dde/v2j9vzwoAScgEPx/Bw1CYChhHLrHQ=
+google.golang.org/protobuf v1.36.12-0.20260120151049-f2248ac996af h1:+5/Sw3GsDNlEmu7TfklWKPdQ0Ykja5VEmq2i817+jbI=
+google.golang.org/protobuf v1.36.12-0.20260120151049-f2248ac996af/go.mod h1:HTf+CrKn2C3g5S8VImy6tdcUvCska2kB7j23XfzDpco=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
gopkg.in/check.v1 v1.0.0-20200227125254-8fa46927fb4f/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
@@ -576,44 +566,45 @@ gopkg.in/yaml.v3 v3.0.0-20200615113413-eeeca48fe776/go.mod h1:K4uyk7z7BCEPqu6E+C
gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA=
gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
-honnef.co/go/tools v0.0.0-20180728063816-88497007e858/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
-k8s.io/api v0.35.2 h1:tW7mWc2RpxW7HS4CoRXhtYHSzme1PN1UjGHJ1bdrtdw=
-k8s.io/api v0.35.2/go.mod h1:7AJfqGoAZcwSFhOjcGM7WV05QxMMgUaChNfLTXDRE60=
-k8s.io/apiextensions-apiserver v0.35.2 h1:iyStXHoJZsUXPh/nFAsjC29rjJWdSgUmG1XpApE29c0=
-k8s.io/apiextensions-apiserver v0.35.2/go.mod h1:OdyGvcO1FtMDWQ+rRh/Ei3b6X3g2+ZDHd0MSRGeS8rU=
-k8s.io/apimachinery v0.35.2 h1:NqsM/mmZA7sHW02JZ9RTtk3wInRgbVxL8MPfzSANAK8=
-k8s.io/apimachinery v0.35.2/go.mod h1:jQCgFZFR1F4Ik7hvr2g84RTJSZegBc8yHgFWKn//hns=
-k8s.io/apiserver v0.35.2 h1:rb52v0CZGEL0FkhjS+I6jHflAp7fZ4MIaKcEHX7wmDk=
-k8s.io/apiserver v0.35.2/go.mod h1:CROJUAu0tfjZLyYgSeBsBan2T7LUJGh0ucWwTCSSk7g=
-k8s.io/client-go v0.35.2 h1:YUfPefdGJA4aljDdayAXkc98DnPkIetMl4PrKX97W9o=
-k8s.io/client-go v0.35.2/go.mod h1:4QqEwh4oQpeK8AaefZ0jwTFJw/9kIjdQi0jpKeYvz7g=
-k8s.io/component-base v0.35.2 h1:btgR+qNrpWuRSuvWSnQYsZy88yf5gVwemvz0yw79pGc=
-k8s.io/component-base v0.35.2/go.mod h1:B1iBJjooe6xIJYUucAxb26RwhAjzx0gHnqO9htWIX+0=
-k8s.io/component-helpers v0.35.2 h1:7Ea4CDgHnyOGrl3ZhD8e46SdTyf1itTONnreJ2Q52UM=
-k8s.io/component-helpers v0.35.2/go.mod h1:ybIoc8i92FG7xJFrBcEMzB8ul1wlZgfF0I4Z9w0V6VQ=
-k8s.io/controller-manager v0.35.2 h1:EpLIwm4bBgoFwXiVULgNxtpUF9cbXUkcGkZ6vUlurYQ=
-k8s.io/controller-manager v0.35.2/go.mod h1:CknUpFd1A0S9h+J9eQZXvZt05ssXMnsYCCLRghm/gp4=
-k8s.io/dynamic-resource-allocation v0.35.2 h1:CSfEHQrDifXk2/KAzr8MVWlDs6wY/7A+C/lGQoKrOec=
-k8s.io/dynamic-resource-allocation v0.35.2/go.mod h1:5XCJwTZgZiSyFxbqFyUpMsCtHT4UONn/SiDfI9kXlH0=
-k8s.io/klog/v2 v2.130.1 h1:n9Xl7H1Xvksem4KFG4PYbdQCQxqc/tTUyrgXaOhHSzk=
-k8s.io/klog/v2 v2.130.1/go.mod h1:3Jpz1GvMt720eyJH1ckRHK1EDfpxISzJ7I9OYgaDtPE=
-k8s.io/kms v0.35.2 h1:XPlj7QmLBfzm8gGQnc3+Y95hZLiJs3DjA0IyFOV5Z7g=
-k8s.io/kms v0.35.2/go.mod h1:VT+4ekZAdrZDMgShK37vvlyHUVhwI9t/9tvh0AyCWmQ=
-k8s.io/kube-openapi v0.0.0-20250910181357-589584f1c912 h1:Y3gxNAuB0OBLImH611+UDZcmKS3g6CthxToOb37KgwE=
-k8s.io/kube-openapi v0.0.0-20250910181357-589584f1c912/go.mod h1:kdmbQkyfwUagLfXIad1y2TdrjPFWp2Q89B3qkRwf/pQ=
-k8s.io/kubelet v0.35.2 h1:qF9jOe1j6vT4bVQZ6nnTTA5uu5NCnyR10o9IkW8Z0JQ=
-k8s.io/kubelet v0.35.2/go.mod h1:2pyCVLDfm7ErNwWZw2mutCloAXX76gfOToIMCHCq/8s=
-k8s.io/kubernetes v1.35.2 h1:2HthVDfK3YJYv624imuKXPzUJ17xQop9OT5dgT+IMKE=
-k8s.io/kubernetes v1.35.2/go.mod h1:AaPpCpiS8oAqRbEwpY5r3RitLpwpVp5lVXKFkJril58=
-k8s.io/utils v0.0.0-20251002143259-bc988d571ff4 h1:SjGebBtkBqHFOli+05xYbK8YF1Dzkbzn+gDM4X9T4Ck=
-k8s.io/utils v0.0.0-20251002143259-bc988d571ff4/go.mod h1:OLgZIPagt7ERELqWJFomSt595RzquPNLL48iOWgYOg0=
-sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.31.2 h1:jpcvIRr3GLoUoEKRkHKSmGjxb6lWwrBlJsXc+eUYQHM=
-sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.31.2/go.mod h1:Ve9uj1L+deCXFrPOk1LpFXqTg7LCFzFso6PA48q/XZw=
+k8s.io/api v0.36.3 h1:NxB+05W2UGqXWFXcLO0RB5cnqnUPP5v5sVlaOH0Iz4w=
+k8s.io/api v0.36.3/go.mod h1:JzLQKqRHC5+I8RVj/lS3lCg0mg6nWI9Fo/Sk3ElxHzg=
+k8s.io/apiextensions-apiserver v0.36.3 h1:dPmOAPhwTtqb1bTxbFPsy18KHPhktQeO3WUPXunZIB0=
+k8s.io/apiextensions-apiserver v0.36.3/go.mod h1:KTXFqgXiuw2pRoL+Wpmttqc+up9Xt/GohadPWeLLOa4=
+k8s.io/apimachinery v0.36.3 h1:PkzMRBRG8joFD8EhCuQAtNPvJlxb82FwplP26HIzvAM=
+k8s.io/apimachinery v0.36.3/go.mod h1:cTSjBWgPe/6CQyBKzY/hDIRWCQQQeK0mfLbml0UYFHE=
+k8s.io/apiserver v0.36.3 h1:MGSg2SkdfuytiDEcRylT5mQFmmSsbx90XFUO67Y4bsQ=
+k8s.io/apiserver v0.36.3/go.mod h1:fVH7zv9EUNUA7Fl7LtDKh8aB9W7u1VQPSGtWV5SjUxg=
+k8s.io/client-go v0.0.0-20260808041404-a92355f83186 h1:jSfugZ+Pgyu357FAEclN8k9sfX3Ye0Qf0qa4XTO5A1E=
+k8s.io/client-go v0.0.0-20260808041404-a92355f83186/go.mod h1:o149Nle6LiwCPJnCLW9eKDgyeXuKCPZ56nDetmnHnOc=
+k8s.io/component-base v0.36.3 h1:vc/UFvPCkW0irPz84LAodAL1j3f4xktPM6dDJIEheAY=
+k8s.io/component-base v0.36.3/go.mod h1:hZbNFG+gCMl9EbykDGEu73feKP9/Cq6JsV4pTo9GTO8=
+k8s.io/component-helpers v0.36.3 h1:hya22S0Mto0SlHaiD4kMIi817f/tK7uTMsShxrDKQaY=
+k8s.io/component-helpers v0.36.3/go.mod h1:QjREK1lOFXR+jxTqzrtHgOtzUc2s9sm8zuFSiK+TW+c=
+k8s.io/controller-manager v0.36.3 h1:GUP9E6+1EUEzxZgceOw2I+jyuahrTluadj6ZoZ/1Sbw=
+k8s.io/controller-manager v0.36.3/go.mod h1:zrjaNqXRz4vfK5TdOQZEfOiTofcyIKrt/Y+jKdwqLa4=
+k8s.io/dynamic-resource-allocation v0.36.3 h1:5cDyWiGhqJMrp8UwdgAqHcDkZHQ7wFhIK4aTr3OgFrI=
+k8s.io/dynamic-resource-allocation v0.36.3/go.mod h1:jt+LtmnMqIqV7lG4PznEtuhPy+fHipfAD0Q+biKszAg=
+k8s.io/klog/v2 v2.140.0 h1:Tf+J3AH7xnUzZyVVXhTgGhEKnFqye14aadWv7bzXdzc=
+k8s.io/klog/v2 v2.140.0/go.mod h1:o+/RWfJ6PwpnFn7OyAG3QnO47BFsymfEfrz6XyYSSp0=
+k8s.io/kms v0.36.3 h1:uHY7Vfec0IhuTWjO6u/u/6hE1DcZmCB7Xm/6+GQxkNs=
+k8s.io/kms v0.36.3/go.mod h1:g91diTD9h0oJCCHkTb00krlF+Qm5HTnkWLi9Q/TpRoc=
+k8s.io/kube-openapi v0.0.0-20260519202549-bbf5c5577288 h1:A7Lby6ekC6nv+6oO38huCMFBRP0Os+tIeq1GkwxOQes=
+k8s.io/kube-openapi v0.0.0-20260519202549-bbf5c5577288/go.mod h1:V/QaCUYDa+0QpcHhVVc5l99Uz56wEMEXBSj9oCDkNDY=
+k8s.io/kubelet v0.36.3 h1:dRzEnhHk35Opy6wjWR4YBcN5RI9lB2npUY37TghFuPU=
+k8s.io/kubelet v0.36.3/go.mod h1:4USFGr21Ioka+b964Beq0NvV5b5aca3RWJ1/kfq+RLw=
+k8s.io/kubernetes v1.36.3 h1:qDQdoMiluAE2Eab6Fa52YV+WjiGz9mZFFoagEA6cI+o=
+k8s.io/kubernetes v1.36.3/go.mod h1:6oChkQeI7Yf6lV9lFpSdRzODdbY/ECp/4zUeBk8ONaw=
+k8s.io/streaming v0.36.3 h1:9rAaqBk0C0Pc7+/fqGekj07NV+/Xrew58p647A0JT8w=
+k8s.io/streaming v0.36.3/go.mod h1:z6fV3D+NVkoeqRMtWwlUZK6U17SY/LqNzOxWL6GyR/s=
+k8s.io/utils v0.0.0-20260707023825-cf1189d6abe3 h1:jVkFFVfXdXP74B/zbO3hM3hpSFD0xvhQ5U686DPurkE=
+k8s.io/utils v0.0.0-20260707023825-cf1189d6abe3/go.mod h1:M2s5JB1lIYP3jzZdorPLHXIPJzt9vv2muW5a6L9DtNM=
+sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.34.0 h1:hSfpvjjTQXQY2Fol2CS0QHMNs/WI1MOSGzCm1KhM5ec=
+sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.34.0/go.mod h1:Ve9uj1L+deCXFrPOk1LpFXqTg7LCFzFso6PA48q/XZw=
sigs.k8s.io/json v0.0.0-20250730193827-2d320260d730 h1:IpInykpT6ceI+QxKBbEflcR5EXP7sU1kvOlxwZh5txg=
sigs.k8s.io/json v0.0.0-20250730193827-2d320260d730/go.mod h1:mdzfpAEoE6DHQEN0uh9ZbOCuHbLK5wOm7dK4ctXE9Tg=
sigs.k8s.io/randfill v1.0.0 h1:JfjMILfT8A6RbawdsK2JXGBR5AQVfd+9TbzrlneTyrU=
sigs.k8s.io/randfill v1.0.0/go.mod h1:XeLlZ/jmk4i1HRopwe7/aU3H5n1zNUcX6TM94b3QxOY=
-sigs.k8s.io/structured-merge-diff/v6 v6.3.0 h1:jTijUJbW353oVOd9oTlifJqOGEkUw2jB/fXCbTiQEco=
-sigs.k8s.io/structured-merge-diff/v6 v6.3.0/go.mod h1:M3W8sfWvn2HhQDIbGWj3S099YozAsymCo/wrT5ohRUE=
+sigs.k8s.io/structured-merge-diff/v6 v6.3.3 h1:u08YRbVUi59ri4YD6cg0UqNM4Dimn0sIl+wldcx5PYw=
+sigs.k8s.io/structured-merge-diff/v6 v6.3.3/go.mod h1:M3W8sfWvn2HhQDIbGWj3S099YozAsymCo/wrT5ohRUE=
sigs.k8s.io/yaml v1.6.0 h1:G8fkbMSAFqgEFgh4b1wmtzDnioxFCUgTZhlbj5P9QYs=
sigs.k8s.io/yaml v1.6.0/go.mod h1:796bPqUfzR/0jLAl6XjHl3Ck7MiyVv8dbTdyT3/pMf4=
diff --git a/pkg/apps/deployer/deployer_controller.go b/pkg/apps/deployer/deployer_controller.go
index 2d4c443438..31b5c024a3 100755
--- a/pkg/apps/deployer/deployer_controller.go
+++ b/pkg/apps/deployer/deployer_controller.go
@@ -569,9 +569,9 @@ func (c *DeploymentController) cleanupDeployerPods(deployment *corev1.Replicatio
func (c *DeploymentController) emitDeploymentEvent(deployment *corev1.ReplicationController, eventType, title, message string) {
if config, _ := appsserialization.DecodeDeploymentConfig(deployment); config != nil {
- c.recorder.Eventf(config, eventType, title, message)
+ c.recorder.Eventf(config, eventType, title, "%s", message)
} else {
- c.recorder.Eventf(deployment, eventType, title, message)
+ c.recorder.Eventf(deployment, eventType, title, "%s", message)
}
}
diff --git a/pkg/apps/deployer/deployer_controller_test.go b/pkg/apps/deployer/deployer_controller_test.go
index b48e4a9e4f..e79171f745 100644
--- a/pkg/apps/deployer/deployer_controller_test.go
+++ b/pkg/apps/deployer/deployer_controller_test.go
@@ -1200,8 +1200,8 @@ func TestMakeDeployerPod(t *testing.T) {
p.Spec.Resources = nil
// k8s 1.34
p.Spec.HostnameOverride = nil
- // k8s 1.35
- p.Spec.WorkloadRef = nil
+ // k8s 1.36
+ p.Spec.SchedulingGroup = nil
},
)
inputPodTemplate := &corev1.PodTemplateSpec{}
diff --git a/pkg/apps/deploymentconfig/deploymentconfig_controller.go b/pkg/apps/deploymentconfig/deploymentconfig_controller.go
index beb3a36793..481c537b8e 100644
--- a/pkg/apps/deploymentconfig/deploymentconfig_controller.go
+++ b/pkg/apps/deploymentconfig/deploymentconfig_controller.go
@@ -226,7 +226,7 @@ func (c *DeploymentConfigController) Handle(config *appsv1.DeploymentConfig) err
return fmt.Errorf("couldn't create deployment for deployment config %s: %v", appsutil.LabelForDeploymentConfig(config), err)
}
msg := fmt.Sprintf("Created new replication controller %q for version %d", created.Name, config.Status.LatestVersion)
- c.recorder.Eventf(config, v1.EventTypeNormal, "DeploymentCreated", msg)
+ c.recorder.Eventf(config, v1.EventTypeNormal, "DeploymentCreated", "%s", msg)
// As we've just created a new deployment, we need to make sure to clean
// up old deployments if we have reached our deployment history quota
diff --git a/pkg/build/controller/build/build_controller.go b/pkg/build/controller/build/build_controller.go
index 590e22b217..578b6ee20b 100644
--- a/pkg/build/controller/build/build_controller.go
+++ b/pkg/build/controller/build/build_controller.go
@@ -1569,18 +1569,18 @@ func (bc *BuildController) updateBuild(build *buildv1.Build, update *buildUpdate
switch *update.phase {
case buildv1.BuildPhaseRunning:
bc.recorder.Eventf(patchedBuild, corev1.EventTypeNormal, buildutil.BuildStartedEventReason,
- fmt.Sprintf(buildutil.BuildStartedEventMessage,
- patchedBuild.Namespace, patchedBuild.Name))
+ buildutil.BuildStartedEventMessage,
+ patchedBuild.Namespace, patchedBuild.Name)
case buildv1.BuildPhaseCancelled:
bc.recorder.Eventf(patchedBuild, corev1.EventTypeNormal, buildutil.BuildCancelledEventReason,
- fmt.Sprintf(buildutil.BuildCancelledEventMessage, patchedBuild.Namespace, patchedBuild.Name))
+ buildutil.BuildCancelledEventMessage, patchedBuild.Namespace, patchedBuild.Name)
case buildv1.BuildPhaseComplete:
bc.recorder.Eventf(patchedBuild, corev1.EventTypeNormal, buildutil.BuildCompletedEventReason,
- fmt.Sprintf(buildutil.BuildCompletedEventMessage, patchedBuild.Namespace, patchedBuild.Name))
+ buildutil.BuildCompletedEventMessage, patchedBuild.Namespace, patchedBuild.Name)
case buildv1.BuildPhaseError,
buildv1.BuildPhaseFailed:
- bc.recorder.Eventf(patchedBuild, corev1.EventTypeNormal, buildutil.BuildFailedEventReason, fmt.Sprintf(buildutil.BuildFailedEventMessage,
- patchedBuild.Namespace, patchedBuild.Name))
+ bc.recorder.Eventf(patchedBuild, corev1.EventTypeNormal, buildutil.BuildFailedEventReason, buildutil.BuildFailedEventMessage,
+ patchedBuild.Namespace, patchedBuild.Name)
}
if buildutil.IsTerminalPhase(*update.phase) {
bc.handleBuildCompletion(patchedBuild)
diff --git a/pkg/template/controller/templateinstance_finalizer.go b/pkg/template/controller/templateinstance_finalizer.go
index 280b7d300c..a89dacb170 100644
--- a/pkg/template/controller/templateinstance_finalizer.go
+++ b/pkg/template/controller/templateinstance_finalizer.go
@@ -156,7 +156,7 @@ func (c *TemplateInstanceFinalizerController) sync(key string) error {
}
if len(errs) > 0 {
err = kerrs.NewAggregate(errs)
- c.recorder.Eventf(templateInstance, "FinalizerError", "DeletionFailure", err.Error())
+ c.recorder.Eventf(templateInstance, corev1.EventTypeWarning, "DeletionFailure", "%s", err.Error())
return err
}
diff --git a/vendor/cel.dev/expr/BUILD.bazel b/vendor/cel.dev/expr/BUILD.bazel
index 37d8adc950..f5bda3bb17 100644
--- a/vendor/cel.dev/expr/BUILD.bazel
+++ b/vendor/cel.dev/expr/BUILD.bazel
@@ -16,7 +16,6 @@ go_library(
importpath = "cel.dev/expr",
visibility = ["//visibility:public"],
deps = [
- "@org_golang_google_genproto_googleapis_rpc//status:go_default_library",
"@org_golang_google_protobuf//reflect/protoreflect",
"@org_golang_google_protobuf//runtime/protoimpl",
"@org_golang_google_protobuf//types/known/anypb",
diff --git a/vendor/cel.dev/expr/MODULE.bazel b/vendor/cel.dev/expr/MODULE.bazel
index 85ac9ff617..cb98ed5991 100644
--- a/vendor/cel.dev/expr/MODULE.bazel
+++ b/vendor/cel.dev/expr/MODULE.bazel
@@ -11,26 +11,9 @@ bazel_dep(
version = "0.39.1",
repo_name = "bazel_gazelle",
)
-bazel_dep(
- name = "googleapis",
- version = "0.0.0-20241220-5e258e33.bcr.1",
- repo_name = "com_google_googleapis",
-)
-bazel_dep(
- name = "googleapis-cc",
- version = "1.0.0",
-)
-bazel_dep(
- name = "googleapis-java",
- version = "1.0.0",
-)
-bazel_dep(
- name = "googleapis-go",
- version = "1.0.0",
-)
bazel_dep(
name = "protobuf",
- version = "27.0",
+ version = "27.1",
repo_name = "com_google_protobuf",
)
bazel_dep(
@@ -63,12 +46,11 @@ python.toolchain(
)
go_sdk = use_extension("@io_bazel_rules_go//go:extensions.bzl", "go_sdk")
-go_sdk.download(version = "1.22.0")
+go_sdk.download(version = "1.23.0")
go_deps = use_extension("@bazel_gazelle//:extensions.bzl", "go_deps")
go_deps.from_file(go_mod = "//:go.mod")
use_repo(
go_deps,
- "org_golang_google_genproto_googleapis_rpc",
"org_golang_google_protobuf",
)
diff --git a/vendor/cel.dev/expr/checked.pb.go b/vendor/cel.dev/expr/checked.pb.go
index bb225c8ab3..b18085e9b6 100644
--- a/vendor/cel.dev/expr/checked.pb.go
+++ b/vendor/cel.dev/expr/checked.pb.go
@@ -1,7 +1,7 @@
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
-// protoc-gen-go v1.28.1
-// protoc v3.21.5
+// protoc-gen-go v1.36.10
+// protoc v5.27.1
// source: cel/expr/checked.proto
package expr
@@ -13,6 +13,7 @@ import (
structpb "google.golang.org/protobuf/types/known/structpb"
reflect "reflect"
sync "sync"
+ unsafe "unsafe"
)
const (
@@ -136,24 +137,21 @@ func (Type_WellKnownType) EnumDescriptor() ([]byte, []int) {
}
type CheckedExpr struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
+ ReferenceMap map[int64]*Reference `protobuf:"bytes,2,rep,name=reference_map,json=referenceMap,proto3" json:"reference_map,omitempty" protobuf_key:"varint,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"`
+ TypeMap map[int64]*Type `protobuf:"bytes,3,rep,name=type_map,json=typeMap,proto3" json:"type_map,omitempty" protobuf_key:"varint,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"`
+ SourceInfo *SourceInfo `protobuf:"bytes,5,opt,name=source_info,json=sourceInfo,proto3" json:"source_info,omitempty"`
+ ExprVersion string `protobuf:"bytes,6,opt,name=expr_version,json=exprVersion,proto3" json:"expr_version,omitempty"`
+ Expr *Expr `protobuf:"bytes,4,opt,name=expr,proto3" json:"expr,omitempty"`
unknownFields protoimpl.UnknownFields
-
- ReferenceMap map[int64]*Reference `protobuf:"bytes,2,rep,name=reference_map,json=referenceMap,proto3" json:"reference_map,omitempty" protobuf_key:"varint,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
- TypeMap map[int64]*Type `protobuf:"bytes,3,rep,name=type_map,json=typeMap,proto3" json:"type_map,omitempty" protobuf_key:"varint,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
- SourceInfo *SourceInfo `protobuf:"bytes,5,opt,name=source_info,json=sourceInfo,proto3" json:"source_info,omitempty"`
- ExprVersion string `protobuf:"bytes,6,opt,name=expr_version,json=exprVersion,proto3" json:"expr_version,omitempty"`
- Expr *Expr `protobuf:"bytes,4,opt,name=expr,proto3" json:"expr,omitempty"`
+ sizeCache protoimpl.SizeCache
}
func (x *CheckedExpr) Reset() {
*x = CheckedExpr{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_checked_proto_msgTypes[0]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_checked_proto_msgTypes[0]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *CheckedExpr) String() string {
@@ -164,7 +162,7 @@ func (*CheckedExpr) ProtoMessage() {}
func (x *CheckedExpr) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_checked_proto_msgTypes[0]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -215,11 +213,8 @@ func (x *CheckedExpr) GetExpr() *Expr {
}
type Type struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
- // Types that are assignable to TypeKind:
+ state protoimpl.MessageState `protogen:"open.v1"`
+ // Types that are valid to be assigned to TypeKind:
//
// *Type_Dyn
// *Type_Null
@@ -234,16 +229,16 @@ type Type struct {
// *Type_Type
// *Type_Error
// *Type_AbstractType_
- TypeKind isType_TypeKind `protobuf_oneof:"type_kind"`
+ TypeKind isType_TypeKind `protobuf_oneof:"type_kind"`
+ unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *Type) Reset() {
*x = Type{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_checked_proto_msgTypes[1]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_checked_proto_msgTypes[1]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Type) String() string {
@@ -254,7 +249,7 @@ func (*Type) ProtoMessage() {}
func (x *Type) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_checked_proto_msgTypes[1]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -269,100 +264,126 @@ func (*Type) Descriptor() ([]byte, []int) {
return file_cel_expr_checked_proto_rawDescGZIP(), []int{1}
}
-func (m *Type) GetTypeKind() isType_TypeKind {
- if m != nil {
- return m.TypeKind
+func (x *Type) GetTypeKind() isType_TypeKind {
+ if x != nil {
+ return x.TypeKind
}
return nil
}
func (x *Type) GetDyn() *emptypb.Empty {
- if x, ok := x.GetTypeKind().(*Type_Dyn); ok {
- return x.Dyn
+ if x != nil {
+ if x, ok := x.TypeKind.(*Type_Dyn); ok {
+ return x.Dyn
+ }
}
return nil
}
func (x *Type) GetNull() structpb.NullValue {
- if x, ok := x.GetTypeKind().(*Type_Null); ok {
- return x.Null
+ if x != nil {
+ if x, ok := x.TypeKind.(*Type_Null); ok {
+ return x.Null
+ }
}
return structpb.NullValue(0)
}
func (x *Type) GetPrimitive() Type_PrimitiveType {
- if x, ok := x.GetTypeKind().(*Type_Primitive); ok {
- return x.Primitive
+ if x != nil {
+ if x, ok := x.TypeKind.(*Type_Primitive); ok {
+ return x.Primitive
+ }
}
return Type_PRIMITIVE_TYPE_UNSPECIFIED
}
func (x *Type) GetWrapper() Type_PrimitiveType {
- if x, ok := x.GetTypeKind().(*Type_Wrapper); ok {
- return x.Wrapper
+ if x != nil {
+ if x, ok := x.TypeKind.(*Type_Wrapper); ok {
+ return x.Wrapper
+ }
}
return Type_PRIMITIVE_TYPE_UNSPECIFIED
}
func (x *Type) GetWellKnown() Type_WellKnownType {
- if x, ok := x.GetTypeKind().(*Type_WellKnown); ok {
- return x.WellKnown
+ if x != nil {
+ if x, ok := x.TypeKind.(*Type_WellKnown); ok {
+ return x.WellKnown
+ }
}
return Type_WELL_KNOWN_TYPE_UNSPECIFIED
}
func (x *Type) GetListType() *Type_ListType {
- if x, ok := x.GetTypeKind().(*Type_ListType_); ok {
- return x.ListType
+ if x != nil {
+ if x, ok := x.TypeKind.(*Type_ListType_); ok {
+ return x.ListType
+ }
}
return nil
}
func (x *Type) GetMapType() *Type_MapType {
- if x, ok := x.GetTypeKind().(*Type_MapType_); ok {
- return x.MapType
+ if x != nil {
+ if x, ok := x.TypeKind.(*Type_MapType_); ok {
+ return x.MapType
+ }
}
return nil
}
func (x *Type) GetFunction() *Type_FunctionType {
- if x, ok := x.GetTypeKind().(*Type_Function); ok {
- return x.Function
+ if x != nil {
+ if x, ok := x.TypeKind.(*Type_Function); ok {
+ return x.Function
+ }
}
return nil
}
func (x *Type) GetMessageType() string {
- if x, ok := x.GetTypeKind().(*Type_MessageType); ok {
- return x.MessageType
+ if x != nil {
+ if x, ok := x.TypeKind.(*Type_MessageType); ok {
+ return x.MessageType
+ }
}
return ""
}
func (x *Type) GetTypeParam() string {
- if x, ok := x.GetTypeKind().(*Type_TypeParam); ok {
- return x.TypeParam
+ if x != nil {
+ if x, ok := x.TypeKind.(*Type_TypeParam); ok {
+ return x.TypeParam
+ }
}
return ""
}
func (x *Type) GetType() *Type {
- if x, ok := x.GetTypeKind().(*Type_Type); ok {
- return x.Type
+ if x != nil {
+ if x, ok := x.TypeKind.(*Type_Type); ok {
+ return x.Type
+ }
}
return nil
}
func (x *Type) GetError() *emptypb.Empty {
- if x, ok := x.GetTypeKind().(*Type_Error); ok {
- return x.Error
+ if x != nil {
+ if x, ok := x.TypeKind.(*Type_Error); ok {
+ return x.Error
+ }
}
return nil
}
func (x *Type) GetAbstractType() *Type_AbstractType {
- if x, ok := x.GetTypeKind().(*Type_AbstractType_); ok {
- return x.AbstractType
+ if x != nil {
+ if x, ok := x.TypeKind.(*Type_AbstractType_); ok {
+ return x.AbstractType
+ }
}
return nil
}
@@ -450,25 +471,22 @@ func (*Type_Error) isType_TypeKind() {}
func (*Type_AbstractType_) isType_TypeKind() {}
type Decl struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
- Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
- // Types that are assignable to DeclKind:
+ state protoimpl.MessageState `protogen:"open.v1"`
+ Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
+ // Types that are valid to be assigned to DeclKind:
//
// *Decl_Ident
// *Decl_Function
- DeclKind isDecl_DeclKind `protobuf_oneof:"decl_kind"`
+ DeclKind isDecl_DeclKind `protobuf_oneof:"decl_kind"`
+ unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *Decl) Reset() {
*x = Decl{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_checked_proto_msgTypes[2]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_checked_proto_msgTypes[2]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Decl) String() string {
@@ -479,7 +497,7 @@ func (*Decl) ProtoMessage() {}
func (x *Decl) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_checked_proto_msgTypes[2]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -501,23 +519,27 @@ func (x *Decl) GetName() string {
return ""
}
-func (m *Decl) GetDeclKind() isDecl_DeclKind {
- if m != nil {
- return m.DeclKind
+func (x *Decl) GetDeclKind() isDecl_DeclKind {
+ if x != nil {
+ return x.DeclKind
}
return nil
}
func (x *Decl) GetIdent() *Decl_IdentDecl {
- if x, ok := x.GetDeclKind().(*Decl_Ident); ok {
- return x.Ident
+ if x != nil {
+ if x, ok := x.DeclKind.(*Decl_Ident); ok {
+ return x.Ident
+ }
}
return nil
}
func (x *Decl) GetFunction() *Decl_FunctionDecl {
- if x, ok := x.GetDeclKind().(*Decl_Function); ok {
- return x.Function
+ if x != nil {
+ if x, ok := x.DeclKind.(*Decl_Function); ok {
+ return x.Function
+ }
}
return nil
}
@@ -539,22 +561,19 @@ func (*Decl_Ident) isDecl_DeclKind() {}
func (*Decl_Function) isDecl_DeclKind() {}
type Reference struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
+ Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
+ OverloadId []string `protobuf:"bytes,3,rep,name=overload_id,json=overloadId,proto3" json:"overload_id,omitempty"`
+ Value *Constant `protobuf:"bytes,4,opt,name=value,proto3" json:"value,omitempty"`
unknownFields protoimpl.UnknownFields
-
- Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
- OverloadId []string `protobuf:"bytes,3,rep,name=overload_id,json=overloadId,proto3" json:"overload_id,omitempty"`
- Value *Constant `protobuf:"bytes,4,opt,name=value,proto3" json:"value,omitempty"`
+ sizeCache protoimpl.SizeCache
}
func (x *Reference) Reset() {
*x = Reference{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_checked_proto_msgTypes[3]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_checked_proto_msgTypes[3]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Reference) String() string {
@@ -565,7 +584,7 @@ func (*Reference) ProtoMessage() {}
func (x *Reference) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_checked_proto_msgTypes[3]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -602,20 +621,17 @@ func (x *Reference) GetValue() *Constant {
}
type Type_ListType struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
+ ElemType *Type `protobuf:"bytes,1,opt,name=elem_type,json=elemType,proto3" json:"elem_type,omitempty"`
unknownFields protoimpl.UnknownFields
-
- ElemType *Type `protobuf:"bytes,1,opt,name=elem_type,json=elemType,proto3" json:"elem_type,omitempty"`
+ sizeCache protoimpl.SizeCache
}
func (x *Type_ListType) Reset() {
*x = Type_ListType{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_checked_proto_msgTypes[6]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_checked_proto_msgTypes[6]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Type_ListType) String() string {
@@ -626,7 +642,7 @@ func (*Type_ListType) ProtoMessage() {}
func (x *Type_ListType) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_checked_proto_msgTypes[6]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -649,21 +665,18 @@ func (x *Type_ListType) GetElemType() *Type {
}
type Type_MapType struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
+ KeyType *Type `protobuf:"bytes,1,opt,name=key_type,json=keyType,proto3" json:"key_type,omitempty"`
+ ValueType *Type `protobuf:"bytes,2,opt,name=value_type,json=valueType,proto3" json:"value_type,omitempty"`
unknownFields protoimpl.UnknownFields
-
- KeyType *Type `protobuf:"bytes,1,opt,name=key_type,json=keyType,proto3" json:"key_type,omitempty"`
- ValueType *Type `protobuf:"bytes,2,opt,name=value_type,json=valueType,proto3" json:"value_type,omitempty"`
+ sizeCache protoimpl.SizeCache
}
func (x *Type_MapType) Reset() {
*x = Type_MapType{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_checked_proto_msgTypes[7]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_checked_proto_msgTypes[7]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Type_MapType) String() string {
@@ -674,7 +687,7 @@ func (*Type_MapType) ProtoMessage() {}
func (x *Type_MapType) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_checked_proto_msgTypes[7]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -704,21 +717,18 @@ func (x *Type_MapType) GetValueType() *Type {
}
type Type_FunctionType struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
+ ResultType *Type `protobuf:"bytes,1,opt,name=result_type,json=resultType,proto3" json:"result_type,omitempty"`
+ ArgTypes []*Type `protobuf:"bytes,2,rep,name=arg_types,json=argTypes,proto3" json:"arg_types,omitempty"`
unknownFields protoimpl.UnknownFields
-
- ResultType *Type `protobuf:"bytes,1,opt,name=result_type,json=resultType,proto3" json:"result_type,omitempty"`
- ArgTypes []*Type `protobuf:"bytes,2,rep,name=arg_types,json=argTypes,proto3" json:"arg_types,omitempty"`
+ sizeCache protoimpl.SizeCache
}
func (x *Type_FunctionType) Reset() {
*x = Type_FunctionType{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_checked_proto_msgTypes[8]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_checked_proto_msgTypes[8]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Type_FunctionType) String() string {
@@ -729,7 +739,7 @@ func (*Type_FunctionType) ProtoMessage() {}
func (x *Type_FunctionType) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_checked_proto_msgTypes[8]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -759,21 +769,18 @@ func (x *Type_FunctionType) GetArgTypes() []*Type {
}
type Type_AbstractType struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
- Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
- ParameterTypes []*Type `protobuf:"bytes,2,rep,name=parameter_types,json=parameterTypes,proto3" json:"parameter_types,omitempty"`
+ state protoimpl.MessageState `protogen:"open.v1"`
+ Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
+ ParameterTypes []*Type `protobuf:"bytes,2,rep,name=parameter_types,json=parameterTypes,proto3" json:"parameter_types,omitempty"`
+ unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *Type_AbstractType) Reset() {
*x = Type_AbstractType{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_checked_proto_msgTypes[9]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_checked_proto_msgTypes[9]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Type_AbstractType) String() string {
@@ -784,7 +791,7 @@ func (*Type_AbstractType) ProtoMessage() {}
func (x *Type_AbstractType) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_checked_proto_msgTypes[9]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -814,22 +821,19 @@ func (x *Type_AbstractType) GetParameterTypes() []*Type {
}
type Decl_IdentDecl struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
+ Type *Type `protobuf:"bytes,1,opt,name=type,proto3" json:"type,omitempty"`
+ Value *Constant `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
+ Doc string `protobuf:"bytes,3,opt,name=doc,proto3" json:"doc,omitempty"`
unknownFields protoimpl.UnknownFields
-
- Type *Type `protobuf:"bytes,1,opt,name=type,proto3" json:"type,omitempty"`
- Value *Constant `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
- Doc string `protobuf:"bytes,3,opt,name=doc,proto3" json:"doc,omitempty"`
+ sizeCache protoimpl.SizeCache
}
func (x *Decl_IdentDecl) Reset() {
*x = Decl_IdentDecl{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_checked_proto_msgTypes[10]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_checked_proto_msgTypes[10]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Decl_IdentDecl) String() string {
@@ -840,7 +844,7 @@ func (*Decl_IdentDecl) ProtoMessage() {}
func (x *Decl_IdentDecl) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_checked_proto_msgTypes[10]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -877,20 +881,18 @@ func (x *Decl_IdentDecl) GetDoc() string {
}
type Decl_FunctionDecl struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
+ Overloads []*Decl_FunctionDecl_Overload `protobuf:"bytes,1,rep,name=overloads,proto3" json:"overloads,omitempty"`
+ Doc string `protobuf:"bytes,2,opt,name=doc,proto3" json:"doc,omitempty"`
unknownFields protoimpl.UnknownFields
-
- Overloads []*Decl_FunctionDecl_Overload `protobuf:"bytes,1,rep,name=overloads,proto3" json:"overloads,omitempty"`
+ sizeCache protoimpl.SizeCache
}
func (x *Decl_FunctionDecl) Reset() {
*x = Decl_FunctionDecl{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_checked_proto_msgTypes[11]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_checked_proto_msgTypes[11]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Decl_FunctionDecl) String() string {
@@ -901,7 +903,7 @@ func (*Decl_FunctionDecl) ProtoMessage() {}
func (x *Decl_FunctionDecl) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_checked_proto_msgTypes[11]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -923,26 +925,30 @@ func (x *Decl_FunctionDecl) GetOverloads() []*Decl_FunctionDecl_Overload {
return nil
}
-type Decl_FunctionDecl_Overload struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
+func (x *Decl_FunctionDecl) GetDoc() string {
+ if x != nil {
+ return x.Doc
+ }
+ return ""
+}
- OverloadId string `protobuf:"bytes,1,opt,name=overload_id,json=overloadId,proto3" json:"overload_id,omitempty"`
- Params []*Type `protobuf:"bytes,2,rep,name=params,proto3" json:"params,omitempty"`
- TypeParams []string `protobuf:"bytes,3,rep,name=type_params,json=typeParams,proto3" json:"type_params,omitempty"`
- ResultType *Type `protobuf:"bytes,4,opt,name=result_type,json=resultType,proto3" json:"result_type,omitempty"`
- IsInstanceFunction bool `protobuf:"varint,5,opt,name=is_instance_function,json=isInstanceFunction,proto3" json:"is_instance_function,omitempty"`
- Doc string `protobuf:"bytes,6,opt,name=doc,proto3" json:"doc,omitempty"`
+type Decl_FunctionDecl_Overload struct {
+ state protoimpl.MessageState `protogen:"open.v1"`
+ OverloadId string `protobuf:"bytes,1,opt,name=overload_id,json=overloadId,proto3" json:"overload_id,omitempty"`
+ Params []*Type `protobuf:"bytes,2,rep,name=params,proto3" json:"params,omitempty"`
+ TypeParams []string `protobuf:"bytes,3,rep,name=type_params,json=typeParams,proto3" json:"type_params,omitempty"`
+ ResultType *Type `protobuf:"bytes,4,opt,name=result_type,json=resultType,proto3" json:"result_type,omitempty"`
+ IsInstanceFunction bool `protobuf:"varint,5,opt,name=is_instance_function,json=isInstanceFunction,proto3" json:"is_instance_function,omitempty"`
+ Doc string `protobuf:"bytes,6,opt,name=doc,proto3" json:"doc,omitempty"`
+ unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *Decl_FunctionDecl_Overload) Reset() {
*x = Decl_FunctionDecl_Overload{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_checked_proto_msgTypes[12]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_checked_proto_msgTypes[12]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Decl_FunctionDecl_Overload) String() string {
@@ -953,7 +959,7 @@ func (*Decl_FunctionDecl_Overload) ProtoMessage() {}
func (x *Decl_FunctionDecl_Overload) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_checked_proto_msgTypes[12]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -1012,185 +1018,113 @@ func (x *Decl_FunctionDecl_Overload) GetDoc() string {
var File_cel_expr_checked_proto protoreflect.FileDescriptor
-var file_cel_expr_checked_proto_rawDesc = []byte{
- 0x0a, 0x16, 0x63, 0x65, 0x6c, 0x2f, 0x65, 0x78, 0x70, 0x72, 0x2f, 0x63, 0x68, 0x65, 0x63, 0x6b,
- 0x65, 0x64, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x08, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78,
- 0x70, 0x72, 0x1a, 0x15, 0x63, 0x65, 0x6c, 0x2f, 0x65, 0x78, 0x70, 0x72, 0x2f, 0x73, 0x79, 0x6e,
- 0x74, 0x61, 0x78, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1b, 0x67, 0x6f, 0x6f, 0x67, 0x6c,
- 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x65, 0x6d, 0x70, 0x74, 0x79,
- 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1c, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70,
- 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x2e, 0x70,
- 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xba, 0x03, 0x0a, 0x0b, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x65, 0x64,
- 0x45, 0x78, 0x70, 0x72, 0x12, 0x4c, 0x0a, 0x0d, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63,
- 0x65, 0x5f, 0x6d, 0x61, 0x70, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x63, 0x65,
- 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x65, 0x64, 0x45, 0x78,
- 0x70, 0x72, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x4d, 0x61, 0x70, 0x45,
- 0x6e, 0x74, 0x72, 0x79, 0x52, 0x0c, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x4d,
- 0x61, 0x70, 0x12, 0x3d, 0x0a, 0x08, 0x74, 0x79, 0x70, 0x65, 0x5f, 0x6d, 0x61, 0x70, 0x18, 0x03,
- 0x20, 0x03, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e,
- 0x43, 0x68, 0x65, 0x63, 0x6b, 0x65, 0x64, 0x45, 0x78, 0x70, 0x72, 0x2e, 0x54, 0x79, 0x70, 0x65,
- 0x4d, 0x61, 0x70, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x07, 0x74, 0x79, 0x70, 0x65, 0x4d, 0x61,
- 0x70, 0x12, 0x35, 0x0a, 0x0b, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x5f, 0x69, 0x6e, 0x66, 0x6f,
- 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70,
- 0x72, 0x2e, 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x0a, 0x73, 0x6f,
- 0x75, 0x72, 0x63, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x21, 0x0a, 0x0c, 0x65, 0x78, 0x70, 0x72,
- 0x5f, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b,
- 0x65, 0x78, 0x70, 0x72, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x22, 0x0a, 0x04, 0x65,
- 0x78, 0x70, 0x72, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x63, 0x65, 0x6c, 0x2e,
- 0x65, 0x78, 0x70, 0x72, 0x2e, 0x45, 0x78, 0x70, 0x72, 0x52, 0x04, 0x65, 0x78, 0x70, 0x72, 0x1a,
- 0x54, 0x0a, 0x11, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x4d, 0x61, 0x70, 0x45,
- 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28,
- 0x03, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x29, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18,
- 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x13, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72,
- 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75,
- 0x65, 0x3a, 0x02, 0x38, 0x01, 0x1a, 0x4a, 0x0a, 0x0c, 0x54, 0x79, 0x70, 0x65, 0x4d, 0x61, 0x70,
- 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01,
- 0x28, 0x03, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x24, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65,
- 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70,
- 0x72, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38,
- 0x01, 0x22, 0xe6, 0x09, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x2a, 0x0a, 0x03, 0x64, 0x79,
- 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x16, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65,
- 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x48,
- 0x00, 0x52, 0x03, 0x64, 0x79, 0x6e, 0x12, 0x30, 0x0a, 0x04, 0x6e, 0x75, 0x6c, 0x6c, 0x18, 0x02,
- 0x20, 0x01, 0x28, 0x0e, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72,
- 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x4e, 0x75, 0x6c, 0x6c, 0x56, 0x61, 0x6c, 0x75, 0x65,
- 0x48, 0x00, 0x52, 0x04, 0x6e, 0x75, 0x6c, 0x6c, 0x12, 0x3c, 0x0a, 0x09, 0x70, 0x72, 0x69, 0x6d,
- 0x69, 0x74, 0x69, 0x76, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x1c, 0x2e, 0x63, 0x65,
- 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x2e, 0x50, 0x72, 0x69, 0x6d,
- 0x69, 0x74, 0x69, 0x76, 0x65, 0x54, 0x79, 0x70, 0x65, 0x48, 0x00, 0x52, 0x09, 0x70, 0x72, 0x69,
- 0x6d, 0x69, 0x74, 0x69, 0x76, 0x65, 0x12, 0x38, 0x0a, 0x07, 0x77, 0x72, 0x61, 0x70, 0x70, 0x65,
- 0x72, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x1c, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78,
- 0x70, 0x72, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x2e, 0x50, 0x72, 0x69, 0x6d, 0x69, 0x74, 0x69, 0x76,
- 0x65, 0x54, 0x79, 0x70, 0x65, 0x48, 0x00, 0x52, 0x07, 0x77, 0x72, 0x61, 0x70, 0x70, 0x65, 0x72,
- 0x12, 0x3d, 0x0a, 0x0a, 0x77, 0x65, 0x6c, 0x6c, 0x5f, 0x6b, 0x6e, 0x6f, 0x77, 0x6e, 0x18, 0x05,
- 0x20, 0x01, 0x28, 0x0e, 0x32, 0x1c, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e,
- 0x54, 0x79, 0x70, 0x65, 0x2e, 0x57, 0x65, 0x6c, 0x6c, 0x4b, 0x6e, 0x6f, 0x77, 0x6e, 0x54, 0x79,
- 0x70, 0x65, 0x48, 0x00, 0x52, 0x09, 0x77, 0x65, 0x6c, 0x6c, 0x4b, 0x6e, 0x6f, 0x77, 0x6e, 0x12,
- 0x36, 0x0a, 0x09, 0x6c, 0x69, 0x73, 0x74, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x06, 0x20, 0x01,
- 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x54, 0x79,
- 0x70, 0x65, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x54, 0x79, 0x70, 0x65, 0x48, 0x00, 0x52, 0x08, 0x6c,
- 0x69, 0x73, 0x74, 0x54, 0x79, 0x70, 0x65, 0x12, 0x33, 0x0a, 0x08, 0x6d, 0x61, 0x70, 0x5f, 0x74,
- 0x79, 0x70, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x16, 0x2e, 0x63, 0x65, 0x6c, 0x2e,
- 0x65, 0x78, 0x70, 0x72, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x2e, 0x4d, 0x61, 0x70, 0x54, 0x79, 0x70,
- 0x65, 0x48, 0x00, 0x52, 0x07, 0x6d, 0x61, 0x70, 0x54, 0x79, 0x70, 0x65, 0x12, 0x39, 0x0a, 0x08,
- 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b,
- 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x2e, 0x46,
- 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x54, 0x79, 0x70, 0x65, 0x48, 0x00, 0x52, 0x08, 0x66,
- 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x23, 0x0a, 0x0c, 0x6d, 0x65, 0x73, 0x73, 0x61,
- 0x67, 0x65, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x48, 0x00, 0x52,
- 0x0b, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1f, 0x0a, 0x0a,
- 0x74, 0x79, 0x70, 0x65, 0x5f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x09,
- 0x48, 0x00, 0x52, 0x09, 0x74, 0x79, 0x70, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x12, 0x24, 0x0a,
- 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x63, 0x65,
- 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x48, 0x00, 0x52, 0x04, 0x74,
- 0x79, 0x70, 0x65, 0x12, 0x2e, 0x0a, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x18, 0x0c, 0x20, 0x01,
- 0x28, 0x0b, 0x32, 0x16, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74,
- 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x48, 0x00, 0x52, 0x05, 0x65, 0x72,
- 0x72, 0x6f, 0x72, 0x12, 0x42, 0x0a, 0x0d, 0x61, 0x62, 0x73, 0x74, 0x72, 0x61, 0x63, 0x74, 0x5f,
- 0x74, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x63, 0x65, 0x6c,
- 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x2e, 0x41, 0x62, 0x73, 0x74, 0x72,
- 0x61, 0x63, 0x74, 0x54, 0x79, 0x70, 0x65, 0x48, 0x00, 0x52, 0x0c, 0x61, 0x62, 0x73, 0x74, 0x72,
- 0x61, 0x63, 0x74, 0x54, 0x79, 0x70, 0x65, 0x1a, 0x37, 0x0a, 0x08, 0x4c, 0x69, 0x73, 0x74, 0x54,
- 0x79, 0x70, 0x65, 0x12, 0x2b, 0x0a, 0x09, 0x65, 0x6c, 0x65, 0x6d, 0x5f, 0x74, 0x79, 0x70, 0x65,
- 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70,
- 0x72, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x52, 0x08, 0x65, 0x6c, 0x65, 0x6d, 0x54, 0x79, 0x70, 0x65,
- 0x1a, 0x63, 0x0a, 0x07, 0x4d, 0x61, 0x70, 0x54, 0x79, 0x70, 0x65, 0x12, 0x29, 0x0a, 0x08, 0x6b,
- 0x65, 0x79, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e,
- 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x52, 0x07, 0x6b,
- 0x65, 0x79, 0x54, 0x79, 0x70, 0x65, 0x12, 0x2d, 0x0a, 0x0a, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x5f,
- 0x74, 0x79, 0x70, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x63, 0x65, 0x6c,
- 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x52, 0x09, 0x76, 0x61, 0x6c, 0x75,
- 0x65, 0x54, 0x79, 0x70, 0x65, 0x1a, 0x6c, 0x0a, 0x0c, 0x46, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f,
- 0x6e, 0x54, 0x79, 0x70, 0x65, 0x12, 0x2f, 0x0a, 0x0b, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x5f,
- 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x63, 0x65, 0x6c,
- 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x52, 0x0a, 0x72, 0x65, 0x73, 0x75,
- 0x6c, 0x74, 0x54, 0x79, 0x70, 0x65, 0x12, 0x2b, 0x0a, 0x09, 0x61, 0x72, 0x67, 0x5f, 0x74, 0x79,
- 0x70, 0x65, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x63, 0x65, 0x6c, 0x2e,
- 0x65, 0x78, 0x70, 0x72, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x52, 0x08, 0x61, 0x72, 0x67, 0x54, 0x79,
- 0x70, 0x65, 0x73, 0x1a, 0x5b, 0x0a, 0x0c, 0x41, 0x62, 0x73, 0x74, 0x72, 0x61, 0x63, 0x74, 0x54,
- 0x79, 0x70, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28,
- 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x37, 0x0a, 0x0f, 0x70, 0x61, 0x72, 0x61, 0x6d,
- 0x65, 0x74, 0x65, 0x72, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b,
- 0x32, 0x0e, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x54, 0x79, 0x70, 0x65,
- 0x52, 0x0e, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x65, 0x74, 0x65, 0x72, 0x54, 0x79, 0x70, 0x65, 0x73,
- 0x22, 0x73, 0x0a, 0x0d, 0x50, 0x72, 0x69, 0x6d, 0x69, 0x74, 0x69, 0x76, 0x65, 0x54, 0x79, 0x70,
- 0x65, 0x12, 0x1e, 0x0a, 0x1a, 0x50, 0x52, 0x49, 0x4d, 0x49, 0x54, 0x49, 0x56, 0x45, 0x5f, 0x54,
- 0x59, 0x50, 0x45, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10,
- 0x00, 0x12, 0x08, 0x0a, 0x04, 0x42, 0x4f, 0x4f, 0x4c, 0x10, 0x01, 0x12, 0x09, 0x0a, 0x05, 0x49,
- 0x4e, 0x54, 0x36, 0x34, 0x10, 0x02, 0x12, 0x0a, 0x0a, 0x06, 0x55, 0x49, 0x4e, 0x54, 0x36, 0x34,
- 0x10, 0x03, 0x12, 0x0a, 0x0a, 0x06, 0x44, 0x4f, 0x55, 0x42, 0x4c, 0x45, 0x10, 0x04, 0x12, 0x0a,
- 0x0a, 0x06, 0x53, 0x54, 0x52, 0x49, 0x4e, 0x47, 0x10, 0x05, 0x12, 0x09, 0x0a, 0x05, 0x42, 0x59,
- 0x54, 0x45, 0x53, 0x10, 0x06, 0x22, 0x56, 0x0a, 0x0d, 0x57, 0x65, 0x6c, 0x6c, 0x4b, 0x6e, 0x6f,
- 0x77, 0x6e, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1f, 0x0a, 0x1b, 0x57, 0x45, 0x4c, 0x4c, 0x5f, 0x4b,
- 0x4e, 0x4f, 0x57, 0x4e, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43,
- 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x07, 0x0a, 0x03, 0x41, 0x4e, 0x59, 0x10, 0x01,
- 0x12, 0x0d, 0x0a, 0x09, 0x54, 0x49, 0x4d, 0x45, 0x53, 0x54, 0x41, 0x4d, 0x50, 0x10, 0x02, 0x12,
- 0x0c, 0x0a, 0x08, 0x44, 0x55, 0x52, 0x41, 0x54, 0x49, 0x4f, 0x4e, 0x10, 0x03, 0x42, 0x0b, 0x0a,
- 0x09, 0x74, 0x79, 0x70, 0x65, 0x5f, 0x6b, 0x69, 0x6e, 0x64, 0x22, 0xc2, 0x04, 0x0a, 0x04, 0x44,
- 0x65, 0x63, 0x6c, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28,
- 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x30, 0x0a, 0x05, 0x69, 0x64, 0x65, 0x6e, 0x74,
- 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70,
- 0x72, 0x2e, 0x44, 0x65, 0x63, 0x6c, 0x2e, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x44, 0x65, 0x63, 0x6c,
- 0x48, 0x00, 0x52, 0x05, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x12, 0x39, 0x0a, 0x08, 0x66, 0x75, 0x6e,
- 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x63, 0x65,
- 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x44, 0x65, 0x63, 0x6c, 0x2e, 0x46, 0x75, 0x6e, 0x63,
- 0x74, 0x69, 0x6f, 0x6e, 0x44, 0x65, 0x63, 0x6c, 0x48, 0x00, 0x52, 0x08, 0x66, 0x75, 0x6e, 0x63,
- 0x74, 0x69, 0x6f, 0x6e, 0x1a, 0x6b, 0x0a, 0x09, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x44, 0x65, 0x63,
- 0x6c, 0x12, 0x22, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32,
- 0x0e, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x52,
- 0x04, 0x74, 0x79, 0x70, 0x65, 0x12, 0x28, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02,
- 0x20, 0x01, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e,
- 0x43, 0x6f, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x74, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x12,
- 0x10, 0x0a, 0x03, 0x64, 0x6f, 0x63, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x64, 0x6f,
- 0x63, 0x1a, 0xbe, 0x02, 0x0a, 0x0c, 0x46, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x44, 0x65,
- 0x63, 0x6c, 0x12, 0x42, 0x0a, 0x09, 0x6f, 0x76, 0x65, 0x72, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x18,
- 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72,
- 0x2e, 0x44, 0x65, 0x63, 0x6c, 0x2e, 0x46, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x44, 0x65,
- 0x63, 0x6c, 0x2e, 0x4f, 0x76, 0x65, 0x72, 0x6c, 0x6f, 0x61, 0x64, 0x52, 0x09, 0x6f, 0x76, 0x65,
- 0x72, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x1a, 0xe9, 0x01, 0x0a, 0x08, 0x4f, 0x76, 0x65, 0x72, 0x6c,
- 0x6f, 0x61, 0x64, 0x12, 0x1f, 0x0a, 0x0b, 0x6f, 0x76, 0x65, 0x72, 0x6c, 0x6f, 0x61, 0x64, 0x5f,
- 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6f, 0x76, 0x65, 0x72, 0x6c, 0x6f,
- 0x61, 0x64, 0x49, 0x64, 0x12, 0x26, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x02,
- 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e,
- 0x54, 0x79, 0x70, 0x65, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x1f, 0x0a, 0x0b,
- 0x74, 0x79, 0x70, 0x65, 0x5f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28,
- 0x09, 0x52, 0x0a, 0x74, 0x79, 0x70, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x2f, 0x0a,
- 0x0b, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x04, 0x20, 0x01,
- 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x54, 0x79,
- 0x70, 0x65, 0x52, 0x0a, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x54, 0x79, 0x70, 0x65, 0x12, 0x30,
- 0x0a, 0x14, 0x69, 0x73, 0x5f, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x5f, 0x66, 0x75,
- 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x52, 0x12, 0x69, 0x73,
- 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x46, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e,
- 0x12, 0x10, 0x0a, 0x03, 0x64, 0x6f, 0x63, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x64,
- 0x6f, 0x63, 0x42, 0x0b, 0x0a, 0x09, 0x64, 0x65, 0x63, 0x6c, 0x5f, 0x6b, 0x69, 0x6e, 0x64, 0x22,
- 0x6a, 0x0a, 0x09, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x12, 0x12, 0x0a, 0x04,
- 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65,
- 0x12, 0x1f, 0x0a, 0x0b, 0x6f, 0x76, 0x65, 0x72, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x69, 0x64, 0x18,
- 0x03, 0x20, 0x03, 0x28, 0x09, 0x52, 0x0a, 0x6f, 0x76, 0x65, 0x72, 0x6c, 0x6f, 0x61, 0x64, 0x49,
- 0x64, 0x12, 0x28, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b,
- 0x32, 0x12, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x43, 0x6f, 0x6e, 0x73,
- 0x74, 0x61, 0x6e, 0x74, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x42, 0x2c, 0x0a, 0x0c, 0x64,
- 0x65, 0x76, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x42, 0x09, 0x44, 0x65, 0x63,
- 0x6c, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x0c, 0x63, 0x65, 0x6c, 0x2e, 0x64, 0x65,
- 0x76, 0x2f, 0x65, 0x78, 0x70, 0x72, 0xf8, 0x01, 0x01, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f,
- 0x33,
-}
+const file_cel_expr_checked_proto_rawDesc = "" +
+ "\n" +
+ "\x16cel/expr/checked.proto\x12\bcel.expr\x1a\x15cel/expr/syntax.proto\x1a\x1bgoogle/protobuf/empty.proto\x1a\x1cgoogle/protobuf/struct.proto\"\xba\x03\n" +
+ "\vCheckedExpr\x12L\n" +
+ "\rreference_map\x18\x02 \x03(\v2'.cel.expr.CheckedExpr.ReferenceMapEntryR\freferenceMap\x12=\n" +
+ "\btype_map\x18\x03 \x03(\v2\".cel.expr.CheckedExpr.TypeMapEntryR\atypeMap\x125\n" +
+ "\vsource_info\x18\x05 \x01(\v2\x14.cel.expr.SourceInfoR\n" +
+ "sourceInfo\x12!\n" +
+ "\fexpr_version\x18\x06 \x01(\tR\vexprVersion\x12\"\n" +
+ "\x04expr\x18\x04 \x01(\v2\x0e.cel.expr.ExprR\x04expr\x1aT\n" +
+ "\x11ReferenceMapEntry\x12\x10\n" +
+ "\x03key\x18\x01 \x01(\x03R\x03key\x12)\n" +
+ "\x05value\x18\x02 \x01(\v2\x13.cel.expr.ReferenceR\x05value:\x028\x01\x1aJ\n" +
+ "\fTypeMapEntry\x12\x10\n" +
+ "\x03key\x18\x01 \x01(\x03R\x03key\x12$\n" +
+ "\x05value\x18\x02 \x01(\v2\x0e.cel.expr.TypeR\x05value:\x028\x01\"\xe6\t\n" +
+ "\x04Type\x12*\n" +
+ "\x03dyn\x18\x01 \x01(\v2\x16.google.protobuf.EmptyH\x00R\x03dyn\x120\n" +
+ "\x04null\x18\x02 \x01(\x0e2\x1a.google.protobuf.NullValueH\x00R\x04null\x12<\n" +
+ "\tprimitive\x18\x03 \x01(\x0e2\x1c.cel.expr.Type.PrimitiveTypeH\x00R\tprimitive\x128\n" +
+ "\awrapper\x18\x04 \x01(\x0e2\x1c.cel.expr.Type.PrimitiveTypeH\x00R\awrapper\x12=\n" +
+ "\n" +
+ "well_known\x18\x05 \x01(\x0e2\x1c.cel.expr.Type.WellKnownTypeH\x00R\twellKnown\x126\n" +
+ "\tlist_type\x18\x06 \x01(\v2\x17.cel.expr.Type.ListTypeH\x00R\blistType\x123\n" +
+ "\bmap_type\x18\a \x01(\v2\x16.cel.expr.Type.MapTypeH\x00R\amapType\x129\n" +
+ "\bfunction\x18\b \x01(\v2\x1b.cel.expr.Type.FunctionTypeH\x00R\bfunction\x12#\n" +
+ "\fmessage_type\x18\t \x01(\tH\x00R\vmessageType\x12\x1f\n" +
+ "\n" +
+ "type_param\x18\n" +
+ " \x01(\tH\x00R\ttypeParam\x12$\n" +
+ "\x04type\x18\v \x01(\v2\x0e.cel.expr.TypeH\x00R\x04type\x12.\n" +
+ "\x05error\x18\f \x01(\v2\x16.google.protobuf.EmptyH\x00R\x05error\x12B\n" +
+ "\rabstract_type\x18\x0e \x01(\v2\x1b.cel.expr.Type.AbstractTypeH\x00R\fabstractType\x1a7\n" +
+ "\bListType\x12+\n" +
+ "\telem_type\x18\x01 \x01(\v2\x0e.cel.expr.TypeR\belemType\x1ac\n" +
+ "\aMapType\x12)\n" +
+ "\bkey_type\x18\x01 \x01(\v2\x0e.cel.expr.TypeR\akeyType\x12-\n" +
+ "\n" +
+ "value_type\x18\x02 \x01(\v2\x0e.cel.expr.TypeR\tvalueType\x1al\n" +
+ "\fFunctionType\x12/\n" +
+ "\vresult_type\x18\x01 \x01(\v2\x0e.cel.expr.TypeR\n" +
+ "resultType\x12+\n" +
+ "\targ_types\x18\x02 \x03(\v2\x0e.cel.expr.TypeR\bargTypes\x1a[\n" +
+ "\fAbstractType\x12\x12\n" +
+ "\x04name\x18\x01 \x01(\tR\x04name\x127\n" +
+ "\x0fparameter_types\x18\x02 \x03(\v2\x0e.cel.expr.TypeR\x0eparameterTypes\"s\n" +
+ "\rPrimitiveType\x12\x1e\n" +
+ "\x1aPRIMITIVE_TYPE_UNSPECIFIED\x10\x00\x12\b\n" +
+ "\x04BOOL\x10\x01\x12\t\n" +
+ "\x05INT64\x10\x02\x12\n" +
+ "\n" +
+ "\x06UINT64\x10\x03\x12\n" +
+ "\n" +
+ "\x06DOUBLE\x10\x04\x12\n" +
+ "\n" +
+ "\x06STRING\x10\x05\x12\t\n" +
+ "\x05BYTES\x10\x06\"V\n" +
+ "\rWellKnownType\x12\x1f\n" +
+ "\x1bWELL_KNOWN_TYPE_UNSPECIFIED\x10\x00\x12\a\n" +
+ "\x03ANY\x10\x01\x12\r\n" +
+ "\tTIMESTAMP\x10\x02\x12\f\n" +
+ "\bDURATION\x10\x03B\v\n" +
+ "\ttype_kind\"\xd4\x04\n" +
+ "\x04Decl\x12\x12\n" +
+ "\x04name\x18\x01 \x01(\tR\x04name\x120\n" +
+ "\x05ident\x18\x02 \x01(\v2\x18.cel.expr.Decl.IdentDeclH\x00R\x05ident\x129\n" +
+ "\bfunction\x18\x03 \x01(\v2\x1b.cel.expr.Decl.FunctionDeclH\x00R\bfunction\x1ak\n" +
+ "\tIdentDecl\x12\"\n" +
+ "\x04type\x18\x01 \x01(\v2\x0e.cel.expr.TypeR\x04type\x12(\n" +
+ "\x05value\x18\x02 \x01(\v2\x12.cel.expr.ConstantR\x05value\x12\x10\n" +
+ "\x03doc\x18\x03 \x01(\tR\x03doc\x1a\xd0\x02\n" +
+ "\fFunctionDecl\x12B\n" +
+ "\toverloads\x18\x01 \x03(\v2$.cel.expr.Decl.FunctionDecl.OverloadR\toverloads\x12\x10\n" +
+ "\x03doc\x18\x02 \x01(\tR\x03doc\x1a\xe9\x01\n" +
+ "\bOverload\x12\x1f\n" +
+ "\voverload_id\x18\x01 \x01(\tR\n" +
+ "overloadId\x12&\n" +
+ "\x06params\x18\x02 \x03(\v2\x0e.cel.expr.TypeR\x06params\x12\x1f\n" +
+ "\vtype_params\x18\x03 \x03(\tR\n" +
+ "typeParams\x12/\n" +
+ "\vresult_type\x18\x04 \x01(\v2\x0e.cel.expr.TypeR\n" +
+ "resultType\x120\n" +
+ "\x14is_instance_function\x18\x05 \x01(\bR\x12isInstanceFunction\x12\x10\n" +
+ "\x03doc\x18\x06 \x01(\tR\x03docB\v\n" +
+ "\tdecl_kind\"j\n" +
+ "\tReference\x12\x12\n" +
+ "\x04name\x18\x01 \x01(\tR\x04name\x12\x1f\n" +
+ "\voverload_id\x18\x03 \x03(\tR\n" +
+ "overloadId\x12(\n" +
+ "\x05value\x18\x04 \x01(\v2\x12.cel.expr.ConstantR\x05valueB,\n" +
+ "\fdev.cel.exprB\tDeclProtoP\x01Z\fcel.dev/expr\xf8\x01\x01b\x06proto3"
var (
file_cel_expr_checked_proto_rawDescOnce sync.Once
- file_cel_expr_checked_proto_rawDescData = file_cel_expr_checked_proto_rawDesc
+ file_cel_expr_checked_proto_rawDescData []byte
)
func file_cel_expr_checked_proto_rawDescGZIP() []byte {
file_cel_expr_checked_proto_rawDescOnce.Do(func() {
- file_cel_expr_checked_proto_rawDescData = protoimpl.X.CompressGZIP(file_cel_expr_checked_proto_rawDescData)
+ file_cel_expr_checked_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_cel_expr_checked_proto_rawDesc), len(file_cel_expr_checked_proto_rawDesc)))
})
return file_cel_expr_checked_proto_rawDescData
}
var file_cel_expr_checked_proto_enumTypes = make([]protoimpl.EnumInfo, 2)
var file_cel_expr_checked_proto_msgTypes = make([]protoimpl.MessageInfo, 13)
-var file_cel_expr_checked_proto_goTypes = []interface{}{
+var file_cel_expr_checked_proto_goTypes = []any{
(Type_PrimitiveType)(0), // 0: cel.expr.Type.PrimitiveType
(Type_WellKnownType)(0), // 1: cel.expr.Type.WellKnownType
(*CheckedExpr)(nil), // 2: cel.expr.CheckedExpr
@@ -1257,141 +1191,7 @@ func file_cel_expr_checked_proto_init() {
return
}
file_cel_expr_syntax_proto_init()
- if !protoimpl.UnsafeEnabled {
- file_cel_expr_checked_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*CheckedExpr); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- file_cel_expr_checked_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*Type); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- file_cel_expr_checked_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*Decl); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- file_cel_expr_checked_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*Reference); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- file_cel_expr_checked_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*Type_ListType); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- file_cel_expr_checked_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*Type_MapType); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- file_cel_expr_checked_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*Type_FunctionType); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- file_cel_expr_checked_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*Type_AbstractType); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- file_cel_expr_checked_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*Decl_IdentDecl); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- file_cel_expr_checked_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*Decl_FunctionDecl); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- file_cel_expr_checked_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*Decl_FunctionDecl_Overload); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- }
- file_cel_expr_checked_proto_msgTypes[1].OneofWrappers = []interface{}{
+ file_cel_expr_checked_proto_msgTypes[1].OneofWrappers = []any{
(*Type_Dyn)(nil),
(*Type_Null)(nil),
(*Type_Primitive)(nil),
@@ -1406,7 +1206,7 @@ func file_cel_expr_checked_proto_init() {
(*Type_Error)(nil),
(*Type_AbstractType_)(nil),
}
- file_cel_expr_checked_proto_msgTypes[2].OneofWrappers = []interface{}{
+ file_cel_expr_checked_proto_msgTypes[2].OneofWrappers = []any{
(*Decl_Ident)(nil),
(*Decl_Function)(nil),
}
@@ -1414,7 +1214,7 @@ func file_cel_expr_checked_proto_init() {
out := protoimpl.TypeBuilder{
File: protoimpl.DescBuilder{
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
- RawDescriptor: file_cel_expr_checked_proto_rawDesc,
+ RawDescriptor: unsafe.Slice(unsafe.StringData(file_cel_expr_checked_proto_rawDesc), len(file_cel_expr_checked_proto_rawDesc)),
NumEnums: 2,
NumMessages: 13,
NumExtensions: 0,
@@ -1426,7 +1226,6 @@ func file_cel_expr_checked_proto_init() {
MessageInfos: file_cel_expr_checked_proto_msgTypes,
}.Build()
File_cel_expr_checked_proto = out.File
- file_cel_expr_checked_proto_rawDesc = nil
file_cel_expr_checked_proto_goTypes = nil
file_cel_expr_checked_proto_depIdxs = nil
}
diff --git a/vendor/cel.dev/expr/eval.pb.go b/vendor/cel.dev/expr/eval.pb.go
index a7aae0900c..83acb8935b 100644
--- a/vendor/cel.dev/expr/eval.pb.go
+++ b/vendor/cel.dev/expr/eval.pb.go
@@ -1,6 +1,6 @@
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
-// protoc-gen-go v1.36.3
+// protoc-gen-go v1.36.10
// protoc v5.27.1
// source: cel/expr/eval.proto
@@ -12,6 +12,7 @@ import (
anypb "google.golang.org/protobuf/types/known/anypb"
reflect "reflect"
sync "sync"
+ unsafe "unsafe"
)
const (
@@ -373,58 +374,39 @@ func (x *EvalState_Result) GetValue() int64 {
var File_cel_expr_eval_proto protoreflect.FileDescriptor
-var file_cel_expr_eval_proto_rawDesc = []byte{
- 0x0a, 0x13, 0x63, 0x65, 0x6c, 0x2f, 0x65, 0x78, 0x70, 0x72, 0x2f, 0x65, 0x76, 0x61, 0x6c, 0x2e,
- 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x08, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x1a,
- 0x19, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66,
- 0x2f, 0x61, 0x6e, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x63, 0x65, 0x6c, 0x2f,
- 0x65, 0x78, 0x70, 0x72, 0x2f, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f,
- 0x22, 0xa2, 0x01, 0x0a, 0x09, 0x45, 0x76, 0x61, 0x6c, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x2b,
- 0x0a, 0x06, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x13,
- 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x45, 0x78, 0x70, 0x72, 0x56, 0x61,
- 0x6c, 0x75, 0x65, 0x52, 0x06, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x12, 0x34, 0x0a, 0x07, 0x72,
- 0x65, 0x73, 0x75, 0x6c, 0x74, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x63,
- 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x45, 0x76, 0x61, 0x6c, 0x53, 0x74, 0x61, 0x74,
- 0x65, 0x2e, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x52, 0x07, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74,
- 0x73, 0x1a, 0x32, 0x0a, 0x06, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x65,
- 0x78, 0x70, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x65, 0x78, 0x70, 0x72, 0x12,
- 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05,
- 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x9a, 0x01, 0x0a, 0x09, 0x45, 0x78, 0x70, 0x72, 0x56, 0x61,
- 0x6c, 0x75, 0x65, 0x12, 0x27, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x01,
- 0x28, 0x0b, 0x32, 0x0f, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x56, 0x61,
- 0x6c, 0x75, 0x65, 0x48, 0x00, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x2a, 0x0a, 0x05,
- 0x65, 0x72, 0x72, 0x6f, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x63, 0x65,
- 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x53, 0x65, 0x74, 0x48,
- 0x00, 0x52, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x12, 0x30, 0x0a, 0x07, 0x75, 0x6e, 0x6b, 0x6e,
- 0x6f, 0x77, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x63, 0x65, 0x6c, 0x2e,
- 0x65, 0x78, 0x70, 0x72, 0x2e, 0x55, 0x6e, 0x6b, 0x6e, 0x6f, 0x77, 0x6e, 0x53, 0x65, 0x74, 0x48,
- 0x00, 0x52, 0x07, 0x75, 0x6e, 0x6b, 0x6e, 0x6f, 0x77, 0x6e, 0x42, 0x06, 0x0a, 0x04, 0x6b, 0x69,
- 0x6e, 0x64, 0x22, 0x34, 0x0a, 0x08, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x53, 0x65, 0x74, 0x12, 0x28,
- 0x0a, 0x06, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x10,
- 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73,
- 0x52, 0x06, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x73, 0x22, 0x66, 0x0a, 0x06, 0x53, 0x74, 0x61, 0x74,
- 0x75, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05,
- 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67,
- 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65,
- 0x12, 0x2e, 0x0a, 0x07, 0x64, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28,
- 0x0b, 0x32, 0x14, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f,
- 0x62, 0x75, 0x66, 0x2e, 0x41, 0x6e, 0x79, 0x52, 0x07, 0x64, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x73,
- 0x22, 0x22, 0x0a, 0x0a, 0x55, 0x6e, 0x6b, 0x6e, 0x6f, 0x77, 0x6e, 0x53, 0x65, 0x74, 0x12, 0x14,
- 0x0a, 0x05, 0x65, 0x78, 0x70, 0x72, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x03, 0x52, 0x05, 0x65,
- 0x78, 0x70, 0x72, 0x73, 0x42, 0x2c, 0x0a, 0x0c, 0x64, 0x65, 0x76, 0x2e, 0x63, 0x65, 0x6c, 0x2e,
- 0x65, 0x78, 0x70, 0x72, 0x42, 0x09, 0x45, 0x76, 0x61, 0x6c, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50,
- 0x01, 0x5a, 0x0c, 0x63, 0x65, 0x6c, 0x2e, 0x64, 0x65, 0x76, 0x2f, 0x65, 0x78, 0x70, 0x72, 0xf8,
- 0x01, 0x01, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
-}
+const file_cel_expr_eval_proto_rawDesc = "" +
+ "\n" +
+ "\x13cel/expr/eval.proto\x12\bcel.expr\x1a\x19google/protobuf/any.proto\x1a\x14cel/expr/value.proto\"\xa2\x01\n" +
+ "\tEvalState\x12+\n" +
+ "\x06values\x18\x01 \x03(\v2\x13.cel.expr.ExprValueR\x06values\x124\n" +
+ "\aresults\x18\x03 \x03(\v2\x1a.cel.expr.EvalState.ResultR\aresults\x1a2\n" +
+ "\x06Result\x12\x12\n" +
+ "\x04expr\x18\x01 \x01(\x03R\x04expr\x12\x14\n" +
+ "\x05value\x18\x02 \x01(\x03R\x05value\"\x9a\x01\n" +
+ "\tExprValue\x12'\n" +
+ "\x05value\x18\x01 \x01(\v2\x0f.cel.expr.ValueH\x00R\x05value\x12*\n" +
+ "\x05error\x18\x02 \x01(\v2\x12.cel.expr.ErrorSetH\x00R\x05error\x120\n" +
+ "\aunknown\x18\x03 \x01(\v2\x14.cel.expr.UnknownSetH\x00R\aunknownB\x06\n" +
+ "\x04kind\"4\n" +
+ "\bErrorSet\x12(\n" +
+ "\x06errors\x18\x01 \x03(\v2\x10.cel.expr.StatusR\x06errors\"f\n" +
+ "\x06Status\x12\x12\n" +
+ "\x04code\x18\x01 \x01(\x05R\x04code\x12\x18\n" +
+ "\amessage\x18\x02 \x01(\tR\amessage\x12.\n" +
+ "\adetails\x18\x03 \x03(\v2\x14.google.protobuf.AnyR\adetails\"\"\n" +
+ "\n" +
+ "UnknownSet\x12\x14\n" +
+ "\x05exprs\x18\x01 \x03(\x03R\x05exprsB,\n" +
+ "\fdev.cel.exprB\tEvalProtoP\x01Z\fcel.dev/expr\xf8\x01\x01b\x06proto3"
var (
file_cel_expr_eval_proto_rawDescOnce sync.Once
- file_cel_expr_eval_proto_rawDescData = file_cel_expr_eval_proto_rawDesc
+ file_cel_expr_eval_proto_rawDescData []byte
)
func file_cel_expr_eval_proto_rawDescGZIP() []byte {
file_cel_expr_eval_proto_rawDescOnce.Do(func() {
- file_cel_expr_eval_proto_rawDescData = protoimpl.X.CompressGZIP(file_cel_expr_eval_proto_rawDescData)
+ file_cel_expr_eval_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_cel_expr_eval_proto_rawDesc), len(file_cel_expr_eval_proto_rawDesc)))
})
return file_cel_expr_eval_proto_rawDescData
}
@@ -470,7 +452,7 @@ func file_cel_expr_eval_proto_init() {
out := protoimpl.TypeBuilder{
File: protoimpl.DescBuilder{
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
- RawDescriptor: file_cel_expr_eval_proto_rawDesc,
+ RawDescriptor: unsafe.Slice(unsafe.StringData(file_cel_expr_eval_proto_rawDesc), len(file_cel_expr_eval_proto_rawDesc)),
NumEnums: 0,
NumMessages: 6,
NumExtensions: 0,
@@ -481,7 +463,6 @@ func file_cel_expr_eval_proto_init() {
MessageInfos: file_cel_expr_eval_proto_msgTypes,
}.Build()
File_cel_expr_eval_proto = out.File
- file_cel_expr_eval_proto_rawDesc = nil
file_cel_expr_eval_proto_goTypes = nil
file_cel_expr_eval_proto_depIdxs = nil
}
diff --git a/vendor/cel.dev/expr/explain.pb.go b/vendor/cel.dev/expr/explain.pb.go
index 79fd5443b9..4239933978 100644
--- a/vendor/cel.dev/expr/explain.pb.go
+++ b/vendor/cel.dev/expr/explain.pb.go
@@ -1,7 +1,7 @@
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
-// protoc-gen-go v1.28.1
-// protoc v3.21.5
+// protoc-gen-go v1.36.10
+// protoc v5.27.1
// source: cel/expr/explain.proto
package expr
@@ -11,6 +11,7 @@ import (
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
reflect "reflect"
sync "sync"
+ unsafe "unsafe"
)
const (
@@ -20,23 +21,20 @@ const (
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
)
-// Deprecated: Do not use.
+// Deprecated: Marked as deprecated in cel/expr/explain.proto.
type Explain struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
+ Values []*Value `protobuf:"bytes,1,rep,name=values,proto3" json:"values,omitempty"`
+ ExprSteps []*Explain_ExprStep `protobuf:"bytes,2,rep,name=expr_steps,json=exprSteps,proto3" json:"expr_steps,omitempty"`
unknownFields protoimpl.UnknownFields
-
- Values []*Value `protobuf:"bytes,1,rep,name=values,proto3" json:"values,omitempty"`
- ExprSteps []*Explain_ExprStep `protobuf:"bytes,2,rep,name=expr_steps,json=exprSteps,proto3" json:"expr_steps,omitempty"`
+ sizeCache protoimpl.SizeCache
}
func (x *Explain) Reset() {
*x = Explain{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_explain_proto_msgTypes[0]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_explain_proto_msgTypes[0]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Explain) String() string {
@@ -47,7 +45,7 @@ func (*Explain) ProtoMessage() {}
func (x *Explain) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_explain_proto_msgTypes[0]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -77,21 +75,18 @@ func (x *Explain) GetExprSteps() []*Explain_ExprStep {
}
type Explain_ExprStep struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
+ Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
+ ValueIndex int32 `protobuf:"varint,2,opt,name=value_index,json=valueIndex,proto3" json:"value_index,omitempty"`
unknownFields protoimpl.UnknownFields
-
- Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
- ValueIndex int32 `protobuf:"varint,2,opt,name=value_index,json=valueIndex,proto3" json:"value_index,omitempty"`
+ sizeCache protoimpl.SizeCache
}
func (x *Explain_ExprStep) Reset() {
*x = Explain_ExprStep{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_explain_proto_msgTypes[1]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_explain_proto_msgTypes[1]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Explain_ExprStep) String() string {
@@ -102,7 +97,7 @@ func (*Explain_ExprStep) ProtoMessage() {}
func (x *Explain_ExprStep) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_explain_proto_msgTypes[1]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -133,42 +128,33 @@ func (x *Explain_ExprStep) GetValueIndex() int32 {
var File_cel_expr_explain_proto protoreflect.FileDescriptor
-var file_cel_expr_explain_proto_rawDesc = []byte{
- 0x0a, 0x16, 0x63, 0x65, 0x6c, 0x2f, 0x65, 0x78, 0x70, 0x72, 0x2f, 0x65, 0x78, 0x70, 0x6c, 0x61,
- 0x69, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x08, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78,
- 0x70, 0x72, 0x1a, 0x14, 0x63, 0x65, 0x6c, 0x2f, 0x65, 0x78, 0x70, 0x72, 0x2f, 0x76, 0x61, 0x6c,
- 0x75, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xae, 0x01, 0x0a, 0x07, 0x45, 0x78, 0x70,
- 0x6c, 0x61, 0x69, 0x6e, 0x12, 0x27, 0x0a, 0x06, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x18, 0x01,
- 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0f, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e,
- 0x56, 0x61, 0x6c, 0x75, 0x65, 0x52, 0x06, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x12, 0x39, 0x0a,
- 0x0a, 0x65, 0x78, 0x70, 0x72, 0x5f, 0x73, 0x74, 0x65, 0x70, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28,
- 0x0b, 0x32, 0x1a, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x45, 0x78, 0x70,
- 0x6c, 0x61, 0x69, 0x6e, 0x2e, 0x45, 0x78, 0x70, 0x72, 0x53, 0x74, 0x65, 0x70, 0x52, 0x09, 0x65,
- 0x78, 0x70, 0x72, 0x53, 0x74, 0x65, 0x70, 0x73, 0x1a, 0x3b, 0x0a, 0x08, 0x45, 0x78, 0x70, 0x72,
- 0x53, 0x74, 0x65, 0x70, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03,
- 0x52, 0x02, 0x69, 0x64, 0x12, 0x1f, 0x0a, 0x0b, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x5f, 0x69, 0x6e,
- 0x64, 0x65, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x76, 0x61, 0x6c, 0x75, 0x65,
- 0x49, 0x6e, 0x64, 0x65, 0x78, 0x3a, 0x02, 0x18, 0x01, 0x42, 0x2f, 0x0a, 0x0c, 0x64, 0x65, 0x76,
- 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x42, 0x0c, 0x45, 0x78, 0x70, 0x6c, 0x61,
- 0x69, 0x6e, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x0c, 0x63, 0x65, 0x6c, 0x2e, 0x64,
- 0x65, 0x76, 0x2f, 0x65, 0x78, 0x70, 0x72, 0xf8, 0x01, 0x01, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74,
- 0x6f, 0x33,
-}
+const file_cel_expr_explain_proto_rawDesc = "" +
+ "\n" +
+ "\x16cel/expr/explain.proto\x12\bcel.expr\x1a\x14cel/expr/value.proto\"\xae\x01\n" +
+ "\aExplain\x12'\n" +
+ "\x06values\x18\x01 \x03(\v2\x0f.cel.expr.ValueR\x06values\x129\n" +
+ "\n" +
+ "expr_steps\x18\x02 \x03(\v2\x1a.cel.expr.Explain.ExprStepR\texprSteps\x1a;\n" +
+ "\bExprStep\x12\x0e\n" +
+ "\x02id\x18\x01 \x01(\x03R\x02id\x12\x1f\n" +
+ "\vvalue_index\x18\x02 \x01(\x05R\n" +
+ "valueIndex:\x02\x18\x01B/\n" +
+ "\fdev.cel.exprB\fExplainProtoP\x01Z\fcel.dev/expr\xf8\x01\x01b\x06proto3"
var (
file_cel_expr_explain_proto_rawDescOnce sync.Once
- file_cel_expr_explain_proto_rawDescData = file_cel_expr_explain_proto_rawDesc
+ file_cel_expr_explain_proto_rawDescData []byte
)
func file_cel_expr_explain_proto_rawDescGZIP() []byte {
file_cel_expr_explain_proto_rawDescOnce.Do(func() {
- file_cel_expr_explain_proto_rawDescData = protoimpl.X.CompressGZIP(file_cel_expr_explain_proto_rawDescData)
+ file_cel_expr_explain_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_cel_expr_explain_proto_rawDesc), len(file_cel_expr_explain_proto_rawDesc)))
})
return file_cel_expr_explain_proto_rawDescData
}
var file_cel_expr_explain_proto_msgTypes = make([]protoimpl.MessageInfo, 2)
-var file_cel_expr_explain_proto_goTypes = []interface{}{
+var file_cel_expr_explain_proto_goTypes = []any{
(*Explain)(nil), // 0: cel.expr.Explain
(*Explain_ExprStep)(nil), // 1: cel.expr.Explain.ExprStep
(*Value)(nil), // 2: cel.expr.Value
@@ -189,37 +175,11 @@ func file_cel_expr_explain_proto_init() {
return
}
file_cel_expr_value_proto_init()
- if !protoimpl.UnsafeEnabled {
- file_cel_expr_explain_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*Explain); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- file_cel_expr_explain_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*Explain_ExprStep); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- }
type x struct{}
out := protoimpl.TypeBuilder{
File: protoimpl.DescBuilder{
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
- RawDescriptor: file_cel_expr_explain_proto_rawDesc,
+ RawDescriptor: unsafe.Slice(unsafe.StringData(file_cel_expr_explain_proto_rawDesc), len(file_cel_expr_explain_proto_rawDesc)),
NumEnums: 0,
NumMessages: 2,
NumExtensions: 0,
@@ -230,7 +190,6 @@ func file_cel_expr_explain_proto_init() {
MessageInfos: file_cel_expr_explain_proto_msgTypes,
}.Build()
File_cel_expr_explain_proto = out.File
- file_cel_expr_explain_proto_rawDesc = nil
file_cel_expr_explain_proto_goTypes = nil
file_cel_expr_explain_proto_depIdxs = nil
}
diff --git a/vendor/cel.dev/expr/syntax.pb.go b/vendor/cel.dev/expr/syntax.pb.go
index 48a952872e..72d19b20d4 100644
--- a/vendor/cel.dev/expr/syntax.pb.go
+++ b/vendor/cel.dev/expr/syntax.pb.go
@@ -1,7 +1,7 @@
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
-// protoc-gen-go v1.28.1
-// protoc v3.21.5
+// protoc-gen-go v1.36.10
+// protoc v5.27.1
// source: cel/expr/syntax.proto
package expr
@@ -14,6 +14,7 @@ import (
timestamppb "google.golang.org/protobuf/types/known/timestamppb"
reflect "reflect"
sync "sync"
+ unsafe "unsafe"
)
const (
@@ -76,21 +77,18 @@ func (SourceInfo_Extension_Component) EnumDescriptor() ([]byte, []int) {
}
type ParsedExpr struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
+ Expr *Expr `protobuf:"bytes,2,opt,name=expr,proto3" json:"expr,omitempty"`
+ SourceInfo *SourceInfo `protobuf:"bytes,3,opt,name=source_info,json=sourceInfo,proto3" json:"source_info,omitempty"`
unknownFields protoimpl.UnknownFields
-
- Expr *Expr `protobuf:"bytes,2,opt,name=expr,proto3" json:"expr,omitempty"`
- SourceInfo *SourceInfo `protobuf:"bytes,3,opt,name=source_info,json=sourceInfo,proto3" json:"source_info,omitempty"`
+ sizeCache protoimpl.SizeCache
}
func (x *ParsedExpr) Reset() {
*x = ParsedExpr{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_syntax_proto_msgTypes[0]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_syntax_proto_msgTypes[0]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *ParsedExpr) String() string {
@@ -101,7 +99,7 @@ func (*ParsedExpr) ProtoMessage() {}
func (x *ParsedExpr) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_syntax_proto_msgTypes[0]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -131,12 +129,9 @@ func (x *ParsedExpr) GetSourceInfo() *SourceInfo {
}
type Expr struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
- Id int64 `protobuf:"varint,2,opt,name=id,proto3" json:"id,omitempty"`
- // Types that are assignable to ExprKind:
+ state protoimpl.MessageState `protogen:"open.v1"`
+ Id int64 `protobuf:"varint,2,opt,name=id,proto3" json:"id,omitempty"`
+ // Types that are valid to be assigned to ExprKind:
//
// *Expr_ConstExpr
// *Expr_IdentExpr
@@ -145,16 +140,16 @@ type Expr struct {
// *Expr_ListExpr
// *Expr_StructExpr
// *Expr_ComprehensionExpr
- ExprKind isExpr_ExprKind `protobuf_oneof:"expr_kind"`
+ ExprKind isExpr_ExprKind `protobuf_oneof:"expr_kind"`
+ unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *Expr) Reset() {
*x = Expr{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_syntax_proto_msgTypes[1]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_syntax_proto_msgTypes[1]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Expr) String() string {
@@ -165,7 +160,7 @@ func (*Expr) ProtoMessage() {}
func (x *Expr) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_syntax_proto_msgTypes[1]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -187,58 +182,72 @@ func (x *Expr) GetId() int64 {
return 0
}
-func (m *Expr) GetExprKind() isExpr_ExprKind {
- if m != nil {
- return m.ExprKind
+func (x *Expr) GetExprKind() isExpr_ExprKind {
+ if x != nil {
+ return x.ExprKind
}
return nil
}
func (x *Expr) GetConstExpr() *Constant {
- if x, ok := x.GetExprKind().(*Expr_ConstExpr); ok {
- return x.ConstExpr
+ if x != nil {
+ if x, ok := x.ExprKind.(*Expr_ConstExpr); ok {
+ return x.ConstExpr
+ }
}
return nil
}
func (x *Expr) GetIdentExpr() *Expr_Ident {
- if x, ok := x.GetExprKind().(*Expr_IdentExpr); ok {
- return x.IdentExpr
+ if x != nil {
+ if x, ok := x.ExprKind.(*Expr_IdentExpr); ok {
+ return x.IdentExpr
+ }
}
return nil
}
func (x *Expr) GetSelectExpr() *Expr_Select {
- if x, ok := x.GetExprKind().(*Expr_SelectExpr); ok {
- return x.SelectExpr
+ if x != nil {
+ if x, ok := x.ExprKind.(*Expr_SelectExpr); ok {
+ return x.SelectExpr
+ }
}
return nil
}
func (x *Expr) GetCallExpr() *Expr_Call {
- if x, ok := x.GetExprKind().(*Expr_CallExpr); ok {
- return x.CallExpr
+ if x != nil {
+ if x, ok := x.ExprKind.(*Expr_CallExpr); ok {
+ return x.CallExpr
+ }
}
return nil
}
func (x *Expr) GetListExpr() *Expr_CreateList {
- if x, ok := x.GetExprKind().(*Expr_ListExpr); ok {
- return x.ListExpr
+ if x != nil {
+ if x, ok := x.ExprKind.(*Expr_ListExpr); ok {
+ return x.ListExpr
+ }
}
return nil
}
func (x *Expr) GetStructExpr() *Expr_CreateStruct {
- if x, ok := x.GetExprKind().(*Expr_StructExpr); ok {
- return x.StructExpr
+ if x != nil {
+ if x, ok := x.ExprKind.(*Expr_StructExpr); ok {
+ return x.StructExpr
+ }
}
return nil
}
func (x *Expr) GetComprehensionExpr() *Expr_Comprehension {
- if x, ok := x.GetExprKind().(*Expr_ComprehensionExpr); ok {
- return x.ComprehensionExpr
+ if x != nil {
+ if x, ok := x.ExprKind.(*Expr_ComprehensionExpr); ok {
+ return x.ComprehensionExpr
+ }
}
return nil
}
@@ -290,11 +299,8 @@ func (*Expr_StructExpr) isExpr_ExprKind() {}
func (*Expr_ComprehensionExpr) isExpr_ExprKind() {}
type Constant struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
- // Types that are assignable to ConstantKind:
+ state protoimpl.MessageState `protogen:"open.v1"`
+ // Types that are valid to be assigned to ConstantKind:
//
// *Constant_NullValue
// *Constant_BoolValue
@@ -305,16 +311,16 @@ type Constant struct {
// *Constant_BytesValue
// *Constant_DurationValue
// *Constant_TimestampValue
- ConstantKind isConstant_ConstantKind `protobuf_oneof:"constant_kind"`
+ ConstantKind isConstant_ConstantKind `protobuf_oneof:"constant_kind"`
+ unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *Constant) Reset() {
*x = Constant{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_syntax_proto_msgTypes[2]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_syntax_proto_msgTypes[2]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Constant) String() string {
@@ -325,7 +331,7 @@ func (*Constant) ProtoMessage() {}
func (x *Constant) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_syntax_proto_msgTypes[2]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -340,74 +346,92 @@ func (*Constant) Descriptor() ([]byte, []int) {
return file_cel_expr_syntax_proto_rawDescGZIP(), []int{2}
}
-func (m *Constant) GetConstantKind() isConstant_ConstantKind {
- if m != nil {
- return m.ConstantKind
+func (x *Constant) GetConstantKind() isConstant_ConstantKind {
+ if x != nil {
+ return x.ConstantKind
}
return nil
}
func (x *Constant) GetNullValue() structpb.NullValue {
- if x, ok := x.GetConstantKind().(*Constant_NullValue); ok {
- return x.NullValue
+ if x != nil {
+ if x, ok := x.ConstantKind.(*Constant_NullValue); ok {
+ return x.NullValue
+ }
}
return structpb.NullValue(0)
}
func (x *Constant) GetBoolValue() bool {
- if x, ok := x.GetConstantKind().(*Constant_BoolValue); ok {
- return x.BoolValue
+ if x != nil {
+ if x, ok := x.ConstantKind.(*Constant_BoolValue); ok {
+ return x.BoolValue
+ }
}
return false
}
func (x *Constant) GetInt64Value() int64 {
- if x, ok := x.GetConstantKind().(*Constant_Int64Value); ok {
- return x.Int64Value
+ if x != nil {
+ if x, ok := x.ConstantKind.(*Constant_Int64Value); ok {
+ return x.Int64Value
+ }
}
return 0
}
func (x *Constant) GetUint64Value() uint64 {
- if x, ok := x.GetConstantKind().(*Constant_Uint64Value); ok {
- return x.Uint64Value
+ if x != nil {
+ if x, ok := x.ConstantKind.(*Constant_Uint64Value); ok {
+ return x.Uint64Value
+ }
}
return 0
}
func (x *Constant) GetDoubleValue() float64 {
- if x, ok := x.GetConstantKind().(*Constant_DoubleValue); ok {
- return x.DoubleValue
+ if x != nil {
+ if x, ok := x.ConstantKind.(*Constant_DoubleValue); ok {
+ return x.DoubleValue
+ }
}
return 0
}
func (x *Constant) GetStringValue() string {
- if x, ok := x.GetConstantKind().(*Constant_StringValue); ok {
- return x.StringValue
+ if x != nil {
+ if x, ok := x.ConstantKind.(*Constant_StringValue); ok {
+ return x.StringValue
+ }
}
return ""
}
func (x *Constant) GetBytesValue() []byte {
- if x, ok := x.GetConstantKind().(*Constant_BytesValue); ok {
- return x.BytesValue
+ if x != nil {
+ if x, ok := x.ConstantKind.(*Constant_BytesValue); ok {
+ return x.BytesValue
+ }
}
return nil
}
-// Deprecated: Do not use.
+// Deprecated: Marked as deprecated in cel/expr/syntax.proto.
func (x *Constant) GetDurationValue() *durationpb.Duration {
- if x, ok := x.GetConstantKind().(*Constant_DurationValue); ok {
- return x.DurationValue
+ if x != nil {
+ if x, ok := x.ConstantKind.(*Constant_DurationValue); ok {
+ return x.DurationValue
+ }
}
return nil
}
-// Deprecated: Do not use.
+// Deprecated: Marked as deprecated in cel/expr/syntax.proto.
func (x *Constant) GetTimestampValue() *timestamppb.Timestamp {
- if x, ok := x.GetConstantKind().(*Constant_TimestampValue); ok {
- return x.TimestampValue
+ if x != nil {
+ if x, ok := x.ConstantKind.(*Constant_TimestampValue); ok {
+ return x.TimestampValue
+ }
}
return nil
}
@@ -445,12 +469,12 @@ type Constant_BytesValue struct {
}
type Constant_DurationValue struct {
- // Deprecated: Do not use.
+ // Deprecated: Marked as deprecated in cel/expr/syntax.proto.
DurationValue *durationpb.Duration `protobuf:"bytes,8,opt,name=duration_value,json=durationValue,proto3,oneof"`
}
type Constant_TimestampValue struct {
- // Deprecated: Do not use.
+ // Deprecated: Marked as deprecated in cel/expr/syntax.proto.
TimestampValue *timestamppb.Timestamp `protobuf:"bytes,9,opt,name=timestamp_value,json=timestampValue,proto3,oneof"`
}
@@ -473,25 +497,22 @@ func (*Constant_DurationValue) isConstant_ConstantKind() {}
func (*Constant_TimestampValue) isConstant_ConstantKind() {}
type SourceInfo struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
+ state protoimpl.MessageState `protogen:"open.v1"`
SyntaxVersion string `protobuf:"bytes,1,opt,name=syntax_version,json=syntaxVersion,proto3" json:"syntax_version,omitempty"`
Location string `protobuf:"bytes,2,opt,name=location,proto3" json:"location,omitempty"`
LineOffsets []int32 `protobuf:"varint,3,rep,packed,name=line_offsets,json=lineOffsets,proto3" json:"line_offsets,omitempty"`
- Positions map[int64]int32 `protobuf:"bytes,4,rep,name=positions,proto3" json:"positions,omitempty" protobuf_key:"varint,1,opt,name=key,proto3" protobuf_val:"varint,2,opt,name=value,proto3"`
- MacroCalls map[int64]*Expr `protobuf:"bytes,5,rep,name=macro_calls,json=macroCalls,proto3" json:"macro_calls,omitempty" protobuf_key:"varint,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
+ Positions map[int64]int32 `protobuf:"bytes,4,rep,name=positions,proto3" json:"positions,omitempty" protobuf_key:"varint,1,opt,name=key" protobuf_val:"varint,2,opt,name=value"`
+ MacroCalls map[int64]*Expr `protobuf:"bytes,5,rep,name=macro_calls,json=macroCalls,proto3" json:"macro_calls,omitempty" protobuf_key:"varint,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"`
Extensions []*SourceInfo_Extension `protobuf:"bytes,6,rep,name=extensions,proto3" json:"extensions,omitempty"`
+ unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *SourceInfo) Reset() {
*x = SourceInfo{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_syntax_proto_msgTypes[3]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_syntax_proto_msgTypes[3]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *SourceInfo) String() string {
@@ -502,7 +523,7 @@ func (*SourceInfo) ProtoMessage() {}
func (x *SourceInfo) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_syntax_proto_msgTypes[3]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -560,20 +581,17 @@ func (x *SourceInfo) GetExtensions() []*SourceInfo_Extension {
}
type Expr_Ident struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
+ Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
unknownFields protoimpl.UnknownFields
-
- Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
+ sizeCache protoimpl.SizeCache
}
func (x *Expr_Ident) Reset() {
*x = Expr_Ident{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_syntax_proto_msgTypes[4]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_syntax_proto_msgTypes[4]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Expr_Ident) String() string {
@@ -584,7 +602,7 @@ func (*Expr_Ident) ProtoMessage() {}
func (x *Expr_Ident) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_syntax_proto_msgTypes[4]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -607,22 +625,19 @@ func (x *Expr_Ident) GetName() string {
}
type Expr_Select struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
+ Operand *Expr `protobuf:"bytes,1,opt,name=operand,proto3" json:"operand,omitempty"`
+ Field string `protobuf:"bytes,2,opt,name=field,proto3" json:"field,omitempty"`
+ TestOnly bool `protobuf:"varint,3,opt,name=test_only,json=testOnly,proto3" json:"test_only,omitempty"`
unknownFields protoimpl.UnknownFields
-
- Operand *Expr `protobuf:"bytes,1,opt,name=operand,proto3" json:"operand,omitempty"`
- Field string `protobuf:"bytes,2,opt,name=field,proto3" json:"field,omitempty"`
- TestOnly bool `protobuf:"varint,3,opt,name=test_only,json=testOnly,proto3" json:"test_only,omitempty"`
+ sizeCache protoimpl.SizeCache
}
func (x *Expr_Select) Reset() {
*x = Expr_Select{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_syntax_proto_msgTypes[5]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_syntax_proto_msgTypes[5]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Expr_Select) String() string {
@@ -633,7 +648,7 @@ func (*Expr_Select) ProtoMessage() {}
func (x *Expr_Select) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_syntax_proto_msgTypes[5]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -670,22 +685,19 @@ func (x *Expr_Select) GetTestOnly() bool {
}
type Expr_Call struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
+ Target *Expr `protobuf:"bytes,1,opt,name=target,proto3" json:"target,omitempty"`
+ Function string `protobuf:"bytes,2,opt,name=function,proto3" json:"function,omitempty"`
+ Args []*Expr `protobuf:"bytes,3,rep,name=args,proto3" json:"args,omitempty"`
unknownFields protoimpl.UnknownFields
-
- Target *Expr `protobuf:"bytes,1,opt,name=target,proto3" json:"target,omitempty"`
- Function string `protobuf:"bytes,2,opt,name=function,proto3" json:"function,omitempty"`
- Args []*Expr `protobuf:"bytes,3,rep,name=args,proto3" json:"args,omitempty"`
+ sizeCache protoimpl.SizeCache
}
func (x *Expr_Call) Reset() {
*x = Expr_Call{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_syntax_proto_msgTypes[6]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_syntax_proto_msgTypes[6]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Expr_Call) String() string {
@@ -696,7 +708,7 @@ func (*Expr_Call) ProtoMessage() {}
func (x *Expr_Call) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_syntax_proto_msgTypes[6]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -733,21 +745,18 @@ func (x *Expr_Call) GetArgs() []*Expr {
}
type Expr_CreateList struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
- Elements []*Expr `protobuf:"bytes,1,rep,name=elements,proto3" json:"elements,omitempty"`
- OptionalIndices []int32 `protobuf:"varint,2,rep,packed,name=optional_indices,json=optionalIndices,proto3" json:"optional_indices,omitempty"`
+ state protoimpl.MessageState `protogen:"open.v1"`
+ Elements []*Expr `protobuf:"bytes,1,rep,name=elements,proto3" json:"elements,omitempty"`
+ OptionalIndices []int32 `protobuf:"varint,2,rep,packed,name=optional_indices,json=optionalIndices,proto3" json:"optional_indices,omitempty"`
+ unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *Expr_CreateList) Reset() {
*x = Expr_CreateList{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_syntax_proto_msgTypes[7]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_syntax_proto_msgTypes[7]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Expr_CreateList) String() string {
@@ -758,7 +767,7 @@ func (*Expr_CreateList) ProtoMessage() {}
func (x *Expr_CreateList) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_syntax_proto_msgTypes[7]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -788,21 +797,18 @@ func (x *Expr_CreateList) GetOptionalIndices() []int32 {
}
type Expr_CreateStruct struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
+ MessageName string `protobuf:"bytes,1,opt,name=message_name,json=messageName,proto3" json:"message_name,omitempty"`
+ Entries []*Expr_CreateStruct_Entry `protobuf:"bytes,2,rep,name=entries,proto3" json:"entries,omitempty"`
unknownFields protoimpl.UnknownFields
-
- MessageName string `protobuf:"bytes,1,opt,name=message_name,json=messageName,proto3" json:"message_name,omitempty"`
- Entries []*Expr_CreateStruct_Entry `protobuf:"bytes,2,rep,name=entries,proto3" json:"entries,omitempty"`
+ sizeCache protoimpl.SizeCache
}
func (x *Expr_CreateStruct) Reset() {
*x = Expr_CreateStruct{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_syntax_proto_msgTypes[8]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_syntax_proto_msgTypes[8]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Expr_CreateStruct) String() string {
@@ -813,7 +819,7 @@ func (*Expr_CreateStruct) ProtoMessage() {}
func (x *Expr_CreateStruct) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_syntax_proto_msgTypes[8]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -843,26 +849,24 @@ func (x *Expr_CreateStruct) GetEntries() []*Expr_CreateStruct_Entry {
}
type Expr_Comprehension struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
+ IterVar string `protobuf:"bytes,1,opt,name=iter_var,json=iterVar,proto3" json:"iter_var,omitempty"`
+ IterVar2 string `protobuf:"bytes,8,opt,name=iter_var2,json=iterVar2,proto3" json:"iter_var2,omitempty"`
+ IterRange *Expr `protobuf:"bytes,2,opt,name=iter_range,json=iterRange,proto3" json:"iter_range,omitempty"`
+ AccuVar string `protobuf:"bytes,3,opt,name=accu_var,json=accuVar,proto3" json:"accu_var,omitempty"`
+ AccuInit *Expr `protobuf:"bytes,4,opt,name=accu_init,json=accuInit,proto3" json:"accu_init,omitempty"`
+ LoopCondition *Expr `protobuf:"bytes,5,opt,name=loop_condition,json=loopCondition,proto3" json:"loop_condition,omitempty"`
+ LoopStep *Expr `protobuf:"bytes,6,opt,name=loop_step,json=loopStep,proto3" json:"loop_step,omitempty"`
+ Result *Expr `protobuf:"bytes,7,opt,name=result,proto3" json:"result,omitempty"`
unknownFields protoimpl.UnknownFields
-
- IterVar string `protobuf:"bytes,1,opt,name=iter_var,json=iterVar,proto3" json:"iter_var,omitempty"`
- IterRange *Expr `protobuf:"bytes,2,opt,name=iter_range,json=iterRange,proto3" json:"iter_range,omitempty"`
- AccuVar string `protobuf:"bytes,3,opt,name=accu_var,json=accuVar,proto3" json:"accu_var,omitempty"`
- AccuInit *Expr `protobuf:"bytes,4,opt,name=accu_init,json=accuInit,proto3" json:"accu_init,omitempty"`
- LoopCondition *Expr `protobuf:"bytes,5,opt,name=loop_condition,json=loopCondition,proto3" json:"loop_condition,omitempty"`
- LoopStep *Expr `protobuf:"bytes,6,opt,name=loop_step,json=loopStep,proto3" json:"loop_step,omitempty"`
- Result *Expr `protobuf:"bytes,7,opt,name=result,proto3" json:"result,omitempty"`
+ sizeCache protoimpl.SizeCache
}
func (x *Expr_Comprehension) Reset() {
*x = Expr_Comprehension{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_syntax_proto_msgTypes[9]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_syntax_proto_msgTypes[9]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Expr_Comprehension) String() string {
@@ -873,7 +877,7 @@ func (*Expr_Comprehension) ProtoMessage() {}
func (x *Expr_Comprehension) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_syntax_proto_msgTypes[9]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -895,6 +899,13 @@ func (x *Expr_Comprehension) GetIterVar() string {
return ""
}
+func (x *Expr_Comprehension) GetIterVar2() string {
+ if x != nil {
+ return x.IterVar2
+ }
+ return ""
+}
+
func (x *Expr_Comprehension) GetIterRange() *Expr {
if x != nil {
return x.IterRange
@@ -938,27 +949,24 @@ func (x *Expr_Comprehension) GetResult() *Expr {
}
type Expr_CreateStruct_Entry struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
- Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
- // Types that are assignable to KeyKind:
+ state protoimpl.MessageState `protogen:"open.v1"`
+ Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
+ // Types that are valid to be assigned to KeyKind:
//
// *Expr_CreateStruct_Entry_FieldKey
// *Expr_CreateStruct_Entry_MapKey
KeyKind isExpr_CreateStruct_Entry_KeyKind `protobuf_oneof:"key_kind"`
Value *Expr `protobuf:"bytes,4,opt,name=value,proto3" json:"value,omitempty"`
OptionalEntry bool `protobuf:"varint,5,opt,name=optional_entry,json=optionalEntry,proto3" json:"optional_entry,omitempty"`
+ unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *Expr_CreateStruct_Entry) Reset() {
*x = Expr_CreateStruct_Entry{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_syntax_proto_msgTypes[10]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_syntax_proto_msgTypes[10]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Expr_CreateStruct_Entry) String() string {
@@ -969,7 +977,7 @@ func (*Expr_CreateStruct_Entry) ProtoMessage() {}
func (x *Expr_CreateStruct_Entry) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_syntax_proto_msgTypes[10]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -991,23 +999,27 @@ func (x *Expr_CreateStruct_Entry) GetId() int64 {
return 0
}
-func (m *Expr_CreateStruct_Entry) GetKeyKind() isExpr_CreateStruct_Entry_KeyKind {
- if m != nil {
- return m.KeyKind
+func (x *Expr_CreateStruct_Entry) GetKeyKind() isExpr_CreateStruct_Entry_KeyKind {
+ if x != nil {
+ return x.KeyKind
}
return nil
}
func (x *Expr_CreateStruct_Entry) GetFieldKey() string {
- if x, ok := x.GetKeyKind().(*Expr_CreateStruct_Entry_FieldKey); ok {
- return x.FieldKey
+ if x != nil {
+ if x, ok := x.KeyKind.(*Expr_CreateStruct_Entry_FieldKey); ok {
+ return x.FieldKey
+ }
}
return ""
}
func (x *Expr_CreateStruct_Entry) GetMapKey() *Expr {
- if x, ok := x.GetKeyKind().(*Expr_CreateStruct_Entry_MapKey); ok {
- return x.MapKey
+ if x != nil {
+ if x, ok := x.KeyKind.(*Expr_CreateStruct_Entry_MapKey); ok {
+ return x.MapKey
+ }
}
return nil
}
@@ -1043,22 +1055,19 @@ func (*Expr_CreateStruct_Entry_FieldKey) isExpr_CreateStruct_Entry_KeyKind() {}
func (*Expr_CreateStruct_Entry_MapKey) isExpr_CreateStruct_Entry_KeyKind() {}
type SourceInfo_Extension struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
+ state protoimpl.MessageState `protogen:"open.v1"`
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
AffectedComponents []SourceInfo_Extension_Component `protobuf:"varint,2,rep,packed,name=affected_components,json=affectedComponents,proto3,enum=cel.expr.SourceInfo_Extension_Component" json:"affected_components,omitempty"`
Version *SourceInfo_Extension_Version `protobuf:"bytes,3,opt,name=version,proto3" json:"version,omitempty"`
+ unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *SourceInfo_Extension) Reset() {
*x = SourceInfo_Extension{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_syntax_proto_msgTypes[13]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_syntax_proto_msgTypes[13]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *SourceInfo_Extension) String() string {
@@ -1069,7 +1078,7 @@ func (*SourceInfo_Extension) ProtoMessage() {}
func (x *SourceInfo_Extension) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_syntax_proto_msgTypes[13]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -1106,21 +1115,18 @@ func (x *SourceInfo_Extension) GetVersion() *SourceInfo_Extension_Version {
}
type SourceInfo_Extension_Version struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
+ Major int64 `protobuf:"varint,1,opt,name=major,proto3" json:"major,omitempty"`
+ Minor int64 `protobuf:"varint,2,opt,name=minor,proto3" json:"minor,omitempty"`
unknownFields protoimpl.UnknownFields
-
- Major int64 `protobuf:"varint,1,opt,name=major,proto3" json:"major,omitempty"`
- Minor int64 `protobuf:"varint,2,opt,name=minor,proto3" json:"minor,omitempty"`
+ sizeCache protoimpl.SizeCache
}
func (x *SourceInfo_Extension_Version) Reset() {
*x = SourceInfo_Extension_Version{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_syntax_proto_msgTypes[14]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_syntax_proto_msgTypes[14]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *SourceInfo_Extension_Version) String() string {
@@ -1131,7 +1137,7 @@ func (*SourceInfo_Extension_Version) ProtoMessage() {}
func (x *SourceInfo_Extension_Version) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_syntax_proto_msgTypes[14]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -1162,210 +1168,124 @@ func (x *SourceInfo_Extension_Version) GetMinor() int64 {
var File_cel_expr_syntax_proto protoreflect.FileDescriptor
-var file_cel_expr_syntax_proto_rawDesc = []byte{
- 0x0a, 0x15, 0x63, 0x65, 0x6c, 0x2f, 0x65, 0x78, 0x70, 0x72, 0x2f, 0x73, 0x79, 0x6e, 0x74, 0x61,
- 0x78, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x08, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70,
- 0x72, 0x1a, 0x1e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62,
- 0x75, 0x66, 0x2f, 0x64, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74,
- 0x6f, 0x1a, 0x1c, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62,
- 0x75, 0x66, 0x2f, 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a,
- 0x1f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66,
- 0x2f, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f,
- 0x22, 0x67, 0x0a, 0x0a, 0x50, 0x61, 0x72, 0x73, 0x65, 0x64, 0x45, 0x78, 0x70, 0x72, 0x12, 0x22,
- 0x0a, 0x04, 0x65, 0x78, 0x70, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x63,
- 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x45, 0x78, 0x70, 0x72, 0x52, 0x04, 0x65, 0x78,
- 0x70, 0x72, 0x12, 0x35, 0x0a, 0x0b, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x5f, 0x69, 0x6e, 0x66,
- 0x6f, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78,
- 0x70, 0x72, 0x2e, 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x0a, 0x73,
- 0x6f, 0x75, 0x72, 0x63, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x22, 0xfd, 0x0a, 0x0a, 0x04, 0x45, 0x78,
- 0x70, 0x72, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02,
- 0x69, 0x64, 0x12, 0x33, 0x0a, 0x0a, 0x63, 0x6f, 0x6e, 0x73, 0x74, 0x5f, 0x65, 0x78, 0x70, 0x72,
- 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70,
- 0x72, 0x2e, 0x43, 0x6f, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x74, 0x48, 0x00, 0x52, 0x09, 0x63, 0x6f,
- 0x6e, 0x73, 0x74, 0x45, 0x78, 0x70, 0x72, 0x12, 0x35, 0x0a, 0x0a, 0x69, 0x64, 0x65, 0x6e, 0x74,
- 0x5f, 0x65, 0x78, 0x70, 0x72, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x63, 0x65,
- 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x45, 0x78, 0x70, 0x72, 0x2e, 0x49, 0x64, 0x65, 0x6e,
- 0x74, 0x48, 0x00, 0x52, 0x09, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x45, 0x78, 0x70, 0x72, 0x12, 0x38,
- 0x0a, 0x0b, 0x73, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x5f, 0x65, 0x78, 0x70, 0x72, 0x18, 0x05, 0x20,
- 0x01, 0x28, 0x0b, 0x32, 0x15, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x45,
- 0x78, 0x70, 0x72, 0x2e, 0x53, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x48, 0x00, 0x52, 0x0a, 0x73, 0x65,
- 0x6c, 0x65, 0x63, 0x74, 0x45, 0x78, 0x70, 0x72, 0x12, 0x32, 0x0a, 0x09, 0x63, 0x61, 0x6c, 0x6c,
- 0x5f, 0x65, 0x78, 0x70, 0x72, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x13, 0x2e, 0x63, 0x65,
- 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x45, 0x78, 0x70, 0x72, 0x2e, 0x43, 0x61, 0x6c, 0x6c,
- 0x48, 0x00, 0x52, 0x08, 0x63, 0x61, 0x6c, 0x6c, 0x45, 0x78, 0x70, 0x72, 0x12, 0x38, 0x0a, 0x09,
- 0x6c, 0x69, 0x73, 0x74, 0x5f, 0x65, 0x78, 0x70, 0x72, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0b, 0x32,
- 0x19, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x45, 0x78, 0x70, 0x72, 0x2e,
- 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x48, 0x00, 0x52, 0x08, 0x6c, 0x69,
- 0x73, 0x74, 0x45, 0x78, 0x70, 0x72, 0x12, 0x3e, 0x0a, 0x0b, 0x73, 0x74, 0x72, 0x75, 0x63, 0x74,
- 0x5f, 0x65, 0x78, 0x70, 0x72, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x63, 0x65,
- 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x45, 0x78, 0x70, 0x72, 0x2e, 0x43, 0x72, 0x65, 0x61,
- 0x74, 0x65, 0x53, 0x74, 0x72, 0x75, 0x63, 0x74, 0x48, 0x00, 0x52, 0x0a, 0x73, 0x74, 0x72, 0x75,
- 0x63, 0x74, 0x45, 0x78, 0x70, 0x72, 0x12, 0x4d, 0x0a, 0x12, 0x63, 0x6f, 0x6d, 0x70, 0x72, 0x65,
- 0x68, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x5f, 0x65, 0x78, 0x70, 0x72, 0x18, 0x09, 0x20, 0x01,
- 0x28, 0x0b, 0x32, 0x1c, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x45, 0x78,
- 0x70, 0x72, 0x2e, 0x43, 0x6f, 0x6d, 0x70, 0x72, 0x65, 0x68, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e,
- 0x48, 0x00, 0x52, 0x11, 0x63, 0x6f, 0x6d, 0x70, 0x72, 0x65, 0x68, 0x65, 0x6e, 0x73, 0x69, 0x6f,
- 0x6e, 0x45, 0x78, 0x70, 0x72, 0x1a, 0x1b, 0x0a, 0x05, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x12, 0x12,
- 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61,
- 0x6d, 0x65, 0x1a, 0x65, 0x0a, 0x06, 0x53, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x12, 0x28, 0x0a, 0x07,
- 0x6f, 0x70, 0x65, 0x72, 0x61, 0x6e, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e,
- 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x45, 0x78, 0x70, 0x72, 0x52, 0x07, 0x6f,
- 0x70, 0x65, 0x72, 0x61, 0x6e, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x18,
- 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x12, 0x1b, 0x0a, 0x09,
- 0x74, 0x65, 0x73, 0x74, 0x5f, 0x6f, 0x6e, 0x6c, 0x79, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x52,
- 0x08, 0x74, 0x65, 0x73, 0x74, 0x4f, 0x6e, 0x6c, 0x79, 0x1a, 0x6e, 0x0a, 0x04, 0x43, 0x61, 0x6c,
- 0x6c, 0x12, 0x26, 0x0a, 0x06, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28,
- 0x0b, 0x32, 0x0e, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x45, 0x78, 0x70,
- 0x72, 0x52, 0x06, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x12, 0x1a, 0x0a, 0x08, 0x66, 0x75, 0x6e,
- 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x66, 0x75, 0x6e,
- 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x22, 0x0a, 0x04, 0x61, 0x72, 0x67, 0x73, 0x18, 0x03, 0x20,
- 0x03, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x45,
- 0x78, 0x70, 0x72, 0x52, 0x04, 0x61, 0x72, 0x67, 0x73, 0x1a, 0x63, 0x0a, 0x0a, 0x43, 0x72, 0x65,
- 0x61, 0x74, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x2a, 0x0a, 0x08, 0x65, 0x6c, 0x65, 0x6d, 0x65,
- 0x6e, 0x74, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x63, 0x65, 0x6c, 0x2e,
- 0x65, 0x78, 0x70, 0x72, 0x2e, 0x45, 0x78, 0x70, 0x72, 0x52, 0x08, 0x65, 0x6c, 0x65, 0x6d, 0x65,
- 0x6e, 0x74, 0x73, 0x12, 0x29, 0x0a, 0x10, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x61, 0x6c, 0x5f,
- 0x69, 0x6e, 0x64, 0x69, 0x63, 0x65, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x05, 0x52, 0x0f, 0x6f,
- 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x61, 0x6c, 0x49, 0x6e, 0x64, 0x69, 0x63, 0x65, 0x73, 0x1a, 0xab,
- 0x02, 0x0a, 0x0c, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x53, 0x74, 0x72, 0x75, 0x63, 0x74, 0x12,
- 0x21, 0x0a, 0x0c, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18,
- 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x4e, 0x61,
- 0x6d, 0x65, 0x12, 0x3b, 0x0a, 0x07, 0x65, 0x6e, 0x74, 0x72, 0x69, 0x65, 0x73, 0x18, 0x02, 0x20,
- 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x45,
- 0x78, 0x70, 0x72, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x53, 0x74, 0x72, 0x75, 0x63, 0x74,
- 0x2e, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x07, 0x65, 0x6e, 0x74, 0x72, 0x69, 0x65, 0x73, 0x1a,
- 0xba, 0x01, 0x0a, 0x05, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18,
- 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x1d, 0x0a, 0x09, 0x66, 0x69, 0x65,
- 0x6c, 0x64, 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x48, 0x00, 0x52, 0x08,
- 0x66, 0x69, 0x65, 0x6c, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x29, 0x0a, 0x07, 0x6d, 0x61, 0x70, 0x5f,
- 0x6b, 0x65, 0x79, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x63, 0x65, 0x6c, 0x2e,
- 0x65, 0x78, 0x70, 0x72, 0x2e, 0x45, 0x78, 0x70, 0x72, 0x48, 0x00, 0x52, 0x06, 0x6d, 0x61, 0x70,
- 0x4b, 0x65, 0x79, 0x12, 0x24, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x04, 0x20, 0x01,
- 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x45, 0x78,
- 0x70, 0x72, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x25, 0x0a, 0x0e, 0x6f, 0x70, 0x74,
- 0x69, 0x6f, 0x6e, 0x61, 0x6c, 0x5f, 0x65, 0x6e, 0x74, 0x72, 0x79, 0x18, 0x05, 0x20, 0x01, 0x28,
- 0x08, 0x52, 0x0d, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x61, 0x6c, 0x45, 0x6e, 0x74, 0x72, 0x79,
- 0x42, 0x0a, 0x0a, 0x08, 0x6b, 0x65, 0x79, 0x5f, 0x6b, 0x69, 0x6e, 0x64, 0x1a, 0xad, 0x02, 0x0a,
- 0x0d, 0x43, 0x6f, 0x6d, 0x70, 0x72, 0x65, 0x68, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x19,
- 0x0a, 0x08, 0x69, 0x74, 0x65, 0x72, 0x5f, 0x76, 0x61, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
- 0x52, 0x07, 0x69, 0x74, 0x65, 0x72, 0x56, 0x61, 0x72, 0x12, 0x2d, 0x0a, 0x0a, 0x69, 0x74, 0x65,
- 0x72, 0x5f, 0x72, 0x61, 0x6e, 0x67, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e,
- 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x45, 0x78, 0x70, 0x72, 0x52, 0x09, 0x69,
- 0x74, 0x65, 0x72, 0x52, 0x61, 0x6e, 0x67, 0x65, 0x12, 0x19, 0x0a, 0x08, 0x61, 0x63, 0x63, 0x75,
- 0x5f, 0x76, 0x61, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x61, 0x63, 0x63, 0x75,
- 0x56, 0x61, 0x72, 0x12, 0x2b, 0x0a, 0x09, 0x61, 0x63, 0x63, 0x75, 0x5f, 0x69, 0x6e, 0x69, 0x74,
- 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70,
- 0x72, 0x2e, 0x45, 0x78, 0x70, 0x72, 0x52, 0x08, 0x61, 0x63, 0x63, 0x75, 0x49, 0x6e, 0x69, 0x74,
- 0x12, 0x35, 0x0a, 0x0e, 0x6c, 0x6f, 0x6f, 0x70, 0x5f, 0x63, 0x6f, 0x6e, 0x64, 0x69, 0x74, 0x69,
- 0x6f, 0x6e, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65,
- 0x78, 0x70, 0x72, 0x2e, 0x45, 0x78, 0x70, 0x72, 0x52, 0x0d, 0x6c, 0x6f, 0x6f, 0x70, 0x43, 0x6f,
- 0x6e, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x2b, 0x0a, 0x09, 0x6c, 0x6f, 0x6f, 0x70, 0x5f,
- 0x73, 0x74, 0x65, 0x70, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x63, 0x65, 0x6c,
- 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x45, 0x78, 0x70, 0x72, 0x52, 0x08, 0x6c, 0x6f, 0x6f, 0x70,
- 0x53, 0x74, 0x65, 0x70, 0x12, 0x26, 0x0a, 0x06, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x18, 0x07,
- 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e,
- 0x45, 0x78, 0x70, 0x72, 0x52, 0x06, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x42, 0x0b, 0x0a, 0x09,
- 0x65, 0x78, 0x70, 0x72, 0x5f, 0x6b, 0x69, 0x6e, 0x64, 0x22, 0xc1, 0x03, 0x0a, 0x08, 0x43, 0x6f,
- 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x74, 0x12, 0x3b, 0x0a, 0x0a, 0x6e, 0x75, 0x6c, 0x6c, 0x5f, 0x76,
- 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f,
- 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x4e, 0x75, 0x6c,
- 0x6c, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x48, 0x00, 0x52, 0x09, 0x6e, 0x75, 0x6c, 0x6c, 0x56, 0x61,
- 0x6c, 0x75, 0x65, 0x12, 0x1f, 0x0a, 0x0a, 0x62, 0x6f, 0x6f, 0x6c, 0x5f, 0x76, 0x61, 0x6c, 0x75,
- 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x48, 0x00, 0x52, 0x09, 0x62, 0x6f, 0x6f, 0x6c, 0x56,
- 0x61, 0x6c, 0x75, 0x65, 0x12, 0x21, 0x0a, 0x0b, 0x69, 0x6e, 0x74, 0x36, 0x34, 0x5f, 0x76, 0x61,
- 0x6c, 0x75, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x48, 0x00, 0x52, 0x0a, 0x69, 0x6e, 0x74,
- 0x36, 0x34, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x23, 0x0a, 0x0c, 0x75, 0x69, 0x6e, 0x74, 0x36,
- 0x34, 0x5f, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x04, 0x48, 0x00, 0x52,
- 0x0b, 0x75, 0x69, 0x6e, 0x74, 0x36, 0x34, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x23, 0x0a, 0x0c,
- 0x64, 0x6f, 0x75, 0x62, 0x6c, 0x65, 0x5f, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x05, 0x20, 0x01,
- 0x28, 0x01, 0x48, 0x00, 0x52, 0x0b, 0x64, 0x6f, 0x75, 0x62, 0x6c, 0x65, 0x56, 0x61, 0x6c, 0x75,
- 0x65, 0x12, 0x23, 0x0a, 0x0c, 0x73, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x5f, 0x76, 0x61, 0x6c, 0x75,
- 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x48, 0x00, 0x52, 0x0b, 0x73, 0x74, 0x72, 0x69, 0x6e,
- 0x67, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x21, 0x0a, 0x0b, 0x62, 0x79, 0x74, 0x65, 0x73, 0x5f,
- 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0c, 0x48, 0x00, 0x52, 0x0a, 0x62,
- 0x79, 0x74, 0x65, 0x73, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x46, 0x0a, 0x0e, 0x64, 0x75, 0x72,
- 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28,
- 0x0b, 0x32, 0x19, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f,
- 0x62, 0x75, 0x66, 0x2e, 0x44, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x02, 0x18, 0x01,
- 0x48, 0x00, 0x52, 0x0d, 0x64, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x56, 0x61, 0x6c, 0x75,
- 0x65, 0x12, 0x49, 0x0a, 0x0f, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x5f, 0x76,
- 0x61, 0x6c, 0x75, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f,
- 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d,
- 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x42, 0x02, 0x18, 0x01, 0x48, 0x00, 0x52, 0x0e, 0x74, 0x69,
- 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x42, 0x0f, 0x0a, 0x0d,
- 0x63, 0x6f, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x74, 0x5f, 0x6b, 0x69, 0x6e, 0x64, 0x22, 0xac, 0x06,
- 0x0a, 0x0a, 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x25, 0x0a, 0x0e,
- 0x73, 0x79, 0x6e, 0x74, 0x61, 0x78, 0x5f, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x01,
- 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x73, 0x79, 0x6e, 0x74, 0x61, 0x78, 0x56, 0x65, 0x72, 0x73,
- 0x69, 0x6f, 0x6e, 0x12, 0x1a, 0x0a, 0x08, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18,
- 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12,
- 0x21, 0x0a, 0x0c, 0x6c, 0x69, 0x6e, 0x65, 0x5f, 0x6f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x73, 0x18,
- 0x03, 0x20, 0x03, 0x28, 0x05, 0x52, 0x0b, 0x6c, 0x69, 0x6e, 0x65, 0x4f, 0x66, 0x66, 0x73, 0x65,
- 0x74, 0x73, 0x12, 0x41, 0x0a, 0x09, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18,
- 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x23, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72,
- 0x2e, 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x2e, 0x50, 0x6f, 0x73, 0x69,
- 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x09, 0x70, 0x6f, 0x73, 0x69,
- 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x45, 0x0a, 0x0b, 0x6d, 0x61, 0x63, 0x72, 0x6f, 0x5f, 0x63,
- 0x61, 0x6c, 0x6c, 0x73, 0x18, 0x05, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x63, 0x65, 0x6c,
- 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x49, 0x6e, 0x66, 0x6f,
- 0x2e, 0x4d, 0x61, 0x63, 0x72, 0x6f, 0x43, 0x61, 0x6c, 0x6c, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79,
- 0x52, 0x0a, 0x6d, 0x61, 0x63, 0x72, 0x6f, 0x43, 0x61, 0x6c, 0x6c, 0x73, 0x12, 0x3e, 0x0a, 0x0a,
- 0x65, 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x06, 0x20, 0x03, 0x28, 0x0b,
- 0x32, 0x1e, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x53, 0x6f, 0x75, 0x72,
- 0x63, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x2e, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e,
- 0x52, 0x0a, 0x65, 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x1a, 0x3c, 0x0a, 0x0e,
- 0x50, 0x6f, 0x73, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10,
- 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x03, 0x6b, 0x65, 0x79,
- 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52,
- 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x1a, 0x4d, 0x0a, 0x0f, 0x4d, 0x61,
- 0x63, 0x72, 0x6f, 0x43, 0x61, 0x6c, 0x6c, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a,
- 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12,
- 0x24, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e,
- 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x45, 0x78, 0x70, 0x72, 0x52, 0x05,
- 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x1a, 0xe0, 0x02, 0x0a, 0x09, 0x45, 0x78,
- 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20,
- 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x59, 0x0a, 0x13, 0x61, 0x66, 0x66, 0x65, 0x63,
- 0x74, 0x65, 0x64, 0x5f, 0x63, 0x6f, 0x6d, 0x70, 0x6f, 0x6e, 0x65, 0x6e, 0x74, 0x73, 0x18, 0x02,
- 0x20, 0x03, 0x28, 0x0e, 0x32, 0x28, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e,
- 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x2e, 0x45, 0x78, 0x74, 0x65, 0x6e,
- 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x43, 0x6f, 0x6d, 0x70, 0x6f, 0x6e, 0x65, 0x6e, 0x74, 0x52, 0x12,
- 0x61, 0x66, 0x66, 0x65, 0x63, 0x74, 0x65, 0x64, 0x43, 0x6f, 0x6d, 0x70, 0x6f, 0x6e, 0x65, 0x6e,
- 0x74, 0x73, 0x12, 0x40, 0x0a, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20,
- 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x53,
- 0x6f, 0x75, 0x72, 0x63, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x2e, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x73,
- 0x69, 0x6f, 0x6e, 0x2e, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x52, 0x07, 0x76, 0x65, 0x72,
- 0x73, 0x69, 0x6f, 0x6e, 0x1a, 0x35, 0x0a, 0x07, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12,
- 0x14, 0x0a, 0x05, 0x6d, 0x61, 0x6a, 0x6f, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05,
- 0x6d, 0x61, 0x6a, 0x6f, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x6d, 0x69, 0x6e, 0x6f, 0x72, 0x18, 0x02,
- 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x6d, 0x69, 0x6e, 0x6f, 0x72, 0x22, 0x6f, 0x0a, 0x09, 0x43,
- 0x6f, 0x6d, 0x70, 0x6f, 0x6e, 0x65, 0x6e, 0x74, 0x12, 0x19, 0x0a, 0x15, 0x43, 0x4f, 0x4d, 0x50,
- 0x4f, 0x4e, 0x45, 0x4e, 0x54, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45,
- 0x44, 0x10, 0x00, 0x12, 0x14, 0x0a, 0x10, 0x43, 0x4f, 0x4d, 0x50, 0x4f, 0x4e, 0x45, 0x4e, 0x54,
- 0x5f, 0x50, 0x41, 0x52, 0x53, 0x45, 0x52, 0x10, 0x01, 0x12, 0x1a, 0x0a, 0x16, 0x43, 0x4f, 0x4d,
- 0x50, 0x4f, 0x4e, 0x45, 0x4e, 0x54, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x43, 0x48, 0x45, 0x43,
- 0x4b, 0x45, 0x52, 0x10, 0x02, 0x12, 0x15, 0x0a, 0x11, 0x43, 0x4f, 0x4d, 0x50, 0x4f, 0x4e, 0x45,
- 0x4e, 0x54, 0x5f, 0x52, 0x55, 0x4e, 0x54, 0x49, 0x4d, 0x45, 0x10, 0x03, 0x42, 0x2e, 0x0a, 0x0c,
- 0x64, 0x65, 0x76, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x42, 0x0b, 0x53, 0x79,
- 0x6e, 0x74, 0x61, 0x78, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x0c, 0x63, 0x65, 0x6c,
- 0x2e, 0x64, 0x65, 0x76, 0x2f, 0x65, 0x78, 0x70, 0x72, 0xf8, 0x01, 0x01, 0x62, 0x06, 0x70, 0x72,
- 0x6f, 0x74, 0x6f, 0x33,
-}
+const file_cel_expr_syntax_proto_rawDesc = "" +
+ "\n" +
+ "\x15cel/expr/syntax.proto\x12\bcel.expr\x1a\x1egoogle/protobuf/duration.proto\x1a\x1cgoogle/protobuf/struct.proto\x1a\x1fgoogle/protobuf/timestamp.proto\"g\n" +
+ "\n" +
+ "ParsedExpr\x12\"\n" +
+ "\x04expr\x18\x02 \x01(\v2\x0e.cel.expr.ExprR\x04expr\x125\n" +
+ "\vsource_info\x18\x03 \x01(\v2\x14.cel.expr.SourceInfoR\n" +
+ "sourceInfo\"\x9a\v\n" +
+ "\x04Expr\x12\x0e\n" +
+ "\x02id\x18\x02 \x01(\x03R\x02id\x123\n" +
+ "\n" +
+ "const_expr\x18\x03 \x01(\v2\x12.cel.expr.ConstantH\x00R\tconstExpr\x125\n" +
+ "\n" +
+ "ident_expr\x18\x04 \x01(\v2\x14.cel.expr.Expr.IdentH\x00R\tidentExpr\x128\n" +
+ "\vselect_expr\x18\x05 \x01(\v2\x15.cel.expr.Expr.SelectH\x00R\n" +
+ "selectExpr\x122\n" +
+ "\tcall_expr\x18\x06 \x01(\v2\x13.cel.expr.Expr.CallH\x00R\bcallExpr\x128\n" +
+ "\tlist_expr\x18\a \x01(\v2\x19.cel.expr.Expr.CreateListH\x00R\blistExpr\x12>\n" +
+ "\vstruct_expr\x18\b \x01(\v2\x1b.cel.expr.Expr.CreateStructH\x00R\n" +
+ "structExpr\x12M\n" +
+ "\x12comprehension_expr\x18\t \x01(\v2\x1c.cel.expr.Expr.ComprehensionH\x00R\x11comprehensionExpr\x1a\x1b\n" +
+ "\x05Ident\x12\x12\n" +
+ "\x04name\x18\x01 \x01(\tR\x04name\x1ae\n" +
+ "\x06Select\x12(\n" +
+ "\aoperand\x18\x01 \x01(\v2\x0e.cel.expr.ExprR\aoperand\x12\x14\n" +
+ "\x05field\x18\x02 \x01(\tR\x05field\x12\x1b\n" +
+ "\ttest_only\x18\x03 \x01(\bR\btestOnly\x1an\n" +
+ "\x04Call\x12&\n" +
+ "\x06target\x18\x01 \x01(\v2\x0e.cel.expr.ExprR\x06target\x12\x1a\n" +
+ "\bfunction\x18\x02 \x01(\tR\bfunction\x12\"\n" +
+ "\x04args\x18\x03 \x03(\v2\x0e.cel.expr.ExprR\x04args\x1ac\n" +
+ "\n" +
+ "CreateList\x12*\n" +
+ "\belements\x18\x01 \x03(\v2\x0e.cel.expr.ExprR\belements\x12)\n" +
+ "\x10optional_indices\x18\x02 \x03(\x05R\x0foptionalIndices\x1a\xab\x02\n" +
+ "\fCreateStruct\x12!\n" +
+ "\fmessage_name\x18\x01 \x01(\tR\vmessageName\x12;\n" +
+ "\aentries\x18\x02 \x03(\v2!.cel.expr.Expr.CreateStruct.EntryR\aentries\x1a\xba\x01\n" +
+ "\x05Entry\x12\x0e\n" +
+ "\x02id\x18\x01 \x01(\x03R\x02id\x12\x1d\n" +
+ "\tfield_key\x18\x02 \x01(\tH\x00R\bfieldKey\x12)\n" +
+ "\amap_key\x18\x03 \x01(\v2\x0e.cel.expr.ExprH\x00R\x06mapKey\x12$\n" +
+ "\x05value\x18\x04 \x01(\v2\x0e.cel.expr.ExprR\x05value\x12%\n" +
+ "\x0eoptional_entry\x18\x05 \x01(\bR\roptionalEntryB\n" +
+ "\n" +
+ "\bkey_kind\x1a\xca\x02\n" +
+ "\rComprehension\x12\x19\n" +
+ "\biter_var\x18\x01 \x01(\tR\aiterVar\x12\x1b\n" +
+ "\titer_var2\x18\b \x01(\tR\biterVar2\x12-\n" +
+ "\n" +
+ "iter_range\x18\x02 \x01(\v2\x0e.cel.expr.ExprR\titerRange\x12\x19\n" +
+ "\baccu_var\x18\x03 \x01(\tR\aaccuVar\x12+\n" +
+ "\taccu_init\x18\x04 \x01(\v2\x0e.cel.expr.ExprR\baccuInit\x125\n" +
+ "\x0eloop_condition\x18\x05 \x01(\v2\x0e.cel.expr.ExprR\rloopCondition\x12+\n" +
+ "\tloop_step\x18\x06 \x01(\v2\x0e.cel.expr.ExprR\bloopStep\x12&\n" +
+ "\x06result\x18\a \x01(\v2\x0e.cel.expr.ExprR\x06resultB\v\n" +
+ "\texpr_kind\"\xc1\x03\n" +
+ "\bConstant\x12;\n" +
+ "\n" +
+ "null_value\x18\x01 \x01(\x0e2\x1a.google.protobuf.NullValueH\x00R\tnullValue\x12\x1f\n" +
+ "\n" +
+ "bool_value\x18\x02 \x01(\bH\x00R\tboolValue\x12!\n" +
+ "\vint64_value\x18\x03 \x01(\x03H\x00R\n" +
+ "int64Value\x12#\n" +
+ "\fuint64_value\x18\x04 \x01(\x04H\x00R\vuint64Value\x12#\n" +
+ "\fdouble_value\x18\x05 \x01(\x01H\x00R\vdoubleValue\x12#\n" +
+ "\fstring_value\x18\x06 \x01(\tH\x00R\vstringValue\x12!\n" +
+ "\vbytes_value\x18\a \x01(\fH\x00R\n" +
+ "bytesValue\x12F\n" +
+ "\x0eduration_value\x18\b \x01(\v2\x19.google.protobuf.DurationB\x02\x18\x01H\x00R\rdurationValue\x12I\n" +
+ "\x0ftimestamp_value\x18\t \x01(\v2\x1a.google.protobuf.TimestampB\x02\x18\x01H\x00R\x0etimestampValueB\x0f\n" +
+ "\rconstant_kind\"\xac\x06\n" +
+ "\n" +
+ "SourceInfo\x12%\n" +
+ "\x0esyntax_version\x18\x01 \x01(\tR\rsyntaxVersion\x12\x1a\n" +
+ "\blocation\x18\x02 \x01(\tR\blocation\x12!\n" +
+ "\fline_offsets\x18\x03 \x03(\x05R\vlineOffsets\x12A\n" +
+ "\tpositions\x18\x04 \x03(\v2#.cel.expr.SourceInfo.PositionsEntryR\tpositions\x12E\n" +
+ "\vmacro_calls\x18\x05 \x03(\v2$.cel.expr.SourceInfo.MacroCallsEntryR\n" +
+ "macroCalls\x12>\n" +
+ "\n" +
+ "extensions\x18\x06 \x03(\v2\x1e.cel.expr.SourceInfo.ExtensionR\n" +
+ "extensions\x1a<\n" +
+ "\x0ePositionsEntry\x12\x10\n" +
+ "\x03key\x18\x01 \x01(\x03R\x03key\x12\x14\n" +
+ "\x05value\x18\x02 \x01(\x05R\x05value:\x028\x01\x1aM\n" +
+ "\x0fMacroCallsEntry\x12\x10\n" +
+ "\x03key\x18\x01 \x01(\x03R\x03key\x12$\n" +
+ "\x05value\x18\x02 \x01(\v2\x0e.cel.expr.ExprR\x05value:\x028\x01\x1a\xe0\x02\n" +
+ "\tExtension\x12\x0e\n" +
+ "\x02id\x18\x01 \x01(\tR\x02id\x12Y\n" +
+ "\x13affected_components\x18\x02 \x03(\x0e2(.cel.expr.SourceInfo.Extension.ComponentR\x12affectedComponents\x12@\n" +
+ "\aversion\x18\x03 \x01(\v2&.cel.expr.SourceInfo.Extension.VersionR\aversion\x1a5\n" +
+ "\aVersion\x12\x14\n" +
+ "\x05major\x18\x01 \x01(\x03R\x05major\x12\x14\n" +
+ "\x05minor\x18\x02 \x01(\x03R\x05minor\"o\n" +
+ "\tComponent\x12\x19\n" +
+ "\x15COMPONENT_UNSPECIFIED\x10\x00\x12\x14\n" +
+ "\x10COMPONENT_PARSER\x10\x01\x12\x1a\n" +
+ "\x16COMPONENT_TYPE_CHECKER\x10\x02\x12\x15\n" +
+ "\x11COMPONENT_RUNTIME\x10\x03B.\n" +
+ "\fdev.cel.exprB\vSyntaxProtoP\x01Z\fcel.dev/expr\xf8\x01\x01b\x06proto3"
var (
file_cel_expr_syntax_proto_rawDescOnce sync.Once
- file_cel_expr_syntax_proto_rawDescData = file_cel_expr_syntax_proto_rawDesc
+ file_cel_expr_syntax_proto_rawDescData []byte
)
func file_cel_expr_syntax_proto_rawDescGZIP() []byte {
file_cel_expr_syntax_proto_rawDescOnce.Do(func() {
- file_cel_expr_syntax_proto_rawDescData = protoimpl.X.CompressGZIP(file_cel_expr_syntax_proto_rawDescData)
+ file_cel_expr_syntax_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_cel_expr_syntax_proto_rawDesc), len(file_cel_expr_syntax_proto_rawDesc)))
})
return file_cel_expr_syntax_proto_rawDescData
}
var file_cel_expr_syntax_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
var file_cel_expr_syntax_proto_msgTypes = make([]protoimpl.MessageInfo, 15)
-var file_cel_expr_syntax_proto_goTypes = []interface{}{
+var file_cel_expr_syntax_proto_goTypes = []any{
(SourceInfo_Extension_Component)(0), // 0: cel.expr.SourceInfo.Extension.Component
(*ParsedExpr)(nil), // 1: cel.expr.ParsedExpr
(*Expr)(nil), // 2: cel.expr.Expr
@@ -1429,165 +1349,7 @@ func file_cel_expr_syntax_proto_init() {
if File_cel_expr_syntax_proto != nil {
return
}
- if !protoimpl.UnsafeEnabled {
- file_cel_expr_syntax_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*ParsedExpr); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- file_cel_expr_syntax_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*Expr); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- file_cel_expr_syntax_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*Constant); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- file_cel_expr_syntax_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*SourceInfo); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- file_cel_expr_syntax_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*Expr_Ident); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- file_cel_expr_syntax_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*Expr_Select); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- file_cel_expr_syntax_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*Expr_Call); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- file_cel_expr_syntax_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*Expr_CreateList); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- file_cel_expr_syntax_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*Expr_CreateStruct); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- file_cel_expr_syntax_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*Expr_Comprehension); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- file_cel_expr_syntax_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*Expr_CreateStruct_Entry); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- file_cel_expr_syntax_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*SourceInfo_Extension); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- file_cel_expr_syntax_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*SourceInfo_Extension_Version); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- }
- file_cel_expr_syntax_proto_msgTypes[1].OneofWrappers = []interface{}{
+ file_cel_expr_syntax_proto_msgTypes[1].OneofWrappers = []any{
(*Expr_ConstExpr)(nil),
(*Expr_IdentExpr)(nil),
(*Expr_SelectExpr)(nil),
@@ -1596,7 +1358,7 @@ func file_cel_expr_syntax_proto_init() {
(*Expr_StructExpr)(nil),
(*Expr_ComprehensionExpr)(nil),
}
- file_cel_expr_syntax_proto_msgTypes[2].OneofWrappers = []interface{}{
+ file_cel_expr_syntax_proto_msgTypes[2].OneofWrappers = []any{
(*Constant_NullValue)(nil),
(*Constant_BoolValue)(nil),
(*Constant_Int64Value)(nil),
@@ -1607,7 +1369,7 @@ func file_cel_expr_syntax_proto_init() {
(*Constant_DurationValue)(nil),
(*Constant_TimestampValue)(nil),
}
- file_cel_expr_syntax_proto_msgTypes[10].OneofWrappers = []interface{}{
+ file_cel_expr_syntax_proto_msgTypes[10].OneofWrappers = []any{
(*Expr_CreateStruct_Entry_FieldKey)(nil),
(*Expr_CreateStruct_Entry_MapKey)(nil),
}
@@ -1615,7 +1377,7 @@ func file_cel_expr_syntax_proto_init() {
out := protoimpl.TypeBuilder{
File: protoimpl.DescBuilder{
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
- RawDescriptor: file_cel_expr_syntax_proto_rawDesc,
+ RawDescriptor: unsafe.Slice(unsafe.StringData(file_cel_expr_syntax_proto_rawDesc), len(file_cel_expr_syntax_proto_rawDesc)),
NumEnums: 1,
NumMessages: 15,
NumExtensions: 0,
@@ -1627,7 +1389,6 @@ func file_cel_expr_syntax_proto_init() {
MessageInfos: file_cel_expr_syntax_proto_msgTypes,
}.Build()
File_cel_expr_syntax_proto = out.File
- file_cel_expr_syntax_proto_rawDesc = nil
file_cel_expr_syntax_proto_goTypes = nil
file_cel_expr_syntax_proto_depIdxs = nil
}
diff --git a/vendor/cel.dev/expr/value.pb.go b/vendor/cel.dev/expr/value.pb.go
index e5e29228c2..1f53a6a296 100644
--- a/vendor/cel.dev/expr/value.pb.go
+++ b/vendor/cel.dev/expr/value.pb.go
@@ -1,7 +1,7 @@
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
-// protoc-gen-go v1.28.1
-// protoc v3.21.5
+// protoc-gen-go v1.36.10
+// protoc v5.27.1
// source: cel/expr/value.proto
package expr
@@ -13,6 +13,7 @@ import (
structpb "google.golang.org/protobuf/types/known/structpb"
reflect "reflect"
sync "sync"
+ unsafe "unsafe"
)
const (
@@ -23,11 +24,8 @@ const (
)
type Value struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
- // Types that are assignable to Kind:
+ state protoimpl.MessageState `protogen:"open.v1"`
+ // Types that are valid to be assigned to Kind:
//
// *Value_NullValue
// *Value_BoolValue
@@ -41,16 +39,16 @@ type Value struct {
// *Value_MapValue
// *Value_ListValue
// *Value_TypeValue
- Kind isValue_Kind `protobuf_oneof:"kind"`
+ Kind isValue_Kind `protobuf_oneof:"kind"`
+ unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *Value) Reset() {
*x = Value{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_value_proto_msgTypes[0]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_value_proto_msgTypes[0]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Value) String() string {
@@ -61,7 +59,7 @@ func (*Value) ProtoMessage() {}
func (x *Value) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_value_proto_msgTypes[0]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -76,93 +74,117 @@ func (*Value) Descriptor() ([]byte, []int) {
return file_cel_expr_value_proto_rawDescGZIP(), []int{0}
}
-func (m *Value) GetKind() isValue_Kind {
- if m != nil {
- return m.Kind
+func (x *Value) GetKind() isValue_Kind {
+ if x != nil {
+ return x.Kind
}
return nil
}
func (x *Value) GetNullValue() structpb.NullValue {
- if x, ok := x.GetKind().(*Value_NullValue); ok {
- return x.NullValue
+ if x != nil {
+ if x, ok := x.Kind.(*Value_NullValue); ok {
+ return x.NullValue
+ }
}
return structpb.NullValue(0)
}
func (x *Value) GetBoolValue() bool {
- if x, ok := x.GetKind().(*Value_BoolValue); ok {
- return x.BoolValue
+ if x != nil {
+ if x, ok := x.Kind.(*Value_BoolValue); ok {
+ return x.BoolValue
+ }
}
return false
}
func (x *Value) GetInt64Value() int64 {
- if x, ok := x.GetKind().(*Value_Int64Value); ok {
- return x.Int64Value
+ if x != nil {
+ if x, ok := x.Kind.(*Value_Int64Value); ok {
+ return x.Int64Value
+ }
}
return 0
}
func (x *Value) GetUint64Value() uint64 {
- if x, ok := x.GetKind().(*Value_Uint64Value); ok {
- return x.Uint64Value
+ if x != nil {
+ if x, ok := x.Kind.(*Value_Uint64Value); ok {
+ return x.Uint64Value
+ }
}
return 0
}
func (x *Value) GetDoubleValue() float64 {
- if x, ok := x.GetKind().(*Value_DoubleValue); ok {
- return x.DoubleValue
+ if x != nil {
+ if x, ok := x.Kind.(*Value_DoubleValue); ok {
+ return x.DoubleValue
+ }
}
return 0
}
func (x *Value) GetStringValue() string {
- if x, ok := x.GetKind().(*Value_StringValue); ok {
- return x.StringValue
+ if x != nil {
+ if x, ok := x.Kind.(*Value_StringValue); ok {
+ return x.StringValue
+ }
}
return ""
}
func (x *Value) GetBytesValue() []byte {
- if x, ok := x.GetKind().(*Value_BytesValue); ok {
- return x.BytesValue
+ if x != nil {
+ if x, ok := x.Kind.(*Value_BytesValue); ok {
+ return x.BytesValue
+ }
}
return nil
}
func (x *Value) GetEnumValue() *EnumValue {
- if x, ok := x.GetKind().(*Value_EnumValue); ok {
- return x.EnumValue
+ if x != nil {
+ if x, ok := x.Kind.(*Value_EnumValue); ok {
+ return x.EnumValue
+ }
}
return nil
}
func (x *Value) GetObjectValue() *anypb.Any {
- if x, ok := x.GetKind().(*Value_ObjectValue); ok {
- return x.ObjectValue
+ if x != nil {
+ if x, ok := x.Kind.(*Value_ObjectValue); ok {
+ return x.ObjectValue
+ }
}
return nil
}
func (x *Value) GetMapValue() *MapValue {
- if x, ok := x.GetKind().(*Value_MapValue); ok {
- return x.MapValue
+ if x != nil {
+ if x, ok := x.Kind.(*Value_MapValue); ok {
+ return x.MapValue
+ }
}
return nil
}
func (x *Value) GetListValue() *ListValue {
- if x, ok := x.GetKind().(*Value_ListValue); ok {
- return x.ListValue
+ if x != nil {
+ if x, ok := x.Kind.(*Value_ListValue); ok {
+ return x.ListValue
+ }
}
return nil
}
func (x *Value) GetTypeValue() string {
- if x, ok := x.GetKind().(*Value_TypeValue); ok {
- return x.TypeValue
+ if x != nil {
+ if x, ok := x.Kind.(*Value_TypeValue); ok {
+ return x.TypeValue
+ }
}
return ""
}
@@ -244,21 +266,18 @@ func (*Value_ListValue) isValue_Kind() {}
func (*Value_TypeValue) isValue_Kind() {}
type EnumValue struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
+ Type string `protobuf:"bytes,1,opt,name=type,proto3" json:"type,omitempty"`
+ Value int32 `protobuf:"varint,2,opt,name=value,proto3" json:"value,omitempty"`
unknownFields protoimpl.UnknownFields
-
- Type string `protobuf:"bytes,1,opt,name=type,proto3" json:"type,omitempty"`
- Value int32 `protobuf:"varint,2,opt,name=value,proto3" json:"value,omitempty"`
+ sizeCache protoimpl.SizeCache
}
func (x *EnumValue) Reset() {
*x = EnumValue{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_value_proto_msgTypes[1]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_value_proto_msgTypes[1]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *EnumValue) String() string {
@@ -269,7 +288,7 @@ func (*EnumValue) ProtoMessage() {}
func (x *EnumValue) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_value_proto_msgTypes[1]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -299,20 +318,17 @@ func (x *EnumValue) GetValue() int32 {
}
type ListValue struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
+ Values []*Value `protobuf:"bytes,1,rep,name=values,proto3" json:"values,omitempty"`
unknownFields protoimpl.UnknownFields
-
- Values []*Value `protobuf:"bytes,1,rep,name=values,proto3" json:"values,omitempty"`
+ sizeCache protoimpl.SizeCache
}
func (x *ListValue) Reset() {
*x = ListValue{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_value_proto_msgTypes[2]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_value_proto_msgTypes[2]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *ListValue) String() string {
@@ -323,7 +339,7 @@ func (*ListValue) ProtoMessage() {}
func (x *ListValue) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_value_proto_msgTypes[2]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -346,20 +362,17 @@ func (x *ListValue) GetValues() []*Value {
}
type MapValue struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
+ Entries []*MapValue_Entry `protobuf:"bytes,1,rep,name=entries,proto3" json:"entries,omitempty"`
unknownFields protoimpl.UnknownFields
-
- Entries []*MapValue_Entry `protobuf:"bytes,1,rep,name=entries,proto3" json:"entries,omitempty"`
+ sizeCache protoimpl.SizeCache
}
func (x *MapValue) Reset() {
*x = MapValue{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_value_proto_msgTypes[3]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_value_proto_msgTypes[3]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *MapValue) String() string {
@@ -370,7 +383,7 @@ func (*MapValue) ProtoMessage() {}
func (x *MapValue) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_value_proto_msgTypes[3]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -393,21 +406,18 @@ func (x *MapValue) GetEntries() []*MapValue_Entry {
}
type MapValue_Entry struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
+ Key *Value `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
+ Value *Value `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
unknownFields protoimpl.UnknownFields
-
- Key *Value `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
- Value *Value `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
+ sizeCache protoimpl.SizeCache
}
func (x *MapValue_Entry) Reset() {
*x = MapValue_Entry{}
- if protoimpl.UnsafeEnabled {
- mi := &file_cel_expr_value_proto_msgTypes[4]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_cel_expr_value_proto_msgTypes[4]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *MapValue_Entry) String() string {
@@ -418,7 +428,7 @@ func (*MapValue_Entry) ProtoMessage() {}
func (x *MapValue_Entry) ProtoReflect() protoreflect.Message {
mi := &file_cel_expr_value_proto_msgTypes[4]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -449,83 +459,58 @@ func (x *MapValue_Entry) GetValue() *Value {
var File_cel_expr_value_proto protoreflect.FileDescriptor
-var file_cel_expr_value_proto_rawDesc = []byte{
- 0x0a, 0x14, 0x63, 0x65, 0x6c, 0x2f, 0x65, 0x78, 0x70, 0x72, 0x2f, 0x76, 0x61, 0x6c, 0x75, 0x65,
- 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x08, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72,
- 0x1a, 0x19, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75,
- 0x66, 0x2f, 0x61, 0x6e, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1c, 0x67, 0x6f, 0x6f,
- 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x73, 0x74, 0x72,
- 0x75, 0x63, 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x9d, 0x04, 0x0a, 0x05, 0x56, 0x61,
- 0x6c, 0x75, 0x65, 0x12, 0x3b, 0x0a, 0x0a, 0x6e, 0x75, 0x6c, 0x6c, 0x5f, 0x76, 0x61, 0x6c, 0x75,
- 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65,
- 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x4e, 0x75, 0x6c, 0x6c, 0x56, 0x61,
- 0x6c, 0x75, 0x65, 0x48, 0x00, 0x52, 0x09, 0x6e, 0x75, 0x6c, 0x6c, 0x56, 0x61, 0x6c, 0x75, 0x65,
- 0x12, 0x1f, 0x0a, 0x0a, 0x62, 0x6f, 0x6f, 0x6c, 0x5f, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02,
- 0x20, 0x01, 0x28, 0x08, 0x48, 0x00, 0x52, 0x09, 0x62, 0x6f, 0x6f, 0x6c, 0x56, 0x61, 0x6c, 0x75,
- 0x65, 0x12, 0x21, 0x0a, 0x0b, 0x69, 0x6e, 0x74, 0x36, 0x34, 0x5f, 0x76, 0x61, 0x6c, 0x75, 0x65,
- 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x48, 0x00, 0x52, 0x0a, 0x69, 0x6e, 0x74, 0x36, 0x34, 0x56,
- 0x61, 0x6c, 0x75, 0x65, 0x12, 0x23, 0x0a, 0x0c, 0x75, 0x69, 0x6e, 0x74, 0x36, 0x34, 0x5f, 0x76,
- 0x61, 0x6c, 0x75, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x04, 0x48, 0x00, 0x52, 0x0b, 0x75, 0x69,
- 0x6e, 0x74, 0x36, 0x34, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x23, 0x0a, 0x0c, 0x64, 0x6f, 0x75,
- 0x62, 0x6c, 0x65, 0x5f, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x01, 0x48,
- 0x00, 0x52, 0x0b, 0x64, 0x6f, 0x75, 0x62, 0x6c, 0x65, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x23,
- 0x0a, 0x0c, 0x73, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x5f, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x06,
- 0x20, 0x01, 0x28, 0x09, 0x48, 0x00, 0x52, 0x0b, 0x73, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x56, 0x61,
- 0x6c, 0x75, 0x65, 0x12, 0x21, 0x0a, 0x0b, 0x62, 0x79, 0x74, 0x65, 0x73, 0x5f, 0x76, 0x61, 0x6c,
- 0x75, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0c, 0x48, 0x00, 0x52, 0x0a, 0x62, 0x79, 0x74, 0x65,
- 0x73, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x34, 0x0a, 0x0a, 0x65, 0x6e, 0x75, 0x6d, 0x5f, 0x76,
- 0x61, 0x6c, 0x75, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x13, 0x2e, 0x63, 0x65, 0x6c,
- 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x45, 0x6e, 0x75, 0x6d, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x48,
- 0x00, 0x52, 0x09, 0x65, 0x6e, 0x75, 0x6d, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x39, 0x0a, 0x0c,
- 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x5f, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x0a, 0x20, 0x01,
- 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74,
- 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x41, 0x6e, 0x79, 0x48, 0x00, 0x52, 0x0b, 0x6f, 0x62, 0x6a, 0x65,
- 0x63, 0x74, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x31, 0x0a, 0x09, 0x6d, 0x61, 0x70, 0x5f, 0x76,
- 0x61, 0x6c, 0x75, 0x65, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x63, 0x65, 0x6c,
- 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x4d, 0x61, 0x70, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x48, 0x00,
- 0x52, 0x08, 0x6d, 0x61, 0x70, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x34, 0x0a, 0x0a, 0x6c, 0x69,
- 0x73, 0x74, 0x5f, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x13,
- 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x56, 0x61,
- 0x6c, 0x75, 0x65, 0x48, 0x00, 0x52, 0x09, 0x6c, 0x69, 0x73, 0x74, 0x56, 0x61, 0x6c, 0x75, 0x65,
- 0x12, 0x1f, 0x0a, 0x0a, 0x74, 0x79, 0x70, 0x65, 0x5f, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x0f,
- 0x20, 0x01, 0x28, 0x09, 0x48, 0x00, 0x52, 0x09, 0x74, 0x79, 0x70, 0x65, 0x56, 0x61, 0x6c, 0x75,
- 0x65, 0x42, 0x06, 0x0a, 0x04, 0x6b, 0x69, 0x6e, 0x64, 0x22, 0x35, 0x0a, 0x09, 0x45, 0x6e, 0x75,
- 0x6d, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01,
- 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61,
- 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65,
- 0x22, 0x34, 0x0a, 0x09, 0x4c, 0x69, 0x73, 0x74, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x27, 0x0a,
- 0x06, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0f, 0x2e,
- 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x52, 0x06,
- 0x76, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x22, 0x91, 0x01, 0x0a, 0x08, 0x4d, 0x61, 0x70, 0x56, 0x61,
- 0x6c, 0x75, 0x65, 0x12, 0x32, 0x0a, 0x07, 0x65, 0x6e, 0x74, 0x72, 0x69, 0x65, 0x73, 0x18, 0x01,
- 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e,
- 0x4d, 0x61, 0x70, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x2e, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x07,
- 0x65, 0x6e, 0x74, 0x72, 0x69, 0x65, 0x73, 0x1a, 0x51, 0x0a, 0x05, 0x45, 0x6e, 0x74, 0x72, 0x79,
- 0x12, 0x21, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0f, 0x2e,
- 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x52, 0x03,
- 0x6b, 0x65, 0x79, 0x12, 0x25, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01,
- 0x28, 0x0b, 0x32, 0x0f, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x56, 0x61,
- 0x6c, 0x75, 0x65, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x42, 0x2d, 0x0a, 0x0c, 0x64, 0x65,
- 0x76, 0x2e, 0x63, 0x65, 0x6c, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x42, 0x0a, 0x56, 0x61, 0x6c, 0x75,
- 0x65, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x0c, 0x63, 0x65, 0x6c, 0x2e, 0x64, 0x65,
- 0x76, 0x2f, 0x65, 0x78, 0x70, 0x72, 0xf8, 0x01, 0x01, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f,
- 0x33,
-}
+const file_cel_expr_value_proto_rawDesc = "" +
+ "\n" +
+ "\x14cel/expr/value.proto\x12\bcel.expr\x1a\x19google/protobuf/any.proto\x1a\x1cgoogle/protobuf/struct.proto\"\x9d\x04\n" +
+ "\x05Value\x12;\n" +
+ "\n" +
+ "null_value\x18\x01 \x01(\x0e2\x1a.google.protobuf.NullValueH\x00R\tnullValue\x12\x1f\n" +
+ "\n" +
+ "bool_value\x18\x02 \x01(\bH\x00R\tboolValue\x12!\n" +
+ "\vint64_value\x18\x03 \x01(\x03H\x00R\n" +
+ "int64Value\x12#\n" +
+ "\fuint64_value\x18\x04 \x01(\x04H\x00R\vuint64Value\x12#\n" +
+ "\fdouble_value\x18\x05 \x01(\x01H\x00R\vdoubleValue\x12#\n" +
+ "\fstring_value\x18\x06 \x01(\tH\x00R\vstringValue\x12!\n" +
+ "\vbytes_value\x18\a \x01(\fH\x00R\n" +
+ "bytesValue\x124\n" +
+ "\n" +
+ "enum_value\x18\t \x01(\v2\x13.cel.expr.EnumValueH\x00R\tenumValue\x129\n" +
+ "\fobject_value\x18\n" +
+ " \x01(\v2\x14.google.protobuf.AnyH\x00R\vobjectValue\x121\n" +
+ "\tmap_value\x18\v \x01(\v2\x12.cel.expr.MapValueH\x00R\bmapValue\x124\n" +
+ "\n" +
+ "list_value\x18\f \x01(\v2\x13.cel.expr.ListValueH\x00R\tlistValue\x12\x1f\n" +
+ "\n" +
+ "type_value\x18\x0f \x01(\tH\x00R\ttypeValueB\x06\n" +
+ "\x04kind\"5\n" +
+ "\tEnumValue\x12\x12\n" +
+ "\x04type\x18\x01 \x01(\tR\x04type\x12\x14\n" +
+ "\x05value\x18\x02 \x01(\x05R\x05value\"4\n" +
+ "\tListValue\x12'\n" +
+ "\x06values\x18\x01 \x03(\v2\x0f.cel.expr.ValueR\x06values\"\x91\x01\n" +
+ "\bMapValue\x122\n" +
+ "\aentries\x18\x01 \x03(\v2\x18.cel.expr.MapValue.EntryR\aentries\x1aQ\n" +
+ "\x05Entry\x12!\n" +
+ "\x03key\x18\x01 \x01(\v2\x0f.cel.expr.ValueR\x03key\x12%\n" +
+ "\x05value\x18\x02 \x01(\v2\x0f.cel.expr.ValueR\x05valueB-\n" +
+ "\fdev.cel.exprB\n" +
+ "ValueProtoP\x01Z\fcel.dev/expr\xf8\x01\x01b\x06proto3"
var (
file_cel_expr_value_proto_rawDescOnce sync.Once
- file_cel_expr_value_proto_rawDescData = file_cel_expr_value_proto_rawDesc
+ file_cel_expr_value_proto_rawDescData []byte
)
func file_cel_expr_value_proto_rawDescGZIP() []byte {
file_cel_expr_value_proto_rawDescOnce.Do(func() {
- file_cel_expr_value_proto_rawDescData = protoimpl.X.CompressGZIP(file_cel_expr_value_proto_rawDescData)
+ file_cel_expr_value_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_cel_expr_value_proto_rawDesc), len(file_cel_expr_value_proto_rawDesc)))
})
return file_cel_expr_value_proto_rawDescData
}
var file_cel_expr_value_proto_msgTypes = make([]protoimpl.MessageInfo, 5)
-var file_cel_expr_value_proto_goTypes = []interface{}{
+var file_cel_expr_value_proto_goTypes = []any{
(*Value)(nil), // 0: cel.expr.Value
(*EnumValue)(nil), // 1: cel.expr.EnumValue
(*ListValue)(nil), // 2: cel.expr.ListValue
@@ -556,69 +541,7 @@ func file_cel_expr_value_proto_init() {
if File_cel_expr_value_proto != nil {
return
}
- if !protoimpl.UnsafeEnabled {
- file_cel_expr_value_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*Value); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- file_cel_expr_value_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*EnumValue); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- file_cel_expr_value_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*ListValue); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- file_cel_expr_value_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*MapValue); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- file_cel_expr_value_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*MapValue_Entry); i {
- case 0:
- return &v.state
- case 1:
- return &v.sizeCache
- case 2:
- return &v.unknownFields
- default:
- return nil
- }
- }
- }
- file_cel_expr_value_proto_msgTypes[0].OneofWrappers = []interface{}{
+ file_cel_expr_value_proto_msgTypes[0].OneofWrappers = []any{
(*Value_NullValue)(nil),
(*Value_BoolValue)(nil),
(*Value_Int64Value)(nil),
@@ -636,7 +559,7 @@ func file_cel_expr_value_proto_init() {
out := protoimpl.TypeBuilder{
File: protoimpl.DescBuilder{
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
- RawDescriptor: file_cel_expr_value_proto_rawDesc,
+ RawDescriptor: unsafe.Slice(unsafe.StringData(file_cel_expr_value_proto_rawDesc), len(file_cel_expr_value_proto_rawDesc)),
NumEnums: 0,
NumMessages: 5,
NumExtensions: 0,
@@ -647,7 +570,6 @@ func file_cel_expr_value_proto_init() {
MessageInfos: file_cel_expr_value_proto_msgTypes,
}.Build()
File_cel_expr_value_proto = out.File
- file_cel_expr_value_proto_rawDesc = nil
file_cel_expr_value_proto_goTypes = nil
file_cel_expr_value_proto_depIdxs = nil
}
diff --git a/vendor/github.com/cenkalti/backoff/v4/README.md b/vendor/github.com/cenkalti/backoff/v4/README.md
deleted file mode 100644
index 9433004a28..0000000000
--- a/vendor/github.com/cenkalti/backoff/v4/README.md
+++ /dev/null
@@ -1,30 +0,0 @@
-# Exponential Backoff [![GoDoc][godoc image]][godoc] [![Coverage Status][coveralls image]][coveralls]
-
-This is a Go port of the exponential backoff algorithm from [Google's HTTP Client Library for Java][google-http-java-client].
-
-[Exponential backoff][exponential backoff wiki]
-is an algorithm that uses feedback to multiplicatively decrease the rate of some process,
-in order to gradually find an acceptable rate.
-The retries exponentially increase and stop increasing when a certain threshold is met.
-
-## Usage
-
-Import path is `github.com/cenkalti/backoff/v4`. Please note the version part at the end.
-
-Use https://pkg.go.dev/github.com/cenkalti/backoff/v4 to view the documentation.
-
-## Contributing
-
-* I would like to keep this library as small as possible.
-* Please don't send a PR without opening an issue and discussing it first.
-* If proposed change is not a common use case, I will probably not accept it.
-
-[godoc]: https://pkg.go.dev/github.com/cenkalti/backoff/v4
-[godoc image]: https://godoc.org/github.com/cenkalti/backoff?status.png
-[coveralls]: https://coveralls.io/github/cenkalti/backoff?branch=master
-[coveralls image]: https://coveralls.io/repos/github/cenkalti/backoff/badge.svg?branch=master
-
-[google-http-java-client]: https://github.com/google/google-http-java-client/blob/da1aa993e90285ec18579f1553339b00e19b3ab5/google-http-client/src/main/java/com/google/api/client/util/ExponentialBackOff.java
-[exponential backoff wiki]: http://en.wikipedia.org/wiki/Exponential_backoff
-
-[advanced example]: https://pkg.go.dev/github.com/cenkalti/backoff/v4?tab=doc#pkg-examples
diff --git a/vendor/github.com/cenkalti/backoff/v4/context.go b/vendor/github.com/cenkalti/backoff/v4/context.go
deleted file mode 100644
index 48482330eb..0000000000
--- a/vendor/github.com/cenkalti/backoff/v4/context.go
+++ /dev/null
@@ -1,62 +0,0 @@
-package backoff
-
-import (
- "context"
- "time"
-)
-
-// BackOffContext is a backoff policy that stops retrying after the context
-// is canceled.
-type BackOffContext interface { // nolint: golint
- BackOff
- Context() context.Context
-}
-
-type backOffContext struct {
- BackOff
- ctx context.Context
-}
-
-// WithContext returns a BackOffContext with context ctx
-//
-// ctx must not be nil
-func WithContext(b BackOff, ctx context.Context) BackOffContext { // nolint: golint
- if ctx == nil {
- panic("nil context")
- }
-
- if b, ok := b.(*backOffContext); ok {
- return &backOffContext{
- BackOff: b.BackOff,
- ctx: ctx,
- }
- }
-
- return &backOffContext{
- BackOff: b,
- ctx: ctx,
- }
-}
-
-func getContext(b BackOff) context.Context {
- if cb, ok := b.(BackOffContext); ok {
- return cb.Context()
- }
- if tb, ok := b.(*backOffTries); ok {
- return getContext(tb.delegate)
- }
- return context.Background()
-}
-
-func (b *backOffContext) Context() context.Context {
- return b.ctx
-}
-
-func (b *backOffContext) NextBackOff() time.Duration {
- select {
- case <-b.ctx.Done():
- return Stop
- default:
- return b.BackOff.NextBackOff()
- }
-}
diff --git a/vendor/github.com/cenkalti/backoff/v4/exponential.go b/vendor/github.com/cenkalti/backoff/v4/exponential.go
deleted file mode 100644
index aac99f196a..0000000000
--- a/vendor/github.com/cenkalti/backoff/v4/exponential.go
+++ /dev/null
@@ -1,216 +0,0 @@
-package backoff
-
-import (
- "math/rand"
- "time"
-)
-
-/*
-ExponentialBackOff is a backoff implementation that increases the backoff
-period for each retry attempt using a randomization function that grows exponentially.
-
-NextBackOff() is calculated using the following formula:
-
- randomized interval =
- RetryInterval * (random value in range [1 - RandomizationFactor, 1 + RandomizationFactor])
-
-In other words NextBackOff() will range between the randomization factor
-percentage below and above the retry interval.
-
-For example, given the following parameters:
-
- RetryInterval = 2
- RandomizationFactor = 0.5
- Multiplier = 2
-
-the actual backoff period used in the next retry attempt will range between 1 and 3 seconds,
-multiplied by the exponential, that is, between 2 and 6 seconds.
-
-Note: MaxInterval caps the RetryInterval and not the randomized interval.
-
-If the time elapsed since an ExponentialBackOff instance is created goes past the
-MaxElapsedTime, then the method NextBackOff() starts returning backoff.Stop.
-
-The elapsed time can be reset by calling Reset().
-
-Example: Given the following default arguments, for 10 tries the sequence will be,
-and assuming we go over the MaxElapsedTime on the 10th try:
-
- Request # RetryInterval (seconds) Randomized Interval (seconds)
-
- 1 0.5 [0.25, 0.75]
- 2 0.75 [0.375, 1.125]
- 3 1.125 [0.562, 1.687]
- 4 1.687 [0.8435, 2.53]
- 5 2.53 [1.265, 3.795]
- 6 3.795 [1.897, 5.692]
- 7 5.692 [2.846, 8.538]
- 8 8.538 [4.269, 12.807]
- 9 12.807 [6.403, 19.210]
- 10 19.210 backoff.Stop
-
-Note: Implementation is not thread-safe.
-*/
-type ExponentialBackOff struct {
- InitialInterval time.Duration
- RandomizationFactor float64
- Multiplier float64
- MaxInterval time.Duration
- // After MaxElapsedTime the ExponentialBackOff returns Stop.
- // It never stops if MaxElapsedTime == 0.
- MaxElapsedTime time.Duration
- Stop time.Duration
- Clock Clock
-
- currentInterval time.Duration
- startTime time.Time
-}
-
-// Clock is an interface that returns current time for BackOff.
-type Clock interface {
- Now() time.Time
-}
-
-// ExponentialBackOffOpts is a function type used to configure ExponentialBackOff options.
-type ExponentialBackOffOpts func(*ExponentialBackOff)
-
-// Default values for ExponentialBackOff.
-const (
- DefaultInitialInterval = 500 * time.Millisecond
- DefaultRandomizationFactor = 0.5
- DefaultMultiplier = 1.5
- DefaultMaxInterval = 60 * time.Second
- DefaultMaxElapsedTime = 15 * time.Minute
-)
-
-// NewExponentialBackOff creates an instance of ExponentialBackOff using default values.
-func NewExponentialBackOff(opts ...ExponentialBackOffOpts) *ExponentialBackOff {
- b := &ExponentialBackOff{
- InitialInterval: DefaultInitialInterval,
- RandomizationFactor: DefaultRandomizationFactor,
- Multiplier: DefaultMultiplier,
- MaxInterval: DefaultMaxInterval,
- MaxElapsedTime: DefaultMaxElapsedTime,
- Stop: Stop,
- Clock: SystemClock,
- }
- for _, fn := range opts {
- fn(b)
- }
- b.Reset()
- return b
-}
-
-// WithInitialInterval sets the initial interval between retries.
-func WithInitialInterval(duration time.Duration) ExponentialBackOffOpts {
- return func(ebo *ExponentialBackOff) {
- ebo.InitialInterval = duration
- }
-}
-
-// WithRandomizationFactor sets the randomization factor to add jitter to intervals.
-func WithRandomizationFactor(randomizationFactor float64) ExponentialBackOffOpts {
- return func(ebo *ExponentialBackOff) {
- ebo.RandomizationFactor = randomizationFactor
- }
-}
-
-// WithMultiplier sets the multiplier for increasing the interval after each retry.
-func WithMultiplier(multiplier float64) ExponentialBackOffOpts {
- return func(ebo *ExponentialBackOff) {
- ebo.Multiplier = multiplier
- }
-}
-
-// WithMaxInterval sets the maximum interval between retries.
-func WithMaxInterval(duration time.Duration) ExponentialBackOffOpts {
- return func(ebo *ExponentialBackOff) {
- ebo.MaxInterval = duration
- }
-}
-
-// WithMaxElapsedTime sets the maximum total time for retries.
-func WithMaxElapsedTime(duration time.Duration) ExponentialBackOffOpts {
- return func(ebo *ExponentialBackOff) {
- ebo.MaxElapsedTime = duration
- }
-}
-
-// WithRetryStopDuration sets the duration after which retries should stop.
-func WithRetryStopDuration(duration time.Duration) ExponentialBackOffOpts {
- return func(ebo *ExponentialBackOff) {
- ebo.Stop = duration
- }
-}
-
-// WithClockProvider sets the clock used to measure time.
-func WithClockProvider(clock Clock) ExponentialBackOffOpts {
- return func(ebo *ExponentialBackOff) {
- ebo.Clock = clock
- }
-}
-
-type systemClock struct{}
-
-func (t systemClock) Now() time.Time {
- return time.Now()
-}
-
-// SystemClock implements Clock interface that uses time.Now().
-var SystemClock = systemClock{}
-
-// Reset the interval back to the initial retry interval and restarts the timer.
-// Reset must be called before using b.
-func (b *ExponentialBackOff) Reset() {
- b.currentInterval = b.InitialInterval
- b.startTime = b.Clock.Now()
-}
-
-// NextBackOff calculates the next backoff interval using the formula:
-// Randomized interval = RetryInterval * (1 ± RandomizationFactor)
-func (b *ExponentialBackOff) NextBackOff() time.Duration {
- // Make sure we have not gone over the maximum elapsed time.
- elapsed := b.GetElapsedTime()
- next := getRandomValueFromInterval(b.RandomizationFactor, rand.Float64(), b.currentInterval)
- b.incrementCurrentInterval()
- if b.MaxElapsedTime != 0 && elapsed+next > b.MaxElapsedTime {
- return b.Stop
- }
- return next
-}
-
-// GetElapsedTime returns the elapsed time since an ExponentialBackOff instance
-// is created and is reset when Reset() is called.
-//
-// The elapsed time is computed using time.Now().UnixNano(). It is
-// safe to call even while the backoff policy is used by a running
-// ticker.
-func (b *ExponentialBackOff) GetElapsedTime() time.Duration {
- return b.Clock.Now().Sub(b.startTime)
-}
-
-// Increments the current interval by multiplying it with the multiplier.
-func (b *ExponentialBackOff) incrementCurrentInterval() {
- // Check for overflow, if overflow is detected set the current interval to the max interval.
- if float64(b.currentInterval) >= float64(b.MaxInterval)/b.Multiplier {
- b.currentInterval = b.MaxInterval
- } else {
- b.currentInterval = time.Duration(float64(b.currentInterval) * b.Multiplier)
- }
-}
-
-// Returns a random value from the following interval:
-// [currentInterval - randomizationFactor * currentInterval, currentInterval + randomizationFactor * currentInterval].
-func getRandomValueFromInterval(randomizationFactor, random float64, currentInterval time.Duration) time.Duration {
- if randomizationFactor == 0 {
- return currentInterval // make sure no randomness is used when randomizationFactor is 0.
- }
- var delta = randomizationFactor * float64(currentInterval)
- var minInterval = float64(currentInterval) - delta
- var maxInterval = float64(currentInterval) + delta
-
- // Get a random value from the range [minInterval, maxInterval].
- // The formula used below has a +1 because if the minInterval is 1 and the maxInterval is 3 then
- // we want a 33% chance for selecting either 1, 2 or 3.
- return time.Duration(minInterval + (random * (maxInterval - minInterval + 1)))
-}
diff --git a/vendor/github.com/cenkalti/backoff/v4/retry.go b/vendor/github.com/cenkalti/backoff/v4/retry.go
deleted file mode 100644
index b9c0c51cd7..0000000000
--- a/vendor/github.com/cenkalti/backoff/v4/retry.go
+++ /dev/null
@@ -1,146 +0,0 @@
-package backoff
-
-import (
- "errors"
- "time"
-)
-
-// An OperationWithData is executing by RetryWithData() or RetryNotifyWithData().
-// The operation will be retried using a backoff policy if it returns an error.
-type OperationWithData[T any] func() (T, error)
-
-// An Operation is executing by Retry() or RetryNotify().
-// The operation will be retried using a backoff policy if it returns an error.
-type Operation func() error
-
-func (o Operation) withEmptyData() OperationWithData[struct{}] {
- return func() (struct{}, error) {
- return struct{}{}, o()
- }
-}
-
-// Notify is a notify-on-error function. It receives an operation error and
-// backoff delay if the operation failed (with an error).
-//
-// NOTE that if the backoff policy stated to stop retrying,
-// the notify function isn't called.
-type Notify func(error, time.Duration)
-
-// Retry the operation o until it does not return error or BackOff stops.
-// o is guaranteed to be run at least once.
-//
-// If o returns a *PermanentError, the operation is not retried, and the
-// wrapped error is returned.
-//
-// Retry sleeps the goroutine for the duration returned by BackOff after a
-// failed operation returns.
-func Retry(o Operation, b BackOff) error {
- return RetryNotify(o, b, nil)
-}
-
-// RetryWithData is like Retry but returns data in the response too.
-func RetryWithData[T any](o OperationWithData[T], b BackOff) (T, error) {
- return RetryNotifyWithData(o, b, nil)
-}
-
-// RetryNotify calls notify function with the error and wait duration
-// for each failed attempt before sleep.
-func RetryNotify(operation Operation, b BackOff, notify Notify) error {
- return RetryNotifyWithTimer(operation, b, notify, nil)
-}
-
-// RetryNotifyWithData is like RetryNotify but returns data in the response too.
-func RetryNotifyWithData[T any](operation OperationWithData[T], b BackOff, notify Notify) (T, error) {
- return doRetryNotify(operation, b, notify, nil)
-}
-
-// RetryNotifyWithTimer calls notify function with the error and wait duration using the given Timer
-// for each failed attempt before sleep.
-// A default timer that uses system timer is used when nil is passed.
-func RetryNotifyWithTimer(operation Operation, b BackOff, notify Notify, t Timer) error {
- _, err := doRetryNotify(operation.withEmptyData(), b, notify, t)
- return err
-}
-
-// RetryNotifyWithTimerAndData is like RetryNotifyWithTimer but returns data in the response too.
-func RetryNotifyWithTimerAndData[T any](operation OperationWithData[T], b BackOff, notify Notify, t Timer) (T, error) {
- return doRetryNotify(operation, b, notify, t)
-}
-
-func doRetryNotify[T any](operation OperationWithData[T], b BackOff, notify Notify, t Timer) (T, error) {
- var (
- err error
- next time.Duration
- res T
- )
- if t == nil {
- t = &defaultTimer{}
- }
-
- defer func() {
- t.Stop()
- }()
-
- ctx := getContext(b)
-
- b.Reset()
- for {
- res, err = operation()
- if err == nil {
- return res, nil
- }
-
- var permanent *PermanentError
- if errors.As(err, &permanent) {
- return res, permanent.Err
- }
-
- if next = b.NextBackOff(); next == Stop {
- if cerr := ctx.Err(); cerr != nil {
- return res, cerr
- }
-
- return res, err
- }
-
- if notify != nil {
- notify(err, next)
- }
-
- t.Start(next)
-
- select {
- case <-ctx.Done():
- return res, ctx.Err()
- case <-t.C():
- }
- }
-}
-
-// PermanentError signals that the operation should not be retried.
-type PermanentError struct {
- Err error
-}
-
-func (e *PermanentError) Error() string {
- return e.Err.Error()
-}
-
-func (e *PermanentError) Unwrap() error {
- return e.Err
-}
-
-func (e *PermanentError) Is(target error) bool {
- _, ok := target.(*PermanentError)
- return ok
-}
-
-// Permanent wraps the given err in a *PermanentError.
-func Permanent(err error) error {
- if err == nil {
- return nil
- }
- return &PermanentError{
- Err: err,
- }
-}
diff --git a/vendor/github.com/cenkalti/backoff/v4/tries.go b/vendor/github.com/cenkalti/backoff/v4/tries.go
deleted file mode 100644
index 28d58ca37c..0000000000
--- a/vendor/github.com/cenkalti/backoff/v4/tries.go
+++ /dev/null
@@ -1,38 +0,0 @@
-package backoff
-
-import "time"
-
-/*
-WithMaxRetries creates a wrapper around another BackOff, which will
-return Stop if NextBackOff() has been called too many times since
-the last time Reset() was called
-
-Note: Implementation is not thread-safe.
-*/
-func WithMaxRetries(b BackOff, max uint64) BackOff {
- return &backOffTries{delegate: b, maxTries: max}
-}
-
-type backOffTries struct {
- delegate BackOff
- maxTries uint64
- numTries uint64
-}
-
-func (b *backOffTries) NextBackOff() time.Duration {
- if b.maxTries == 0 {
- return Stop
- }
- if b.maxTries > 0 {
- if b.maxTries <= b.numTries {
- return Stop
- }
- b.numTries++
- }
- return b.delegate.NextBackOff()
-}
-
-func (b *backOffTries) Reset() {
- b.numTries = 0
- b.delegate.Reset()
-}
diff --git a/vendor/github.com/cenkalti/backoff/v4/.gitignore b/vendor/github.com/cenkalti/backoff/v5/.gitignore
similarity index 100%
rename from vendor/github.com/cenkalti/backoff/v4/.gitignore
rename to vendor/github.com/cenkalti/backoff/v5/.gitignore
diff --git a/vendor/github.com/cenkalti/backoff/v5/CHANGELOG.md b/vendor/github.com/cenkalti/backoff/v5/CHANGELOG.md
new file mode 100644
index 0000000000..658c37436d
--- /dev/null
+++ b/vendor/github.com/cenkalti/backoff/v5/CHANGELOG.md
@@ -0,0 +1,29 @@
+# Changelog
+
+All notable changes to this project will be documented in this file.
+
+The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
+and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
+
+## [5.0.0] - 2024-12-19
+
+### Added
+
+- RetryAfterError can be returned from an operation to indicate how long to wait before the next retry.
+
+### Changed
+
+- Retry function now accepts additional options for specifying max number of tries and max elapsed time.
+- Retry function now accepts a context.Context.
+- Operation function signature changed to return result (any type) and error.
+
+### Removed
+
+- RetryNotify* and RetryWithData functions. Only single Retry function remains.
+- Optional arguments from ExponentialBackoff constructor.
+- Clock and Timer interfaces.
+
+### Fixed
+
+- The original error is returned from Retry if there's a PermanentError. (#144)
+- The Retry function respects the wrapped PermanentError. (#140)
diff --git a/vendor/github.com/cenkalti/backoff/v4/LICENSE b/vendor/github.com/cenkalti/backoff/v5/LICENSE
similarity index 100%
rename from vendor/github.com/cenkalti/backoff/v4/LICENSE
rename to vendor/github.com/cenkalti/backoff/v5/LICENSE
diff --git a/vendor/github.com/cenkalti/backoff/v5/README.md b/vendor/github.com/cenkalti/backoff/v5/README.md
new file mode 100644
index 0000000000..4611b1d170
--- /dev/null
+++ b/vendor/github.com/cenkalti/backoff/v5/README.md
@@ -0,0 +1,31 @@
+# Exponential Backoff [![GoDoc][godoc image]][godoc]
+
+This is a Go port of the exponential backoff algorithm from [Google's HTTP Client Library for Java][google-http-java-client].
+
+[Exponential backoff][exponential backoff wiki]
+is an algorithm that uses feedback to multiplicatively decrease the rate of some process,
+in order to gradually find an acceptable rate.
+The retries exponentially increase and stop increasing when a certain threshold is met.
+
+## Usage
+
+Import path is `github.com/cenkalti/backoff/v5`. Please note the version part at the end.
+
+For most cases, use `Retry` function. See [example_test.go][example] for an example.
+
+If you have specific needs, copy `Retry` function (from [retry.go][retry-src]) into your code and modify it as needed.
+
+## Contributing
+
+* I would like to keep this library as small as possible.
+* Please don't send a PR without opening an issue and discussing it first.
+* If proposed change is not a common use case, I will probably not accept it.
+
+[godoc]: https://pkg.go.dev/github.com/cenkalti/backoff/v5
+[godoc image]: https://godoc.org/github.com/cenkalti/backoff?status.png
+
+[google-http-java-client]: https://github.com/google/google-http-java-client/blob/da1aa993e90285ec18579f1553339b00e19b3ab5/google-http-client/src/main/java/com/google/api/client/util/ExponentialBackOff.java
+[exponential backoff wiki]: http://en.wikipedia.org/wiki/Exponential_backoff
+
+[retry-src]: https://github.com/cenkalti/backoff/blob/v5/retry.go
+[example]: https://github.com/cenkalti/backoff/blob/v5/example_test.go
diff --git a/vendor/github.com/cenkalti/backoff/v4/backoff.go b/vendor/github.com/cenkalti/backoff/v5/backoff.go
similarity index 87%
rename from vendor/github.com/cenkalti/backoff/v4/backoff.go
rename to vendor/github.com/cenkalti/backoff/v5/backoff.go
index 3676ee405d..dd2b24ca73 100644
--- a/vendor/github.com/cenkalti/backoff/v4/backoff.go
+++ b/vendor/github.com/cenkalti/backoff/v5/backoff.go
@@ -15,16 +15,16 @@ import "time"
// BackOff is a backoff policy for retrying an operation.
type BackOff interface {
// NextBackOff returns the duration to wait before retrying the operation,
- // or backoff. Stop to indicate that no more retries should be made.
+ // backoff.Stop to indicate that no more retries should be made.
//
// Example usage:
//
- // duration := backoff.NextBackOff();
- // if (duration == backoff.Stop) {
- // // Do not retry operation.
- // } else {
- // // Sleep for duration and retry operation.
- // }
+ // duration := backoff.NextBackOff()
+ // if duration == backoff.Stop {
+ // // Do not retry operation.
+ // } else {
+ // // Sleep for duration and retry operation.
+ // }
//
NextBackOff() time.Duration
diff --git a/vendor/github.com/cenkalti/backoff/v5/error.go b/vendor/github.com/cenkalti/backoff/v5/error.go
new file mode 100644
index 0000000000..beb2b38a23
--- /dev/null
+++ b/vendor/github.com/cenkalti/backoff/v5/error.go
@@ -0,0 +1,46 @@
+package backoff
+
+import (
+ "fmt"
+ "time"
+)
+
+// PermanentError signals that the operation should not be retried.
+type PermanentError struct {
+ Err error
+}
+
+// Permanent wraps the given err in a *PermanentError.
+func Permanent(err error) error {
+ if err == nil {
+ return nil
+ }
+ return &PermanentError{
+ Err: err,
+ }
+}
+
+// Error returns a string representation of the Permanent error.
+func (e *PermanentError) Error() string {
+ return e.Err.Error()
+}
+
+// Unwrap returns the wrapped error.
+func (e *PermanentError) Unwrap() error {
+ return e.Err
+}
+
+// RetryAfterError signals that the operation should be retried after the given duration.
+type RetryAfterError struct {
+ Duration time.Duration
+}
+
+// RetryAfter returns a RetryAfter error that specifies how long to wait before retrying.
+func RetryAfter(seconds int) error {
+ return &RetryAfterError{Duration: time.Duration(seconds) * time.Second}
+}
+
+// Error returns a string representation of the RetryAfter error.
+func (e *RetryAfterError) Error() string {
+ return fmt.Sprintf("retry after %s", e.Duration)
+}
diff --git a/vendor/github.com/cenkalti/backoff/v5/exponential.go b/vendor/github.com/cenkalti/backoff/v5/exponential.go
new file mode 100644
index 0000000000..79d425e874
--- /dev/null
+++ b/vendor/github.com/cenkalti/backoff/v5/exponential.go
@@ -0,0 +1,118 @@
+package backoff
+
+import (
+ "math/rand/v2"
+ "time"
+)
+
+/*
+ExponentialBackOff is a backoff implementation that increases the backoff
+period for each retry attempt using a randomization function that grows exponentially.
+
+NextBackOff() is calculated using the following formula:
+
+ randomized interval =
+ RetryInterval * (random value in range [1 - RandomizationFactor, 1 + RandomizationFactor])
+
+In other words NextBackOff() will range between the randomization factor
+percentage below and above the retry interval.
+
+For example, given the following parameters:
+
+ RetryInterval = 2
+ RandomizationFactor = 0.5
+ Multiplier = 2
+
+the actual backoff period used in the next retry attempt will range between 1 and 3 seconds,
+multiplied by the exponential, that is, between 2 and 6 seconds.
+
+Note: MaxInterval caps the RetryInterval and not the randomized interval.
+
+Example: Given the following default arguments, for 9 tries the sequence will be:
+
+ Request # RetryInterval (seconds) Randomized Interval (seconds)
+
+ 1 0.5 [0.25, 0.75]
+ 2 0.75 [0.375, 1.125]
+ 3 1.125 [0.562, 1.687]
+ 4 1.687 [0.8435, 2.53]
+ 5 2.53 [1.265, 3.795]
+ 6 3.795 [1.897, 5.692]
+ 7 5.692 [2.846, 8.538]
+ 8 8.538 [4.269, 12.807]
+ 9 12.807 [6.403, 19.210]
+
+Note: Implementation is not thread-safe.
+*/
+type ExponentialBackOff struct {
+ InitialInterval time.Duration
+ RandomizationFactor float64
+ Multiplier float64
+ MaxInterval time.Duration
+
+ currentInterval time.Duration
+}
+
+// Default values for ExponentialBackOff.
+const (
+ DefaultInitialInterval = 500 * time.Millisecond
+ DefaultRandomizationFactor = 0.5
+ DefaultMultiplier = 1.5
+ DefaultMaxInterval = 60 * time.Second
+)
+
+// NewExponentialBackOff creates an instance of ExponentialBackOff using default values.
+func NewExponentialBackOff() *ExponentialBackOff {
+ return &ExponentialBackOff{
+ InitialInterval: DefaultInitialInterval,
+ RandomizationFactor: DefaultRandomizationFactor,
+ Multiplier: DefaultMultiplier,
+ MaxInterval: DefaultMaxInterval,
+ }
+}
+
+// Reset the interval back to the initial retry interval and restarts the timer.
+// Reset must be called before using b.
+func (b *ExponentialBackOff) Reset() {
+ b.currentInterval = b.InitialInterval
+}
+
+// NextBackOff calculates the next backoff interval using the formula:
+//
+// Randomized interval = RetryInterval * (1 ± RandomizationFactor)
+func (b *ExponentialBackOff) NextBackOff() time.Duration {
+ if b.currentInterval == 0 {
+ b.currentInterval = b.InitialInterval
+ }
+
+ next := getRandomValueFromInterval(b.RandomizationFactor, rand.Float64(), b.currentInterval)
+ b.incrementCurrentInterval()
+ return next
+}
+
+// Increments the current interval by multiplying it with the multiplier.
+func (b *ExponentialBackOff) incrementCurrentInterval() {
+ // Check for overflow, if overflow is detected set the current interval to the max interval.
+ if float64(b.currentInterval) >= float64(b.MaxInterval)/b.Multiplier {
+ b.currentInterval = b.MaxInterval
+ } else {
+ b.currentInterval = time.Duration(float64(b.currentInterval) * b.Multiplier)
+ }
+}
+
+// Returns a random value from the following interval:
+//
+// [currentInterval - randomizationFactor * currentInterval, currentInterval + randomizationFactor * currentInterval].
+func getRandomValueFromInterval(randomizationFactor, random float64, currentInterval time.Duration) time.Duration {
+ if randomizationFactor == 0 {
+ return currentInterval // make sure no randomness is used when randomizationFactor is 0.
+ }
+ var delta = randomizationFactor * float64(currentInterval)
+ var minInterval = float64(currentInterval) - delta
+ var maxInterval = float64(currentInterval) + delta
+
+ // Get a random value from the range [minInterval, maxInterval].
+ // The formula used below has a +1 because if the minInterval is 1 and the maxInterval is 3 then
+ // we want a 33% chance for selecting either 1, 2 or 3.
+ return time.Duration(minInterval + (random * (maxInterval - minInterval + 1)))
+}
diff --git a/vendor/github.com/cenkalti/backoff/v5/retry.go b/vendor/github.com/cenkalti/backoff/v5/retry.go
new file mode 100644
index 0000000000..32a7f98834
--- /dev/null
+++ b/vendor/github.com/cenkalti/backoff/v5/retry.go
@@ -0,0 +1,139 @@
+package backoff
+
+import (
+ "context"
+ "errors"
+ "time"
+)
+
+// DefaultMaxElapsedTime sets a default limit for the total retry duration.
+const DefaultMaxElapsedTime = 15 * time.Minute
+
+// Operation is a function that attempts an operation and may be retried.
+type Operation[T any] func() (T, error)
+
+// Notify is a function called on operation error with the error and backoff duration.
+type Notify func(error, time.Duration)
+
+// retryOptions holds configuration settings for the retry mechanism.
+type retryOptions struct {
+ BackOff BackOff // Strategy for calculating backoff periods.
+ Timer timer // Timer to manage retry delays.
+ Notify Notify // Optional function to notify on each retry error.
+ MaxTries uint // Maximum number of retry attempts.
+ MaxElapsedTime time.Duration // Maximum total time for all retries.
+}
+
+type RetryOption func(*retryOptions)
+
+// WithBackOff configures a custom backoff strategy.
+func WithBackOff(b BackOff) RetryOption {
+ return func(args *retryOptions) {
+ args.BackOff = b
+ }
+}
+
+// withTimer sets a custom timer for managing delays between retries.
+func withTimer(t timer) RetryOption {
+ return func(args *retryOptions) {
+ args.Timer = t
+ }
+}
+
+// WithNotify sets a notification function to handle retry errors.
+func WithNotify(n Notify) RetryOption {
+ return func(args *retryOptions) {
+ args.Notify = n
+ }
+}
+
+// WithMaxTries limits the number of all attempts.
+func WithMaxTries(n uint) RetryOption {
+ return func(args *retryOptions) {
+ args.MaxTries = n
+ }
+}
+
+// WithMaxElapsedTime limits the total duration for retry attempts.
+func WithMaxElapsedTime(d time.Duration) RetryOption {
+ return func(args *retryOptions) {
+ args.MaxElapsedTime = d
+ }
+}
+
+// Retry attempts the operation until success, a permanent error, or backoff completion.
+// It ensures the operation is executed at least once.
+//
+// Returns the operation result or error if retries are exhausted or context is cancelled.
+func Retry[T any](ctx context.Context, operation Operation[T], opts ...RetryOption) (T, error) {
+ // Initialize default retry options.
+ args := &retryOptions{
+ BackOff: NewExponentialBackOff(),
+ Timer: &defaultTimer{},
+ MaxElapsedTime: DefaultMaxElapsedTime,
+ }
+
+ // Apply user-provided options to the default settings.
+ for _, opt := range opts {
+ opt(args)
+ }
+
+ defer args.Timer.Stop()
+
+ startedAt := time.Now()
+ args.BackOff.Reset()
+ for numTries := uint(1); ; numTries++ {
+ // Execute the operation.
+ res, err := operation()
+ if err == nil {
+ return res, nil
+ }
+
+ // Stop retrying if maximum tries exceeded.
+ if args.MaxTries > 0 && numTries >= args.MaxTries {
+ return res, err
+ }
+
+ // Handle permanent errors without retrying.
+ var permanent *PermanentError
+ if errors.As(err, &permanent) {
+ return res, permanent.Unwrap()
+ }
+
+ // Stop retrying if context is cancelled.
+ if cerr := context.Cause(ctx); cerr != nil {
+ return res, cerr
+ }
+
+ // Calculate next backoff duration.
+ next := args.BackOff.NextBackOff()
+ if next == Stop {
+ return res, err
+ }
+
+ // Reset backoff if RetryAfterError is encountered.
+ var retryAfter *RetryAfterError
+ if errors.As(err, &retryAfter) {
+ next = retryAfter.Duration
+ args.BackOff.Reset()
+ }
+
+ // Stop retrying if maximum elapsed time exceeded.
+ if args.MaxElapsedTime > 0 && time.Since(startedAt)+next > args.MaxElapsedTime {
+ return res, err
+ }
+
+ // Notify on error if a notifier function is provided.
+ if args.Notify != nil {
+ args.Notify(err, next)
+ }
+
+ // Wait for the next backoff period or context cancellation.
+ args.Timer.Start(next)
+ select {
+ case <-args.Timer.C():
+ case <-ctx.Done():
+ return res, context.Cause(ctx)
+ }
+ }
+}
diff --git a/vendor/github.com/cenkalti/backoff/v4/ticker.go b/vendor/github.com/cenkalti/backoff/v5/ticker.go
similarity index 80%
rename from vendor/github.com/cenkalti/backoff/v4/ticker.go
rename to vendor/github.com/cenkalti/backoff/v5/ticker.go
index df9d68bce5..f0d4b2ae72 100644
--- a/vendor/github.com/cenkalti/backoff/v4/ticker.go
+++ b/vendor/github.com/cenkalti/backoff/v5/ticker.go
@@ -1,7 +1,6 @@
package backoff
import (
- "context"
"sync"
"time"
)
@@ -14,8 +13,7 @@ type Ticker struct {
C <-chan time.Time
c chan time.Time
b BackOff
- ctx context.Context
- timer Timer
+ timer timer
stop chan struct{}
stopOnce sync.Once
}
@@ -27,22 +25,12 @@ type Ticker struct {
// provided backoff policy (notably calling NextBackOff or Reset)
// while the ticker is running.
func NewTicker(b BackOff) *Ticker {
- return NewTickerWithTimer(b, &defaultTimer{})
-}
-
-// NewTickerWithTimer returns a new Ticker with a custom timer.
-// A default timer that uses system timer is used when nil is passed.
-func NewTickerWithTimer(b BackOff, timer Timer) *Ticker {
- if timer == nil {
- timer = &defaultTimer{}
- }
c := make(chan time.Time)
t := &Ticker{
C: c,
c: c,
b: b,
- ctx: getContext(b),
- timer: timer,
+ timer: &defaultTimer{},
stop: make(chan struct{}),
}
t.b.Reset()
@@ -73,8 +61,6 @@ func (t *Ticker) run() {
case <-t.stop:
t.c = nil // Prevent future ticks from being sent to the channel.
return
- case <-t.ctx.Done():
- return
}
}
}
diff --git a/vendor/github.com/cenkalti/backoff/v4/timer.go b/vendor/github.com/cenkalti/backoff/v5/timer.go
similarity index 96%
rename from vendor/github.com/cenkalti/backoff/v4/timer.go
rename to vendor/github.com/cenkalti/backoff/v5/timer.go
index 8120d0213c..a895309747 100644
--- a/vendor/github.com/cenkalti/backoff/v4/timer.go
+++ b/vendor/github.com/cenkalti/backoff/v5/timer.go
@@ -2,7 +2,7 @@ package backoff
import "time"
-type Timer interface {
+type timer interface {
Start(duration time.Duration)
Stop()
C() <-chan time.Time
diff --git a/vendor/github.com/coreos/go-systemd/v22/daemon/sdnotify_other.go b/vendor/github.com/coreos/go-systemd/v22/daemon/sdnotify_other.go
new file mode 100644
index 0000000000..d6309495d4
--- /dev/null
+++ b/vendor/github.com/coreos/go-systemd/v22/daemon/sdnotify_other.go
@@ -0,0 +1,22 @@
+// Copyright 2025
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+//go:build !unix
+
+package daemon
+
+// SdNotifyMonotonicUsec returns the empty string on unsupported platforms.
+func SdNotifyMonotonicUsec() string {
+ return ""
+}
diff --git a/vendor/github.com/coreos/go-systemd/v22/daemon/sdnotify_unix.go b/vendor/github.com/coreos/go-systemd/v22/daemon/sdnotify_unix.go
new file mode 100644
index 0000000000..bdbe6b0c28
--- /dev/null
+++ b/vendor/github.com/coreos/go-systemd/v22/daemon/sdnotify_unix.go
@@ -0,0 +1,36 @@
+// Copyright 2025
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+//go:build unix
+
+package daemon
+
+import (
+ "strconv"
+
+ "golang.org/x/sys/unix"
+)
+
+// SdNotifyMonotonicUsec returns a MONOTONIC_USEC=... assignment for the current time
+// with a trailing newline included. This is typically used with [SdNotifyReloading].
+//
+// If the monotonic clock is not available on the system, the empty string is returned.
+func SdNotifyMonotonicUsec() string {
+ var ts unix.Timespec
+ if err := unix.ClockGettime(unix.CLOCK_MONOTONIC, &ts); err != nil {
+ // Monotonic clock is not available on this system.
+ return ""
+ }
+ return "MONOTONIC_USEC=" + strconv.FormatInt(ts.Nano()/1000, 10) + "\n"
+}
diff --git a/vendor/github.com/coreos/go-systemd/v22/daemon/watchdog.go b/vendor/github.com/coreos/go-systemd/v22/daemon/watchdog.go
index 25d9c1aa93..a93314d0ab 100644
--- a/vendor/github.com/coreos/go-systemd/v22/daemon/watchdog.go
+++ b/vendor/github.com/coreos/go-systemd/v22/daemon/watchdog.go
@@ -15,6 +15,7 @@
package daemon
import (
+ "errors"
"fmt"
"os"
"strconv"
@@ -51,10 +52,10 @@ func SdWatchdogEnabled(unsetEnvironment bool) (time.Duration, error) {
}
s, err := strconv.Atoi(wusec)
if err != nil {
- return 0, fmt.Errorf("error converting WATCHDOG_USEC: %s", err)
+ return 0, fmt.Errorf("error converting WATCHDOG_USEC: %w", err)
}
if s <= 0 {
- return 0, fmt.Errorf("error WATCHDOG_USEC must be a positive number")
+ return 0, errors.New("error WATCHDOG_USEC must be a positive number")
}
interval := time.Duration(s) * time.Microsecond
@@ -63,7 +64,7 @@ func SdWatchdogEnabled(unsetEnvironment bool) (time.Duration, error) {
}
p, err := strconv.Atoi(wpid)
if err != nil {
- return 0, fmt.Errorf("error converting WATCHDOG_PID: %s", err)
+ return 0, fmt.Errorf("error converting WATCHDOG_PID: %w", err)
}
if os.Getpid() != p {
return 0, nil
diff --git a/vendor/github.com/coreos/go-systemd/v22/journal/journal.go b/vendor/github.com/coreos/go-systemd/v22/journal/journal.go
index ac24c7767d..16c4e47751 100644
--- a/vendor/github.com/coreos/go-systemd/v22/journal/journal.go
+++ b/vendor/github.com/coreos/go-systemd/v22/journal/journal.go
@@ -41,6 +41,6 @@ const (
)
// Print prints a message to the local systemd journal using Send().
-func Print(priority Priority, format string, a ...interface{}) error {
+func Print(priority Priority, format string, a ...any) error {
return Send(fmt.Sprintf(format, a...), priority, nil)
}
diff --git a/vendor/github.com/coreos/go-systemd/v22/journal/journal_unix.go b/vendor/github.com/coreos/go-systemd/v22/journal/journal_unix.go
index c5b23a8196..55cb9eb26a 100644
--- a/vendor/github.com/coreos/go-systemd/v22/journal/journal_unix.go
+++ b/vendor/github.com/coreos/go-systemd/v22/journal/journal_unix.go
@@ -13,7 +13,6 @@
// limitations under the License.
//go:build !windows
-// +build !windows
// Package journal provides write bindings to the local systemd journal.
// It is implemented in pure Go and connects to the journal directly over its
@@ -31,7 +30,6 @@ import (
"errors"
"fmt"
"io"
- "io/ioutil"
"net"
"os"
"strconv"
@@ -108,7 +106,7 @@ func fdIsJournalStream(fd int) (bool, error) {
var expectedStat syscall.Stat_t
_, err := fmt.Sscanf(journalStream, "%d:%d", &expectedStat.Dev, &expectedStat.Ino)
if err != nil {
- return false, fmt.Errorf("failed to parse JOURNAL_STREAM=%q: %v", journalStream, err)
+ return false, fmt.Errorf("failed to parse JOURNAL_STREAM=%q: %w", journalStream, err)
}
var stat syscall.Stat_t
@@ -194,7 +192,7 @@ func appendVariable(w io.Writer, name, value string) {
* - the data, followed by a newline
*/
fmt.Fprintln(w, name)
- binary.Write(w, binary.LittleEndian, uint64(len(value)))
+ _ = binary.Write(w, binary.LittleEndian, uint64(len(value)))
fmt.Fprintln(w, value)
} else {
/* just write the variable and value all on one line */
@@ -214,7 +212,7 @@ func validVarName(name string) error {
}
for _, c := range name {
- if !(('A' <= c && c <= 'Z') || ('0' <= c && c <= '9') || c == '_') {
+ if ('A' > c || c > 'Z') && ('0' > c || c > '9') && c != '_' {
return errors.New("Variable name contains invalid characters")
}
}
@@ -239,7 +237,7 @@ func isSocketSpaceError(err error) bool {
// tempFd creates a temporary, unlinked file under `/dev/shm`.
func tempFd() (*os.File, error) {
- file, err := ioutil.TempFile("/dev/shm/", "journal.XXXXX")
+ file, err := os.CreateTemp("/dev/shm/", "journal.XXXXX")
if err != nil {
return nil, err
}
diff --git a/vendor/github.com/emicklei/go-restful/v3/.travis.yml b/vendor/github.com/emicklei/go-restful/v3/.travis.yml
deleted file mode 100644
index 3a0bf5ff1b..0000000000
--- a/vendor/github.com/emicklei/go-restful/v3/.travis.yml
+++ /dev/null
@@ -1,13 +0,0 @@
-language: go
-
-go:
- - 1.x
-
-before_install:
- - go test -v
-
-script:
- - go test -race -coverprofile=coverage.txt -covermode=atomic
-
-after_success:
- - bash <(curl -s https://codecov.io/bash)
\ No newline at end of file
diff --git a/vendor/github.com/emicklei/go-restful/v3/CHANGES.md b/vendor/github.com/emicklei/go-restful/v3/CHANGES.md
index 6f24dfff56..4fcd920abe 100644
--- a/vendor/github.com/emicklei/go-restful/v3/CHANGES.md
+++ b/vendor/github.com/emicklei/go-restful/v3/CHANGES.md
@@ -1,5 +1,9 @@
# Change history of go-restful
+## [v3.13.0] - 2025-08-14
+
+- optimize performance of path matching in CurlyRouter ( thanks @wenhuang, Wen Huang)
+
## [v3.12.2] - 2025-02-21
- allow empty payloads in post,put,patch, issue #580 ( thanks @liggitt, Jordan Liggitt)
diff --git a/vendor/github.com/emicklei/go-restful/v3/README.md b/vendor/github.com/emicklei/go-restful/v3/README.md
index 3fb40d1980..50a79ab692 100644
--- a/vendor/github.com/emicklei/go-restful/v3/README.md
+++ b/vendor/github.com/emicklei/go-restful/v3/README.md
@@ -84,6 +84,7 @@ func (u UserResource) findUser(request *restful.Request, response *restful.Respo
- Configurable (trace) logging
- Customizable gzip/deflate readers and writers using CompressorProvider registration
- Inject your own http.Handler using the `HttpMiddlewareHandlerToFilter` function
+- Added `SetPathTokenCacheEnabled` and `SetCustomVerbCacheEnabled` to disable regexp caching (default=true)
## How to customize
There are several hooks to customize the behavior of the go-restful package.
diff --git a/vendor/github.com/emicklei/go-restful/v3/curly.go b/vendor/github.com/emicklei/go-restful/v3/curly.go
index 6fd2bcd5a1..eec43bfd06 100644
--- a/vendor/github.com/emicklei/go-restful/v3/curly.go
+++ b/vendor/github.com/emicklei/go-restful/v3/curly.go
@@ -9,11 +9,35 @@ import (
"regexp"
"sort"
"strings"
+ "sync"
)
// CurlyRouter expects Routes with paths that contain zero or more parameters in curly brackets.
type CurlyRouter struct{}
+var (
+ regexCache sync.Map // Cache for compiled regex patterns
+ pathTokenCacheEnabled = true // Enable/disable path token regex caching
+)
+
+// SetPathTokenCacheEnabled enables or disables path token regex caching for CurlyRouter.
+// When disabled, regex patterns will be compiled on every request.
+// When enabled (default), compiled regex patterns are cached for better performance.
+func SetPathTokenCacheEnabled(enabled bool) {
+ pathTokenCacheEnabled = enabled
+}
+
+// getCachedRegexp retrieves a compiled regex from the cache if found and valid.
+// Returns the regex and true if found and valid, nil and false otherwise.
+func getCachedRegexp(cache *sync.Map, pattern string) (*regexp.Regexp, bool) {
+ if cached, found := cache.Load(pattern); found {
+ if regex, ok := cached.(*regexp.Regexp); ok {
+ return regex, true
+ }
+ }
+ return nil, false
+}
+
// SelectRoute is part of the Router interface and returns the best match
// for the WebService and its Route for the given Request.
func (c CurlyRouter) SelectRoute(
@@ -113,8 +137,28 @@ func (c CurlyRouter) regularMatchesPathToken(routeToken string, colon int, reque
}
return true, true
}
- matched, err := regexp.MatchString(regPart, requestToken)
- return (matched && err == nil), false
+
+ // Check cache first (if enabled)
+ if pathTokenCacheEnabled {
+ if regex, found := getCachedRegexp(®exCache, regPart); found {
+ matched := regex.MatchString(requestToken)
+ return matched, false
+ }
+ }
+
+ // Compile the regex
+ regex, err := regexp.Compile(regPart)
+ if err != nil {
+ return false, false
+ }
+
+ // Cache the regex (if enabled)
+ if pathTokenCacheEnabled {
+ regexCache.Store(regPart, regex)
+ }
+
+ matched := regex.MatchString(requestToken)
+ return matched, false
}
var jsr311Router = RouterJSR311{}
@@ -168,7 +212,7 @@ func (c CurlyRouter) computeWebserviceScore(requestTokens []string, routeTokens
if matchesToken {
score++ // extra score for regex match
}
- }
+ }
} else {
// not a parameter
if eachRequestToken != eachRouteToken {
diff --git a/vendor/github.com/emicklei/go-restful/v3/custom_verb.go b/vendor/github.com/emicklei/go-restful/v3/custom_verb.go
index bfc17efde8..0b98eeb091 100644
--- a/vendor/github.com/emicklei/go-restful/v3/custom_verb.go
+++ b/vendor/github.com/emicklei/go-restful/v3/custom_verb.go
@@ -1,14 +1,28 @@
package restful
+// Copyright 2025 Ernest Micklei. All rights reserved.
+// Use of this source code is governed by a license
+// that can be found in the LICENSE file.
+
import (
"fmt"
"regexp"
+ "sync"
)
var (
- customVerbReg = regexp.MustCompile(":([A-Za-z]+)$")
+ customVerbReg = regexp.MustCompile(":([A-Za-z]+)$")
+ customVerbCache sync.Map // Cache for compiled custom verb regexes
+ customVerbCacheEnabled = true // Enable/disable custom verb regex caching
)
+// SetCustomVerbCacheEnabled enables or disables custom verb regex caching.
+// When disabled, custom verb regex patterns will be compiled on every request.
+// When enabled (default), compiled custom verb regex patterns are cached for better performance.
+func SetCustomVerbCacheEnabled(enabled bool) {
+ customVerbCacheEnabled = enabled
+}
+
func hasCustomVerb(routeToken string) bool {
return customVerbReg.MatchString(routeToken)
}
@@ -20,7 +34,23 @@ func isMatchCustomVerb(routeToken string, pathToken string) bool {
}
customVerb := rs[1]
- specificVerbReg := regexp.MustCompile(fmt.Sprintf(":%s$", customVerb))
+ regexPattern := fmt.Sprintf(":%s$", customVerb)
+
+ // Check cache first (if enabled)
+ if customVerbCacheEnabled {
+ if specificVerbReg, found := getCachedRegexp(&customVerbCache, regexPattern); found {
+ return specificVerbReg.MatchString(pathToken)
+ }
+ }
+
+ // Compile the regex
+ specificVerbReg := regexp.MustCompile(regexPattern)
+
+ // Cache the regex (if enabled)
+ if customVerbCacheEnabled {
+ customVerbCache.Store(regexPattern, specificVerbReg)
+ }
+
return specificVerbReg.MatchString(pathToken)
}
diff --git a/vendor/github.com/emicklei/go-restful/v3/doc.go b/vendor/github.com/emicklei/go-restful/v3/doc.go
index 69b13057d0..80809225b8 100644
--- a/vendor/github.com/emicklei/go-restful/v3/doc.go
+++ b/vendor/github.com/emicklei/go-restful/v3/doc.go
@@ -1,7 +1,7 @@
/*
Package restful , a lean package for creating REST-style WebServices without magic.
-WebServices and Routes
+### WebServices and Routes
A WebService has a collection of Route objects that dispatch incoming Http Requests to a function calls.
Typically, a WebService has a root path (e.g. /users) and defines common MIME types for its routes.
@@ -30,14 +30,14 @@ The (*Request, *Response) arguments provide functions for reading information fr
See the example https://github.com/emicklei/go-restful/blob/v3/examples/user-resource/restful-user-resource.go with a full implementation.
-Regular expression matching Routes
+### Regular expression matching Routes
A Route parameter can be specified using the format "uri/{var[:regexp]}" or the special version "uri/{var:*}" for matching the tail of the path.
For example, /persons/{name:[A-Z][A-Z]} can be used to restrict values for the parameter "name" to only contain capital alphabetic characters.
Regular expressions must use the standard Go syntax as described in the regexp package. (https://code.google.com/p/re2/wiki/Syntax)
This feature requires the use of a CurlyRouter.
-Containers
+### Containers
A Container holds a collection of WebServices, Filters and a http.ServeMux for multiplexing http requests.
Using the statements "restful.Add(...) and restful.Filter(...)" will register WebServices and Filters to the Default Container.
@@ -47,7 +47,7 @@ You can create your own Container and create a new http.Server for that particul
container := restful.NewContainer()
server := &http.Server{Addr: ":8081", Handler: container}
-Filters
+### Filters
A filter dynamically intercepts requests and responses to transform or use the information contained in the requests or responses.
You can use filters to perform generic logging, measurement, authentication, redirect, set response headers etc.
@@ -60,22 +60,21 @@ Use the following statement to pass the request,response pair to the next filter
chain.ProcessFilter(req, resp)
-Container Filters
+### Container Filters
These are processed before any registered WebService.
// install a (global) filter for the default container (processed before any webservice)
restful.Filter(globalLogging)
-WebService Filters
+### WebService Filters
These are processed before any Route of a WebService.
// install a webservice filter (processed before any route)
ws.Filter(webserviceLogging).Filter(measureTime)
-
-Route Filters
+### Route Filters
These are processed before calling the function associated with the Route.
@@ -84,7 +83,7 @@ These are processed before calling the function associated with the Route.
See the example https://github.com/emicklei/go-restful/blob/v3/examples/filters/restful-filters.go with full implementations.
-Response Encoding
+### Response Encoding
Two encodings are supported: gzip and deflate. To enable this for all responses:
@@ -95,20 +94,20 @@ Alternatively, you can create a Filter that performs the encoding and install it
See the example https://github.com/emicklei/go-restful/blob/v3/examples/encoding/restful-encoding-filter.go
-OPTIONS support
+### OPTIONS support
By installing a pre-defined container filter, your Webservice(s) can respond to the OPTIONS Http request.
Filter(OPTIONSFilter())
-CORS
+### CORS
By installing the filter of a CrossOriginResourceSharing (CORS), your WebService(s) can handle CORS requests.
cors := CrossOriginResourceSharing{ExposeHeaders: []string{"X-My-Header"}, CookiesAllowed: false, Container: DefaultContainer}
Filter(cors.Filter)
-Error Handling
+### Error Handling
Unexpected things happen. If a request cannot be processed because of a failure, your service needs to tell via the response what happened and why.
For this reason HTTP status codes exist and it is important to use the correct code in every exceptional situation.
@@ -137,11 +136,11 @@ The request does not have or has an unknown Accept Header set for this operation
The request does not have or has an unknown Content-Type Header set for this operation.
-ServiceError
+### ServiceError
In addition to setting the correct (error) Http status code, you can choose to write a ServiceError message on the response.
-Performance options
+### Performance options
This package has several options that affect the performance of your service. It is important to understand them and how you can change it.
@@ -156,30 +155,27 @@ Default value is true
If content encoding is enabled then the default strategy for getting new gzip/zlib writers and readers is to use a sync.Pool.
Because writers are expensive structures, performance is even more improved when using a preloaded cache. You can also inject your own implementation.
-Trouble shooting
+### Trouble shooting
This package has the means to produce detail logging of the complete Http request matching process and filter invocation.
Enabling this feature requires you to set an implementation of restful.StdLogger (e.g. log.Logger) instance such as:
restful.TraceLogger(log.New(os.Stdout, "[restful] ", log.LstdFlags|log.Lshortfile))
-Logging
+### Logging
The restful.SetLogger() method allows you to override the logger used by the package. By default restful
uses the standard library `log` package and logs to stdout. Different logging packages are supported as
long as they conform to `StdLogger` interface defined in the `log` sub-package, writing an adapter for your
preferred package is simple.
-Resources
+### Resources
-[project]: https://github.com/emicklei/go-restful
+(c) 2012-2025, http://ernestmicklei.com. MIT License
+[project]: https://github.com/emicklei/go-restful
[examples]: https://github.com/emicklei/go-restful/blob/master/examples
-
-[design]: http://ernestmicklei.com/2012/11/11/go-restful-api-design/
-
+[design]: http://ernestmicklei.com/2012/11/11/go-restful-api-design/
[showcases]: https://github.com/emicklei/mora, https://github.com/emicklei/landskape
-
-(c) 2012-2015, http://ernestmicklei.com. MIT License
*/
package restful
diff --git a/vendor/github.com/go-openapi/swag/.codecov.yml b/vendor/github.com/go-openapi/swag/.codecov.yml
new file mode 100644
index 0000000000..3354f44b28
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/.codecov.yml
@@ -0,0 +1,4 @@
+ignore:
+ - jsonutils/fixtures_test
+ - jsonutils/adapters/ifaces/mocks
+ - jsonutils/adapters/testintegration/benchmarks
diff --git a/vendor/github.com/go-openapi/swag/.golangci.yml b/vendor/github.com/go-openapi/swag/.golangci.yml
index 80e2be0042..126264a6b8 100644
--- a/vendor/github.com/go-openapi/swag/.golangci.yml
+++ b/vendor/github.com/go-openapi/swag/.golangci.yml
@@ -1,60 +1,78 @@
-linters-settings:
- govet:
- check-shadowing: true
- golint:
- min-confidence: 0
- gocyclo:
- min-complexity: 45
- maligned:
- suggest-new: true
- dupl:
- threshold: 200
- goconst:
- min-len: 3
- min-occurrences: 3
-
+version: "2"
linters:
- enable-all: true
+ default: all
disable:
- - maligned
- - lll
- - gochecknoinits
- - gochecknoglobals
+ - cyclop
+ - depguard
+ - errchkjson
+ - errorlint
+ - exhaustruct
+ - forcetypeassert
- funlen
- - godox
+ - gochecknoglobals
+ - gochecknoinits
- gocognit
- - whitespace
- - wsl
- - wrapcheck
- - testpackage
- - nlreturn
- - gomnd
- - exhaustivestruct
- - goerr113
- - errorlint
- - nestif
- godot
- - gofumpt
+ - godox
+ - gomoddirectives
+ - gosmopolitan
+ - inamedparam
+ - intrange
+ - ireturn
+ - lll
+ - musttag
+ - modernize
+ - nestif
+ - nlreturn
+ - nonamedreturns
+ - noinlineerr
- paralleltest
- - tparallel
+ - recvcheck
+ - testpackage
- thelper
- - ifshort
- - exhaustruct
+ - tagliatelle
+ - tparallel
+ - unparam
- varnamelen
- - gci
- - depguard
- - errchkjson
- - inamedparam
- - nonamedreturns
- - musttag
- - ireturn
- - forcetypeassert
- - cyclop
- # deprecated linters
- - deadcode
- - interfacer
- - scopelint
- - varcheck
- - structcheck
- - golint
- - nosnakecase
+ - whitespace
+ - wrapcheck
+ - wsl
+ - wsl_v5
+ settings:
+ dupl:
+ threshold: 200
+ goconst:
+ min-len: 2
+ min-occurrences: 3
+ gocyclo:
+ min-complexity: 45
+ exclusions:
+ generated: lax
+ presets:
+ - comments
+ - common-false-positives
+ - legacy
+ - std-error-handling
+ paths:
+ - third_party$
+ - builtin$
+ - examples$
+formatters:
+ enable:
+ - gofmt
+ - goimports
+ exclusions:
+ generated: lax
+ paths:
+ - third_party$
+ - builtin$
+ - examples$
+issues:
+ # Maximum issues count per one linter.
+ # Set to 0 to disable.
+ # Default: 50
+ max-issues-per-linter: 0
+ # Maximum count of issues with the same text.
+ # Set to 0 to disable.
+ # Default: 3
+ max-same-issues: 0
diff --git a/vendor/github.com/go-openapi/swag/.mockery.yml b/vendor/github.com/go-openapi/swag/.mockery.yml
new file mode 100644
index 0000000000..8557cb58d3
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/.mockery.yml
@@ -0,0 +1,30 @@
+all: false
+dir: '{{.InterfaceDir}}'
+filename: mocks_test.go
+force-file-write: true
+formatter: goimports
+include-auto-generated: false
+log-level: info
+structname: '{{.Mock}}{{.InterfaceName}}'
+pkgname: '{{.SrcPackageName}}'
+recursive: false
+require-template-schema-exists: true
+template: matryer
+template-schema: '{{.Template}}.schema.json'
+packages:
+ github.com/go-openapi/swag/jsonutils/adapters/ifaces:
+ config:
+ dir: jsonutils/adapters/ifaces/mocks
+ filename: mocks.go
+ pkgname: 'mocks'
+ force-file-write: true
+ all: true
+ github.com/go-openapi/swag/jsonutils/adapters/testintegration:
+ config:
+ inpackage: true
+ dir: jsonutils/adapters/testintegration
+ force-file-write: true
+ all: true
+ interfaces:
+ EJMarshaler:
+ EJUnmarshaler:
diff --git a/vendor/github.com/go-openapi/swag/BENCHMARK.md b/vendor/github.com/go-openapi/swag/BENCHMARK.md
deleted file mode 100644
index e7f28ed6b7..0000000000
--- a/vendor/github.com/go-openapi/swag/BENCHMARK.md
+++ /dev/null
@@ -1,52 +0,0 @@
-# Benchmarks
-
-## Name mangling utilities
-
-```bash
-go test -bench XXX -run XXX -benchtime 30s
-```
-
-### Benchmarks at b3e7a5386f996177e4808f11acb2aa93a0f660df
-
-```
-goos: linux
-goarch: amd64
-pkg: github.com/go-openapi/swag
-cpu: Intel(R) Core(TM) i5-6200U CPU @ 2.30GHz
-BenchmarkToXXXName/ToGoName-4 862623 44101 ns/op 10450 B/op 732 allocs/op
-BenchmarkToXXXName/ToVarName-4 853656 40728 ns/op 10468 B/op 734 allocs/op
-BenchmarkToXXXName/ToFileName-4 1268312 27813 ns/op 9785 B/op 617 allocs/op
-BenchmarkToXXXName/ToCommandName-4 1276322 27903 ns/op 9785 B/op 617 allocs/op
-BenchmarkToXXXName/ToHumanNameLower-4 895334 40354 ns/op 10472 B/op 731 allocs/op
-BenchmarkToXXXName/ToHumanNameTitle-4 882441 40678 ns/op 10566 B/op 749 allocs/op
-```
-
-### Benchmarks after PR #79
-
-~ x10 performance improvement and ~ /100 memory allocations.
-
-```
-goos: linux
-goarch: amd64
-pkg: github.com/go-openapi/swag
-cpu: Intel(R) Core(TM) i5-6200U CPU @ 2.30GHz
-BenchmarkToXXXName/ToGoName-4 9595830 3991 ns/op 42 B/op 5 allocs/op
-BenchmarkToXXXName/ToVarName-4 9194276 3984 ns/op 62 B/op 7 allocs/op
-BenchmarkToXXXName/ToFileName-4 17002711 2123 ns/op 147 B/op 7 allocs/op
-BenchmarkToXXXName/ToCommandName-4 16772926 2111 ns/op 147 B/op 7 allocs/op
-BenchmarkToXXXName/ToHumanNameLower-4 9788331 3749 ns/op 92 B/op 6 allocs/op
-BenchmarkToXXXName/ToHumanNameTitle-4 9188260 3941 ns/op 104 B/op 6 allocs/op
-```
-
-```
-goos: linux
-goarch: amd64
-pkg: github.com/go-openapi/swag
-cpu: AMD Ryzen 7 5800X 8-Core Processor
-BenchmarkToXXXName/ToGoName-16 18527378 1972 ns/op 42 B/op 5 allocs/op
-BenchmarkToXXXName/ToVarName-16 15552692 2093 ns/op 62 B/op 7 allocs/op
-BenchmarkToXXXName/ToFileName-16 32161176 1117 ns/op 147 B/op 7 allocs/op
-BenchmarkToXXXName/ToCommandName-16 32256634 1137 ns/op 147 B/op 7 allocs/op
-BenchmarkToXXXName/ToHumanNameLower-16 18599661 1946 ns/op 92 B/op 6 allocs/op
-BenchmarkToXXXName/ToHumanNameTitle-16 17581353 2054 ns/op 105 B/op 6 allocs/op
-```
diff --git a/vendor/github.com/go-openapi/swag/README.md b/vendor/github.com/go-openapi/swag/README.md
index a729222998..371fd55fdc 100644
--- a/vendor/github.com/go-openapi/swag/README.md
+++ b/vendor/github.com/go-openapi/swag/README.md
@@ -1,23 +1,239 @@
# Swag [](https://github.com/go-openapi/swag/actions?query=workflow%3A"go+test") [](https://codecov.io/gh/go-openapi/swag)
[](https://slackin.goswagger.io)
-[](https://raw.githubusercontent.com/go-openapi/swag/master/LICENSE)
+[](https://raw.githubusercontent.com/go-openapi/swag/master/LICENSE)
[](https://pkg.go.dev/github.com/go-openapi/swag)
[](https://goreportcard.com/report/github.com/go-openapi/swag)
-Contains a bunch of helper functions for go-openapi and go-swagger projects.
+Package `swag` contains a bunch of helper functions for go-openapi and go-swagger projects.
You may also use it standalone for your projects.
-* convert between value and pointers for builtin types
-* convert from string to builtin types (wraps strconv)
-* fast json concatenation
-* search in path
-* load from file or http
-* name mangling
+> **NOTE**
+> `swag` is one of the foundational building blocks of the go-openapi initiative.
+> Most repositories in `github.com/go-openapi/...` depend on it in some way.
+> And so does our CLI tool `github.com/go-swagger/go-swagger`,
+> as well as the code generated by this tool.
+* [Contents](#contents)
+* [Dependencies](#dependencies)
+* [Release Notes](#release-notes)
+* [Licensing](#licensing)
+* [Note to contributors](#note-to-contributors)
+* [TODOs, suggestions and plans](#todos-suggestions-and-plans)
-This repo has only few dependencies outside of the standard library:
+## Contents
-* YAML utilities depend on `gopkg.in/yaml.v3`
-* `github.com/mailru/easyjson v0.7.7`
+`go-openapi/swag` exposes a collection of relatively independent modules.
+
+Moving forward, no additional feature will be added to the `swag` API directly at the root package level,
+which remains there for backward-compatibility purposes. All exported top-level features are now deprecated.
+
+Child modules will continue to evolve and some new ones may be added in the future.
+
+| Module | Content | Main features |
+|---------------|---------|---------------|
+| `cmdutils` | utilities to work with CLIs ||
+| `conv` | type conversion utilities | convert between values and pointers for any types
convert from string to builtin types (wraps `strconv`)
require `./typeutils` (test dependency)
|
+| `fileutils` | file utilities | |
+| `jsonname` | JSON utilities | infer JSON names from `go` properties
|
+| `jsonutils` | JSON utilities | fast json concatenation
read and write JSON from and to dynamic `go` data structures
~require `github.com/mailru/easyjson`~
|
+| `loading` | file loading | load from file or http
require `./yamlutils`
|
+| `mangling` | safe name generation | name mangling for `go`
|
+| `netutils` | networking utilities | host, port from address
|
+| `stringutils` | `string` utilities | search in slice (with case-insensitive)
split/join query parameters as arrays
|
+| `typeutils` | `go` types utilities | check the zero value for any type
safe check for a nil value
|
+| `yamlutils` | YAML utilities | converting YAML to JSON
loading YAML into a dynamic YAML document
maintaining the original order of keys in YAML objects
require `./jsonutils`
~require `github.com/mailru/easyjson`~
require `go.yaml.in/yaml/v3`
|
+
+---
+
+## Dependencies
+
+The root module `github.com/go-openapi/swag` at the repo level maintains a few
+dependencies outside of the standard library.
+
+* YAML utilities depend on `go.yaml.in/yaml/v3`
+* JSON utilities depend on their registered adapter module:
+ * by default, only the standard library is used
+ * `github.com/mailru/easyjson` is now only a dependency for module
+ `github.com/go-openapi/swag/jsonutils/adapters/easyjson/json`,
+ for users willing to import that module.
+ * integration tests and benchmarks use all the dependencies are published as their own module
+* other dependencies are test dependencies drawn from `github.com/stretchr/testify`
+
+## Release notes
+
+### v0.25.4
+
+** mangling**
+
+Bug fix
+
+* [x] mangler may panic with pluralized overlapping initialisms
+
+Tests
+
+* [x] introduced fuzz tests
+
+### v0.25.3
+
+** mangling**
+
+Bug fix
+
+* [x] mangler may panic with pluralized initialisms
+
+### v0.25.2
+
+Minor changes due to internal maintenance that don't affect the behavior of the library.
+
+* [x] removed indirect test dependencies by switching all tests to `go-openapi/testify`,
+ a fork of `stretch/testify` with zero-dependencies.
+* [x] improvements to CI to catch test reports.
+* [x] modernized licensing annotations in source code, using the more compact SPDX annotations
+ rather than the full license terms.
+* [x] simplified a bit JSON & YAML testing by using newly available assertions
+* started the journey to an OpenSSF score card badge:
+ * [x] explicited permissions in CI workflows
+ * [x] published security policy
+ * pinned dependencies to github actions
+ * introduced fuzzing in tests
+
+### v0.25.1
+
+* fixes a data race that could occur when using the standard library implementation of a JSON ordered map
+
+### v0.25.0
+
+**New with this release**:
+
+* requires `go1.24`, as iterators are being introduced
+* removes the dependency to `mailru/easyjson` by default (#68)
+ * functionality remains the same, but performance may somewhat degrade for applications
+ that relied on `easyjson`
+ * users of the JSON or YAML utilities who want to use `easyjson` as their preferred JSON serializer library
+ will be able to do so by registering this the corresponding JSON adapter at runtime. See below.
+ * ordered keys in JSON and YAML objects: this feature used to rely solely on `easyjson`.
+ With this release, an implementation relying on the standard `encoding/json` is provided.
+ * an independent [benchmark](./jsonutils/adapters/testintegration/benchmarks/README.md) to compare the different adapters
+* improves the "float is integer" check (`conv.IsFloat64AJSONInteger`) (#59)
+* removes the _direct_ dependency to `gopkg.in/yaml.v3` (indirect dependency is still incurred through `stretchr/testify`) (#127)
+* exposed `conv.IsNil()` (previously kept private): a safe nil check (accounting for the "non-nil interface with nil value" nonsensical go trick)
+
+**What coming next?**
+
+Moving forward, we want to :
+* provide an implementation of the JSON adapter based on `encoding/json/v2`, for `go1.25` builds.
+* provide similar implementations for `goccy/go-json` and `jsoniterator/go`, and perhaps some other
+ similar libraries may be interesting too.
+
+
+**How to explicitly register a dependency at runtime**?
+
+The following would maintain how JSON utilities proposed by `swag` used work, up to `v0.24.1`.
+
+ ```go
+ import (
+ "github.com/go-openapi/swag/jsonutils/adapters"
+ easyjson "github.com/go-openapi/swag/jsonutils/adapters/easyjson/json"
+ )
+
+ func init() {
+ easyjson.Register(adapters.Registry)
+ }
+ ```
+
+Subsequent calls to `jsonutils.ReadJSON()` or `jsonutils.WriteJSON()` will switch to `easyjson`
+whenever the passed data structures implement the `easyjson.Unmarshaler` or `easyjson.Marshaler` respectively,
+or fallback to the standard library.
+
+For more details, you may also look at our
+[integration tests](jsonutils/adapters/testintegration/integration_suite_test.go#29).
+
+### v0.24.0
+
+With this release, we have largely modernized the API of `swag`:
+
+* The traditional `swag` API is still supported: code that imports `swag` will still
+ compile and work the same.
+* A deprecation notice is published to encourage consumers of this library to adopt
+ the newer API
+* **Deprecation notice**
+ * configuration through global variables is now deprecated, in favor of options passed as parameters
+ * all helper functions are moved to more specialized packages, which are exposed as
+ go modules. Importing such a module would reduce the footprint of dependencies.
+ * _all_ functions, variables, constants exposed by the deprecated API have now moved, so
+ that consumers of the new API no longer need to import github.com/go-openapi/swag, but
+ should import the desired sub-module(s).
+
+**New with this release**:
+
+* [x] type converters and pointer to value helpers now support generic types
+* [x] name mangling now support pluralized initialisms (issue #46)
+ Strings like "contact IDs" are now recognized as such a plural form and mangled as a linter would expect.
+* [x] performance: small improvements to reduce the overhead of convert/format wrappers (see issues #110, or PR #108)
+* [x] performance: name mangling utilities run ~ 10% faster (PR #115)
+
+---
+
+## Licensing
+
+This library ships under the [SPDX-License-Identifier: Apache-2.0](./LICENSE).
+
+## Note to contributors
+
+A mono-repo structure comes with some unavoidable extra pains...
+
+* Testing
+
+> The usual `go test ./...` command, run from the root of this repo won't work any longer to test all submodules.
+>
+> Each module constitutes an independant unit of test. So you have to run `go test` inside each module.
+> Or you may take a look at how this is achieved by CI
+> [here] https://github.com/go-openapi/swag/blob/master/.github/workflows/go-test.yml).
+>
+> There are also some alternative tricks using `go work`, for local development, if you feel comfortable with
+> go workspaces. Perhaps some day, we'll have a `go work test` to run all tests without any hack.
+
+* Releasing
+
+> Each module follows its own independant module versioning.
+>
+> So you have tags like `mangling/v0.24.0`, `fileutils/v0.24.0` etc that are used by `go mod` and `go get`
+> to refer to the tagged version of each module specifically.
+>
+> This means we may release patches etc to each module independently.
+>
+> We'd like to adopt the rule that modules in this repo would only differ by a patch version
+> (e.g. `v0.24.5` vs `v0.24.3`), and we'll level all modules whenever a minor version is introduced.
+>
+> A script in `./hack` is provided to tag all modules with the same version in one go.
+
+* Continuous integration
+
+> At this moment, all tests in all modules are systematically run over the full test matrix (3 platform x 2 go releases).
+> This generates quite a lot of jobs.
+>
+> We ought to reduce the number of jobs required to test a PR focused on only a few modules.
+
+## Todos, suggestions and plans
+
+All kinds of contributions are welcome.
+
+A few ideas:
+
+* [x] Complete the split of dependencies to isolate easyjson from the rest
+* [x] Improve CI to reduce needed tests
+* [x] Replace dependency to `gopkg.in/yaml.v3` (`yamlutil`)
+* [ ] Improve mangling utilities (improve readability, support for capitalized words,
+ better word substitution for non-letter symbols...)
+* [ ] Move back to this common shared pot a few of the technical features introduced by go-swagger independently
+ (e.g. mangle go package names, search package with go modules support, ...)
+* [ ] Apply a similar mono-repo approach to go-openapi/strfmt which suffer from similar woes: bloated API,
+ imposed dependency to some database driver.
+* [ ] Adapt `go-swagger` (incl. generated code) to the new `swag` API.
+* [ ] Factorize some tests, as there is a lot of redundant testing code in `jsonutils`
+* [ ] Benchmark & profiling: publish independently the tool built to analyze and chart benchmarks (e.g. similar to `benchvisual`)
+* [ ] more thorough testing for nil / null case
+* [ ] ci pipeline to manage releases
+* [ ] cleaner mockery generation (doesn't work out of the box for all sub-modules)
diff --git a/vendor/github.com/go-openapi/swag/SECURITY.md b/vendor/github.com/go-openapi/swag/SECURITY.md
new file mode 100644
index 0000000000..72296a8313
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/SECURITY.md
@@ -0,0 +1,19 @@
+# Security Policy
+
+This policy outlines the commitment and practices of the go-openapi maintainers regarding security.
+
+## Supported Versions
+
+| Version | Supported |
+| ------- | ------------------ |
+| 0.25.x | :white_check_mark: |
+
+## Reporting a vulnerability
+
+If you become aware of a security vulnerability that affects the current repository,
+please report it privately to the maintainers.
+
+Please follow the instructions provided by github to
+[Privately report a security vulnerability](https://docs.github.com/en/code-security/security-advisories/guidance-on-reporting-and-writing-information-about-vulnerabilities/privately-reporting-a-security-vulnerability#privately-reporting-a-security-vulnerability).
+
+TL;DR: on Github, navigate to the project's "Security" tab then click on "Report a vulnerability".
diff --git a/vendor/github.com/google/btree/LICENSE b/vendor/github.com/go-openapi/swag/cmdutils/LICENSE
similarity index 100%
rename from vendor/github.com/google/btree/LICENSE
rename to vendor/github.com/go-openapi/swag/cmdutils/LICENSE
diff --git a/vendor/github.com/go-openapi/swag/cmdutils/cmd_utils.go b/vendor/github.com/go-openapi/swag/cmdutils/cmd_utils.go
new file mode 100644
index 0000000000..6c7bbb26f0
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/cmdutils/cmd_utils.go
@@ -0,0 +1,13 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package cmdutils
+
+// CommandLineOptionsGroup represents a group of user-defined command line options.
+//
+// This is for instance used to configure command line arguments in API servers generated by go-swagger.
+type CommandLineOptionsGroup struct {
+ ShortDescription string
+ LongDescription string
+ Options any
+}
diff --git a/vendor/github.com/go-openapi/swag/cmdutils/doc.go b/vendor/github.com/go-openapi/swag/cmdutils/doc.go
new file mode 100644
index 0000000000..31f2c37538
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/cmdutils/doc.go
@@ -0,0 +1,5 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+// Package cmdutils brings helpers for CLIs produced by go-openapi
+package cmdutils
diff --git a/vendor/github.com/go-openapi/swag/cmdutils_iface.go b/vendor/github.com/go-openapi/swag/cmdutils_iface.go
new file mode 100644
index 0000000000..bd0c1fc128
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/cmdutils_iface.go
@@ -0,0 +1,11 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package swag
+
+import "github.com/go-openapi/swag/cmdutils"
+
+// CommandLineOptionsGroup represents a group of user-defined command line options.
+//
+// Deprecated: use [cmdutils.CommandLineOptionsGroup] instead.
+type CommandLineOptionsGroup = cmdutils.CommandLineOptionsGroup
diff --git a/vendor/github.com/go-openapi/swag/conv/LICENSE b/vendor/github.com/go-openapi/swag/conv/LICENSE
new file mode 100644
index 0000000000..d645695673
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/conv/LICENSE
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/vendor/github.com/go-openapi/swag/conv/convert.go b/vendor/github.com/go-openapi/swag/conv/convert.go
new file mode 100644
index 0000000000..f205c39134
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/conv/convert.go
@@ -0,0 +1,161 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package conv
+
+import (
+ "math"
+ "strconv"
+ "strings"
+)
+
+// same as ECMA Number.MAX_SAFE_INTEGER and Number.MIN_SAFE_INTEGER
+const (
+ maxJSONFloat = float64(1<<53 - 1) // 9007199254740991.0 2^53 - 1
+ minJSONFloat = -float64(1<<53 - 1) //-9007199254740991.0 -2^53 - 1
+ epsilon float64 = 1e-9
+)
+
+// IsFloat64AJSONInteger allows for integers [-2^53, 2^53-1] inclusive.
+func IsFloat64AJSONInteger(f float64) bool {
+ if math.IsNaN(f) || math.IsInf(f, 0) || f < minJSONFloat || f > maxJSONFloat {
+ return false
+ }
+ rounded := math.Round(f)
+ if f == rounded {
+ return true
+ }
+ if rounded == 0 { // f = 0.0 exited above
+ return false
+ }
+
+ diff := math.Abs(f - rounded)
+ if diff == 0 {
+ return true
+ }
+
+ // relative error Abs{f - Round(f)) / Round(f)} < ε ; Round(f)
+ return diff < epsilon*math.Abs(rounded)
+}
+
+// ConvertFloat turns a string into a float numerical value.
+func ConvertFloat[T Float](str string) (T, error) {
+ var v T
+ f, err := strconv.ParseFloat(str, bitsize(v))
+ if err != nil {
+ return 0, err
+ }
+
+ return T(f), nil
+}
+
+// ConvertInteger turns a string into a signed integer.
+func ConvertInteger[T Signed](str string) (T, error) {
+ var v T
+ f, err := strconv.ParseInt(str, 10, bitsize(v))
+ if err != nil {
+ return 0, err
+ }
+
+ return T(f), nil
+}
+
+// ConvertUinteger turns a string into an unsigned integer.
+func ConvertUinteger[T Unsigned](str string) (T, error) {
+ var v T
+ f, err := strconv.ParseUint(str, 10, bitsize(v))
+ if err != nil {
+ return 0, err
+ }
+
+ return T(f), nil
+}
+
+// ConvertBool turns a string into a boolean.
+//
+// It supports a few more "true" strings than [strconv.ParseBool]:
+//
+// - it is not case sensitive ("trUe" or "FalsE" work)
+// - "ok", "yes", "y", "on", "selected", "checked", "enabled" are all true
+// - everything that is not true is false: there is never an actual error returned
+func ConvertBool(str string) (bool, error) {
+ switch strings.ToLower(str) {
+ case "true",
+ "1",
+ "yes",
+ "ok",
+ "y",
+ "on",
+ "selected",
+ "checked",
+ "t",
+ "enabled":
+ return true, nil
+ default:
+ return false, nil
+ }
+}
+
+// ConvertFloat32 turns a string into a float32.
+func ConvertFloat32(str string) (float32, error) { return ConvertFloat[float32](str) }
+
+// ConvertFloat64 turns a string into a float64
+func ConvertFloat64(str string) (float64, error) { return ConvertFloat[float64](str) }
+
+// ConvertInt8 turns a string into an int8
+func ConvertInt8(str string) (int8, error) { return ConvertInteger[int8](str) }
+
+// ConvertInt16 turns a string into an int16
+func ConvertInt16(str string) (int16, error) {
+ i, err := strconv.ParseInt(str, 10, 16)
+ if err != nil {
+ return 0, err
+ }
+ return int16(i), nil
+}
+
+// ConvertInt32 turns a string into an int32
+func ConvertInt32(str string) (int32, error) {
+ i, err := strconv.ParseInt(str, 10, 32)
+ if err != nil {
+ return 0, err
+ }
+ return int32(i), nil
+}
+
+// ConvertInt64 turns a string into an int64
+func ConvertInt64(str string) (int64, error) {
+ return strconv.ParseInt(str, 10, 64)
+}
+
+// ConvertUint8 turns a string into an uint8
+func ConvertUint8(str string) (uint8, error) {
+ i, err := strconv.ParseUint(str, 10, 8)
+ if err != nil {
+ return 0, err
+ }
+ return uint8(i), nil
+}
+
+// ConvertUint16 turns a string into an uint16
+func ConvertUint16(str string) (uint16, error) {
+ i, err := strconv.ParseUint(str, 10, 16)
+ if err != nil {
+ return 0, err
+ }
+ return uint16(i), nil
+}
+
+// ConvertUint32 turns a string into an uint32
+func ConvertUint32(str string) (uint32, error) {
+ i, err := strconv.ParseUint(str, 10, 32)
+ if err != nil {
+ return 0, err
+ }
+ return uint32(i), nil
+}
+
+// ConvertUint64 turns a string into an uint64
+func ConvertUint64(str string) (uint64, error) {
+ return strconv.ParseUint(str, 10, 64)
+}
diff --git a/vendor/github.com/go-openapi/swag/conv/convert_types.go b/vendor/github.com/go-openapi/swag/conv/convert_types.go
new file mode 100644
index 0000000000..cf4c6495eb
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/conv/convert_types.go
@@ -0,0 +1,72 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package conv
+
+// Unlicensed credits (idea, concept)
+//
+// The idea to convert values to pointers and the other way around, was inspired, eons ago, by the aws go sdk.
+//
+// Nowadays, all sensible API sdk's expose a similar functionality.
+
+// Pointer returns a pointer to the value passed in.
+func Pointer[T any](v T) *T {
+ return &v
+}
+
+// Value returns a shallow copy of the value of the pointer passed in.
+//
+// If the pointer is nil, the returned value is the zero value.
+func Value[T any](v *T) T {
+ if v != nil {
+ return *v
+ }
+
+ var zero T
+ return zero
+}
+
+// PointerSlice converts a slice of values into a slice of pointers.
+func PointerSlice[T any](src []T) []*T {
+ dst := make([]*T, len(src))
+ for i := 0; i < len(src); i++ {
+ dst[i] = &(src[i])
+ }
+ return dst
+}
+
+// ValueSlice converts a slice of pointers into a slice of values.
+//
+// nil elements are zero values.
+func ValueSlice[T any](src []*T) []T {
+ dst := make([]T, len(src))
+ for i := 0; i < len(src); i++ {
+ if src[i] != nil {
+ dst[i] = *(src[i])
+ }
+ }
+ return dst
+}
+
+// PointerMap converts a map of values into a map of pointers.
+func PointerMap[K comparable, T any](src map[K]T) map[K]*T {
+ dst := make(map[K]*T)
+ for k, val := range src {
+ v := val
+ dst[k] = &v
+ }
+ return dst
+}
+
+// ValueMap converts a map of pointers into a map of values.
+//
+// nil elements are skipped.
+func ValueMap[K comparable, T any](src map[K]*T) map[K]T {
+ dst := make(map[K]T)
+ for k, val := range src {
+ if val != nil {
+ dst[k] = *val
+ }
+ }
+ return dst
+}
diff --git a/vendor/github.com/go-openapi/swag/conv/doc.go b/vendor/github.com/go-openapi/swag/conv/doc.go
new file mode 100644
index 0000000000..1bd6ead6e2
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/conv/doc.go
@@ -0,0 +1,15 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+// Package conv exposes utilities to convert types.
+//
+// The Convert and Format families of functions are essentially a shorthand to [strconv] functions,
+// using the decimal representation of numbers.
+//
+// Features:
+//
+// - from string representation to value ("Convert*") and reciprocally ("Format*")
+// - from pointer to value ([Value]) and reciprocally ([Pointer])
+// - from slice of values to slice of pointers ([PointerSlice]) and reciprocally ([ValueSlice])
+// - from map of values to map of pointers ([PointerMap]) and reciprocally ([ValueMap])
+package conv
diff --git a/vendor/github.com/go-openapi/swag/conv/format.go b/vendor/github.com/go-openapi/swag/conv/format.go
new file mode 100644
index 0000000000..5b87b8e146
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/conv/format.go
@@ -0,0 +1,28 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package conv
+
+import (
+ "strconv"
+)
+
+// FormatInteger turns an integer type into a string.
+func FormatInteger[T Signed](value T) string {
+ return strconv.FormatInt(int64(value), 10)
+}
+
+// FormatUinteger turns an unsigned integer type into a string.
+func FormatUinteger[T Unsigned](value T) string {
+ return strconv.FormatUint(uint64(value), 10)
+}
+
+// FormatFloat turns a floating point numerical value into a string.
+func FormatFloat[T Float](value T) string {
+ return strconv.FormatFloat(float64(value), 'f', -1, bitsize(value))
+}
+
+// FormatBool turns a boolean into a string.
+func FormatBool(value bool) string {
+ return strconv.FormatBool(value)
+}
diff --git a/vendor/github.com/go-openapi/swag/conv/sizeof.go b/vendor/github.com/go-openapi/swag/conv/sizeof.go
new file mode 100644
index 0000000000..4943465573
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/conv/sizeof.go
@@ -0,0 +1,20 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package conv
+
+import "unsafe"
+
+// bitsize returns the size in bits of a type.
+//
+// NOTE: [unsafe.SizeOf] simply returns the size in bytes of the value.
+// For primitive types T, the generic stencil is precompiled and this value
+// is resolved at compile time, resulting in an immediate call to [strconv.ParseFloat].
+//
+// We may leave up to the go compiler to simplify this function into a
+// constant value, which happens in practice at least for primitive types
+// (e.g. numerical types).
+func bitsize[T Numerical](value T) int {
+ const bitsPerByte = 8
+ return int(unsafe.Sizeof(value)) * bitsPerByte
+}
diff --git a/vendor/github.com/go-openapi/swag/conv/type_constraints.go b/vendor/github.com/go-openapi/swag/conv/type_constraints.go
new file mode 100644
index 0000000000..81135e827e
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/conv/type_constraints.go
@@ -0,0 +1,29 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package conv
+
+type (
+ // these type constraints are redefined after golang.org/x/exp/constraints,
+ // because importing that package causes an undesired go upgrade.
+
+ // Signed integer types, cf. [golang.org/x/exp/constraints.Signed]
+ Signed interface {
+ ~int | ~int8 | ~int16 | ~int32 | ~int64
+ }
+
+ // Unsigned integer types, cf. [golang.org/x/exp/constraints.Unsigned]
+ Unsigned interface {
+ ~uint | ~uint8 | ~uint16 | ~uint32 | ~uint64 | ~uintptr
+ }
+
+ // Float numerical types, cf. [golang.org/x/exp/constraints.Float]
+ Float interface {
+ ~float32 | ~float64
+ }
+
+ // Numerical types
+ Numerical interface {
+ Signed | Unsigned | Float
+ }
+)
diff --git a/vendor/github.com/go-openapi/swag/conv_iface.go b/vendor/github.com/go-openapi/swag/conv_iface.go
new file mode 100644
index 0000000000..eea7b2e56e
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/conv_iface.go
@@ -0,0 +1,486 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package swag
+
+import (
+ "time"
+
+ "github.com/go-openapi/swag/conv"
+)
+
+// IsFloat64AJSONInteger allows for integers [-2^53, 2^53-1] inclusive.
+//
+// Deprecated: use [conv.IsFloat64AJSONInteger] instead.
+func IsFloat64AJSONInteger(f float64) bool { return conv.IsFloat64AJSONInteger(f) }
+
+// ConvertBool turns a string into a boolean.
+//
+// Deprecated: use [conv.ConvertBool] instead.
+func ConvertBool(str string) (bool, error) { return conv.ConvertBool(str) }
+
+// ConvertFloat32 turns a string into a float32.
+//
+// Deprecated: use [conv.ConvertFloat32] instead. Alternatively, you may use the generic version [conv.ConvertFloat].
+func ConvertFloat32(str string) (float32, error) { return conv.ConvertFloat[float32](str) }
+
+// ConvertFloat64 turns a string into a float64.
+//
+// Deprecated: use [conv.ConvertFloat64] instead. Alternatively, you may use the generic version [conv.ConvertFloat].
+func ConvertFloat64(str string) (float64, error) { return conv.ConvertFloat[float64](str) }
+
+// ConvertInt8 turns a string into an int8.
+//
+// Deprecated: use [conv.ConvertInt8] instead. Alternatively, you may use the generic version [conv.ConvertInteger].
+func ConvertInt8(str string) (int8, error) { return conv.ConvertInteger[int8](str) }
+
+// ConvertInt16 turns a string into an int16.
+//
+// Deprecated: use [conv.ConvertInt16] instead. Alternatively, you may use the generic version [conv.ConvertInteger].
+func ConvertInt16(str string) (int16, error) { return conv.ConvertInteger[int16](str) }
+
+// ConvertInt32 turns a string into an int32.
+//
+// Deprecated: use [conv.ConvertInt32] instead. Alternatively, you may use the generic version [conv.ConvertInteger].
+func ConvertInt32(str string) (int32, error) { return conv.ConvertInteger[int32](str) }
+
+// ConvertInt64 turns a string into an int64.
+//
+// Deprecated: use [conv.ConvertInt64] instead. Alternatively, you may use the generic version [conv.ConvertInteger].
+func ConvertInt64(str string) (int64, error) { return conv.ConvertInteger[int64](str) }
+
+// ConvertUint8 turns a string into an uint8.
+//
+// Deprecated: use [conv.ConvertUint8] instead. Alternatively, you may use the generic version [conv.ConvertUinteger].
+func ConvertUint8(str string) (uint8, error) { return conv.ConvertUinteger[uint8](str) }
+
+// ConvertUint16 turns a string into an uint16.
+//
+// Deprecated: use [conv.ConvertUint16] instead. Alternatively, you may use the generic version [conv.ConvertUinteger].
+func ConvertUint16(str string) (uint16, error) { return conv.ConvertUinteger[uint16](str) }
+
+// ConvertUint32 turns a string into an uint32.
+//
+// Deprecated: use [conv.ConvertUint32] instead. Alternatively, you may use the generic version [conv.ConvertUinteger].
+func ConvertUint32(str string) (uint32, error) { return conv.ConvertUinteger[uint32](str) }
+
+// ConvertUint64 turns a string into an uint64.
+//
+// Deprecated: use [conv.ConvertUint64] instead. Alternatively, you may use the generic version [conv.ConvertUinteger].
+func ConvertUint64(str string) (uint64, error) { return conv.ConvertUinteger[uint64](str) }
+
+// FormatBool turns a boolean into a string.
+//
+// Deprecated: use [conv.FormatBool] instead.
+func FormatBool(value bool) string { return conv.FormatBool(value) }
+
+// FormatFloat32 turns a float32 into a string.
+//
+// Deprecated: use [conv.FormatFloat] instead.
+func FormatFloat32(value float32) string { return conv.FormatFloat(value) }
+
+// FormatFloat64 turns a float64 into a string.
+//
+// Deprecated: use [conv.FormatFloat] instead.
+func FormatFloat64(value float64) string { return conv.FormatFloat(value) }
+
+// FormatInt8 turns an int8 into a string.
+//
+// Deprecated: use [conv.FormatInteger] instead.
+func FormatInt8(value int8) string { return conv.FormatInteger(value) }
+
+// FormatInt16 turns an int16 into a string.
+//
+// Deprecated: use [conv.FormatInteger] instead.
+func FormatInt16(value int16) string { return conv.FormatInteger(value) }
+
+// FormatInt32 turns an int32 into a string
+//
+// Deprecated: use [conv.FormatInteger] instead.
+func FormatInt32(value int32) string { return conv.FormatInteger(value) }
+
+// FormatInt64 turns an int64 into a string.
+//
+// Deprecated: use [conv.FormatInteger] instead.
+func FormatInt64(value int64) string { return conv.FormatInteger(value) }
+
+// FormatUint8 turns an uint8 into a string.
+//
+// Deprecated: use [conv.FormatUinteger] instead.
+func FormatUint8(value uint8) string { return conv.FormatUinteger(value) }
+
+// FormatUint16 turns an uint16 into a string.
+//
+// Deprecated: use [conv.FormatUinteger] instead.
+func FormatUint16(value uint16) string { return conv.FormatUinteger(value) }
+
+// FormatUint32 turns an uint32 into a string.
+//
+// Deprecated: use [conv.FormatUinteger] instead.
+func FormatUint32(value uint32) string { return conv.FormatUinteger(value) }
+
+// FormatUint64 turns an uint64 into a string.
+//
+// Deprecated: use [conv.FormatUinteger] instead.
+func FormatUint64(value uint64) string { return conv.FormatUinteger(value) }
+
+// String turn a pointer to of the string value passed in.
+//
+// Deprecated: use [conv.Pointer] instead.
+func String(v string) *string { return conv.Pointer(v) }
+
+// StringValue turn the value of the string pointer passed in or
+// "" if the pointer is nil.
+//
+// Deprecated: use [conv.Value] instead.
+func StringValue(v *string) string { return conv.Value(v) }
+
+// StringSlice converts a slice of string values into a slice of string pointers.
+//
+// Deprecated: use [conv.PointerSlice] instead.
+func StringSlice(src []string) []*string { return conv.PointerSlice(src) }
+
+// StringValueSlice converts a slice of string pointers into a slice of string values.
+//
+// Deprecated: use [conv.ValueSlice] instead.
+func StringValueSlice(src []*string) []string { return conv.ValueSlice(src) }
+
+// StringMap converts a string map of string values into a string map of string pointers.
+//
+// Deprecated: use [conv.PointerMap] instead.
+func StringMap(src map[string]string) map[string]*string { return conv.PointerMap(src) }
+
+// StringValueMap converts a string map of string pointers into a string map of string values.
+//
+// Deprecated: use [conv.ValueMap] instead.
+func StringValueMap(src map[string]*string) map[string]string { return conv.ValueMap(src) }
+
+// Bool turn a pointer to of the bool value passed in.
+//
+// Deprecated: use [conv.Pointer] instead.
+func Bool(v bool) *bool { return conv.Pointer(v) }
+
+// BoolValue turn the value of the bool pointer passed in or false if the pointer is nil.
+//
+// Deprecated: use [conv.Value] instead.
+func BoolValue(v *bool) bool { return conv.Value(v) }
+
+// BoolSlice converts a slice of bool values into a slice of bool pointers.
+//
+// Deprecated: use [conv.PointerSlice] instead.
+func BoolSlice(src []bool) []*bool { return conv.PointerSlice(src) }
+
+// BoolValueSlice converts a slice of bool pointers into a slice of bool values.
+//
+// Deprecated: use [conv.ValueSlice] instead.
+func BoolValueSlice(src []*bool) []bool { return conv.ValueSlice(src) }
+
+// BoolMap converts a string map of bool values into a string map of bool pointers.
+//
+// Deprecated: use [conv.PointerMap] instead.
+func BoolMap(src map[string]bool) map[string]*bool { return conv.PointerMap(src) }
+
+// BoolValueMap converts a string map of bool pointers into a string map of bool values.
+//
+// Deprecated: use [conv.ValueMap] instead.
+func BoolValueMap(src map[string]*bool) map[string]bool { return conv.ValueMap(src) }
+
+// Int turn a pointer to of the int value passed in.
+//
+// Deprecated: use [conv.Pointer] instead.
+func Int(v int) *int { return conv.Pointer(v) }
+
+// IntValue turn the value of the int pointer passed in or 0 if the pointer is nil.
+//
+// Deprecated: use [conv.Value] instead.
+func IntValue(v *int) int { return conv.Value(v) }
+
+// IntSlice converts a slice of int values into a slice of int pointers.
+//
+// Deprecated: use [conv.PointerSlice] instead.
+func IntSlice(src []int) []*int { return conv.PointerSlice(src) }
+
+// IntValueSlice converts a slice of int pointers into a slice of int values.
+//
+// Deprecated: use [conv.ValueSlice] instead.
+func IntValueSlice(src []*int) []int { return conv.ValueSlice(src) }
+
+// IntMap converts a string map of int values into a string map of int pointers.
+//
+// Deprecated: use [conv.PointerMap] instead.
+func IntMap(src map[string]int) map[string]*int { return conv.PointerMap(src) }
+
+// IntValueMap converts a string map of int pointers into a string map of int values.
+//
+// Deprecated: use [conv.ValueMap] instead.
+func IntValueMap(src map[string]*int) map[string]int { return conv.ValueMap(src) }
+
+// Int32 turn a pointer to of the int32 value passed in.
+//
+// Deprecated: use [conv.Pointer] instead.
+func Int32(v int32) *int32 { return conv.Pointer(v) }
+
+// Int32Value turn the value of the int32 pointer passed in or 0 if the pointer is nil.
+//
+// Deprecated: use [conv.Value] instead.
+func Int32Value(v *int32) int32 { return conv.Value(v) }
+
+// Int32Slice converts a slice of int32 values into a slice of int32 pointers.
+//
+// Deprecated: use [conv.PointerSlice] instead.
+func Int32Slice(src []int32) []*int32 { return conv.PointerSlice(src) }
+
+// Int32ValueSlice converts a slice of int32 pointers into a slice of int32 values.
+//
+// Deprecated: use [conv.ValueSlice] instead.
+func Int32ValueSlice(src []*int32) []int32 { return conv.ValueSlice(src) }
+
+// Int32Map converts a string map of int32 values into a string map of int32 pointers.
+//
+// Deprecated: use [conv.PointerMap] instead.
+func Int32Map(src map[string]int32) map[string]*int32 { return conv.PointerMap(src) }
+
+// Int32ValueMap converts a string map of int32 pointers into a string map of int32 values.
+//
+// Deprecated: use [conv.ValueMap] instead.
+func Int32ValueMap(src map[string]*int32) map[string]int32 { return conv.ValueMap(src) }
+
+// Int64 turn a pointer to of the int64 value passed in.
+//
+// Deprecated: use [conv.Pointer] instead.
+func Int64(v int64) *int64 { return conv.Pointer(v) }
+
+// Int64Value turn the value of the int64 pointer passed in or 0 if the pointer is nil.
+//
+// Deprecated: use [conv.Value] instead.
+func Int64Value(v *int64) int64 { return conv.Value(v) }
+
+// Int64Slice converts a slice of int64 values into a slice of int64 pointers.
+//
+// Deprecated: use [conv.PointerSlice] instead.
+func Int64Slice(src []int64) []*int64 { return conv.PointerSlice(src) }
+
+// Int64ValueSlice converts a slice of int64 pointers into a slice of int64 values.
+//
+// Deprecated: use [conv.ValueSlice] instead.
+func Int64ValueSlice(src []*int64) []int64 { return conv.ValueSlice(src) }
+
+// Int64Map converts a string map of int64 values into a string map of int64 pointers.
+//
+// Deprecated: use [conv.PointerMap] instead.
+func Int64Map(src map[string]int64) map[string]*int64 { return conv.PointerMap(src) }
+
+// Int64ValueMap converts a string map of int64 pointers into a string map of int64 values.
+//
+// Deprecated: use [conv.ValueMap] instead.
+func Int64ValueMap(src map[string]*int64) map[string]int64 { return conv.ValueMap(src) }
+
+// Uint16 turn a pointer to of the uint16 value passed in.
+//
+// Deprecated: use [conv.Pointer] instead.
+func Uint16(v uint16) *uint16 { return conv.Pointer(v) }
+
+// Uint16Value turn the value of the uint16 pointer passed in or 0 if the pointer is nil.
+//
+// Deprecated: use [conv.Value] instead.
+func Uint16Value(v *uint16) uint16 { return conv.Value(v) }
+
+// Uint16Slice converts a slice of uint16 values into a slice of uint16 pointers.
+//
+// Deprecated: use [conv.PointerSlice] instead.
+func Uint16Slice(src []uint16) []*uint16 { return conv.PointerSlice(src) }
+
+// Uint16ValueSlice converts a slice of uint16 pointers into a slice of uint16 values.
+//
+// Deprecated: use [conv.ValueSlice] instead.
+func Uint16ValueSlice(src []*uint16) []uint16 { return conv.ValueSlice(src) }
+
+// Uint16Map converts a string map of uint16 values into a string map of uint16 pointers.
+//
+// Deprecated: use [conv.PointerMap] instead.
+func Uint16Map(src map[string]uint16) map[string]*uint16 { return conv.PointerMap(src) }
+
+// Uint16ValueMap converts a string map of uint16 pointers into a string map of uint16 values.
+//
+// Deprecated: use [conv.ValueMap] instead.
+func Uint16ValueMap(src map[string]*uint16) map[string]uint16 { return conv.ValueMap(src) }
+
+// Uint turn a pointer to of the uint value passed in.
+//
+// Deprecated: use [conv.Pointer] instead.
+func Uint(v uint) *uint { return conv.Pointer(v) }
+
+// UintValue turn the value of the uint pointer passed in or 0 if the pointer is nil.
+//
+// Deprecated: use [conv.Value] instead.
+func UintValue(v *uint) uint { return conv.Value(v) }
+
+// UintSlice converts a slice of uint values into a slice of uint pointers.
+//
+// Deprecated: use [conv.PointerSlice] instead.
+func UintSlice(src []uint) []*uint { return conv.PointerSlice(src) }
+
+// UintValueSlice converts a slice of uint pointers into a slice of uint values.
+//
+// Deprecated: use [conv.ValueSlice] instead.
+func UintValueSlice(src []*uint) []uint { return conv.ValueSlice(src) }
+
+// UintMap converts a string map of uint values into a string map of uint pointers.
+//
+// Deprecated: use [conv.PointerMap] instead.
+func UintMap(src map[string]uint) map[string]*uint { return conv.PointerMap(src) }
+
+// UintValueMap converts a string map of uint pointers into a string map of uint values.
+//
+// Deprecated: use [conv.ValueMap] instead.
+func UintValueMap(src map[string]*uint) map[string]uint { return conv.ValueMap(src) }
+
+// Uint32 turn a pointer to of the uint32 value passed in.
+//
+// Deprecated: use [conv.Pointer] instead.
+func Uint32(v uint32) *uint32 { return conv.Pointer(v) }
+
+// Uint32Value turn the value of the uint32 pointer passed in or 0 if the pointer is nil.
+//
+// Deprecated: use [conv.Value] instead.
+func Uint32Value(v *uint32) uint32 { return conv.Value(v) }
+
+// Uint32Slice converts a slice of uint32 values into a slice of uint32 pointers.
+//
+// Deprecated: use [conv.PointerSlice] instead.
+func Uint32Slice(src []uint32) []*uint32 { return conv.PointerSlice(src) }
+
+// Uint32ValueSlice converts a slice of uint32 pointers into a slice of uint32 values.
+//
+// Deprecated: use [conv.ValueSlice] instead.
+func Uint32ValueSlice(src []*uint32) []uint32 { return conv.ValueSlice(src) }
+
+// Uint32Map converts a string map of uint32 values into a string map of uint32 pointers.
+//
+// Deprecated: use [conv.PointerMap] instead.
+func Uint32Map(src map[string]uint32) map[string]*uint32 { return conv.PointerMap(src) }
+
+// Uint32ValueMap converts a string map of uint32 pointers into a string map of uint32 values.
+//
+// Deprecated: use [conv.ValueMap] instead.
+func Uint32ValueMap(src map[string]*uint32) map[string]uint32 { return conv.ValueMap(src) }
+
+// Uint64 turn a pointer to of the uint64 value passed in.
+//
+// Deprecated: use [conv.Pointer] instead.
+func Uint64(v uint64) *uint64 { return conv.Pointer(v) }
+
+// Uint64Value turn the value of the uint64 pointer passed in or 0 if the pointer is nil.
+//
+// Deprecated: use [conv.Value] instead.
+func Uint64Value(v *uint64) uint64 { return conv.Value(v) }
+
+// Uint64Slice converts a slice of uint64 values into a slice of uint64 pointers.
+//
+// Deprecated: use [conv.PointerSlice] instead.
+func Uint64Slice(src []uint64) []*uint64 { return conv.PointerSlice(src) }
+
+// Uint64ValueSlice converts a slice of uint64 pointers into a slice of uint64 values.
+//
+// Deprecated: use [conv.ValueSlice] instead.
+func Uint64ValueSlice(src []*uint64) []uint64 { return conv.ValueSlice(src) }
+
+// Uint64Map converts a string map of uint64 values into a string map of uint64 pointers.
+//
+// Deprecated: use [conv.PointerMap] instead.
+func Uint64Map(src map[string]uint64) map[string]*uint64 { return conv.PointerMap(src) }
+
+// Uint64ValueMap converts a string map of uint64 pointers into a string map of uint64 values.
+//
+// Deprecated: use [conv.ValueMap] instead.
+func Uint64ValueMap(src map[string]*uint64) map[string]uint64 { return conv.ValueMap(src) }
+
+// Float32 turn a pointer to of the float32 value passed in.
+//
+// Deprecated: use [conv.Pointer] instead.
+func Float32(v float32) *float32 { return conv.Pointer(v) }
+
+// Float32Value turn the value of the float32 pointer passed in or 0 if the pointer is nil.
+//
+// Deprecated: use [conv.Value] instead.
+func Float32Value(v *float32) float32 { return conv.Value(v) }
+
+// Float32Slice converts a slice of float32 values into a slice of float32 pointers.
+//
+// Deprecated: use [conv.PointerSlice] instead.
+func Float32Slice(src []float32) []*float32 { return conv.PointerSlice(src) }
+
+// Float32ValueSlice converts a slice of float32 pointers into a slice of float32 values.
+//
+// Deprecated: use [conv.ValueSlice] instead.
+func Float32ValueSlice(src []*float32) []float32 { return conv.ValueSlice(src) }
+
+// Float32Map converts a string map of float32 values into a string map of float32 pointers.
+//
+// Deprecated: use [conv.PointerMap] instead.
+func Float32Map(src map[string]float32) map[string]*float32 { return conv.PointerMap(src) }
+
+// Float32ValueMap converts a string map of float32 pointers into a string map of float32 values.
+//
+// Deprecated: use [conv.ValueMap] instead.
+func Float32ValueMap(src map[string]*float32) map[string]float32 { return conv.ValueMap(src) }
+
+// Float64 turn a pointer to of the float64 value passed in.
+//
+// Deprecated: use [conv.Pointer] instead.
+func Float64(v float64) *float64 { return conv.Pointer(v) }
+
+// Float64Value turn the value of the float64 pointer passed in or 0 if the pointer is nil.
+//
+// Deprecated: use [conv.Value] instead.
+func Float64Value(v *float64) float64 { return conv.Value(v) }
+
+// Float64Slice converts a slice of float64 values into a slice of float64 pointers.
+//
+// Deprecated: use [conv.PointerSlice] instead.
+func Float64Slice(src []float64) []*float64 { return conv.PointerSlice(src) }
+
+// Float64ValueSlice converts a slice of float64 pointers into a slice of float64 values.
+//
+// Deprecated: use [conv.ValueSlice] instead.
+func Float64ValueSlice(src []*float64) []float64 { return conv.ValueSlice(src) }
+
+// Float64Map converts a string map of float64 values into a string map of float64 pointers.
+//
+// Deprecated: use [conv.PointerMap] instead.
+func Float64Map(src map[string]float64) map[string]*float64 { return conv.PointerMap(src) }
+
+// Float64ValueMap converts a string map of float64 pointers into a string map of float64 values.
+//
+// Deprecated: use [conv.ValueMap] instead.
+func Float64ValueMap(src map[string]*float64) map[string]float64 { return conv.ValueMap(src) }
+
+// Time turn a pointer to of the time.Time value passed in.
+//
+// Deprecated: use [conv.Pointer] instead.
+func Time(v time.Time) *time.Time { return conv.Pointer(v) }
+
+// TimeValue turn the value of the time.Time pointer passed in or time.Time{} if the pointer is nil.
+//
+// Deprecated: use [conv.Value] instead.
+func TimeValue(v *time.Time) time.Time { return conv.Value(v) }
+
+// TimeSlice converts a slice of time.Time values into a slice of time.Time pointers.
+//
+// Deprecated: use [conv.PointerSlice] instead.
+func TimeSlice(src []time.Time) []*time.Time { return conv.PointerSlice(src) }
+
+// TimeValueSlice converts a slice of time.Time pointers into a slice of time.Time values
+//
+// Deprecated: use [conv.ValueSlice] instead.
+func TimeValueSlice(src []*time.Time) []time.Time { return conv.ValueSlice(src) }
+
+// TimeMap converts a string map of time.Time values into a string map of time.Time pointers.
+//
+// Deprecated: use [conv.PointerMap] instead.
+func TimeMap(src map[string]time.Time) map[string]*time.Time { return conv.PointerMap(src) }
+
+// TimeValueMap converts a string map of time.Time pointers into a string map of time.Time values.
+//
+// Deprecated: use [conv.ValueMap] instead.
+func TimeValueMap(src map[string]*time.Time) map[string]time.Time { return conv.ValueMap(src) }
diff --git a/vendor/github.com/go-openapi/swag/convert.go b/vendor/github.com/go-openapi/swag/convert.go
deleted file mode 100644
index fc085aeb8e..0000000000
--- a/vendor/github.com/go-openapi/swag/convert.go
+++ /dev/null
@@ -1,208 +0,0 @@
-// Copyright 2015 go-swagger maintainers
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-package swag
-
-import (
- "math"
- "strconv"
- "strings"
-)
-
-// same as ECMA Number.MAX_SAFE_INTEGER and Number.MIN_SAFE_INTEGER
-const (
- maxJSONFloat = float64(1<<53 - 1) // 9007199254740991.0 2^53 - 1
- minJSONFloat = -float64(1<<53 - 1) //-9007199254740991.0 -2^53 - 1
- epsilon float64 = 1e-9
-)
-
-// IsFloat64AJSONInteger allow for integers [-2^53, 2^53-1] inclusive
-func IsFloat64AJSONInteger(f float64) bool {
- if math.IsNaN(f) || math.IsInf(f, 0) || f < minJSONFloat || f > maxJSONFloat {
- return false
- }
- fa := math.Abs(f)
- g := float64(uint64(f))
- ga := math.Abs(g)
-
- diff := math.Abs(f - g)
-
- // more info: https://floating-point-gui.de/errors/comparison/#look-out-for-edge-cases
- switch {
- case f == g: // best case
- return true
- case f == float64(int64(f)) || f == float64(uint64(f)): // optimistic case
- return true
- case f == 0 || g == 0 || diff < math.SmallestNonzeroFloat64: // very close to 0 values
- return diff < (epsilon * math.SmallestNonzeroFloat64)
- }
- // check the relative error
- return diff/math.Min(fa+ga, math.MaxFloat64) < epsilon
-}
-
-var evaluatesAsTrue map[string]struct{}
-
-func init() {
- evaluatesAsTrue = map[string]struct{}{
- "true": {},
- "1": {},
- "yes": {},
- "ok": {},
- "y": {},
- "on": {},
- "selected": {},
- "checked": {},
- "t": {},
- "enabled": {},
- }
-}
-
-// ConvertBool turn a string into a boolean
-func ConvertBool(str string) (bool, error) {
- _, ok := evaluatesAsTrue[strings.ToLower(str)]
- return ok, nil
-}
-
-// ConvertFloat32 turn a string into a float32
-func ConvertFloat32(str string) (float32, error) {
- f, err := strconv.ParseFloat(str, 32)
- if err != nil {
- return 0, err
- }
- return float32(f), nil
-}
-
-// ConvertFloat64 turn a string into a float64
-func ConvertFloat64(str string) (float64, error) {
- return strconv.ParseFloat(str, 64)
-}
-
-// ConvertInt8 turn a string into an int8
-func ConvertInt8(str string) (int8, error) {
- i, err := strconv.ParseInt(str, 10, 8)
- if err != nil {
- return 0, err
- }
- return int8(i), nil
-}
-
-// ConvertInt16 turn a string into an int16
-func ConvertInt16(str string) (int16, error) {
- i, err := strconv.ParseInt(str, 10, 16)
- if err != nil {
- return 0, err
- }
- return int16(i), nil
-}
-
-// ConvertInt32 turn a string into an int32
-func ConvertInt32(str string) (int32, error) {
- i, err := strconv.ParseInt(str, 10, 32)
- if err != nil {
- return 0, err
- }
- return int32(i), nil
-}
-
-// ConvertInt64 turn a string into an int64
-func ConvertInt64(str string) (int64, error) {
- return strconv.ParseInt(str, 10, 64)
-}
-
-// ConvertUint8 turn a string into an uint8
-func ConvertUint8(str string) (uint8, error) {
- i, err := strconv.ParseUint(str, 10, 8)
- if err != nil {
- return 0, err
- }
- return uint8(i), nil
-}
-
-// ConvertUint16 turn a string into an uint16
-func ConvertUint16(str string) (uint16, error) {
- i, err := strconv.ParseUint(str, 10, 16)
- if err != nil {
- return 0, err
- }
- return uint16(i), nil
-}
-
-// ConvertUint32 turn a string into an uint32
-func ConvertUint32(str string) (uint32, error) {
- i, err := strconv.ParseUint(str, 10, 32)
- if err != nil {
- return 0, err
- }
- return uint32(i), nil
-}
-
-// ConvertUint64 turn a string into an uint64
-func ConvertUint64(str string) (uint64, error) {
- return strconv.ParseUint(str, 10, 64)
-}
-
-// FormatBool turns a boolean into a string
-func FormatBool(value bool) string {
- return strconv.FormatBool(value)
-}
-
-// FormatFloat32 turns a float32 into a string
-func FormatFloat32(value float32) string {
- return strconv.FormatFloat(float64(value), 'f', -1, 32)
-}
-
-// FormatFloat64 turns a float64 into a string
-func FormatFloat64(value float64) string {
- return strconv.FormatFloat(value, 'f', -1, 64)
-}
-
-// FormatInt8 turns an int8 into a string
-func FormatInt8(value int8) string {
- return strconv.FormatInt(int64(value), 10)
-}
-
-// FormatInt16 turns an int16 into a string
-func FormatInt16(value int16) string {
- return strconv.FormatInt(int64(value), 10)
-}
-
-// FormatInt32 turns an int32 into a string
-func FormatInt32(value int32) string {
- return strconv.Itoa(int(value))
-}
-
-// FormatInt64 turns an int64 into a string
-func FormatInt64(value int64) string {
- return strconv.FormatInt(value, 10)
-}
-
-// FormatUint8 turns an uint8 into a string
-func FormatUint8(value uint8) string {
- return strconv.FormatUint(uint64(value), 10)
-}
-
-// FormatUint16 turns an uint16 into a string
-func FormatUint16(value uint16) string {
- return strconv.FormatUint(uint64(value), 10)
-}
-
-// FormatUint32 turns an uint32 into a string
-func FormatUint32(value uint32) string {
- return strconv.FormatUint(uint64(value), 10)
-}
-
-// FormatUint64 turns an uint64 into a string
-func FormatUint64(value uint64) string {
- return strconv.FormatUint(value, 10)
-}
diff --git a/vendor/github.com/go-openapi/swag/convert_types.go b/vendor/github.com/go-openapi/swag/convert_types.go
deleted file mode 100644
index c49cc473a8..0000000000
--- a/vendor/github.com/go-openapi/swag/convert_types.go
+++ /dev/null
@@ -1,730 +0,0 @@
-package swag
-
-import "time"
-
-// This file was taken from the aws go sdk
-
-// String returns a pointer to of the string value passed in.
-func String(v string) *string {
- return &v
-}
-
-// StringValue returns the value of the string pointer passed in or
-// "" if the pointer is nil.
-func StringValue(v *string) string {
- if v != nil {
- return *v
- }
- return ""
-}
-
-// StringSlice converts a slice of string values into a slice of
-// string pointers
-func StringSlice(src []string) []*string {
- dst := make([]*string, len(src))
- for i := 0; i < len(src); i++ {
- dst[i] = &(src[i])
- }
- return dst
-}
-
-// StringValueSlice converts a slice of string pointers into a slice of
-// string values
-func StringValueSlice(src []*string) []string {
- dst := make([]string, len(src))
- for i := 0; i < len(src); i++ {
- if src[i] != nil {
- dst[i] = *(src[i])
- }
- }
- return dst
-}
-
-// StringMap converts a string map of string values into a string
-// map of string pointers
-func StringMap(src map[string]string) map[string]*string {
- dst := make(map[string]*string)
- for k, val := range src {
- v := val
- dst[k] = &v
- }
- return dst
-}
-
-// StringValueMap converts a string map of string pointers into a string
-// map of string values
-func StringValueMap(src map[string]*string) map[string]string {
- dst := make(map[string]string)
- for k, val := range src {
- if val != nil {
- dst[k] = *val
- }
- }
- return dst
-}
-
-// Bool returns a pointer to of the bool value passed in.
-func Bool(v bool) *bool {
- return &v
-}
-
-// BoolValue returns the value of the bool pointer passed in or
-// false if the pointer is nil.
-func BoolValue(v *bool) bool {
- if v != nil {
- return *v
- }
- return false
-}
-
-// BoolSlice converts a slice of bool values into a slice of
-// bool pointers
-func BoolSlice(src []bool) []*bool {
- dst := make([]*bool, len(src))
- for i := 0; i < len(src); i++ {
- dst[i] = &(src[i])
- }
- return dst
-}
-
-// BoolValueSlice converts a slice of bool pointers into a slice of
-// bool values
-func BoolValueSlice(src []*bool) []bool {
- dst := make([]bool, len(src))
- for i := 0; i < len(src); i++ {
- if src[i] != nil {
- dst[i] = *(src[i])
- }
- }
- return dst
-}
-
-// BoolMap converts a string map of bool values into a string
-// map of bool pointers
-func BoolMap(src map[string]bool) map[string]*bool {
- dst := make(map[string]*bool)
- for k, val := range src {
- v := val
- dst[k] = &v
- }
- return dst
-}
-
-// BoolValueMap converts a string map of bool pointers into a string
-// map of bool values
-func BoolValueMap(src map[string]*bool) map[string]bool {
- dst := make(map[string]bool)
- for k, val := range src {
- if val != nil {
- dst[k] = *val
- }
- }
- return dst
-}
-
-// Int returns a pointer to of the int value passed in.
-func Int(v int) *int {
- return &v
-}
-
-// IntValue returns the value of the int pointer passed in or
-// 0 if the pointer is nil.
-func IntValue(v *int) int {
- if v != nil {
- return *v
- }
- return 0
-}
-
-// IntSlice converts a slice of int values into a slice of
-// int pointers
-func IntSlice(src []int) []*int {
- dst := make([]*int, len(src))
- for i := 0; i < len(src); i++ {
- dst[i] = &(src[i])
- }
- return dst
-}
-
-// IntValueSlice converts a slice of int pointers into a slice of
-// int values
-func IntValueSlice(src []*int) []int {
- dst := make([]int, len(src))
- for i := 0; i < len(src); i++ {
- if src[i] != nil {
- dst[i] = *(src[i])
- }
- }
- return dst
-}
-
-// IntMap converts a string map of int values into a string
-// map of int pointers
-func IntMap(src map[string]int) map[string]*int {
- dst := make(map[string]*int)
- for k, val := range src {
- v := val
- dst[k] = &v
- }
- return dst
-}
-
-// IntValueMap converts a string map of int pointers into a string
-// map of int values
-func IntValueMap(src map[string]*int) map[string]int {
- dst := make(map[string]int)
- for k, val := range src {
- if val != nil {
- dst[k] = *val
- }
- }
- return dst
-}
-
-// Int32 returns a pointer to of the int32 value passed in.
-func Int32(v int32) *int32 {
- return &v
-}
-
-// Int32Value returns the value of the int32 pointer passed in or
-// 0 if the pointer is nil.
-func Int32Value(v *int32) int32 {
- if v != nil {
- return *v
- }
- return 0
-}
-
-// Int32Slice converts a slice of int32 values into a slice of
-// int32 pointers
-func Int32Slice(src []int32) []*int32 {
- dst := make([]*int32, len(src))
- for i := 0; i < len(src); i++ {
- dst[i] = &(src[i])
- }
- return dst
-}
-
-// Int32ValueSlice converts a slice of int32 pointers into a slice of
-// int32 values
-func Int32ValueSlice(src []*int32) []int32 {
- dst := make([]int32, len(src))
- for i := 0; i < len(src); i++ {
- if src[i] != nil {
- dst[i] = *(src[i])
- }
- }
- return dst
-}
-
-// Int32Map converts a string map of int32 values into a string
-// map of int32 pointers
-func Int32Map(src map[string]int32) map[string]*int32 {
- dst := make(map[string]*int32)
- for k, val := range src {
- v := val
- dst[k] = &v
- }
- return dst
-}
-
-// Int32ValueMap converts a string map of int32 pointers into a string
-// map of int32 values
-func Int32ValueMap(src map[string]*int32) map[string]int32 {
- dst := make(map[string]int32)
- for k, val := range src {
- if val != nil {
- dst[k] = *val
- }
- }
- return dst
-}
-
-// Int64 returns a pointer to of the int64 value passed in.
-func Int64(v int64) *int64 {
- return &v
-}
-
-// Int64Value returns the value of the int64 pointer passed in or
-// 0 if the pointer is nil.
-func Int64Value(v *int64) int64 {
- if v != nil {
- return *v
- }
- return 0
-}
-
-// Int64Slice converts a slice of int64 values into a slice of
-// int64 pointers
-func Int64Slice(src []int64) []*int64 {
- dst := make([]*int64, len(src))
- for i := 0; i < len(src); i++ {
- dst[i] = &(src[i])
- }
- return dst
-}
-
-// Int64ValueSlice converts a slice of int64 pointers into a slice of
-// int64 values
-func Int64ValueSlice(src []*int64) []int64 {
- dst := make([]int64, len(src))
- for i := 0; i < len(src); i++ {
- if src[i] != nil {
- dst[i] = *(src[i])
- }
- }
- return dst
-}
-
-// Int64Map converts a string map of int64 values into a string
-// map of int64 pointers
-func Int64Map(src map[string]int64) map[string]*int64 {
- dst := make(map[string]*int64)
- for k, val := range src {
- v := val
- dst[k] = &v
- }
- return dst
-}
-
-// Int64ValueMap converts a string map of int64 pointers into a string
-// map of int64 values
-func Int64ValueMap(src map[string]*int64) map[string]int64 {
- dst := make(map[string]int64)
- for k, val := range src {
- if val != nil {
- dst[k] = *val
- }
- }
- return dst
-}
-
-// Uint16 returns a pointer to of the uint16 value passed in.
-func Uint16(v uint16) *uint16 {
- return &v
-}
-
-// Uint16Value returns the value of the uint16 pointer passed in or
-// 0 if the pointer is nil.
-func Uint16Value(v *uint16) uint16 {
- if v != nil {
- return *v
- }
-
- return 0
-}
-
-// Uint16Slice converts a slice of uint16 values into a slice of
-// uint16 pointers
-func Uint16Slice(src []uint16) []*uint16 {
- dst := make([]*uint16, len(src))
- for i := 0; i < len(src); i++ {
- dst[i] = &(src[i])
- }
-
- return dst
-}
-
-// Uint16ValueSlice converts a slice of uint16 pointers into a slice of
-// uint16 values
-func Uint16ValueSlice(src []*uint16) []uint16 {
- dst := make([]uint16, len(src))
-
- for i := 0; i < len(src); i++ {
- if src[i] != nil {
- dst[i] = *(src[i])
- }
- }
-
- return dst
-}
-
-// Uint16Map converts a string map of uint16 values into a string
-// map of uint16 pointers
-func Uint16Map(src map[string]uint16) map[string]*uint16 {
- dst := make(map[string]*uint16)
-
- for k, val := range src {
- v := val
- dst[k] = &v
- }
-
- return dst
-}
-
-// Uint16ValueMap converts a string map of uint16 pointers into a string
-// map of uint16 values
-func Uint16ValueMap(src map[string]*uint16) map[string]uint16 {
- dst := make(map[string]uint16)
-
- for k, val := range src {
- if val != nil {
- dst[k] = *val
- }
- }
-
- return dst
-}
-
-// Uint returns a pointer to of the uint value passed in.
-func Uint(v uint) *uint {
- return &v
-}
-
-// UintValue returns the value of the uint pointer passed in or
-// 0 if the pointer is nil.
-func UintValue(v *uint) uint {
- if v != nil {
- return *v
- }
- return 0
-}
-
-// UintSlice converts a slice of uint values into a slice of
-// uint pointers
-func UintSlice(src []uint) []*uint {
- dst := make([]*uint, len(src))
- for i := 0; i < len(src); i++ {
- dst[i] = &(src[i])
- }
- return dst
-}
-
-// UintValueSlice converts a slice of uint pointers into a slice of
-// uint values
-func UintValueSlice(src []*uint) []uint {
- dst := make([]uint, len(src))
- for i := 0; i < len(src); i++ {
- if src[i] != nil {
- dst[i] = *(src[i])
- }
- }
- return dst
-}
-
-// UintMap converts a string map of uint values into a string
-// map of uint pointers
-func UintMap(src map[string]uint) map[string]*uint {
- dst := make(map[string]*uint)
- for k, val := range src {
- v := val
- dst[k] = &v
- }
- return dst
-}
-
-// UintValueMap converts a string map of uint pointers into a string
-// map of uint values
-func UintValueMap(src map[string]*uint) map[string]uint {
- dst := make(map[string]uint)
- for k, val := range src {
- if val != nil {
- dst[k] = *val
- }
- }
- return dst
-}
-
-// Uint32 returns a pointer to of the uint32 value passed in.
-func Uint32(v uint32) *uint32 {
- return &v
-}
-
-// Uint32Value returns the value of the uint32 pointer passed in or
-// 0 if the pointer is nil.
-func Uint32Value(v *uint32) uint32 {
- if v != nil {
- return *v
- }
- return 0
-}
-
-// Uint32Slice converts a slice of uint32 values into a slice of
-// uint32 pointers
-func Uint32Slice(src []uint32) []*uint32 {
- dst := make([]*uint32, len(src))
- for i := 0; i < len(src); i++ {
- dst[i] = &(src[i])
- }
- return dst
-}
-
-// Uint32ValueSlice converts a slice of uint32 pointers into a slice of
-// uint32 values
-func Uint32ValueSlice(src []*uint32) []uint32 {
- dst := make([]uint32, len(src))
- for i := 0; i < len(src); i++ {
- if src[i] != nil {
- dst[i] = *(src[i])
- }
- }
- return dst
-}
-
-// Uint32Map converts a string map of uint32 values into a string
-// map of uint32 pointers
-func Uint32Map(src map[string]uint32) map[string]*uint32 {
- dst := make(map[string]*uint32)
- for k, val := range src {
- v := val
- dst[k] = &v
- }
- return dst
-}
-
-// Uint32ValueMap converts a string map of uint32 pointers into a string
-// map of uint32 values
-func Uint32ValueMap(src map[string]*uint32) map[string]uint32 {
- dst := make(map[string]uint32)
- for k, val := range src {
- if val != nil {
- dst[k] = *val
- }
- }
- return dst
-}
-
-// Uint64 returns a pointer to of the uint64 value passed in.
-func Uint64(v uint64) *uint64 {
- return &v
-}
-
-// Uint64Value returns the value of the uint64 pointer passed in or
-// 0 if the pointer is nil.
-func Uint64Value(v *uint64) uint64 {
- if v != nil {
- return *v
- }
- return 0
-}
-
-// Uint64Slice converts a slice of uint64 values into a slice of
-// uint64 pointers
-func Uint64Slice(src []uint64) []*uint64 {
- dst := make([]*uint64, len(src))
- for i := 0; i < len(src); i++ {
- dst[i] = &(src[i])
- }
- return dst
-}
-
-// Uint64ValueSlice converts a slice of uint64 pointers into a slice of
-// uint64 values
-func Uint64ValueSlice(src []*uint64) []uint64 {
- dst := make([]uint64, len(src))
- for i := 0; i < len(src); i++ {
- if src[i] != nil {
- dst[i] = *(src[i])
- }
- }
- return dst
-}
-
-// Uint64Map converts a string map of uint64 values into a string
-// map of uint64 pointers
-func Uint64Map(src map[string]uint64) map[string]*uint64 {
- dst := make(map[string]*uint64)
- for k, val := range src {
- v := val
- dst[k] = &v
- }
- return dst
-}
-
-// Uint64ValueMap converts a string map of uint64 pointers into a string
-// map of uint64 values
-func Uint64ValueMap(src map[string]*uint64) map[string]uint64 {
- dst := make(map[string]uint64)
- for k, val := range src {
- if val != nil {
- dst[k] = *val
- }
- }
- return dst
-}
-
-// Float32 returns a pointer to of the float32 value passed in.
-func Float32(v float32) *float32 {
- return &v
-}
-
-// Float32Value returns the value of the float32 pointer passed in or
-// 0 if the pointer is nil.
-func Float32Value(v *float32) float32 {
- if v != nil {
- return *v
- }
-
- return 0
-}
-
-// Float32Slice converts a slice of float32 values into a slice of
-// float32 pointers
-func Float32Slice(src []float32) []*float32 {
- dst := make([]*float32, len(src))
-
- for i := 0; i < len(src); i++ {
- dst[i] = &(src[i])
- }
-
- return dst
-}
-
-// Float32ValueSlice converts a slice of float32 pointers into a slice of
-// float32 values
-func Float32ValueSlice(src []*float32) []float32 {
- dst := make([]float32, len(src))
-
- for i := 0; i < len(src); i++ {
- if src[i] != nil {
- dst[i] = *(src[i])
- }
- }
-
- return dst
-}
-
-// Float32Map converts a string map of float32 values into a string
-// map of float32 pointers
-func Float32Map(src map[string]float32) map[string]*float32 {
- dst := make(map[string]*float32)
-
- for k, val := range src {
- v := val
- dst[k] = &v
- }
-
- return dst
-}
-
-// Float32ValueMap converts a string map of float32 pointers into a string
-// map of float32 values
-func Float32ValueMap(src map[string]*float32) map[string]float32 {
- dst := make(map[string]float32)
-
- for k, val := range src {
- if val != nil {
- dst[k] = *val
- }
- }
-
- return dst
-}
-
-// Float64 returns a pointer to of the float64 value passed in.
-func Float64(v float64) *float64 {
- return &v
-}
-
-// Float64Value returns the value of the float64 pointer passed in or
-// 0 if the pointer is nil.
-func Float64Value(v *float64) float64 {
- if v != nil {
- return *v
- }
- return 0
-}
-
-// Float64Slice converts a slice of float64 values into a slice of
-// float64 pointers
-func Float64Slice(src []float64) []*float64 {
- dst := make([]*float64, len(src))
- for i := 0; i < len(src); i++ {
- dst[i] = &(src[i])
- }
- return dst
-}
-
-// Float64ValueSlice converts a slice of float64 pointers into a slice of
-// float64 values
-func Float64ValueSlice(src []*float64) []float64 {
- dst := make([]float64, len(src))
- for i := 0; i < len(src); i++ {
- if src[i] != nil {
- dst[i] = *(src[i])
- }
- }
- return dst
-}
-
-// Float64Map converts a string map of float64 values into a string
-// map of float64 pointers
-func Float64Map(src map[string]float64) map[string]*float64 {
- dst := make(map[string]*float64)
- for k, val := range src {
- v := val
- dst[k] = &v
- }
- return dst
-}
-
-// Float64ValueMap converts a string map of float64 pointers into a string
-// map of float64 values
-func Float64ValueMap(src map[string]*float64) map[string]float64 {
- dst := make(map[string]float64)
- for k, val := range src {
- if val != nil {
- dst[k] = *val
- }
- }
- return dst
-}
-
-// Time returns a pointer to of the time.Time value passed in.
-func Time(v time.Time) *time.Time {
- return &v
-}
-
-// TimeValue returns the value of the time.Time pointer passed in or
-// time.Time{} if the pointer is nil.
-func TimeValue(v *time.Time) time.Time {
- if v != nil {
- return *v
- }
- return time.Time{}
-}
-
-// TimeSlice converts a slice of time.Time values into a slice of
-// time.Time pointers
-func TimeSlice(src []time.Time) []*time.Time {
- dst := make([]*time.Time, len(src))
- for i := 0; i < len(src); i++ {
- dst[i] = &(src[i])
- }
- return dst
-}
-
-// TimeValueSlice converts a slice of time.Time pointers into a slice of
-// time.Time values
-func TimeValueSlice(src []*time.Time) []time.Time {
- dst := make([]time.Time, len(src))
- for i := 0; i < len(src); i++ {
- if src[i] != nil {
- dst[i] = *(src[i])
- }
- }
- return dst
-}
-
-// TimeMap converts a string map of time.Time values into a string
-// map of time.Time pointers
-func TimeMap(src map[string]time.Time) map[string]*time.Time {
- dst := make(map[string]*time.Time)
- for k, val := range src {
- v := val
- dst[k] = &v
- }
- return dst
-}
-
-// TimeValueMap converts a string map of time.Time pointers into a string
-// map of time.Time values
-func TimeValueMap(src map[string]*time.Time) map[string]time.Time {
- dst := make(map[string]time.Time)
- for k, val := range src {
- if val != nil {
- dst[k] = *val
- }
- }
- return dst
-}
diff --git a/vendor/github.com/go-openapi/swag/doc.go b/vendor/github.com/go-openapi/swag/doc.go
index 55094cb74c..b54b57478a 100644
--- a/vendor/github.com/go-openapi/swag/doc.go
+++ b/vendor/github.com/go-openapi/swag/doc.go
@@ -1,31 +1,47 @@
-// Copyright 2015 go-swagger maintainers
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+// Package swag contains a bunch of helper functions for go-openapi and go-swagger projects.
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+// You may also use it standalone for your projects.
//
-// http://www.apache.org/licenses/LICENSE-2.0
+// NOTE: all features that used to be exposed as package-level members (constants, variables,
+// functions and types) are now deprecated and are superseded by equivalent features in
+// more specialized sub-packages.
+// Moving forward, no additional feature will be added to the [swag] API directly at the root package level,
+// which remains there for backward-compatibility purposes.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-/*
-Package swag contains a bunch of helper functions for go-openapi and go-swagger projects.
-
-You may also use it standalone for your projects.
-
- - convert between value and pointers for builtin types
- - convert from string to builtin types (wraps strconv)
- - fast json concatenation
- - search in path
- - load from file or http
- - name mangling
-
-This repo has only few dependencies outside of the standard library:
-
- - YAML utilities depend on gopkg.in/yaml.v2
-*/
+// Child modules will continue to evolve or some new ones may be added in the future.
+//
+// # Modules
+//
+// - [cmdutils] utilities to work with CLIs
+//
+// - [conv] type conversion utilities
+//
+// - [fileutils] file utilities
+//
+// - [jsonname] JSON utilities
+//
+// - [jsonutils] JSON utilities
+//
+// - [loading] file loading
+//
+// - [mangling] safe name generation
+//
+// - [netutils] networking utilities
+//
+// - [stringutils] `string` utilities
+//
+// - [typeutils] `go` types utilities
+//
+// - [yamlutils] YAML utilities
+//
+// # Dependencies
+//
+// This repo has a few dependencies outside of the standard library:
+//
+// - YAML utilities depend on [go.yaml.in/yaml/v3]
package swag
+
+//go:generate mockery
diff --git a/vendor/github.com/go-openapi/swag/file.go b/vendor/github.com/go-openapi/swag/file.go
deleted file mode 100644
index 16accc55f8..0000000000
--- a/vendor/github.com/go-openapi/swag/file.go
+++ /dev/null
@@ -1,33 +0,0 @@
-// Copyright 2015 go-swagger maintainers
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-package swag
-
-import "mime/multipart"
-
-// File represents an uploaded file.
-type File struct {
- Data multipart.File
- Header *multipart.FileHeader
-}
-
-// Read bytes from the file
-func (f *File) Read(p []byte) (n int, err error) {
- return f.Data.Read(p)
-}
-
-// Close the file
-func (f *File) Close() error {
- return f.Data.Close()
-}
diff --git a/vendor/github.com/go-openapi/swag/fileutils/LICENSE b/vendor/github.com/go-openapi/swag/fileutils/LICENSE
new file mode 100644
index 0000000000..d645695673
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/fileutils/LICENSE
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/vendor/github.com/go-openapi/swag/fileutils/doc.go b/vendor/github.com/go-openapi/swag/fileutils/doc.go
new file mode 100644
index 0000000000..859a200d84
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/fileutils/doc.go
@@ -0,0 +1,10 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+// Package fileutils exposes utilities to deal with files and paths.
+//
+// Currently, there is:
+// - [File] to represent an abstraction of an uploaded file.
+// For instance, this is used by [github.com/go-openapi/runtime.File].
+// - path search utilities (e.g. finding packages in the GO search path)
+package fileutils
diff --git a/vendor/github.com/go-openapi/swag/fileutils/file.go b/vendor/github.com/go-openapi/swag/fileutils/file.go
new file mode 100644
index 0000000000..5ad4cfaeaf
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/fileutils/file.go
@@ -0,0 +1,22 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package fileutils
+
+import "mime/multipart"
+
+// File represents an uploaded file.
+type File struct {
+ Data multipart.File
+ Header *multipart.FileHeader
+}
+
+// Read bytes from the file
+func (f *File) Read(p []byte) (n int, err error) {
+ return f.Data.Read(p)
+}
+
+// Close the file
+func (f *File) Close() error {
+ return f.Data.Close()
+}
diff --git a/vendor/github.com/go-openapi/swag/fileutils/path.go b/vendor/github.com/go-openapi/swag/fileutils/path.go
new file mode 100644
index 0000000000..dd09f690bf
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/fileutils/path.go
@@ -0,0 +1,52 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package fileutils
+
+import (
+ "os"
+ "path/filepath"
+ "runtime"
+ "strings"
+)
+
+// GOPATHKey represents the env key for gopath
+const GOPATHKey = "GOPATH"
+
+// FindInSearchPath finds a package in a provided lists of paths
+func FindInSearchPath(searchPath, pkg string) string {
+ pathsList := filepath.SplitList(searchPath)
+ for _, path := range pathsList {
+ if evaluatedPath, err := filepath.EvalSymlinks(filepath.Join(path, "src", pkg)); err == nil {
+ if _, err := os.Stat(evaluatedPath); err == nil {
+ return evaluatedPath
+ }
+ }
+ }
+ return ""
+}
+
+// FindInGoSearchPath finds a package in the $GOPATH:$GOROOT
+//
+// Deprecated: this function is no longer relevant with modern go.
+// It uses [runtime.GOROOT] under the hood, which is deprecated as of go1.24.
+func FindInGoSearchPath(pkg string) string {
+ return FindInSearchPath(FullGoSearchPath(), pkg)
+}
+
+// FullGoSearchPath gets the search paths for finding packages
+//
+// Deprecated: this function is no longer relevant with modern go.
+// It uses [runtime.GOROOT] under the hood, which is deprecated as of go1.24.
+func FullGoSearchPath() string {
+ allPaths := os.Getenv(GOPATHKey)
+ if allPaths == "" {
+ allPaths = filepath.Join(os.Getenv("HOME"), "go")
+ }
+ if allPaths != "" {
+ allPaths = strings.Join([]string{allPaths, runtime.GOROOT()}, ":")
+ } else {
+ allPaths = runtime.GOROOT()
+ }
+ return allPaths
+}
diff --git a/vendor/github.com/go-openapi/swag/fileutils_iface.go b/vendor/github.com/go-openapi/swag/fileutils_iface.go
new file mode 100644
index 0000000000..f3e79a0e4b
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/fileutils_iface.go
@@ -0,0 +1,33 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package swag
+
+import "github.com/go-openapi/swag/fileutils"
+
+// GOPATHKey represents the env key for gopath
+//
+// Deprecated: use [fileutils.GOPATHKey] instead.
+const GOPATHKey = fileutils.GOPATHKey
+
+// File represents an uploaded file.
+//
+// Deprecated: use [fileutils.File] instead.
+type File = fileutils.File
+
+// FindInSearchPath finds a package in a provided lists of paths.
+//
+// Deprecated: use [fileutils.FindInSearchPath] instead.
+func FindInSearchPath(searchPath, pkg string) string {
+ return fileutils.FindInSearchPath(searchPath, pkg)
+}
+
+// FindInGoSearchPath finds a package in the $GOPATH:$GOROOT
+//
+// Deprecated: use [fileutils.FindInGoSearchPath] instead.
+func FindInGoSearchPath(pkg string) string { return fileutils.FindInGoSearchPath(pkg) }
+
+// FullGoSearchPath gets the search paths for finding packages
+//
+// Deprecated: use [fileutils.FullGoSearchPath] instead.
+func FullGoSearchPath() string { return fileutils.FullGoSearchPath() }
diff --git a/vendor/github.com/go-openapi/swag/go.work b/vendor/github.com/go-openapi/swag/go.work
new file mode 100644
index 0000000000..1e537f0749
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/go.work
@@ -0,0 +1,20 @@
+use (
+ .
+ ./cmdutils
+ ./conv
+ ./fileutils
+ ./jsonname
+ ./jsonutils
+ ./jsonutils/adapters/easyjson
+ ./jsonutils/adapters/testintegration
+ ./jsonutils/adapters/testintegration/benchmarks
+ ./jsonutils/fixtures_test
+ ./loading
+ ./mangling
+ ./netutils
+ ./stringutils
+ ./typeutils
+ ./yamlutils
+)
+
+go 1.24.0
diff --git a/vendor/github.com/go-openapi/swag/go.work.sum b/vendor/github.com/go-openapi/swag/go.work.sum
new file mode 100644
index 0000000000..c1308cafa6
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/go.work.sum
@@ -0,0 +1,7 @@
+github.com/go-openapi/testify/v2 v2.0.1/go.mod h1:HCPmvFFnheKK2BuwSA0TbbdxJ3I16pjwMkYkP4Ywn54=
+golang.org/x/mod v0.21.0 h1:vvrHzRwRfVKSiLrG+d4FMl/Qi4ukBCE6kZlTUkDYRT0=
+golang.org/x/mod v0.21.0/go.mod h1:6SkKJ3Xj0I0BrPOZoBy3bdMptDDU9oJrpohJ3eWZ1fY=
+golang.org/x/sys v0.26.0 h1:KHjCJyddX0LoSTb3J+vWpupP9p0oznkqVk/IfjymZbo=
+golang.org/x/sys v0.26.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=
+golang.org/x/tools v0.26.0 h1:v/60pFQmzmT9ExmjDv2gGIfi3OqfKoEP6I5+umXlbnQ=
+golang.org/x/tools v0.26.0/go.mod h1:TPVVj70c7JJ3WCazhD8OdXcZg/og+b9+tH/KxylGwH0=
diff --git a/vendor/github.com/go-openapi/swag/initialism_index.go b/vendor/github.com/go-openapi/swag/initialism_index.go
deleted file mode 100644
index 20a359bb60..0000000000
--- a/vendor/github.com/go-openapi/swag/initialism_index.go
+++ /dev/null
@@ -1,202 +0,0 @@
-// Copyright 2015 go-swagger maintainers
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-package swag
-
-import (
- "sort"
- "strings"
- "sync"
-)
-
-var (
- // commonInitialisms are common acronyms that are kept as whole uppercased words.
- commonInitialisms *indexOfInitialisms
-
- // initialisms is a slice of sorted initialisms
- initialisms []string
-
- // a copy of initialisms pre-baked as []rune
- initialismsRunes [][]rune
- initialismsUpperCased [][]rune
-
- isInitialism func(string) bool
-
- maxAllocMatches int
-)
-
-func init() {
- // Taken from https://github.com/golang/lint/blob/3390df4df2787994aea98de825b964ac7944b817/lint.go#L732-L769
- configuredInitialisms := map[string]bool{
- "ACL": true,
- "API": true,
- "ASCII": true,
- "CPU": true,
- "CSS": true,
- "DNS": true,
- "EOF": true,
- "GUID": true,
- "HTML": true,
- "HTTPS": true,
- "HTTP": true,
- "ID": true,
- "IP": true,
- "IPv4": true,
- "IPv6": true,
- "JSON": true,
- "LHS": true,
- "OAI": true,
- "QPS": true,
- "RAM": true,
- "RHS": true,
- "RPC": true,
- "SLA": true,
- "SMTP": true,
- "SQL": true,
- "SSH": true,
- "TCP": true,
- "TLS": true,
- "TTL": true,
- "UDP": true,
- "UI": true,
- "UID": true,
- "UUID": true,
- "URI": true,
- "URL": true,
- "UTF8": true,
- "VM": true,
- "XML": true,
- "XMPP": true,
- "XSRF": true,
- "XSS": true,
- }
-
- // a thread-safe index of initialisms
- commonInitialisms = newIndexOfInitialisms().load(configuredInitialisms)
- initialisms = commonInitialisms.sorted()
- initialismsRunes = asRunes(initialisms)
- initialismsUpperCased = asUpperCased(initialisms)
- maxAllocMatches = maxAllocHeuristic(initialismsRunes)
-
- // a test function
- isInitialism = commonInitialisms.isInitialism
-}
-
-func asRunes(in []string) [][]rune {
- out := make([][]rune, len(in))
- for i, initialism := range in {
- out[i] = []rune(initialism)
- }
-
- return out
-}
-
-func asUpperCased(in []string) [][]rune {
- out := make([][]rune, len(in))
-
- for i, initialism := range in {
- out[i] = []rune(upper(trim(initialism)))
- }
-
- return out
-}
-
-func maxAllocHeuristic(in [][]rune) int {
- heuristic := make(map[rune]int)
- for _, initialism := range in {
- heuristic[initialism[0]]++
- }
-
- var maxAlloc int
- for _, val := range heuristic {
- if val > maxAlloc {
- maxAlloc = val
- }
- }
-
- return maxAlloc
-}
-
-// AddInitialisms add additional initialisms
-func AddInitialisms(words ...string) {
- for _, word := range words {
- // commonInitialisms[upper(word)] = true
- commonInitialisms.add(upper(word))
- }
- // sort again
- initialisms = commonInitialisms.sorted()
- initialismsRunes = asRunes(initialisms)
- initialismsUpperCased = asUpperCased(initialisms)
-}
-
-// indexOfInitialisms is a thread-safe implementation of the sorted index of initialisms.
-// Since go1.9, this may be implemented with sync.Map.
-type indexOfInitialisms struct {
- sortMutex *sync.Mutex
- index *sync.Map
-}
-
-func newIndexOfInitialisms() *indexOfInitialisms {
- return &indexOfInitialisms{
- sortMutex: new(sync.Mutex),
- index: new(sync.Map),
- }
-}
-
-func (m *indexOfInitialisms) load(initial map[string]bool) *indexOfInitialisms {
- m.sortMutex.Lock()
- defer m.sortMutex.Unlock()
- for k, v := range initial {
- m.index.Store(k, v)
- }
- return m
-}
-
-func (m *indexOfInitialisms) isInitialism(key string) bool {
- _, ok := m.index.Load(key)
- return ok
-}
-
-func (m *indexOfInitialisms) add(key string) *indexOfInitialisms {
- m.index.Store(key, true)
- return m
-}
-
-func (m *indexOfInitialisms) sorted() (result []string) {
- m.sortMutex.Lock()
- defer m.sortMutex.Unlock()
- m.index.Range(func(key, _ interface{}) bool {
- k := key.(string)
- result = append(result, k)
- return true
- })
- sort.Sort(sort.Reverse(byInitialism(result)))
- return
-}
-
-type byInitialism []string
-
-func (s byInitialism) Len() int {
- return len(s)
-}
-func (s byInitialism) Swap(i, j int) {
- s[i], s[j] = s[j], s[i]
-}
-func (s byInitialism) Less(i, j int) bool {
- if len(s[i]) != len(s[j]) {
- return len(s[i]) < len(s[j])
- }
-
- return strings.Compare(s[i], s[j]) > 0
-}
diff --git a/vendor/github.com/go-openapi/swag/json.go b/vendor/github.com/go-openapi/swag/json.go
deleted file mode 100644
index 7e9902ca31..0000000000
--- a/vendor/github.com/go-openapi/swag/json.go
+++ /dev/null
@@ -1,312 +0,0 @@
-// Copyright 2015 go-swagger maintainers
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-package swag
-
-import (
- "bytes"
- "encoding/json"
- "log"
- "reflect"
- "strings"
- "sync"
-
- "github.com/mailru/easyjson/jlexer"
- "github.com/mailru/easyjson/jwriter"
-)
-
-// nullJSON represents a JSON object with null type
-var nullJSON = []byte("null")
-
-// DefaultJSONNameProvider the default cache for types
-var DefaultJSONNameProvider = NewNameProvider()
-
-const comma = byte(',')
-
-var closers map[byte]byte
-
-func init() {
- closers = map[byte]byte{
- '{': '}',
- '[': ']',
- }
-}
-
-type ejMarshaler interface {
- MarshalEasyJSON(w *jwriter.Writer)
-}
-
-type ejUnmarshaler interface {
- UnmarshalEasyJSON(w *jlexer.Lexer)
-}
-
-// WriteJSON writes json data, prefers finding an appropriate interface to short-circuit the marshaler
-// so it takes the fastest option available.
-func WriteJSON(data interface{}) ([]byte, error) {
- if d, ok := data.(ejMarshaler); ok {
- jw := new(jwriter.Writer)
- d.MarshalEasyJSON(jw)
- return jw.BuildBytes()
- }
- if d, ok := data.(json.Marshaler); ok {
- return d.MarshalJSON()
- }
- return json.Marshal(data)
-}
-
-// ReadJSON reads json data, prefers finding an appropriate interface to short-circuit the unmarshaler
-// so it takes the fastest option available
-func ReadJSON(data []byte, value interface{}) error {
- trimmedData := bytes.Trim(data, "\x00")
- if d, ok := value.(ejUnmarshaler); ok {
- jl := &jlexer.Lexer{Data: trimmedData}
- d.UnmarshalEasyJSON(jl)
- return jl.Error()
- }
- if d, ok := value.(json.Unmarshaler); ok {
- return d.UnmarshalJSON(trimmedData)
- }
- return json.Unmarshal(trimmedData, value)
-}
-
-// DynamicJSONToStruct converts an untyped json structure into a struct
-func DynamicJSONToStruct(data interface{}, target interface{}) error {
- // TODO: convert straight to a json typed map (mergo + iterate?)
- b, err := WriteJSON(data)
- if err != nil {
- return err
- }
- return ReadJSON(b, target)
-}
-
-// ConcatJSON concatenates multiple json objects efficiently
-func ConcatJSON(blobs ...[]byte) []byte {
- if len(blobs) == 0 {
- return nil
- }
-
- last := len(blobs) - 1
- for blobs[last] == nil || bytes.Equal(blobs[last], nullJSON) {
- // strips trailing null objects
- last--
- if last < 0 {
- // there was nothing but "null"s or nil...
- return nil
- }
- }
- if last == 0 {
- return blobs[0]
- }
-
- var opening, closing byte
- var idx, a int
- buf := bytes.NewBuffer(nil)
-
- for i, b := range blobs[:last+1] {
- if b == nil || bytes.Equal(b, nullJSON) {
- // a null object is in the list: skip it
- continue
- }
- if len(b) > 0 && opening == 0 { // is this an array or an object?
- opening, closing = b[0], closers[b[0]]
- }
-
- if opening != '{' && opening != '[' {
- continue // don't know how to concatenate non container objects
- }
-
- if len(b) < 3 { // yep empty but also the last one, so closing this thing
- if i == last && a > 0 {
- if err := buf.WriteByte(closing); err != nil {
- log.Println(err)
- }
- }
- continue
- }
-
- idx = 0
- if a > 0 { // we need to join with a comma for everything beyond the first non-empty item
- if err := buf.WriteByte(comma); err != nil {
- log.Println(err)
- }
- idx = 1 // this is not the first or the last so we want to drop the leading bracket
- }
-
- if i != last { // not the last one, strip brackets
- if _, err := buf.Write(b[idx : len(b)-1]); err != nil {
- log.Println(err)
- }
- } else { // last one, strip only the leading bracket
- if _, err := buf.Write(b[idx:]); err != nil {
- log.Println(err)
- }
- }
- a++
- }
- // somehow it ended up being empty, so provide a default value
- if buf.Len() == 0 {
- if err := buf.WriteByte(opening); err != nil {
- log.Println(err)
- }
- if err := buf.WriteByte(closing); err != nil {
- log.Println(err)
- }
- }
- return buf.Bytes()
-}
-
-// ToDynamicJSON turns an object into a properly JSON typed structure
-func ToDynamicJSON(data interface{}) interface{} {
- // TODO: convert straight to a json typed map (mergo + iterate?)
- b, err := json.Marshal(data)
- if err != nil {
- log.Println(err)
- }
- var res interface{}
- if err := json.Unmarshal(b, &res); err != nil {
- log.Println(err)
- }
- return res
-}
-
-// FromDynamicJSON turns an object into a properly JSON typed structure
-func FromDynamicJSON(data, target interface{}) error {
- b, err := json.Marshal(data)
- if err != nil {
- log.Println(err)
- }
- return json.Unmarshal(b, target)
-}
-
-// NameProvider represents an object capable of translating from go property names
-// to json property names
-// This type is thread-safe.
-type NameProvider struct {
- lock *sync.Mutex
- index map[reflect.Type]nameIndex
-}
-
-type nameIndex struct {
- jsonNames map[string]string
- goNames map[string]string
-}
-
-// NewNameProvider creates a new name provider
-func NewNameProvider() *NameProvider {
- return &NameProvider{
- lock: &sync.Mutex{},
- index: make(map[reflect.Type]nameIndex),
- }
-}
-
-func buildnameIndex(tpe reflect.Type, idx, reverseIdx map[string]string) {
- for i := 0; i < tpe.NumField(); i++ {
- targetDes := tpe.Field(i)
-
- if targetDes.PkgPath != "" { // unexported
- continue
- }
-
- if targetDes.Anonymous { // walk embedded structures tree down first
- buildnameIndex(targetDes.Type, idx, reverseIdx)
- continue
- }
-
- if tag := targetDes.Tag.Get("json"); tag != "" {
-
- parts := strings.Split(tag, ",")
- if len(parts) == 0 {
- continue
- }
-
- nm := parts[0]
- if nm == "-" {
- continue
- }
- if nm == "" { // empty string means we want to use the Go name
- nm = targetDes.Name
- }
-
- idx[nm] = targetDes.Name
- reverseIdx[targetDes.Name] = nm
- }
- }
-}
-
-func newNameIndex(tpe reflect.Type) nameIndex {
- var idx = make(map[string]string, tpe.NumField())
- var reverseIdx = make(map[string]string, tpe.NumField())
-
- buildnameIndex(tpe, idx, reverseIdx)
- return nameIndex{jsonNames: idx, goNames: reverseIdx}
-}
-
-// GetJSONNames gets all the json property names for a type
-func (n *NameProvider) GetJSONNames(subject interface{}) []string {
- n.lock.Lock()
- defer n.lock.Unlock()
- tpe := reflect.Indirect(reflect.ValueOf(subject)).Type()
- names, ok := n.index[tpe]
- if !ok {
- names = n.makeNameIndex(tpe)
- }
-
- res := make([]string, 0, len(names.jsonNames))
- for k := range names.jsonNames {
- res = append(res, k)
- }
- return res
-}
-
-// GetJSONName gets the json name for a go property name
-func (n *NameProvider) GetJSONName(subject interface{}, name string) (string, bool) {
- tpe := reflect.Indirect(reflect.ValueOf(subject)).Type()
- return n.GetJSONNameForType(tpe, name)
-}
-
-// GetJSONNameForType gets the json name for a go property name on a given type
-func (n *NameProvider) GetJSONNameForType(tpe reflect.Type, name string) (string, bool) {
- n.lock.Lock()
- defer n.lock.Unlock()
- names, ok := n.index[tpe]
- if !ok {
- names = n.makeNameIndex(tpe)
- }
- nme, ok := names.goNames[name]
- return nme, ok
-}
-
-func (n *NameProvider) makeNameIndex(tpe reflect.Type) nameIndex {
- names := newNameIndex(tpe)
- n.index[tpe] = names
- return names
-}
-
-// GetGoName gets the go name for a json property name
-func (n *NameProvider) GetGoName(subject interface{}, name string) (string, bool) {
- tpe := reflect.Indirect(reflect.ValueOf(subject)).Type()
- return n.GetGoNameForType(tpe, name)
-}
-
-// GetGoNameForType gets the go name for a given type for a json property name
-func (n *NameProvider) GetGoNameForType(tpe reflect.Type, name string) (string, bool) {
- n.lock.Lock()
- defer n.lock.Unlock()
- names, ok := n.index[tpe]
- if !ok {
- names = n.makeNameIndex(tpe)
- }
- nme, ok := names.jsonNames[name]
- return nme, ok
-}
diff --git a/vendor/github.com/go-openapi/swag/jsonname/LICENSE b/vendor/github.com/go-openapi/swag/jsonname/LICENSE
new file mode 100644
index 0000000000..d645695673
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/jsonname/LICENSE
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/vendor/github.com/go-openapi/swag/jsonname/doc.go b/vendor/github.com/go-openapi/swag/jsonname/doc.go
new file mode 100644
index 0000000000..79232eaca4
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/jsonname/doc.go
@@ -0,0 +1,5 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+// Package jsonname is a provider of json property names from go properties.
+package jsonname
diff --git a/vendor/github.com/go-openapi/swag/jsonname/name_provider.go b/vendor/github.com/go-openapi/swag/jsonname/name_provider.go
new file mode 100644
index 0000000000..8eaf1bece8
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/jsonname/name_provider.go
@@ -0,0 +1,138 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package jsonname
+
+import (
+ "reflect"
+ "strings"
+ "sync"
+)
+
+// DefaultJSONNameProvider is the default cache for types.
+var DefaultJSONNameProvider = NewNameProvider()
+
+// NameProvider represents an object capable of translating from go property names
+// to json property names.
+//
+// This type is thread-safe.
+//
+// See [github.com/go-openapi/jsonpointer.Pointer] for an example.
+type NameProvider struct {
+ lock *sync.Mutex
+ index map[reflect.Type]nameIndex
+}
+
+type nameIndex struct {
+ jsonNames map[string]string
+ goNames map[string]string
+}
+
+// NewNameProvider creates a new name provider
+func NewNameProvider() *NameProvider {
+ return &NameProvider{
+ lock: &sync.Mutex{},
+ index: make(map[reflect.Type]nameIndex),
+ }
+}
+
+func buildnameIndex(tpe reflect.Type, idx, reverseIdx map[string]string) {
+ for i := 0; i < tpe.NumField(); i++ {
+ targetDes := tpe.Field(i)
+
+ if targetDes.PkgPath != "" { // unexported
+ continue
+ }
+
+ if targetDes.Anonymous { // walk embedded structures tree down first
+ buildnameIndex(targetDes.Type, idx, reverseIdx)
+ continue
+ }
+
+ if tag := targetDes.Tag.Get("json"); tag != "" {
+
+ parts := strings.Split(tag, ",")
+ if len(parts) == 0 {
+ continue
+ }
+
+ nm := parts[0]
+ if nm == "-" {
+ continue
+ }
+ if nm == "" { // empty string means we want to use the Go name
+ nm = targetDes.Name
+ }
+
+ idx[nm] = targetDes.Name
+ reverseIdx[targetDes.Name] = nm
+ }
+ }
+}
+
+func newNameIndex(tpe reflect.Type) nameIndex {
+ var idx = make(map[string]string, tpe.NumField())
+ var reverseIdx = make(map[string]string, tpe.NumField())
+
+ buildnameIndex(tpe, idx, reverseIdx)
+ return nameIndex{jsonNames: idx, goNames: reverseIdx}
+}
+
+// GetJSONNames gets all the json property names for a type
+func (n *NameProvider) GetJSONNames(subject any) []string {
+ n.lock.Lock()
+ defer n.lock.Unlock()
+ tpe := reflect.Indirect(reflect.ValueOf(subject)).Type()
+ names, ok := n.index[tpe]
+ if !ok {
+ names = n.makeNameIndex(tpe)
+ }
+
+ res := make([]string, 0, len(names.jsonNames))
+ for k := range names.jsonNames {
+ res = append(res, k)
+ }
+ return res
+}
+
+// GetJSONName gets the json name for a go property name
+func (n *NameProvider) GetJSONName(subject any, name string) (string, bool) {
+ tpe := reflect.Indirect(reflect.ValueOf(subject)).Type()
+ return n.GetJSONNameForType(tpe, name)
+}
+
+// GetJSONNameForType gets the json name for a go property name on a given type
+func (n *NameProvider) GetJSONNameForType(tpe reflect.Type, name string) (string, bool) {
+ n.lock.Lock()
+ defer n.lock.Unlock()
+ names, ok := n.index[tpe]
+ if !ok {
+ names = n.makeNameIndex(tpe)
+ }
+ nme, ok := names.goNames[name]
+ return nme, ok
+}
+
+// GetGoName gets the go name for a json property name
+func (n *NameProvider) GetGoName(subject any, name string) (string, bool) {
+ tpe := reflect.Indirect(reflect.ValueOf(subject)).Type()
+ return n.GetGoNameForType(tpe, name)
+}
+
+// GetGoNameForType gets the go name for a given type for a json property name
+func (n *NameProvider) GetGoNameForType(tpe reflect.Type, name string) (string, bool) {
+ n.lock.Lock()
+ defer n.lock.Unlock()
+ names, ok := n.index[tpe]
+ if !ok {
+ names = n.makeNameIndex(tpe)
+ }
+ nme, ok := names.jsonNames[name]
+ return nme, ok
+}
+
+func (n *NameProvider) makeNameIndex(tpe reflect.Type) nameIndex {
+ names := newNameIndex(tpe)
+ n.index[tpe] = names
+ return names
+}
diff --git a/vendor/github.com/go-openapi/swag/jsonname_iface.go b/vendor/github.com/go-openapi/swag/jsonname_iface.go
new file mode 100644
index 0000000000..303a007f6f
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/jsonname_iface.go
@@ -0,0 +1,24 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package swag
+
+import (
+ "github.com/go-openapi/swag/jsonname"
+)
+
+// DefaultJSONNameProvider is the default cache for types
+//
+// Deprecated: use [jsonname.DefaultJSONNameProvider] instead.
+var DefaultJSONNameProvider = jsonname.DefaultJSONNameProvider
+
+// NameProvider represents an object capable of translating from go property names
+// to json property names.
+//
+// Deprecated: use [jsonname.NameProvider] instead.
+type NameProvider = jsonname.NameProvider
+
+// NewNameProvider creates a new name provider
+//
+// Deprecated: use [jsonname.NewNameProvider] instead.
+func NewNameProvider() *NameProvider { return jsonname.NewNameProvider() }
diff --git a/vendor/github.com/go-openapi/swag/jsonutils/LICENSE b/vendor/github.com/go-openapi/swag/jsonutils/LICENSE
new file mode 100644
index 0000000000..d645695673
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/jsonutils/LICENSE
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/vendor/github.com/go-openapi/swag/jsonutils/README.md b/vendor/github.com/go-openapi/swag/jsonutils/README.md
new file mode 100644
index 0000000000..d745cdb466
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/jsonutils/README.md
@@ -0,0 +1,108 @@
+ # jsonutils
+
+`jsonutils` exposes a few tools to work with JSON:
+
+- a fast, simple `Concat` to concatenate (not merge) JSON objects and arrays
+- `FromDynamicJSON` to convert a data structure into a "dynamic JSON" data structure
+- `ReadJSON` and `WriteJSON` behave like `json.Unmarshal` and `json.Marshal`,
+ with the ability to use another underlying serialization library through an `Adapter`
+ configured at runtime
+- a `JSONMapSlice` structure that may be used to store JSON objects with the order of keys maintained
+
+## Dynamic JSON
+
+We call "dynamic JSON" the go data structure that results from unmarshaling JSON like this:
+
+```go
+ var value any
+ jsonBytes := `{"a": 1, ... }`
+ _ = json.Unmarshal(jsonBytes, &value)
+```
+
+In this configuration, the standard library mappings are as follows:
+
+| JSON | go |
+|-----------|------------------|
+| `number` | `float64` |
+| `string` | `string` |
+| `boolean` | `bool` |
+| `null` | `nil` |
+| `object` | `map[string]any` |
+| `array` | `[]any` |
+
+## Map slices
+
+When using `JSONMapSlice`, the ordering of keys is ensured by replacing
+mappings to `map[string]any` by a `JSONMapSlice` which is an (ordered)
+slice of `JSONMapItem`s.
+
+Notice that a similar feature is available for YAML (see [`yamlutils`](../yamlutils)),
+with a `YAMLMapSlice` type based on the `JSONMapSlice`.
+
+`JSONMapSlice` is similar to an ordered map, but the keys are not retrieved
+in constant time.
+
+Another difference with the the above standard mappings is that numbers don't always map
+to a `float64`: if the value is a JSON integer, it unmarshals to `int64`.
+
+See also [some examples](https://pkg.go.dev/github.com/go-openapi/swag/jsonutils#pkg-examples)
+
+## Adapters
+
+`ReadJSON`, `WriteJSON` and `FromDynamicJSON` (which is a combination of the latter two)
+are wrappers on top of `json.Unmarshal` and `json.Marshal`.
+
+By default, the adapter merely wraps the standard library.
+
+The adapter may be used to register other JSON serialization libraries,
+possibly several ones at the same time.
+
+If the value passed is identified as an "ordered map" (i.e. implements `ifaces.Ordered`
+or `ifaces.SetOrdered`, the adapter favors the "ordered" JSON behavior and tries to
+find a registered implementation that support ordered keys in objects.
+
+Our standard library implementation supports this.
+
+As of `v0.25.0`, we support through such an adapter the popular `mailru/easyjson`
+library, which kicks in when the passed values support the `easyjson.Unmarshaler`
+or `easyjson.Marshaler` interfaces.
+
+In the future, we plan to add more similar libraries that compete on the go JSON
+serializers scene.
+
+## Registering an adapter
+
+In package `github.com/go-openapi/swag/easyjson/adapters`, several adapters are available.
+
+Each adapter is an independent go module. Hence you'll pick its dependencies only if you import it.
+
+At this moment we provide:
+* `stdlib`: JSON adapter based on the standard library
+* `easyjson`: JSON adapter based on the `github.com/mailru/easyjson`
+
+The adapters provide the basic `Marshal` and `Unmarshal` capabilities, plus an implementation
+of the `MapSlice` pattern.
+
+You may also build your own adapter based on your specific use-case. An adapter is not required to implement
+all capabilities.
+
+Every adapter comes with a `Register` function, possibly with some options, to register the adapter
+to a global registry.
+
+For example, to enable `easyjson` to be used in `ReadJSON` and `WriteJSON`, you would write something like:
+
+```go
+ import (
+ "github.com/go-openapi/swag/jsonutils/adapters"
+ easyjson "github.com/go-openapi/swag/jsonutils/adapters/easyjson/json"
+ )
+
+ func init() {
+ easyjson.Register(adapters.Registry)
+ }
+```
+
+You may register several adapters. In this case, capability matching is evaluated from the last registered
+adapters (LIFO).
+
+## [Benchmarks](./adapters/testintegration/benchmarks/README.md)
diff --git a/vendor/github.com/go-openapi/swag/jsonutils/adapters/doc.go b/vendor/github.com/go-openapi/swag/jsonutils/adapters/doc.go
new file mode 100644
index 0000000000..76d3898fca
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/jsonutils/adapters/doc.go
@@ -0,0 +1,8 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+// Package adapters exposes a registry of adapters to multiple
+// JSON serialization libraries.
+//
+// All interfaces are defined in package [ifaces.Adapter].
+package adapters
diff --git a/vendor/github.com/go-openapi/swag/jsonutils/adapters/ifaces/doc.go b/vendor/github.com/go-openapi/swag/jsonutils/adapters/ifaces/doc.go
new file mode 100644
index 0000000000..1fd43a1fad
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/jsonutils/adapters/ifaces/doc.go
@@ -0,0 +1,5 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+// Package ifaces exposes all interfaces to work with adapters.
+package ifaces
diff --git a/vendor/github.com/go-openapi/swag/jsonutils/adapters/ifaces/ifaces.go b/vendor/github.com/go-openapi/swag/jsonutils/adapters/ifaces/ifaces.go
new file mode 100644
index 0000000000..7805e5e5e3
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/jsonutils/adapters/ifaces/ifaces.go
@@ -0,0 +1,84 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package ifaces
+
+import (
+ _ "encoding/json" // for documentation purpose
+ "iter"
+)
+
+// Ordered knows how to iterate over the (key,value) pairs of a JSON object.
+type Ordered interface {
+ OrderedItems() iter.Seq2[string, any]
+}
+
+// SetOrdered knows how to append or update the keys of a JSON object,
+// given an iterator over (key,value) pairs.
+//
+// If the provided iterator is nil then the receiver should be set to nil.
+type SetOrdered interface {
+ SetOrderedItems(iter.Seq2[string, any])
+}
+
+// OrderedMap represent a JSON object (i.e. like a map[string,any]),
+// and knows how to serialize and deserialize JSON with the order of keys maintained.
+type OrderedMap interface {
+ Ordered
+ SetOrdered
+
+ OrderedMarshalJSON() ([]byte, error)
+ OrderedUnmarshalJSON([]byte) error
+}
+
+// MarshalAdapter behaves likes the standard library [json.Marshal].
+type MarshalAdapter interface {
+ Poolable
+
+ Marshal(any) ([]byte, error)
+}
+
+// OrderedMarshalAdapter behaves likes the standard library [json.Marshal], preserving the order of keys in objects.
+type OrderedMarshalAdapter interface {
+ Poolable
+
+ OrderedMarshal(Ordered) ([]byte, error)
+}
+
+// UnmarshalAdapter behaves likes the standard library [json.Unmarshal].
+type UnmarshalAdapter interface {
+ Poolable
+
+ Unmarshal([]byte, any) error
+}
+
+// OrderedUnmarshalAdapter behaves likes the standard library [json.Unmarshal], preserving the order of keys in objects.
+type OrderedUnmarshalAdapter interface {
+ Poolable
+
+ OrderedUnmarshal([]byte, SetOrdered) error
+}
+
+// Adapter exposes an interface like the standard [json] library.
+type Adapter interface {
+ MarshalAdapter
+ UnmarshalAdapter
+
+ OrderedAdapter
+}
+
+// OrderedAdapter exposes interfaces to process JSON and keep the order of object keys.
+type OrderedAdapter interface {
+ OrderedMarshalAdapter
+ OrderedUnmarshalAdapter
+ NewOrderedMap(capacity int) OrderedMap
+}
+
+type Poolable interface {
+ // Self-redeem: for [Adapter] s that are allocated from a pool.
+ // The [Adapter] must not be used after calling [Redeem].
+ Redeem()
+
+ // Reset the state of the [Adapter], if any.
+ Reset()
+}
diff --git a/vendor/github.com/go-openapi/swag/jsonutils/adapters/ifaces/registry_iface.go b/vendor/github.com/go-openapi/swag/jsonutils/adapters/ifaces/registry_iface.go
new file mode 100644
index 0000000000..2d6c69f4e6
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/jsonutils/adapters/ifaces/registry_iface.go
@@ -0,0 +1,91 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package ifaces
+
+import (
+ "strings"
+)
+
+// Capability indicates what a JSON adapter is capable of.
+type Capability uint8
+
+const (
+ CapabilityMarshalJSON Capability = 1 << iota
+ CapabilityUnmarshalJSON
+ CapabilityOrderedMarshalJSON
+ CapabilityOrderedUnmarshalJSON
+ CapabilityOrderedMap
+)
+
+func (c Capability) String() string {
+ switch c {
+ case CapabilityMarshalJSON:
+ return "MarshalJSON"
+ case CapabilityUnmarshalJSON:
+ return "UnmarshalJSON"
+ case CapabilityOrderedMarshalJSON:
+ return "OrderedMarshalJSON"
+ case CapabilityOrderedUnmarshalJSON:
+ return "OrderedUnmarshalJSON"
+ case CapabilityOrderedMap:
+ return "OrderedMap"
+ default:
+ return ""
+ }
+}
+
+// Capabilities holds several unitary capability flags
+type Capabilities uint8
+
+// Has some capability flag enabled.
+func (c Capabilities) Has(capability Capability) bool {
+ return Capability(c)&capability > 0
+}
+
+func (c Capabilities) String() string {
+ var w strings.Builder
+
+ first := true
+ for _, capability := range []Capability{
+ CapabilityMarshalJSON,
+ CapabilityUnmarshalJSON,
+ CapabilityOrderedMarshalJSON,
+ CapabilityOrderedUnmarshalJSON,
+ CapabilityOrderedMap,
+ } {
+ if c.Has(capability) {
+ if !first {
+ w.WriteByte('|')
+ } else {
+ first = false
+ }
+ w.WriteString(capability.String())
+ }
+ }
+
+ return w.String()
+}
+
+const (
+ AllCapabilities Capabilities = Capabilities(uint8(CapabilityMarshalJSON) |
+ uint8(CapabilityUnmarshalJSON) |
+ uint8(CapabilityOrderedMarshalJSON) |
+ uint8(CapabilityOrderedUnmarshalJSON) |
+ uint8(CapabilityOrderedMap))
+
+ AllUnorderedCapabilities Capabilities = Capabilities(uint8(CapabilityMarshalJSON) | uint8(CapabilityUnmarshalJSON))
+)
+
+// RegistryEntry describes how any given adapter registers its capabilities to the [Registrar].
+type RegistryEntry struct {
+ Who string
+ What Capabilities
+ Constructor func() Adapter
+ Support func(what Capability, value any) bool
+}
+
+// Registrar is a type that knows how to keep registration calls from adapters.
+type Registrar interface {
+ RegisterFor(RegistryEntry)
+}
diff --git a/vendor/github.com/go-openapi/swag/jsonutils/adapters/registry.go b/vendor/github.com/go-openapi/swag/jsonutils/adapters/registry.go
new file mode 100644
index 0000000000..3062acaff2
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/jsonutils/adapters/registry.go
@@ -0,0 +1,229 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package adapters
+
+import (
+ "fmt"
+ "reflect"
+ "slices"
+ "sync"
+
+ "github.com/go-openapi/swag/jsonutils/adapters/ifaces"
+ stdlib "github.com/go-openapi/swag/jsonutils/adapters/stdlib/json"
+)
+
+// Registry holds the global registry for registered adapters.
+var Registry = NewRegistrar()
+
+var (
+ defaultRegistered = stdlib.Register
+
+ _ ifaces.Registrar = &Registrar{}
+)
+
+type registryError string
+
+func (e registryError) Error() string {
+ return string(e)
+}
+
+// ErrRegistry indicates an error returned by the [Registrar].
+var ErrRegistry registryError = "JSON adapters registry error"
+
+type registry []*ifaces.RegistryEntry
+
+// Registrar holds registered [ifaces.Adapters] for different serialization capabilities.
+//
+// Internally, it maintains a cache for data types that favor a given adapter.
+type Registrar struct {
+ marshalerRegistry registry
+ unmarshalerRegistry registry
+ orderedMarshalerRegistry registry
+ orderedUnmarshalerRegistry registry
+ orderedMapRegistry registry
+
+ gmx sync.RWMutex
+
+ // cache indexed by value type, so we don't have to lookup
+ marshalerCache map[reflect.Type]*ifaces.RegistryEntry
+ unmarshalerCache map[reflect.Type]*ifaces.RegistryEntry
+ orderedMarshalerCache map[reflect.Type]*ifaces.RegistryEntry
+ orderedUnmarshalerCache map[reflect.Type]*ifaces.RegistryEntry
+ orderedMapCache map[reflect.Type]*ifaces.RegistryEntry
+}
+
+func NewRegistrar() *Registrar {
+ r := &Registrar{}
+
+ r.marshalerRegistry = make(registry, 0, 1)
+ r.unmarshalerRegistry = make(registry, 0, 1)
+ r.orderedMarshalerRegistry = make(registry, 0, 1)
+ r.orderedUnmarshalerRegistry = make(registry, 0, 1)
+ r.orderedMapRegistry = make(registry, 0, 1)
+
+ r.marshalerCache = make(map[reflect.Type]*ifaces.RegistryEntry)
+ r.unmarshalerCache = make(map[reflect.Type]*ifaces.RegistryEntry)
+ r.orderedMarshalerCache = make(map[reflect.Type]*ifaces.RegistryEntry)
+ r.orderedUnmarshalerCache = make(map[reflect.Type]*ifaces.RegistryEntry)
+ r.orderedMapCache = make(map[reflect.Type]*ifaces.RegistryEntry)
+
+ defaultRegistered(r)
+
+ return r
+}
+
+// ClearCache resets the internal type cache.
+func (r *Registrar) ClearCache() {
+ r.gmx.Lock()
+ r.clearCache()
+ r.gmx.Unlock()
+}
+
+// Reset the [Registrar] to its defaults.
+func (r *Registrar) Reset() {
+ r.gmx.Lock()
+ r.clearCache()
+ r.marshalerRegistry = r.marshalerRegistry[:0]
+ r.unmarshalerRegistry = r.unmarshalerRegistry[:0]
+ r.orderedMarshalerRegistry = r.orderedMarshalerRegistry[:0]
+ r.orderedUnmarshalerRegistry = r.orderedUnmarshalerRegistry[:0]
+ r.orderedMapRegistry = r.orderedMapRegistry[:0]
+ r.gmx.Unlock()
+
+ defaultRegistered(r)
+}
+
+// RegisterFor registers an adapter for some JSON capabilities.
+func (r *Registrar) RegisterFor(entry ifaces.RegistryEntry) {
+ r.gmx.Lock()
+ if entry.What.Has(ifaces.CapabilityMarshalJSON) {
+ e := entry
+ e.What &= ifaces.Capabilities(ifaces.CapabilityMarshalJSON)
+ r.marshalerRegistry = slices.Insert(r.marshalerRegistry, 0, &e)
+ }
+ if entry.What.Has(ifaces.CapabilityUnmarshalJSON) {
+ e := entry
+ e.What &= ifaces.Capabilities(ifaces.CapabilityUnmarshalJSON)
+ r.unmarshalerRegistry = slices.Insert(r.unmarshalerRegistry, 0, &e)
+ }
+ if entry.What.Has(ifaces.CapabilityOrderedMarshalJSON) {
+ e := entry
+ e.What &= ifaces.Capabilities(ifaces.CapabilityOrderedMarshalJSON)
+ r.orderedMarshalerRegistry = slices.Insert(r.orderedMarshalerRegistry, 0, &e)
+ }
+ if entry.What.Has(ifaces.CapabilityOrderedUnmarshalJSON) {
+ e := entry
+ e.What &= ifaces.Capabilities(ifaces.CapabilityOrderedUnmarshalJSON)
+ r.orderedUnmarshalerRegistry = slices.Insert(r.orderedUnmarshalerRegistry, 0, &e)
+ }
+ if entry.What.Has(ifaces.CapabilityOrderedMap) {
+ e := entry
+ e.What &= ifaces.Capabilities(ifaces.CapabilityOrderedMap)
+ r.orderedMapRegistry = slices.Insert(r.orderedMapRegistry, 0, &e)
+ }
+ r.gmx.Unlock()
+}
+
+// AdapterFor returns an [ifaces.Adapter] that supports this capability for this type of value.
+//
+// The [ifaces.Adapter] may be redeemed to its pool using its Redeem() method, for adapters that support global
+// pooling. When this is not the case, the redeem function is just a no-operation.
+func (r *Registrar) AdapterFor(capability ifaces.Capability, value any) ifaces.Adapter {
+ entry := r.findFirstFor(capability, value)
+ if entry == nil {
+ return nil
+ }
+
+ return entry.Constructor()
+}
+
+func (r *Registrar) clearCache() {
+ clear(r.marshalerCache)
+ clear(r.unmarshalerCache)
+ clear(r.orderedMarshalerCache)
+ clear(r.orderedUnmarshalerCache)
+ clear(r.orderedMapCache)
+}
+
+func (r *Registrar) findFirstFor(capability ifaces.Capability, value any) *ifaces.RegistryEntry {
+ switch capability {
+ case ifaces.CapabilityMarshalJSON:
+ return r.findFirstInRegistryFor(r.marshalerRegistry, r.marshalerCache, capability, value)
+ case ifaces.CapabilityUnmarshalJSON:
+ return r.findFirstInRegistryFor(r.unmarshalerRegistry, r.unmarshalerCache, capability, value)
+ case ifaces.CapabilityOrderedMarshalJSON:
+ return r.findFirstInRegistryFor(r.orderedMarshalerRegistry, r.orderedMarshalerCache, capability, value)
+ case ifaces.CapabilityOrderedUnmarshalJSON:
+ return r.findFirstInRegistryFor(r.orderedUnmarshalerRegistry, r.orderedUnmarshalerCache, capability, value)
+ case ifaces.CapabilityOrderedMap:
+ return r.findFirstInRegistryFor(r.orderedMapRegistry, r.orderedMapCache, capability, value)
+ default:
+ panic(fmt.Errorf("unsupported capability %d: %w", capability, ErrRegistry))
+ }
+}
+
+func (r *Registrar) findFirstInRegistryFor(reg registry, cache map[reflect.Type]*ifaces.RegistryEntry, capability ifaces.Capability, value any) *ifaces.RegistryEntry {
+ r.gmx.RLock()
+ if len(reg) > 1 {
+ if entry, ok := cache[reflect.TypeOf(value)]; ok {
+ // cache hit
+ r.gmx.RUnlock()
+ return entry
+ }
+ }
+
+ for _, entry := range reg {
+ if !entry.Support(capability, value) {
+ continue
+ }
+
+ r.gmx.RUnlock()
+
+ // update the internal cache
+ r.gmx.Lock()
+ cache[reflect.TypeOf(value)] = entry
+ r.gmx.Unlock()
+
+ return entry
+ }
+
+ // no adapter found
+ r.gmx.RUnlock()
+
+ return nil
+}
+
+// MarshalAdapterFor returns the first adapter that knows how to Marshal this type of value.
+func MarshalAdapterFor(value any) ifaces.MarshalAdapter {
+ return Registry.AdapterFor(ifaces.CapabilityMarshalJSON, value)
+}
+
+// OrderedMarshalAdapterFor returns the first adapter that knows how to OrderedMarshal this type of value.
+func OrderedMarshalAdapterFor(value ifaces.Ordered) ifaces.OrderedMarshalAdapter {
+ return Registry.AdapterFor(ifaces.CapabilityOrderedMarshalJSON, value)
+}
+
+// UnmarshalAdapterFor returns the first adapter that knows how to Unmarshal this type of value.
+func UnmarshalAdapterFor(value any) ifaces.UnmarshalAdapter {
+ return Registry.AdapterFor(ifaces.CapabilityUnmarshalJSON, value)
+}
+
+// OrderedUnmarshalAdapterFor provides the first adapter that knows how to OrderedUnmarshal this type of value.
+func OrderedUnmarshalAdapterFor(value ifaces.SetOrdered) ifaces.OrderedUnmarshalAdapter {
+ return Registry.AdapterFor(ifaces.CapabilityOrderedUnmarshalJSON, value)
+}
+
+// NewOrderedMap provides the "ordered map" implementation provided by the registry.
+func NewOrderedMap(capacity int) ifaces.OrderedMap {
+ var v any
+ adapter := Registry.AdapterFor(ifaces.CapabilityOrderedUnmarshalJSON, v)
+ if adapter == nil {
+ return nil
+ }
+
+ defer adapter.Redeem()
+ return adapter.NewOrderedMap(capacity)
+}
+
+func noopRedeemer() {}
diff --git a/vendor/github.com/go-openapi/swag/jsonutils/adapters/stdlib/json/adapter.go b/vendor/github.com/go-openapi/swag/jsonutils/adapters/stdlib/json/adapter.go
new file mode 100644
index 0000000000..0213ff5c29
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/jsonutils/adapters/stdlib/json/adapter.go
@@ -0,0 +1,115 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package json
+
+import (
+ stdjson "encoding/json"
+
+ "github.com/go-openapi/swag/jsonutils/adapters/ifaces"
+ "github.com/go-openapi/swag/typeutils"
+)
+
+const sensibleBufferSize = 8192
+
+type jsonError string
+
+func (e jsonError) Error() string {
+ return string(e)
+}
+
+// ErrStdlib indicates that an error comes from the stdlib JSON adapter
+var ErrStdlib jsonError = "error from the JSON adapter stdlib"
+
+var _ ifaces.Adapter = &Adapter{}
+
+type Adapter struct {
+}
+
+// NewAdapter yields an [ifaces.Adapter] using the standard library.
+func NewAdapter() *Adapter {
+ return &Adapter{}
+}
+
+func (a *Adapter) Marshal(value any) ([]byte, error) {
+ return stdjson.Marshal(value)
+}
+
+func (a *Adapter) Unmarshal(data []byte, value any) error {
+ return stdjson.Unmarshal(data, value)
+}
+
+func (a *Adapter) OrderedMarshal(value ifaces.Ordered) ([]byte, error) {
+ w := poolOfWriters.Borrow()
+ defer func() {
+ poolOfWriters.Redeem(w)
+ }()
+
+ if typeutils.IsNil(value) {
+ w.RawString("null")
+
+ return w.BuildBytes()
+ }
+
+ w.RawByte('{')
+ first := true
+ for k, v := range value.OrderedItems() {
+ if first {
+ first = false
+ } else {
+ w.RawByte(',')
+ }
+
+ w.String(k)
+ w.RawByte(':')
+
+ switch val := v.(type) {
+ case ifaces.Ordered:
+ w.Raw(a.OrderedMarshal(val))
+ default:
+ w.Raw(stdjson.Marshal(v))
+ }
+ }
+
+ w.RawByte('}')
+
+ return w.BuildBytes()
+}
+
+func (a *Adapter) OrderedUnmarshal(data []byte, value ifaces.SetOrdered) error {
+ var m MapSlice
+ if err := m.OrderedUnmarshalJSON(data); err != nil {
+ return err
+ }
+
+ if typeutils.IsNil(m) {
+ // force input value to nil
+ value.SetOrderedItems(nil)
+
+ return nil
+ }
+
+ value.SetOrderedItems(m.OrderedItems())
+
+ return nil
+}
+
+func (a *Adapter) NewOrderedMap(capacity int) ifaces.OrderedMap {
+ m := make(MapSlice, 0, capacity)
+
+ return &m
+}
+
+// Redeem the [Adapter] when it comes from a pool.
+//
+// The adapter becomes immediately unusable once redeemed.
+func (a *Adapter) Redeem() {
+ if a == nil {
+ return
+ }
+
+ RedeemAdapter(a)
+}
+
+func (a *Adapter) Reset() {
+}
diff --git a/vendor/github.com/go-openapi/swag/jsonutils/adapters/stdlib/json/doc.go b/vendor/github.com/go-openapi/swag/jsonutils/adapters/stdlib/json/doc.go
new file mode 100644
index 0000000000..5ea1b44042
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/jsonutils/adapters/stdlib/json/doc.go
@@ -0,0 +1,5 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+// Package json implements an [ifaces.Adapter] using the standard library.
+package json
diff --git a/vendor/github.com/go-openapi/swag/jsonutils/adapters/stdlib/json/lexer.go b/vendor/github.com/go-openapi/swag/jsonutils/adapters/stdlib/json/lexer.go
new file mode 100644
index 0000000000..b5aa1c7972
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/jsonutils/adapters/stdlib/json/lexer.go
@@ -0,0 +1,320 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package json
+
+import (
+ stdjson "encoding/json"
+ "errors"
+ "fmt"
+ "io"
+ "math"
+ "strconv"
+
+ "github.com/go-openapi/swag/conv"
+)
+
+type token struct {
+ stdjson.Token
+}
+
+func (t token) String() string {
+ if t == invalidToken {
+ return "invalid token"
+ }
+ if t == eofToken {
+ return "EOF"
+ }
+
+ return fmt.Sprintf("%v", t.Token)
+}
+
+func (t token) Kind() tokenKind {
+ switch t.Token.(type) {
+ case nil:
+ return tokenNull
+ case stdjson.Delim:
+ return tokenDelim
+ case bool:
+ return tokenBool
+ case float64:
+ return tokenFloat
+ case stdjson.Number:
+ return tokenNumber
+ case string:
+ return tokenString
+ default:
+ return tokenUndef
+ }
+}
+
+func (t token) Delim() byte {
+ r, ok := t.Token.(stdjson.Delim)
+ if !ok {
+ return 0
+ }
+
+ return byte(r)
+}
+
+type tokenKind uint8
+
+const (
+ tokenUndef tokenKind = iota
+ tokenString
+ tokenNumber
+ tokenFloat
+ tokenBool
+ tokenNull
+ tokenDelim
+)
+
+var (
+ invalidToken = token{
+ Token: stdjson.Token(struct{}{}),
+ }
+
+ eofToken = token{
+ Token: stdjson.Token(&struct{}{}),
+ }
+
+ undefToken = token{
+ Token: stdjson.Token(uint8(0)),
+ }
+)
+
+// jlexer apes easyjson's jlexer, but uses the standard library decoder under the hood.
+type jlexer struct {
+ buf *bytesReader
+ dec *stdjson.Decoder
+ err error
+ // current token
+ next token
+ // started bool
+}
+
+type bytesReader struct {
+ buf []byte
+ offset int
+}
+
+func (b *bytesReader) Reset() {
+ b.buf = nil
+ b.offset = 0
+}
+
+func (b *bytesReader) Read(p []byte) (int, error) {
+ if b.offset >= len(b.buf) {
+ return 0, io.EOF
+ }
+
+ n := len(p)
+ buf := b.buf[b.offset:]
+ m := len(buf)
+
+ if n >= m {
+ copy(p, buf)
+ b.offset += m
+
+ return m, nil
+ }
+
+ copy(p, buf[:n])
+ b.offset += n
+
+ return n, nil
+}
+
+var _ io.Reader = &bytesReader{}
+
+func newLexer(data []byte) *jlexer {
+ l := &jlexer{
+ // current: undefToken,
+ next: undefToken,
+ }
+ l.buf = &bytesReader{
+ buf: data,
+ }
+ l.dec = stdjson.NewDecoder(l.buf) // unfortunately, cannot pool this
+
+ return l
+}
+
+func (l *jlexer) Reset() {
+ l.err = nil
+ l.next = undefToken
+ // leave l.dec and l.buf alone, since they are replaced at every Borrow
+}
+
+func (l *jlexer) Error() error {
+ return l.err
+}
+
+func (l *jlexer) SetErr(err error) {
+ l.err = err
+}
+
+func (l *jlexer) Ok() bool {
+ return l.err == nil
+}
+
+// NextToken consumes a token
+func (l *jlexer) NextToken() token {
+ if !l.Ok() {
+ return invalidToken
+ }
+
+ if l.next != undefToken {
+ next := l.next
+ l.next = undefToken
+
+ return next
+ }
+
+ return l.fetchToken()
+}
+
+// PeekToken returns the next token without consuming it
+func (l *jlexer) PeekToken() token {
+ if l.next == undefToken {
+ l.next = l.fetchToken()
+ }
+
+ return l.next
+}
+
+func (l *jlexer) Skip() {
+ _ = l.NextToken()
+}
+
+func (l *jlexer) IsDelim(c byte) bool {
+ if !l.Ok() {
+ return false
+ }
+
+ next := l.PeekToken()
+ if next.Kind() != tokenDelim {
+ return false
+ }
+
+ if next.Delim() != c {
+ return false
+ }
+
+ return true
+}
+
+func (l *jlexer) IsNull() bool {
+ if !l.Ok() {
+ return false
+ }
+
+ next := l.PeekToken()
+
+ return next.Kind() == tokenNull
+}
+
+func (l *jlexer) Delim(c byte) {
+ if !l.Ok() {
+ return
+ }
+
+ tok := l.NextToken()
+ if tok.Kind() != tokenDelim {
+ l.err = fmt.Errorf("expected a delimiter token but got '%v': %w", tok, ErrStdlib)
+
+ return
+ }
+
+ if tok.Delim() != c {
+ l.err = fmt.Errorf("expected delimiter '%q' but got '%q': %w", c, tok.Delim(), ErrStdlib)
+ }
+}
+
+func (l *jlexer) Null() {
+ if !l.Ok() {
+ return
+ }
+
+ tok := l.NextToken()
+ if tok.Kind() != tokenNull {
+ l.err = fmt.Errorf("expected a null token but got '%v': %w", tok, ErrStdlib)
+ }
+}
+
+func (l *jlexer) Number() any {
+ if !l.Ok() {
+ return 0
+ }
+
+ tok := l.NextToken()
+
+ switch tok.Kind() { //nolint:exhaustive
+ case tokenNumber:
+ n := tok.Token.(stdjson.Number).String()
+ f, _ := strconv.ParseFloat(n, 64)
+ if conv.IsFloat64AJSONInteger(f) {
+ return int64(math.Trunc(f))
+ }
+
+ return f
+
+ case tokenFloat:
+ f := tok.Token.(float64)
+ if conv.IsFloat64AJSONInteger(f) {
+ return int64(math.Trunc(f))
+ }
+
+ return f
+
+ default:
+ l.err = fmt.Errorf("expected a number token but got '%v': %w", tok, ErrStdlib)
+
+ return 0
+ }
+}
+
+func (l *jlexer) Bool() bool {
+ if !l.Ok() {
+ return false
+ }
+
+ tok := l.NextToken()
+ if tok.Kind() != tokenBool {
+ l.err = fmt.Errorf("expected a bool token but got '%v': %w", tok, ErrStdlib)
+
+ return false
+ }
+
+ return tok.Token.(bool)
+}
+
+func (l *jlexer) String() string {
+ if !l.Ok() {
+ return ""
+ }
+
+ tok := l.NextToken()
+ if tok.Kind() != tokenString {
+ l.err = fmt.Errorf("expected a string token but got '%v': %w", tok, ErrStdlib)
+
+ return ""
+ }
+
+ return tok.Token.(string)
+}
+
+// Commas and colons are elided.
+func (l *jlexer) fetchToken() token {
+ jtok, err := l.dec.Token()
+ if err != nil {
+ if errors.Is(err, io.EOF) {
+ return eofToken
+ }
+
+ l.err = errors.Join(err, ErrStdlib)
+ return invalidToken
+ }
+
+ return token{Token: jtok}
+}
diff --git a/vendor/github.com/go-openapi/swag/jsonutils/adapters/stdlib/json/ordered_map.go b/vendor/github.com/go-openapi/swag/jsonutils/adapters/stdlib/json/ordered_map.go
new file mode 100644
index 0000000000..54deef406f
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/jsonutils/adapters/stdlib/json/ordered_map.go
@@ -0,0 +1,266 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package json
+
+import (
+ stdjson "encoding/json"
+ "fmt"
+ "iter"
+
+ "github.com/go-openapi/swag/jsonutils/adapters/ifaces"
+)
+
+var _ ifaces.OrderedMap = &MapSlice{}
+
+// MapSlice represents a JSON object, with the order of keys maintained.
+type MapSlice []MapItem
+
+func (s MapSlice) OrderedItems() iter.Seq2[string, any] {
+ return func(yield func(string, any) bool) {
+ for _, item := range s {
+ if !yield(item.Key, item.Value) {
+ return
+ }
+ }
+ }
+}
+
+func (s *MapSlice) SetOrderedItems(items iter.Seq2[string, any]) {
+ if items == nil {
+ *s = nil
+
+ return
+ }
+
+ m := *s
+ if len(m) > 0 {
+ // update mode
+ idx := make(map[string]int, len(m))
+
+ for i, item := range m {
+ idx[item.Key] = i
+ }
+
+ for k, v := range items {
+ idx, ok := idx[k]
+ if ok {
+ m[idx].Value = v
+
+ continue
+ }
+ m = append(m, MapItem{Key: k, Value: v})
+ }
+
+ *s = m
+
+ return
+ }
+
+ for k, v := range items {
+ m = append(m, MapItem{Key: k, Value: v})
+ }
+
+ *s = m
+}
+
+// MarshalJSON renders a [MapSlice] as JSON bytes, preserving the order of keys.
+func (s MapSlice) MarshalJSON() ([]byte, error) {
+ return s.OrderedMarshalJSON()
+}
+
+func (s MapSlice) OrderedMarshalJSON() ([]byte, error) {
+ w := poolOfWriters.Borrow()
+ defer func() {
+ poolOfWriters.Redeem(w)
+ }()
+
+ s.marshalObject(w)
+
+ return w.BuildBytes() // this clones data, so it's okay to redeem the writer and its buffer
+}
+
+// UnmarshalJSON builds a [MapSlice] from JSON bytes, preserving the order of keys.
+//
+// Inner objects are unmarshaled as [MapSlice] slices and not map[string]any.
+func (s *MapSlice) UnmarshalJSON(data []byte) error {
+ return s.OrderedUnmarshalJSON(data)
+}
+
+func (s *MapSlice) OrderedUnmarshalJSON(data []byte) error {
+ l := poolOfLexers.Borrow(data)
+ defer func() {
+ poolOfLexers.Redeem(l)
+ }()
+
+ s.unmarshalObject(l)
+
+ return l.Error()
+}
+
+func (s MapSlice) marshalObject(w *jwriter) {
+ if s == nil {
+ w.RawString("null")
+
+ return
+ }
+
+ w.RawByte('{')
+
+ if len(s) == 0 {
+ w.RawByte('}')
+
+ return
+ }
+
+ s[0].marshalJSON(w)
+
+ for i := 1; i < len(s); i++ {
+ w.RawByte(',')
+ s[i].marshalJSON(w)
+ }
+
+ w.RawByte('}')
+}
+
+func (s *MapSlice) unmarshalObject(in *jlexer) {
+ if in.IsNull() {
+ in.Skip()
+
+ return
+ }
+
+ in.Delim('{') // consume token
+ if !in.Ok() {
+ return
+ }
+
+ result := make(MapSlice, 0)
+
+ for in.Ok() && !in.IsDelim('}') {
+ var mi MapItem
+
+ mi.unmarshalKeyValue(in)
+ result = append(result, mi)
+ }
+
+ in.Delim('}')
+
+ if !in.Ok() {
+ return
+ }
+
+ *s = result
+}
+
+// MapItem represents the value of a key in a JSON object held by [MapSlice].
+//
+// Notice that [MapItem] should not be marshaled to or unmarshaled from JSON directly,
+// use this type as part of a [MapSlice] when dealing with JSON bytes.
+type MapItem struct {
+ Key string
+ Value any
+}
+
+func (s MapItem) marshalJSON(w *jwriter) {
+ w.String(s.Key)
+ w.RawByte(':')
+ w.Raw(stdjson.Marshal(s.Value))
+}
+
+func (s *MapItem) unmarshalKeyValue(in *jlexer) {
+ key := in.String() // consume string
+ value := s.asInterface(in) // consume any value, including termination tokens '}' or ']'
+
+ if !in.Ok() {
+ return
+ }
+
+ s.Key = key
+ s.Value = value
+}
+
+func (s *MapItem) unmarshalArray(in *jlexer) []any {
+ if in.IsNull() {
+ in.Skip()
+
+ return nil
+ }
+
+ in.Delim('[') // consume token
+ if !in.Ok() {
+ return nil
+ }
+
+ ret := make([]any, 0)
+
+ for in.Ok() && !in.IsDelim(']') {
+ ret = append(ret, s.asInterface(in))
+ }
+
+ in.Delim(']')
+ if !in.Ok() {
+ return nil
+ }
+
+ return ret
+}
+
+// asInterface is very much like [jlexer.Lexer.Interface], but unmarshals an object
+// into a [MapSlice], not a map[string]any.
+//
+// We have to force parsing errors somehow, since [jlexer.Lexer] doesn't let us
+// set a parsing error directly.
+func (s *MapItem) asInterface(in *jlexer) any {
+ if !in.Ok() {
+ return nil
+ }
+
+ tok := in.PeekToken() // look-ahead what the next token looks like
+ kind := tok.Kind()
+
+ switch kind {
+ case tokenString:
+ return in.String() // consume string
+
+ case tokenNumber, tokenFloat:
+ return in.Number()
+
+ case tokenBool:
+ return in.Bool()
+
+ case tokenNull:
+ in.Null()
+
+ return nil
+
+ case tokenDelim:
+ switch tok.Delim() {
+ case '{': // not consumed yet
+ ret := make(MapSlice, 0)
+ ret.unmarshalObject(in) // consumes the terminating '}'
+
+ if in.Ok() {
+ return ret
+ }
+
+ // lexer is in an error state: will exhaust
+ return nil
+
+ case '[': // not consumed yet
+ return s.unmarshalArray(in) // consumes the terminating ']'
+ default:
+ in.SetErr(fmt.Errorf("unexpected delimiter: %v: %w", tok, ErrStdlib)) // force error
+ return nil
+ }
+
+ case tokenUndef:
+ fallthrough
+ default:
+ if in.Ok() {
+ in.SetErr(fmt.Errorf("unexpected token: %v: %w", tok, ErrStdlib)) // force error
+ }
+
+ return nil
+ }
+}
diff --git a/vendor/github.com/go-openapi/swag/jsonutils/adapters/stdlib/json/pool.go b/vendor/github.com/go-openapi/swag/jsonutils/adapters/stdlib/json/pool.go
new file mode 100644
index 0000000000..709b97c304
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/jsonutils/adapters/stdlib/json/pool.go
@@ -0,0 +1,143 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package json
+
+import (
+ "encoding/json"
+ "sync"
+
+ "github.com/go-openapi/swag/jsonutils/adapters/ifaces"
+)
+
+type adaptersPool struct {
+ sync.Pool
+}
+
+func (p *adaptersPool) Borrow() *Adapter {
+ return p.Get().(*Adapter)
+}
+
+func (p *adaptersPool) BorrowIface() ifaces.Adapter {
+ return p.Get().(*Adapter)
+}
+
+func (p *adaptersPool) Redeem(a *Adapter) {
+ p.Put(a)
+}
+
+type writersPool struct {
+ sync.Pool
+}
+
+func (p *writersPool) Borrow() *jwriter {
+ ptr := p.Get()
+
+ jw := ptr.(*jwriter)
+ jw.Reset()
+
+ return jw
+}
+
+func (p *writersPool) Redeem(w *jwriter) {
+ p.Put(w)
+}
+
+type lexersPool struct {
+ sync.Pool
+}
+
+func (p *lexersPool) Borrow(data []byte) *jlexer {
+ ptr := p.Get()
+
+ l := ptr.(*jlexer)
+ l.buf = poolOfReaders.Borrow(data)
+ l.dec = json.NewDecoder(l.buf) // cannot pool, not exposed by the encoding/json API
+ l.Reset()
+
+ return l
+}
+
+func (p *lexersPool) Redeem(l *jlexer) {
+ l.dec = nil
+ discard := l.buf
+ l.buf = nil
+ poolOfReaders.Redeem(discard)
+ p.Put(l)
+}
+
+type readersPool struct {
+ sync.Pool
+}
+
+func (p *readersPool) Borrow(data []byte) *bytesReader {
+ ptr := p.Get()
+
+ b := ptr.(*bytesReader)
+ b.Reset()
+ b.buf = data
+
+ return b
+}
+
+func (p *readersPool) Redeem(b *bytesReader) {
+ p.Put(b)
+}
+
+var (
+ poolOfAdapters = &adaptersPool{
+ Pool: sync.Pool{
+ New: func() any {
+ return NewAdapter()
+ },
+ },
+ }
+
+ poolOfWriters = &writersPool{
+ Pool: sync.Pool{
+ New: func() any {
+ return newJWriter()
+ },
+ },
+ }
+
+ poolOfLexers = &lexersPool{
+ Pool: sync.Pool{
+ New: func() any {
+ return newLexer(nil)
+ },
+ },
+ }
+
+ poolOfReaders = &readersPool{
+ Pool: sync.Pool{
+ New: func() any {
+ return &bytesReader{}
+ },
+ },
+ }
+)
+
+// BorrowAdapter borrows an [Adapter] from the pool, recycling already allocated instances.
+func BorrowAdapter() *Adapter {
+ return poolOfAdapters.Borrow()
+}
+
+// BorrowAdapterIface borrows a stdlib [Adapter] and converts it directly
+// to [ifaces.Adapter]. This is useful to avoid further allocations when
+// translating the concrete type into an interface.
+func BorrowAdapterIface() ifaces.Adapter {
+ return poolOfAdapters.BorrowIface()
+}
+
+// RedeemAdapter redeems an [Adapter] to the pool, so it may be recycled.
+func RedeemAdapter(a *Adapter) {
+ poolOfAdapters.Redeem(a)
+}
+
+func RedeemAdapterIface(a ifaces.Adapter) {
+ concrete, ok := a.(*Adapter)
+ if ok {
+ poolOfAdapters.Redeem(concrete)
+ }
+}
diff --git a/vendor/github.com/go-openapi/swag/jsonutils/adapters/stdlib/json/register.go b/vendor/github.com/go-openapi/swag/jsonutils/adapters/stdlib/json/register.go
new file mode 100644
index 0000000000..fc8818694e
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/jsonutils/adapters/stdlib/json/register.go
@@ -0,0 +1,26 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package json
+
+import (
+ "fmt"
+ "reflect"
+
+ "github.com/go-openapi/swag/jsonutils/adapters/ifaces"
+)
+
+func Register(dispatcher ifaces.Registrar) {
+ t := reflect.TypeOf(Adapter{})
+ dispatcher.RegisterFor(
+ ifaces.RegistryEntry{
+ Who: fmt.Sprintf("%s.%s", t.PkgPath(), t.Name()),
+ What: ifaces.AllCapabilities,
+ Constructor: BorrowAdapterIface,
+ Support: support,
+ })
+}
+
+func support(_ ifaces.Capability, _ any) bool {
+ return true
+}
diff --git a/vendor/github.com/go-openapi/swag/jsonutils/adapters/stdlib/json/writer.go b/vendor/github.com/go-openapi/swag/jsonutils/adapters/stdlib/json/writer.go
new file mode 100644
index 0000000000..dc2325c1a3
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/jsonutils/adapters/stdlib/json/writer.go
@@ -0,0 +1,75 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package json
+
+import (
+ "bytes"
+ "encoding/json"
+ "strings"
+)
+
+type jwriter struct {
+ buf *bytes.Buffer
+ err error
+}
+
+func newJWriter() *jwriter {
+ buf := make([]byte, 0, sensibleBufferSize)
+
+ return &jwriter{buf: bytes.NewBuffer(buf)}
+}
+
+func (w *jwriter) Reset() {
+ w.buf.Reset()
+ w.err = nil
+}
+
+func (w *jwriter) RawString(s string) {
+ if w.err != nil {
+ return
+ }
+ w.buf.WriteString(s)
+}
+
+func (w *jwriter) Raw(b []byte, err error) {
+ if w.err != nil {
+ return
+ }
+ if err != nil {
+ w.err = err
+ return
+ }
+
+ _, _ = w.buf.Write(b)
+}
+
+func (w *jwriter) RawByte(c byte) {
+ if w.err != nil {
+ return
+ }
+ w.buf.WriteByte(c)
+}
+
+var quoteReplacer = strings.NewReplacer(`"`, `\"`, `\`, `\\`)
+
+func (w *jwriter) String(s string) {
+ if w.err != nil {
+ return
+ }
+ // escape quotes and \
+ s = quoteReplacer.Replace(s)
+
+ _ = w.buf.WriteByte('"')
+ json.HTMLEscape(w.buf, []byte(s))
+ _ = w.buf.WriteByte('"')
+}
+
+// BuildBytes returns a clone of the internal buffer.
+func (w *jwriter) BuildBytes() ([]byte, error) {
+ if w.err != nil {
+ return nil, w.err
+ }
+
+ return bytes.Clone(w.buf.Bytes()), nil
+}
diff --git a/vendor/github.com/go-openapi/swag/jsonutils/concat.go b/vendor/github.com/go-openapi/swag/jsonutils/concat.go
new file mode 100644
index 0000000000..2068503af0
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/jsonutils/concat.go
@@ -0,0 +1,92 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package jsonutils
+
+import (
+ "bytes"
+)
+
+// nullJSON represents a JSON object with null type
+var nullJSON = []byte("null")
+
+const comma = byte(',')
+
+var closers map[byte]byte
+
+func init() {
+ closers = map[byte]byte{
+ '{': '}',
+ '[': ']',
+ }
+}
+
+// ConcatJSON concatenates multiple json objects or arrays efficiently.
+//
+// Note that [ConcatJSON] performs a very simple (and fast) concatenation
+// operation: it does not attempt to merge objects.
+func ConcatJSON(blobs ...[]byte) []byte {
+ if len(blobs) == 0 {
+ return nil
+ }
+
+ last := len(blobs) - 1
+ for blobs[last] == nil || bytes.Equal(blobs[last], nullJSON) {
+ // strips trailing null objects
+ last--
+ if last < 0 {
+ // there was nothing but "null"s or nil...
+ return nil
+ }
+ }
+ if last == 0 {
+ return blobs[0]
+ }
+
+ var opening, closing byte
+ var idx, a int
+ buf := bytes.NewBuffer(nil)
+
+ for i, b := range blobs[:last+1] {
+ if b == nil || bytes.Equal(b, nullJSON) {
+ // a null object is in the list: skip it
+ continue
+ }
+ if len(b) > 0 && opening == 0 { // is this an array or an object?
+ opening, closing = b[0], closers[b[0]]
+ }
+
+ if opening != '{' && opening != '[' {
+ continue // don't know how to concatenate non container objects
+ }
+
+ const minLengthIfNotEmpty = 3
+ if len(b) < minLengthIfNotEmpty { // yep empty but also the last one, so closing this thing
+ if i == last && a > 0 {
+ _ = buf.WriteByte(closing) // never returns err != nil
+ }
+ continue
+ }
+
+ idx = 0
+ if a > 0 { // we need to join with a comma for everything beyond the first non-empty item
+ _ = buf.WriteByte(comma) // never returns err != nil
+ idx = 1 // this is not the first or the last so we want to drop the leading bracket
+ }
+
+ if i != last { // not the last one, strip brackets
+ _, _ = buf.Write(b[idx : len(b)-1]) // never returns err != nil
+ } else { // last one, strip only the leading bracket
+ _, _ = buf.Write(b[idx:])
+ }
+ a++
+ }
+
+ // somehow it ended up being empty, so provide a default value
+ if buf.Len() == 0 && (opening == '{' || opening == '[') {
+ _ = buf.WriteByte(opening) // never returns err != nil
+ _ = buf.WriteByte(closing)
+ }
+
+ return buf.Bytes()
+}
diff --git a/vendor/github.com/go-openapi/swag/jsonutils/doc.go b/vendor/github.com/go-openapi/swag/jsonutils/doc.go
new file mode 100644
index 0000000000..3926cc58d1
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/jsonutils/doc.go
@@ -0,0 +1,7 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+// Package jsonutils provides helpers to work with JSON.
+//
+// These utilities work with dynamic go structures to and from JSON.
+package jsonutils
diff --git a/vendor/github.com/go-openapi/swag/jsonutils/json.go b/vendor/github.com/go-openapi/swag/jsonutils/json.go
new file mode 100644
index 0000000000..40753ce03f
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/jsonutils/json.go
@@ -0,0 +1,116 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package jsonutils
+
+import (
+ "bytes"
+ "encoding/json"
+
+ "github.com/go-openapi/swag/jsonutils/adapters"
+ "github.com/go-openapi/swag/jsonutils/adapters/ifaces"
+)
+
+// WriteJSON marshals a data structure as JSON.
+//
+// The difference with [json.Marshal] is that it may check among several alternatives
+// to do so.
+//
+// See [adapters.Registrar] for more details about how to configure
+// multiple serialization alternatives.
+//
+// NOTE: to allow types that are [easyjson.Marshaler] s to use that route to process JSON,
+// you now need to register the adapter for easyjson at runtime.
+func WriteJSON(value any) ([]byte, error) {
+ if orderedMap, isOrdered := value.(ifaces.Ordered); isOrdered {
+ orderedMarshaler := adapters.OrderedMarshalAdapterFor(orderedMap)
+
+ if orderedMarshaler != nil {
+ defer orderedMarshaler.Redeem()
+
+ return orderedMarshaler.OrderedMarshal(orderedMap)
+ }
+
+ // no support found in registered adapters, fallback to the default (unordered) case
+ }
+
+ marshaler := adapters.MarshalAdapterFor(value)
+ if marshaler != nil {
+ defer marshaler.Redeem()
+
+ return marshaler.Marshal(value)
+ }
+
+ // no support found in registered adapters, fallback to the default standard library.
+ //
+ // This only happens when tinkering with the global registry of adapters, since the default handles all the above cases.
+ return json.Marshal(value) // Codecov ignore // this is a safeguard not easily simulated in tests
+}
+
+// ReadJSON unmarshals JSON data into a data structure.
+//
+// The difference with [json.Unmarshal] is that it may check among several alternatives
+// to do so.
+//
+// See [adapters.Registrar] for more details about how to configure
+// multiple serialization alternatives.
+//
+// NOTE: value must be a pointer.
+//
+// If the provided value implements [ifaces.SetOrdered], it is a considered an "ordered map" and [ReadJSON]
+// will favor an adapter that supports the [ifaces.OrderedUnmarshal] feature, or fallback to
+// an unordered behavior if none is found.
+//
+// NOTE: to allow types that are [easyjson.Unmarshaler] s to use that route to process JSON,
+// you now need to register the adapter for easyjson at runtime.
+func ReadJSON(data []byte, value any) error {
+ trimmedData := bytes.Trim(data, "\x00")
+
+ if orderedMap, isOrdered := value.(ifaces.SetOrdered); isOrdered {
+ // if the value is an ordered map, favors support for OrderedUnmarshal.
+
+ orderedUnmarshaler := adapters.OrderedUnmarshalAdapterFor(orderedMap)
+
+ if orderedUnmarshaler != nil {
+ defer orderedUnmarshaler.Redeem()
+
+ return orderedUnmarshaler.OrderedUnmarshal(trimmedData, orderedMap)
+ }
+
+ // no support found in registered adapters, fallback to the default (unordered) case
+ }
+
+ unmarshaler := adapters.UnmarshalAdapterFor(value)
+ if unmarshaler != nil {
+ defer unmarshaler.Redeem()
+
+ return unmarshaler.Unmarshal(trimmedData, value)
+ }
+
+ // no support found in registered adapters, fallback to the default standard library.
+ //
+ // This only happens when tinkering with the global registry of adapters, since the default handles all the above cases.
+ return json.Unmarshal(trimmedData, value) // Codecov ignore // this is a safeguard not easily simulated in tests
+}
+
+// FromDynamicJSON turns a go value into a properly JSON typed structure.
+//
+// "Dynamic JSON" refers to what you get when unmarshaling JSON into an untyped any,
+// i.e. objects are represented by map[string]any, arrays by []any, and
+// all numbers are represented as float64.
+//
+// NOTE: target must be a pointer.
+//
+// # Maintaining the order of keys in objects
+//
+// If source and target implement [ifaces.Ordered] and [ifaces.SetOrdered] respectively,
+// they are considered "ordered maps" and the order of keys is maintained in the
+// "jsonification" process. In that case, map[string]any values are replaced by (ordered) [JSONMapSlice] ones.
+func FromDynamicJSON(source, target any) error {
+ b, err := WriteJSON(source)
+ if err != nil {
+ return err
+ }
+
+ return ReadJSON(b, target)
+}
diff --git a/vendor/github.com/go-openapi/swag/jsonutils/ordered_map.go b/vendor/github.com/go-openapi/swag/jsonutils/ordered_map.go
new file mode 100644
index 0000000000..38dd3e2444
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/jsonutils/ordered_map.go
@@ -0,0 +1,114 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package jsonutils
+
+import (
+ "iter"
+
+ "github.com/go-openapi/swag/jsonutils/adapters"
+ "github.com/go-openapi/swag/typeutils"
+)
+
+// JSONMapSlice represents a JSON object, with the order of keys maintained.
+//
+// It behaves like an ordered map, but keys can't be accessed in constant time.
+type JSONMapSlice []JSONMapItem
+
+// OrderedItems iterates over all (key,value) pairs with the order of keys maintained.
+//
+// This implements the [ifaces.Ordered] interface, so that [ifaces.Adapter] s know how to marshal
+// keys in the desired order.
+func (s JSONMapSlice) OrderedItems() iter.Seq2[string, any] {
+ return func(yield func(string, any) bool) {
+ for _, item := range s {
+ if !yield(item.Key, item.Value) {
+ return
+ }
+ }
+ }
+}
+
+// SetOrderedItems sets keys in the [JSONMapSlice] objects, as presented by
+// the provided iterator.
+//
+// As a special case, if items is nil, this sets to receiver to a nil slice.
+//
+// This implements the [ifaces.SetOrdered] interface, so that [ifaces.Adapter] s know how to unmarshal
+// keys in the desired order.
+func (s *JSONMapSlice) SetOrderedItems(items iter.Seq2[string, any]) {
+ if items == nil {
+ // force receiver to be a nil slice
+ *s = nil
+
+ return
+ }
+
+ m := *s
+ if len(m) > 0 {
+ // update mode: short-circuited when unmarshaling fresh data structures
+ idx := make(map[string]int, len(m))
+
+ for i, item := range m {
+ idx[item.Key] = i
+ }
+
+ for k, v := range items {
+ idx, ok := idx[k]
+ if ok {
+ m[idx].Value = v
+
+ continue
+ }
+
+ m = append(m, JSONMapItem{Key: k, Value: v})
+ }
+
+ *s = m
+
+ return
+ }
+
+ for k, v := range items {
+ m = append(m, JSONMapItem{Key: k, Value: v})
+ }
+
+ *s = m
+}
+
+// MarshalJSON renders a [JSONMapSlice] as JSON bytes, preserving the order of keys.
+//
+// It will pick the JSON library currently configured by the [adapters.Registry] (defaults to the standard library).
+func (s JSONMapSlice) MarshalJSON() ([]byte, error) {
+ orderedMarshaler := adapters.OrderedMarshalAdapterFor(s)
+ defer orderedMarshaler.Redeem()
+
+ return orderedMarshaler.OrderedMarshal(s)
+}
+
+// UnmarshalJSON builds a [JSONMapSlice] from JSON bytes, preserving the order of keys.
+//
+// Inner objects are unmarshaled as ordered [JSONMapSlice] slices and not map[string]any.
+//
+// It will pick the JSON library currently configured by the [adapters.Registry] (defaults to the standard library).
+func (s *JSONMapSlice) UnmarshalJSON(data []byte) error {
+ if typeutils.IsNil(*s) {
+ // allow to unmarshal with a simple var declaration (nil slice)
+ *s = JSONMapSlice{}
+ }
+
+ orderedUnmarshaler := adapters.OrderedUnmarshalAdapterFor(s)
+ defer orderedUnmarshaler.Redeem()
+
+ return orderedUnmarshaler.OrderedUnmarshal(data, s)
+}
+
+// JSONMapItem represents the value of a key in a JSON object held by [JSONMapSlice].
+//
+// Notice that JSONMapItem should not be marshaled to or unmarshaled from JSON directly.
+//
+// Use this type as part of a [JSONMapSlice] when dealing with JSON bytes.
+type JSONMapItem struct {
+ Key string
+ Value any
+}
diff --git a/vendor/github.com/go-openapi/swag/jsonutils_iface.go b/vendor/github.com/go-openapi/swag/jsonutils_iface.go
new file mode 100644
index 0000000000..7bd4105fa5
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/jsonutils_iface.go
@@ -0,0 +1,65 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package swag
+
+import (
+ "log"
+
+ "github.com/go-openapi/swag/jsonutils"
+)
+
+// JSONMapSlice represents a JSON object, with the order of keys maintained
+//
+// Deprecated: use [jsonutils.JSONMapSlice] instead, or [yamlutils.YAMLMapSlice] if you marshal YAML.
+type JSONMapSlice = jsonutils.JSONMapSlice
+
+// JSONMapItem represents a JSON object, with the order of keys maintained
+//
+// Deprecated: use [jsonutils.JSONMapItem] instead.
+type JSONMapItem = jsonutils.JSONMapItem
+
+// WriteJSON writes json data.
+//
+// Deprecated: use [jsonutils.WriteJSON] instead.
+func WriteJSON(data any) ([]byte, error) { return jsonutils.WriteJSON(data) }
+
+// ReadJSON reads json data.
+//
+// Deprecated: use [jsonutils.ReadJSON] instead.
+func ReadJSON(data []byte, value any) error { return jsonutils.ReadJSON(data, value) }
+
+// DynamicJSONToStruct converts an untyped JSON structure into a target data type.
+//
+// Deprecated: use [jsonutils.FromDynamicJSON] instead.
+func DynamicJSONToStruct(data any, target any) error {
+ return jsonutils.FromDynamicJSON(data, target)
+}
+
+// ConcatJSON concatenates multiple JSON objects efficiently.
+//
+// Deprecated: use [jsonutils.ConcatJSON] instead.
+func ConcatJSON(blobs ...[]byte) []byte { return jsonutils.ConcatJSON(blobs...) }
+
+// ToDynamicJSON turns a go value into a properly JSON untyped structure.
+//
+// It is the same as [FromDynamicJSON], but doesn't check for errors.
+//
+// Deprecated: this function is a misnomer and is unsafe. Use [jsonutils.FromDynamicJSON] instead.
+func ToDynamicJSON(value any) any {
+ var res any
+ if err := FromDynamicJSON(value, &res); err != nil {
+ log.Println(err)
+ }
+
+ return res
+}
+
+// FromDynamicJSON turns a go value into a properly JSON typed structure.
+//
+// "Dynamic JSON" refers to what you get when unmarshaling JSON into an untyped any,
+// i.e. objects are represented by map[string]any, arrays by []any, and all
+// scalar values are any.
+//
+// Deprecated: use [jsonutils.FromDynamicJSON] instead.
+func FromDynamicJSON(data, target any) error { return jsonutils.FromDynamicJSON(data, target) }
diff --git a/vendor/github.com/go-openapi/swag/loading.go b/vendor/github.com/go-openapi/swag/loading.go
deleted file mode 100644
index 783442fddf..0000000000
--- a/vendor/github.com/go-openapi/swag/loading.go
+++ /dev/null
@@ -1,176 +0,0 @@
-// Copyright 2015 go-swagger maintainers
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-package swag
-
-import (
- "fmt"
- "io"
- "log"
- "net/http"
- "net/url"
- "os"
- "path"
- "path/filepath"
- "runtime"
- "strings"
- "time"
-)
-
-// LoadHTTPTimeout the default timeout for load requests
-var LoadHTTPTimeout = 30 * time.Second
-
-// LoadHTTPBasicAuthUsername the username to use when load requests require basic auth
-var LoadHTTPBasicAuthUsername = ""
-
-// LoadHTTPBasicAuthPassword the password to use when load requests require basic auth
-var LoadHTTPBasicAuthPassword = ""
-
-// LoadHTTPCustomHeaders an optional collection of custom HTTP headers for load requests
-var LoadHTTPCustomHeaders = map[string]string{}
-
-// LoadFromFileOrHTTP loads the bytes from a file or a remote http server based on the path passed in
-func LoadFromFileOrHTTP(pth string) ([]byte, error) {
- return LoadStrategy(pth, os.ReadFile, loadHTTPBytes(LoadHTTPTimeout))(pth)
-}
-
-// LoadFromFileOrHTTPWithTimeout loads the bytes from a file or a remote http server based on the path passed in
-// timeout arg allows for per request overriding of the request timeout
-func LoadFromFileOrHTTPWithTimeout(pth string, timeout time.Duration) ([]byte, error) {
- return LoadStrategy(pth, os.ReadFile, loadHTTPBytes(timeout))(pth)
-}
-
-// LoadStrategy returns a loader function for a given path or URI.
-//
-// The load strategy returns the remote load for any path starting with `http`.
-// So this works for any URI with a scheme `http` or `https`.
-//
-// The fallback strategy is to call the local loader.
-//
-// The local loader takes a local file system path (absolute or relative) as argument,
-// or alternatively a `file://...` URI, **without host** (see also below for windows).
-//
-// There are a few liberalities, initially intended to be tolerant regarding the URI syntax,
-// especially on windows.
-//
-// Before the local loader is called, the given path is transformed:
-// - percent-encoded characters are unescaped
-// - simple paths (e.g. `./folder/file`) are passed as-is
-// - on windows, occurrences of `/` are replaced by `\`, so providing a relative path such a `folder/file` works too.
-//
-// For paths provided as URIs with the "file" scheme, please note that:
-// - `file://` is simply stripped.
-// This means that the host part of the URI is not parsed at all.
-// For example, `file:///folder/file" becomes "/folder/file`,
-// but `file://localhost/folder/file` becomes `localhost/folder/file` on unix systems.
-// Similarly, `file://./folder/file` yields `./folder/file`.
-// - on windows, `file://...` can take a host so as to specify an UNC share location.
-//
-// Reminder about windows-specifics:
-// - `file://host/folder/file` becomes an UNC path like `\\host\folder\file` (no port specification is supported)
-// - `file:///c:/folder/file` becomes `C:\folder\file`
-// - `file://c:/folder/file` is tolerated (without leading `/`) and becomes `c:\folder\file`
-func LoadStrategy(pth string, local, remote func(string) ([]byte, error)) func(string) ([]byte, error) {
- if strings.HasPrefix(pth, "http") {
- return remote
- }
-
- return func(p string) ([]byte, error) {
- upth, err := url.PathUnescape(p)
- if err != nil {
- return nil, err
- }
-
- if !strings.HasPrefix(p, `file://`) {
- // regular file path provided: just normalize slashes
- return local(filepath.FromSlash(upth))
- }
-
- if runtime.GOOS != "windows" {
- // crude processing: this leaves full URIs with a host with a (mostly) unexpected result
- upth = strings.TrimPrefix(upth, `file://`)
-
- return local(filepath.FromSlash(upth))
- }
-
- // windows-only pre-processing of file://... URIs
-
- // support for canonical file URIs on windows.
- u, err := url.Parse(filepath.ToSlash(upth))
- if err != nil {
- return nil, err
- }
-
- if u.Host != "" {
- // assume UNC name (volume share)
- // NOTE: UNC port not yet supported
-
- // when the "host" segment is a drive letter:
- // file://C:/folder/... => C:\folder
- upth = path.Clean(strings.Join([]string{u.Host, u.Path}, `/`))
- if !strings.HasSuffix(u.Host, ":") && u.Host[0] != '.' {
- // tolerance: if we have a leading dot, this can't be a host
- // file://host/share/folder\... ==> \\host\share\path\folder
- upth = "//" + upth
- }
- } else {
- // no host, let's figure out if this is a drive letter
- upth = strings.TrimPrefix(upth, `file://`)
- first, _, _ := strings.Cut(strings.TrimPrefix(u.Path, "/"), "/")
- if strings.HasSuffix(first, ":") {
- // drive letter in the first segment:
- // file:///c:/folder/... ==> strip the leading slash
- upth = strings.TrimPrefix(upth, `/`)
- }
- }
-
- return local(filepath.FromSlash(upth))
- }
-}
-
-func loadHTTPBytes(timeout time.Duration) func(path string) ([]byte, error) {
- return func(path string) ([]byte, error) {
- client := &http.Client{Timeout: timeout}
- req, err := http.NewRequest(http.MethodGet, path, nil) //nolint:noctx
- if err != nil {
- return nil, err
- }
-
- if LoadHTTPBasicAuthUsername != "" && LoadHTTPBasicAuthPassword != "" {
- req.SetBasicAuth(LoadHTTPBasicAuthUsername, LoadHTTPBasicAuthPassword)
- }
-
- for key, val := range LoadHTTPCustomHeaders {
- req.Header.Set(key, val)
- }
-
- resp, err := client.Do(req)
- defer func() {
- if resp != nil {
- if e := resp.Body.Close(); e != nil {
- log.Println(e)
- }
- }
- }()
- if err != nil {
- return nil, err
- }
-
- if resp.StatusCode != http.StatusOK {
- return nil, fmt.Errorf("could not access document at %q [%s] ", path, resp.Status)
- }
-
- return io.ReadAll(resp.Body)
- }
-}
diff --git a/vendor/github.com/go-openapi/swag/loading/LICENSE b/vendor/github.com/go-openapi/swag/loading/LICENSE
new file mode 100644
index 0000000000..d645695673
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/loading/LICENSE
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/vendor/github.com/go-openapi/swag/loading/doc.go b/vendor/github.com/go-openapi/swag/loading/doc.go
new file mode 100644
index 0000000000..8cf7bcb8b9
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/loading/doc.go
@@ -0,0 +1,5 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+// Package loading provides tools to load a file from http or from a local file system.
+package loading
diff --git a/vendor/github.com/go-openapi/swag/loading/errors.go b/vendor/github.com/go-openapi/swag/loading/errors.go
new file mode 100644
index 0000000000..b3964289c7
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/loading/errors.go
@@ -0,0 +1,15 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package loading
+
+type loadingError string
+
+const (
+ // ErrLoader is an error raised by the file loader utility
+ ErrLoader loadingError = "loader error"
+)
+
+func (e loadingError) Error() string {
+ return string(e)
+}
diff --git a/vendor/github.com/go-openapi/swag/loading/json.go b/vendor/github.com/go-openapi/swag/loading/json.go
new file mode 100644
index 0000000000..59db12f5cf
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/loading/json.go
@@ -0,0 +1,25 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package loading
+
+import (
+ "encoding/json"
+ "errors"
+ "path/filepath"
+)
+
+// JSONMatcher matches json for a file loader.
+func JSONMatcher(path string) bool {
+ ext := filepath.Ext(path)
+ return ext == ".json" || ext == ".jsn" || ext == ".jso"
+}
+
+// JSONDoc loads a json document from either a file or a remote url.
+func JSONDoc(path string, opts ...Option) (json.RawMessage, error) {
+ data, err := LoadFromFileOrHTTP(path, opts...)
+ if err != nil {
+ return nil, errors.Join(err, ErrLoader)
+ }
+ return json.RawMessage(data), nil
+}
diff --git a/vendor/github.com/go-openapi/swag/loading/loading.go b/vendor/github.com/go-openapi/swag/loading/loading.go
new file mode 100644
index 0000000000..269fb74d16
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/loading/loading.go
@@ -0,0 +1,160 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package loading
+
+import (
+ "context"
+ "embed"
+ "fmt"
+ "io"
+ "log"
+ "net/http"
+ "net/url"
+ "path"
+ "path/filepath"
+ "runtime"
+ "strings"
+)
+
+// LoadFromFileOrHTTP loads the bytes from a file or a remote http server based on the path passed in
+func LoadFromFileOrHTTP(pth string, opts ...Option) ([]byte, error) {
+ o := optionsWithDefaults(opts)
+ return LoadStrategy(pth, o.ReadFileFunc(), loadHTTPBytes(opts...), opts...)(pth)
+}
+
+// LoadStrategy returns a loader function for a given path or URI.
+//
+// The load strategy returns the remote load for any path starting with `http`.
+// So this works for any URI with a scheme `http` or `https`.
+//
+// The fallback strategy is to call the local loader.
+//
+// The local loader takes a local file system path (absolute or relative) as argument,
+// or alternatively a `file://...` URI, **without host** (see also below for windows).
+//
+// There are a few liberalities, initially intended to be tolerant regarding the URI syntax,
+// especially on windows.
+//
+// Before the local loader is called, the given path is transformed:
+// - percent-encoded characters are unescaped
+// - simple paths (e.g. `./folder/file`) are passed as-is
+// - on windows, occurrences of `/` are replaced by `\`, so providing a relative path such a `folder/file` works too.
+//
+// For paths provided as URIs with the "file" scheme, please note that:
+// - `file://` is simply stripped.
+// This means that the host part of the URI is not parsed at all.
+// For example, `file:///folder/file" becomes "/folder/file`,
+// but `file://localhost/folder/file` becomes `localhost/folder/file` on unix systems.
+// Similarly, `file://./folder/file` yields `./folder/file`.
+// - on windows, `file://...` can take a host so as to specify an UNC share location.
+//
+// Reminder about windows-specifics:
+// - `file://host/folder/file` becomes an UNC path like `\\host\folder\file` (no port specification is supported)
+// - `file:///c:/folder/file` becomes `C:\folder\file`
+// - `file://c:/folder/file` is tolerated (without leading `/`) and becomes `c:\folder\file`
+func LoadStrategy(pth string, local, remote func(string) ([]byte, error), opts ...Option) func(string) ([]byte, error) {
+ if strings.HasPrefix(pth, "http") {
+ return remote
+ }
+ o := optionsWithDefaults(opts)
+ _, isEmbedFS := o.fs.(embed.FS)
+
+ return func(p string) ([]byte, error) {
+ upth, err := url.PathUnescape(p)
+ if err != nil {
+ return nil, err
+ }
+
+ cpth, hasPrefix := strings.CutPrefix(upth, "file://")
+ if !hasPrefix || isEmbedFS || runtime.GOOS != "windows" {
+ // crude processing: trim the file:// prefix. This leaves full URIs with a host with a (mostly) unexpected result
+ // regular file path provided: just normalize slashes
+ if isEmbedFS {
+ // on windows, we need to slash the path if FS is an embed FS.
+ return local(strings.TrimLeft(filepath.ToSlash(cpth), "./")) // remove invalid leading characters for embed FS
+ }
+
+ return local(filepath.FromSlash(cpth))
+ }
+
+ // windows-only pre-processing of file://... URIs, excluding embed.FS
+
+ // support for canonical file URIs on windows.
+ u, err := url.Parse(filepath.ToSlash(upth))
+ if err != nil {
+ return nil, err
+ }
+
+ if u.Host != "" {
+ // assume UNC name (volume share)
+ // NOTE: UNC port not yet supported
+
+ // when the "host" segment is a drive letter:
+ // file://C:/folder/... => C:\folder
+ upth = path.Clean(strings.Join([]string{u.Host, u.Path}, `/`))
+ if !strings.HasSuffix(u.Host, ":") && u.Host[0] != '.' {
+ // tolerance: if we have a leading dot, this can't be a host
+ // file://host/share/folder\... ==> \\host\share\path\folder
+ upth = "//" + upth
+ }
+ } else {
+ // no host, let's figure out if this is a drive letter
+ upth = strings.TrimPrefix(upth, `file://`)
+ first, _, _ := strings.Cut(strings.TrimPrefix(u.Path, "/"), "/")
+ if strings.HasSuffix(first, ":") {
+ // drive letter in the first segment:
+ // file:///c:/folder/... ==> strip the leading slash
+ upth = strings.TrimPrefix(upth, `/`)
+ }
+ }
+
+ return local(filepath.FromSlash(upth))
+ }
+}
+
+func loadHTTPBytes(opts ...Option) func(path string) ([]byte, error) {
+ o := optionsWithDefaults(opts)
+
+ return func(path string) ([]byte, error) {
+ client := o.client
+ timeoutCtx := context.Background()
+ var cancel func()
+
+ if o.httpTimeout > 0 {
+ timeoutCtx, cancel = context.WithTimeout(timeoutCtx, o.httpTimeout)
+ defer cancel()
+ }
+
+ req, err := http.NewRequestWithContext(timeoutCtx, http.MethodGet, path, nil)
+ if err != nil {
+ return nil, err
+ }
+
+ if o.basicAuthUsername != "" && o.basicAuthPassword != "" {
+ req.SetBasicAuth(o.basicAuthUsername, o.basicAuthPassword)
+ }
+
+ for key, val := range o.customHeaders {
+ req.Header.Set(key, val)
+ }
+
+ resp, err := client.Do(req)
+ defer func() {
+ if resp != nil {
+ if e := resp.Body.Close(); e != nil {
+ log.Println(e)
+ }
+ }
+ }()
+ if err != nil {
+ return nil, err
+ }
+
+ if resp.StatusCode != http.StatusOK {
+ return nil, fmt.Errorf("could not access document at %q [%s]: %w", path, resp.Status, ErrLoader)
+ }
+
+ return io.ReadAll(resp.Body)
+ }
+}
diff --git a/vendor/github.com/go-openapi/swag/loading/options.go b/vendor/github.com/go-openapi/swag/loading/options.go
new file mode 100644
index 0000000000..6674ac69e6
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/loading/options.go
@@ -0,0 +1,125 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package loading
+
+import (
+ "io/fs"
+ "net/http"
+ "os"
+ "time"
+)
+
+type (
+ // Option provides options for loading a file over HTTP or from a file.
+ Option func(*options)
+
+ httpOptions struct {
+ httpTimeout time.Duration
+ basicAuthUsername string
+ basicAuthPassword string
+ customHeaders map[string]string
+ client *http.Client
+ }
+
+ fileOptions struct {
+ fs fs.ReadFileFS
+ }
+
+ options struct {
+ httpOptions
+ fileOptions
+ }
+)
+
+func (fo fileOptions) ReadFileFunc() func(string) ([]byte, error) {
+ if fo.fs == nil {
+ return os.ReadFile
+ }
+
+ return fo.fs.ReadFile
+}
+
+// WithTimeout sets a timeout for the remote file loader.
+//
+// The default timeout is 30s.
+func WithTimeout(timeout time.Duration) Option {
+ return func(o *options) {
+ o.httpTimeout = timeout
+ }
+}
+
+// WithBasicAuth sets a basic authentication scheme for the remote file loader.
+func WithBasicAuth(username, password string) Option {
+ return func(o *options) {
+ o.basicAuthUsername = username
+ o.basicAuthPassword = password
+ }
+}
+
+// WithCustomHeaders sets custom headers for the remote file loader.
+func WithCustomHeaders(headers map[string]string) Option {
+ return func(o *options) {
+ if o.customHeaders == nil {
+ o.customHeaders = make(map[string]string, len(headers))
+ }
+
+ for header, value := range headers {
+ o.customHeaders[header] = value
+ }
+ }
+}
+
+// WithHTTPClient overrides the default HTTP client used to fetch a remote file.
+//
+// By default, [http.DefaultClient] is used.
+func WithHTTPClient(client *http.Client) Option {
+ return func(o *options) {
+ o.client = client
+ }
+}
+
+// WithFS sets a file system for the local file loader.
+//
+// If the provided file system is a [fs.ReadFileFS], the ReadFile function is used.
+// Otherwise, ReadFile is wrapped using [fs.ReadFile].
+//
+// By default, the file system is the one provided by the os package.
+//
+// For example, this may be set to consume from an embedded file system, or a rooted FS.
+func WithFS(filesystem fs.FS) Option {
+ return func(o *options) {
+ if rfs, ok := filesystem.(fs.ReadFileFS); ok {
+ o.fs = rfs
+
+ return
+ }
+ o.fs = readFileFS{FS: filesystem}
+ }
+}
+
+type readFileFS struct {
+ fs.FS
+}
+
+func (r readFileFS) ReadFile(name string) ([]byte, error) {
+ return fs.ReadFile(r.FS, name)
+}
+
+func optionsWithDefaults(opts []Option) options {
+ const defaultTimeout = 30 * time.Second
+
+ o := options{
+ // package level defaults
+ httpOptions: httpOptions{
+ httpTimeout: defaultTimeout,
+ client: http.DefaultClient,
+ },
+ }
+
+ for _, apply := range opts {
+ apply(&o)
+ }
+
+ return o
+}
diff --git a/vendor/github.com/go-openapi/swag/loading/yaml.go b/vendor/github.com/go-openapi/swag/loading/yaml.go
new file mode 100644
index 0000000000..3ebb53668c
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/loading/yaml.go
@@ -0,0 +1,37 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package loading
+
+import (
+ "encoding/json"
+ "path/filepath"
+
+ "github.com/go-openapi/swag/yamlutils"
+)
+
+// YAMLMatcher matches yaml for a file loader.
+func YAMLMatcher(path string) bool {
+ ext := filepath.Ext(path)
+ return ext == ".yaml" || ext == ".yml"
+}
+
+// YAMLDoc loads a yaml document from either http or a file and converts it to json.
+func YAMLDoc(path string, opts ...Option) (json.RawMessage, error) {
+ yamlDoc, err := YAMLData(path, opts...)
+ if err != nil {
+ return nil, err
+ }
+
+ return yamlutils.YAMLToJSON(yamlDoc)
+}
+
+// YAMLData loads a yaml document from either http or a file.
+func YAMLData(path string, opts ...Option) (any, error) {
+ data, err := LoadFromFileOrHTTP(path, opts...)
+ if err != nil {
+ return nil, err
+ }
+
+ return yamlutils.BytesToYAMLDoc(data)
+}
diff --git a/vendor/github.com/go-openapi/swag/loading_iface.go b/vendor/github.com/go-openapi/swag/loading_iface.go
new file mode 100644
index 0000000000..27ec3fb8c3
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/loading_iface.go
@@ -0,0 +1,91 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package swag
+
+import (
+ "encoding/json"
+ "time"
+
+ "github.com/go-openapi/swag/loading"
+)
+
+var (
+ // Package-level defaults for the file loading utilities (deprecated).
+
+ // LoadHTTPTimeout the default timeout for load requests.
+ //
+ // Deprecated: use [loading.WithTimeout] instead.
+ LoadHTTPTimeout = 30 * time.Second
+
+ // LoadHTTPBasicAuthUsername the username to use when load requests require basic auth.
+ //
+ // Deprecated: use [loading.WithBasicAuth] instead.
+ LoadHTTPBasicAuthUsername = ""
+
+ // LoadHTTPBasicAuthPassword the password to use when load requests require basic auth.
+ //
+ // Deprecated: use [loading.WithBasicAuth] instead.
+ LoadHTTPBasicAuthPassword = ""
+
+ // LoadHTTPCustomHeaders an optional collection of custom HTTP headers for load requests.
+ //
+ // Deprecated: use [loading.WithCustomHeaders] instead.
+ LoadHTTPCustomHeaders = map[string]string{}
+)
+
+// LoadFromFileOrHTTP loads the bytes from a file or a remote http server based on the provided path.
+//
+// Deprecated: use [loading.LoadFromFileOrHTTP] instead.
+func LoadFromFileOrHTTP(pth string, opts ...loading.Option) ([]byte, error) {
+ return loading.LoadFromFileOrHTTP(pth, loadingOptionsWithDefaults(opts)...)
+}
+
+// LoadFromFileOrHTTPWithTimeout loads the bytes from a file or a remote http server based on the path passed in
+// timeout arg allows for per request overriding of the request timeout.
+//
+// Deprecated: use [loading.LoadFileOrHTTP] with the [loading.WithTimeout] option instead.
+func LoadFromFileOrHTTPWithTimeout(pth string, timeout time.Duration, opts ...loading.Option) ([]byte, error) {
+ opts = append(opts, loading.WithTimeout(timeout))
+
+ return LoadFromFileOrHTTP(pth, opts...)
+}
+
+// LoadStrategy returns a loader function for a given path or URL.
+//
+// Deprecated: use [loading.LoadStrategy] instead.
+func LoadStrategy(pth string, local, remote func(string) ([]byte, error), opts ...loading.Option) func(string) ([]byte, error) {
+ return loading.LoadStrategy(pth, local, remote, loadingOptionsWithDefaults(opts)...)
+}
+
+// YAMLMatcher matches yaml for a file loader.
+//
+// Deprecated: use [loading.YAMLMatcher] instead.
+func YAMLMatcher(path string) bool { return loading.YAMLMatcher(path) }
+
+// YAMLDoc loads a yaml document from either http or a file and converts it to json.
+//
+// Deprecated: use [loading.YAMLDoc] instead.
+func YAMLDoc(path string) (json.RawMessage, error) {
+ return loading.YAMLDoc(path)
+}
+
+// YAMLData loads a yaml document from either http or a file.
+//
+// Deprecated: use [loading.YAMLData] instead.
+func YAMLData(path string) (any, error) {
+ return loading.YAMLData(path)
+}
+
+// loadingOptionsWithDefaults bridges deprecated default settings that use package-level variables,
+// with the recommended use of loading.Option.
+func loadingOptionsWithDefaults(opts []loading.Option) []loading.Option {
+ o := []loading.Option{
+ loading.WithTimeout(LoadHTTPTimeout),
+ loading.WithBasicAuth(LoadHTTPBasicAuthUsername, LoadHTTPBasicAuthPassword),
+ loading.WithCustomHeaders(LoadHTTPCustomHeaders),
+ }
+ o = append(o, opts...)
+
+ return o
+}
diff --git a/vendor/github.com/go-openapi/swag/mangling/BENCHMARK.md b/vendor/github.com/go-openapi/swag/mangling/BENCHMARK.md
new file mode 100644
index 0000000000..6674c63b72
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/mangling/BENCHMARK.md
@@ -0,0 +1,90 @@
+# Benchmarking name mangling utilities
+
+```bash
+go test -bench XXX -run XXX -benchtime 30s
+```
+
+## Benchmarks at b3e7a5386f996177e4808f11acb2aa93a0f660df
+
+```
+goos: linux
+goarch: amd64
+pkg: github.com/go-openapi/swag
+cpu: Intel(R) Core(TM) i5-6200U CPU @ 2.30GHz
+BenchmarkToXXXName/ToGoName-4 862623 44101 ns/op 10450 B/op 732 allocs/op
+BenchmarkToXXXName/ToVarName-4 853656 40728 ns/op 10468 B/op 734 allocs/op
+BenchmarkToXXXName/ToFileName-4 1268312 27813 ns/op 9785 B/op 617 allocs/op
+BenchmarkToXXXName/ToCommandName-4 1276322 27903 ns/op 9785 B/op 617 allocs/op
+BenchmarkToXXXName/ToHumanNameLower-4 895334 40354 ns/op 10472 B/op 731 allocs/op
+BenchmarkToXXXName/ToHumanNameTitle-4 882441 40678 ns/op 10566 B/op 749 allocs/op
+```
+
+## Benchmarks after PR #79
+
+~ x10 performance improvement and ~ /100 memory allocations.
+
+```
+goos: linux
+goarch: amd64
+pkg: github.com/go-openapi/swag
+cpu: Intel(R) Core(TM) i5-6200U CPU @ 2.30GHz
+BenchmarkToXXXName/ToGoName-4 9595830 3991 ns/op 42 B/op 5 allocs/op
+BenchmarkToXXXName/ToVarName-4 9194276 3984 ns/op 62 B/op 7 allocs/op
+BenchmarkToXXXName/ToFileName-4 17002711 2123 ns/op 147 B/op 7 allocs/op
+BenchmarkToXXXName/ToCommandName-4 16772926 2111 ns/op 147 B/op 7 allocs/op
+BenchmarkToXXXName/ToHumanNameLower-4 9788331 3749 ns/op 92 B/op 6 allocs/op
+BenchmarkToXXXName/ToHumanNameTitle-4 9188260 3941 ns/op 104 B/op 6 allocs/op
+```
+
+```
+goos: linux
+goarch: amd64
+pkg: github.com/go-openapi/swag
+cpu: AMD Ryzen 7 5800X 8-Core Processor
+BenchmarkToXXXName/ToGoName-16 18527378 1972 ns/op 42 B/op 5 allocs/op
+BenchmarkToXXXName/ToVarName-16 15552692 2093 ns/op 62 B/op 7 allocs/op
+BenchmarkToXXXName/ToFileName-16 32161176 1117 ns/op 147 B/op 7 allocs/op
+BenchmarkToXXXName/ToCommandName-16 32256634 1137 ns/op 147 B/op 7 allocs/op
+BenchmarkToXXXName/ToHumanNameLower-16 18599661 1946 ns/op 92 B/op 6 allocs/op
+BenchmarkToXXXName/ToHumanNameTitle-16 17581353 2054 ns/op 105 B/op 6 allocs/op
+```
+
+## Benchmarks at d7d2d1b895f5b6747afaff312dd2a402e69e818b
+
+go1.24
+
+```
+goos: linux
+goarch: amd64
+pkg: github.com/go-openapi/swag
+cpu: AMD Ryzen 7 5800X 8-Core Processor
+BenchmarkToXXXName/ToGoName-16 19757858 1881 ns/op 42 B/op 5 allocs/op
+BenchmarkToXXXName/ToVarName-16 17494111 2094 ns/op 74 B/op 7 allocs/op
+BenchmarkToXXXName/ToFileName-16 28161226 1492 ns/op 158 B/op 7 allocs/op
+BenchmarkToXXXName/ToCommandName-16 23787333 1489 ns/op 158 B/op 7 allocs/op
+BenchmarkToXXXName/ToHumanNameLower-16 17537257 2030 ns/op 103 B/op 6 allocs/op
+BenchmarkToXXXName/ToHumanNameTitle-16 16977453 2156 ns/op 105 B/op 6 allocs/op
+```
+
+## Benchmarks after PR #106
+
+Moving the scope of everything down to a struct allowed to reduce a bit garbage and pooling.
+
+On top of that, ToGoName (and thus ToVarName) have been subject to a minor optimization, removing a few allocations.
+
+Overall timings improve by ~ -10%.
+
+go1.24
+
+```
+goos: linux
+goarch: amd64
+pkg: github.com/go-openapi/swag/mangling
+cpu: AMD Ryzen 7 5800X 8-Core Processor
+BenchmarkToXXXName/ToGoName-16 22496130 1618 ns/op 31 B/op 3 allocs/op
+BenchmarkToXXXName/ToVarName-16 22538068 1618 ns/op 33 B/op 3 allocs/op
+BenchmarkToXXXName/ToFileName-16 27722977 1236 ns/op 105 B/op 6 allocs/op
+BenchmarkToXXXName/ToCommandName-16 27967395 1258 ns/op 105 B/op 6 allocs/op
+BenchmarkToXXXName/ToHumanNameLower-16 18587901 1917 ns/op 103 B/op 6 allocs/op
+BenchmarkToXXXName/ToHumanNameTitle-16 17193208 2019 ns/op 108 B/op 7 allocs/op
+```
diff --git a/vendor/github.com/go-openapi/swag/mangling/LICENSE b/vendor/github.com/go-openapi/swag/mangling/LICENSE
new file mode 100644
index 0000000000..d645695673
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/mangling/LICENSE
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/vendor/github.com/go-openapi/swag/mangling/doc.go b/vendor/github.com/go-openapi/swag/mangling/doc.go
new file mode 100644
index 0000000000..ce0d890485
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/mangling/doc.go
@@ -0,0 +1,25 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+// Package mangling provides name mangling capabilities.
+//
+// Name mangling is an important stage when generating code:
+// it helps construct safe program identifiers that abide by the language rules
+// and play along with linters.
+//
+// Examples:
+//
+// Suppose we get an object name taken from an API spec: "json_object",
+//
+// We may generate a legit go type name using [NameMangler.ToGoName]: "JsonObject".
+//
+// We may then locate this type in a source file named using [NameMangler.ToFileName]: "json_object.go".
+//
+// The methods exposed by the NameMangler are used to generate code in many different contexts, such as:
+//
+// - generating exported or unexported go identifiers from a JSON schema or an API spec
+// - generating file names
+// - generating human-readable comments for types and variables
+// - generating JSON-like API identifiers from go code
+// - ...
+package mangling
diff --git a/vendor/github.com/go-openapi/swag/mangling/initialism_index.go b/vendor/github.com/go-openapi/swag/mangling/initialism_index.go
new file mode 100644
index 0000000000..e5b70c1493
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/mangling/initialism_index.go
@@ -0,0 +1,270 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package mangling
+
+import (
+ "sort"
+ "strings"
+ "unicode"
+ "unicode/utf8"
+)
+
+// DefaultInitialisms returns all the initialisms configured by default for this package.
+//
+// # Motivation
+//
+// Common initialisms are acronyms for which the ordinary camel-casing rules are altered and
+// for which we retain the original case.
+//
+// This is largely specific to the go naming conventions enforced by golint (now revive).
+//
+// # Example
+//
+// In go, "id" is a good-looking identifier, but "Id" is not and "ID" is preferred
+// (notice that this stems only from conventions: the go compiler accepts all of these).
+//
+// Similarly, we may use "http", but not "Http". In this case, "HTTP" is preferred.
+//
+// # Reference and customization
+//
+// The default list of these casing-style exceptions is taken from the [github.com/mgechev/revive] linter for go:
+// https://github.com/mgechev/revive/blob/master/lint/name.go#L93
+//
+// There are a few additions to the original list, such as IPv4, IPv6 and OAI ("OpenAPI").
+//
+// For these additions, "IPv4" would be preferred to "Ipv4" or "IPV4", and "OAI" to "Oai"
+//
+// You may redefine this list entirely using the mangler option [WithInitialisms], or simply add extra definitions
+// using [WithAdditionalInitialisms].
+//
+// # Mixed-case and plurals
+//
+// Notice that initialisms are not necessarily fully upper-cased: a mixed-case initialism indicates the preferred casing.
+//
+// Obviously, lower-case only initialisms do not make a lot of sense: if lower-case only initialisms are added,
+// they will be considered fully capitalized.
+//
+// Plural forms use mixed case like "IDs". And so do values like "IPv4" or "IPv6".
+//
+// The [NameMangler] automatically detects simple plurals for words such as "IDs" or "APIs",
+// so you don't need to configure these variants.
+//
+// At this moment, it doesn't support pluralization of terms that ends with an 's' (or 'S'), since there is
+// no clear consensus on whether a word like DNS should be pluralized as DNSes or remain invariant.
+// The [NameMangler] consider those invariant. Therefore DNSs or DNSes are not recognized as plurals for DNS.
+//
+// Besids, we don't want to support pluralization of terms which would otherwise conflict with another one,
+// like "HTTPs" vs "HTTPS". All these should be considered invariant. Hence: "Https" matches "HTTPS" and
+// "HTTPSS" is "HTTPS" followed by "S".
+func DefaultInitialisms() []string {
+ return []string{
+ "ACL",
+ "API",
+ "ASCII",
+ "CPU",
+ "CSS",
+ "DNS",
+ "EOF",
+ "GUID",
+ "HTML",
+ "HTTPS",
+ "HTTP",
+ "ID",
+ "IP",
+ "IPv4", // prefer the mixed case outcome IPv4 over the capitalized IPV4
+ "IPv6", // prefer the mixed case outcome IPv6 over the capitalized IPV6
+ "JSON",
+ "LHS",
+ "OAI",
+ "QPS",
+ "RAM",
+ "RHS",
+ "RPC",
+ "SLA",
+ "SMTP",
+ "SQL",
+ "SSH",
+ "TCP",
+ "TLS",
+ "TTL",
+ "UDP",
+ "UI",
+ "UID",
+ "UUID",
+ "URI",
+ "URL",
+ "UTF8",
+ "VM",
+ "XML",
+ "XMPP",
+ "XSRF",
+ "XSS",
+ }
+}
+
+type indexOfInitialisms struct {
+ initialismsCache
+
+ index map[string]struct{}
+}
+
+func newIndexOfInitialisms() *indexOfInitialisms {
+ return &indexOfInitialisms{
+ index: make(map[string]struct{}),
+ }
+}
+
+func (m *indexOfInitialisms) add(words ...string) *indexOfInitialisms {
+ for _, word := range words {
+ // sanitization of injected words: trimmed from blanks, and must start with a letter
+ trimmed := strings.TrimSpace(word)
+
+ firstRune, _ := utf8.DecodeRuneInString(trimmed)
+ if !unicode.IsLetter(firstRune) {
+ continue
+ }
+
+ // Initialisms are case-sensitive. This means that we support mixed-case words.
+ // However, if specified as a lower-case string, the initialism should be fully capitalized.
+ if trimmed == strings.ToLower(trimmed) {
+ m.index[strings.ToUpper(trimmed)] = struct{}{}
+
+ continue
+ }
+
+ m.index[trimmed] = struct{}{}
+ }
+ return m
+}
+
+func (m *indexOfInitialisms) sorted() []string {
+ result := make([]string, 0, len(m.index))
+ for k := range m.index {
+ result = append(result, k)
+ }
+ sort.Sort(sort.Reverse(byInitialism(result)))
+ return result
+}
+
+func (m *indexOfInitialisms) buildCache() {
+ m.build(m.sorted(), m.pluralForm)
+}
+
+// initialismsCache caches all needed pre-computed and converted initialism entries,
+// in the desired resolution order.
+type initialismsCache struct {
+ initialisms []string
+ initialismsRunes [][]rune
+ initialismsUpperCased [][]rune // initialisms cached in their trimmed, upper-cased version
+ initialismsPluralForm []pluralForm
+}
+
+func (c *initialismsCache) build(in []string, pluralfunc func(string) pluralForm) {
+ c.initialisms = in
+ c.initialismsRunes = asRunes(c.initialisms)
+ c.initialismsUpperCased = asUpperCased(c.initialisms)
+ c.initialismsPluralForm = asPluralForms(c.initialisms, pluralfunc)
+}
+
+// pluralForm denotes the kind of pluralization to be used for initialisms.
+//
+// At this moment, initialisms are either invariant or follow a simple plural form with an
+// extra (lower case) "s".
+type pluralForm uint8
+
+const (
+ notPlural pluralForm = iota
+ invariantPlural
+ simplePlural
+)
+
+func (f pluralForm) String() string {
+ switch f {
+ case notPlural:
+ return "notPlural"
+ case invariantPlural:
+ return "invariantPlural"
+ case simplePlural:
+ return "simplePlural"
+ default:
+ return ""
+ }
+}
+
+// pluralForm indicates how we want to pluralize a given initialism.
+//
+// Besides configured invariant forms (like HTTP and HTTPS),
+// an initialism is normally pluralized by adding a single 's', like in IDs.
+//
+// Initialisms ending with an 'S' or an 's' are configured as invariant (we don't
+// support plural forms like CSSes or DNSes, however the mechanism could be extended to
+// do just that).
+func (m *indexOfInitialisms) pluralForm(key string) pluralForm {
+ if _, ok := m.index[key]; !ok {
+ return notPlural
+ }
+
+ if strings.HasSuffix(strings.ToUpper(key), "S") {
+ return invariantPlural
+ }
+
+ if _, ok := m.index[key+"s"]; ok {
+ return invariantPlural
+ }
+
+ if _, ok := m.index[key+"S"]; ok {
+ return invariantPlural
+ }
+
+ return simplePlural
+}
+
+type byInitialism []string
+
+func (s byInitialism) Len() int {
+ return len(s)
+}
+func (s byInitialism) Swap(i, j int) {
+ s[i], s[j] = s[j], s[i]
+}
+
+// Less specifies the order in which initialisms are prioritized:
+// 1. match longest first
+// 2. when equal length, match in reverse lexicographical order, lower case match comes first
+func (s byInitialism) Less(i, j int) bool {
+ if len(s[i]) != len(s[j]) {
+ return len(s[i]) < len(s[j])
+ }
+
+ return s[i] < s[j]
+}
+
+func asRunes(in []string) [][]rune {
+ out := make([][]rune, len(in))
+ for i, initialism := range in {
+ out[i] = []rune(initialism)
+ }
+
+ return out
+}
+
+func asUpperCased(in []string) [][]rune {
+ out := make([][]rune, len(in))
+
+ for i, initialism := range in {
+ out[i] = []rune(upper(trim(initialism)))
+ }
+
+ return out
+}
+
+// asPluralForms bakes an index of pluralization support.
+func asPluralForms(in []string, pluralFunc func(string) pluralForm) []pluralForm {
+ out := make([]pluralForm, len(in))
+ for i, initialism := range in {
+ out[i] = pluralFunc(initialism)
+ }
+
+ return out
+}
diff --git a/vendor/github.com/go-openapi/swag/mangling/name_lexem.go b/vendor/github.com/go-openapi/swag/mangling/name_lexem.go
new file mode 100644
index 0000000000..bc837e3b9f
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/mangling/name_lexem.go
@@ -0,0 +1,186 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package mangling
+
+import (
+ "bytes"
+ "strings"
+ "unicode"
+ "unicode/utf8"
+)
+
+type (
+ lexemKind uint8
+
+ nameLexem struct {
+ original string
+ matchedInitialism string
+ kind lexemKind
+ }
+)
+
+const (
+ lexemKindCasualName lexemKind = iota
+ lexemKindInitialismName
+)
+
+func newInitialismNameLexem(original, matchedInitialism string) nameLexem {
+ return nameLexem{
+ kind: lexemKindInitialismName,
+ original: original,
+ matchedInitialism: matchedInitialism,
+ }
+}
+
+func newCasualNameLexem(original string) nameLexem {
+ return nameLexem{
+ kind: lexemKindCasualName,
+ original: trim(original), // TODO: save on calls to trim
+ }
+}
+
+// WriteTitleized writes the titleized lexeme to a bytes.Buffer.
+//
+// If the first letter cannot be capitalized, it doesn't write anything and return false,
+// so the caller may attempt some workaround strategy.
+func (l nameLexem) WriteTitleized(w *bytes.Buffer, alwaysUpper bool) bool {
+ if l.kind == lexemKindInitialismName {
+ w.WriteString(l.matchedInitialism)
+
+ return true
+ }
+
+ if len(l.original) == 0 {
+ return true
+ }
+
+ if len(l.original) == 1 {
+ // identifier is too short: casing will depend on the context
+ firstByte := l.original[0]
+ switch {
+ case 'A' <= firstByte && firstByte <= 'Z':
+ // safe
+ w.WriteByte(firstByte)
+
+ return true
+ case alwaysUpper && 'a' <= firstByte && firstByte <= 'z':
+ w.WriteByte(firstByte - 'a' + 'A')
+
+ return true
+ default:
+
+ // not a letter: skip and let the caller decide
+ return false
+ }
+ }
+
+ if firstByte := l.original[0]; firstByte < utf8.RuneSelf {
+ // ASCII
+ switch {
+ case 'A' <= firstByte && firstByte <= 'Z':
+ // already an upper case letter
+ w.WriteString(l.original)
+
+ return true
+ case 'a' <= firstByte && firstByte <= 'z':
+ w.WriteByte(firstByte - 'a' + 'A')
+ w.WriteString(l.original[1:])
+
+ return true
+ default:
+ // not a good candidate: doesn't start with a letter
+ return false
+ }
+ }
+
+ // unicode
+ firstRune, idx := utf8.DecodeRuneInString(l.original)
+ if !unicode.IsLetter(firstRune) || !unicode.IsUpper(unicode.ToUpper(firstRune)) {
+ // not a good candidate: doesn't start with a letter
+ // or a rune for which case doesn't make sense (e.g. East-Asian runes etc)
+ return false
+ }
+
+ rest := l.original[idx:]
+ w.WriteRune(unicode.ToUpper(firstRune))
+ w.WriteString(strings.ToLower(rest))
+
+ return true
+}
+
+// WriteLower is like write titleized but it writes a lower-case version of the lexeme.
+//
+// Similarly, there is no writing if the casing of the first rune doesn't make sense.
+func (l nameLexem) WriteLower(w *bytes.Buffer, alwaysLower bool) bool {
+ if l.kind == lexemKindInitialismName {
+ w.WriteString(lower(l.matchedInitialism))
+
+ return true
+ }
+
+ if len(l.original) == 0 {
+ return true
+ }
+
+ if len(l.original) == 1 {
+ // identifier is too short: casing will depend on the context
+ firstByte := l.original[0]
+ switch {
+ case 'a' <= firstByte && firstByte <= 'z':
+ // safe
+ w.WriteByte(firstByte)
+
+ return true
+ case alwaysLower && 'A' <= firstByte && firstByte <= 'Z':
+ w.WriteByte(firstByte - 'A' + 'a')
+
+ return true
+ default:
+
+ // not a letter: skip and let the caller decide
+ return false
+ }
+ }
+
+ if firstByte := l.original[0]; firstByte < utf8.RuneSelf {
+ // ASCII
+ switch {
+ case 'a' <= firstByte && firstByte <= 'z':
+ // already a lower case letter
+ w.WriteString(l.original)
+
+ return true
+ case 'A' <= firstByte && firstByte <= 'Z':
+ w.WriteByte(firstByte - 'A' + 'a')
+ w.WriteString(l.original[1:])
+
+ return true
+ default:
+ // not a good candidate: doesn't start with a letter
+ return false
+ }
+ }
+
+ // unicode
+ firstRune, idx := utf8.DecodeRuneInString(l.original)
+ if !unicode.IsLetter(firstRune) || !unicode.IsLower(unicode.ToLower(firstRune)) {
+ // not a good candidate: doesn't start with a letter
+ // or a rune for which case doesn't make sense (e.g. East-Asian runes etc)
+ return false
+ }
+
+ rest := l.original[idx:]
+ w.WriteRune(unicode.ToLower(firstRune))
+ w.WriteString(rest)
+
+ return true
+}
+
+func (l nameLexem) GetOriginal() string {
+ return l.original
+}
+
+func (l nameLexem) IsInitialism() bool {
+ return l.kind == lexemKindInitialismName
+}
diff --git a/vendor/github.com/go-openapi/swag/mangling/name_mangler.go b/vendor/github.com/go-openapi/swag/mangling/name_mangler.go
new file mode 100644
index 0000000000..da685681d0
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/mangling/name_mangler.go
@@ -0,0 +1,370 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package mangling
+
+import (
+ "strings"
+ "unicode"
+)
+
+// NameMangler knows how to transform sentences or words into
+// identifiers that are a better fit in contexts such as:
+//
+// - unexported or exported go variable identifiers
+// - file names
+// - camel cased identifiers
+// - ...
+//
+// The [NameMangler] is safe for concurrent use, save for its [NameMangler.AddInitialisms] method,
+// which is not.
+//
+// # Known limitations
+//
+// At this moment, the [NameMangler] doesn't play well with "all caps" text:
+//
+// unless every single upper-cased word is declared as an initialism, capitalized words would generally
+// not be transformed with the expected result, e.g.
+//
+// ToFileName("THIS_IS_ALL_CAPS")
+//
+// yields the weird outcome
+//
+// "t_h_i_s_i_s_a_l_l_c_a_p_s"
+type NameMangler struct {
+ options
+
+ index *indexOfInitialisms
+
+ splitter splitter
+ splitterWithPostSplit splitter
+
+ _ struct{}
+}
+
+// NewNameMangler builds a name mangler ready to convert strings.
+//
+// The default name mangler is configured with default common initialisms and all default options.
+func NewNameMangler(opts ...Option) NameMangler {
+ m := NameMangler{
+ options: optionsWithDefaults(opts),
+ index: newIndexOfInitialisms(),
+ }
+ m.addInitialisms(m.commonInitialisms...)
+
+ // a splitter that returns matches lexemes as ready-to-assemble strings:
+ // details of the lexemes are redeemed.
+ m.splitter = newSplitter(
+ withInitialismsCache(&m.index.initialismsCache),
+ withReplaceFunc(m.replaceFunc),
+ )
+
+ // a splitter that returns matches lexemes ready for post-processing
+ m.splitterWithPostSplit = newSplitter(
+ withInitialismsCache(&m.index.initialismsCache),
+ withReplaceFunc(m.replaceFunc),
+ withPostSplitInitialismCheck,
+ )
+
+ return m
+}
+
+// AddInitialisms declares extra initialisms to the mangler.
+//
+// It declares extra words as "initialisms" (i.e. words that won't be camel cased or titled cased),
+// on top of the existing list of common initialisms (such as ID, HTTP...).
+//
+// Added words must start with a (unicode) letter. If some don't, they are ignored.
+// Added words are either fully capitalized or mixed-cased. Lower-case only words are considered capitalized.
+//
+// It is typically used just after initializing the [NameMangler].
+//
+// When all initialisms are known at the time the mangler is initialized, it is preferable to
+// use [NewNameMangler] with the option [WithAdditionalInitialisms].
+//
+// Adding initialisms mutates the mangler and should not be carried out concurrently with other calls to the mangler.
+func (m *NameMangler) AddInitialisms(words ...string) {
+ m.addInitialisms(words...)
+}
+
+// Initialisms renders the list of initialisms supported by this mangler.
+func (m *NameMangler) Initialisms() []string {
+ return m.index.initialisms
+}
+
+// Camelize a single word.
+//
+// Example:
+//
+// - "HELLO" and "hello" become "Hello".
+func (m NameMangler) Camelize(word string) string {
+ ru := []rune(word)
+
+ switch len(ru) {
+ case 0:
+ return ""
+ case 1:
+ return string(unicode.ToUpper(ru[0]))
+ default:
+ camelized := poolOfBuffers.BorrowBuffer(len(word))
+ camelized.Grow(len(word))
+ defer func() {
+ poolOfBuffers.RedeemBuffer(camelized)
+ }()
+
+ camelized.WriteRune(unicode.ToUpper(ru[0]))
+ for _, ru := range ru[1:] {
+ camelized.WriteRune(unicode.ToLower(ru))
+ }
+
+ return camelized.String()
+ }
+}
+
+// ToFileName generates a suitable snake-case file name from a sentence.
+//
+// It lower-cases everything with underscore (_) as a word separator.
+//
+// Examples:
+//
+// - "Hello, Swagger" becomes "hello_swagger"
+// - "HelloSwagger" becomes "hello_swagger"
+func (m NameMangler) ToFileName(name string) string {
+ inptr := m.split(name)
+ in := *inptr
+ out := make([]string, 0, len(in))
+
+ for _, w := range in {
+ out = append(out, lower(w))
+ }
+ poolOfStrings.RedeemStrings(inptr)
+
+ return strings.Join(out, "_")
+}
+
+// ToCommandName generates a suitable CLI command name from a sentence.
+//
+// It lower-cases everything with dash (-) as a word separator.
+//
+// Examples:
+//
+// - "Hello, Swagger" becomes "hello-swagger"
+// - "HelloSwagger" becomes "hello-swagger"
+func (m NameMangler) ToCommandName(name string) string {
+ inptr := m.split(name)
+ in := *inptr
+ out := make([]string, 0, len(in))
+
+ for _, w := range in {
+ out = append(out, lower(w))
+ }
+ poolOfStrings.RedeemStrings(inptr)
+
+ return strings.Join(out, "-")
+}
+
+// ToHumanNameLower represents a code name as a human-readable series of words.
+//
+// It lower-cases everything with blank space as a word separator.
+//
+// NOTE: parts recognized as initialisms just keep their original casing.
+//
+// Examples:
+//
+// - "Hello, Swagger" becomes "hello swagger"
+// - "HelloSwagger" or "Hello-Swagger" become "hello swagger"
+func (m NameMangler) ToHumanNameLower(name string) string {
+ s := m.splitterWithPostSplit
+ in := s.split(name)
+ out := make([]string, 0, len(*in))
+
+ for _, w := range *in {
+ if !w.IsInitialism() {
+ out = append(out, lower(w.GetOriginal()))
+ } else {
+ out = append(out, trim(w.GetOriginal()))
+ }
+ }
+
+ poolOfLexems.RedeemLexems(in)
+
+ return strings.Join(out, " ")
+}
+
+// ToHumanNameTitle represents a code name as a human-readable series of titleized words.
+//
+// It titleizes every word with blank space as a word separator.
+//
+// Examples:
+//
+// - "hello, Swagger" becomes "Hello Swagger"
+// - "helloSwagger" becomes "Hello Swagger"
+func (m NameMangler) ToHumanNameTitle(name string) string {
+ s := m.splitterWithPostSplit
+ in := s.split(name)
+
+ out := make([]string, 0, len(*in))
+ for _, w := range *in {
+ original := trim(w.GetOriginal())
+ if !w.IsInitialism() {
+ out = append(out, m.Camelize(original))
+ } else {
+ out = append(out, original)
+ }
+ }
+ poolOfLexems.RedeemLexems(in)
+
+ return strings.Join(out, " ")
+}
+
+// ToJSONName generates a camelized single-word version of a sentence.
+//
+// The output assembles every camelized word, but for the first word, which
+// is lower-cased.
+//
+// Example:
+//
+// - "Hello_swagger" becomes "helloSwagger"
+func (m NameMangler) ToJSONName(name string) string {
+ inptr := m.split(name)
+ in := *inptr
+ out := make([]string, 0, len(in))
+
+ for i, w := range in {
+ if i == 0 {
+ out = append(out, lower(w))
+ continue
+ }
+ out = append(out, m.Camelize(trim(w)))
+ }
+
+ poolOfStrings.RedeemStrings(inptr)
+
+ return strings.Join(out, "")
+}
+
+// ToVarName generates a legit unexported go variable name from a sentence.
+//
+// The generated name plays well with linters (see also [NameMangler.ToGoName]).
+//
+// Examples:
+//
+// - "Hello_swagger" becomes "helloSwagger"
+// - "Http_server" becomes "httpServer"
+//
+// This name applies the same rules as [NameMangler.ToGoName] (legit exported variable), save the
+// capitalization of the initial rune.
+//
+// Special case: when the initial part is a recognized as an initialism (like in the example above),
+// the full part is lower-cased.
+func (m NameMangler) ToVarName(name string) string {
+ return m.goIdentifier(name, false)
+}
+
+// ToGoName generates a legit exported go variable name from a sentence.
+//
+// The generated name plays well with most linters.
+//
+// ToGoName abides by the go "exported" symbol rule starting with an upper-case letter.
+//
+// Examples:
+//
+// - "hello_swagger" becomes "HelloSwagger"
+// - "Http_server" becomes "HTTPServer"
+//
+// # Edge cases
+//
+// Whenever the first rune is not eligible to upper case, a special prefix is prepended to the resulting name.
+// By default this is simply "X" and you may customize this behavior using the [WithGoNamePrefixFunc] option.
+//
+// This happens when the first rune is not a letter, e.g. a digit, or a symbol that has no word transliteration
+// (see also [WithReplaceFunc] about symbol transliterations),
+// as well as for most East Asian or Devanagari runes, for which there is no such concept as upper-case.
+//
+// # Linting
+//
+// [revive], the successor of golint is the reference linter.
+//
+// This means that [NameMangler.ToGoName] supports the initialisms that revive checks (see also [DefaultInitialisms]).
+//
+// At this moment, there is no attempt to transliterate unicode into ascii, meaning that some linters
+// (e.g. asciicheck, gosmopolitan) may croak on go identifiers generated from unicode input.
+//
+// [revive]: https://github.com/mgechev/revive
+func (m NameMangler) ToGoName(name string) string {
+ return m.goIdentifier(name, true)
+}
+
+func (m NameMangler) goIdentifier(name string, exported bool) string {
+ s := m.splitterWithPostSplit
+ lexems := s.split(name)
+ defer func() {
+ poolOfLexems.RedeemLexems(lexems)
+ }()
+ lexemes := *lexems
+
+ if len(lexemes) == 0 {
+ return ""
+ }
+
+ result := poolOfBuffers.BorrowBuffer(len(name))
+ defer func() {
+ poolOfBuffers.RedeemBuffer(result)
+ }()
+
+ firstPart := lexemes[0]
+ if !exported {
+ if ok := firstPart.WriteLower(result, true); !ok {
+ // NOTE: an initialism as the first part is lower-cased: no longer generates stuff like hTTPxyz.
+ //
+ // same prefixing rule applied to unexported variable as to an exported one, so that we have consistent
+ // names, whether the generated identifier is exported or not.
+ result.WriteString(strings.ToLower(m.prefixFunc()(name)))
+ result.WriteString(lexemes[0].GetOriginal())
+ }
+ } else {
+ if ok := firstPart.WriteTitleized(result, true); !ok {
+ // "repairs" a lexeme that doesn't start with a letter to become
+ // the start a legit go name. The current strategy is very crude and simply adds a fixed prefix,
+ // e.g. "X".
+ // For instance "1_sesame_street" would be split into lexemes ["1", "sesame", "street"] and
+ // the first one ("1") would result in something like "X1" (with the default prefix function).
+ //
+ // NOTE: no longer forcing the first part to be fully upper-cased
+ result.WriteString(m.prefixFunc()(name))
+ result.WriteString(lexemes[0].GetOriginal())
+ }
+ }
+
+ for _, lexem := range lexemes[1:] {
+ // NOTE: no longer forcing initialism parts to be fully upper-cased:
+ // * pluralized initialism preserve their trailing "s"
+ // * mixed-cased initialisms, such as IPv4, are preserved
+ if ok := lexem.WriteTitleized(result, false); !ok {
+ // it's not titleized: perhaps it's too short, perhaps the first rune is not a letter.
+ // write anyway
+ result.WriteString(lexem.GetOriginal())
+ }
+ }
+
+ return result.String()
+}
+
+func (m *NameMangler) addInitialisms(words ...string) {
+ m.index.add(words...)
+ m.index.buildCache()
+}
+
+// split calls the inner splitter.
+func (m NameMangler) split(str string) *[]string {
+ s := m.splitter
+ lexems := s.split(str)
+ result := poolOfStrings.BorrowStrings()
+
+ for _, lexem := range *lexems {
+ *result = append(*result, lexem.GetOriginal())
+ }
+ poolOfLexems.RedeemLexems(lexems)
+
+ return result
+}
diff --git a/vendor/github.com/go-openapi/swag/mangling/options.go b/vendor/github.com/go-openapi/swag/mangling/options.go
new file mode 100644
index 0000000000..3c92b2f18b
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/mangling/options.go
@@ -0,0 +1,150 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package mangling
+
+type (
+ // PrefixFunc defines a safeguard rule (that may depend on the input string), to prefix
+ // a generated go name (in [NameMangler.ToGoName] and [NameMangler.ToVarName]).
+ //
+ // See [NameMangler.ToGoName] for more about which edge cases the prefix function covers.
+ PrefixFunc func(string) string
+
+ // ReplaceFunc is a transliteration function to replace special runes by a word.
+ ReplaceFunc func(r rune) (string, bool)
+
+ // Option to configure a [NameMangler].
+ Option func(*options)
+
+ options struct {
+ commonInitialisms []string
+
+ goNamePrefixFunc PrefixFunc
+ goNamePrefixFuncPtr *PrefixFunc
+ replaceFunc func(r rune) (string, bool)
+ }
+)
+
+func (o *options) prefixFunc() PrefixFunc {
+ if o.goNamePrefixFuncPtr != nil && *o.goNamePrefixFuncPtr != nil {
+ return *o.goNamePrefixFuncPtr
+ }
+
+ return o.goNamePrefixFunc
+}
+
+// WithGoNamePrefixFunc overrides the default prefix rule to safeguard generated go names.
+//
+// Example:
+//
+// This helps convert "123" into "{prefix}123" (a very crude strategy indeed, but it works).
+//
+// See [github.com/go-swagger/go-swagger/generator.DefaultFuncMap] for an example.
+//
+// The prefix function is assumed to return a string that starts with an upper case letter.
+//
+// The default is to prefix with "X".
+//
+// See [NameMangler.ToGoName] for more about which edge cases the prefix function covers.
+func WithGoNamePrefixFunc(fn PrefixFunc) Option {
+ return func(o *options) {
+ o.goNamePrefixFunc = fn
+ }
+}
+
+// WithGoNamePrefixFuncPtr is like [WithGoNamePrefixFunc] but it specifies a pointer to a function.
+//
+// [WithGoNamePrefixFunc] should be preferred in most situations. This option should only serve the
+// purpose of handling special situations where the prefix function is not an internal variable
+// (e.g. an exported package global).
+//
+// [WithGoNamePrefixFuncPtr] supersedes [WithGoNamePrefixFunc] if it also specified.
+//
+// If the provided pointer is nil or points to a nil value, this option has no effect.
+//
+// The caller should ensure that no undesirable concurrent changes are applied to the function pointed to.
+func WithGoNamePrefixFuncPtr(ptr *PrefixFunc) Option {
+ return func(o *options) {
+ o.goNamePrefixFuncPtr = ptr
+ }
+}
+
+// WithInitialisms declares the initialisms this mangler supports.
+//
+// This supersedes any pre-loaded defaults (see [DefaultInitialisms] for more about what initialisms are).
+//
+// It declares words to be recognized as "initialisms" (i.e. words that won't be camel cased or titled cased).
+//
+// Words must start with a (unicode) letter. If some don't, they are ignored.
+// Words are either fully capitalized or mixed-cased. Lower-case only words are considered capitalized.
+func WithInitialisms(words ...string) Option {
+ return func(o *options) {
+ o.commonInitialisms = words
+ }
+}
+
+// WithAdditionalInitialisms adds new initialisms to the currently supported list (see [DefaultInitialisms]).
+//
+// The same sanitization rules apply as those described for [WithInitialisms].
+func WithAdditionalInitialisms(words ...string) Option {
+ return func(o *options) {
+ o.commonInitialisms = append(o.commonInitialisms, words...)
+ }
+}
+
+// WithReplaceFunc specifies a custom transliteration function instead of the default.
+//
+// The default translates the following characters into words as follows:
+//
+// - '@' -> 'At'
+// - '&' -> 'And'
+// - '|' -> 'Pipe'
+// - '$' -> 'Dollar'
+// - '!' -> 'Bang'
+//
+// Notice that the outcome of a transliteration should always be titleized.
+func WithReplaceFunc(fn ReplaceFunc) Option {
+ return func(o *options) {
+ o.replaceFunc = fn
+ }
+}
+
+func defaultPrefixFunc(_ string) string {
+ return "X"
+}
+
+// defaultReplaceTable finds a word representation for special characters.
+func defaultReplaceTable(r rune) (string, bool) {
+ switch r {
+ case '@':
+ return "At ", true
+ case '&':
+ return "And ", true
+ case '|':
+ return "Pipe ", true
+ case '$':
+ return "Dollar ", true
+ case '!':
+ return "Bang ", true
+ case '-':
+ return "", true
+ case '_':
+ return "", true
+ default:
+ return "", false
+ }
+}
+
+func optionsWithDefaults(opts []Option) options {
+ o := options{
+ commonInitialisms: DefaultInitialisms(),
+ goNamePrefixFunc: defaultPrefixFunc,
+ replaceFunc: defaultReplaceTable,
+ }
+
+ for _, apply := range opts {
+ apply(&o)
+ }
+
+ return o
+}
diff --git a/vendor/github.com/go-openapi/swag/mangling/pools.go b/vendor/github.com/go-openapi/swag/mangling/pools.go
new file mode 100644
index 0000000000..f810435144
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/mangling/pools.go
@@ -0,0 +1,123 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package mangling
+
+import (
+ "bytes"
+ "sync"
+)
+
+const maxAllocMatches = 8
+
+type (
+ // memory pools of temporary objects.
+ //
+ // These are used to recycle temporarily allocated objects
+ // and relieve the GC from undue pressure.
+
+ matchesPool struct {
+ *sync.Pool
+ }
+
+ buffersPool struct {
+ *sync.Pool
+ }
+
+ lexemsPool struct {
+ *sync.Pool
+ }
+
+ stringsPool struct {
+ *sync.Pool
+ }
+)
+
+var (
+ // poolOfMatches holds temporary slices for recycling during the initialism match process
+ poolOfMatches = matchesPool{
+ Pool: &sync.Pool{
+ New: func() any {
+ s := make(initialismMatches, 0, maxAllocMatches)
+
+ return &s
+ },
+ },
+ }
+
+ poolOfBuffers = buffersPool{
+ Pool: &sync.Pool{
+ New: func() any {
+ return new(bytes.Buffer)
+ },
+ },
+ }
+
+ poolOfLexems = lexemsPool{
+ Pool: &sync.Pool{
+ New: func() any {
+ s := make([]nameLexem, 0, maxAllocMatches)
+
+ return &s
+ },
+ },
+ }
+
+ poolOfStrings = stringsPool{
+ Pool: &sync.Pool{
+ New: func() any {
+ s := make([]string, 0, maxAllocMatches)
+
+ return &s
+ },
+ },
+ }
+)
+
+func (p matchesPool) BorrowMatches() *initialismMatches {
+ s := p.Get().(*initialismMatches)
+ *s = (*s)[:0] // reset slice, keep allocated capacity
+
+ return s
+}
+
+func (p buffersPool) BorrowBuffer(size int) *bytes.Buffer {
+ s := p.Get().(*bytes.Buffer)
+ s.Reset()
+
+ if s.Cap() < size {
+ s.Grow(size)
+ }
+
+ return s
+}
+
+func (p lexemsPool) BorrowLexems() *[]nameLexem {
+ s := p.Get().(*[]nameLexem)
+ *s = (*s)[:0] // reset slice, keep allocated capacity
+
+ return s
+}
+
+func (p stringsPool) BorrowStrings() *[]string {
+ s := p.Get().(*[]string)
+ *s = (*s)[:0] // reset slice, keep allocated capacity
+
+ return s
+}
+
+func (p matchesPool) RedeemMatches(s *initialismMatches) {
+ p.Put(s)
+}
+
+func (p buffersPool) RedeemBuffer(s *bytes.Buffer) {
+ p.Put(s)
+}
+
+func (p lexemsPool) RedeemLexems(s *[]nameLexem) {
+ p.Put(s)
+}
+
+func (p stringsPool) RedeemStrings(s *[]string) {
+ p.Put(s)
+}
diff --git a/vendor/github.com/go-openapi/swag/mangling/split.go b/vendor/github.com/go-openapi/swag/mangling/split.go
new file mode 100644
index 0000000000..ed12ea2567
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/mangling/split.go
@@ -0,0 +1,341 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package mangling
+
+import (
+ "fmt"
+ "unicode"
+)
+
+type splitterOption func(*splitter)
+
+// withPostSplitInitialismCheck allows to catch initialisms after main split process
+func withPostSplitInitialismCheck(s *splitter) {
+ s.postSplitInitialismCheck = true
+}
+
+func withReplaceFunc(fn ReplaceFunc) func(*splitter) {
+ return func(s *splitter) {
+ s.replaceFunc = fn
+ }
+}
+
+func withInitialismsCache(c *initialismsCache) splitterOption {
+ return func(s *splitter) {
+ s.initialismsCache = c
+ }
+}
+
+type (
+ initialismMatch struct {
+ body []rune
+ start, end int
+ complete bool
+ hasPlural pluralForm
+ }
+ initialismMatches []initialismMatch
+)
+
+// String representation of a match, e.g. for debugging.
+func (m initialismMatch) String() string {
+ return fmt.Sprintf("{body: %s (%d), start: %d, end; %d, complete: %t, hasPlural: %v}",
+ string(m.body), len(m.body), m.start, m.end, m.complete, m.hasPlural,
+ )
+}
+
+func (m initialismMatch) isZero() bool {
+ return m.start == 0 && m.end == 0
+}
+
+type splitter struct {
+ *initialismsCache
+
+ postSplitInitialismCheck bool
+ replaceFunc ReplaceFunc
+}
+
+func newSplitter(options ...splitterOption) splitter {
+ var s splitter
+
+ for _, option := range options {
+ option(&s)
+ }
+
+ if s.replaceFunc == nil {
+ s.replaceFunc = defaultReplaceTable
+ }
+
+ return s
+}
+
+func (s splitter) split(name string) *[]nameLexem {
+ nameRunes := []rune(name)
+ matches := s.gatherInitialismMatches(nameRunes)
+ if matches == nil {
+ return poolOfLexems.BorrowLexems()
+ }
+
+ return s.mapMatchesToNameLexems(nameRunes, matches)
+}
+
+func (s splitter) gatherInitialismMatches(nameRunes []rune) *initialismMatches {
+ matches := poolOfMatches.BorrowMatches()
+ const minLenInitialism = 1
+ if len(nameRunes) < minLenInitialism+1 {
+ // can't match initialism with 0 or 1 rune
+ return matches
+ }
+
+ // first iteration
+ s.findMatches(matches, nameRunes, nameRunes[0], 0)
+
+ for i, currentRune := range nameRunes[1:] {
+ currentRunePosition := i + 1
+ // recycle allocations as we loop over runes
+ // with such recycling, only 2 slices should be allocated per call
+ // instead of o(n).
+ //
+ // BorrowMatches always yields slices with zero length (with some capacity)
+ newMatches := poolOfMatches.BorrowMatches()
+
+ // check current initialism matches
+ for _, match := range *matches {
+ if keepCompleteMatch := match.complete; keepCompleteMatch {
+ // the match is already complete: keep it then move on to the next match
+ *newMatches = append(*newMatches, match)
+ continue
+ }
+
+ if currentRunePosition-match.start == len(match.body) {
+ // unmatched: skip
+ continue
+ }
+
+ // 1. by construction of the matches, we can't have currentRunePosition - match.start < 0
+ // because matches have been computed with their start <= currentRunePosition in the previous
+ // iterations.
+ // 2. by construction of the matches, we can't have currentRunePosition - match.start >= len(match.body)
+
+ currentMatchRune := match.body[currentRunePosition-match.start]
+ if currentMatchRune != currentRune {
+ // failed match, discard it then move on to the next match
+ continue
+ }
+
+ // try to complete the current match
+ if currentRunePosition-match.start == len(match.body)-1 {
+ // we are close: the next step is to check the symbol ahead
+ // if it is a lowercase letter, then it is not the end of match
+ // but the beginning of the next word.
+ //
+ // NOTE(fredbi): this heuristic sometimes leads to counterintuitive splits and
+ // perhaps (not sure yet) we should check against case _alternance_.
+ //
+ // Example:
+ //
+ // In the current version, in the sentence "IDS initialism", "ID" is recognized as an initialism,
+ // leading to a split like "id_s_initialism" (or IDSInitialism),
+ // whereas in the sentence "IDx initialism", it is not and produces something like
+ // "i_d_x_initialism" (or IDxInitialism). The generated file name is not great.
+ //
+ // Both go identifiers are tolerated by linters.
+ //
+ // Notice that the slightly different input "IDs initialism" is correctly detected
+ // as a pluralized initialism and produces something like "ids_initialism" (or IDsInitialism).
+
+ if currentRunePosition < len(nameRunes)-1 { // when before the last rune
+ nextRune := nameRunes[currentRunePosition+1]
+
+ // recognize a plural form for this initialism (only simple english pluralization is supported).
+ if nextRune == 's' && match.hasPlural == simplePlural {
+ // detected a pluralized initialism
+ match.body = append(match.body, nextRune)
+ lookAhead := currentRunePosition + 1
+ if lookAhead < len(nameRunes)-1 {
+ nextRune = nameRunes[lookAhead+1]
+ if newWord := unicode.IsLower(nextRune); newWord {
+ // it is the start of a new word.
+ // Match is only partial and the initialism is not recognized:
+ // move on to the next match, but do not advance the rune position
+ continue
+ }
+ }
+
+ // this is a pluralized match: keep it
+ currentRunePosition++
+ match.complete = true
+ match.hasPlural = simplePlural
+ match.end = currentRunePosition
+ *newMatches = append(*newMatches, match)
+
+ // match is complete: keep it then move on to the next match
+ continue
+ }
+
+ // other cases
+ // example: invariant plural such as "TLS"
+ if newWord := unicode.IsLower(nextRune); newWord {
+ // it is the start of a new word
+ // Match is only partial and the initialism is not recognized : move on
+ continue
+ }
+ }
+
+ match.complete = true
+ match.end = currentRunePosition
+ }
+
+ // append the ongoing matching attempt: it is not necessarily complete, but was successful so far.
+ // Let's see if it still matches on the next rune.
+ *newMatches = append(*newMatches, match)
+ }
+
+ s.findMatches(newMatches, nameRunes, currentRune, currentRunePosition)
+
+ poolOfMatches.RedeemMatches(matches)
+ matches = newMatches
+ }
+
+ // it is up to the caller to redeem this last slice
+ return matches
+}
+
+func (s splitter) findMatches(newMatches *initialismMatches, nameRunes []rune, currentRune rune, currentRunePosition int) {
+ // check for new initialism matches, based on the first character
+ for i, r := range s.initialismsRunes {
+ if r[0] != currentRune {
+ continue
+ }
+
+ if currentRunePosition+len(r) > len(nameRunes) {
+ continue // not eligible: would spilll over the initial string
+ }
+
+ // possible matches: all initialisms starting with the current rune and that can fit the given string (nameRunes)
+ *newMatches = append(*newMatches, initialismMatch{
+ start: currentRunePosition,
+ body: r,
+ complete: false,
+ hasPlural: s.initialismsPluralForm[i],
+ })
+ }
+}
+
+func (s splitter) mapMatchesToNameLexems(nameRunes []rune, matches *initialismMatches) *[]nameLexem {
+ nameLexems := poolOfLexems.BorrowLexems()
+
+ var lastAcceptedMatch initialismMatch
+ for _, match := range *matches {
+ if !match.complete {
+ continue
+ }
+
+ if firstMatch := lastAcceptedMatch.isZero(); firstMatch {
+ s.appendBrokenDownCasualString(nameLexems, nameRunes[:match.start])
+ *nameLexems = append(*nameLexems, s.breakInitialism(string(match.body)))
+
+ lastAcceptedMatch = match
+
+ continue
+ }
+
+ if overlappedMatch := match.start <= lastAcceptedMatch.end; overlappedMatch {
+ continue
+ }
+
+ middle := nameRunes[lastAcceptedMatch.end+1 : match.start]
+ s.appendBrokenDownCasualString(nameLexems, middle)
+ *nameLexems = append(*nameLexems, s.breakInitialism(string(match.body)))
+
+ lastAcceptedMatch = match
+ }
+
+ // we have not found any accepted matches
+ if lastAcceptedMatch.isZero() {
+ *nameLexems = (*nameLexems)[:0]
+ s.appendBrokenDownCasualString(nameLexems, nameRunes)
+ } else if lastAcceptedMatch.end+1 != len(nameRunes) {
+ rest := nameRunes[lastAcceptedMatch.end+1:]
+ s.appendBrokenDownCasualString(nameLexems, rest)
+ }
+
+ poolOfMatches.RedeemMatches(matches)
+
+ return nameLexems
+}
+
+func (s splitter) breakInitialism(original string) nameLexem {
+ return newInitialismNameLexem(original, original)
+}
+
+func (s splitter) appendBrokenDownCasualString(segments *[]nameLexem, str []rune) {
+ currentSegment := poolOfBuffers.BorrowBuffer(len(str)) // unlike strings.Builder, bytes.Buffer initial storage can reused
+ defer func() {
+ poolOfBuffers.RedeemBuffer(currentSegment)
+ }()
+
+ addCasualNameLexem := func(original string) {
+ *segments = append(*segments, newCasualNameLexem(original))
+ }
+
+ addInitialismNameLexem := func(original, match string) {
+ *segments = append(*segments, newInitialismNameLexem(original, match))
+ }
+
+ var addNameLexem func(string)
+ if s.postSplitInitialismCheck {
+ addNameLexem = func(original string) {
+ for i := range s.initialisms {
+ if isEqualFoldIgnoreSpace(s.initialismsUpperCased[i], original) {
+ addInitialismNameLexem(original, s.initialisms[i])
+
+ return
+ }
+ }
+
+ addCasualNameLexem(original)
+ }
+ } else {
+ addNameLexem = addCasualNameLexem
+ }
+
+ // NOTE: (performance). The few remaining non-amortized allocations
+ // lay in the code below: using String() forces
+ for _, rn := range str {
+ if replace, found := s.replaceFunc(rn); found {
+ if currentSegment.Len() > 0 {
+ addNameLexem(currentSegment.String())
+ currentSegment.Reset()
+ }
+
+ if replace != "" {
+ addNameLexem(replace)
+ }
+
+ continue
+ }
+
+ if !unicode.In(rn, unicode.L, unicode.M, unicode.N, unicode.Pc) {
+ if currentSegment.Len() > 0 {
+ addNameLexem(currentSegment.String())
+ currentSegment.Reset()
+ }
+
+ continue
+ }
+
+ if unicode.IsUpper(rn) {
+ if currentSegment.Len() > 0 {
+ addNameLexem(currentSegment.String())
+ }
+ currentSegment.Reset()
+ }
+
+ currentSegment.WriteRune(rn)
+ }
+
+ if currentSegment.Len() > 0 {
+ addNameLexem(currentSegment.String())
+ }
+}
diff --git a/vendor/github.com/go-openapi/swag/mangling/string_bytes.go b/vendor/github.com/go-openapi/swag/mangling/string_bytes.go
new file mode 100644
index 0000000000..28daaf72b1
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/mangling/string_bytes.go
@@ -0,0 +1,11 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package mangling
+
+import "unsafe"
+
+// hackStringBytes returns the (unsafe) underlying bytes slice of a string.
+func hackStringBytes(str string) []byte {
+ return unsafe.Slice(unsafe.StringData(str), len(str))
+}
diff --git a/vendor/github.com/go-openapi/swag/mangling/util.go b/vendor/github.com/go-openapi/swag/mangling/util.go
new file mode 100644
index 0000000000..0636417e36
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/mangling/util.go
@@ -0,0 +1,118 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package mangling
+
+import (
+ "strings"
+ "unicode"
+ "unicode/utf8"
+)
+
+// Removes leading whitespaces
+func trim(str string) string { return strings.TrimSpace(str) }
+
+// upper is strings.ToUpper() combined with trim
+func upper(str string) string {
+ return strings.ToUpper(trim(str))
+}
+
+// lower is strings.ToLower() combined with trim
+func lower(str string) string {
+ return strings.ToLower(trim(str))
+}
+
+// isEqualFoldIgnoreSpace is the same as strings.EqualFold, but
+// it ignores leading and trailing blank spaces in the compared
+// string.
+//
+// base is assumed to be composed of upper-cased runes, and be already
+// trimmed.
+//
+// This code is heavily inspired from strings.EqualFold.
+func isEqualFoldIgnoreSpace(base []rune, str string) bool {
+ var i, baseIndex int
+ // equivalent to b := []byte(str), but without data copy
+ b := hackStringBytes(str)
+
+ for i < len(b) {
+ if c := b[i]; c < utf8.RuneSelf {
+ // fast path for ASCII
+ if c != ' ' && c != '\t' {
+ break
+ }
+ i++
+
+ continue
+ }
+
+ // unicode case
+ r, size := utf8.DecodeRune(b[i:])
+ if !unicode.IsSpace(r) {
+ break
+ }
+ i += size
+ }
+
+ if i >= len(b) {
+ return len(base) == 0
+ }
+
+ for _, baseRune := range base {
+ if i >= len(b) {
+ break
+ }
+
+ if c := b[i]; c < utf8.RuneSelf {
+ // single byte rune case (ASCII)
+ if baseRune >= utf8.RuneSelf {
+ return false
+ }
+
+ baseChar := byte(baseRune)
+ if c != baseChar && ((c < 'a') || (c > 'z') || (c-'a'+'A' != baseChar)) {
+ return false
+ }
+
+ baseIndex++
+ i++
+
+ continue
+ }
+
+ // unicode case
+ r, size := utf8.DecodeRune(b[i:])
+ if unicode.ToUpper(r) != baseRune {
+ return false
+ }
+ baseIndex++
+ i += size
+ }
+
+ if baseIndex != len(base) {
+ return false
+ }
+
+ // all passed: now we should only have blanks
+ for i < len(b) {
+ if c := b[i]; c < utf8.RuneSelf {
+ // fast path for ASCII
+ if c != ' ' && c != '\t' {
+ return false
+ }
+ i++
+
+ continue
+ }
+
+ // unicode case
+ r, size := utf8.DecodeRune(b[i:])
+ if !unicode.IsSpace(r) {
+ return false
+ }
+
+ i += size
+ }
+
+ return true
+}
diff --git a/vendor/github.com/go-openapi/swag/mangling_iface.go b/vendor/github.com/go-openapi/swag/mangling_iface.go
new file mode 100644
index 0000000000..98b9a99929
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/mangling_iface.go
@@ -0,0 +1,69 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package swag
+
+import "github.com/go-openapi/swag/mangling"
+
+// GoNamePrefixFunc sets an optional rule to prefix go names
+// which do not start with a letter.
+//
+// GoNamePrefixFunc should not be written to while concurrently using the other mangling functions of this package.
+//
+// Deprecated: use [mangling.WithGoNamePrefixFunc] instead.
+var GoNamePrefixFunc mangling.PrefixFunc
+
+// swagNameMangler is a global instance of the name mangler specifically alloted
+// to support deprecated functions.
+var swagNameMangler = mangling.NewNameMangler(
+ mangling.WithGoNamePrefixFuncPtr(&GoNamePrefixFunc),
+)
+
+// AddInitialisms adds additional initialisms to the default list (see [mangling.DefaultInitialisms]).
+//
+// AddInitialisms is not safe to be called concurrently.
+//
+// Deprecated: use [mangling.WithAdditionalInitialisms] instead.
+func AddInitialisms(words ...string) {
+ swagNameMangler.AddInitialisms(words...)
+}
+
+// Camelize a single word.
+//
+// Deprecated: use [mangling.NameMangler.Camelize] instead.
+func Camelize(word string) string { return swagNameMangler.Camelize(word) }
+
+// ToFileName lowercases and underscores a go type name.
+//
+// Deprecated: use [mangling.NameMangler.ToFileName] instead.
+func ToFileName(name string) string { return swagNameMangler.ToFileName(name) }
+
+// ToCommandName lowercases and underscores a go type name.
+//
+// Deprecated: use [mangling.NameMangler.ToCommandName] instead.
+func ToCommandName(name string) string { return swagNameMangler.ToCommandName(name) }
+
+// ToHumanNameLower represents a code name as a human series of words.
+//
+// Deprecated: use [mangling.NameMangler.ToHumanNameLower] instead.
+func ToHumanNameLower(name string) string { return swagNameMangler.ToHumanNameLower(name) }
+
+// ToHumanNameTitle represents a code name as a human series of words with the first letters titleized.
+//
+// Deprecated: use [mangling.NameMangler.ToHumanNameTitle] instead.
+func ToHumanNameTitle(name string) string { return swagNameMangler.ToHumanNameTitle(name) }
+
+// ToJSONName camel-cases a name which can be underscored or pascal-cased.
+//
+// Deprecated: use [mangling.NameMangler.ToJSONName] instead.
+func ToJSONName(name string) string { return swagNameMangler.ToJSONName(name) }
+
+// ToVarName camel-cases a name which can be underscored or pascal-cased.
+//
+// Deprecated: use [mangling.NameMangler.ToVarName] instead.
+func ToVarName(name string) string { return swagNameMangler.ToVarName(name) }
+
+// ToGoName translates a swagger name which can be underscored or camel cased to a name that golint likes.
+//
+// Deprecated: use [mangling.NameMangler.ToGoName] instead.
+func ToGoName(name string) string { return swagNameMangler.ToGoName(name) }
diff --git a/vendor/github.com/go-openapi/swag/name_lexem.go b/vendor/github.com/go-openapi/swag/name_lexem.go
deleted file mode 100644
index 8bb64ac32f..0000000000
--- a/vendor/github.com/go-openapi/swag/name_lexem.go
+++ /dev/null
@@ -1,93 +0,0 @@
-// Copyright 2015 go-swagger maintainers
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-package swag
-
-import (
- "unicode"
- "unicode/utf8"
-)
-
-type (
- lexemKind uint8
-
- nameLexem struct {
- original string
- matchedInitialism string
- kind lexemKind
- }
-)
-
-const (
- lexemKindCasualName lexemKind = iota
- lexemKindInitialismName
-)
-
-func newInitialismNameLexem(original, matchedInitialism string) nameLexem {
- return nameLexem{
- kind: lexemKindInitialismName,
- original: original,
- matchedInitialism: matchedInitialism,
- }
-}
-
-func newCasualNameLexem(original string) nameLexem {
- return nameLexem{
- kind: lexemKindCasualName,
- original: original,
- }
-}
-
-func (l nameLexem) GetUnsafeGoName() string {
- if l.kind == lexemKindInitialismName {
- return l.matchedInitialism
- }
-
- var (
- first rune
- rest string
- )
-
- for i, orig := range l.original {
- if i == 0 {
- first = orig
- continue
- }
-
- if i > 0 {
- rest = l.original[i:]
- break
- }
- }
-
- if len(l.original) > 1 {
- b := poolOfBuffers.BorrowBuffer(utf8.UTFMax + len(rest))
- defer func() {
- poolOfBuffers.RedeemBuffer(b)
- }()
- b.WriteRune(unicode.ToUpper(first))
- b.WriteString(lower(rest))
- return b.String()
- }
-
- return l.original
-}
-
-func (l nameLexem) GetOriginal() string {
- return l.original
-}
-
-func (l nameLexem) IsInitialism() bool {
- return l.kind == lexemKindInitialismName
-}
diff --git a/vendor/github.com/go-openapi/swag/net.go b/vendor/github.com/go-openapi/swag/net.go
deleted file mode 100644
index 821235f84d..0000000000
--- a/vendor/github.com/go-openapi/swag/net.go
+++ /dev/null
@@ -1,38 +0,0 @@
-// Copyright 2015 go-swagger maintainers
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-package swag
-
-import (
- "net"
- "strconv"
-)
-
-// SplitHostPort splits a network address into a host and a port.
-// The port is -1 when there is no port to be found
-func SplitHostPort(addr string) (host string, port int, err error) {
- h, p, err := net.SplitHostPort(addr)
- if err != nil {
- return "", -1, err
- }
- if p == "" {
- return "", -1, &net.AddrError{Err: "missing port in address", Addr: addr}
- }
-
- pi, err := strconv.Atoi(p)
- if err != nil {
- return "", -1, err
- }
- return h, pi, nil
-}
diff --git a/vendor/github.com/go-openapi/swag/netutils/LICENSE b/vendor/github.com/go-openapi/swag/netutils/LICENSE
new file mode 100644
index 0000000000..d645695673
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/netutils/LICENSE
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/vendor/github.com/go-openapi/swag/netutils/doc.go b/vendor/github.com/go-openapi/swag/netutils/doc.go
new file mode 100644
index 0000000000..74282f8e51
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/netutils/doc.go
@@ -0,0 +1,5 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+// Package netutils provides helpers for network-related tasks.
+package netutils
diff --git a/vendor/github.com/go-openapi/swag/netutils/net.go b/vendor/github.com/go-openapi/swag/netutils/net.go
new file mode 100644
index 0000000000..82a1544af7
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/netutils/net.go
@@ -0,0 +1,31 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package netutils
+
+import (
+ "net"
+ "strconv"
+)
+
+// SplitHostPort splits a network address into a host and a port.
+//
+// The difference with the standard net.SplitHostPort is that the port is converted to an int.
+//
+// The port is -1 when there is no port to be found.
+func SplitHostPort(addr string) (host string, port int, err error) {
+ h, p, err := net.SplitHostPort(addr)
+ if err != nil {
+ return "", -1, err
+ }
+ if p == "" {
+ return "", -1, &net.AddrError{Err: "missing port in address", Addr: addr}
+ }
+
+ pi, err := strconv.Atoi(p)
+ if err != nil {
+ return "", -1, err
+ }
+
+ return h, pi, nil
+}
diff --git a/vendor/github.com/go-openapi/swag/netutils_iface.go b/vendor/github.com/go-openapi/swag/netutils_iface.go
new file mode 100644
index 0000000000..d658de25b3
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/netutils_iface.go
@@ -0,0 +1,13 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package swag
+
+import "github.com/go-openapi/swag/netutils"
+
+// SplitHostPort splits a network address into a host and a port.
+//
+// Deprecated: use [netutils.SplitHostPort] instead.
+func SplitHostPort(addr string) (host string, port int, err error) {
+ return netutils.SplitHostPort(addr)
+}
diff --git a/vendor/github.com/go-openapi/swag/path.go b/vendor/github.com/go-openapi/swag/path.go
deleted file mode 100644
index 941bd0176b..0000000000
--- a/vendor/github.com/go-openapi/swag/path.go
+++ /dev/null
@@ -1,59 +0,0 @@
-// Copyright 2015 go-swagger maintainers
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-package swag
-
-import (
- "os"
- "path/filepath"
- "runtime"
- "strings"
-)
-
-const (
- // GOPATHKey represents the env key for gopath
- GOPATHKey = "GOPATH"
-)
-
-// FindInSearchPath finds a package in a provided lists of paths
-func FindInSearchPath(searchPath, pkg string) string {
- pathsList := filepath.SplitList(searchPath)
- for _, path := range pathsList {
- if evaluatedPath, err := filepath.EvalSymlinks(filepath.Join(path, "src", pkg)); err == nil {
- if _, err := os.Stat(evaluatedPath); err == nil {
- return evaluatedPath
- }
- }
- }
- return ""
-}
-
-// FindInGoSearchPath finds a package in the $GOPATH:$GOROOT
-func FindInGoSearchPath(pkg string) string {
- return FindInSearchPath(FullGoSearchPath(), pkg)
-}
-
-// FullGoSearchPath gets the search paths for finding packages
-func FullGoSearchPath() string {
- allPaths := os.Getenv(GOPATHKey)
- if allPaths == "" {
- allPaths = filepath.Join(os.Getenv("HOME"), "go")
- }
- if allPaths != "" {
- allPaths = strings.Join([]string{allPaths, runtime.GOROOT()}, ":")
- } else {
- allPaths = runtime.GOROOT()
- }
- return allPaths
-}
diff --git a/vendor/github.com/go-openapi/swag/split.go b/vendor/github.com/go-openapi/swag/split.go
deleted file mode 100644
index 274727a866..0000000000
--- a/vendor/github.com/go-openapi/swag/split.go
+++ /dev/null
@@ -1,508 +0,0 @@
-// Copyright 2015 go-swagger maintainers
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-package swag
-
-import (
- "bytes"
- "sync"
- "unicode"
- "unicode/utf8"
-)
-
-type (
- splitter struct {
- initialisms []string
- initialismsRunes [][]rune
- initialismsUpperCased [][]rune // initialisms cached in their trimmed, upper-cased version
- postSplitInitialismCheck bool
- }
-
- splitterOption func(*splitter)
-
- initialismMatch struct {
- body []rune
- start, end int
- complete bool
- }
- initialismMatches []initialismMatch
-)
-
-type (
- // memory pools of temporary objects.
- //
- // These are used to recycle temporarily allocated objects
- // and relieve the GC from undue pressure.
-
- matchesPool struct {
- *sync.Pool
- }
-
- buffersPool struct {
- *sync.Pool
- }
-
- lexemsPool struct {
- *sync.Pool
- }
-
- splittersPool struct {
- *sync.Pool
- }
-)
-
-var (
- // poolOfMatches holds temporary slices for recycling during the initialism match process
- poolOfMatches = matchesPool{
- Pool: &sync.Pool{
- New: func() any {
- s := make(initialismMatches, 0, maxAllocMatches)
-
- return &s
- },
- },
- }
-
- poolOfBuffers = buffersPool{
- Pool: &sync.Pool{
- New: func() any {
- return new(bytes.Buffer)
- },
- },
- }
-
- poolOfLexems = lexemsPool{
- Pool: &sync.Pool{
- New: func() any {
- s := make([]nameLexem, 0, maxAllocMatches)
-
- return &s
- },
- },
- }
-
- poolOfSplitters = splittersPool{
- Pool: &sync.Pool{
- New: func() any {
- s := newSplitter()
-
- return &s
- },
- },
- }
-)
-
-// nameReplaceTable finds a word representation for special characters.
-func nameReplaceTable(r rune) (string, bool) {
- switch r {
- case '@':
- return "At ", true
- case '&':
- return "And ", true
- case '|':
- return "Pipe ", true
- case '$':
- return "Dollar ", true
- case '!':
- return "Bang ", true
- case '-':
- return "", true
- case '_':
- return "", true
- default:
- return "", false
- }
-}
-
-// split calls the splitter.
-//
-// Use newSplitter for more control and options
-func split(str string) []string {
- s := poolOfSplitters.BorrowSplitter()
- lexems := s.split(str)
- result := make([]string, 0, len(*lexems))
-
- for _, lexem := range *lexems {
- result = append(result, lexem.GetOriginal())
- }
- poolOfLexems.RedeemLexems(lexems)
- poolOfSplitters.RedeemSplitter(s)
-
- return result
-
-}
-
-func newSplitter(options ...splitterOption) splitter {
- s := splitter{
- postSplitInitialismCheck: false,
- initialisms: initialisms,
- initialismsRunes: initialismsRunes,
- initialismsUpperCased: initialismsUpperCased,
- }
-
- for _, option := range options {
- option(&s)
- }
-
- return s
-}
-
-// withPostSplitInitialismCheck allows to catch initialisms after main split process
-func withPostSplitInitialismCheck(s *splitter) {
- s.postSplitInitialismCheck = true
-}
-
-func (p matchesPool) BorrowMatches() *initialismMatches {
- s := p.Get().(*initialismMatches)
- *s = (*s)[:0] // reset slice, keep allocated capacity
-
- return s
-}
-
-func (p buffersPool) BorrowBuffer(size int) *bytes.Buffer {
- s := p.Get().(*bytes.Buffer)
- s.Reset()
-
- if s.Cap() < size {
- s.Grow(size)
- }
-
- return s
-}
-
-func (p lexemsPool) BorrowLexems() *[]nameLexem {
- s := p.Get().(*[]nameLexem)
- *s = (*s)[:0] // reset slice, keep allocated capacity
-
- return s
-}
-
-func (p splittersPool) BorrowSplitter(options ...splitterOption) *splitter {
- s := p.Get().(*splitter)
- s.postSplitInitialismCheck = false // reset options
- for _, apply := range options {
- apply(s)
- }
-
- return s
-}
-
-func (p matchesPool) RedeemMatches(s *initialismMatches) {
- p.Put(s)
-}
-
-func (p buffersPool) RedeemBuffer(s *bytes.Buffer) {
- p.Put(s)
-}
-
-func (p lexemsPool) RedeemLexems(s *[]nameLexem) {
- p.Put(s)
-}
-
-func (p splittersPool) RedeemSplitter(s *splitter) {
- p.Put(s)
-}
-
-func (m initialismMatch) isZero() bool {
- return m.start == 0 && m.end == 0
-}
-
-func (s splitter) split(name string) *[]nameLexem {
- nameRunes := []rune(name)
- matches := s.gatherInitialismMatches(nameRunes)
- if matches == nil {
- return poolOfLexems.BorrowLexems()
- }
-
- return s.mapMatchesToNameLexems(nameRunes, matches)
-}
-
-func (s splitter) gatherInitialismMatches(nameRunes []rune) *initialismMatches {
- var matches *initialismMatches
-
- for currentRunePosition, currentRune := range nameRunes {
- // recycle these allocations as we loop over runes
- // with such recycling, only 2 slices should be allocated per call
- // instead of o(n).
- newMatches := poolOfMatches.BorrowMatches()
-
- // check current initialism matches
- if matches != nil { // skip first iteration
- for _, match := range *matches {
- if keepCompleteMatch := match.complete; keepCompleteMatch {
- *newMatches = append(*newMatches, match)
- continue
- }
-
- // drop failed match
- currentMatchRune := match.body[currentRunePosition-match.start]
- if currentMatchRune != currentRune {
- continue
- }
-
- // try to complete ongoing match
- if currentRunePosition-match.start == len(match.body)-1 {
- // we are close; the next step is to check the symbol ahead
- // if it is a small letter, then it is not the end of match
- // but beginning of the next word
-
- if currentRunePosition < len(nameRunes)-1 {
- nextRune := nameRunes[currentRunePosition+1]
- if newWord := unicode.IsLower(nextRune); newWord {
- // oh ok, it was the start of a new word
- continue
- }
- }
-
- match.complete = true
- match.end = currentRunePosition
- }
-
- *newMatches = append(*newMatches, match)
- }
- }
-
- // check for new initialism matches
- for i := range s.initialisms {
- initialismRunes := s.initialismsRunes[i]
- if initialismRunes[0] == currentRune {
- *newMatches = append(*newMatches, initialismMatch{
- start: currentRunePosition,
- body: initialismRunes,
- complete: false,
- })
- }
- }
-
- if matches != nil {
- poolOfMatches.RedeemMatches(matches)
- }
- matches = newMatches
- }
-
- // up to the caller to redeem this last slice
- return matches
-}
-
-func (s splitter) mapMatchesToNameLexems(nameRunes []rune, matches *initialismMatches) *[]nameLexem {
- nameLexems := poolOfLexems.BorrowLexems()
-
- var lastAcceptedMatch initialismMatch
- for _, match := range *matches {
- if !match.complete {
- continue
- }
-
- if firstMatch := lastAcceptedMatch.isZero(); firstMatch {
- s.appendBrokenDownCasualString(nameLexems, nameRunes[:match.start])
- *nameLexems = append(*nameLexems, s.breakInitialism(string(match.body)))
-
- lastAcceptedMatch = match
-
- continue
- }
-
- if overlappedMatch := match.start <= lastAcceptedMatch.end; overlappedMatch {
- continue
- }
-
- middle := nameRunes[lastAcceptedMatch.end+1 : match.start]
- s.appendBrokenDownCasualString(nameLexems, middle)
- *nameLexems = append(*nameLexems, s.breakInitialism(string(match.body)))
-
- lastAcceptedMatch = match
- }
-
- // we have not found any accepted matches
- if lastAcceptedMatch.isZero() {
- *nameLexems = (*nameLexems)[:0]
- s.appendBrokenDownCasualString(nameLexems, nameRunes)
- } else if lastAcceptedMatch.end+1 != len(nameRunes) {
- rest := nameRunes[lastAcceptedMatch.end+1:]
- s.appendBrokenDownCasualString(nameLexems, rest)
- }
-
- poolOfMatches.RedeemMatches(matches)
-
- return nameLexems
-}
-
-func (s splitter) breakInitialism(original string) nameLexem {
- return newInitialismNameLexem(original, original)
-}
-
-func (s splitter) appendBrokenDownCasualString(segments *[]nameLexem, str []rune) {
- currentSegment := poolOfBuffers.BorrowBuffer(len(str)) // unlike strings.Builder, bytes.Buffer initial storage can reused
- defer func() {
- poolOfBuffers.RedeemBuffer(currentSegment)
- }()
-
- addCasualNameLexem := func(original string) {
- *segments = append(*segments, newCasualNameLexem(original))
- }
-
- addInitialismNameLexem := func(original, match string) {
- *segments = append(*segments, newInitialismNameLexem(original, match))
- }
-
- var addNameLexem func(string)
- if s.postSplitInitialismCheck {
- addNameLexem = func(original string) {
- for i := range s.initialisms {
- if isEqualFoldIgnoreSpace(s.initialismsUpperCased[i], original) {
- addInitialismNameLexem(original, s.initialisms[i])
-
- return
- }
- }
-
- addCasualNameLexem(original)
- }
- } else {
- addNameLexem = addCasualNameLexem
- }
-
- for _, rn := range str {
- if replace, found := nameReplaceTable(rn); found {
- if currentSegment.Len() > 0 {
- addNameLexem(currentSegment.String())
- currentSegment.Reset()
- }
-
- if replace != "" {
- addNameLexem(replace)
- }
-
- continue
- }
-
- if !unicode.In(rn, unicode.L, unicode.M, unicode.N, unicode.Pc) {
- if currentSegment.Len() > 0 {
- addNameLexem(currentSegment.String())
- currentSegment.Reset()
- }
-
- continue
- }
-
- if unicode.IsUpper(rn) {
- if currentSegment.Len() > 0 {
- addNameLexem(currentSegment.String())
- }
- currentSegment.Reset()
- }
-
- currentSegment.WriteRune(rn)
- }
-
- if currentSegment.Len() > 0 {
- addNameLexem(currentSegment.String())
- }
-}
-
-// isEqualFoldIgnoreSpace is the same as strings.EqualFold, but
-// it ignores leading and trailing blank spaces in the compared
-// string.
-//
-// base is assumed to be composed of upper-cased runes, and be already
-// trimmed.
-//
-// This code is heavily inspired from strings.EqualFold.
-func isEqualFoldIgnoreSpace(base []rune, str string) bool {
- var i, baseIndex int
- // equivalent to b := []byte(str), but without data copy
- b := hackStringBytes(str)
-
- for i < len(b) {
- if c := b[i]; c < utf8.RuneSelf {
- // fast path for ASCII
- if c != ' ' && c != '\t' {
- break
- }
- i++
-
- continue
- }
-
- // unicode case
- r, size := utf8.DecodeRune(b[i:])
- if !unicode.IsSpace(r) {
- break
- }
- i += size
- }
-
- if i >= len(b) {
- return len(base) == 0
- }
-
- for _, baseRune := range base {
- if i >= len(b) {
- break
- }
-
- if c := b[i]; c < utf8.RuneSelf {
- // single byte rune case (ASCII)
- if baseRune >= utf8.RuneSelf {
- return false
- }
-
- baseChar := byte(baseRune)
- if c != baseChar &&
- !('a' <= c && c <= 'z' && c-'a'+'A' == baseChar) {
- return false
- }
-
- baseIndex++
- i++
-
- continue
- }
-
- // unicode case
- r, size := utf8.DecodeRune(b[i:])
- if unicode.ToUpper(r) != baseRune {
- return false
- }
- baseIndex++
- i += size
- }
-
- if baseIndex != len(base) {
- return false
- }
-
- // all passed: now we should only have blanks
- for i < len(b) {
- if c := b[i]; c < utf8.RuneSelf {
- // fast path for ASCII
- if c != ' ' && c != '\t' {
- return false
- }
- i++
-
- continue
- }
-
- // unicode case
- r, size := utf8.DecodeRune(b[i:])
- if !unicode.IsSpace(r) {
- return false
- }
-
- i += size
- }
-
- return true
-}
diff --git a/vendor/github.com/go-openapi/swag/string_bytes.go b/vendor/github.com/go-openapi/swag/string_bytes.go
deleted file mode 100644
index 90745d5ca9..0000000000
--- a/vendor/github.com/go-openapi/swag/string_bytes.go
+++ /dev/null
@@ -1,8 +0,0 @@
-package swag
-
-import "unsafe"
-
-// hackStringBytes returns the (unsafe) underlying bytes slice of a string.
-func hackStringBytes(str string) []byte {
- return unsafe.Slice(unsafe.StringData(str), len(str))
-}
diff --git a/vendor/github.com/go-openapi/swag/stringutils/LICENSE b/vendor/github.com/go-openapi/swag/stringutils/LICENSE
new file mode 100644
index 0000000000..d645695673
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/stringutils/LICENSE
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/vendor/github.com/go-openapi/swag/stringutils/collection_formats.go b/vendor/github.com/go-openapi/swag/stringutils/collection_formats.go
new file mode 100644
index 0000000000..28056ad25c
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/stringutils/collection_formats.go
@@ -0,0 +1,74 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package stringutils
+
+import "strings"
+
+const (
+ // collectionFormatComma = "csv"
+ collectionFormatSpace = "ssv"
+ collectionFormatTab = "tsv"
+ collectionFormatPipe = "pipes"
+ collectionFormatMulti = "multi"
+
+ collectionFormatDefaultSep = ","
+)
+
+// JoinByFormat joins a string array by a known format (e.g. swagger's collectionFormat attribute):
+//
+// ssv: space separated value
+// tsv: tab separated value
+// pipes: pipe (|) separated value
+// csv: comma separated value (default)
+func JoinByFormat(data []string, format string) []string {
+ if len(data) == 0 {
+ return data
+ }
+ var sep string
+ switch format {
+ case collectionFormatSpace:
+ sep = " "
+ case collectionFormatTab:
+ sep = "\t"
+ case collectionFormatPipe:
+ sep = "|"
+ case collectionFormatMulti:
+ return data
+ default:
+ sep = collectionFormatDefaultSep
+ }
+ return []string{strings.Join(data, sep)}
+}
+
+// SplitByFormat splits a string by a known format:
+//
+// ssv: space separated value
+// tsv: tab separated value
+// pipes: pipe (|) separated value
+// csv: comma separated value (default)
+func SplitByFormat(data, format string) []string {
+ if data == "" {
+ return nil
+ }
+ var sep string
+ switch format {
+ case collectionFormatSpace:
+ sep = " "
+ case collectionFormatTab:
+ sep = "\t"
+ case collectionFormatPipe:
+ sep = "|"
+ case collectionFormatMulti:
+ return nil
+ default:
+ sep = collectionFormatDefaultSep
+ }
+ var result []string
+ for _, s := range strings.Split(data, sep) {
+ if ts := strings.TrimSpace(s); ts != "" {
+ result = append(result, ts)
+ }
+ }
+ return result
+}
diff --git a/vendor/github.com/go-openapi/swag/stringutils/doc.go b/vendor/github.com/go-openapi/swag/stringutils/doc.go
new file mode 100644
index 0000000000..c6d17a1160
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/stringutils/doc.go
@@ -0,0 +1,5 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+// Package stringutils exposes helpers to search and process strings.
+package stringutils
diff --git a/vendor/github.com/go-openapi/swag/stringutils/strings.go b/vendor/github.com/go-openapi/swag/stringutils/strings.go
new file mode 100644
index 0000000000..cd792b7d08
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/stringutils/strings.go
@@ -0,0 +1,23 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package stringutils
+
+import (
+ "slices"
+ "strings"
+)
+
+// ContainsStrings searches a slice of strings for a case-sensitive match
+//
+// Now equivalent to the standard library [slice.Contains].
+func ContainsStrings(coll []string, item string) bool {
+ return slices.Contains(coll, item)
+}
+
+// ContainsStringsCI searches a slice of strings for a case-insensitive match
+func ContainsStringsCI(coll []string, item string) bool {
+ return slices.ContainsFunc(coll, func(e string) bool {
+ return strings.EqualFold(e, item)
+ })
+}
diff --git a/vendor/github.com/go-openapi/swag/stringutils_iface.go b/vendor/github.com/go-openapi/swag/stringutils_iface.go
new file mode 100644
index 0000000000..dbfa484843
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/stringutils_iface.go
@@ -0,0 +1,34 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package swag
+
+import "github.com/go-openapi/swag/stringutils"
+
+// ContainsStrings searches a slice of strings for a case-sensitive match.
+//
+// Deprecated: use [slices.Contains] or [stringutils.ContainsStrings] instead.
+func ContainsStrings(coll []string, item string) bool {
+ return stringutils.ContainsStrings(coll, item)
+}
+
+// ContainsStringsCI searches a slice of strings for a case-insensitive match.
+//
+// Deprecated: use [stringutils.ContainsStringsCI] instead.
+func ContainsStringsCI(coll []string, item string) bool {
+ return stringutils.ContainsStringsCI(coll, item)
+}
+
+// JoinByFormat joins a string array by a known format (e.g. swagger's collectionFormat attribute).
+//
+// Deprecated: use [stringutils.JoinByFormat] instead.
+func JoinByFormat(data []string, format string) []string {
+ return stringutils.JoinByFormat(data, format)
+}
+
+// SplitByFormat splits a string by a known format.
+//
+// Deprecated: use [stringutils.SplitByFormat] instead.
+func SplitByFormat(data, format string) []string {
+ return stringutils.SplitByFormat(data, format)
+}
diff --git a/vendor/github.com/go-openapi/swag/typeutils/LICENSE b/vendor/github.com/go-openapi/swag/typeutils/LICENSE
new file mode 100644
index 0000000000..d645695673
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/typeutils/LICENSE
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/vendor/github.com/go-openapi/swag/typeutils/doc.go b/vendor/github.com/go-openapi/swag/typeutils/doc.go
new file mode 100644
index 0000000000..66bed20dff
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/typeutils/doc.go
@@ -0,0 +1,5 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+// Package typeutils exposes utilities to inspect generic types.
+package typeutils
diff --git a/vendor/github.com/go-openapi/swag/typeutils/types.go b/vendor/github.com/go-openapi/swag/typeutils/types.go
new file mode 100644
index 0000000000..55487a673c
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/typeutils/types.go
@@ -0,0 +1,80 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package typeutils
+
+import "reflect"
+
+type zeroable interface {
+ IsZero() bool
+}
+
+// IsZero returns true when the value passed into the function is a zero value.
+// This allows for safer checking of interface values.
+func IsZero(data any) bool {
+ v := reflect.ValueOf(data)
+ // check for nil data
+ switch v.Kind() { //nolint:exhaustive
+ case
+ reflect.Interface,
+ reflect.Func,
+ reflect.Chan,
+ reflect.Pointer,
+ reflect.UnsafePointer,
+ reflect.Map,
+ reflect.Slice:
+ if v.IsNil() {
+ return true
+ }
+ }
+
+ // check for things that have an IsZero method instead
+ if vv, ok := data.(zeroable); ok {
+ return vv.IsZero()
+ }
+
+ // continue with slightly more complex reflection
+ switch v.Kind() { //nolint:exhaustive
+ case reflect.String:
+ return v.Len() == 0
+ case reflect.Bool:
+ return !v.Bool()
+ case reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64:
+ return v.Int() == 0
+ case reflect.Uint, reflect.Uint8, reflect.Uint16, reflect.Uint32, reflect.Uint64, reflect.Uintptr:
+ return v.Uint() == 0
+ case reflect.Float32, reflect.Float64:
+ return v.Float() == 0
+ case reflect.Struct, reflect.Array:
+ return reflect.DeepEqual(data, reflect.Zero(v.Type()).Interface())
+ case reflect.Invalid:
+ return true
+ default:
+ return false
+ }
+}
+
+// IsNil checks if input is nil.
+//
+// For types chan, func, interface, map, pointer, or slice it returns true if its argument is nil.
+//
+// See [reflect.Value.IsNil].
+func IsNil(input any) bool {
+ if input == nil {
+ return true
+ }
+
+ kind := reflect.TypeOf(input).Kind()
+ switch kind { //nolint:exhaustive
+ case reflect.Pointer,
+ reflect.UnsafePointer,
+ reflect.Map,
+ reflect.Slice,
+ reflect.Chan,
+ reflect.Interface,
+ reflect.Func:
+ return reflect.ValueOf(input).IsNil()
+ default:
+ return false
+ }
+}
diff --git a/vendor/github.com/go-openapi/swag/typeutils_iface.go b/vendor/github.com/go-openapi/swag/typeutils_iface.go
new file mode 100644
index 0000000000..b63813ea40
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/typeutils_iface.go
@@ -0,0 +1,12 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package swag
+
+import "github.com/go-openapi/swag/typeutils"
+
+// IsZero returns true when the value passed into the function is a zero value.
+// This allows for safer checking of interface values.
+//
+// Deprecated: use [typeutils.IsZero] instead.
+func IsZero(data any) bool { return typeutils.IsZero(data) }
diff --git a/vendor/github.com/go-openapi/swag/util.go b/vendor/github.com/go-openapi/swag/util.go
deleted file mode 100644
index 5051401c49..0000000000
--- a/vendor/github.com/go-openapi/swag/util.go
+++ /dev/null
@@ -1,364 +0,0 @@
-// Copyright 2015 go-swagger maintainers
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-package swag
-
-import (
- "reflect"
- "strings"
- "unicode"
- "unicode/utf8"
-)
-
-// GoNamePrefixFunc sets an optional rule to prefix go names
-// which do not start with a letter.
-//
-// The prefix function is assumed to return a string that starts with an upper case letter.
-//
-// e.g. to help convert "123" into "{prefix}123"
-//
-// The default is to prefix with "X"
-var GoNamePrefixFunc func(string) string
-
-func prefixFunc(name, in string) string {
- if GoNamePrefixFunc == nil {
- return "X" + in
- }
-
- return GoNamePrefixFunc(name) + in
-}
-
-const (
- // collectionFormatComma = "csv"
- collectionFormatSpace = "ssv"
- collectionFormatTab = "tsv"
- collectionFormatPipe = "pipes"
- collectionFormatMulti = "multi"
-)
-
-// JoinByFormat joins a string array by a known format (e.g. swagger's collectionFormat attribute):
-//
-// ssv: space separated value
-// tsv: tab separated value
-// pipes: pipe (|) separated value
-// csv: comma separated value (default)
-func JoinByFormat(data []string, format string) []string {
- if len(data) == 0 {
- return data
- }
- var sep string
- switch format {
- case collectionFormatSpace:
- sep = " "
- case collectionFormatTab:
- sep = "\t"
- case collectionFormatPipe:
- sep = "|"
- case collectionFormatMulti:
- return data
- default:
- sep = ","
- }
- return []string{strings.Join(data, sep)}
-}
-
-// SplitByFormat splits a string by a known format:
-//
-// ssv: space separated value
-// tsv: tab separated value
-// pipes: pipe (|) separated value
-// csv: comma separated value (default)
-func SplitByFormat(data, format string) []string {
- if data == "" {
- return nil
- }
- var sep string
- switch format {
- case collectionFormatSpace:
- sep = " "
- case collectionFormatTab:
- sep = "\t"
- case collectionFormatPipe:
- sep = "|"
- case collectionFormatMulti:
- return nil
- default:
- sep = ","
- }
- var result []string
- for _, s := range strings.Split(data, sep) {
- if ts := strings.TrimSpace(s); ts != "" {
- result = append(result, ts)
- }
- }
- return result
-}
-
-// Removes leading whitespaces
-func trim(str string) string {
- return strings.TrimSpace(str)
-}
-
-// Shortcut to strings.ToUpper()
-func upper(str string) string {
- return strings.ToUpper(trim(str))
-}
-
-// Shortcut to strings.ToLower()
-func lower(str string) string {
- return strings.ToLower(trim(str))
-}
-
-// Camelize an uppercased word
-func Camelize(word string) string {
- camelized := poolOfBuffers.BorrowBuffer(len(word))
- defer func() {
- poolOfBuffers.RedeemBuffer(camelized)
- }()
-
- for pos, ru := range []rune(word) {
- if pos > 0 {
- camelized.WriteRune(unicode.ToLower(ru))
- } else {
- camelized.WriteRune(unicode.ToUpper(ru))
- }
- }
- return camelized.String()
-}
-
-// ToFileName lowercases and underscores a go type name
-func ToFileName(name string) string {
- in := split(name)
- out := make([]string, 0, len(in))
-
- for _, w := range in {
- out = append(out, lower(w))
- }
-
- return strings.Join(out, "_")
-}
-
-// ToCommandName lowercases and underscores a go type name
-func ToCommandName(name string) string {
- in := split(name)
- out := make([]string, 0, len(in))
-
- for _, w := range in {
- out = append(out, lower(w))
- }
- return strings.Join(out, "-")
-}
-
-// ToHumanNameLower represents a code name as a human series of words
-func ToHumanNameLower(name string) string {
- s := poolOfSplitters.BorrowSplitter(withPostSplitInitialismCheck)
- in := s.split(name)
- poolOfSplitters.RedeemSplitter(s)
- out := make([]string, 0, len(*in))
-
- for _, w := range *in {
- if !w.IsInitialism() {
- out = append(out, lower(w.GetOriginal()))
- } else {
- out = append(out, trim(w.GetOriginal()))
- }
- }
- poolOfLexems.RedeemLexems(in)
-
- return strings.Join(out, " ")
-}
-
-// ToHumanNameTitle represents a code name as a human series of words with the first letters titleized
-func ToHumanNameTitle(name string) string {
- s := poolOfSplitters.BorrowSplitter(withPostSplitInitialismCheck)
- in := s.split(name)
- poolOfSplitters.RedeemSplitter(s)
-
- out := make([]string, 0, len(*in))
- for _, w := range *in {
- original := trim(w.GetOriginal())
- if !w.IsInitialism() {
- out = append(out, Camelize(original))
- } else {
- out = append(out, original)
- }
- }
- poolOfLexems.RedeemLexems(in)
-
- return strings.Join(out, " ")
-}
-
-// ToJSONName camelcases a name which can be underscored or pascal cased
-func ToJSONName(name string) string {
- in := split(name)
- out := make([]string, 0, len(in))
-
- for i, w := range in {
- if i == 0 {
- out = append(out, lower(w))
- continue
- }
- out = append(out, Camelize(trim(w)))
- }
- return strings.Join(out, "")
-}
-
-// ToVarName camelcases a name which can be underscored or pascal cased
-func ToVarName(name string) string {
- res := ToGoName(name)
- if isInitialism(res) {
- return lower(res)
- }
- if len(res) <= 1 {
- return lower(res)
- }
- return lower(res[:1]) + res[1:]
-}
-
-// ToGoName translates a swagger name which can be underscored or camel cased to a name that golint likes
-func ToGoName(name string) string {
- s := poolOfSplitters.BorrowSplitter(withPostSplitInitialismCheck)
- lexems := s.split(name)
- poolOfSplitters.RedeemSplitter(s)
- defer func() {
- poolOfLexems.RedeemLexems(lexems)
- }()
- lexemes := *lexems
-
- if len(lexemes) == 0 {
- return ""
- }
-
- result := poolOfBuffers.BorrowBuffer(len(name))
- defer func() {
- poolOfBuffers.RedeemBuffer(result)
- }()
-
- // check if not starting with a letter, upper case
- firstPart := lexemes[0].GetUnsafeGoName()
- if lexemes[0].IsInitialism() {
- firstPart = upper(firstPart)
- }
-
- if c := firstPart[0]; c < utf8.RuneSelf {
- // ASCII
- switch {
- case 'A' <= c && c <= 'Z':
- result.WriteString(firstPart)
- case 'a' <= c && c <= 'z':
- result.WriteByte(c - 'a' + 'A')
- result.WriteString(firstPart[1:])
- default:
- result.WriteString(prefixFunc(name, firstPart))
- // NOTE: no longer check if prefixFunc returns a string that starts with uppercase:
- // assume this is always the case
- }
- } else {
- // unicode
- firstRune, _ := utf8.DecodeRuneInString(firstPart)
- switch {
- case !unicode.IsLetter(firstRune):
- result.WriteString(prefixFunc(name, firstPart))
- case !unicode.IsUpper(firstRune):
- result.WriteString(prefixFunc(name, firstPart))
- /*
- result.WriteRune(unicode.ToUpper(firstRune))
- result.WriteString(firstPart[offset:])
- */
- default:
- result.WriteString(firstPart)
- }
- }
-
- for _, lexem := range lexemes[1:] {
- goName := lexem.GetUnsafeGoName()
-
- // to support old behavior
- if lexem.IsInitialism() {
- goName = upper(goName)
- }
- result.WriteString(goName)
- }
-
- return result.String()
-}
-
-// ContainsStrings searches a slice of strings for a case-sensitive match
-func ContainsStrings(coll []string, item string) bool {
- for _, a := range coll {
- if a == item {
- return true
- }
- }
- return false
-}
-
-// ContainsStringsCI searches a slice of strings for a case-insensitive match
-func ContainsStringsCI(coll []string, item string) bool {
- for _, a := range coll {
- if strings.EqualFold(a, item) {
- return true
- }
- }
- return false
-}
-
-type zeroable interface {
- IsZero() bool
-}
-
-// IsZero returns true when the value passed into the function is a zero value.
-// This allows for safer checking of interface values.
-func IsZero(data interface{}) bool {
- v := reflect.ValueOf(data)
- // check for nil data
- switch v.Kind() { //nolint:exhaustive
- case reflect.Interface, reflect.Map, reflect.Ptr, reflect.Slice:
- if v.IsNil() {
- return true
- }
- }
-
- // check for things that have an IsZero method instead
- if vv, ok := data.(zeroable); ok {
- return vv.IsZero()
- }
-
- // continue with slightly more complex reflection
- switch v.Kind() { //nolint:exhaustive
- case reflect.String:
- return v.Len() == 0
- case reflect.Bool:
- return !v.Bool()
- case reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64:
- return v.Int() == 0
- case reflect.Uint, reflect.Uint8, reflect.Uint16, reflect.Uint32, reflect.Uint64, reflect.Uintptr:
- return v.Uint() == 0
- case reflect.Float32, reflect.Float64:
- return v.Float() == 0
- case reflect.Struct, reflect.Array:
- return reflect.DeepEqual(data, reflect.Zero(v.Type()).Interface())
- case reflect.Invalid:
- return true
- default:
- return false
- }
-}
-
-// CommandLineOptionsGroup represents a group of user-defined command line options
-type CommandLineOptionsGroup struct {
- ShortDescription string
- LongDescription string
- Options interface{}
-}
diff --git a/vendor/github.com/go-openapi/swag/yaml.go b/vendor/github.com/go-openapi/swag/yaml.go
deleted file mode 100644
index f59e025932..0000000000
--- a/vendor/github.com/go-openapi/swag/yaml.go
+++ /dev/null
@@ -1,481 +0,0 @@
-// Copyright 2015 go-swagger maintainers
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-package swag
-
-import (
- "encoding/json"
- "errors"
- "fmt"
- "path/filepath"
- "reflect"
- "sort"
- "strconv"
-
- "github.com/mailru/easyjson/jlexer"
- "github.com/mailru/easyjson/jwriter"
- yaml "gopkg.in/yaml.v3"
-)
-
-// YAMLMatcher matches yaml
-func YAMLMatcher(path string) bool {
- ext := filepath.Ext(path)
- return ext == ".yaml" || ext == ".yml"
-}
-
-// YAMLToJSON converts YAML unmarshaled data into json compatible data
-func YAMLToJSON(data interface{}) (json.RawMessage, error) {
- jm, err := transformData(data)
- if err != nil {
- return nil, err
- }
- b, err := WriteJSON(jm)
- return json.RawMessage(b), err
-}
-
-// BytesToYAMLDoc converts a byte slice into a YAML document
-func BytesToYAMLDoc(data []byte) (interface{}, error) {
- var document yaml.Node // preserve order that is present in the document
- if err := yaml.Unmarshal(data, &document); err != nil {
- return nil, err
- }
- if document.Kind != yaml.DocumentNode || len(document.Content) != 1 || document.Content[0].Kind != yaml.MappingNode {
- return nil, errors.New("only YAML documents that are objects are supported")
- }
- return &document, nil
-}
-
-func yamlNode(root *yaml.Node) (interface{}, error) {
- switch root.Kind {
- case yaml.DocumentNode:
- return yamlDocument(root)
- case yaml.SequenceNode:
- return yamlSequence(root)
- case yaml.MappingNode:
- return yamlMapping(root)
- case yaml.ScalarNode:
- return yamlScalar(root)
- case yaml.AliasNode:
- return yamlNode(root.Alias)
- default:
- return nil, fmt.Errorf("unsupported YAML node type: %v", root.Kind)
- }
-}
-
-func yamlDocument(node *yaml.Node) (interface{}, error) {
- if len(node.Content) != 1 {
- return nil, fmt.Errorf("unexpected YAML Document node content length: %d", len(node.Content))
- }
- return yamlNode(node.Content[0])
-}
-
-func yamlMapping(node *yaml.Node) (interface{}, error) {
- m := make(JSONMapSlice, len(node.Content)/2)
-
- var j int
- for i := 0; i < len(node.Content); i += 2 {
- var nmi JSONMapItem
- k, err := yamlStringScalarC(node.Content[i])
- if err != nil {
- return nil, fmt.Errorf("unable to decode YAML map key: %w", err)
- }
- nmi.Key = k
- v, err := yamlNode(node.Content[i+1])
- if err != nil {
- return nil, fmt.Errorf("unable to process YAML map value for key %q: %w", k, err)
- }
- nmi.Value = v
- m[j] = nmi
- j++
- }
- return m, nil
-}
-
-func yamlSequence(node *yaml.Node) (interface{}, error) {
- s := make([]interface{}, 0)
-
- for i := 0; i < len(node.Content); i++ {
-
- v, err := yamlNode(node.Content[i])
- if err != nil {
- return nil, fmt.Errorf("unable to decode YAML sequence value: %w", err)
- }
- s = append(s, v)
- }
- return s, nil
-}
-
-const ( // See https://yaml.org/type/
- yamlStringScalar = "tag:yaml.org,2002:str"
- yamlIntScalar = "tag:yaml.org,2002:int"
- yamlBoolScalar = "tag:yaml.org,2002:bool"
- yamlFloatScalar = "tag:yaml.org,2002:float"
- yamlTimestamp = "tag:yaml.org,2002:timestamp"
- yamlNull = "tag:yaml.org,2002:null"
-)
-
-func yamlScalar(node *yaml.Node) (interface{}, error) {
- switch node.LongTag() {
- case yamlStringScalar:
- return node.Value, nil
- case yamlBoolScalar:
- b, err := strconv.ParseBool(node.Value)
- if err != nil {
- return nil, fmt.Errorf("unable to process scalar node. Got %q. Expecting bool content: %w", node.Value, err)
- }
- return b, nil
- case yamlIntScalar:
- i, err := strconv.ParseInt(node.Value, 10, 64)
- if err != nil {
- return nil, fmt.Errorf("unable to process scalar node. Got %q. Expecting integer content: %w", node.Value, err)
- }
- return i, nil
- case yamlFloatScalar:
- f, err := strconv.ParseFloat(node.Value, 64)
- if err != nil {
- return nil, fmt.Errorf("unable to process scalar node. Got %q. Expecting float content: %w", node.Value, err)
- }
- return f, nil
- case yamlTimestamp:
- return node.Value, nil
- case yamlNull:
- return nil, nil //nolint:nilnil
- default:
- return nil, fmt.Errorf("YAML tag %q is not supported", node.LongTag())
- }
-}
-
-func yamlStringScalarC(node *yaml.Node) (string, error) {
- if node.Kind != yaml.ScalarNode {
- return "", fmt.Errorf("expecting a string scalar but got %q", node.Kind)
- }
- switch node.LongTag() {
- case yamlStringScalar, yamlIntScalar, yamlFloatScalar:
- return node.Value, nil
- default:
- return "", fmt.Errorf("YAML tag %q is not supported as map key", node.LongTag())
- }
-}
-
-// JSONMapSlice represent a JSON object, with the order of keys maintained
-type JSONMapSlice []JSONMapItem
-
-// MarshalJSON renders a JSONMapSlice as JSON
-func (s JSONMapSlice) MarshalJSON() ([]byte, error) {
- w := &jwriter.Writer{Flags: jwriter.NilMapAsEmpty | jwriter.NilSliceAsEmpty}
- s.MarshalEasyJSON(w)
- return w.BuildBytes()
-}
-
-// MarshalEasyJSON renders a JSONMapSlice as JSON, using easyJSON
-func (s JSONMapSlice) MarshalEasyJSON(w *jwriter.Writer) {
- w.RawByte('{')
-
- ln := len(s)
- last := ln - 1
- for i := 0; i < ln; i++ {
- s[i].MarshalEasyJSON(w)
- if i != last { // last item
- w.RawByte(',')
- }
- }
-
- w.RawByte('}')
-}
-
-// UnmarshalJSON makes a JSONMapSlice from JSON
-func (s *JSONMapSlice) UnmarshalJSON(data []byte) error {
- l := jlexer.Lexer{Data: data}
- s.UnmarshalEasyJSON(&l)
- return l.Error()
-}
-
-// UnmarshalEasyJSON makes a JSONMapSlice from JSON, using easyJSON
-func (s *JSONMapSlice) UnmarshalEasyJSON(in *jlexer.Lexer) {
- if in.IsNull() {
- in.Skip()
- return
- }
-
- var result JSONMapSlice
- in.Delim('{')
- for !in.IsDelim('}') {
- var mi JSONMapItem
- mi.UnmarshalEasyJSON(in)
- result = append(result, mi)
- }
- *s = result
-}
-
-func (s JSONMapSlice) MarshalYAML() (interface{}, error) {
- var n yaml.Node
- n.Kind = yaml.DocumentNode
- var nodes []*yaml.Node
- for _, item := range s {
- nn, err := json2yaml(item.Value)
- if err != nil {
- return nil, err
- }
- ns := []*yaml.Node{
- {
- Kind: yaml.ScalarNode,
- Tag: yamlStringScalar,
- Value: item.Key,
- },
- nn,
- }
- nodes = append(nodes, ns...)
- }
-
- n.Content = []*yaml.Node{
- {
- Kind: yaml.MappingNode,
- Content: nodes,
- },
- }
-
- return yaml.Marshal(&n)
-}
-
-func isNil(input interface{}) bool {
- if input == nil {
- return true
- }
- kind := reflect.TypeOf(input).Kind()
- switch kind { //nolint:exhaustive
- case reflect.Ptr, reflect.Map, reflect.Slice, reflect.Chan:
- return reflect.ValueOf(input).IsNil()
- default:
- return false
- }
-}
-
-func json2yaml(item interface{}) (*yaml.Node, error) {
- if isNil(item) {
- return &yaml.Node{
- Kind: yaml.ScalarNode,
- Value: "null",
- }, nil
- }
-
- switch val := item.(type) {
- case JSONMapSlice:
- var n yaml.Node
- n.Kind = yaml.MappingNode
- for i := range val {
- childNode, err := json2yaml(&val[i].Value)
- if err != nil {
- return nil, err
- }
- n.Content = append(n.Content, &yaml.Node{
- Kind: yaml.ScalarNode,
- Tag: yamlStringScalar,
- Value: val[i].Key,
- }, childNode)
- }
- return &n, nil
- case map[string]interface{}:
- var n yaml.Node
- n.Kind = yaml.MappingNode
- keys := make([]string, 0, len(val))
- for k := range val {
- keys = append(keys, k)
- }
- sort.Strings(keys)
-
- for _, k := range keys {
- v := val[k]
- childNode, err := json2yaml(v)
- if err != nil {
- return nil, err
- }
- n.Content = append(n.Content, &yaml.Node{
- Kind: yaml.ScalarNode,
- Tag: yamlStringScalar,
- Value: k,
- }, childNode)
- }
- return &n, nil
- case []interface{}:
- var n yaml.Node
- n.Kind = yaml.SequenceNode
- for i := range val {
- childNode, err := json2yaml(val[i])
- if err != nil {
- return nil, err
- }
- n.Content = append(n.Content, childNode)
- }
- return &n, nil
- case string:
- return &yaml.Node{
- Kind: yaml.ScalarNode,
- Tag: yamlStringScalar,
- Value: val,
- }, nil
- case float64:
- return &yaml.Node{
- Kind: yaml.ScalarNode,
- Tag: yamlFloatScalar,
- Value: strconv.FormatFloat(val, 'f', -1, 64),
- }, nil
- case int64:
- return &yaml.Node{
- Kind: yaml.ScalarNode,
- Tag: yamlIntScalar,
- Value: strconv.FormatInt(val, 10),
- }, nil
- case uint64:
- return &yaml.Node{
- Kind: yaml.ScalarNode,
- Tag: yamlIntScalar,
- Value: strconv.FormatUint(val, 10),
- }, nil
- case bool:
- return &yaml.Node{
- Kind: yaml.ScalarNode,
- Tag: yamlBoolScalar,
- Value: strconv.FormatBool(val),
- }, nil
- default:
- return nil, fmt.Errorf("unhandled type: %T", val)
- }
-}
-
-// JSONMapItem represents the value of a key in a JSON object held by JSONMapSlice
-type JSONMapItem struct {
- Key string
- Value interface{}
-}
-
-// MarshalJSON renders a JSONMapItem as JSON
-func (s JSONMapItem) MarshalJSON() ([]byte, error) {
- w := &jwriter.Writer{Flags: jwriter.NilMapAsEmpty | jwriter.NilSliceAsEmpty}
- s.MarshalEasyJSON(w)
- return w.BuildBytes()
-}
-
-// MarshalEasyJSON renders a JSONMapItem as JSON, using easyJSON
-func (s JSONMapItem) MarshalEasyJSON(w *jwriter.Writer) {
- w.String(s.Key)
- w.RawByte(':')
- w.Raw(WriteJSON(s.Value))
-}
-
-// UnmarshalJSON makes a JSONMapItem from JSON
-func (s *JSONMapItem) UnmarshalJSON(data []byte) error {
- l := jlexer.Lexer{Data: data}
- s.UnmarshalEasyJSON(&l)
- return l.Error()
-}
-
-// UnmarshalEasyJSON makes a JSONMapItem from JSON, using easyJSON
-func (s *JSONMapItem) UnmarshalEasyJSON(in *jlexer.Lexer) {
- key := in.UnsafeString()
- in.WantColon()
- value := in.Interface()
- in.WantComma()
- s.Key = key
- s.Value = value
-}
-
-func transformData(input interface{}) (out interface{}, err error) {
- format := func(t interface{}) (string, error) {
- switch k := t.(type) {
- case string:
- return k, nil
- case uint:
- return strconv.FormatUint(uint64(k), 10), nil
- case uint8:
- return strconv.FormatUint(uint64(k), 10), nil
- case uint16:
- return strconv.FormatUint(uint64(k), 10), nil
- case uint32:
- return strconv.FormatUint(uint64(k), 10), nil
- case uint64:
- return strconv.FormatUint(k, 10), nil
- case int:
- return strconv.Itoa(k), nil
- case int8:
- return strconv.FormatInt(int64(k), 10), nil
- case int16:
- return strconv.FormatInt(int64(k), 10), nil
- case int32:
- return strconv.FormatInt(int64(k), 10), nil
- case int64:
- return strconv.FormatInt(k, 10), nil
- default:
- return "", fmt.Errorf("unexpected map key type, got: %T", k)
- }
- }
-
- switch in := input.(type) {
- case yaml.Node:
- return yamlNode(&in)
- case *yaml.Node:
- return yamlNode(in)
- case map[interface{}]interface{}:
- o := make(JSONMapSlice, 0, len(in))
- for ke, va := range in {
- var nmi JSONMapItem
- if nmi.Key, err = format(ke); err != nil {
- return nil, err
- }
-
- v, ert := transformData(va)
- if ert != nil {
- return nil, ert
- }
- nmi.Value = v
- o = append(o, nmi)
- }
- return o, nil
- case []interface{}:
- len1 := len(in)
- o := make([]interface{}, len1)
- for i := 0; i < len1; i++ {
- o[i], err = transformData(in[i])
- if err != nil {
- return nil, err
- }
- }
- return o, nil
- }
- return input, nil
-}
-
-// YAMLDoc loads a yaml document from either http or a file and converts it to json
-func YAMLDoc(path string) (json.RawMessage, error) {
- yamlDoc, err := YAMLData(path)
- if err != nil {
- return nil, err
- }
-
- data, err := YAMLToJSON(yamlDoc)
- if err != nil {
- return nil, err
- }
-
- return data, nil
-}
-
-// YAMLData loads a yaml document from either http or a file
-func YAMLData(path string) (interface{}, error) {
- data, err := LoadFromFileOrHTTP(path)
- if err != nil {
- return nil, err
- }
-
- return BytesToYAMLDoc(data)
-}
diff --git a/vendor/github.com/go-openapi/swag/yamlutils/LICENSE b/vendor/github.com/go-openapi/swag/yamlutils/LICENSE
new file mode 100644
index 0000000000..d645695673
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/yamlutils/LICENSE
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/vendor/github.com/go-openapi/swag/yamlutils/doc.go b/vendor/github.com/go-openapi/swag/yamlutils/doc.go
new file mode 100644
index 0000000000..7bb92a82f1
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/yamlutils/doc.go
@@ -0,0 +1,13 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+// Package yamlutils provides utilities to work with YAML documents.
+//
+// - [BytesToYAMLDoc] to construct a [yaml.Node] document
+// - [YAMLToJSON] to convert a [yaml.Node] document to JSON bytes
+// - [YAMLMapSlice] to serialize and deserialize YAML with the order of keys maintained
+package yamlutils
+
+import (
+ _ "go.yaml.in/yaml/v3" // for documentation purpose only
+)
diff --git a/vendor/github.com/go-openapi/swag/yamlutils/errors.go b/vendor/github.com/go-openapi/swag/yamlutils/errors.go
new file mode 100644
index 0000000000..e87bc5e8be
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/yamlutils/errors.go
@@ -0,0 +1,15 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package yamlutils
+
+type yamlError string
+
+const (
+ // ErrYAML is an error raised by YAML utilities
+ ErrYAML yamlError = "yaml error"
+)
+
+func (e yamlError) Error() string {
+ return string(e)
+}
diff --git a/vendor/github.com/go-openapi/swag/yamlutils/ordered_map.go b/vendor/github.com/go-openapi/swag/yamlutils/ordered_map.go
new file mode 100644
index 0000000000..3daf68dbba
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/yamlutils/ordered_map.go
@@ -0,0 +1,316 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package yamlutils
+
+import (
+ "fmt"
+ "iter"
+ "slices"
+ "sort"
+ "strconv"
+
+ "github.com/go-openapi/swag/conv"
+ "github.com/go-openapi/swag/jsonutils"
+ "github.com/go-openapi/swag/jsonutils/adapters/ifaces"
+ "github.com/go-openapi/swag/typeutils"
+ yaml "go.yaml.in/yaml/v3"
+)
+
+var (
+ _ yaml.Marshaler = YAMLMapSlice{}
+ _ yaml.Unmarshaler = &YAMLMapSlice{}
+)
+
+// YAMLMapSlice represents a YAML object, with the order of keys maintained.
+//
+// It is similar to [jsonutils.JSONMapSlice] and also knows how to marshal and unmarshal YAML.
+//
+// It behaves like an ordered map, but keys can't be accessed in constant time.
+type YAMLMapSlice []YAMLMapItem
+
+// YAMLMapItem represents the value of a key in a YAML object held by [YAMLMapSlice].
+//
+// It is entirely equivalent to [jsonutils.JSONMapItem], with the same limitation that
+// you should not Marshal or Unmarshal directly this type, outside of a [YAMLMapSlice].
+type YAMLMapItem = jsonutils.JSONMapItem
+
+func (s YAMLMapSlice) OrderedItems() iter.Seq2[string, any] {
+ return func(yield func(string, any) bool) {
+ for _, item := range s {
+ if !yield(item.Key, item.Value) {
+ return
+ }
+ }
+ }
+}
+
+// SetOrderedItems implements [ifaces.SetOrdered]: it merges keys passed by the iterator argument
+// into the [YAMLMapSlice].
+func (s *YAMLMapSlice) SetOrderedItems(items iter.Seq2[string, any]) {
+ if items == nil {
+ // force receiver to be a nil slice
+ *s = nil
+
+ return
+ }
+
+ m := *s
+ if len(m) > 0 {
+ // update mode: short-circuited when unmarshaling fresh data structures
+ idx := make(map[string]int, len(m))
+
+ for i, item := range m {
+ idx[item.Key] = i
+ }
+
+ for k, v := range items {
+ idx, ok := idx[k]
+ if ok {
+ m[idx].Value = v
+
+ continue
+ }
+
+ m = append(m, YAMLMapItem{Key: k, Value: v})
+ }
+
+ *s = m
+
+ return
+ }
+
+ for k, v := range items {
+ m = append(m, YAMLMapItem{Key: k, Value: v})
+ }
+
+ *s = m
+}
+
+// MarshalJSON renders this YAML object as JSON bytes.
+//
+// The difference with standard JSON marshaling is that the order of keys is maintained.
+func (s YAMLMapSlice) MarshalJSON() ([]byte, error) {
+ return jsonutils.JSONMapSlice(s).MarshalJSON()
+}
+
+// UnmarshalJSON builds this YAML object from JSON bytes.
+//
+// The difference with standard JSON marshaling is that the order of keys is maintained.
+func (s *YAMLMapSlice) UnmarshalJSON(data []byte) error {
+ js := jsonutils.JSONMapSlice(*s)
+
+ if err := js.UnmarshalJSON(data); err != nil {
+ return err
+ }
+
+ *s = YAMLMapSlice(js)
+
+ return nil
+}
+
+// MarshalYAML produces a YAML document as bytes
+//
+// The difference with standard YAML marshaling is that the order of keys is maintained.
+//
+// It implements [yaml.Marshaler].
+func (s YAMLMapSlice) MarshalYAML() (any, error) {
+ if typeutils.IsNil(s) {
+ return []byte("null\n"), nil
+ }
+ var n yaml.Node
+ n.Kind = yaml.DocumentNode
+ var nodes []*yaml.Node
+
+ for _, item := range s {
+ nn, err := json2yaml(item.Value)
+ if err != nil {
+ return nil, err
+ }
+
+ ns := []*yaml.Node{
+ {
+ Kind: yaml.ScalarNode,
+ Tag: yamlStringScalar,
+ Value: item.Key,
+ },
+ nn,
+ }
+ nodes = append(nodes, ns...)
+ }
+
+ n.Content = []*yaml.Node{
+ {
+ Kind: yaml.MappingNode,
+ Content: nodes,
+ },
+ }
+
+ return yaml.Marshal(&n)
+}
+
+// UnmarshalYAML builds a YAMLMapSlice object from a YAML document [yaml.Node].
+//
+// It implements [yaml.Unmarshaler].
+func (s *YAMLMapSlice) UnmarshalYAML(node *yaml.Node) error {
+ if typeutils.IsNil(*s) {
+ // allow to unmarshal with a simple var declaration (nil slice)
+ *s = YAMLMapSlice{}
+ }
+ if node == nil {
+ *s = nil
+ return nil
+ }
+
+ const sensibleAllocDivider = 2
+ m := slices.Grow(*s, len(node.Content)/sensibleAllocDivider)
+ m = m[:0]
+
+ for i := 0; i < len(node.Content); i += 2 {
+ var nmi YAMLMapItem
+ k, err := yamlStringScalarC(node.Content[i])
+ if err != nil {
+ return fmt.Errorf("unable to decode YAML map key: %w: %w", err, ErrYAML)
+ }
+ nmi.Key = k
+ v, err := yamlNode(node.Content[i+1])
+ if err != nil {
+ return fmt.Errorf("unable to process YAML map value for key %q: %w: %w", k, err, ErrYAML)
+ }
+ nmi.Value = v
+ m = append(m, nmi)
+ }
+
+ *s = m
+
+ return nil
+}
+
+func json2yaml(item any) (*yaml.Node, error) {
+ if typeutils.IsNil(item) {
+ return &yaml.Node{
+ Kind: yaml.ScalarNode,
+ Value: "null",
+ }, nil
+ }
+
+ switch val := item.(type) {
+ case ifaces.Ordered:
+ return orderedYAML(val)
+
+ case map[string]any:
+ var n yaml.Node
+ n.Kind = yaml.MappingNode
+ keys := make([]string, 0, len(val))
+ for k := range val {
+ keys = append(keys, k)
+ }
+ sort.Strings(keys)
+
+ for _, k := range keys {
+ v := val[k]
+ childNode, err := json2yaml(v)
+ if err != nil {
+ return nil, err
+ }
+ n.Content = append(n.Content, &yaml.Node{
+ Kind: yaml.ScalarNode,
+ Tag: yamlStringScalar,
+ Value: k,
+ }, childNode)
+ }
+ return &n, nil
+
+ case []any:
+ var n yaml.Node
+ n.Kind = yaml.SequenceNode
+ for i := range val {
+ childNode, err := json2yaml(val[i])
+ if err != nil {
+ return nil, err
+ }
+ n.Content = append(n.Content, childNode)
+ }
+ return &n, nil
+ case string:
+ return &yaml.Node{
+ Kind: yaml.ScalarNode,
+ Tag: yamlStringScalar,
+ Value: val,
+ }, nil
+ case float32:
+ return floatNode(val)
+ case float64:
+ return floatNode(val)
+ case int:
+ return integerNode(val)
+ case int8:
+ return integerNode(val)
+ case int16:
+ return integerNode(val)
+ case int32:
+ return integerNode(val)
+ case int64:
+ return integerNode(val)
+ case uint:
+ return uintegerNode(val)
+ case uint8:
+ return uintegerNode(val)
+ case uint16:
+ return uintegerNode(val)
+ case uint32:
+ return uintegerNode(val)
+ case uint64:
+ return uintegerNode(val)
+ case bool:
+ return &yaml.Node{
+ Kind: yaml.ScalarNode,
+ Tag: yamlBoolScalar,
+ Value: strconv.FormatBool(val),
+ }, nil
+ default:
+ return nil, fmt.Errorf("unhandled type: %T: %w", val, ErrYAML)
+ }
+}
+
+func floatNode[T conv.Float](val T) (*yaml.Node, error) {
+ return &yaml.Node{
+ Kind: yaml.ScalarNode,
+ Tag: yamlFloatScalar,
+ Value: conv.FormatFloat(val),
+ }, nil
+}
+
+func integerNode[T conv.Signed](val T) (*yaml.Node, error) {
+ return &yaml.Node{
+ Kind: yaml.ScalarNode,
+ Tag: yamlIntScalar,
+ Value: conv.FormatInteger(val),
+ }, nil
+}
+
+func uintegerNode[T conv.Unsigned](val T) (*yaml.Node, error) {
+ return &yaml.Node{
+ Kind: yaml.ScalarNode,
+ Tag: yamlIntScalar,
+ Value: conv.FormatUinteger(val),
+ }, nil
+}
+
+func orderedYAML[T ifaces.Ordered](val T) (*yaml.Node, error) {
+ var n yaml.Node
+ n.Kind = yaml.MappingNode
+ for key, value := range val.OrderedItems() {
+ childNode, err := json2yaml(value)
+ if err != nil {
+ return nil, err
+ }
+
+ n.Content = append(n.Content, &yaml.Node{
+ Kind: yaml.ScalarNode,
+ Tag: yamlStringScalar,
+ Value: key,
+ }, childNode)
+ }
+ return &n, nil
+}
diff --git a/vendor/github.com/go-openapi/swag/yamlutils/yaml.go b/vendor/github.com/go-openapi/swag/yamlutils/yaml.go
new file mode 100644
index 0000000000..e3aff3c2fd
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/yamlutils/yaml.go
@@ -0,0 +1,211 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package yamlutils
+
+import (
+ json "encoding/json"
+ "fmt"
+ "strconv"
+
+ "github.com/go-openapi/swag/jsonutils"
+ yaml "go.yaml.in/yaml/v3"
+)
+
+// YAMLToJSON converts a YAML document into JSON bytes.
+//
+// Note: a YAML document is the output from a [yaml.Marshaler], e.g a pointer to a [yaml.Node].
+//
+// [YAMLToJSON] is typically called after [BytesToYAMLDoc].
+func YAMLToJSON(value any) (json.RawMessage, error) {
+ jm, err := transformData(value)
+ if err != nil {
+ return nil, err
+ }
+
+ b, err := jsonutils.WriteJSON(jm)
+
+ return json.RawMessage(b), err
+}
+
+// BytesToYAMLDoc converts a byte slice into a YAML document.
+//
+// This function only supports root documents that are objects.
+//
+// A YAML document is a pointer to a [yaml.Node].
+func BytesToYAMLDoc(data []byte) (any, error) {
+ var document yaml.Node // preserve order that is present in the document
+ if err := yaml.Unmarshal(data, &document); err != nil {
+ return nil, err
+ }
+ if document.Kind != yaml.DocumentNode || len(document.Content) != 1 || document.Content[0].Kind != yaml.MappingNode {
+ return nil, fmt.Errorf("only YAML documents that are objects are supported: %w", ErrYAML)
+ }
+ return &document, nil
+}
+
+func yamlNode(root *yaml.Node) (any, error) {
+ switch root.Kind {
+ case yaml.DocumentNode:
+ return yamlDocument(root)
+ case yaml.SequenceNode:
+ return yamlSequence(root)
+ case yaml.MappingNode:
+ return yamlMapping(root)
+ case yaml.ScalarNode:
+ return yamlScalar(root)
+ case yaml.AliasNode:
+ return yamlNode(root.Alias)
+ default:
+ return nil, fmt.Errorf("unsupported YAML node type: %v: %w", root.Kind, ErrYAML)
+ }
+}
+
+func yamlDocument(node *yaml.Node) (any, error) {
+ if len(node.Content) != 1 {
+ return nil, fmt.Errorf("unexpected YAML Document node content length: %d: %w", len(node.Content), ErrYAML)
+ }
+ return yamlNode(node.Content[0])
+}
+
+func yamlMapping(node *yaml.Node) (any, error) {
+ const sensibleAllocDivider = 2 // nodes concatenate (key,value) sequences
+ m := make(YAMLMapSlice, len(node.Content)/sensibleAllocDivider)
+
+ if err := m.UnmarshalYAML(node); err != nil {
+ return nil, err
+ }
+
+ return m, nil
+}
+
+func yamlSequence(node *yaml.Node) (any, error) {
+ s := make([]any, 0)
+
+ for i := range len(node.Content) {
+ v, err := yamlNode(node.Content[i])
+ if err != nil {
+ return nil, fmt.Errorf("unable to decode YAML sequence value: %w: %w", err, ErrYAML)
+ }
+ s = append(s, v)
+ }
+ return s, nil
+}
+
+const ( // See https://yaml.org/type/
+ yamlStringScalar = "tag:yaml.org,2002:str"
+ yamlIntScalar = "tag:yaml.org,2002:int"
+ yamlBoolScalar = "tag:yaml.org,2002:bool"
+ yamlFloatScalar = "tag:yaml.org,2002:float"
+ yamlTimestamp = "tag:yaml.org,2002:timestamp"
+ yamlNull = "tag:yaml.org,2002:null"
+)
+
+func yamlScalar(node *yaml.Node) (any, error) {
+ switch node.LongTag() {
+ case yamlStringScalar:
+ return node.Value, nil
+ case yamlBoolScalar:
+ b, err := strconv.ParseBool(node.Value)
+ if err != nil {
+ return nil, fmt.Errorf("unable to process scalar node. Got %q. Expecting bool content: %w: %w", node.Value, err, ErrYAML)
+ }
+ return b, nil
+ case yamlIntScalar:
+ i, err := strconv.ParseInt(node.Value, 10, 64)
+ if err != nil {
+ return nil, fmt.Errorf("unable to process scalar node. Got %q. Expecting integer content: %w: %w", node.Value, err, ErrYAML)
+ }
+ return i, nil
+ case yamlFloatScalar:
+ f, err := strconv.ParseFloat(node.Value, 64)
+ if err != nil {
+ return nil, fmt.Errorf("unable to process scalar node. Got %q. Expecting float content: %w: %w", node.Value, err, ErrYAML)
+ }
+ return f, nil
+ case yamlTimestamp:
+ // YAML timestamp is marshaled as string, not time
+ return node.Value, nil
+ case yamlNull:
+ return nil, nil //nolint:nilnil
+ default:
+ return nil, fmt.Errorf("YAML tag %q is not supported: %w", node.LongTag(), ErrYAML)
+ }
+}
+
+func yamlStringScalarC(node *yaml.Node) (string, error) {
+ if node.Kind != yaml.ScalarNode {
+ return "", fmt.Errorf("expecting a string scalar but got %q: %w", node.Kind, ErrYAML)
+ }
+ switch node.LongTag() {
+ case yamlStringScalar, yamlIntScalar, yamlFloatScalar:
+ return node.Value, nil
+ default:
+ return "", fmt.Errorf("YAML tag %q is not supported as map key: %w", node.LongTag(), ErrYAML)
+ }
+}
+
+func format(t any) (string, error) {
+ switch k := t.(type) {
+ case string:
+ return k, nil
+ case uint:
+ return strconv.FormatUint(uint64(k), 10), nil
+ case uint8:
+ return strconv.FormatUint(uint64(k), 10), nil
+ case uint16:
+ return strconv.FormatUint(uint64(k), 10), nil
+ case uint32:
+ return strconv.FormatUint(uint64(k), 10), nil
+ case uint64:
+ return strconv.FormatUint(k, 10), nil
+ case int:
+ return strconv.Itoa(k), nil
+ case int8:
+ return strconv.FormatInt(int64(k), 10), nil
+ case int16:
+ return strconv.FormatInt(int64(k), 10), nil
+ case int32:
+ return strconv.FormatInt(int64(k), 10), nil
+ case int64:
+ return strconv.FormatInt(k, 10), nil
+ default:
+ return "", fmt.Errorf("unexpected map key type, got: %T: %w", k, ErrYAML)
+ }
+}
+
+func transformData(input any) (out any, err error) {
+ switch in := input.(type) {
+ case yaml.Node:
+ return yamlNode(&in)
+ case *yaml.Node:
+ return yamlNode(in)
+ case map[any]any:
+ o := make(YAMLMapSlice, 0, len(in))
+ for ke, va := range in {
+ var nmi YAMLMapItem
+ if nmi.Key, err = format(ke); err != nil {
+ return nil, err
+ }
+
+ v, ert := transformData(va)
+ if ert != nil {
+ return nil, ert
+ }
+ nmi.Value = v
+ o = append(o, nmi)
+ }
+ return o, nil
+ case []any:
+ len1 := len(in)
+ o := make([]any, len1)
+ for i := range len1 {
+ o[i], err = transformData(in[i])
+ if err != nil {
+ return nil, err
+ }
+ }
+ return o, nil
+ }
+ return input, nil
+}
diff --git a/vendor/github.com/go-openapi/swag/yamlutils_iface.go b/vendor/github.com/go-openapi/swag/yamlutils_iface.go
new file mode 100644
index 0000000000..57767efc56
--- /dev/null
+++ b/vendor/github.com/go-openapi/swag/yamlutils_iface.go
@@ -0,0 +1,20 @@
+// SPDX-FileCopyrightText: Copyright 2015-2025 go-swagger maintainers
+// SPDX-License-Identifier: Apache-2.0
+
+package swag
+
+import (
+ "encoding/json"
+
+ "github.com/go-openapi/swag/yamlutils"
+)
+
+// YAMLToJSON converts YAML unmarshaled data into json compatible data
+//
+// Deprecated: use [yamlutils.YAMLToJSON] instead.
+func YAMLToJSON(data any) (json.RawMessage, error) { return yamlutils.YAMLToJSON(data) }
+
+// BytesToYAMLDoc converts a byte slice into a YAML document
+//
+// Deprecated: use [yamlutils.BytesToYAMLDoc] instead.
+func BytesToYAMLDoc(data []byte) (any, error) { return yamlutils.BytesToYAMLDoc(data) }
diff --git a/vendor/github.com/google/btree/README.md b/vendor/github.com/google/btree/README.md
deleted file mode 100644
index eab5dbf7ba..0000000000
--- a/vendor/github.com/google/btree/README.md
+++ /dev/null
@@ -1,10 +0,0 @@
-# BTree implementation for Go
-
-This package provides an in-memory B-Tree implementation for Go, useful as
-an ordered, mutable data structure.
-
-The API is based off of the wonderful
-http://godoc.org/github.com/petar/GoLLRB/llrb, and is meant to allow btree to
-act as a drop-in replacement for gollrb trees.
-
-See http://godoc.org/github.com/google/btree for documentation.
diff --git a/vendor/github.com/google/btree/btree.go b/vendor/github.com/google/btree/btree.go
deleted file mode 100644
index 6f5184fef7..0000000000
--- a/vendor/github.com/google/btree/btree.go
+++ /dev/null
@@ -1,893 +0,0 @@
-// Copyright 2014 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-//go:build !go1.18
-// +build !go1.18
-
-// Package btree implements in-memory B-Trees of arbitrary degree.
-//
-// btree implements an in-memory B-Tree for use as an ordered data structure.
-// It is not meant for persistent storage solutions.
-//
-// It has a flatter structure than an equivalent red-black or other binary tree,
-// which in some cases yields better memory usage and/or performance.
-// See some discussion on the matter here:
-// http://google-opensource.blogspot.com/2013/01/c-containers-that-save-memory-and-time.html
-// Note, though, that this project is in no way related to the C++ B-Tree
-// implementation written about there.
-//
-// Within this tree, each node contains a slice of items and a (possibly nil)
-// slice of children. For basic numeric values or raw structs, this can cause
-// efficiency differences when compared to equivalent C++ template code that
-// stores values in arrays within the node:
-// * Due to the overhead of storing values as interfaces (each
-// value needs to be stored as the value itself, then 2 words for the
-// interface pointing to that value and its type), resulting in higher
-// memory use.
-// * Since interfaces can point to values anywhere in memory, values are
-// most likely not stored in contiguous blocks, resulting in a higher
-// number of cache misses.
-// These issues don't tend to matter, though, when working with strings or other
-// heap-allocated structures, since C++-equivalent structures also must store
-// pointers and also distribute their values across the heap.
-//
-// This implementation is designed to be a drop-in replacement to gollrb.LLRB
-// trees, (http://github.com/petar/gollrb), an excellent and probably the most
-// widely used ordered tree implementation in the Go ecosystem currently.
-// Its functions, therefore, exactly mirror those of
-// llrb.LLRB where possible. Unlike gollrb, though, we currently don't
-// support storing multiple equivalent values.
-package btree
-
-import (
- "fmt"
- "io"
- "sort"
- "strings"
- "sync"
-)
-
-// Item represents a single object in the tree.
-type Item interface {
- // Less tests whether the current item is less than the given argument.
- //
- // This must provide a strict weak ordering.
- // If !a.Less(b) && !b.Less(a), we treat this to mean a == b (i.e. we can only
- // hold one of either a or b in the tree).
- Less(than Item) bool
-}
-
-const (
- DefaultFreeListSize = 32
-)
-
-var (
- nilItems = make(items, 16)
- nilChildren = make(children, 16)
-)
-
-// FreeList represents a free list of btree nodes. By default each
-// BTree has its own FreeList, but multiple BTrees can share the same
-// FreeList.
-// Two Btrees using the same freelist are safe for concurrent write access.
-type FreeList struct {
- mu sync.Mutex
- freelist []*node
-}
-
-// NewFreeList creates a new free list.
-// size is the maximum size of the returned free list.
-func NewFreeList(size int) *FreeList {
- return &FreeList{freelist: make([]*node, 0, size)}
-}
-
-func (f *FreeList) newNode() (n *node) {
- f.mu.Lock()
- index := len(f.freelist) - 1
- if index < 0 {
- f.mu.Unlock()
- return new(node)
- }
- n = f.freelist[index]
- f.freelist[index] = nil
- f.freelist = f.freelist[:index]
- f.mu.Unlock()
- return
-}
-
-// freeNode adds the given node to the list, returning true if it was added
-// and false if it was discarded.
-func (f *FreeList) freeNode(n *node) (out bool) {
- f.mu.Lock()
- if len(f.freelist) < cap(f.freelist) {
- f.freelist = append(f.freelist, n)
- out = true
- }
- f.mu.Unlock()
- return
-}
-
-// ItemIterator allows callers of Ascend* to iterate in-order over portions of
-// the tree. When this function returns false, iteration will stop and the
-// associated Ascend* function will immediately return.
-type ItemIterator func(i Item) bool
-
-// New creates a new B-Tree with the given degree.
-//
-// New(2), for example, will create a 2-3-4 tree (each node contains 1-3 items
-// and 2-4 children).
-func New(degree int) *BTree {
- return NewWithFreeList(degree, NewFreeList(DefaultFreeListSize))
-}
-
-// NewWithFreeList creates a new B-Tree that uses the given node free list.
-func NewWithFreeList(degree int, f *FreeList) *BTree {
- if degree <= 1 {
- panic("bad degree")
- }
- return &BTree{
- degree: degree,
- cow: ©OnWriteContext{freelist: f},
- }
-}
-
-// items stores items in a node.
-type items []Item
-
-// insertAt inserts a value into the given index, pushing all subsequent values
-// forward.
-func (s *items) insertAt(index int, item Item) {
- *s = append(*s, nil)
- if index < len(*s) {
- copy((*s)[index+1:], (*s)[index:])
- }
- (*s)[index] = item
-}
-
-// removeAt removes a value at a given index, pulling all subsequent values
-// back.
-func (s *items) removeAt(index int) Item {
- item := (*s)[index]
- copy((*s)[index:], (*s)[index+1:])
- (*s)[len(*s)-1] = nil
- *s = (*s)[:len(*s)-1]
- return item
-}
-
-// pop removes and returns the last element in the list.
-func (s *items) pop() (out Item) {
- index := len(*s) - 1
- out = (*s)[index]
- (*s)[index] = nil
- *s = (*s)[:index]
- return
-}
-
-// truncate truncates this instance at index so that it contains only the
-// first index items. index must be less than or equal to length.
-func (s *items) truncate(index int) {
- var toClear items
- *s, toClear = (*s)[:index], (*s)[index:]
- for len(toClear) > 0 {
- toClear = toClear[copy(toClear, nilItems):]
- }
-}
-
-// find returns the index where the given item should be inserted into this
-// list. 'found' is true if the item already exists in the list at the given
-// index.
-func (s items) find(item Item) (index int, found bool) {
- i := sort.Search(len(s), func(i int) bool {
- return item.Less(s[i])
- })
- if i > 0 && !s[i-1].Less(item) {
- return i - 1, true
- }
- return i, false
-}
-
-// children stores child nodes in a node.
-type children []*node
-
-// insertAt inserts a value into the given index, pushing all subsequent values
-// forward.
-func (s *children) insertAt(index int, n *node) {
- *s = append(*s, nil)
- if index < len(*s) {
- copy((*s)[index+1:], (*s)[index:])
- }
- (*s)[index] = n
-}
-
-// removeAt removes a value at a given index, pulling all subsequent values
-// back.
-func (s *children) removeAt(index int) *node {
- n := (*s)[index]
- copy((*s)[index:], (*s)[index+1:])
- (*s)[len(*s)-1] = nil
- *s = (*s)[:len(*s)-1]
- return n
-}
-
-// pop removes and returns the last element in the list.
-func (s *children) pop() (out *node) {
- index := len(*s) - 1
- out = (*s)[index]
- (*s)[index] = nil
- *s = (*s)[:index]
- return
-}
-
-// truncate truncates this instance at index so that it contains only the
-// first index children. index must be less than or equal to length.
-func (s *children) truncate(index int) {
- var toClear children
- *s, toClear = (*s)[:index], (*s)[index:]
- for len(toClear) > 0 {
- toClear = toClear[copy(toClear, nilChildren):]
- }
-}
-
-// node is an internal node in a tree.
-//
-// It must at all times maintain the invariant that either
-// * len(children) == 0, len(items) unconstrained
-// * len(children) == len(items) + 1
-type node struct {
- items items
- children children
- cow *copyOnWriteContext
-}
-
-func (n *node) mutableFor(cow *copyOnWriteContext) *node {
- if n.cow == cow {
- return n
- }
- out := cow.newNode()
- if cap(out.items) >= len(n.items) {
- out.items = out.items[:len(n.items)]
- } else {
- out.items = make(items, len(n.items), cap(n.items))
- }
- copy(out.items, n.items)
- // Copy children
- if cap(out.children) >= len(n.children) {
- out.children = out.children[:len(n.children)]
- } else {
- out.children = make(children, len(n.children), cap(n.children))
- }
- copy(out.children, n.children)
- return out
-}
-
-func (n *node) mutableChild(i int) *node {
- c := n.children[i].mutableFor(n.cow)
- n.children[i] = c
- return c
-}
-
-// split splits the given node at the given index. The current node shrinks,
-// and this function returns the item that existed at that index and a new node
-// containing all items/children after it.
-func (n *node) split(i int) (Item, *node) {
- item := n.items[i]
- next := n.cow.newNode()
- next.items = append(next.items, n.items[i+1:]...)
- n.items.truncate(i)
- if len(n.children) > 0 {
- next.children = append(next.children, n.children[i+1:]...)
- n.children.truncate(i + 1)
- }
- return item, next
-}
-
-// maybeSplitChild checks if a child should be split, and if so splits it.
-// Returns whether or not a split occurred.
-func (n *node) maybeSplitChild(i, maxItems int) bool {
- if len(n.children[i].items) < maxItems {
- return false
- }
- first := n.mutableChild(i)
- item, second := first.split(maxItems / 2)
- n.items.insertAt(i, item)
- n.children.insertAt(i+1, second)
- return true
-}
-
-// insert inserts an item into the subtree rooted at this node, making sure
-// no nodes in the subtree exceed maxItems items. Should an equivalent item be
-// be found/replaced by insert, it will be returned.
-func (n *node) insert(item Item, maxItems int) Item {
- i, found := n.items.find(item)
- if found {
- out := n.items[i]
- n.items[i] = item
- return out
- }
- if len(n.children) == 0 {
- n.items.insertAt(i, item)
- return nil
- }
- if n.maybeSplitChild(i, maxItems) {
- inTree := n.items[i]
- switch {
- case item.Less(inTree):
- // no change, we want first split node
- case inTree.Less(item):
- i++ // we want second split node
- default:
- out := n.items[i]
- n.items[i] = item
- return out
- }
- }
- return n.mutableChild(i).insert(item, maxItems)
-}
-
-// get finds the given key in the subtree and returns it.
-func (n *node) get(key Item) Item {
- i, found := n.items.find(key)
- if found {
- return n.items[i]
- } else if len(n.children) > 0 {
- return n.children[i].get(key)
- }
- return nil
-}
-
-// min returns the first item in the subtree.
-func min(n *node) Item {
- if n == nil {
- return nil
- }
- for len(n.children) > 0 {
- n = n.children[0]
- }
- if len(n.items) == 0 {
- return nil
- }
- return n.items[0]
-}
-
-// max returns the last item in the subtree.
-func max(n *node) Item {
- if n == nil {
- return nil
- }
- for len(n.children) > 0 {
- n = n.children[len(n.children)-1]
- }
- if len(n.items) == 0 {
- return nil
- }
- return n.items[len(n.items)-1]
-}
-
-// toRemove details what item to remove in a node.remove call.
-type toRemove int
-
-const (
- removeItem toRemove = iota // removes the given item
- removeMin // removes smallest item in the subtree
- removeMax // removes largest item in the subtree
-)
-
-// remove removes an item from the subtree rooted at this node.
-func (n *node) remove(item Item, minItems int, typ toRemove) Item {
- var i int
- var found bool
- switch typ {
- case removeMax:
- if len(n.children) == 0 {
- return n.items.pop()
- }
- i = len(n.items)
- case removeMin:
- if len(n.children) == 0 {
- return n.items.removeAt(0)
- }
- i = 0
- case removeItem:
- i, found = n.items.find(item)
- if len(n.children) == 0 {
- if found {
- return n.items.removeAt(i)
- }
- return nil
- }
- default:
- panic("invalid type")
- }
- // If we get to here, we have children.
- if len(n.children[i].items) <= minItems {
- return n.growChildAndRemove(i, item, minItems, typ)
- }
- child := n.mutableChild(i)
- // Either we had enough items to begin with, or we've done some
- // merging/stealing, because we've got enough now and we're ready to return
- // stuff.
- if found {
- // The item exists at index 'i', and the child we've selected can give us a
- // predecessor, since if we've gotten here it's got > minItems items in it.
- out := n.items[i]
- // We use our special-case 'remove' call with typ=maxItem to pull the
- // predecessor of item i (the rightmost leaf of our immediate left child)
- // and set it into where we pulled the item from.
- n.items[i] = child.remove(nil, minItems, removeMax)
- return out
- }
- // Final recursive call. Once we're here, we know that the item isn't in this
- // node and that the child is big enough to remove from.
- return child.remove(item, minItems, typ)
-}
-
-// growChildAndRemove grows child 'i' to make sure it's possible to remove an
-// item from it while keeping it at minItems, then calls remove to actually
-// remove it.
-//
-// Most documentation says we have to do two sets of special casing:
-// 1) item is in this node
-// 2) item is in child
-// In both cases, we need to handle the two subcases:
-// A) node has enough values that it can spare one
-// B) node doesn't have enough values
-// For the latter, we have to check:
-// a) left sibling has node to spare
-// b) right sibling has node to spare
-// c) we must merge
-// To simplify our code here, we handle cases #1 and #2 the same:
-// If a node doesn't have enough items, we make sure it does (using a,b,c).
-// We then simply redo our remove call, and the second time (regardless of
-// whether we're in case 1 or 2), we'll have enough items and can guarantee
-// that we hit case A.
-func (n *node) growChildAndRemove(i int, item Item, minItems int, typ toRemove) Item {
- if i > 0 && len(n.children[i-1].items) > minItems {
- // Steal from left child
- child := n.mutableChild(i)
- stealFrom := n.mutableChild(i - 1)
- stolenItem := stealFrom.items.pop()
- child.items.insertAt(0, n.items[i-1])
- n.items[i-1] = stolenItem
- if len(stealFrom.children) > 0 {
- child.children.insertAt(0, stealFrom.children.pop())
- }
- } else if i < len(n.items) && len(n.children[i+1].items) > minItems {
- // steal from right child
- child := n.mutableChild(i)
- stealFrom := n.mutableChild(i + 1)
- stolenItem := stealFrom.items.removeAt(0)
- child.items = append(child.items, n.items[i])
- n.items[i] = stolenItem
- if len(stealFrom.children) > 0 {
- child.children = append(child.children, stealFrom.children.removeAt(0))
- }
- } else {
- if i >= len(n.items) {
- i--
- }
- child := n.mutableChild(i)
- // merge with right child
- mergeItem := n.items.removeAt(i)
- mergeChild := n.children.removeAt(i + 1).mutableFor(n.cow)
- child.items = append(child.items, mergeItem)
- child.items = append(child.items, mergeChild.items...)
- child.children = append(child.children, mergeChild.children...)
- n.cow.freeNode(mergeChild)
- }
- return n.remove(item, minItems, typ)
-}
-
-type direction int
-
-const (
- descend = direction(-1)
- ascend = direction(+1)
-)
-
-// iterate provides a simple method for iterating over elements in the tree.
-//
-// When ascending, the 'start' should be less than 'stop' and when descending,
-// the 'start' should be greater than 'stop'. Setting 'includeStart' to true
-// will force the iterator to include the first item when it equals 'start',
-// thus creating a "greaterOrEqual" or "lessThanEqual" rather than just a
-// "greaterThan" or "lessThan" queries.
-func (n *node) iterate(dir direction, start, stop Item, includeStart bool, hit bool, iter ItemIterator) (bool, bool) {
- var ok, found bool
- var index int
- switch dir {
- case ascend:
- if start != nil {
- index, _ = n.items.find(start)
- }
- for i := index; i < len(n.items); i++ {
- if len(n.children) > 0 {
- if hit, ok = n.children[i].iterate(dir, start, stop, includeStart, hit, iter); !ok {
- return hit, false
- }
- }
- if !includeStart && !hit && start != nil && !start.Less(n.items[i]) {
- hit = true
- continue
- }
- hit = true
- if stop != nil && !n.items[i].Less(stop) {
- return hit, false
- }
- if !iter(n.items[i]) {
- return hit, false
- }
- }
- if len(n.children) > 0 {
- if hit, ok = n.children[len(n.children)-1].iterate(dir, start, stop, includeStart, hit, iter); !ok {
- return hit, false
- }
- }
- case descend:
- if start != nil {
- index, found = n.items.find(start)
- if !found {
- index = index - 1
- }
- } else {
- index = len(n.items) - 1
- }
- for i := index; i >= 0; i-- {
- if start != nil && !n.items[i].Less(start) {
- if !includeStart || hit || start.Less(n.items[i]) {
- continue
- }
- }
- if len(n.children) > 0 {
- if hit, ok = n.children[i+1].iterate(dir, start, stop, includeStart, hit, iter); !ok {
- return hit, false
- }
- }
- if stop != nil && !stop.Less(n.items[i]) {
- return hit, false // continue
- }
- hit = true
- if !iter(n.items[i]) {
- return hit, false
- }
- }
- if len(n.children) > 0 {
- if hit, ok = n.children[0].iterate(dir, start, stop, includeStart, hit, iter); !ok {
- return hit, false
- }
- }
- }
- return hit, true
-}
-
-// Used for testing/debugging purposes.
-func (n *node) print(w io.Writer, level int) {
- fmt.Fprintf(w, "%sNODE:%v\n", strings.Repeat(" ", level), n.items)
- for _, c := range n.children {
- c.print(w, level+1)
- }
-}
-
-// BTree is an implementation of a B-Tree.
-//
-// BTree stores Item instances in an ordered structure, allowing easy insertion,
-// removal, and iteration.
-//
-// Write operations are not safe for concurrent mutation by multiple
-// goroutines, but Read operations are.
-type BTree struct {
- degree int
- length int
- root *node
- cow *copyOnWriteContext
-}
-
-// copyOnWriteContext pointers determine node ownership... a tree with a write
-// context equivalent to a node's write context is allowed to modify that node.
-// A tree whose write context does not match a node's is not allowed to modify
-// it, and must create a new, writable copy (IE: it's a Clone).
-//
-// When doing any write operation, we maintain the invariant that the current
-// node's context is equal to the context of the tree that requested the write.
-// We do this by, before we descend into any node, creating a copy with the
-// correct context if the contexts don't match.
-//
-// Since the node we're currently visiting on any write has the requesting
-// tree's context, that node is modifiable in place. Children of that node may
-// not share context, but before we descend into them, we'll make a mutable
-// copy.
-type copyOnWriteContext struct {
- freelist *FreeList
-}
-
-// Clone clones the btree, lazily. Clone should not be called concurrently,
-// but the original tree (t) and the new tree (t2) can be used concurrently
-// once the Clone call completes.
-//
-// The internal tree structure of b is marked read-only and shared between t and
-// t2. Writes to both t and t2 use copy-on-write logic, creating new nodes
-// whenever one of b's original nodes would have been modified. Read operations
-// should have no performance degredation. Write operations for both t and t2
-// will initially experience minor slow-downs caused by additional allocs and
-// copies due to the aforementioned copy-on-write logic, but should converge to
-// the original performance characteristics of the original tree.
-func (t *BTree) Clone() (t2 *BTree) {
- // Create two entirely new copy-on-write contexts.
- // This operation effectively creates three trees:
- // the original, shared nodes (old b.cow)
- // the new b.cow nodes
- // the new out.cow nodes
- cow1, cow2 := *t.cow, *t.cow
- out := *t
- t.cow = &cow1
- out.cow = &cow2
- return &out
-}
-
-// maxItems returns the max number of items to allow per node.
-func (t *BTree) maxItems() int {
- return t.degree*2 - 1
-}
-
-// minItems returns the min number of items to allow per node (ignored for the
-// root node).
-func (t *BTree) minItems() int {
- return t.degree - 1
-}
-
-func (c *copyOnWriteContext) newNode() (n *node) {
- n = c.freelist.newNode()
- n.cow = c
- return
-}
-
-type freeType int
-
-const (
- ftFreelistFull freeType = iota // node was freed (available for GC, not stored in freelist)
- ftStored // node was stored in the freelist for later use
- ftNotOwned // node was ignored by COW, since it's owned by another one
-)
-
-// freeNode frees a node within a given COW context, if it's owned by that
-// context. It returns what happened to the node (see freeType const
-// documentation).
-func (c *copyOnWriteContext) freeNode(n *node) freeType {
- if n.cow == c {
- // clear to allow GC
- n.items.truncate(0)
- n.children.truncate(0)
- n.cow = nil
- if c.freelist.freeNode(n) {
- return ftStored
- } else {
- return ftFreelistFull
- }
- } else {
- return ftNotOwned
- }
-}
-
-// ReplaceOrInsert adds the given item to the tree. If an item in the tree
-// already equals the given one, it is removed from the tree and returned.
-// Otherwise, nil is returned.
-//
-// nil cannot be added to the tree (will panic).
-func (t *BTree) ReplaceOrInsert(item Item) Item {
- if item == nil {
- panic("nil item being added to BTree")
- }
- if t.root == nil {
- t.root = t.cow.newNode()
- t.root.items = append(t.root.items, item)
- t.length++
- return nil
- } else {
- t.root = t.root.mutableFor(t.cow)
- if len(t.root.items) >= t.maxItems() {
- item2, second := t.root.split(t.maxItems() / 2)
- oldroot := t.root
- t.root = t.cow.newNode()
- t.root.items = append(t.root.items, item2)
- t.root.children = append(t.root.children, oldroot, second)
- }
- }
- out := t.root.insert(item, t.maxItems())
- if out == nil {
- t.length++
- }
- return out
-}
-
-// Delete removes an item equal to the passed in item from the tree, returning
-// it. If no such item exists, returns nil.
-func (t *BTree) Delete(item Item) Item {
- return t.deleteItem(item, removeItem)
-}
-
-// DeleteMin removes the smallest item in the tree and returns it.
-// If no such item exists, returns nil.
-func (t *BTree) DeleteMin() Item {
- return t.deleteItem(nil, removeMin)
-}
-
-// DeleteMax removes the largest item in the tree and returns it.
-// If no such item exists, returns nil.
-func (t *BTree) DeleteMax() Item {
- return t.deleteItem(nil, removeMax)
-}
-
-func (t *BTree) deleteItem(item Item, typ toRemove) Item {
- if t.root == nil || len(t.root.items) == 0 {
- return nil
- }
- t.root = t.root.mutableFor(t.cow)
- out := t.root.remove(item, t.minItems(), typ)
- if len(t.root.items) == 0 && len(t.root.children) > 0 {
- oldroot := t.root
- t.root = t.root.children[0]
- t.cow.freeNode(oldroot)
- }
- if out != nil {
- t.length--
- }
- return out
-}
-
-// AscendRange calls the iterator for every value in the tree within the range
-// [greaterOrEqual, lessThan), until iterator returns false.
-func (t *BTree) AscendRange(greaterOrEqual, lessThan Item, iterator ItemIterator) {
- if t.root == nil {
- return
- }
- t.root.iterate(ascend, greaterOrEqual, lessThan, true, false, iterator)
-}
-
-// AscendLessThan calls the iterator for every value in the tree within the range
-// [first, pivot), until iterator returns false.
-func (t *BTree) AscendLessThan(pivot Item, iterator ItemIterator) {
- if t.root == nil {
- return
- }
- t.root.iterate(ascend, nil, pivot, false, false, iterator)
-}
-
-// AscendGreaterOrEqual calls the iterator for every value in the tree within
-// the range [pivot, last], until iterator returns false.
-func (t *BTree) AscendGreaterOrEqual(pivot Item, iterator ItemIterator) {
- if t.root == nil {
- return
- }
- t.root.iterate(ascend, pivot, nil, true, false, iterator)
-}
-
-// Ascend calls the iterator for every value in the tree within the range
-// [first, last], until iterator returns false.
-func (t *BTree) Ascend(iterator ItemIterator) {
- if t.root == nil {
- return
- }
- t.root.iterate(ascend, nil, nil, false, false, iterator)
-}
-
-// DescendRange calls the iterator for every value in the tree within the range
-// [lessOrEqual, greaterThan), until iterator returns false.
-func (t *BTree) DescendRange(lessOrEqual, greaterThan Item, iterator ItemIterator) {
- if t.root == nil {
- return
- }
- t.root.iterate(descend, lessOrEqual, greaterThan, true, false, iterator)
-}
-
-// DescendLessOrEqual calls the iterator for every value in the tree within the range
-// [pivot, first], until iterator returns false.
-func (t *BTree) DescendLessOrEqual(pivot Item, iterator ItemIterator) {
- if t.root == nil {
- return
- }
- t.root.iterate(descend, pivot, nil, true, false, iterator)
-}
-
-// DescendGreaterThan calls the iterator for every value in the tree within
-// the range [last, pivot), until iterator returns false.
-func (t *BTree) DescendGreaterThan(pivot Item, iterator ItemIterator) {
- if t.root == nil {
- return
- }
- t.root.iterate(descend, nil, pivot, false, false, iterator)
-}
-
-// Descend calls the iterator for every value in the tree within the range
-// [last, first], until iterator returns false.
-func (t *BTree) Descend(iterator ItemIterator) {
- if t.root == nil {
- return
- }
- t.root.iterate(descend, nil, nil, false, false, iterator)
-}
-
-// Get looks for the key item in the tree, returning it. It returns nil if
-// unable to find that item.
-func (t *BTree) Get(key Item) Item {
- if t.root == nil {
- return nil
- }
- return t.root.get(key)
-}
-
-// Min returns the smallest item in the tree, or nil if the tree is empty.
-func (t *BTree) Min() Item {
- return min(t.root)
-}
-
-// Max returns the largest item in the tree, or nil if the tree is empty.
-func (t *BTree) Max() Item {
- return max(t.root)
-}
-
-// Has returns true if the given key is in the tree.
-func (t *BTree) Has(key Item) bool {
- return t.Get(key) != nil
-}
-
-// Len returns the number of items currently in the tree.
-func (t *BTree) Len() int {
- return t.length
-}
-
-// Clear removes all items from the btree. If addNodesToFreelist is true,
-// t's nodes are added to its freelist as part of this call, until the freelist
-// is full. Otherwise, the root node is simply dereferenced and the subtree
-// left to Go's normal GC processes.
-//
-// This can be much faster
-// than calling Delete on all elements, because that requires finding/removing
-// each element in the tree and updating the tree accordingly. It also is
-// somewhat faster than creating a new tree to replace the old one, because
-// nodes from the old tree are reclaimed into the freelist for use by the new
-// one, instead of being lost to the garbage collector.
-//
-// This call takes:
-// O(1): when addNodesToFreelist is false, this is a single operation.
-// O(1): when the freelist is already full, it breaks out immediately
-// O(freelist size): when the freelist is empty and the nodes are all owned
-// by this tree, nodes are added to the freelist until full.
-// O(tree size): when all nodes are owned by another tree, all nodes are
-// iterated over looking for nodes to add to the freelist, and due to
-// ownership, none are.
-func (t *BTree) Clear(addNodesToFreelist bool) {
- if t.root != nil && addNodesToFreelist {
- t.root.reset(t.cow)
- }
- t.root, t.length = nil, 0
-}
-
-// reset returns a subtree to the freelist. It breaks out immediately if the
-// freelist is full, since the only benefit of iterating is to fill that
-// freelist up. Returns true if parent reset call should continue.
-func (n *node) reset(c *copyOnWriteContext) bool {
- for _, child := range n.children {
- if !child.reset(c) {
- return false
- }
- }
- return c.freeNode(n) != ftFreelistFull
-}
-
-// Int implements the Item interface for integers.
-type Int int
-
-// Less returns true if int(a) < int(b).
-func (a Int) Less(b Item) bool {
- return a < b.(Int)
-}
diff --git a/vendor/github.com/google/btree/btree_generic.go b/vendor/github.com/google/btree/btree_generic.go
deleted file mode 100644
index e44a0f4880..0000000000
--- a/vendor/github.com/google/btree/btree_generic.go
+++ /dev/null
@@ -1,1083 +0,0 @@
-// Copyright 2014-2022 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-//go:build go1.18
-// +build go1.18
-
-// In Go 1.18 and beyond, a BTreeG generic is created, and BTree is a specific
-// instantiation of that generic for the Item interface, with a backwards-
-// compatible API. Before go1.18, generics are not supported,
-// and BTree is just an implementation based around the Item interface.
-
-// Package btree implements in-memory B-Trees of arbitrary degree.
-//
-// btree implements an in-memory B-Tree for use as an ordered data structure.
-// It is not meant for persistent storage solutions.
-//
-// It has a flatter structure than an equivalent red-black or other binary tree,
-// which in some cases yields better memory usage and/or performance.
-// See some discussion on the matter here:
-// http://google-opensource.blogspot.com/2013/01/c-containers-that-save-memory-and-time.html
-// Note, though, that this project is in no way related to the C++ B-Tree
-// implementation written about there.
-//
-// Within this tree, each node contains a slice of items and a (possibly nil)
-// slice of children. For basic numeric values or raw structs, this can cause
-// efficiency differences when compared to equivalent C++ template code that
-// stores values in arrays within the node:
-// * Due to the overhead of storing values as interfaces (each
-// value needs to be stored as the value itself, then 2 words for the
-// interface pointing to that value and its type), resulting in higher
-// memory use.
-// * Since interfaces can point to values anywhere in memory, values are
-// most likely not stored in contiguous blocks, resulting in a higher
-// number of cache misses.
-// These issues don't tend to matter, though, when working with strings or other
-// heap-allocated structures, since C++-equivalent structures also must store
-// pointers and also distribute their values across the heap.
-//
-// This implementation is designed to be a drop-in replacement to gollrb.LLRB
-// trees, (http://github.com/petar/gollrb), an excellent and probably the most
-// widely used ordered tree implementation in the Go ecosystem currently.
-// Its functions, therefore, exactly mirror those of
-// llrb.LLRB where possible. Unlike gollrb, though, we currently don't
-// support storing multiple equivalent values.
-//
-// There are two implementations; those suffixed with 'G' are generics, usable
-// for any type, and require a passed-in "less" function to define their ordering.
-// Those without this prefix are specific to the 'Item' interface, and use
-// its 'Less' function for ordering.
-package btree
-
-import (
- "fmt"
- "io"
- "sort"
- "strings"
- "sync"
-)
-
-// Item represents a single object in the tree.
-type Item interface {
- // Less tests whether the current item is less than the given argument.
- //
- // This must provide a strict weak ordering.
- // If !a.Less(b) && !b.Less(a), we treat this to mean a == b (i.e. we can only
- // hold one of either a or b in the tree).
- Less(than Item) bool
-}
-
-const (
- DefaultFreeListSize = 32
-)
-
-// FreeListG represents a free list of btree nodes. By default each
-// BTree has its own FreeList, but multiple BTrees can share the same
-// FreeList, in particular when they're created with Clone.
-// Two Btrees using the same freelist are safe for concurrent write access.
-type FreeListG[T any] struct {
- mu sync.Mutex
- freelist []*node[T]
-}
-
-// NewFreeListG creates a new free list.
-// size is the maximum size of the returned free list.
-func NewFreeListG[T any](size int) *FreeListG[T] {
- return &FreeListG[T]{freelist: make([]*node[T], 0, size)}
-}
-
-func (f *FreeListG[T]) newNode() (n *node[T]) {
- f.mu.Lock()
- index := len(f.freelist) - 1
- if index < 0 {
- f.mu.Unlock()
- return new(node[T])
- }
- n = f.freelist[index]
- f.freelist[index] = nil
- f.freelist = f.freelist[:index]
- f.mu.Unlock()
- return
-}
-
-func (f *FreeListG[T]) freeNode(n *node[T]) (out bool) {
- f.mu.Lock()
- if len(f.freelist) < cap(f.freelist) {
- f.freelist = append(f.freelist, n)
- out = true
- }
- f.mu.Unlock()
- return
-}
-
-// ItemIteratorG allows callers of {A/De}scend* to iterate in-order over portions of
-// the tree. When this function returns false, iteration will stop and the
-// associated Ascend* function will immediately return.
-type ItemIteratorG[T any] func(item T) bool
-
-// Ordered represents the set of types for which the '<' operator work.
-type Ordered interface {
- ~int | ~int8 | ~int16 | ~int32 | ~int64 | ~uint | ~uint8 | ~uint16 | ~uint32 | ~uint64 | ~float32 | ~float64 | ~string
-}
-
-// Less[T] returns a default LessFunc that uses the '<' operator for types that support it.
-func Less[T Ordered]() LessFunc[T] {
- return func(a, b T) bool { return a < b }
-}
-
-// NewOrderedG creates a new B-Tree for ordered types.
-func NewOrderedG[T Ordered](degree int) *BTreeG[T] {
- return NewG[T](degree, Less[T]())
-}
-
-// NewG creates a new B-Tree with the given degree.
-//
-// NewG(2), for example, will create a 2-3-4 tree (each node contains 1-3 items
-// and 2-4 children).
-//
-// The passed-in LessFunc determines how objects of type T are ordered.
-func NewG[T any](degree int, less LessFunc[T]) *BTreeG[T] {
- return NewWithFreeListG(degree, less, NewFreeListG[T](DefaultFreeListSize))
-}
-
-// NewWithFreeListG creates a new B-Tree that uses the given node free list.
-func NewWithFreeListG[T any](degree int, less LessFunc[T], f *FreeListG[T]) *BTreeG[T] {
- if degree <= 1 {
- panic("bad degree")
- }
- return &BTreeG[T]{
- degree: degree,
- cow: ©OnWriteContext[T]{freelist: f, less: less},
- }
-}
-
-// items stores items in a node.
-type items[T any] []T
-
-// insertAt inserts a value into the given index, pushing all subsequent values
-// forward.
-func (s *items[T]) insertAt(index int, item T) {
- var zero T
- *s = append(*s, zero)
- if index < len(*s) {
- copy((*s)[index+1:], (*s)[index:])
- }
- (*s)[index] = item
-}
-
-// removeAt removes a value at a given index, pulling all subsequent values
-// back.
-func (s *items[T]) removeAt(index int) T {
- item := (*s)[index]
- copy((*s)[index:], (*s)[index+1:])
- var zero T
- (*s)[len(*s)-1] = zero
- *s = (*s)[:len(*s)-1]
- return item
-}
-
-// pop removes and returns the last element in the list.
-func (s *items[T]) pop() (out T) {
- index := len(*s) - 1
- out = (*s)[index]
- var zero T
- (*s)[index] = zero
- *s = (*s)[:index]
- return
-}
-
-// truncate truncates this instance at index so that it contains only the
-// first index items. index must be less than or equal to length.
-func (s *items[T]) truncate(index int) {
- var toClear items[T]
- *s, toClear = (*s)[:index], (*s)[index:]
- var zero T
- for i := 0; i < len(toClear); i++ {
- toClear[i] = zero
- }
-}
-
-// find returns the index where the given item should be inserted into this
-// list. 'found' is true if the item already exists in the list at the given
-// index.
-func (s items[T]) find(item T, less func(T, T) bool) (index int, found bool) {
- i := sort.Search(len(s), func(i int) bool {
- return less(item, s[i])
- })
- if i > 0 && !less(s[i-1], item) {
- return i - 1, true
- }
- return i, false
-}
-
-// node is an internal node in a tree.
-//
-// It must at all times maintain the invariant that either
-// * len(children) == 0, len(items) unconstrained
-// * len(children) == len(items) + 1
-type node[T any] struct {
- items items[T]
- children items[*node[T]]
- cow *copyOnWriteContext[T]
-}
-
-func (n *node[T]) mutableFor(cow *copyOnWriteContext[T]) *node[T] {
- if n.cow == cow {
- return n
- }
- out := cow.newNode()
- if cap(out.items) >= len(n.items) {
- out.items = out.items[:len(n.items)]
- } else {
- out.items = make(items[T], len(n.items), cap(n.items))
- }
- copy(out.items, n.items)
- // Copy children
- if cap(out.children) >= len(n.children) {
- out.children = out.children[:len(n.children)]
- } else {
- out.children = make(items[*node[T]], len(n.children), cap(n.children))
- }
- copy(out.children, n.children)
- return out
-}
-
-func (n *node[T]) mutableChild(i int) *node[T] {
- c := n.children[i].mutableFor(n.cow)
- n.children[i] = c
- return c
-}
-
-// split splits the given node at the given index. The current node shrinks,
-// and this function returns the item that existed at that index and a new node
-// containing all items/children after it.
-func (n *node[T]) split(i int) (T, *node[T]) {
- item := n.items[i]
- next := n.cow.newNode()
- next.items = append(next.items, n.items[i+1:]...)
- n.items.truncate(i)
- if len(n.children) > 0 {
- next.children = append(next.children, n.children[i+1:]...)
- n.children.truncate(i + 1)
- }
- return item, next
-}
-
-// maybeSplitChild checks if a child should be split, and if so splits it.
-// Returns whether or not a split occurred.
-func (n *node[T]) maybeSplitChild(i, maxItems int) bool {
- if len(n.children[i].items) < maxItems {
- return false
- }
- first := n.mutableChild(i)
- item, second := first.split(maxItems / 2)
- n.items.insertAt(i, item)
- n.children.insertAt(i+1, second)
- return true
-}
-
-// insert inserts an item into the subtree rooted at this node, making sure
-// no nodes in the subtree exceed maxItems items. Should an equivalent item be
-// be found/replaced by insert, it will be returned.
-func (n *node[T]) insert(item T, maxItems int) (_ T, _ bool) {
- i, found := n.items.find(item, n.cow.less)
- if found {
- out := n.items[i]
- n.items[i] = item
- return out, true
- }
- if len(n.children) == 0 {
- n.items.insertAt(i, item)
- return
- }
- if n.maybeSplitChild(i, maxItems) {
- inTree := n.items[i]
- switch {
- case n.cow.less(item, inTree):
- // no change, we want first split node
- case n.cow.less(inTree, item):
- i++ // we want second split node
- default:
- out := n.items[i]
- n.items[i] = item
- return out, true
- }
- }
- return n.mutableChild(i).insert(item, maxItems)
-}
-
-// get finds the given key in the subtree and returns it.
-func (n *node[T]) get(key T) (_ T, _ bool) {
- i, found := n.items.find(key, n.cow.less)
- if found {
- return n.items[i], true
- } else if len(n.children) > 0 {
- return n.children[i].get(key)
- }
- return
-}
-
-// min returns the first item in the subtree.
-func min[T any](n *node[T]) (_ T, found bool) {
- if n == nil {
- return
- }
- for len(n.children) > 0 {
- n = n.children[0]
- }
- if len(n.items) == 0 {
- return
- }
- return n.items[0], true
-}
-
-// max returns the last item in the subtree.
-func max[T any](n *node[T]) (_ T, found bool) {
- if n == nil {
- return
- }
- for len(n.children) > 0 {
- n = n.children[len(n.children)-1]
- }
- if len(n.items) == 0 {
- return
- }
- return n.items[len(n.items)-1], true
-}
-
-// toRemove details what item to remove in a node.remove call.
-type toRemove int
-
-const (
- removeItem toRemove = iota // removes the given item
- removeMin // removes smallest item in the subtree
- removeMax // removes largest item in the subtree
-)
-
-// remove removes an item from the subtree rooted at this node.
-func (n *node[T]) remove(item T, minItems int, typ toRemove) (_ T, _ bool) {
- var i int
- var found bool
- switch typ {
- case removeMax:
- if len(n.children) == 0 {
- return n.items.pop(), true
- }
- i = len(n.items)
- case removeMin:
- if len(n.children) == 0 {
- return n.items.removeAt(0), true
- }
- i = 0
- case removeItem:
- i, found = n.items.find(item, n.cow.less)
- if len(n.children) == 0 {
- if found {
- return n.items.removeAt(i), true
- }
- return
- }
- default:
- panic("invalid type")
- }
- // If we get to here, we have children.
- if len(n.children[i].items) <= minItems {
- return n.growChildAndRemove(i, item, minItems, typ)
- }
- child := n.mutableChild(i)
- // Either we had enough items to begin with, or we've done some
- // merging/stealing, because we've got enough now and we're ready to return
- // stuff.
- if found {
- // The item exists at index 'i', and the child we've selected can give us a
- // predecessor, since if we've gotten here it's got > minItems items in it.
- out := n.items[i]
- // We use our special-case 'remove' call with typ=maxItem to pull the
- // predecessor of item i (the rightmost leaf of our immediate left child)
- // and set it into where we pulled the item from.
- var zero T
- n.items[i], _ = child.remove(zero, minItems, removeMax)
- return out, true
- }
- // Final recursive call. Once we're here, we know that the item isn't in this
- // node and that the child is big enough to remove from.
- return child.remove(item, minItems, typ)
-}
-
-// growChildAndRemove grows child 'i' to make sure it's possible to remove an
-// item from it while keeping it at minItems, then calls remove to actually
-// remove it.
-//
-// Most documentation says we have to do two sets of special casing:
-// 1) item is in this node
-// 2) item is in child
-// In both cases, we need to handle the two subcases:
-// A) node has enough values that it can spare one
-// B) node doesn't have enough values
-// For the latter, we have to check:
-// a) left sibling has node to spare
-// b) right sibling has node to spare
-// c) we must merge
-// To simplify our code here, we handle cases #1 and #2 the same:
-// If a node doesn't have enough items, we make sure it does (using a,b,c).
-// We then simply redo our remove call, and the second time (regardless of
-// whether we're in case 1 or 2), we'll have enough items and can guarantee
-// that we hit case A.
-func (n *node[T]) growChildAndRemove(i int, item T, minItems int, typ toRemove) (T, bool) {
- if i > 0 && len(n.children[i-1].items) > minItems {
- // Steal from left child
- child := n.mutableChild(i)
- stealFrom := n.mutableChild(i - 1)
- stolenItem := stealFrom.items.pop()
- child.items.insertAt(0, n.items[i-1])
- n.items[i-1] = stolenItem
- if len(stealFrom.children) > 0 {
- child.children.insertAt(0, stealFrom.children.pop())
- }
- } else if i < len(n.items) && len(n.children[i+1].items) > minItems {
- // steal from right child
- child := n.mutableChild(i)
- stealFrom := n.mutableChild(i + 1)
- stolenItem := stealFrom.items.removeAt(0)
- child.items = append(child.items, n.items[i])
- n.items[i] = stolenItem
- if len(stealFrom.children) > 0 {
- child.children = append(child.children, stealFrom.children.removeAt(0))
- }
- } else {
- if i >= len(n.items) {
- i--
- }
- child := n.mutableChild(i)
- // merge with right child
- mergeItem := n.items.removeAt(i)
- mergeChild := n.children.removeAt(i + 1)
- child.items = append(child.items, mergeItem)
- child.items = append(child.items, mergeChild.items...)
- child.children = append(child.children, mergeChild.children...)
- n.cow.freeNode(mergeChild)
- }
- return n.remove(item, minItems, typ)
-}
-
-type direction int
-
-const (
- descend = direction(-1)
- ascend = direction(+1)
-)
-
-type optionalItem[T any] struct {
- item T
- valid bool
-}
-
-func optional[T any](item T) optionalItem[T] {
- return optionalItem[T]{item: item, valid: true}
-}
-func empty[T any]() optionalItem[T] {
- return optionalItem[T]{}
-}
-
-// iterate provides a simple method for iterating over elements in the tree.
-//
-// When ascending, the 'start' should be less than 'stop' and when descending,
-// the 'start' should be greater than 'stop'. Setting 'includeStart' to true
-// will force the iterator to include the first item when it equals 'start',
-// thus creating a "greaterOrEqual" or "lessThanEqual" rather than just a
-// "greaterThan" or "lessThan" queries.
-func (n *node[T]) iterate(dir direction, start, stop optionalItem[T], includeStart bool, hit bool, iter ItemIteratorG[T]) (bool, bool) {
- var ok, found bool
- var index int
- switch dir {
- case ascend:
- if start.valid {
- index, _ = n.items.find(start.item, n.cow.less)
- }
- for i := index; i < len(n.items); i++ {
- if len(n.children) > 0 {
- if hit, ok = n.children[i].iterate(dir, start, stop, includeStart, hit, iter); !ok {
- return hit, false
- }
- }
- if !includeStart && !hit && start.valid && !n.cow.less(start.item, n.items[i]) {
- hit = true
- continue
- }
- hit = true
- if stop.valid && !n.cow.less(n.items[i], stop.item) {
- return hit, false
- }
- if !iter(n.items[i]) {
- return hit, false
- }
- }
- if len(n.children) > 0 {
- if hit, ok = n.children[len(n.children)-1].iterate(dir, start, stop, includeStart, hit, iter); !ok {
- return hit, false
- }
- }
- case descend:
- if start.valid {
- index, found = n.items.find(start.item, n.cow.less)
- if !found {
- index = index - 1
- }
- } else {
- index = len(n.items) - 1
- }
- for i := index; i >= 0; i-- {
- if start.valid && !n.cow.less(n.items[i], start.item) {
- if !includeStart || hit || n.cow.less(start.item, n.items[i]) {
- continue
- }
- }
- if len(n.children) > 0 {
- if hit, ok = n.children[i+1].iterate(dir, start, stop, includeStart, hit, iter); !ok {
- return hit, false
- }
- }
- if stop.valid && !n.cow.less(stop.item, n.items[i]) {
- return hit, false // continue
- }
- hit = true
- if !iter(n.items[i]) {
- return hit, false
- }
- }
- if len(n.children) > 0 {
- if hit, ok = n.children[0].iterate(dir, start, stop, includeStart, hit, iter); !ok {
- return hit, false
- }
- }
- }
- return hit, true
-}
-
-// print is used for testing/debugging purposes.
-func (n *node[T]) print(w io.Writer, level int) {
- fmt.Fprintf(w, "%sNODE:%v\n", strings.Repeat(" ", level), n.items)
- for _, c := range n.children {
- c.print(w, level+1)
- }
-}
-
-// BTreeG is a generic implementation of a B-Tree.
-//
-// BTreeG stores items of type T in an ordered structure, allowing easy insertion,
-// removal, and iteration.
-//
-// Write operations are not safe for concurrent mutation by multiple
-// goroutines, but Read operations are.
-type BTreeG[T any] struct {
- degree int
- length int
- root *node[T]
- cow *copyOnWriteContext[T]
-}
-
-// LessFunc[T] determines how to order a type 'T'. It should implement a strict
-// ordering, and should return true if within that ordering, 'a' < 'b'.
-type LessFunc[T any] func(a, b T) bool
-
-// copyOnWriteContext pointers determine node ownership... a tree with a write
-// context equivalent to a node's write context is allowed to modify that node.
-// A tree whose write context does not match a node's is not allowed to modify
-// it, and must create a new, writable copy (IE: it's a Clone).
-//
-// When doing any write operation, we maintain the invariant that the current
-// node's context is equal to the context of the tree that requested the write.
-// We do this by, before we descend into any node, creating a copy with the
-// correct context if the contexts don't match.
-//
-// Since the node we're currently visiting on any write has the requesting
-// tree's context, that node is modifiable in place. Children of that node may
-// not share context, but before we descend into them, we'll make a mutable
-// copy.
-type copyOnWriteContext[T any] struct {
- freelist *FreeListG[T]
- less LessFunc[T]
-}
-
-// Clone clones the btree, lazily. Clone should not be called concurrently,
-// but the original tree (t) and the new tree (t2) can be used concurrently
-// once the Clone call completes.
-//
-// The internal tree structure of b is marked read-only and shared between t and
-// t2. Writes to both t and t2 use copy-on-write logic, creating new nodes
-// whenever one of b's original nodes would have been modified. Read operations
-// should have no performance degredation. Write operations for both t and t2
-// will initially experience minor slow-downs caused by additional allocs and
-// copies due to the aforementioned copy-on-write logic, but should converge to
-// the original performance characteristics of the original tree.
-func (t *BTreeG[T]) Clone() (t2 *BTreeG[T]) {
- // Create two entirely new copy-on-write contexts.
- // This operation effectively creates three trees:
- // the original, shared nodes (old b.cow)
- // the new b.cow nodes
- // the new out.cow nodes
- cow1, cow2 := *t.cow, *t.cow
- out := *t
- t.cow = &cow1
- out.cow = &cow2
- return &out
-}
-
-// maxItems returns the max number of items to allow per node.
-func (t *BTreeG[T]) maxItems() int {
- return t.degree*2 - 1
-}
-
-// minItems returns the min number of items to allow per node (ignored for the
-// root node).
-func (t *BTreeG[T]) minItems() int {
- return t.degree - 1
-}
-
-func (c *copyOnWriteContext[T]) newNode() (n *node[T]) {
- n = c.freelist.newNode()
- n.cow = c
- return
-}
-
-type freeType int
-
-const (
- ftFreelistFull freeType = iota // node was freed (available for GC, not stored in freelist)
- ftStored // node was stored in the freelist for later use
- ftNotOwned // node was ignored by COW, since it's owned by another one
-)
-
-// freeNode frees a node within a given COW context, if it's owned by that
-// context. It returns what happened to the node (see freeType const
-// documentation).
-func (c *copyOnWriteContext[T]) freeNode(n *node[T]) freeType {
- if n.cow == c {
- // clear to allow GC
- n.items.truncate(0)
- n.children.truncate(0)
- n.cow = nil
- if c.freelist.freeNode(n) {
- return ftStored
- } else {
- return ftFreelistFull
- }
- } else {
- return ftNotOwned
- }
-}
-
-// ReplaceOrInsert adds the given item to the tree. If an item in the tree
-// already equals the given one, it is removed from the tree and returned,
-// and the second return value is true. Otherwise, (zeroValue, false)
-//
-// nil cannot be added to the tree (will panic).
-func (t *BTreeG[T]) ReplaceOrInsert(item T) (_ T, _ bool) {
- if t.root == nil {
- t.root = t.cow.newNode()
- t.root.items = append(t.root.items, item)
- t.length++
- return
- } else {
- t.root = t.root.mutableFor(t.cow)
- if len(t.root.items) >= t.maxItems() {
- item2, second := t.root.split(t.maxItems() / 2)
- oldroot := t.root
- t.root = t.cow.newNode()
- t.root.items = append(t.root.items, item2)
- t.root.children = append(t.root.children, oldroot, second)
- }
- }
- out, outb := t.root.insert(item, t.maxItems())
- if !outb {
- t.length++
- }
- return out, outb
-}
-
-// Delete removes an item equal to the passed in item from the tree, returning
-// it. If no such item exists, returns (zeroValue, false).
-func (t *BTreeG[T]) Delete(item T) (T, bool) {
- return t.deleteItem(item, removeItem)
-}
-
-// DeleteMin removes the smallest item in the tree and returns it.
-// If no such item exists, returns (zeroValue, false).
-func (t *BTreeG[T]) DeleteMin() (T, bool) {
- var zero T
- return t.deleteItem(zero, removeMin)
-}
-
-// DeleteMax removes the largest item in the tree and returns it.
-// If no such item exists, returns (zeroValue, false).
-func (t *BTreeG[T]) DeleteMax() (T, bool) {
- var zero T
- return t.deleteItem(zero, removeMax)
-}
-
-func (t *BTreeG[T]) deleteItem(item T, typ toRemove) (_ T, _ bool) {
- if t.root == nil || len(t.root.items) == 0 {
- return
- }
- t.root = t.root.mutableFor(t.cow)
- out, outb := t.root.remove(item, t.minItems(), typ)
- if len(t.root.items) == 0 && len(t.root.children) > 0 {
- oldroot := t.root
- t.root = t.root.children[0]
- t.cow.freeNode(oldroot)
- }
- if outb {
- t.length--
- }
- return out, outb
-}
-
-// AscendRange calls the iterator for every value in the tree within the range
-// [greaterOrEqual, lessThan), until iterator returns false.
-func (t *BTreeG[T]) AscendRange(greaterOrEqual, lessThan T, iterator ItemIteratorG[T]) {
- if t.root == nil {
- return
- }
- t.root.iterate(ascend, optional[T](greaterOrEqual), optional[T](lessThan), true, false, iterator)
-}
-
-// AscendLessThan calls the iterator for every value in the tree within the range
-// [first, pivot), until iterator returns false.
-func (t *BTreeG[T]) AscendLessThan(pivot T, iterator ItemIteratorG[T]) {
- if t.root == nil {
- return
- }
- t.root.iterate(ascend, empty[T](), optional(pivot), false, false, iterator)
-}
-
-// AscendGreaterOrEqual calls the iterator for every value in the tree within
-// the range [pivot, last], until iterator returns false.
-func (t *BTreeG[T]) AscendGreaterOrEqual(pivot T, iterator ItemIteratorG[T]) {
- if t.root == nil {
- return
- }
- t.root.iterate(ascend, optional[T](pivot), empty[T](), true, false, iterator)
-}
-
-// Ascend calls the iterator for every value in the tree within the range
-// [first, last], until iterator returns false.
-func (t *BTreeG[T]) Ascend(iterator ItemIteratorG[T]) {
- if t.root == nil {
- return
- }
- t.root.iterate(ascend, empty[T](), empty[T](), false, false, iterator)
-}
-
-// DescendRange calls the iterator for every value in the tree within the range
-// [lessOrEqual, greaterThan), until iterator returns false.
-func (t *BTreeG[T]) DescendRange(lessOrEqual, greaterThan T, iterator ItemIteratorG[T]) {
- if t.root == nil {
- return
- }
- t.root.iterate(descend, optional[T](lessOrEqual), optional[T](greaterThan), true, false, iterator)
-}
-
-// DescendLessOrEqual calls the iterator for every value in the tree within the range
-// [pivot, first], until iterator returns false.
-func (t *BTreeG[T]) DescendLessOrEqual(pivot T, iterator ItemIteratorG[T]) {
- if t.root == nil {
- return
- }
- t.root.iterate(descend, optional[T](pivot), empty[T](), true, false, iterator)
-}
-
-// DescendGreaterThan calls the iterator for every value in the tree within
-// the range [last, pivot), until iterator returns false.
-func (t *BTreeG[T]) DescendGreaterThan(pivot T, iterator ItemIteratorG[T]) {
- if t.root == nil {
- return
- }
- t.root.iterate(descend, empty[T](), optional[T](pivot), false, false, iterator)
-}
-
-// Descend calls the iterator for every value in the tree within the range
-// [last, first], until iterator returns false.
-func (t *BTreeG[T]) Descend(iterator ItemIteratorG[T]) {
- if t.root == nil {
- return
- }
- t.root.iterate(descend, empty[T](), empty[T](), false, false, iterator)
-}
-
-// Get looks for the key item in the tree, returning it. It returns
-// (zeroValue, false) if unable to find that item.
-func (t *BTreeG[T]) Get(key T) (_ T, _ bool) {
- if t.root == nil {
- return
- }
- return t.root.get(key)
-}
-
-// Min returns the smallest item in the tree, or (zeroValue, false) if the tree is empty.
-func (t *BTreeG[T]) Min() (_ T, _ bool) {
- return min(t.root)
-}
-
-// Max returns the largest item in the tree, or (zeroValue, false) if the tree is empty.
-func (t *BTreeG[T]) Max() (_ T, _ bool) {
- return max(t.root)
-}
-
-// Has returns true if the given key is in the tree.
-func (t *BTreeG[T]) Has(key T) bool {
- _, ok := t.Get(key)
- return ok
-}
-
-// Len returns the number of items currently in the tree.
-func (t *BTreeG[T]) Len() int {
- return t.length
-}
-
-// Clear removes all items from the btree. If addNodesToFreelist is true,
-// t's nodes are added to its freelist as part of this call, until the freelist
-// is full. Otherwise, the root node is simply dereferenced and the subtree
-// left to Go's normal GC processes.
-//
-// This can be much faster
-// than calling Delete on all elements, because that requires finding/removing
-// each element in the tree and updating the tree accordingly. It also is
-// somewhat faster than creating a new tree to replace the old one, because
-// nodes from the old tree are reclaimed into the freelist for use by the new
-// one, instead of being lost to the garbage collector.
-//
-// This call takes:
-// O(1): when addNodesToFreelist is false, this is a single operation.
-// O(1): when the freelist is already full, it breaks out immediately
-// O(freelist size): when the freelist is empty and the nodes are all owned
-// by this tree, nodes are added to the freelist until full.
-// O(tree size): when all nodes are owned by another tree, all nodes are
-// iterated over looking for nodes to add to the freelist, and due to
-// ownership, none are.
-func (t *BTreeG[T]) Clear(addNodesToFreelist bool) {
- if t.root != nil && addNodesToFreelist {
- t.root.reset(t.cow)
- }
- t.root, t.length = nil, 0
-}
-
-// reset returns a subtree to the freelist. It breaks out immediately if the
-// freelist is full, since the only benefit of iterating is to fill that
-// freelist up. Returns true if parent reset call should continue.
-func (n *node[T]) reset(c *copyOnWriteContext[T]) bool {
- for _, child := range n.children {
- if !child.reset(c) {
- return false
- }
- }
- return c.freeNode(n) != ftFreelistFull
-}
-
-// Int implements the Item interface for integers.
-type Int int
-
-// Less returns true if int(a) < int(b).
-func (a Int) Less(b Item) bool {
- return a < b.(Int)
-}
-
-// BTree is an implementation of a B-Tree.
-//
-// BTree stores Item instances in an ordered structure, allowing easy insertion,
-// removal, and iteration.
-//
-// Write operations are not safe for concurrent mutation by multiple
-// goroutines, but Read operations are.
-type BTree BTreeG[Item]
-
-var itemLess LessFunc[Item] = func(a, b Item) bool {
- return a.Less(b)
-}
-
-// New creates a new B-Tree with the given degree.
-//
-// New(2), for example, will create a 2-3-4 tree (each node contains 1-3 items
-// and 2-4 children).
-func New(degree int) *BTree {
- return (*BTree)(NewG[Item](degree, itemLess))
-}
-
-// FreeList represents a free list of btree nodes. By default each
-// BTree has its own FreeList, but multiple BTrees can share the same
-// FreeList.
-// Two Btrees using the same freelist are safe for concurrent write access.
-type FreeList FreeListG[Item]
-
-// NewFreeList creates a new free list.
-// size is the maximum size of the returned free list.
-func NewFreeList(size int) *FreeList {
- return (*FreeList)(NewFreeListG[Item](size))
-}
-
-// NewWithFreeList creates a new B-Tree that uses the given node free list.
-func NewWithFreeList(degree int, f *FreeList) *BTree {
- return (*BTree)(NewWithFreeListG[Item](degree, itemLess, (*FreeListG[Item])(f)))
-}
-
-// ItemIterator allows callers of Ascend* to iterate in-order over portions of
-// the tree. When this function returns false, iteration will stop and the
-// associated Ascend* function will immediately return.
-type ItemIterator ItemIteratorG[Item]
-
-// Clone clones the btree, lazily. Clone should not be called concurrently,
-// but the original tree (t) and the new tree (t2) can be used concurrently
-// once the Clone call completes.
-//
-// The internal tree structure of b is marked read-only and shared between t and
-// t2. Writes to both t and t2 use copy-on-write logic, creating new nodes
-// whenever one of b's original nodes would have been modified. Read operations
-// should have no performance degredation. Write operations for both t and t2
-// will initially experience minor slow-downs caused by additional allocs and
-// copies due to the aforementioned copy-on-write logic, but should converge to
-// the original performance characteristics of the original tree.
-func (t *BTree) Clone() (t2 *BTree) {
- return (*BTree)((*BTreeG[Item])(t).Clone())
-}
-
-// Delete removes an item equal to the passed in item from the tree, returning
-// it. If no such item exists, returns nil.
-func (t *BTree) Delete(item Item) Item {
- i, _ := (*BTreeG[Item])(t).Delete(item)
- return i
-}
-
-// DeleteMax removes the largest item in the tree and returns it.
-// If no such item exists, returns nil.
-func (t *BTree) DeleteMax() Item {
- i, _ := (*BTreeG[Item])(t).DeleteMax()
- return i
-}
-
-// DeleteMin removes the smallest item in the tree and returns it.
-// If no such item exists, returns nil.
-func (t *BTree) DeleteMin() Item {
- i, _ := (*BTreeG[Item])(t).DeleteMin()
- return i
-}
-
-// Get looks for the key item in the tree, returning it. It returns nil if
-// unable to find that item.
-func (t *BTree) Get(key Item) Item {
- i, _ := (*BTreeG[Item])(t).Get(key)
- return i
-}
-
-// Max returns the largest item in the tree, or nil if the tree is empty.
-func (t *BTree) Max() Item {
- i, _ := (*BTreeG[Item])(t).Max()
- return i
-}
-
-// Min returns the smallest item in the tree, or nil if the tree is empty.
-func (t *BTree) Min() Item {
- i, _ := (*BTreeG[Item])(t).Min()
- return i
-}
-
-// Has returns true if the given key is in the tree.
-func (t *BTree) Has(key Item) bool {
- return (*BTreeG[Item])(t).Has(key)
-}
-
-// ReplaceOrInsert adds the given item to the tree. If an item in the tree
-// already equals the given one, it is removed from the tree and returned.
-// Otherwise, nil is returned.
-//
-// nil cannot be added to the tree (will panic).
-func (t *BTree) ReplaceOrInsert(item Item) Item {
- i, _ := (*BTreeG[Item])(t).ReplaceOrInsert(item)
- return i
-}
-
-// AscendRange calls the iterator for every value in the tree within the range
-// [greaterOrEqual, lessThan), until iterator returns false.
-func (t *BTree) AscendRange(greaterOrEqual, lessThan Item, iterator ItemIterator) {
- (*BTreeG[Item])(t).AscendRange(greaterOrEqual, lessThan, (ItemIteratorG[Item])(iterator))
-}
-
-// AscendLessThan calls the iterator for every value in the tree within the range
-// [first, pivot), until iterator returns false.
-func (t *BTree) AscendLessThan(pivot Item, iterator ItemIterator) {
- (*BTreeG[Item])(t).AscendLessThan(pivot, (ItemIteratorG[Item])(iterator))
-}
-
-// AscendGreaterOrEqual calls the iterator for every value in the tree within
-// the range [pivot, last], until iterator returns false.
-func (t *BTree) AscendGreaterOrEqual(pivot Item, iterator ItemIterator) {
- (*BTreeG[Item])(t).AscendGreaterOrEqual(pivot, (ItemIteratorG[Item])(iterator))
-}
-
-// Ascend calls the iterator for every value in the tree within the range
-// [first, last], until iterator returns false.
-func (t *BTree) Ascend(iterator ItemIterator) {
- (*BTreeG[Item])(t).Ascend((ItemIteratorG[Item])(iterator))
-}
-
-// DescendRange calls the iterator for every value in the tree within the range
-// [lessOrEqual, greaterThan), until iterator returns false.
-func (t *BTree) DescendRange(lessOrEqual, greaterThan Item, iterator ItemIterator) {
- (*BTreeG[Item])(t).DescendRange(lessOrEqual, greaterThan, (ItemIteratorG[Item])(iterator))
-}
-
-// DescendLessOrEqual calls the iterator for every value in the tree within the range
-// [pivot, first], until iterator returns false.
-func (t *BTree) DescendLessOrEqual(pivot Item, iterator ItemIterator) {
- (*BTreeG[Item])(t).DescendLessOrEqual(pivot, (ItemIteratorG[Item])(iterator))
-}
-
-// DescendGreaterThan calls the iterator for every value in the tree within
-// the range [last, pivot), until iterator returns false.
-func (t *BTree) DescendGreaterThan(pivot Item, iterator ItemIterator) {
- (*BTreeG[Item])(t).DescendGreaterThan(pivot, (ItemIteratorG[Item])(iterator))
-}
-
-// Descend calls the iterator for every value in the tree within the range
-// [last, first], until iterator returns false.
-func (t *BTree) Descend(iterator ItemIterator) {
- (*BTreeG[Item])(t).Descend((ItemIteratorG[Item])(iterator))
-}
-
-// Len returns the number of items currently in the tree.
-func (t *BTree) Len() int {
- return (*BTreeG[Item])(t).Len()
-}
-
-// Clear removes all items from the btree. If addNodesToFreelist is true,
-// t's nodes are added to its freelist as part of this call, until the freelist
-// is full. Otherwise, the root node is simply dereferenced and the subtree
-// left to Go's normal GC processes.
-//
-// This can be much faster
-// than calling Delete on all elements, because that requires finding/removing
-// each element in the tree and updating the tree accordingly. It also is
-// somewhat faster than creating a new tree to replace the old one, because
-// nodes from the old tree are reclaimed into the freelist for use by the new
-// one, instead of being lost to the garbage collector.
-//
-// This call takes:
-// O(1): when addNodesToFreelist is false, this is a single operation.
-// O(1): when the freelist is already full, it breaks out immediately
-// O(freelist size): when the freelist is empty and the nodes are all owned
-// by this tree, nodes are added to the freelist until full.
-// O(tree size): when all nodes are owned by another tree, all nodes are
-// iterated over looking for nodes to add to the freelist, and due to
-// ownership, none are.
-func (t *BTree) Clear(addNodesToFreelist bool) {
- (*BTreeG[Item])(t).Clear(addNodesToFreelist)
-}
diff --git a/vendor/github.com/google/pprof/profile/merge.go b/vendor/github.com/google/pprof/profile/merge.go
index ba4d746407..8a51690be4 100644
--- a/vendor/github.com/google/pprof/profile/merge.go
+++ b/vendor/github.com/google/pprof/profile/merge.go
@@ -17,6 +17,7 @@ package profile
import (
"encoding/binary"
"fmt"
+ "slices"
"sort"
"strconv"
"strings"
@@ -78,12 +79,10 @@ func Merge(srcs []*Profile) (*Profile, error) {
}
}
- for _, s := range p.Sample {
- if isZeroSample(s) {
- // If there are any zero samples, re-merge the profile to GC
- // them.
- return Merge([]*Profile{p})
- }
+ if slices.ContainsFunc(p.Sample, isZeroSample) {
+ // If there are any zero samples, re-merge the profile to GC
+ // them.
+ return Merge([]*Profile{p})
}
return p, nil
diff --git a/vendor/github.com/google/pprof/profile/profile.go b/vendor/github.com/google/pprof/profile/profile.go
index f47a243903..18df65a8df 100644
--- a/vendor/github.com/google/pprof/profile/profile.go
+++ b/vendor/github.com/google/pprof/profile/profile.go
@@ -24,6 +24,7 @@ import (
"math"
"path/filepath"
"regexp"
+ "slices"
"sort"
"strings"
"sync"
@@ -277,7 +278,7 @@ func (p *Profile) massageMappings() {
// Use heuristics to identify main binary and move it to the top of the list of mappings
for i, m := range p.Mapping {
- file := strings.TrimSpace(strings.Replace(m.File, "(deleted)", "", -1))
+ file := strings.TrimSpace(strings.ReplaceAll(m.File, "(deleted)", ""))
if len(file) == 0 {
continue
}
@@ -734,12 +735,7 @@ func (p *Profile) RemoveLabel(key string) {
// HasLabel returns true if a sample has a label with indicated key and value.
func (s *Sample) HasLabel(key, value string) bool {
- for _, v := range s.Label[key] {
- if v == value {
- return true
- }
- }
- return false
+ return slices.Contains(s.Label[key], value)
}
// SetNumLabel sets the specified key to the specified value for all samples in the
@@ -852,7 +848,17 @@ func (p *Profile) HasFileLines() bool {
// "[vdso]", "[vsyscall]" and some others, see the code.
func (m *Mapping) Unsymbolizable() bool {
name := filepath.Base(m.File)
- return strings.HasPrefix(name, "[") || strings.HasPrefix(name, "linux-vdso") || strings.HasPrefix(m.File, "/dev/dri/") || m.File == "//anon"
+ switch {
+ case strings.HasPrefix(name, "["):
+ case strings.HasPrefix(name, "linux-vdso"):
+ case strings.HasPrefix(m.File, "/dev/dri/"):
+ case m.File == "//anon":
+ case m.File == "":
+ case strings.HasPrefix(m.File, "/memfd:"):
+ default:
+ return false
+ }
+ return true
}
// Copy makes a fully independent copy of a profile.
diff --git a/vendor/github.com/google/pprof/profile/proto.go b/vendor/github.com/google/pprof/profile/proto.go
index a15696ba16..31bf6bca63 100644
--- a/vendor/github.com/google/pprof/profile/proto.go
+++ b/vendor/github.com/google/pprof/profile/proto.go
@@ -36,6 +36,7 @@ package profile
import (
"errors"
"fmt"
+ "slices"
)
type buffer struct {
@@ -187,6 +188,16 @@ func le32(p []byte) uint32 {
return uint32(p[0]) | uint32(p[1])<<8 | uint32(p[2])<<16 | uint32(p[3])<<24
}
+func peekNumVarints(data []byte) (numVarints int) {
+ for ; len(data) > 0; numVarints++ {
+ var err error
+ if _, data, err = decodeVarint(data); err != nil {
+ break
+ }
+ }
+ return numVarints
+}
+
func decodeVarint(data []byte) (uint64, []byte, error) {
var u uint64
for i := 0; ; i++ {
@@ -286,6 +297,9 @@ func decodeInt64(b *buffer, x *int64) error {
func decodeInt64s(b *buffer, x *[]int64) error {
if b.typ == 2 {
// Packed encoding
+ dataLen := peekNumVarints(b.data)
+ *x = slices.Grow(*x, dataLen)
+
data := b.data
for len(data) > 0 {
var u uint64
@@ -316,8 +330,11 @@ func decodeUint64(b *buffer, x *uint64) error {
func decodeUint64s(b *buffer, x *[]uint64) error {
if b.typ == 2 {
- data := b.data
// Packed encoding
+ dataLen := peekNumVarints(b.data)
+ *x = slices.Grow(*x, dataLen)
+
+ data := b.data
for len(data) > 0 {
var u uint64
var err error
diff --git a/vendor/github.com/google/pprof/profile/prune.go b/vendor/github.com/google/pprof/profile/prune.go
index b2f9fd5466..7bba31e8ce 100644
--- a/vendor/github.com/google/pprof/profile/prune.go
+++ b/vendor/github.com/google/pprof/profile/prune.go
@@ -19,6 +19,7 @@ package profile
import (
"fmt"
"regexp"
+ "slices"
"strings"
)
@@ -40,13 +41,7 @@ func simplifyFunc(f string) string {
// Account for unsimplified names -- try to remove the argument list by trimming
// starting from the first '(', but skipping reserved names that have '('.
for _, ind := range bracketRx.FindAllStringSubmatchIndex(funcName, -1) {
- foundReserved := false
- for _, res := range reservedNames {
- if funcName[ind[0]:ind[1]] == res {
- foundReserved = true
- break
- }
- }
+ foundReserved := slices.Contains(reservedNames, funcName[ind[0]:ind[1]])
if !foundReserved {
funcName = funcName[:ind[0]]
break
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/LICENSE b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus/LICENSE
similarity index 100%
rename from vendor/github.com/grpc-ecosystem/go-grpc-prometheus/LICENSE
rename to vendor/github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus/LICENSE
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus/client_metrics.go b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus/client_metrics.go
new file mode 100644
index 0000000000..5c8ba20765
--- /dev/null
+++ b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus/client_metrics.go
@@ -0,0 +1,117 @@
+// Copyright (c) The go-grpc-middleware Authors.
+// Licensed under the Apache License 2.0.
+
+package prometheus
+
+import (
+ "github.com/grpc-ecosystem/go-grpc-middleware/v2/interceptors"
+ "github.com/prometheus/client_golang/prometheus"
+ "google.golang.org/grpc"
+)
+
+// ClientMetrics represents a collection of metrics to be registered on a
+// Prometheus metrics registry for a gRPC client.
+type ClientMetrics struct {
+ clientStartedCounter *prometheus.CounterVec
+ clientHandledCounter *prometheus.CounterVec
+ clientStreamMsgReceived *prometheus.CounterVec
+ clientStreamMsgSent *prometheus.CounterVec
+
+ // clientHandledHistogram can be nil
+ clientHandledHistogram *prometheus.HistogramVec
+ // clientStreamRecvHistogram can be nil
+ clientStreamRecvHistogram *prometheus.HistogramVec
+ // clientStreamSendHistogram can be nil
+ clientStreamSendHistogram *prometheus.HistogramVec
+}
+
+// NewClientMetrics returns a new ClientMetrics object.
+// NOTE: Remember to register ClientMetrics object using prometheus registry
+// e.g. prometheus.MustRegister(myClientMetrics).
+func NewClientMetrics(opts ...ClientMetricsOption) *ClientMetrics {
+ var config clientMetricsConfig
+ config.apply(opts)
+ return &ClientMetrics{
+ clientStartedCounter: prometheus.NewCounterVec(
+ config.counterOpts.apply(prometheus.CounterOpts{
+ Name: "grpc_client_started_total",
+ Help: "Total number of RPCs started on the client.",
+ }), []string{"grpc_type", "grpc_service", "grpc_method"}),
+
+ clientHandledCounter: prometheus.NewCounterVec(
+ config.counterOpts.apply(prometheus.CounterOpts{
+ Name: "grpc_client_handled_total",
+ Help: "Total number of RPCs completed by the client, regardless of success or failure.",
+ }), []string{"grpc_type", "grpc_service", "grpc_method", "grpc_code"}),
+
+ clientStreamMsgReceived: prometheus.NewCounterVec(
+ config.counterOpts.apply(prometheus.CounterOpts{
+ Name: "grpc_client_msg_received_total",
+ Help: "Total number of RPC stream messages received by the client.",
+ }), []string{"grpc_type", "grpc_service", "grpc_method"}),
+
+ clientStreamMsgSent: prometheus.NewCounterVec(
+ config.counterOpts.apply(prometheus.CounterOpts{
+ Name: "grpc_client_msg_sent_total",
+ Help: "Total number of gRPC stream messages sent by the client.",
+ }), []string{"grpc_type", "grpc_service", "grpc_method"}),
+
+ clientHandledHistogram: config.clientHandledHistogram,
+ clientStreamRecvHistogram: config.clientStreamRecvHistogram,
+ clientStreamSendHistogram: config.clientStreamSendHistogram,
+ }
+}
+
+// Describe sends the super-set of all possible descriptors of metrics
+// collected by this Collector to the provided channel and returns once
+// the last descriptor has been sent.
+func (m *ClientMetrics) Describe(ch chan<- *prometheus.Desc) {
+ m.clientStartedCounter.Describe(ch)
+ m.clientHandledCounter.Describe(ch)
+ m.clientStreamMsgReceived.Describe(ch)
+ m.clientStreamMsgSent.Describe(ch)
+ if m.clientHandledHistogram != nil {
+ m.clientHandledHistogram.Describe(ch)
+ }
+ if m.clientStreamRecvHistogram != nil {
+ m.clientStreamRecvHistogram.Describe(ch)
+ }
+ if m.clientStreamSendHistogram != nil {
+ m.clientStreamSendHistogram.Describe(ch)
+ }
+}
+
+// Collect is called by the Prometheus registry when collecting
+// metrics. The implementation sends each collected metric via the
+// provided channel and returns once the last metric has been sent.
+func (m *ClientMetrics) Collect(ch chan<- prometheus.Metric) {
+ m.clientStartedCounter.Collect(ch)
+ m.clientHandledCounter.Collect(ch)
+ m.clientStreamMsgReceived.Collect(ch)
+ m.clientStreamMsgSent.Collect(ch)
+ if m.clientHandledHistogram != nil {
+ m.clientHandledHistogram.Collect(ch)
+ }
+ if m.clientStreamRecvHistogram != nil {
+ m.clientStreamRecvHistogram.Collect(ch)
+ }
+ if m.clientStreamSendHistogram != nil {
+ m.clientStreamSendHistogram.Collect(ch)
+ }
+}
+
+// UnaryClientInterceptor is a gRPC client-side interceptor that provides Prometheus monitoring for Unary RPCs.
+func (m *ClientMetrics) UnaryClientInterceptor(opts ...Option) grpc.UnaryClientInterceptor {
+ return interceptors.UnaryClientInterceptor(&reportable{
+ opts: opts,
+ clientMetrics: m,
+ })
+}
+
+// StreamClientInterceptor is a gRPC client-side interceptor that provides Prometheus monitoring for Streaming RPCs.
+func (m *ClientMetrics) StreamClientInterceptor(opts ...Option) grpc.StreamClientInterceptor {
+ return interceptors.StreamClientInterceptor(&reportable{
+ opts: opts,
+ clientMetrics: m,
+ })
+}
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus/client_options.go b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus/client_options.go
new file mode 100644
index 0000000000..c2671679c6
--- /dev/null
+++ b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus/client_options.go
@@ -0,0 +1,77 @@
+// Copyright (c) The go-grpc-middleware Authors.
+// Licensed under the Apache License 2.0.
+
+package prometheus
+
+import (
+ "github.com/prometheus/client_golang/prometheus"
+)
+
+type clientMetricsConfig struct {
+ counterOpts counterOptions
+ // clientHandledHistogram can be nil.
+ clientHandledHistogram *prometheus.HistogramVec
+ // clientStreamRecvHistogram can be nil.
+ clientStreamRecvHistogram *prometheus.HistogramVec
+ // clientStreamSendHistogram can be nil.
+ clientStreamSendHistogram *prometheus.HistogramVec
+}
+
+type ClientMetricsOption func(*clientMetricsConfig)
+
+func (c *clientMetricsConfig) apply(opts []ClientMetricsOption) {
+ for _, o := range opts {
+ o(c)
+ }
+}
+
+func WithClientCounterOptions(opts ...CounterOption) ClientMetricsOption {
+ return func(o *clientMetricsConfig) {
+ o.counterOpts = opts
+ }
+}
+
+// WithClientHandlingTimeHistogram turns on recording of handling time of RPCs.
+// Histogram metrics can be very expensive for Prometheus to retain and query.
+func WithClientHandlingTimeHistogram(opts ...HistogramOption) ClientMetricsOption {
+ return func(o *clientMetricsConfig) {
+ o.clientHandledHistogram = prometheus.NewHistogramVec(
+ histogramOptions(opts).apply(prometheus.HistogramOpts{
+ Name: "grpc_client_handling_seconds",
+ Help: "Histogram of response latency (seconds) of the gRPC until it is finished by the application.",
+ Buckets: prometheus.DefBuckets,
+ }),
+ []string{"grpc_type", "grpc_service", "grpc_method"},
+ )
+ }
+}
+
+// WithClientStreamRecvHistogram turns on recording of single message receive time of streaming RPCs.
+// Histogram metrics can be very expensive for Prometheus to retain and query.
+func WithClientStreamRecvHistogram(opts ...HistogramOption) ClientMetricsOption {
+ return func(o *clientMetricsConfig) {
+ o.clientStreamRecvHistogram = prometheus.NewHistogramVec(
+ histogramOptions(opts).apply(prometheus.HistogramOpts{
+ Name: "grpc_client_msg_recv_handling_seconds",
+ Help: "Histogram of response latency (seconds) of the gRPC single message receive.",
+ Buckets: prometheus.DefBuckets,
+ }),
+ []string{"grpc_type", "grpc_service", "grpc_method"},
+ )
+ }
+}
+
+// WithClientStreamSendHistogram turns on recording of single message send time of streaming RPCs.
+// Histogram metrics can be very expensive for Prometheus to retain and query.
+func WithClientStreamSendHistogram(opts ...HistogramOption) ClientMetricsOption {
+ return func(o *clientMetricsConfig) {
+ o.clientStreamSendHistogram = prometheus.NewHistogramVec(
+ histogramOptions(opts).apply(prometheus.HistogramOpts{
+ Name: "grpc_client_msg_send_handling_seconds",
+ Help: "Histogram of response latency (seconds) of the gRPC single message send.",
+ Buckets: prometheus.DefBuckets,
+ }),
+ []string{"grpc_type", "grpc_service", "grpc_method"},
+ )
+ }
+}
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus/constants.go b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus/constants.go
new file mode 100644
index 0000000000..5c36923f7e
--- /dev/null
+++ b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus/constants.go
@@ -0,0 +1,23 @@
+// Copyright (c) The go-grpc-middleware Authors.
+// Licensed under the Apache License 2.0.
+
+package prometheus
+
+type grpcType string
+
+// grpcType describes all types of grpc connection.
+const (
+ Unary grpcType = "unary"
+ ClientStream grpcType = "client_stream"
+ ServerStream grpcType = "server_stream"
+ BidiStream grpcType = "bidi_stream"
+)
+
+// Kind describes whether interceptor is a client or server type.
+type Kind string
+
+// Enum for Client and Server Kind.
+const (
+ KindClient Kind = "client"
+ KindServer Kind = "server"
+)
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus/doc.go b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus/doc.go
new file mode 100644
index 0000000000..b62f17efb7
--- /dev/null
+++ b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus/doc.go
@@ -0,0 +1,8 @@
+// Copyright (c) The go-grpc-middleware Authors.
+// Licensed under the Apache License 2.0.
+
+/*
+Package prometheus provides a standalone interceptor for metrics. It's next iteration of deprecated https://github.com/grpc-ecosystem/go-grpc-prometheus.
+See https://github.com/grpc-ecosystem/go-grpc-middleware/tree/main/examples for example.
+*/
+package prometheus
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus/options.go b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus/options.go
new file mode 100644
index 0000000000..2047b5fe41
--- /dev/null
+++ b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus/options.go
@@ -0,0 +1,152 @@
+// Copyright (c) The go-grpc-middleware Authors.
+// Licensed under the Apache License 2.0.
+
+package prometheus
+
+import (
+ "github.com/prometheus/client_golang/prometheus"
+ "google.golang.org/grpc"
+ "google.golang.org/grpc/status"
+)
+
+// FromError returns a grpc status. If the error code is neither a valid grpc status nor a context error, codes.Unknown
+// will be set.
+func FromError(err error) *status.Status {
+ s, ok := status.FromError(err)
+ // Mirror what the grpc server itself does, i.e. also convert context errors to status
+ if !ok {
+ s = status.FromContextError(err)
+ }
+ return s
+}
+
+// A CounterOption lets you add options to Counter metrics using With* funcs.
+type CounterOption func(*prometheus.CounterOpts)
+
+type counterOptions []CounterOption
+
+func (co counterOptions) apply(o prometheus.CounterOpts) prometheus.CounterOpts {
+ for _, f := range co {
+ f(&o)
+ }
+ return o
+}
+
+// WithConstLabels allows you to add ConstLabels to Counter metrics.
+func WithConstLabels(labels prometheus.Labels) CounterOption {
+ return func(o *prometheus.CounterOpts) {
+ o.ConstLabels = labels
+ }
+}
+
+// WithSubsystem allows you to add a Subsystem to Counter metrics.
+func WithSubsystem(subsystem string) CounterOption {
+ return func(o *prometheus.CounterOpts) {
+ o.Subsystem = subsystem
+ }
+}
+
+// WithNamespace allows you to add a Namespace to Counter metrics.
+func WithNamespace(namespace string) CounterOption {
+ return func(o *prometheus.CounterOpts) {
+ o.Namespace = namespace
+ }
+}
+
+// A HistogramOption lets you add options to Histogram metrics using With*
+// funcs.
+type HistogramOption func(*prometheus.HistogramOpts)
+
+type histogramOptions []HistogramOption
+
+func (ho histogramOptions) apply(o prometheus.HistogramOpts) prometheus.HistogramOpts {
+ for _, f := range ho {
+ f(&o)
+ }
+ return o
+}
+
+// WithHistogramBuckets allows you to specify custom bucket ranges for histograms if EnableHandlingTimeHistogram is on.
+func WithHistogramBuckets(buckets []float64) HistogramOption {
+ return func(o *prometheus.HistogramOpts) { o.Buckets = buckets }
+}
+
+// WithHistogramOpts allows you to specify HistogramOpts but makes sure the correct name and label is used.
+// This function is helpful when specifying more than just the buckets, like using NativeHistograms.
+func WithHistogramOpts(opts *prometheus.HistogramOpts) HistogramOption {
+ // TODO: This isn't ideal either if new fields are added to prometheus.HistogramOpts.
+ // Maybe we can change the interface to accept arbitrary HistogramOpts and
+ // only make sure to overwrite the necessary fields (name, labels).
+ return func(o *prometheus.HistogramOpts) {
+ o.Buckets = opts.Buckets
+ o.NativeHistogramBucketFactor = opts.NativeHistogramBucketFactor
+ o.NativeHistogramZeroThreshold = opts.NativeHistogramZeroThreshold
+ o.NativeHistogramMaxBucketNumber = opts.NativeHistogramMaxBucketNumber
+ o.NativeHistogramMinResetDuration = opts.NativeHistogramMinResetDuration
+ o.NativeHistogramMaxZeroThreshold = opts.NativeHistogramMaxZeroThreshold
+ }
+}
+
+// WithHistogramConstLabels allows you to add custom ConstLabels to
+// histograms metrics.
+func WithHistogramConstLabels(labels prometheus.Labels) HistogramOption {
+ return func(o *prometheus.HistogramOpts) {
+ o.ConstLabels = labels
+ }
+}
+
+// WithHistogramSubsystem allows you to add a Subsystem to histograms metrics.
+func WithHistogramSubsystem(subsystem string) HistogramOption {
+ return func(o *prometheus.HistogramOpts) {
+ o.Subsystem = subsystem
+ }
+}
+
+// WithHistogramNamespace allows you to add a Namespace to histograms metrics.
+func WithHistogramNamespace(namespace string) HistogramOption {
+ return func(o *prometheus.HistogramOpts) {
+ o.Namespace = namespace
+ }
+}
+
+func typeFromMethodInfo(mInfo *grpc.MethodInfo) grpcType {
+ if !mInfo.IsClientStream && !mInfo.IsServerStream {
+ return Unary
+ }
+ if mInfo.IsClientStream && !mInfo.IsServerStream {
+ return ClientStream
+ }
+ if !mInfo.IsClientStream && mInfo.IsServerStream {
+ return ServerStream
+ }
+ return BidiStream
+}
+
+// An Option lets you add options to prometheus interceptors using With* funcs.
+type Option func(*config)
+
+type config struct {
+ exemplarFn exemplarFromCtxFn
+ labelsFn labelsFromCtxFn
+}
+
+func (c *config) apply(opts []Option) {
+ for _, o := range opts {
+ o(c)
+ }
+}
+
+// WithExemplarFromContext sets function that will be used to deduce exemplar for all counter and histogram metrics.
+func WithExemplarFromContext(exemplarFn exemplarFromCtxFn) Option {
+ return func(o *config) {
+ o.exemplarFn = exemplarFn
+ }
+}
+
+// WithLabelsFromContext sets function that will be used to extract labels from context for metrics.
+// This should be used in conjunction with WithContextLabels to define which labels to extract.
+func WithLabelsFromContext(labelsFn labelsFromCtxFn) Option {
+ return func(o *config) {
+ o.labelsFn = labelsFn
+ }
+}
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus/reporter.go b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus/reporter.go
new file mode 100644
index 0000000000..268beb3e61
--- /dev/null
+++ b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus/reporter.go
@@ -0,0 +1,139 @@
+// Copyright (c) The go-grpc-middleware Authors.
+// Licensed under the Apache License 2.0.
+
+package prometheus
+
+import (
+ "context"
+ "time"
+
+ "github.com/grpc-ecosystem/go-grpc-middleware/v2/interceptors"
+ "github.com/prometheus/client_golang/prometheus"
+)
+
+type reporter struct {
+ clientMetrics *ClientMetrics
+ serverMetrics *ServerMetrics
+ typ interceptors.GRPCType
+ service, method string
+ kind Kind
+ exemplar prometheus.Labels
+ contextLabels []string
+}
+
+func (r *reporter) PostCall(err error, rpcDuration time.Duration) {
+ // get status code from error
+ status := FromError(err)
+ code := status.Code()
+
+ // perform handling of metrics from code
+ switch r.kind {
+ case KindServer:
+ baseLabels := []string{string(r.typ), r.service, r.method, code.String()}
+ allLabels := append(baseLabels, r.contextLabels...)
+ r.incrementWithExemplar(r.serverMetrics.serverHandledCounter, allLabels...)
+ if r.serverMetrics.serverHandledHistogram != nil {
+ histLabels := []string{string(r.typ), r.service, r.method}
+ allHistLabels := append(histLabels, r.contextLabels...)
+ r.observeWithExemplar(r.serverMetrics.serverHandledHistogram, rpcDuration.Seconds(), allHistLabels...)
+ }
+
+ case KindClient:
+ r.incrementWithExemplar(r.clientMetrics.clientHandledCounter, string(r.typ), r.service, r.method, code.String())
+ if r.clientMetrics.clientHandledHistogram != nil {
+ r.observeWithExemplar(r.clientMetrics.clientHandledHistogram, rpcDuration.Seconds(), string(r.typ), r.service, r.method)
+ }
+ }
+}
+
+func (r *reporter) PostMsgSend(_ any, _ error, sendDuration time.Duration) {
+ switch r.kind {
+ case KindServer:
+ baseLabels := []string{string(r.typ), r.service, r.method}
+ allLabels := append(baseLabels, r.contextLabels...)
+ r.incrementWithExemplar(r.serverMetrics.serverStreamMsgSent, allLabels...)
+ case KindClient:
+ r.incrementWithExemplar(r.clientMetrics.clientStreamMsgSent, string(r.typ), r.service, r.method)
+ if r.clientMetrics.clientStreamSendHistogram != nil {
+ r.observeWithExemplar(r.clientMetrics.clientStreamSendHistogram, sendDuration.Seconds(), string(r.typ), r.service, r.method)
+ }
+ }
+}
+
+func (r *reporter) PostMsgReceive(_ any, _ error, recvDuration time.Duration) {
+ switch r.kind {
+ case KindServer:
+ baseLabels := []string{string(r.typ), r.service, r.method}
+ allLabels := append(baseLabels, r.contextLabels...)
+ r.incrementWithExemplar(r.serverMetrics.serverStreamMsgReceived, allLabels...)
+ case KindClient:
+ r.incrementWithExemplar(r.clientMetrics.clientStreamMsgReceived, string(r.typ), r.service, r.method)
+ if r.clientMetrics.clientStreamRecvHistogram != nil {
+ r.observeWithExemplar(r.clientMetrics.clientStreamRecvHistogram, recvDuration.Seconds(), string(r.typ), r.service, r.method)
+ }
+ }
+}
+
+type reportable struct {
+ clientMetrics *ClientMetrics
+ serverMetrics *ServerMetrics
+
+ opts []Option
+}
+
+func (rep *reportable) ServerReporter(ctx context.Context, meta interceptors.CallMeta) (interceptors.Reporter, context.Context) {
+ return rep.reporter(ctx, rep.serverMetrics, nil, meta, KindServer)
+}
+
+func (rep *reportable) ClientReporter(ctx context.Context, meta interceptors.CallMeta) (interceptors.Reporter, context.Context) {
+ return rep.reporter(ctx, nil, rep.clientMetrics, meta, KindClient)
+}
+
+func (rep *reportable) reporter(ctx context.Context, sm *ServerMetrics, cm *ClientMetrics, meta interceptors.CallMeta, kind Kind) (interceptors.Reporter, context.Context) {
+ var c config
+ c.apply(rep.opts)
+ r := &reporter{
+ clientMetrics: cm,
+ serverMetrics: sm,
+ typ: meta.Typ,
+ service: meta.Service,
+ method: meta.Method,
+ kind: kind,
+ }
+ if c.exemplarFn != nil {
+ r.exemplar = c.exemplarFn(ctx)
+ }
+
+ // Extract context labels if labelsFn is configured and we're on server side
+ if c.labelsFn != nil && kind == KindServer && sm != nil {
+ contextLabelMap := c.labelsFn(ctx)
+ // Extract context label values in the order defined by the server metrics
+ r.contextLabels = make([]string, len(sm.contextLabelNames))
+ for i, labelName := range sm.contextLabelNames {
+ if value, exists := contextLabelMap[labelName]; exists {
+ r.contextLabels[i] = value
+ } else {
+ // Use empty string if label not found in context
+ r.contextLabels[i] = ""
+ }
+ }
+ }
+
+ switch kind {
+ case KindClient:
+ r.incrementWithExemplar(r.clientMetrics.clientStartedCounter, string(r.typ), r.service, r.method)
+ case KindServer:
+ baseLabels := []string{string(r.typ), r.service, r.method}
+ allLabels := append(baseLabels, r.contextLabels...)
+ r.incrementWithExemplar(r.serverMetrics.serverStartedCounter, allLabels...)
+ }
+ return r, ctx
+}
+
+func (r *reporter) incrementWithExemplar(c *prometheus.CounterVec, lvals ...string) {
+ c.WithLabelValues(lvals...).(prometheus.ExemplarAdder).AddWithExemplar(1, r.exemplar)
+}
+
+func (r *reporter) observeWithExemplar(h *prometheus.HistogramVec, value float64, lvals ...string) {
+ h.WithLabelValues(lvals...).(prometheus.ExemplarObserver).ObserveWithExemplar(value, r.exemplar)
+}
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus/server_metrics.go b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus/server_metrics.go
new file mode 100644
index 0000000000..358d574caf
--- /dev/null
+++ b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus/server_metrics.go
@@ -0,0 +1,163 @@
+// Copyright (c) The go-grpc-middleware Authors.
+// Licensed under the Apache License 2.0.
+
+package prometheus
+
+import (
+ "github.com/grpc-ecosystem/go-grpc-middleware/v2/interceptors"
+ "github.com/prometheus/client_golang/prometheus"
+ "google.golang.org/grpc"
+ "google.golang.org/grpc/reflection"
+)
+
+// ServerMetrics represents a collection of metrics to be registered on a
+// Prometheus metrics registry for a gRPC server.
+type ServerMetrics struct {
+ serverStartedCounter *prometheus.CounterVec
+ serverHandledCounter *prometheus.CounterVec
+ serverStreamMsgReceived *prometheus.CounterVec
+ serverStreamMsgSent *prometheus.CounterVec
+ // serverHandledHistogram can be nil.
+ serverHandledHistogram *prometheus.HistogramVec
+ // contextLabelNames stores the names of context labels
+ contextLabelNames []string
+}
+
+// NewServerMetrics returns a new ServerMetrics object that has server interceptor methods.
+// NOTE: Remember to register ServerMetrics object by using prometheus registry
+// e.g. prometheus.MustRegister(myServerMetrics).
+func NewServerMetrics(opts ...ServerMetricsOption) *ServerMetrics {
+ var config serverMetricsConfig
+ config.apply(opts)
+
+ // Build label names by combining default labels with context labels
+ defaultLabels := []string{"grpc_type", "grpc_service", "grpc_method"}
+ defaultLabelsWithCode := []string{"grpc_type", "grpc_service", "grpc_method", "grpc_code"}
+
+ startedLabels := append(defaultLabels, config.contextLabels...)
+ handledLabels := append(defaultLabelsWithCode, config.contextLabels...)
+ streamLabels := append(defaultLabels, config.contextLabels...)
+
+ // Create histogram if enabled
+ var serverHandledHistogram *prometheus.HistogramVec
+ if config.enableHistogram {
+ histogramLabels := append(defaultLabels, config.contextLabels...)
+ serverHandledHistogram = prometheus.NewHistogramVec(
+ histogramOptions(config.histogramOpts).apply(prometheus.HistogramOpts{
+ Name: "grpc_server_handling_seconds",
+ Help: "Histogram of response latency (seconds) of gRPC that had been application-level handled by the server.",
+ Buckets: prometheus.DefBuckets,
+ }),
+ histogramLabels,
+ )
+ }
+
+ return &ServerMetrics{
+ serverStartedCounter: prometheus.NewCounterVec(
+ config.counterOpts.apply(prometheus.CounterOpts{
+ Name: "grpc_server_started_total",
+ Help: "Total number of RPCs started on the server.",
+ }), startedLabels),
+ serverHandledCounter: prometheus.NewCounterVec(
+ config.counterOpts.apply(prometheus.CounterOpts{
+ Name: "grpc_server_handled_total",
+ Help: "Total number of RPCs completed on the server, regardless of success or failure.",
+ }), handledLabels),
+ serverStreamMsgReceived: prometheus.NewCounterVec(
+ config.counterOpts.apply(prometheus.CounterOpts{
+ Name: "grpc_server_msg_received_total",
+ Help: "Total number of RPC stream messages received on the server.",
+ }), streamLabels),
+ serverStreamMsgSent: prometheus.NewCounterVec(
+ config.counterOpts.apply(prometheus.CounterOpts{
+ Name: "grpc_server_msg_sent_total",
+ Help: "Total number of gRPC stream messages sent by the server.",
+ }), streamLabels),
+ serverHandledHistogram: serverHandledHistogram,
+ contextLabelNames: config.contextLabels,
+ }
+}
+
+// Describe sends the super-set of all possible descriptors of metrics
+// collected by this Collector to the provided channel and returns once
+// the last descriptor has been sent.
+func (m *ServerMetrics) Describe(ch chan<- *prometheus.Desc) {
+ m.serverStartedCounter.Describe(ch)
+ m.serverHandledCounter.Describe(ch)
+ m.serverStreamMsgReceived.Describe(ch)
+ m.serverStreamMsgSent.Describe(ch)
+ if m.serverHandledHistogram != nil {
+ m.serverHandledHistogram.Describe(ch)
+ }
+}
+
+// Collect is called by the Prometheus registry when collecting
+// metrics. The implementation sends each collected metric via the
+// provided channel and returns once the last metric has been sent.
+func (m *ServerMetrics) Collect(ch chan<- prometheus.Metric) {
+ m.serverStartedCounter.Collect(ch)
+ m.serverHandledCounter.Collect(ch)
+ m.serverStreamMsgReceived.Collect(ch)
+ m.serverStreamMsgSent.Collect(ch)
+ if m.serverHandledHistogram != nil {
+ m.serverHandledHistogram.Collect(ch)
+ }
+}
+
+// InitializeMetrics initializes all metrics, with their appropriate null
+// value, for all gRPC methods registered on a gRPC server. This is useful, to
+// ensure that all metrics exist when collecting and querying.
+// NOTE: This might add significant cardinality and might not be needed in future version of Prometheus (created timestamp).
+func (m *ServerMetrics) InitializeMetrics(server reflection.ServiceInfoProvider) {
+ serviceInfo := server.GetServiceInfo()
+ for serviceName, info := range serviceInfo {
+ for _, mInfo := range info.Methods {
+ m.preRegisterMethod(serviceName, &mInfo)
+ }
+ }
+}
+
+// preRegisterMethod is invoked on Register of a Server, allowing all gRPC services labels to be pre-populated.
+func (m *ServerMetrics) preRegisterMethod(serviceName string, mInfo *grpc.MethodInfo) {
+ methodName := mInfo.Name
+ methodType := string(typeFromMethodInfo(mInfo))
+
+ // Create empty context label values for pre-registration
+ contextLabels := make([]string, len(m.contextLabelNames))
+ for i := range contextLabels {
+ contextLabels[i] = ""
+ }
+
+ // Build complete label value arrays
+ startedLabels := append([]string{methodType, serviceName, methodName}, contextLabels...)
+ handledLabels := append([]string{methodType, serviceName, methodName}, contextLabels...)
+ streamLabels := append([]string{methodType, serviceName, methodName}, contextLabels...)
+
+ // These are just references (no increments), as just referencing will create the labels but not set values.
+ _, _ = m.serverStartedCounter.GetMetricWithLabelValues(startedLabels...)
+ _, _ = m.serverStreamMsgReceived.GetMetricWithLabelValues(streamLabels...)
+ _, _ = m.serverStreamMsgSent.GetMetricWithLabelValues(streamLabels...)
+ if m.serverHandledHistogram != nil {
+ _, _ = m.serverHandledHistogram.GetMetricWithLabelValues(streamLabels...)
+ }
+ for _, code := range interceptors.AllCodes {
+ handledLabelsWithCode := append(handledLabels, code.String())
+ _, _ = m.serverHandledCounter.GetMetricWithLabelValues(handledLabelsWithCode...)
+ }
+}
+
+// UnaryServerInterceptor is a gRPC server-side interceptor that provides Prometheus monitoring for Unary RPCs.
+func (m *ServerMetrics) UnaryServerInterceptor(opts ...Option) grpc.UnaryServerInterceptor {
+ return interceptors.UnaryServerInterceptor(&reportable{
+ opts: opts,
+ serverMetrics: m,
+ })
+}
+
+// StreamServerInterceptor is a gRPC server-side interceptor that provides Prometheus monitoring for Streaming RPCs.
+func (m *ServerMetrics) StreamServerInterceptor(opts ...Option) grpc.StreamServerInterceptor {
+ return interceptors.StreamServerInterceptor(&reportable{
+ opts: opts,
+ serverMetrics: m,
+ })
+}
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus/server_options.go b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus/server_options.go
new file mode 100644
index 0000000000..14340637d1
--- /dev/null
+++ b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus/server_options.go
@@ -0,0 +1,56 @@
+// Copyright (c) The go-grpc-middleware Authors.
+// Licensed under the Apache License 2.0.
+
+package prometheus
+
+import (
+ "context"
+
+ "github.com/prometheus/client_golang/prometheus"
+)
+
+type exemplarFromCtxFn func(ctx context.Context) prometheus.Labels
+type labelsFromCtxFn func(metadata context.Context) prometheus.Labels
+
+type serverMetricsConfig struct {
+ counterOpts counterOptions
+ // histogramOpts stores the options for creating the histogram with dynamic labels
+ histogramOpts histogramOptions
+ // enableHistogram indicates whether histogram should be created
+ enableHistogram bool
+ // contextLabels defines the names of dynamic labels to be extracted from context
+ contextLabels []string
+}
+
+type ServerMetricsOption func(*serverMetricsConfig)
+
+func (c *serverMetricsConfig) apply(opts []ServerMetricsOption) {
+ for _, o := range opts {
+ o(c)
+ }
+}
+
+// WithServerCounterOptions sets counter options.
+func WithServerCounterOptions(opts ...CounterOption) ServerMetricsOption {
+ return func(o *serverMetricsConfig) {
+ o.counterOpts = opts
+ }
+}
+
+// WithServerHandlingTimeHistogram turns on recording of handling time of RPCs.
+// Histogram metrics can be very expensive for Prometheus to retain and query.
+func WithServerHandlingTimeHistogram(opts ...HistogramOption) ServerMetricsOption {
+ return func(o *serverMetricsConfig) {
+ o.histogramOpts = opts
+ o.enableHistogram = true
+ }
+}
+
+// WithContextLabels configures the server metrics to include dynamic labels extracted from context.
+// The provided label names will be added to all server metrics as dynamic labels.
+// Use WithLabelsFromContext in the interceptor options to specify how to extract these labels from context.
+func WithContextLabels(labelNames ...string) ServerMetricsOption {
+ return func(o *serverMetricsConfig) {
+ o.contextLabels = labelNames
+ }
+}
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-middleware/v2/COPYRIGHT b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/v2/COPYRIGHT
new file mode 100644
index 0000000000..3b13627cdb
--- /dev/null
+++ b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/v2/COPYRIGHT
@@ -0,0 +1,2 @@
+Copyright (c) The go-grpc-middleware Authors.
+Licensed under the Apache License 2.0.
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-middleware/v2/LICENSE b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/v2/LICENSE
new file mode 100644
index 0000000000..b2b065037f
--- /dev/null
+++ b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/v2/LICENSE
@@ -0,0 +1,201 @@
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
\ No newline at end of file
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-middleware/v2/interceptors/callmeta.go b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/v2/interceptors/callmeta.go
new file mode 100644
index 0000000000..df3f5d11a8
--- /dev/null
+++ b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/v2/interceptors/callmeta.go
@@ -0,0 +1,67 @@
+// Copyright (c) The go-grpc-middleware Authors.
+// Licensed under the Apache License 2.0.
+
+package interceptors
+
+import (
+ "fmt"
+ "strings"
+
+ "google.golang.org/grpc"
+)
+
+func splitFullMethodName(fullMethod string) (string, string) {
+ fullMethod = strings.TrimPrefix(fullMethod, "/") // remove leading slash
+ if i := strings.Index(fullMethod, "/"); i >= 0 {
+ return fullMethod[:i], fullMethod[i+1:]
+ }
+ return "unknown", "unknown"
+}
+
+type CallMeta struct {
+ ReqOrNil any
+ Typ GRPCType
+ Service string
+ Method string
+ IsClient bool
+}
+
+func NewClientCallMeta(fullMethod string, streamDesc *grpc.StreamDesc, reqOrNil any) CallMeta {
+ c := CallMeta{IsClient: true, ReqOrNil: reqOrNil, Typ: Unary}
+ if streamDesc != nil {
+ c.Typ = clientStreamType(streamDesc)
+ }
+ c.Service, c.Method = splitFullMethodName(fullMethod)
+ return c
+}
+
+func NewServerCallMeta(fullMethod string, streamInfo *grpc.StreamServerInfo, reqOrNil any) CallMeta {
+ c := CallMeta{IsClient: false, ReqOrNil: reqOrNil, Typ: Unary}
+ if streamInfo != nil {
+ c.Typ = serverStreamType(streamInfo)
+ }
+ c.Service, c.Method = splitFullMethodName(fullMethod)
+ return c
+}
+
+func (c CallMeta) FullMethod() string {
+ return fmt.Sprintf("/%s/%s", c.Service, c.Method)
+}
+
+func clientStreamType(desc *grpc.StreamDesc) GRPCType {
+ if desc.ClientStreams && !desc.ServerStreams {
+ return ClientStream
+ } else if !desc.ClientStreams && desc.ServerStreams {
+ return ServerStream
+ }
+ return BidiStream
+}
+
+func serverStreamType(info *grpc.StreamServerInfo) GRPCType {
+ if info.IsClientStream && !info.IsServerStream {
+ return ClientStream
+ } else if !info.IsClientStream && info.IsServerStream {
+ return ServerStream
+ }
+ return BidiStream
+}
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-middleware/v2/interceptors/client.go b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/v2/interceptors/client.go
new file mode 100644
index 0000000000..7b4460e21e
--- /dev/null
+++ b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/v2/interceptors/client.go
@@ -0,0 +1,80 @@
+// Copyright (c) The go-grpc-middleware Authors.
+// Licensed under the Apache License 2.0.
+
+// Go gRPC Middleware monitoring interceptors for client-side gRPC.
+
+package interceptors
+
+import (
+ "context"
+ "errors"
+ "io"
+ "time"
+
+ "google.golang.org/grpc"
+)
+
+// UnaryClientInterceptor is a gRPC client-side interceptor that provides reporting for Unary RPCs.
+func UnaryClientInterceptor(reportable ClientReportable) grpc.UnaryClientInterceptor {
+ return func(ctx context.Context, method string, req, reply any, cc *grpc.ClientConn, invoker grpc.UnaryInvoker, opts ...grpc.CallOption) error {
+ r := newReport(NewClientCallMeta(method, nil, req))
+ reporter, newCtx := reportable.ClientReporter(ctx, r.callMeta)
+
+ reporter.PostMsgSend(req, nil, time.Since(r.startTime))
+ err := invoker(newCtx, method, req, reply, cc, opts...)
+ reporter.PostMsgReceive(reply, err, time.Since(r.startTime))
+ reporter.PostCall(err, time.Since(r.startTime))
+ return err
+ }
+}
+
+// StreamClientInterceptor is a gRPC client-side interceptor that provides reporting for Stream RPCs.
+func StreamClientInterceptor(reportable ClientReportable) grpc.StreamClientInterceptor {
+ return func(ctx context.Context, desc *grpc.StreamDesc, cc *grpc.ClientConn, method string, streamer grpc.Streamer, opts ...grpc.CallOption) (grpc.ClientStream, error) {
+ r := newReport(NewClientCallMeta(method, desc, nil))
+ reporter, newCtx := reportable.ClientReporter(ctx, r.callMeta)
+
+ clientStream, err := streamer(newCtx, desc, cc, method, opts...)
+ if err != nil {
+ reporter.PostCall(err, time.Since(r.startTime))
+ return nil, err
+ }
+ return &monitoredClientStream{ClientStream: clientStream, startTime: r.startTime, hasServerStream: desc.ServerStreams, reporter: reporter}, nil
+ }
+}
+
+// monitoredClientStream wraps grpc.ClientStream allowing each Sent/Recv of message to report.
+type monitoredClientStream struct {
+ grpc.ClientStream
+
+ startTime time.Time
+ hasServerStream bool
+ reporter Reporter
+}
+
+func (s *monitoredClientStream) SendMsg(m any) error {
+ start := time.Now()
+ err := s.ClientStream.SendMsg(m)
+ s.reporter.PostMsgSend(m, err, time.Since(start))
+ return err
+}
+
+func (s *monitoredClientStream) RecvMsg(m any) error {
+ start := time.Now()
+ err := s.ClientStream.RecvMsg(m)
+ s.reporter.PostMsgReceive(m, err, time.Since(start))
+
+ if s.hasServerStream {
+ if err == nil {
+ return nil
+ }
+ var postErr error
+ if !errors.Is(err, io.EOF) {
+ postErr = err
+ }
+ s.reporter.PostCall(postErr, time.Since(s.startTime))
+ } else {
+ s.reporter.PostCall(err, time.Since(s.startTime))
+ }
+ return err
+}
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-middleware/v2/interceptors/doc.go b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/v2/interceptors/doc.go
new file mode 100644
index 0000000000..2608b9a4f8
--- /dev/null
+++ b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/v2/interceptors/doc.go
@@ -0,0 +1,12 @@
+// Copyright (c) The go-grpc-middleware Authors.
+// Licensed under the Apache License 2.0.
+
+//
+/*
+interceptor is an internal package used by higher level middlewares. It allows injecting custom code in various
+places of the gRPC lifecycle.
+
+This particular package is intended for use by other middleware, metric, logging or otherwise.
+This allows code to be shared between different implementations.
+*/
+package interceptors
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-middleware/v2/interceptors/reporter.go b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/v2/interceptors/reporter.go
new file mode 100644
index 0000000000..c1731962a0
--- /dev/null
+++ b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/v2/interceptors/reporter.go
@@ -0,0 +1,73 @@
+// Copyright (c) The go-grpc-middleware Authors.
+// Licensed under the Apache License 2.0.
+
+package interceptors
+
+import (
+ "context"
+ "time"
+
+ "google.golang.org/grpc/codes"
+)
+
+type GRPCType string
+
+const (
+ Unary GRPCType = "unary"
+ ClientStream GRPCType = "client_stream"
+ ServerStream GRPCType = "server_stream"
+ BidiStream GRPCType = "bidi_stream"
+)
+
+var AllCodes = []codes.Code{
+ codes.OK, codes.Canceled, codes.Unknown, codes.InvalidArgument, codes.DeadlineExceeded, codes.NotFound,
+ codes.AlreadyExists, codes.PermissionDenied, codes.Unauthenticated, codes.ResourceExhausted,
+ codes.FailedPrecondition, codes.Aborted, codes.OutOfRange, codes.Unimplemented, codes.Internal,
+ codes.Unavailable, codes.DataLoss,
+}
+
+type ClientReportable interface {
+ ClientReporter(context.Context, CallMeta) (Reporter, context.Context)
+}
+
+type ServerReportable interface {
+ ServerReporter(context.Context, CallMeta) (Reporter, context.Context)
+}
+
+// CommonReportableFunc helper allows an easy way to implement reporter with common client and server logic.
+type CommonReportableFunc func(ctx context.Context, c CallMeta) (Reporter, context.Context)
+
+func (f CommonReportableFunc) ClientReporter(ctx context.Context, c CallMeta) (Reporter, context.Context) {
+ return f(ctx, c)
+}
+
+func (f CommonReportableFunc) ServerReporter(ctx context.Context, c CallMeta) (Reporter, context.Context) {
+ return f(ctx, c)
+}
+
+type Reporter interface {
+ PostCall(err error, rpcDuration time.Duration)
+ PostMsgSend(reqProto any, err error, sendDuration time.Duration)
+ PostMsgReceive(replyProto any, err error, recvDuration time.Duration)
+}
+
+var _ Reporter = NoopReporter{}
+
+type NoopReporter struct{}
+
+func (NoopReporter) PostCall(error, time.Duration) {}
+func (NoopReporter) PostMsgSend(any, error, time.Duration) {}
+func (NoopReporter) PostMsgReceive(any, error, time.Duration) {}
+
+type report struct {
+ callMeta CallMeta
+ startTime time.Time
+}
+
+func newReport(callMeta CallMeta) report {
+ r := report{
+ startTime: time.Now(),
+ callMeta: callMeta,
+ }
+ return r
+}
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-middleware/v2/interceptors/server.go b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/v2/interceptors/server.go
new file mode 100644
index 0000000000..0484109069
--- /dev/null
+++ b/vendor/github.com/grpc-ecosystem/go-grpc-middleware/v2/interceptors/server.go
@@ -0,0 +1,65 @@
+// Copyright (c) The go-grpc-middleware Authors.
+// Licensed under the Apache License 2.0.
+
+// Go gRPC Middleware monitoring interceptors for server-side gRPC.
+
+package interceptors
+
+import (
+ "context"
+ "time"
+
+ "google.golang.org/grpc"
+)
+
+// UnaryServerInterceptor is a gRPC server-side interceptor that provides reporting for Unary RPCs.
+func UnaryServerInterceptor(reportable ServerReportable) grpc.UnaryServerInterceptor {
+ return func(ctx context.Context, req any, info *grpc.UnaryServerInfo, handler grpc.UnaryHandler) (any, error) {
+ r := newReport(NewServerCallMeta(info.FullMethod, nil, req))
+ reporter, newCtx := reportable.ServerReporter(ctx, r.callMeta)
+
+ reporter.PostMsgReceive(req, nil, time.Since(r.startTime))
+ resp, err := handler(newCtx, req)
+ reporter.PostMsgSend(resp, err, time.Since(r.startTime))
+
+ reporter.PostCall(err, time.Since(r.startTime))
+ return resp, err
+ }
+}
+
+// StreamServerInterceptor is a gRPC server-side interceptor that provides reporting for Streaming RPCs.
+func StreamServerInterceptor(reportable ServerReportable) grpc.StreamServerInterceptor {
+ return func(srv any, ss grpc.ServerStream, info *grpc.StreamServerInfo, handler grpc.StreamHandler) error {
+ r := newReport(NewServerCallMeta(info.FullMethod, info, nil))
+ reporter, newCtx := reportable.ServerReporter(ss.Context(), r.callMeta)
+ err := handler(srv, &monitoredServerStream{ServerStream: ss, newCtx: newCtx, reporter: reporter})
+ reporter.PostCall(err, time.Since(r.startTime))
+ return err
+ }
+}
+
+// monitoredStream wraps grpc.ServerStream allowing each Sent/Recv of message to report.
+type monitoredServerStream struct {
+ grpc.ServerStream
+
+ newCtx context.Context
+ reporter Reporter
+}
+
+func (s *monitoredServerStream) Context() context.Context {
+ return s.newCtx
+}
+
+func (s *monitoredServerStream) SendMsg(m any) error {
+ start := time.Now()
+ err := s.ServerStream.SendMsg(m)
+ s.reporter.PostMsgSend(m, err, time.Since(start))
+ return err
+}
+
+func (s *monitoredServerStream) RecvMsg(m any) error {
+ start := time.Now()
+ err := s.ServerStream.RecvMsg(m)
+ s.reporter.PostMsgReceive(m, err, time.Since(start))
+ return err
+}
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/.gitignore b/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/.gitignore
deleted file mode 100644
index 2233cff9d1..0000000000
--- a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/.gitignore
+++ /dev/null
@@ -1,201 +0,0 @@
-#vendor
-vendor/
-
-# Created by .ignore support plugin (hsz.mobi)
-coverage.txt
-### Go template
-# Compiled Object files, Static and Dynamic libs (Shared Objects)
-*.o
-*.a
-*.so
-
-# Folders
-_obj
-_test
-
-# Architecture specific extensions/prefixes
-*.[568vq]
-[568vq].out
-
-*.cgo1.go
-*.cgo2.c
-_cgo_defun.c
-_cgo_gotypes.go
-_cgo_export.*
-
-_testmain.go
-
-*.exe
-*.test
-*.prof
-### Windows template
-# Windows image file caches
-Thumbs.db
-ehthumbs.db
-
-# Folder config file
-Desktop.ini
-
-# Recycle Bin used on file shares
-$RECYCLE.BIN/
-
-# Windows Installer files
-*.cab
-*.msi
-*.msm
-*.msp
-
-# Windows shortcuts
-*.lnk
-### Kate template
-# Swap Files #
-.*.kate-swp
-.swp.*
-### SublimeText template
-# cache files for sublime text
-*.tmlanguage.cache
-*.tmPreferences.cache
-*.stTheme.cache
-
-# workspace files are user-specific
-*.sublime-workspace
-
-# project files should be checked into the repository, unless a significant
-# proportion of contributors will probably not be using SublimeText
-# *.sublime-project
-
-# sftp configuration file
-sftp-config.json
-### Linux template
-*~
-
-# temporary files which can be created if a process still has a handle open of a deleted file
-.fuse_hidden*
-
-# KDE directory preferences
-.directory
-
-# Linux trash folder which might appear on any partition or disk
-.Trash-*
-### JetBrains template
-# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio and Webstorm
-# Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839
-
-# User-specific stuff:
-.idea
-.idea/tasks.xml
-.idea/dictionaries
-.idea/vcs.xml
-.idea/jsLibraryMappings.xml
-
-# Sensitive or high-churn files:
-.idea/dataSources.ids
-.idea/dataSources.xml
-.idea/dataSources.local.xml
-.idea/sqlDataSources.xml
-.idea/dynamic.xml
-.idea/uiDesigner.xml
-
-# Gradle:
-.idea/gradle.xml
-.idea/libraries
-
-# Mongo Explorer plugin:
-.idea/mongoSettings.xml
-
-## File-based project format:
-*.iws
-
-## Plugin-specific files:
-
-# IntelliJ
-/out/
-
-# mpeltonen/sbt-idea plugin
-.idea_modules/
-
-# JIRA plugin
-atlassian-ide-plugin.xml
-
-# Crashlytics plugin (for Android Studio and IntelliJ)
-com_crashlytics_export_strings.xml
-crashlytics.properties
-crashlytics-build.properties
-fabric.properties
-### Xcode template
-# Xcode
-#
-# gitignore contributors: remember to update Global/Xcode.gitignore, Objective-C.gitignore & Swift.gitignore
-
-## Build generated
-build/
-DerivedData/
-
-## Various settings
-*.pbxuser
-!default.pbxuser
-*.mode1v3
-!default.mode1v3
-*.mode2v3
-!default.mode2v3
-*.perspectivev3
-!default.perspectivev3
-xcuserdata/
-
-## Other
-*.moved-aside
-*.xccheckout
-*.xcscmblueprint
-### Eclipse template
-
-.metadata
-bin/
-tmp/
-*.tmp
-*.bak
-*.swp
-*~.nib
-local.properties
-.settings/
-.loadpath
-.recommenders
-
-# Eclipse Core
-.project
-
-# External tool builders
-.externalToolBuilders/
-
-# Locally stored "Eclipse launch configurations"
-*.launch
-
-# PyDev specific (Python IDE for Eclipse)
-*.pydevproject
-
-# CDT-specific (C/C++ Development Tooling)
-.cproject
-
-# JDT-specific (Eclipse Java Development Tools)
-.classpath
-
-# Java annotation processor (APT)
-.factorypath
-
-# PDT-specific (PHP Development Tools)
-.buildpath
-
-# sbteclipse plugin
-.target
-
-# Tern plugin
-.tern-project
-
-# TeXlipse plugin
-.texlipse
-
-# STS (Spring Tool Suite)
-.springBeans
-
-# Code Recommenders
-.recommenders/
-
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/.travis.yml b/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/.travis.yml
deleted file mode 100644
index ac037f5573..0000000000
--- a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/.travis.yml
+++ /dev/null
@@ -1,23 +0,0 @@
-sudo: false
-language: go
-go:
- - 1.9.x
- - 1.10.x
- - 1.11.x
- - 1.12.x
- - master
-
-env:
-- GO111MODULE=on
-
-install:
-# With Go modules (eg Go >= 1.11), it isn't necessary anymore to 'go get' the dependencies before running the tests.
-- if [[ $TRAVIS_GO_VERSION =~ ^1\.(7|8|9|10)\. ]]; then go get github.com/prometheus/client_golang/prometheus; fi
-- if [[ $TRAVIS_GO_VERSION =~ ^1\.(7|8|9|10)\. ]]; then go get google.golang.org/grpc; fi
-- if [[ $TRAVIS_GO_VERSION =~ ^1\.(7|8|9|10)\. ]]; then go get github.com/stretchr/testify; fi
-
-script:
-- make test
-
-after_success:
-- bash <(curl -s https://codecov.io/bash)
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/CHANGELOG.md b/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/CHANGELOG.md
deleted file mode 100644
index 14e8869cb9..0000000000
--- a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/CHANGELOG.md
+++ /dev/null
@@ -1,28 +0,0 @@
-# Changelog
-All notable changes to this project will be documented in this file.
-
-The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
-and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
-
-## [Unreleased]
-
-### Added
-* Support for error unwrapping. (Supported for `github.com/pkg/errors` and native wrapping added in go1.13)
-
-## [1.2.0](https://github.com/grpc-ecosystem/go-grpc-prometheus/releases/tag/v1.2.0) - 2018-06-04
-
-### Added
-
-* Require go 1.9 or later and test against these versions in CI.
-* Provide metrics object as `prometheus.Collector`, for conventional metric registration.
-* Support non-default/global Prometheus registry.
-* Allow configuring counters with `prometheus.CounterOpts`.
-
-### Changed
-
-* Remove usage of deprecated `grpc.Code()`.
-* Remove usage of deprecated `grpc.Errorf` and replace with `status.Errorf`.
-
----
-
-This changelog was started with version `v1.2.0`, for earlier versions refer to the respective [GitHub releases](https://github.com/grpc-ecosystem/go-grpc-prometheus/releases).
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/README.md b/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/README.md
deleted file mode 100644
index 2b2824028c..0000000000
--- a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/README.md
+++ /dev/null
@@ -1,256 +0,0 @@
-# Go gRPC Interceptors for Prometheus monitoring
-
-[](https://travis-ci.org/grpc-ecosystem/go-grpc-prometheus)
-[](http://goreportcard.com/report/grpc-ecosystem/go-grpc-prometheus)
-[](https://godoc.org/github.com/grpc-ecosystem/go-grpc-prometheus)
-[](https://sourcegraph.com/github.com/grpc-ecosystem/go-grpc-prometheus/?badge)
-[](https://codecov.io/gh/grpc-ecosystem/go-grpc-prometheus)
-[](https://join.slack.com/t/improbable-eng/shared_invite/enQtMzQ1ODcyMzQ5MjM4LWY5ZWZmNGM2ODc5MmViNmQ3ZTA3ZTY3NzQwOTBlMTkzZmIxZTIxODk0OWU3YjZhNWVlNDU3MDlkZGViZjhkMjc)
-[](LICENSE)
-
-> :warning: We consolidating projects and moving to single repo where we have more control and awareness. We are moving this codebase for longterm to https://github.com/grpc-ecosystem/go-grpc-middleware/tree/v2. Existing state of Prometheus middleware was moved to https://github.com/grpc-ecosystem/go-grpc-middleware/tree/v2/providers/openmetrics
-If you want to change something effectively long term, I would suggest proposing PR against https://github.com/grpc-ecosystem/go-grpc-middleware/tree/v2/providers/openmetrics instead (notice `v2 `branch, not master!).
-
-
-
-
-[Prometheus](https://prometheus.io/) monitoring for your [gRPC Go](https://github.com/grpc/grpc-go) servers and clients.
-
-A sister implementation for [gRPC Java](https://github.com/grpc/grpc-java) (same metrics, same semantics) is in [grpc-ecosystem/java-grpc-prometheus](https://github.com/grpc-ecosystem/java-grpc-prometheus).
-
-## Interceptors
-
-[gRPC Go](https://github.com/grpc/grpc-go) recently acquired support for Interceptors, i.e. middleware that is executed
-by a gRPC Server before the request is passed onto the user's application logic. It is a perfect way to implement
-common patterns: auth, logging and... monitoring.
-
-To use Interceptors in chains, please see [`go-grpc-middleware`](https://github.com/mwitkow/go-grpc-middleware).
-
-This library requires Go 1.9 or later.
-
-## Usage
-
-There are two types of interceptors: client-side and server-side. This package provides monitoring Interceptors for both.
-
-### Server-side
-
-```go
-import "github.com/grpc-ecosystem/go-grpc-prometheus"
-...
- // Initialize your gRPC server's interceptor.
- myServer := grpc.NewServer(
- grpc.StreamInterceptor(grpc_prometheus.StreamServerInterceptor),
- grpc.UnaryInterceptor(grpc_prometheus.UnaryServerInterceptor),
- )
- // Register your gRPC service implementations.
- myservice.RegisterMyServiceServer(s.server, &myServiceImpl{})
- // After all your registrations, make sure all of the Prometheus metrics are initialized.
- grpc_prometheus.Register(myServer)
- // Register Prometheus metrics handler.
- http.Handle("/metrics", promhttp.Handler())
-...
-```
-
-### Client-side
-
-```go
-import "github.com/grpc-ecosystem/go-grpc-prometheus"
-...
- clientConn, err = grpc.Dial(
- address,
- grpc.WithUnaryInterceptor(grpc_prometheus.UnaryClientInterceptor),
- grpc.WithStreamInterceptor(grpc_prometheus.StreamClientInterceptor)
- )
- client = pb_testproto.NewTestServiceClient(clientConn)
- resp, err := client.PingEmpty(s.ctx, &myservice.Request{Msg: "hello"})
-...
-```
-
-# Metrics
-
-## Labels
-
-All server-side metrics start with `grpc_server` as Prometheus subsystem name. All client-side metrics start with `grpc_client`. Both of them have mirror-concepts. Similarly all methods
-contain the same rich labels:
-
- * `grpc_service` - the [gRPC service](http://www.grpc.io/docs/#defining-a-service) name, which is the combination of protobuf `package` and
- the `grpc_service` section name. E.g. for `package = mwitkow.testproto` and
- `service TestService` the label will be `grpc_service="mwitkow.testproto.TestService"`
- * `grpc_method` - the name of the method called on the gRPC service. E.g.
- `grpc_method="Ping"`
- * `grpc_type` - the gRPC [type of request](http://www.grpc.io/docs/guides/concepts.html#rpc-life-cycle).
- Differentiating between the two is important especially for latency measurements.
-
- - `unary` is single request, single response RPC
- - `client_stream` is a multi-request, single response RPC
- - `server_stream` is a single request, multi-response RPC
- - `bidi_stream` is a multi-request, multi-response RPC
-
-
-Additionally for completed RPCs, the following labels are used:
-
- * `grpc_code` - the human-readable [gRPC status code](https://github.com/grpc/grpc-go/blob/master/codes/codes.go).
- The list of all statuses is to long, but here are some common ones:
-
- - `OK` - means the RPC was successful
- - `IllegalArgument` - RPC contained bad values
- - `Internal` - server-side error not disclosed to the clients
-
-## Counters
-
-The counters and their up to date documentation is in [server_reporter.go](server_reporter.go) and [client_reporter.go](client_reporter.go)
-the respective Prometheus handler (usually `/metrics`).
-
-For the purpose of this documentation we will only discuss `grpc_server` metrics. The `grpc_client` ones contain mirror concepts.
-
-For simplicity, let's assume we're tracking a single server-side RPC call of [`mwitkow.testproto.TestService`](examples/testproto/test.proto),
-calling the method `PingList`. The call succeeds and returns 20 messages in the stream.
-
-First, immediately after the server receives the call it will increment the
-`grpc_server_started_total` and start the handling time clock (if histograms are enabled).
-
-```jsoniq
-grpc_server_started_total{grpc_method="PingList",grpc_service="mwitkow.testproto.TestService",grpc_type="server_stream"} 1
-```
-
-Then the user logic gets invoked. It receives one message from the client containing the request
-(it's a `server_stream`):
-
-```jsoniq
-grpc_server_msg_received_total{grpc_method="PingList",grpc_service="mwitkow.testproto.TestService",grpc_type="server_stream"} 1
-```
-
-The user logic may return an error, or send multiple messages back to the client. In this case, on
-each of the 20 messages sent back, a counter will be incremented:
-
-```jsoniq
-grpc_server_msg_sent_total{grpc_method="PingList",grpc_service="mwitkow.testproto.TestService",grpc_type="server_stream"} 20
-```
-
-After the call completes, its status (`OK` or other [gRPC status code](https://github.com/grpc/grpc-go/blob/master/codes/codes.go))
-and the relevant call labels increment the `grpc_server_handled_total` counter.
-
-```jsoniq
-grpc_server_handled_total{grpc_code="OK",grpc_method="PingList",grpc_service="mwitkow.testproto.TestService",grpc_type="server_stream"} 1
-```
-
-## Histograms
-
-[Prometheus histograms](https://prometheus.io/docs/concepts/metric_types/#histogram) are a great way
-to measure latency distributions of your RPCs. However, since it is bad practice to have metrics
-of [high cardinality](https://prometheus.io/docs/practices/instrumentation/#do-not-overuse-labels)
-the latency monitoring metrics are disabled by default. To enable them please call the following
-in your server initialization code:
-
-```jsoniq
-grpc_prometheus.EnableHandlingTimeHistogram()
-```
-
-After the call completes, its handling time will be recorded in a [Prometheus histogram](https://prometheus.io/docs/concepts/metric_types/#histogram)
-variable `grpc_server_handling_seconds`. The histogram variable contains three sub-metrics:
-
- * `grpc_server_handling_seconds_count` - the count of all completed RPCs by status and method
- * `grpc_server_handling_seconds_sum` - cumulative time of RPCs by status and method, useful for
- calculating average handling times
- * `grpc_server_handling_seconds_bucket` - contains the counts of RPCs by status and method in respective
- handling-time buckets. These buckets can be used by Prometheus to estimate SLAs (see [here](https://prometheus.io/docs/practices/histograms/))
-
-The counter values will look as follows:
-
-```jsoniq
-grpc_server_handling_seconds_bucket{grpc_code="OK",grpc_method="PingList",grpc_service="mwitkow.testproto.TestService",grpc_type="server_stream",le="0.005"} 1
-grpc_server_handling_seconds_bucket{grpc_code="OK",grpc_method="PingList",grpc_service="mwitkow.testproto.TestService",grpc_type="server_stream",le="0.01"} 1
-grpc_server_handling_seconds_bucket{grpc_code="OK",grpc_method="PingList",grpc_service="mwitkow.testproto.TestService",grpc_type="server_stream",le="0.025"} 1
-grpc_server_handling_seconds_bucket{grpc_code="OK",grpc_method="PingList",grpc_service="mwitkow.testproto.TestService",grpc_type="server_stream",le="0.05"} 1
-grpc_server_handling_seconds_bucket{grpc_code="OK",grpc_method="PingList",grpc_service="mwitkow.testproto.TestService",grpc_type="server_stream",le="0.1"} 1
-grpc_server_handling_seconds_bucket{grpc_code="OK",grpc_method="PingList",grpc_service="mwitkow.testproto.TestService",grpc_type="server_stream",le="0.25"} 1
-grpc_server_handling_seconds_bucket{grpc_code="OK",grpc_method="PingList",grpc_service="mwitkow.testproto.TestService",grpc_type="server_stream",le="0.5"} 1
-grpc_server_handling_seconds_bucket{grpc_code="OK",grpc_method="PingList",grpc_service="mwitkow.testproto.TestService",grpc_type="server_stream",le="1"} 1
-grpc_server_handling_seconds_bucket{grpc_code="OK",grpc_method="PingList",grpc_service="mwitkow.testproto.TestService",grpc_type="server_stream",le="2.5"} 1
-grpc_server_handling_seconds_bucket{grpc_code="OK",grpc_method="PingList",grpc_service="mwitkow.testproto.TestService",grpc_type="server_stream",le="5"} 1
-grpc_server_handling_seconds_bucket{grpc_code="OK",grpc_method="PingList",grpc_service="mwitkow.testproto.TestService",grpc_type="server_stream",le="10"} 1
-grpc_server_handling_seconds_bucket{grpc_code="OK",grpc_method="PingList",grpc_service="mwitkow.testproto.TestService",grpc_type="server_stream",le="+Inf"} 1
-grpc_server_handling_seconds_sum{grpc_code="OK",grpc_method="PingList",grpc_service="mwitkow.testproto.TestService",grpc_type="server_stream"} 0.0003866430000000001
-grpc_server_handling_seconds_count{grpc_code="OK",grpc_method="PingList",grpc_service="mwitkow.testproto.TestService",grpc_type="server_stream"} 1
-```
-
-
-## Useful query examples
-
-Prometheus philosophy is to provide raw metrics to the monitoring system, and
-let the aggregations be handled there. The verbosity of above metrics make it possible to have that
-flexibility. Here's a couple of useful monitoring queries:
-
-
-### request inbound rate
-```jsoniq
-sum(rate(grpc_server_started_total{job="foo"}[1m])) by (grpc_service)
-```
-For `job="foo"` (common label to differentiate between Prometheus monitoring targets), calculate the
-rate of requests per second (1 minute window) for each gRPC `grpc_service` that the job has. Please note
-how the `grpc_method` is being omitted here: all methods of a given gRPC service will be summed together.
-
-### unary request error rate
-```jsoniq
-sum(rate(grpc_server_handled_total{job="foo",grpc_type="unary",grpc_code!="OK"}[1m])) by (grpc_service)
-```
-For `job="foo"`, calculate the per-`grpc_service` rate of `unary` (1:1) RPCs that failed, i.e. the
-ones that didn't finish with `OK` code.
-
-### unary request error percentage
-```jsoniq
-sum(rate(grpc_server_handled_total{job="foo",grpc_type="unary",grpc_code!="OK"}[1m])) by (grpc_service)
- /
-sum(rate(grpc_server_started_total{job="foo",grpc_type="unary"}[1m])) by (grpc_service)
- * 100.0
-```
-For `job="foo"`, calculate the percentage of failed requests by service. It's easy to notice that
-this is a combination of the two above examples. This is an example of a query you would like to
-[alert on](https://prometheus.io/docs/alerting/rules/) in your system for SLA violations, e.g.
-"no more than 1% requests should fail".
-
-### average response stream size
-```jsoniq
-sum(rate(grpc_server_msg_sent_total{job="foo",grpc_type="server_stream"}[10m])) by (grpc_service)
- /
-sum(rate(grpc_server_started_total{job="foo",grpc_type="server_stream"}[10m])) by (grpc_service)
-```
-For `job="foo"` what is the `grpc_service`-wide `10m` average of messages returned for all `
-server_stream` RPCs. This allows you to track the stream sizes returned by your system, e.g. allows
-you to track when clients started to send "wide" queries that ret
-Note the divisor is the number of started RPCs, in order to account for in-flight requests.
-
-### 99%-tile latency of unary requests
-```jsoniq
-histogram_quantile(0.99,
- sum(rate(grpc_server_handling_seconds_bucket{job="foo",grpc_type="unary"}[5m])) by (grpc_service,le)
-)
-```
-For `job="foo"`, returns an 99%-tile [quantile estimation](https://prometheus.io/docs/practices/histograms/#quantiles)
-of the handling time of RPCs per service. Please note the `5m` rate, this means that the quantile
-estimation will take samples in a rolling `5m` window. When combined with other quantiles
-(e.g. 50%, 90%), this query gives you tremendous insight into the responsiveness of your system
-(e.g. impact of caching).
-
-### percentage of slow unary queries (>250ms)
-```jsoniq
-100.0 - (
-sum(rate(grpc_server_handling_seconds_bucket{job="foo",grpc_type="unary",le="0.25"}[5m])) by (grpc_service)
- /
-sum(rate(grpc_server_handling_seconds_count{job="foo",grpc_type="unary"}[5m])) by (grpc_service)
-) * 100.0
-```
-For `job="foo"` calculate the by-`grpc_service` fraction of slow requests that took longer than `0.25`
-seconds. This query is relatively complex, since the Prometheus aggregations use `le` (less or equal)
-buckets, meaning that counting "fast" requests fractions is easier. However, simple maths helps.
-This is an example of a query you would like to alert on in your system for SLA violations,
-e.g. "less than 1% of requests are slower than 250ms".
-
-
-## Status
-
-This code has been used since August 2015 as the basis for monitoring of *production* gRPC micro services at [Improbable](https://improbable.io).
-
-## License
-
-`go-grpc-prometheus` is released under the Apache 2.0 license. See the [LICENSE](LICENSE) file for details.
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/client.go b/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/client.go
deleted file mode 100644
index dc1a6e6f66..0000000000
--- a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/client.go
+++ /dev/null
@@ -1,57 +0,0 @@
-// Copyright 2016 Michal Witkowski. All Rights Reserved.
-// See LICENSE for licensing terms.
-
-// gRPC Prometheus monitoring interceptors for client-side gRPC.
-
-package grpc_prometheus
-
-import (
- prom "github.com/prometheus/client_golang/prometheus"
-)
-
-var (
- // DefaultClientMetrics is the default instance of ClientMetrics. It is
- // intended to be used in conjunction the default Prometheus metrics
- // registry.
- DefaultClientMetrics = NewClientMetrics()
-
- // UnaryClientInterceptor is a gRPC client-side interceptor that provides Prometheus monitoring for Unary RPCs.
- UnaryClientInterceptor = DefaultClientMetrics.UnaryClientInterceptor()
-
- // StreamClientInterceptor is a gRPC client-side interceptor that provides Prometheus monitoring for Streaming RPCs.
- StreamClientInterceptor = DefaultClientMetrics.StreamClientInterceptor()
-)
-
-func init() {
- prom.MustRegister(DefaultClientMetrics.clientStartedCounter)
- prom.MustRegister(DefaultClientMetrics.clientHandledCounter)
- prom.MustRegister(DefaultClientMetrics.clientStreamMsgReceived)
- prom.MustRegister(DefaultClientMetrics.clientStreamMsgSent)
-}
-
-// EnableClientHandlingTimeHistogram turns on recording of handling time of
-// RPCs. Histogram metrics can be very expensive for Prometheus to retain and
-// query. This function acts on the DefaultClientMetrics variable and the
-// default Prometheus metrics registry.
-func EnableClientHandlingTimeHistogram(opts ...HistogramOption) {
- DefaultClientMetrics.EnableClientHandlingTimeHistogram(opts...)
- prom.Register(DefaultClientMetrics.clientHandledHistogram)
-}
-
-// EnableClientStreamReceiveTimeHistogram turns on recording of
-// single message receive time of streaming RPCs.
-// This function acts on the DefaultClientMetrics variable and the
-// default Prometheus metrics registry.
-func EnableClientStreamReceiveTimeHistogram(opts ...HistogramOption) {
- DefaultClientMetrics.EnableClientStreamReceiveTimeHistogram(opts...)
- prom.Register(DefaultClientMetrics.clientStreamRecvHistogram)
-}
-
-// EnableClientStreamSendTimeHistogram turns on recording of
-// single message send time of streaming RPCs.
-// This function acts on the DefaultClientMetrics variable and the
-// default Prometheus metrics registry.
-func EnableClientStreamSendTimeHistogram(opts ...HistogramOption) {
- DefaultClientMetrics.EnableClientStreamSendTimeHistogram(opts...)
- prom.Register(DefaultClientMetrics.clientStreamSendHistogram)
-}
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/client_metrics.go b/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/client_metrics.go
deleted file mode 100644
index a344084262..0000000000
--- a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/client_metrics.go
+++ /dev/null
@@ -1,244 +0,0 @@
-package grpc_prometheus
-
-import (
- "context"
- "io"
-
- prom "github.com/prometheus/client_golang/prometheus"
- "google.golang.org/grpc"
- "google.golang.org/grpc/codes"
- "google.golang.org/grpc/status"
-)
-
-// ClientMetrics represents a collection of metrics to be registered on a
-// Prometheus metrics registry for a gRPC client.
-type ClientMetrics struct {
- clientStartedCounter *prom.CounterVec
- clientHandledCounter *prom.CounterVec
- clientStreamMsgReceived *prom.CounterVec
- clientStreamMsgSent *prom.CounterVec
-
- clientHandledHistogramEnabled bool
- clientHandledHistogramOpts prom.HistogramOpts
- clientHandledHistogram *prom.HistogramVec
-
- clientStreamRecvHistogramEnabled bool
- clientStreamRecvHistogramOpts prom.HistogramOpts
- clientStreamRecvHistogram *prom.HistogramVec
-
- clientStreamSendHistogramEnabled bool
- clientStreamSendHistogramOpts prom.HistogramOpts
- clientStreamSendHistogram *prom.HistogramVec
-}
-
-// NewClientMetrics returns a ClientMetrics object. Use a new instance of
-// ClientMetrics when not using the default Prometheus metrics registry, for
-// example when wanting to control which metrics are added to a registry as
-// opposed to automatically adding metrics via init functions.
-func NewClientMetrics(counterOpts ...CounterOption) *ClientMetrics {
- opts := counterOptions(counterOpts)
- return &ClientMetrics{
- clientStartedCounter: prom.NewCounterVec(
- opts.apply(prom.CounterOpts{
- Name: "grpc_client_started_total",
- Help: "Total number of RPCs started on the client.",
- }), []string{"grpc_type", "grpc_service", "grpc_method"}),
-
- clientHandledCounter: prom.NewCounterVec(
- opts.apply(prom.CounterOpts{
- Name: "grpc_client_handled_total",
- Help: "Total number of RPCs completed by the client, regardless of success or failure.",
- }), []string{"grpc_type", "grpc_service", "grpc_method", "grpc_code"}),
-
- clientStreamMsgReceived: prom.NewCounterVec(
- opts.apply(prom.CounterOpts{
- Name: "grpc_client_msg_received_total",
- Help: "Total number of RPC stream messages received by the client.",
- }), []string{"grpc_type", "grpc_service", "grpc_method"}),
-
- clientStreamMsgSent: prom.NewCounterVec(
- opts.apply(prom.CounterOpts{
- Name: "grpc_client_msg_sent_total",
- Help: "Total number of gRPC stream messages sent by the client.",
- }), []string{"grpc_type", "grpc_service", "grpc_method"}),
-
- clientHandledHistogramEnabled: false,
- clientHandledHistogramOpts: prom.HistogramOpts{
- Name: "grpc_client_handling_seconds",
- Help: "Histogram of response latency (seconds) of the gRPC until it is finished by the application.",
- Buckets: prom.DefBuckets,
- },
- clientHandledHistogram: nil,
- clientStreamRecvHistogramEnabled: false,
- clientStreamRecvHistogramOpts: prom.HistogramOpts{
- Name: "grpc_client_msg_recv_handling_seconds",
- Help: "Histogram of response latency (seconds) of the gRPC single message receive.",
- Buckets: prom.DefBuckets,
- },
- clientStreamRecvHistogram: nil,
- clientStreamSendHistogramEnabled: false,
- clientStreamSendHistogramOpts: prom.HistogramOpts{
- Name: "grpc_client_msg_send_handling_seconds",
- Help: "Histogram of response latency (seconds) of the gRPC single message send.",
- Buckets: prom.DefBuckets,
- },
- clientStreamSendHistogram: nil,
- }
-}
-
-// Describe sends the super-set of all possible descriptors of metrics
-// collected by this Collector to the provided channel and returns once
-// the last descriptor has been sent.
-func (m *ClientMetrics) Describe(ch chan<- *prom.Desc) {
- m.clientStartedCounter.Describe(ch)
- m.clientHandledCounter.Describe(ch)
- m.clientStreamMsgReceived.Describe(ch)
- m.clientStreamMsgSent.Describe(ch)
- if m.clientHandledHistogramEnabled {
- m.clientHandledHistogram.Describe(ch)
- }
- if m.clientStreamRecvHistogramEnabled {
- m.clientStreamRecvHistogram.Describe(ch)
- }
- if m.clientStreamSendHistogramEnabled {
- m.clientStreamSendHistogram.Describe(ch)
- }
-}
-
-// Collect is called by the Prometheus registry when collecting
-// metrics. The implementation sends each collected metric via the
-// provided channel and returns once the last metric has been sent.
-func (m *ClientMetrics) Collect(ch chan<- prom.Metric) {
- m.clientStartedCounter.Collect(ch)
- m.clientHandledCounter.Collect(ch)
- m.clientStreamMsgReceived.Collect(ch)
- m.clientStreamMsgSent.Collect(ch)
- if m.clientHandledHistogramEnabled {
- m.clientHandledHistogram.Collect(ch)
- }
- if m.clientStreamRecvHistogramEnabled {
- m.clientStreamRecvHistogram.Collect(ch)
- }
- if m.clientStreamSendHistogramEnabled {
- m.clientStreamSendHistogram.Collect(ch)
- }
-}
-
-// EnableClientHandlingTimeHistogram turns on recording of handling time of RPCs.
-// Histogram metrics can be very expensive for Prometheus to retain and query.
-func (m *ClientMetrics) EnableClientHandlingTimeHistogram(opts ...HistogramOption) {
- for _, o := range opts {
- o(&m.clientHandledHistogramOpts)
- }
- if !m.clientHandledHistogramEnabled {
- m.clientHandledHistogram = prom.NewHistogramVec(
- m.clientHandledHistogramOpts,
- []string{"grpc_type", "grpc_service", "grpc_method"},
- )
- }
- m.clientHandledHistogramEnabled = true
-}
-
-// EnableClientStreamReceiveTimeHistogram turns on recording of single message receive time of streaming RPCs.
-// Histogram metrics can be very expensive for Prometheus to retain and query.
-func (m *ClientMetrics) EnableClientStreamReceiveTimeHistogram(opts ...HistogramOption) {
- for _, o := range opts {
- o(&m.clientStreamRecvHistogramOpts)
- }
-
- if !m.clientStreamRecvHistogramEnabled {
- m.clientStreamRecvHistogram = prom.NewHistogramVec(
- m.clientStreamRecvHistogramOpts,
- []string{"grpc_type", "grpc_service", "grpc_method"},
- )
- }
-
- m.clientStreamRecvHistogramEnabled = true
-}
-
-// EnableClientStreamSendTimeHistogram turns on recording of single message send time of streaming RPCs.
-// Histogram metrics can be very expensive for Prometheus to retain and query.
-func (m *ClientMetrics) EnableClientStreamSendTimeHistogram(opts ...HistogramOption) {
- for _, o := range opts {
- o(&m.clientStreamSendHistogramOpts)
- }
-
- if !m.clientStreamSendHistogramEnabled {
- m.clientStreamSendHistogram = prom.NewHistogramVec(
- m.clientStreamSendHistogramOpts,
- []string{"grpc_type", "grpc_service", "grpc_method"},
- )
- }
-
- m.clientStreamSendHistogramEnabled = true
-}
-
-// UnaryClientInterceptor is a gRPC client-side interceptor that provides Prometheus monitoring for Unary RPCs.
-func (m *ClientMetrics) UnaryClientInterceptor() func(ctx context.Context, method string, req, reply interface{}, cc *grpc.ClientConn, invoker grpc.UnaryInvoker, opts ...grpc.CallOption) error {
- return func(ctx context.Context, method string, req, reply interface{}, cc *grpc.ClientConn, invoker grpc.UnaryInvoker, opts ...grpc.CallOption) error {
- monitor := newClientReporter(m, Unary, method)
- monitor.SentMessage()
- err := invoker(ctx, method, req, reply, cc, opts...)
- if err == nil {
- monitor.ReceivedMessage()
- }
- st, _ := status.FromError(err)
- monitor.Handled(st.Code())
- return err
- }
-}
-
-// StreamClientInterceptor is a gRPC client-side interceptor that provides Prometheus monitoring for Streaming RPCs.
-func (m *ClientMetrics) StreamClientInterceptor() func(ctx context.Context, desc *grpc.StreamDesc, cc *grpc.ClientConn, method string, streamer grpc.Streamer, opts ...grpc.CallOption) (grpc.ClientStream, error) {
- return func(ctx context.Context, desc *grpc.StreamDesc, cc *grpc.ClientConn, method string, streamer grpc.Streamer, opts ...grpc.CallOption) (grpc.ClientStream, error) {
- monitor := newClientReporter(m, clientStreamType(desc), method)
- clientStream, err := streamer(ctx, desc, cc, method, opts...)
- if err != nil {
- st, _ := status.FromError(err)
- monitor.Handled(st.Code())
- return nil, err
- }
- return &monitoredClientStream{clientStream, monitor}, nil
- }
-}
-
-func clientStreamType(desc *grpc.StreamDesc) grpcType {
- if desc.ClientStreams && !desc.ServerStreams {
- return ClientStream
- } else if !desc.ClientStreams && desc.ServerStreams {
- return ServerStream
- }
- return BidiStream
-}
-
-// monitoredClientStream wraps grpc.ClientStream allowing each Sent/Recv of message to increment counters.
-type monitoredClientStream struct {
- grpc.ClientStream
- monitor *clientReporter
-}
-
-func (s *monitoredClientStream) SendMsg(m interface{}) error {
- timer := s.monitor.SendMessageTimer()
- err := s.ClientStream.SendMsg(m)
- timer.ObserveDuration()
- if err == nil {
- s.monitor.SentMessage()
- }
- return err
-}
-
-func (s *monitoredClientStream) RecvMsg(m interface{}) error {
- timer := s.monitor.ReceiveMessageTimer()
- err := s.ClientStream.RecvMsg(m)
- timer.ObserveDuration()
-
- if err == nil {
- s.monitor.ReceivedMessage()
- } else if err == io.EOF {
- s.monitor.Handled(codes.OK)
- } else {
- st, _ := status.FromError(err)
- s.monitor.Handled(st.Code())
- }
- return err
-}
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/client_reporter.go b/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/client_reporter.go
deleted file mode 100644
index 286d6571ca..0000000000
--- a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/client_reporter.go
+++ /dev/null
@@ -1,79 +0,0 @@
-// Copyright 2016 Michal Witkowski. All Rights Reserved.
-// See LICENSE for licensing terms.
-
-package grpc_prometheus
-
-import (
- "time"
-
- "github.com/prometheus/client_golang/prometheus"
- "google.golang.org/grpc/codes"
-)
-
-type clientReporter struct {
- metrics *ClientMetrics
- rpcType grpcType
- serviceName string
- methodName string
- startTime time.Time
-}
-
-func newClientReporter(m *ClientMetrics, rpcType grpcType, fullMethod string) *clientReporter {
- r := &clientReporter{
- metrics: m,
- rpcType: rpcType,
- }
- if r.metrics.clientHandledHistogramEnabled {
- r.startTime = time.Now()
- }
- r.serviceName, r.methodName = splitMethodName(fullMethod)
- r.metrics.clientStartedCounter.WithLabelValues(string(r.rpcType), r.serviceName, r.methodName).Inc()
- return r
-}
-
-// timer is a helper interface to time functions.
-type timer interface {
- ObserveDuration() time.Duration
-}
-
-type noOpTimer struct {
-}
-
-func (noOpTimer) ObserveDuration() time.Duration {
- return 0
-}
-
-var emptyTimer = noOpTimer{}
-
-func (r *clientReporter) ReceiveMessageTimer() timer {
- if r.metrics.clientStreamRecvHistogramEnabled {
- hist := r.metrics.clientStreamRecvHistogram.WithLabelValues(string(r.rpcType), r.serviceName, r.methodName)
- return prometheus.NewTimer(hist)
- }
-
- return emptyTimer
-}
-
-func (r *clientReporter) ReceivedMessage() {
- r.metrics.clientStreamMsgReceived.WithLabelValues(string(r.rpcType), r.serviceName, r.methodName).Inc()
-}
-
-func (r *clientReporter) SendMessageTimer() timer {
- if r.metrics.clientStreamSendHistogramEnabled {
- hist := r.metrics.clientStreamSendHistogram.WithLabelValues(string(r.rpcType), r.serviceName, r.methodName)
- return prometheus.NewTimer(hist)
- }
-
- return emptyTimer
-}
-
-func (r *clientReporter) SentMessage() {
- r.metrics.clientStreamMsgSent.WithLabelValues(string(r.rpcType), r.serviceName, r.methodName).Inc()
-}
-
-func (r *clientReporter) Handled(code codes.Code) {
- r.metrics.clientHandledCounter.WithLabelValues(string(r.rpcType), r.serviceName, r.methodName, code.String()).Inc()
- if r.metrics.clientHandledHistogramEnabled {
- r.metrics.clientHandledHistogram.WithLabelValues(string(r.rpcType), r.serviceName, r.methodName).Observe(time.Since(r.startTime).Seconds())
- }
-}
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/makefile b/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/makefile
deleted file mode 100644
index 6cfc8d27fe..0000000000
--- a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/makefile
+++ /dev/null
@@ -1,14 +0,0 @@
-GOFILES_NOVENDOR = $(shell go list ./... | grep -v /vendor/)
-
-all: vet fmt test
-
-fmt:
- go fmt $(GOFILES_NOVENDOR)
-
-vet:
- go vet $(GOFILES_NOVENDOR)
-
-test: vet
- ./scripts/test_all.sh
-
-.PHONY: all vet test
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/metric_options.go b/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/metric_options.go
deleted file mode 100644
index 9d51aec981..0000000000
--- a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/metric_options.go
+++ /dev/null
@@ -1,41 +0,0 @@
-package grpc_prometheus
-
-import (
- prom "github.com/prometheus/client_golang/prometheus"
-)
-
-// A CounterOption lets you add options to Counter metrics using With* funcs.
-type CounterOption func(*prom.CounterOpts)
-
-type counterOptions []CounterOption
-
-func (co counterOptions) apply(o prom.CounterOpts) prom.CounterOpts {
- for _, f := range co {
- f(&o)
- }
- return o
-}
-
-// WithConstLabels allows you to add ConstLabels to Counter metrics.
-func WithConstLabels(labels prom.Labels) CounterOption {
- return func(o *prom.CounterOpts) {
- o.ConstLabels = labels
- }
-}
-
-// A HistogramOption lets you add options to Histogram metrics using With*
-// funcs.
-type HistogramOption func(*prom.HistogramOpts)
-
-// WithHistogramBuckets allows you to specify custom bucket ranges for histograms if EnableHandlingTimeHistogram is on.
-func WithHistogramBuckets(buckets []float64) HistogramOption {
- return func(o *prom.HistogramOpts) { o.Buckets = buckets }
-}
-
-// WithHistogramConstLabels allows you to add custom ConstLabels to
-// histograms metrics.
-func WithHistogramConstLabels(labels prom.Labels) HistogramOption {
- return func(o *prom.HistogramOpts) {
- o.ConstLabels = labels
- }
-}
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/packages/grpcstatus/grpcstatus.go b/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/packages/grpcstatus/grpcstatus.go
deleted file mode 100644
index 6c0f285f15..0000000000
--- a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/packages/grpcstatus/grpcstatus.go
+++ /dev/null
@@ -1,57 +0,0 @@
-package grpcstatus
-
-import (
- "google.golang.org/grpc/codes"
- "google.golang.org/grpc/status"
-)
-
-type gRPCStatus interface {
- GRPCStatus() *status.Status
-}
-
-func unwrapPkgErrorsGRPCStatus(err error) (*status.Status, bool) {
- type causer interface {
- Cause() error
- }
-
- // Unwrapping the github.com/pkg/errors causer interface, using `Cause` directly could miss some error implementing
- // the `GRPCStatus` function so we have to check it on our selves.
- unwrappedCauser := err
- for unwrappedCauser != nil {
- if s, ok := unwrappedCauser.(gRPCStatus); ok {
- return s.GRPCStatus(), true
- }
- cause, ok := unwrappedCauser.(causer)
- if !ok {
- break
- }
- unwrappedCauser = cause.Cause()
- }
- return nil, false
-}
-
-// Since error can be wrapped and the `FromError` function only checks for `GRPCStatus` function
-// and as a fallback uses the `Unknown` gRPC status we need to unwrap the error if possible to get the original status.
-// pkg/errors and Go native errors packages have two different approaches so we try to unwrap both types.
-// Eventually should be implemented in the go-grpc status function `FromError`. See https://github.com/grpc/grpc-go/issues/2934
-func FromError(err error) (s *status.Status, ok bool) {
- s, ok = status.FromError(err)
- if ok {
- return s, true
- }
-
- // Try to unwrap `github.com/pkg/errors` wrapped error
- s, ok = unwrapPkgErrorsGRPCStatus(err)
- if ok {
- return s, true
- }
-
- // Try to unwrap native wrapped errors using `fmt.Errorf` and `%w`
- s, ok = unwrapNativeWrappedGRPCStatus(err)
- if ok {
- return s, true
- }
-
- // We failed to unwrap any GRPSStatus so return default `Unknown`
- return status.New(codes.Unknown, err.Error()), false
-}
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/packages/grpcstatus/native_unwrap1.12-.go b/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/packages/grpcstatus/native_unwrap1.12-.go
deleted file mode 100644
index 0f575fe294..0000000000
--- a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/packages/grpcstatus/native_unwrap1.12-.go
+++ /dev/null
@@ -1,11 +0,0 @@
-// +build !go1.13
-
-package grpcstatus
-
-import (
- "google.golang.org/grpc/status"
-)
-
-func unwrapNativeWrappedGRPCStatus(err error) (*status.Status, bool) {
- return nil, false
-}
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/packages/grpcstatus/native_unwrap1.13+.go b/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/packages/grpcstatus/native_unwrap1.13+.go
deleted file mode 100644
index 216d057e89..0000000000
--- a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/packages/grpcstatus/native_unwrap1.13+.go
+++ /dev/null
@@ -1,17 +0,0 @@
-// +build go1.13
-
-package grpcstatus
-
-import (
- "errors"
- "google.golang.org/grpc/status"
-)
-
-func unwrapNativeWrappedGRPCStatus(err error) (*status.Status, bool) {
- // Unwrapping the native Go unwrap interface
- var unwrappedStatus gRPCStatus
- if ok := errors.As(err, &unwrappedStatus); ok {
- return unwrappedStatus.GRPCStatus(), true
- }
- return nil, false
-}
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/server.go b/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/server.go
deleted file mode 100644
index 322f99046f..0000000000
--- a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/server.go
+++ /dev/null
@@ -1,48 +0,0 @@
-// Copyright 2016 Michal Witkowski. All Rights Reserved.
-// See LICENSE for licensing terms.
-
-// gRPC Prometheus monitoring interceptors for server-side gRPC.
-
-package grpc_prometheus
-
-import (
- prom "github.com/prometheus/client_golang/prometheus"
- "google.golang.org/grpc"
-)
-
-var (
- // DefaultServerMetrics is the default instance of ServerMetrics. It is
- // intended to be used in conjunction the default Prometheus metrics
- // registry.
- DefaultServerMetrics = NewServerMetrics()
-
- // UnaryServerInterceptor is a gRPC server-side interceptor that provides Prometheus monitoring for Unary RPCs.
- UnaryServerInterceptor = DefaultServerMetrics.UnaryServerInterceptor()
-
- // StreamServerInterceptor is a gRPC server-side interceptor that provides Prometheus monitoring for Streaming RPCs.
- StreamServerInterceptor = DefaultServerMetrics.StreamServerInterceptor()
-)
-
-func init() {
- prom.MustRegister(DefaultServerMetrics.serverStartedCounter)
- prom.MustRegister(DefaultServerMetrics.serverHandledCounter)
- prom.MustRegister(DefaultServerMetrics.serverStreamMsgReceived)
- prom.MustRegister(DefaultServerMetrics.serverStreamMsgSent)
-}
-
-// Register takes a gRPC server and pre-initializes all counters to 0. This
-// allows for easier monitoring in Prometheus (no missing metrics), and should
-// be called *after* all services have been registered with the server. This
-// function acts on the DefaultServerMetrics variable.
-func Register(server *grpc.Server) {
- DefaultServerMetrics.InitializeMetrics(server)
-}
-
-// EnableHandlingTimeHistogram turns on recording of handling time
-// of RPCs. Histogram metrics can be very expensive for Prometheus
-// to retain and query. This function acts on the DefaultServerMetrics
-// variable and the default Prometheus metrics registry.
-func EnableHandlingTimeHistogram(opts ...HistogramOption) {
- DefaultServerMetrics.EnableHandlingTimeHistogram(opts...)
- prom.Register(DefaultServerMetrics.serverHandledHistogram)
-}
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/server_metrics.go b/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/server_metrics.go
deleted file mode 100644
index d28a46e89b..0000000000
--- a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/server_metrics.go
+++ /dev/null
@@ -1,186 +0,0 @@
-package grpc_prometheus
-
-import (
- "context"
- "github.com/grpc-ecosystem/go-grpc-prometheus/packages/grpcstatus"
- prom "github.com/prometheus/client_golang/prometheus"
-
- "google.golang.org/grpc"
-)
-
-// ServerMetrics represents a collection of metrics to be registered on a
-// Prometheus metrics registry for a gRPC server.
-type ServerMetrics struct {
- serverStartedCounter *prom.CounterVec
- serverHandledCounter *prom.CounterVec
- serverStreamMsgReceived *prom.CounterVec
- serverStreamMsgSent *prom.CounterVec
- serverHandledHistogramEnabled bool
- serverHandledHistogramOpts prom.HistogramOpts
- serverHandledHistogram *prom.HistogramVec
-}
-
-// NewServerMetrics returns a ServerMetrics object. Use a new instance of
-// ServerMetrics when not using the default Prometheus metrics registry, for
-// example when wanting to control which metrics are added to a registry as
-// opposed to automatically adding metrics via init functions.
-func NewServerMetrics(counterOpts ...CounterOption) *ServerMetrics {
- opts := counterOptions(counterOpts)
- return &ServerMetrics{
- serverStartedCounter: prom.NewCounterVec(
- opts.apply(prom.CounterOpts{
- Name: "grpc_server_started_total",
- Help: "Total number of RPCs started on the server.",
- }), []string{"grpc_type", "grpc_service", "grpc_method"}),
- serverHandledCounter: prom.NewCounterVec(
- opts.apply(prom.CounterOpts{
- Name: "grpc_server_handled_total",
- Help: "Total number of RPCs completed on the server, regardless of success or failure.",
- }), []string{"grpc_type", "grpc_service", "grpc_method", "grpc_code"}),
- serverStreamMsgReceived: prom.NewCounterVec(
- opts.apply(prom.CounterOpts{
- Name: "grpc_server_msg_received_total",
- Help: "Total number of RPC stream messages received on the server.",
- }), []string{"grpc_type", "grpc_service", "grpc_method"}),
- serverStreamMsgSent: prom.NewCounterVec(
- opts.apply(prom.CounterOpts{
- Name: "grpc_server_msg_sent_total",
- Help: "Total number of gRPC stream messages sent by the server.",
- }), []string{"grpc_type", "grpc_service", "grpc_method"}),
- serverHandledHistogramEnabled: false,
- serverHandledHistogramOpts: prom.HistogramOpts{
- Name: "grpc_server_handling_seconds",
- Help: "Histogram of response latency (seconds) of gRPC that had been application-level handled by the server.",
- Buckets: prom.DefBuckets,
- },
- serverHandledHistogram: nil,
- }
-}
-
-// EnableHandlingTimeHistogram enables histograms being registered when
-// registering the ServerMetrics on a Prometheus registry. Histograms can be
-// expensive on Prometheus servers. It takes options to configure histogram
-// options such as the defined buckets.
-func (m *ServerMetrics) EnableHandlingTimeHistogram(opts ...HistogramOption) {
- for _, o := range opts {
- o(&m.serverHandledHistogramOpts)
- }
- if !m.serverHandledHistogramEnabled {
- m.serverHandledHistogram = prom.NewHistogramVec(
- m.serverHandledHistogramOpts,
- []string{"grpc_type", "grpc_service", "grpc_method"},
- )
- }
- m.serverHandledHistogramEnabled = true
-}
-
-// Describe sends the super-set of all possible descriptors of metrics
-// collected by this Collector to the provided channel and returns once
-// the last descriptor has been sent.
-func (m *ServerMetrics) Describe(ch chan<- *prom.Desc) {
- m.serverStartedCounter.Describe(ch)
- m.serverHandledCounter.Describe(ch)
- m.serverStreamMsgReceived.Describe(ch)
- m.serverStreamMsgSent.Describe(ch)
- if m.serverHandledHistogramEnabled {
- m.serverHandledHistogram.Describe(ch)
- }
-}
-
-// Collect is called by the Prometheus registry when collecting
-// metrics. The implementation sends each collected metric via the
-// provided channel and returns once the last metric has been sent.
-func (m *ServerMetrics) Collect(ch chan<- prom.Metric) {
- m.serverStartedCounter.Collect(ch)
- m.serverHandledCounter.Collect(ch)
- m.serverStreamMsgReceived.Collect(ch)
- m.serverStreamMsgSent.Collect(ch)
- if m.serverHandledHistogramEnabled {
- m.serverHandledHistogram.Collect(ch)
- }
-}
-
-// UnaryServerInterceptor is a gRPC server-side interceptor that provides Prometheus monitoring for Unary RPCs.
-func (m *ServerMetrics) UnaryServerInterceptor() func(ctx context.Context, req interface{}, info *grpc.UnaryServerInfo, handler grpc.UnaryHandler) (interface{}, error) {
- return func(ctx context.Context, req interface{}, info *grpc.UnaryServerInfo, handler grpc.UnaryHandler) (interface{}, error) {
- monitor := newServerReporter(m, Unary, info.FullMethod)
- monitor.ReceivedMessage()
- resp, err := handler(ctx, req)
- st, _ := grpcstatus.FromError(err)
- monitor.Handled(st.Code())
- if err == nil {
- monitor.SentMessage()
- }
- return resp, err
- }
-}
-
-// StreamServerInterceptor is a gRPC server-side interceptor that provides Prometheus monitoring for Streaming RPCs.
-func (m *ServerMetrics) StreamServerInterceptor() func(srv interface{}, ss grpc.ServerStream, info *grpc.StreamServerInfo, handler grpc.StreamHandler) error {
- return func(srv interface{}, ss grpc.ServerStream, info *grpc.StreamServerInfo, handler grpc.StreamHandler) error {
- monitor := newServerReporter(m, streamRPCType(info), info.FullMethod)
- err := handler(srv, &monitoredServerStream{ss, monitor})
- st, _ := grpcstatus.FromError(err)
- monitor.Handled(st.Code())
- return err
- }
-}
-
-// InitializeMetrics initializes all metrics, with their appropriate null
-// value, for all gRPC methods registered on a gRPC server. This is useful, to
-// ensure that all metrics exist when collecting and querying.
-func (m *ServerMetrics) InitializeMetrics(server *grpc.Server) {
- serviceInfo := server.GetServiceInfo()
- for serviceName, info := range serviceInfo {
- for _, mInfo := range info.Methods {
- preRegisterMethod(m, serviceName, &mInfo)
- }
- }
-}
-
-func streamRPCType(info *grpc.StreamServerInfo) grpcType {
- if info.IsClientStream && !info.IsServerStream {
- return ClientStream
- } else if !info.IsClientStream && info.IsServerStream {
- return ServerStream
- }
- return BidiStream
-}
-
-// monitoredStream wraps grpc.ServerStream allowing each Sent/Recv of message to increment counters.
-type monitoredServerStream struct {
- grpc.ServerStream
- monitor *serverReporter
-}
-
-func (s *monitoredServerStream) SendMsg(m interface{}) error {
- err := s.ServerStream.SendMsg(m)
- if err == nil {
- s.monitor.SentMessage()
- }
- return err
-}
-
-func (s *monitoredServerStream) RecvMsg(m interface{}) error {
- err := s.ServerStream.RecvMsg(m)
- if err == nil {
- s.monitor.ReceivedMessage()
- }
- return err
-}
-
-// preRegisterMethod is invoked on Register of a Server, allowing all gRPC services labels to be pre-populated.
-func preRegisterMethod(metrics *ServerMetrics, serviceName string, mInfo *grpc.MethodInfo) {
- methodName := mInfo.Name
- methodType := string(typeFromMethodInfo(mInfo))
- // These are just references (no increments), as just referencing will create the labels but not set values.
- metrics.serverStartedCounter.GetMetricWithLabelValues(methodType, serviceName, methodName)
- metrics.serverStreamMsgReceived.GetMetricWithLabelValues(methodType, serviceName, methodName)
- metrics.serverStreamMsgSent.GetMetricWithLabelValues(methodType, serviceName, methodName)
- if metrics.serverHandledHistogramEnabled {
- metrics.serverHandledHistogram.GetMetricWithLabelValues(methodType, serviceName, methodName)
- }
- for _, code := range allCodes {
- metrics.serverHandledCounter.GetMetricWithLabelValues(methodType, serviceName, methodName, code.String())
- }
-}
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/server_reporter.go b/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/server_reporter.go
deleted file mode 100644
index aa9db5401a..0000000000
--- a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/server_reporter.go
+++ /dev/null
@@ -1,46 +0,0 @@
-// Copyright 2016 Michal Witkowski. All Rights Reserved.
-// See LICENSE for licensing terms.
-
-package grpc_prometheus
-
-import (
- "time"
-
- "google.golang.org/grpc/codes"
-)
-
-type serverReporter struct {
- metrics *ServerMetrics
- rpcType grpcType
- serviceName string
- methodName string
- startTime time.Time
-}
-
-func newServerReporter(m *ServerMetrics, rpcType grpcType, fullMethod string) *serverReporter {
- r := &serverReporter{
- metrics: m,
- rpcType: rpcType,
- }
- if r.metrics.serverHandledHistogramEnabled {
- r.startTime = time.Now()
- }
- r.serviceName, r.methodName = splitMethodName(fullMethod)
- r.metrics.serverStartedCounter.WithLabelValues(string(r.rpcType), r.serviceName, r.methodName).Inc()
- return r
-}
-
-func (r *serverReporter) ReceivedMessage() {
- r.metrics.serverStreamMsgReceived.WithLabelValues(string(r.rpcType), r.serviceName, r.methodName).Inc()
-}
-
-func (r *serverReporter) SentMessage() {
- r.metrics.serverStreamMsgSent.WithLabelValues(string(r.rpcType), r.serviceName, r.methodName).Inc()
-}
-
-func (r *serverReporter) Handled(code codes.Code) {
- r.metrics.serverHandledCounter.WithLabelValues(string(r.rpcType), r.serviceName, r.methodName, code.String()).Inc()
- if r.metrics.serverHandledHistogramEnabled {
- r.metrics.serverHandledHistogram.WithLabelValues(string(r.rpcType), r.serviceName, r.methodName).Observe(time.Since(r.startTime).Seconds())
- }
-}
diff --git a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/util.go b/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/util.go
deleted file mode 100644
index 7987de35f4..0000000000
--- a/vendor/github.com/grpc-ecosystem/go-grpc-prometheus/util.go
+++ /dev/null
@@ -1,50 +0,0 @@
-// Copyright 2016 Michal Witkowski. All Rights Reserved.
-// See LICENSE for licensing terms.
-
-package grpc_prometheus
-
-import (
- "strings"
-
- "google.golang.org/grpc"
- "google.golang.org/grpc/codes"
-)
-
-type grpcType string
-
-const (
- Unary grpcType = "unary"
- ClientStream grpcType = "client_stream"
- ServerStream grpcType = "server_stream"
- BidiStream grpcType = "bidi_stream"
-)
-
-var (
- allCodes = []codes.Code{
- codes.OK, codes.Canceled, codes.Unknown, codes.InvalidArgument, codes.DeadlineExceeded, codes.NotFound,
- codes.AlreadyExists, codes.PermissionDenied, codes.Unauthenticated, codes.ResourceExhausted,
- codes.FailedPrecondition, codes.Aborted, codes.OutOfRange, codes.Unimplemented, codes.Internal,
- codes.Unavailable, codes.DataLoss,
- }
-)
-
-func splitMethodName(fullMethodName string) (string, string) {
- fullMethodName = strings.TrimPrefix(fullMethodName, "/") // remove leading slash
- if i := strings.Index(fullMethodName, "/"); i >= 0 {
- return fullMethodName[:i], fullMethodName[i+1:]
- }
- return "unknown", "unknown"
-}
-
-func typeFromMethodInfo(mInfo *grpc.MethodInfo) grpcType {
- if !mInfo.IsClientStream && !mInfo.IsServerStream {
- return Unary
- }
- if mInfo.IsClientStream && !mInfo.IsServerStream {
- return ClientStream
- }
- if !mInfo.IsClientStream && mInfo.IsServerStream {
- return ServerStream
- }
- return BidiStream
-}
diff --git a/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-openapiv2/options/openapiv2.pb.go b/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-openapiv2/options/openapiv2.pb.go
index 3a34e664e0..5121dce386 100644
--- a/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-openapiv2/options/openapiv2.pb.go
+++ b/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-openapiv2/options/openapiv2.pb.go
@@ -3476,6 +3476,9 @@ type JSONSchema_FieldConfiguration struct {
// parameter. Use this to avoid having auto generated path parameter names
// for overlapping paths.
PathParamName string `protobuf:"bytes,47,opt,name=path_param_name,json=pathParamName,proto3" json:"path_param_name,omitempty"`
+ // Declares this field to be deprecated. Allows for the generated OpenAPI
+ // parameter to be marked as deprecated without affecting the proto field.
+ Deprecated bool `protobuf:"varint,49,opt,name=deprecated,proto3" json:"deprecated,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
@@ -3512,10 +3515,21 @@ func (x *JSONSchema_FieldConfiguration) GetPathParamName() string {
return ""
}
+func (x *JSONSchema_FieldConfiguration) GetDeprecated() bool {
+ if x != nil {
+ return x.Deprecated
+ }
+ return false
+}
+
func (x *JSONSchema_FieldConfiguration) SetPathParamName(v string) {
x.PathParamName = v
}
+func (x *JSONSchema_FieldConfiguration) SetDeprecated(v bool) {
+ x.Deprecated = v
+}
+
type JSONSchema_FieldConfiguration_builder struct {
_ [0]func() // Prevents comparability and use of unkeyed literals for the builder.
@@ -3524,6 +3538,9 @@ type JSONSchema_FieldConfiguration_builder struct {
// parameter. Use this to avoid having auto generated path parameter names
// for overlapping paths.
PathParamName string
+ // Declares this field to be deprecated. Allows for the generated OpenAPI
+ // parameter to be marked as deprecated without affecting the proto field.
+ Deprecated bool
}
func (b0 JSONSchema_FieldConfiguration_builder) Build() *JSONSchema_FieldConfiguration {
@@ -3531,6 +3548,7 @@ func (b0 JSONSchema_FieldConfiguration_builder) Build() *JSONSchema_FieldConfigu
b, x := &b0, m0
_, _ = b, x
x.PathParamName = b.PathParamName
+ x.Deprecated = b.Deprecated
return m0
}
@@ -3904,7 +3922,7 @@ var file_protoc_gen_openapiv2_options_openapiv2_proto_rawDesc = []byte{
0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x2c, 0x0a, 0x05,
0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x16, 0x2e, 0x67, 0x6f,
0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x56, 0x61,
- 0x6c, 0x75, 0x65, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0xd7,
+ 0x6c, 0x75, 0x65, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0xf7,
0x0a, 0x0a, 0x0a, 0x4a, 0x53, 0x4f, 0x4e, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x12, 0x10, 0x0a,
0x03, 0x72, 0x65, 0x66, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x72, 0x65, 0x66, 0x12,
0x14, 0x0a, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05,
@@ -3968,11 +3986,13 @@ var file_protoc_gen_openapiv2_options_openapiv2_proto_rawDesc = []byte{
0x67, 0x65, 0x6e, 0x5f, 0x6f, 0x70, 0x65, 0x6e, 0x61, 0x70, 0x69, 0x76, 0x32, 0x2e, 0x6f, 0x70,
0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x4a, 0x53, 0x4f, 0x4e, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61,
0x2e, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79,
- 0x52, 0x0a, 0x65, 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x1a, 0x3c, 0x0a, 0x12,
+ 0x52, 0x0a, 0x65, 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x1a, 0x5c, 0x0a, 0x12,
0x46, 0x69, 0x65, 0x6c, 0x64, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x75, 0x72, 0x61, 0x74, 0x69,
0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x0f, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x70, 0x61, 0x72, 0x61, 0x6d,
0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x2f, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x70, 0x61, 0x74,
- 0x68, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x4e, 0x61, 0x6d, 0x65, 0x1a, 0x55, 0x0a, 0x0f, 0x45, 0x78,
+ 0x68, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x64, 0x65,
+ 0x70, 0x72, 0x65, 0x63, 0x61, 0x74, 0x65, 0x64, 0x18, 0x31, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0a,
+ 0x64, 0x65, 0x70, 0x72, 0x65, 0x63, 0x61, 0x74, 0x65, 0x64, 0x1a, 0x55, 0x0a, 0x0f, 0x45, 0x78,
0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a,
0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12,
0x2c, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x16,
diff --git a/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-openapiv2/options/openapiv2.proto b/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-openapiv2/options/openapiv2.proto
index 5313f0818a..444a5687a5 100644
--- a/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-openapiv2/options/openapiv2.proto
+++ b/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-openapiv2/options/openapiv2.proto
@@ -612,6 +612,9 @@ message JSONSchema {
// parameter. Use this to avoid having auto generated path parameter names
// for overlapping paths.
string path_param_name = 47;
+ // Declares this field to be deprecated. Allows for the generated OpenAPI
+ // parameter to be marked as deprecated without affecting the proto field.
+ bool deprecated = 49;
}
// Custom properties that start with "x-" such as "x-foo" used to describe
// extra functionality that is not covered by the standard OpenAPI Specification.
diff --git a/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-openapiv2/options/openapiv2_protoopaque.pb.go b/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-openapiv2/options/openapiv2_protoopaque.pb.go
index 1f0e0c2691..5316ed6192 100644
--- a/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-openapiv2/options/openapiv2_protoopaque.pb.go
+++ b/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-openapiv2/options/openapiv2_protoopaque.pb.go
@@ -3268,6 +3268,7 @@ func (b0 Scopes_builder) Build() *Scopes {
type JSONSchema_FieldConfiguration struct {
state protoimpl.MessageState `protogen:"opaque.v1"`
xxx_hidden_PathParamName string `protobuf:"bytes,47,opt,name=path_param_name,json=pathParamName,proto3" json:"path_param_name,omitempty"`
+ xxx_hidden_Deprecated bool `protobuf:"varint,49,opt,name=deprecated,proto3" json:"deprecated,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
@@ -3304,10 +3305,21 @@ func (x *JSONSchema_FieldConfiguration) GetPathParamName() string {
return ""
}
+func (x *JSONSchema_FieldConfiguration) GetDeprecated() bool {
+ if x != nil {
+ return x.xxx_hidden_Deprecated
+ }
+ return false
+}
+
func (x *JSONSchema_FieldConfiguration) SetPathParamName(v string) {
x.xxx_hidden_PathParamName = v
}
+func (x *JSONSchema_FieldConfiguration) SetDeprecated(v bool) {
+ x.xxx_hidden_Deprecated = v
+}
+
type JSONSchema_FieldConfiguration_builder struct {
_ [0]func() // Prevents comparability and use of unkeyed literals for the builder.
@@ -3316,6 +3328,9 @@ type JSONSchema_FieldConfiguration_builder struct {
// parameter. Use this to avoid having auto generated path parameter names
// for overlapping paths.
PathParamName string
+ // Declares this field to be deprecated. Allows for the generated OpenAPI
+ // parameter to be marked as deprecated without affecting the proto field.
+ Deprecated bool
}
func (b0 JSONSchema_FieldConfiguration_builder) Build() *JSONSchema_FieldConfiguration {
@@ -3323,6 +3338,7 @@ func (b0 JSONSchema_FieldConfiguration_builder) Build() *JSONSchema_FieldConfigu
b, x := &b0, m0
_, _ = b, x
x.xxx_hidden_PathParamName = b.PathParamName
+ x.xxx_hidden_Deprecated = b.Deprecated
return m0
}
@@ -3696,7 +3712,7 @@ var file_protoc_gen_openapiv2_options_openapiv2_proto_rawDesc = []byte{
0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x2c, 0x0a, 0x05,
0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x16, 0x2e, 0x67, 0x6f,
0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x56, 0x61,
- 0x6c, 0x75, 0x65, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0xd7,
+ 0x6c, 0x75, 0x65, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0xf7,
0x0a, 0x0a, 0x0a, 0x4a, 0x53, 0x4f, 0x4e, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x12, 0x10, 0x0a,
0x03, 0x72, 0x65, 0x66, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x72, 0x65, 0x66, 0x12,
0x14, 0x0a, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05,
@@ -3760,11 +3776,13 @@ var file_protoc_gen_openapiv2_options_openapiv2_proto_rawDesc = []byte{
0x67, 0x65, 0x6e, 0x5f, 0x6f, 0x70, 0x65, 0x6e, 0x61, 0x70, 0x69, 0x76, 0x32, 0x2e, 0x6f, 0x70,
0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x4a, 0x53, 0x4f, 0x4e, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61,
0x2e, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79,
- 0x52, 0x0a, 0x65, 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x1a, 0x3c, 0x0a, 0x12,
+ 0x52, 0x0a, 0x65, 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x1a, 0x5c, 0x0a, 0x12,
0x46, 0x69, 0x65, 0x6c, 0x64, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x75, 0x72, 0x61, 0x74, 0x69,
0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x0f, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x70, 0x61, 0x72, 0x61, 0x6d,
0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x2f, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x70, 0x61, 0x74,
- 0x68, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x4e, 0x61, 0x6d, 0x65, 0x1a, 0x55, 0x0a, 0x0f, 0x45, 0x78,
+ 0x68, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x64, 0x65,
+ 0x70, 0x72, 0x65, 0x63, 0x61, 0x74, 0x65, 0x64, 0x18, 0x31, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0a,
+ 0x64, 0x65, 0x70, 0x72, 0x65, 0x63, 0x61, 0x74, 0x65, 0x64, 0x1a, 0x55, 0x0a, 0x0f, 0x45, 0x78,
0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a,
0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12,
0x2c, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x16,
diff --git a/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/BUILD.bazel b/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/BUILD.bazel
index a65d88eb86..04b4bebf3d 100644
--- a/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/BUILD.bazel
+++ b/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/BUILD.bazel
@@ -27,6 +27,7 @@ go_library(
"//internal/httprule",
"//utilities",
"@org_golang_google_genproto_googleapis_api//httpbody",
+ "@org_golang_google_grpc//:grpc",
"@org_golang_google_grpc//codes",
"@org_golang_google_grpc//grpclog",
"@org_golang_google_grpc//health/grpc_health_v1",
diff --git a/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/context.go b/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/context.go
index 2f2b342431..00b2228a1d 100644
--- a/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/context.go
+++ b/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/context.go
@@ -201,13 +201,13 @@ func annotateContext(ctx context.Context, mux *ServeMux, req *http.Request, rpcM
if timeout != 0 {
ctx, _ = context.WithTimeout(ctx, timeout)
}
- if len(pairs) == 0 {
- return ctx, nil, nil
- }
md := metadata.Pairs(pairs...)
for _, mda := range mux.metadataAnnotators {
md = metadata.Join(md, mda(ctx, req))
}
+ if len(md) == 0 {
+ return ctx, nil, nil
+ }
return ctx, md, nil
}
diff --git a/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/marshal_jsonpb.go b/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/marshal_jsonpb.go
index 8376d1e0ef..3d07063007 100644
--- a/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/marshal_jsonpb.go
+++ b/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/marshal_jsonpb.go
@@ -66,7 +66,7 @@ func (j *JSONPb) marshalTo(w io.Writer, v interface{}) error {
var (
// protoMessageType is stored to prevent constant lookup of the same type at runtime.
- protoMessageType = reflect.TypeOf((*proto.Message)(nil)).Elem()
+ protoMessageType = reflect.TypeFor[proto.Message]()
)
// marshalNonProto marshals a non-message field of a protobuf message.
@@ -325,9 +325,9 @@ type protoEnum interface {
EnumDescriptor() ([]byte, []int)
}
-var typeProtoEnum = reflect.TypeOf((*protoEnum)(nil)).Elem()
+var typeProtoEnum = reflect.TypeFor[protoEnum]()
-var typeProtoMessage = reflect.TypeOf((*proto.Message)(nil)).Elem()
+var typeProtoMessage = reflect.TypeFor[proto.Message]()
// Delimiter for newline encoded JSON streams.
func (j *JSONPb) Delimiter() []byte {
diff --git a/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/mux.go b/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/mux.go
index 19255ec441..3eb1616717 100644
--- a/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/mux.go
+++ b/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/mux.go
@@ -10,6 +10,7 @@ import (
"strings"
"github.com/grpc-ecosystem/grpc-gateway/v2/internal/httprule"
+ "google.golang.org/grpc"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/grpclog"
"google.golang.org/grpc/health/grpc_health_v1"
@@ -281,12 +282,19 @@ func WithHealthEndpointAt(healthCheckClient grpc_health_v1.HealthClient, endpoin
http.MethodGet, endpointPath, func(w http.ResponseWriter, r *http.Request, _ map[string]string,
) {
_, outboundMarshaler := MarshalerForRequest(s, r)
+ annotatedContext, err := AnnotateContext(r.Context(), s, r, grpc_health_v1.Health_Check_FullMethodName, WithHTTPPathPattern(endpointPath))
+ if err != nil {
+ s.errorHandler(r.Context(), s, outboundMarshaler, w, r, err)
+ return
+ }
- resp, err := healthCheckClient.Check(r.Context(), &grpc_health_v1.HealthCheckRequest{
+ var md ServerMetadata
+ resp, err := healthCheckClient.Check(annotatedContext, &grpc_health_v1.HealthCheckRequest{
Service: r.URL.Query().Get("service"),
- })
+ }, grpc.Header(&md.HeaderMD), grpc.Trailer(&md.TrailerMD))
+ annotatedContext = NewServerMetadataContext(annotatedContext, md)
if err != nil {
- s.errorHandler(r.Context(), s, outboundMarshaler, w, r, err)
+ s.errorHandler(annotatedContext, s, outboundMarshaler, w, r, err)
return
}
@@ -300,7 +308,7 @@ func WithHealthEndpointAt(healthCheckClient grpc_health_v1.HealthClient, endpoin
err = status.Error(codes.NotFound, resp.String())
}
- s.errorHandler(r.Context(), s, outboundMarshaler, w, r, err)
+ s.errorHandler(annotatedContext, s, outboundMarshaler, w, r, err)
return
}
diff --git a/vendor/github.com/josharian/intern/README.md b/vendor/github.com/josharian/intern/README.md
deleted file mode 100644
index ffc44b219b..0000000000
--- a/vendor/github.com/josharian/intern/README.md
+++ /dev/null
@@ -1,5 +0,0 @@
-Docs: https://godoc.org/github.com/josharian/intern
-
-See also [Go issue 5160](https://golang.org/issue/5160).
-
-License: MIT
diff --git a/vendor/github.com/josharian/intern/intern.go b/vendor/github.com/josharian/intern/intern.go
deleted file mode 100644
index 7acb1fe90a..0000000000
--- a/vendor/github.com/josharian/intern/intern.go
+++ /dev/null
@@ -1,44 +0,0 @@
-// Package intern interns strings.
-// Interning is best effort only.
-// Interned strings may be removed automatically
-// at any time without notification.
-// All functions may be called concurrently
-// with themselves and each other.
-package intern
-
-import "sync"
-
-var (
- pool sync.Pool = sync.Pool{
- New: func() interface{} {
- return make(map[string]string)
- },
- }
-)
-
-// String returns s, interned.
-func String(s string) string {
- m := pool.Get().(map[string]string)
- c, ok := m[s]
- if ok {
- pool.Put(m)
- return c
- }
- m[s] = s
- pool.Put(m)
- return s
-}
-
-// Bytes returns b converted to a string, interned.
-func Bytes(b []byte) string {
- m := pool.Get().(map[string]string)
- c, ok := m[string(b)]
- if ok {
- pool.Put(m)
- return c
- }
- s := string(b)
- m[s] = s
- pool.Put(m)
- return s
-}
diff --git a/vendor/github.com/josharian/intern/license.md b/vendor/github.com/josharian/intern/license.md
deleted file mode 100644
index 353d3055f0..0000000000
--- a/vendor/github.com/josharian/intern/license.md
+++ /dev/null
@@ -1,21 +0,0 @@
-MIT License
-
-Copyright (c) 2019 Josh Bleecher Snyder
-
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files (the "Software"), to deal
-in the Software without restriction, including without limitation the rights
-to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in all
-copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
-SOFTWARE.
diff --git a/vendor/github.com/mailru/easyjson/LICENSE b/vendor/github.com/mailru/easyjson/LICENSE
deleted file mode 100644
index fbff658f70..0000000000
--- a/vendor/github.com/mailru/easyjson/LICENSE
+++ /dev/null
@@ -1,7 +0,0 @@
-Copyright (c) 2016 Mail.Ru Group
-
-Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff --git a/vendor/github.com/mailru/easyjson/buffer/pool.go b/vendor/github.com/mailru/easyjson/buffer/pool.go
deleted file mode 100644
index 598a54af9d..0000000000
--- a/vendor/github.com/mailru/easyjson/buffer/pool.go
+++ /dev/null
@@ -1,278 +0,0 @@
-// Package buffer implements a buffer for serialization, consisting of a chain of []byte-s to
-// reduce copying and to allow reuse of individual chunks.
-package buffer
-
-import (
- "io"
- "net"
- "sync"
-)
-
-// PoolConfig contains configuration for the allocation and reuse strategy.
-type PoolConfig struct {
- StartSize int // Minimum chunk size that is allocated.
- PooledSize int // Minimum chunk size that is reused, reusing chunks too small will result in overhead.
- MaxSize int // Maximum chunk size that will be allocated.
-}
-
-var config = PoolConfig{
- StartSize: 128,
- PooledSize: 512,
- MaxSize: 32768,
-}
-
-// Reuse pool: chunk size -> pool.
-var buffers = map[int]*sync.Pool{}
-
-func initBuffers() {
- for l := config.PooledSize; l <= config.MaxSize; l *= 2 {
- buffers[l] = new(sync.Pool)
- }
-}
-
-func init() {
- initBuffers()
-}
-
-// Init sets up a non-default pooling and allocation strategy. Should be run before serialization is done.
-func Init(cfg PoolConfig) {
- config = cfg
- initBuffers()
-}
-
-// putBuf puts a chunk to reuse pool if it can be reused.
-func putBuf(buf []byte) {
- size := cap(buf)
- if size < config.PooledSize {
- return
- }
- if c := buffers[size]; c != nil {
- c.Put(buf[:0])
- }
-}
-
-// getBuf gets a chunk from reuse pool or creates a new one if reuse failed.
-func getBuf(size int) []byte {
- if size >= config.PooledSize {
- if c := buffers[size]; c != nil {
- v := c.Get()
- if v != nil {
- return v.([]byte)
- }
- }
- }
- return make([]byte, 0, size)
-}
-
-// Buffer is a buffer optimized for serialization without extra copying.
-type Buffer struct {
-
- // Buf is the current chunk that can be used for serialization.
- Buf []byte
-
- toPool []byte
- bufs [][]byte
-}
-
-// EnsureSpace makes sure that the current chunk contains at least s free bytes,
-// possibly creating a new chunk.
-func (b *Buffer) EnsureSpace(s int) {
- if cap(b.Buf)-len(b.Buf) < s {
- b.ensureSpaceSlow(s)
- }
-}
-
-func (b *Buffer) ensureSpaceSlow(s int) {
- l := len(b.Buf)
- if l > 0 {
- if cap(b.toPool) != cap(b.Buf) {
- // Chunk was reallocated, toPool can be pooled.
- putBuf(b.toPool)
- }
- if cap(b.bufs) == 0 {
- b.bufs = make([][]byte, 0, 8)
- }
- b.bufs = append(b.bufs, b.Buf)
- l = cap(b.toPool) * 2
- } else {
- l = config.StartSize
- }
-
- if l > config.MaxSize {
- l = config.MaxSize
- }
- b.Buf = getBuf(l)
- b.toPool = b.Buf
-}
-
-// AppendByte appends a single byte to buffer.
-func (b *Buffer) AppendByte(data byte) {
- b.EnsureSpace(1)
- b.Buf = append(b.Buf, data)
-}
-
-// AppendBytes appends a byte slice to buffer.
-func (b *Buffer) AppendBytes(data []byte) {
- if len(data) <= cap(b.Buf)-len(b.Buf) {
- b.Buf = append(b.Buf, data...) // fast path
- } else {
- b.appendBytesSlow(data)
- }
-}
-
-func (b *Buffer) appendBytesSlow(data []byte) {
- for len(data) > 0 {
- b.EnsureSpace(1)
-
- sz := cap(b.Buf) - len(b.Buf)
- if sz > len(data) {
- sz = len(data)
- }
-
- b.Buf = append(b.Buf, data[:sz]...)
- data = data[sz:]
- }
-}
-
-// AppendString appends a string to buffer.
-func (b *Buffer) AppendString(data string) {
- if len(data) <= cap(b.Buf)-len(b.Buf) {
- b.Buf = append(b.Buf, data...) // fast path
- } else {
- b.appendStringSlow(data)
- }
-}
-
-func (b *Buffer) appendStringSlow(data string) {
- for len(data) > 0 {
- b.EnsureSpace(1)
-
- sz := cap(b.Buf) - len(b.Buf)
- if sz > len(data) {
- sz = len(data)
- }
-
- b.Buf = append(b.Buf, data[:sz]...)
- data = data[sz:]
- }
-}
-
-// Size computes the size of a buffer by adding sizes of every chunk.
-func (b *Buffer) Size() int {
- size := len(b.Buf)
- for _, buf := range b.bufs {
- size += len(buf)
- }
- return size
-}
-
-// DumpTo outputs the contents of a buffer to a writer and resets the buffer.
-func (b *Buffer) DumpTo(w io.Writer) (written int, err error) {
- bufs := net.Buffers(b.bufs)
- if len(b.Buf) > 0 {
- bufs = append(bufs, b.Buf)
- }
- n, err := bufs.WriteTo(w)
-
- for _, buf := range b.bufs {
- putBuf(buf)
- }
- putBuf(b.toPool)
-
- b.bufs = nil
- b.Buf = nil
- b.toPool = nil
-
- return int(n), err
-}
-
-// BuildBytes creates a single byte slice with all the contents of the buffer. Data is
-// copied if it does not fit in a single chunk. You can optionally provide one byte
-// slice as argument that it will try to reuse.
-func (b *Buffer) BuildBytes(reuse ...[]byte) []byte {
- if len(b.bufs) == 0 {
- ret := b.Buf
- b.toPool = nil
- b.Buf = nil
- return ret
- }
-
- var ret []byte
- size := b.Size()
-
- // If we got a buffer as argument and it is big enough, reuse it.
- if len(reuse) == 1 && cap(reuse[0]) >= size {
- ret = reuse[0][:0]
- } else {
- ret = make([]byte, 0, size)
- }
- for _, buf := range b.bufs {
- ret = append(ret, buf...)
- putBuf(buf)
- }
-
- ret = append(ret, b.Buf...)
- putBuf(b.toPool)
-
- b.bufs = nil
- b.toPool = nil
- b.Buf = nil
-
- return ret
-}
-
-type readCloser struct {
- offset int
- bufs [][]byte
-}
-
-func (r *readCloser) Read(p []byte) (n int, err error) {
- for _, buf := range r.bufs {
- // Copy as much as we can.
- x := copy(p[n:], buf[r.offset:])
- n += x // Increment how much we filled.
-
- // Did we empty the whole buffer?
- if r.offset+x == len(buf) {
- // On to the next buffer.
- r.offset = 0
- r.bufs = r.bufs[1:]
-
- // We can release this buffer.
- putBuf(buf)
- } else {
- r.offset += x
- }
-
- if n == len(p) {
- break
- }
- }
- // No buffers left or nothing read?
- if len(r.bufs) == 0 {
- err = io.EOF
- }
- return
-}
-
-func (r *readCloser) Close() error {
- // Release all remaining buffers.
- for _, buf := range r.bufs {
- putBuf(buf)
- }
- // In case Close gets called multiple times.
- r.bufs = nil
-
- return nil
-}
-
-// ReadCloser creates an io.ReadCloser with all the contents of the buffer.
-func (b *Buffer) ReadCloser() io.ReadCloser {
- ret := &readCloser{0, append(b.bufs, b.Buf)}
-
- b.bufs = nil
- b.toPool = nil
- b.Buf = nil
-
- return ret
-}
diff --git a/vendor/github.com/mailru/easyjson/jlexer/bytestostr.go b/vendor/github.com/mailru/easyjson/jlexer/bytestostr.go
deleted file mode 100644
index ff7b27c5b2..0000000000
--- a/vendor/github.com/mailru/easyjson/jlexer/bytestostr.go
+++ /dev/null
@@ -1,24 +0,0 @@
-// This file will only be included to the build if neither
-// easyjson_nounsafe nor appengine build tag is set. See README notes
-// for more details.
-
-//+build !easyjson_nounsafe
-//+build !appengine
-
-package jlexer
-
-import (
- "reflect"
- "unsafe"
-)
-
-// bytesToStr creates a string pointing at the slice to avoid copying.
-//
-// Warning: the string returned by the function should be used with care, as the whole input data
-// chunk may be either blocked from being freed by GC because of a single string or the buffer.Data
-// may be garbage-collected even when the string exists.
-func bytesToStr(data []byte) string {
- h := (*reflect.SliceHeader)(unsafe.Pointer(&data))
- shdr := reflect.StringHeader{Data: h.Data, Len: h.Len}
- return *(*string)(unsafe.Pointer(&shdr))
-}
diff --git a/vendor/github.com/mailru/easyjson/jlexer/bytestostr_nounsafe.go b/vendor/github.com/mailru/easyjson/jlexer/bytestostr_nounsafe.go
deleted file mode 100644
index 864d1be676..0000000000
--- a/vendor/github.com/mailru/easyjson/jlexer/bytestostr_nounsafe.go
+++ /dev/null
@@ -1,13 +0,0 @@
-// This file is included to the build if any of the buildtags below
-// are defined. Refer to README notes for more details.
-
-//+build easyjson_nounsafe appengine
-
-package jlexer
-
-// bytesToStr creates a string normally from []byte
-//
-// Note that this method is roughly 1.5x slower than using the 'unsafe' method.
-func bytesToStr(data []byte) string {
- return string(data)
-}
diff --git a/vendor/github.com/mailru/easyjson/jlexer/error.go b/vendor/github.com/mailru/easyjson/jlexer/error.go
deleted file mode 100644
index e90ec40d05..0000000000
--- a/vendor/github.com/mailru/easyjson/jlexer/error.go
+++ /dev/null
@@ -1,15 +0,0 @@
-package jlexer
-
-import "fmt"
-
-// LexerError implements the error interface and represents all possible errors that can be
-// generated during parsing the JSON data.
-type LexerError struct {
- Reason string
- Offset int
- Data string
-}
-
-func (l *LexerError) Error() string {
- return fmt.Sprintf("parse error: %s near offset %d of '%s'", l.Reason, l.Offset, l.Data)
-}
diff --git a/vendor/github.com/mailru/easyjson/jlexer/lexer.go b/vendor/github.com/mailru/easyjson/jlexer/lexer.go
deleted file mode 100644
index b5f5e26132..0000000000
--- a/vendor/github.com/mailru/easyjson/jlexer/lexer.go
+++ /dev/null
@@ -1,1244 +0,0 @@
-// Package jlexer contains a JSON lexer implementation.
-//
-// It is expected that it is mostly used with generated parser code, so the interface is tuned
-// for a parser that knows what kind of data is expected.
-package jlexer
-
-import (
- "bytes"
- "encoding/base64"
- "encoding/json"
- "errors"
- "fmt"
- "io"
- "strconv"
- "unicode"
- "unicode/utf16"
- "unicode/utf8"
-
- "github.com/josharian/intern"
-)
-
-// tokenKind determines type of a token.
-type tokenKind byte
-
-const (
- tokenUndef tokenKind = iota // No token.
- tokenDelim // Delimiter: one of '{', '}', '[' or ']'.
- tokenString // A string literal, e.g. "abc\u1234"
- tokenNumber // Number literal, e.g. 1.5e5
- tokenBool // Boolean literal: true or false.
- tokenNull // null keyword.
-)
-
-// token describes a single token: type, position in the input and value.
-type token struct {
- kind tokenKind // Type of a token.
-
- boolValue bool // Value if a boolean literal token.
- byteValueCloned bool // true if byteValue was allocated and does not refer to original json body
- byteValue []byte // Raw value of a token.
- delimValue byte
-}
-
-// Lexer is a JSON lexer: it iterates over JSON tokens in a byte slice.
-type Lexer struct {
- Data []byte // Input data given to the lexer.
-
- start int // Start of the current token.
- pos int // Current unscanned position in the input stream.
- token token // Last scanned token, if token.kind != tokenUndef.
-
- firstElement bool // Whether current element is the first in array or an object.
- wantSep byte // A comma or a colon character, which need to occur before a token.
-
- UseMultipleErrors bool // If we want to use multiple errors.
- fatalError error // Fatal error occurred during lexing. It is usually a syntax error.
- multipleErrors []*LexerError // Semantic errors occurred during lexing. Marshalling will be continued after finding this errors.
-}
-
-// FetchToken scans the input for the next token.
-func (r *Lexer) FetchToken() {
- r.token.kind = tokenUndef
- r.start = r.pos
-
- // Check if r.Data has r.pos element
- // If it doesn't, it mean corrupted input data
- if len(r.Data) < r.pos {
- r.errParse("Unexpected end of data")
- return
- }
- // Determine the type of a token by skipping whitespace and reading the
- // first character.
- for _, c := range r.Data[r.pos:] {
- switch c {
- case ':', ',':
- if r.wantSep == c {
- r.pos++
- r.start++
- r.wantSep = 0
- } else {
- r.errSyntax()
- }
-
- case ' ', '\t', '\r', '\n':
- r.pos++
- r.start++
-
- case '"':
- if r.wantSep != 0 {
- r.errSyntax()
- }
-
- r.token.kind = tokenString
- r.fetchString()
- return
-
- case '{', '[':
- if r.wantSep != 0 {
- r.errSyntax()
- }
- r.firstElement = true
- r.token.kind = tokenDelim
- r.token.delimValue = r.Data[r.pos]
- r.pos++
- return
-
- case '}', ']':
- if !r.firstElement && (r.wantSep != ',') {
- r.errSyntax()
- }
- r.wantSep = 0
- r.token.kind = tokenDelim
- r.token.delimValue = r.Data[r.pos]
- r.pos++
- return
-
- case '0', '1', '2', '3', '4', '5', '6', '7', '8', '9', '-':
- if r.wantSep != 0 {
- r.errSyntax()
- }
- r.token.kind = tokenNumber
- r.fetchNumber()
- return
-
- case 'n':
- if r.wantSep != 0 {
- r.errSyntax()
- }
-
- r.token.kind = tokenNull
- r.fetchNull()
- return
-
- case 't':
- if r.wantSep != 0 {
- r.errSyntax()
- }
-
- r.token.kind = tokenBool
- r.token.boolValue = true
- r.fetchTrue()
- return
-
- case 'f':
- if r.wantSep != 0 {
- r.errSyntax()
- }
-
- r.token.kind = tokenBool
- r.token.boolValue = false
- r.fetchFalse()
- return
-
- default:
- r.errSyntax()
- return
- }
- }
- r.fatalError = io.EOF
- return
-}
-
-// isTokenEnd returns true if the char can follow a non-delimiter token
-func isTokenEnd(c byte) bool {
- return c == ' ' || c == '\t' || c == '\r' || c == '\n' || c == '[' || c == ']' || c == '{' || c == '}' || c == ',' || c == ':'
-}
-
-// fetchNull fetches and checks remaining bytes of null keyword.
-func (r *Lexer) fetchNull() {
- r.pos += 4
- if r.pos > len(r.Data) ||
- r.Data[r.pos-3] != 'u' ||
- r.Data[r.pos-2] != 'l' ||
- r.Data[r.pos-1] != 'l' ||
- (r.pos != len(r.Data) && !isTokenEnd(r.Data[r.pos])) {
-
- r.pos -= 4
- r.errSyntax()
- }
-}
-
-// fetchTrue fetches and checks remaining bytes of true keyword.
-func (r *Lexer) fetchTrue() {
- r.pos += 4
- if r.pos > len(r.Data) ||
- r.Data[r.pos-3] != 'r' ||
- r.Data[r.pos-2] != 'u' ||
- r.Data[r.pos-1] != 'e' ||
- (r.pos != len(r.Data) && !isTokenEnd(r.Data[r.pos])) {
-
- r.pos -= 4
- r.errSyntax()
- }
-}
-
-// fetchFalse fetches and checks remaining bytes of false keyword.
-func (r *Lexer) fetchFalse() {
- r.pos += 5
- if r.pos > len(r.Data) ||
- r.Data[r.pos-4] != 'a' ||
- r.Data[r.pos-3] != 'l' ||
- r.Data[r.pos-2] != 's' ||
- r.Data[r.pos-1] != 'e' ||
- (r.pos != len(r.Data) && !isTokenEnd(r.Data[r.pos])) {
-
- r.pos -= 5
- r.errSyntax()
- }
-}
-
-// fetchNumber scans a number literal token.
-func (r *Lexer) fetchNumber() {
- hasE := false
- afterE := false
- hasDot := false
-
- r.pos++
- for i, c := range r.Data[r.pos:] {
- switch {
- case c >= '0' && c <= '9':
- afterE = false
- case c == '.' && !hasDot:
- hasDot = true
- case (c == 'e' || c == 'E') && !hasE:
- hasE = true
- hasDot = true
- afterE = true
- case (c == '+' || c == '-') && afterE:
- afterE = false
- default:
- r.pos += i
- if !isTokenEnd(c) {
- r.errSyntax()
- } else {
- r.token.byteValue = r.Data[r.start:r.pos]
- }
- return
- }
- }
-
- r.pos = len(r.Data)
- r.token.byteValue = r.Data[r.start:]
-}
-
-// findStringLen tries to scan into the string literal for ending quote char to determine required size.
-// The size will be exact if no escapes are present and may be inexact if there are escaped chars.
-func findStringLen(data []byte) (isValid bool, length int) {
- for {
- idx := bytes.IndexByte(data, '"')
- if idx == -1 {
- return false, len(data)
- }
- if idx == 0 || (idx > 0 && data[idx-1] != '\\') {
- return true, length + idx
- }
-
- // count \\\\\\\ sequences. even number of slashes means quote is not really escaped
- cnt := 1
- for idx-cnt-1 >= 0 && data[idx-cnt-1] == '\\' {
- cnt++
- }
- if cnt%2 == 0 {
- return true, length + idx
- }
-
- length += idx + 1
- data = data[idx+1:]
- }
-}
-
-// unescapeStringToken performs unescaping of string token.
-// if no escaping is needed, original string is returned, otherwise - a new one allocated
-func (r *Lexer) unescapeStringToken() (err error) {
- data := r.token.byteValue
- var unescapedData []byte
-
- for {
- i := bytes.IndexByte(data, '\\')
- if i == -1 {
- break
- }
-
- escapedRune, escapedBytes, err := decodeEscape(data[i:])
- if err != nil {
- r.errParse(err.Error())
- return err
- }
-
- if unescapedData == nil {
- unescapedData = make([]byte, 0, len(r.token.byteValue))
- }
-
- var d [4]byte
- s := utf8.EncodeRune(d[:], escapedRune)
- unescapedData = append(unescapedData, data[:i]...)
- unescapedData = append(unescapedData, d[:s]...)
-
- data = data[i+escapedBytes:]
- }
-
- if unescapedData != nil {
- r.token.byteValue = append(unescapedData, data...)
- r.token.byteValueCloned = true
- }
- return
-}
-
-// getu4 decodes \uXXXX from the beginning of s, returning the hex value,
-// or it returns -1.
-func getu4(s []byte) rune {
- if len(s) < 6 || s[0] != '\\' || s[1] != 'u' {
- return -1
- }
- var val rune
- for i := 2; i < len(s) && i < 6; i++ {
- var v byte
- c := s[i]
- switch c {
- case '0', '1', '2', '3', '4', '5', '6', '7', '8', '9':
- v = c - '0'
- case 'a', 'b', 'c', 'd', 'e', 'f':
- v = c - 'a' + 10
- case 'A', 'B', 'C', 'D', 'E', 'F':
- v = c - 'A' + 10
- default:
- return -1
- }
-
- val <<= 4
- val |= rune(v)
- }
- return val
-}
-
-// decodeEscape processes a single escape sequence and returns number of bytes processed.
-func decodeEscape(data []byte) (decoded rune, bytesProcessed int, err error) {
- if len(data) < 2 {
- return 0, 0, errors.New("incorrect escape symbol \\ at the end of token")
- }
-
- c := data[1]
- switch c {
- case '"', '/', '\\':
- return rune(c), 2, nil
- case 'b':
- return '\b', 2, nil
- case 'f':
- return '\f', 2, nil
- case 'n':
- return '\n', 2, nil
- case 'r':
- return '\r', 2, nil
- case 't':
- return '\t', 2, nil
- case 'u':
- rr := getu4(data)
- if rr < 0 {
- return 0, 0, errors.New("incorrectly escaped \\uXXXX sequence")
- }
-
- read := 6
- if utf16.IsSurrogate(rr) {
- rr1 := getu4(data[read:])
- if dec := utf16.DecodeRune(rr, rr1); dec != unicode.ReplacementChar {
- read += 6
- rr = dec
- } else {
- rr = unicode.ReplacementChar
- }
- }
- return rr, read, nil
- }
-
- return 0, 0, errors.New("incorrectly escaped bytes")
-}
-
-// fetchString scans a string literal token.
-func (r *Lexer) fetchString() {
- r.pos++
- data := r.Data[r.pos:]
-
- isValid, length := findStringLen(data)
- if !isValid {
- r.pos += length
- r.errParse("unterminated string literal")
- return
- }
- r.token.byteValue = data[:length]
- r.pos += length + 1 // skip closing '"' as well
-}
-
-// scanToken scans the next token if no token is currently available in the lexer.
-func (r *Lexer) scanToken() {
- if r.token.kind != tokenUndef || r.fatalError != nil {
- return
- }
-
- r.FetchToken()
-}
-
-// consume resets the current token to allow scanning the next one.
-func (r *Lexer) consume() {
- r.token.kind = tokenUndef
- r.token.byteValueCloned = false
- r.token.delimValue = 0
-}
-
-// Ok returns true if no error (including io.EOF) was encountered during scanning.
-func (r *Lexer) Ok() bool {
- return r.fatalError == nil
-}
-
-const maxErrorContextLen = 13
-
-func (r *Lexer) errParse(what string) {
- if r.fatalError == nil {
- var str string
- if len(r.Data)-r.pos <= maxErrorContextLen {
- str = string(r.Data)
- } else {
- str = string(r.Data[r.pos:r.pos+maxErrorContextLen-3]) + "..."
- }
- r.fatalError = &LexerError{
- Reason: what,
- Offset: r.pos,
- Data: str,
- }
- }
-}
-
-func (r *Lexer) errSyntax() {
- r.errParse("syntax error")
-}
-
-func (r *Lexer) errInvalidToken(expected string) {
- if r.fatalError != nil {
- return
- }
- if r.UseMultipleErrors {
- r.pos = r.start
- r.consume()
- r.SkipRecursive()
- switch expected {
- case "[":
- r.token.delimValue = ']'
- r.token.kind = tokenDelim
- case "{":
- r.token.delimValue = '}'
- r.token.kind = tokenDelim
- }
- r.addNonfatalError(&LexerError{
- Reason: fmt.Sprintf("expected %s", expected),
- Offset: r.start,
- Data: string(r.Data[r.start:r.pos]),
- })
- return
- }
-
- var str string
- if len(r.token.byteValue) <= maxErrorContextLen {
- str = string(r.token.byteValue)
- } else {
- str = string(r.token.byteValue[:maxErrorContextLen-3]) + "..."
- }
- r.fatalError = &LexerError{
- Reason: fmt.Sprintf("expected %s", expected),
- Offset: r.pos,
- Data: str,
- }
-}
-
-func (r *Lexer) GetPos() int {
- return r.pos
-}
-
-// Delim consumes a token and verifies that it is the given delimiter.
-func (r *Lexer) Delim(c byte) {
- if r.token.kind == tokenUndef && r.Ok() {
- r.FetchToken()
- }
-
- if !r.Ok() || r.token.delimValue != c {
- r.consume() // errInvalidToken can change token if UseMultipleErrors is enabled.
- r.errInvalidToken(string([]byte{c}))
- } else {
- r.consume()
- }
-}
-
-// IsDelim returns true if there was no scanning error and next token is the given delimiter.
-func (r *Lexer) IsDelim(c byte) bool {
- if r.token.kind == tokenUndef && r.Ok() {
- r.FetchToken()
- }
- return !r.Ok() || r.token.delimValue == c
-}
-
-// Null verifies that the next token is null and consumes it.
-func (r *Lexer) Null() {
- if r.token.kind == tokenUndef && r.Ok() {
- r.FetchToken()
- }
- if !r.Ok() || r.token.kind != tokenNull {
- r.errInvalidToken("null")
- }
- r.consume()
-}
-
-// IsNull returns true if the next token is a null keyword.
-func (r *Lexer) IsNull() bool {
- if r.token.kind == tokenUndef && r.Ok() {
- r.FetchToken()
- }
- return r.Ok() && r.token.kind == tokenNull
-}
-
-// Skip skips a single token.
-func (r *Lexer) Skip() {
- if r.token.kind == tokenUndef && r.Ok() {
- r.FetchToken()
- }
- r.consume()
-}
-
-// SkipRecursive skips next array or object completely, or just skips a single token if not
-// an array/object.
-//
-// Note: no syntax validation is performed on the skipped data.
-func (r *Lexer) SkipRecursive() {
- r.scanToken()
- var start, end byte
- startPos := r.start
-
- switch r.token.delimValue {
- case '{':
- start, end = '{', '}'
- case '[':
- start, end = '[', ']'
- default:
- r.consume()
- return
- }
-
- r.consume()
-
- level := 1
- inQuotes := false
- wasEscape := false
-
- for i, c := range r.Data[r.pos:] {
- switch {
- case c == start && !inQuotes:
- level++
- case c == end && !inQuotes:
- level--
- if level == 0 {
- r.pos += i + 1
- if !json.Valid(r.Data[startPos:r.pos]) {
- r.pos = len(r.Data)
- r.fatalError = &LexerError{
- Reason: "skipped array/object json value is invalid",
- Offset: r.pos,
- Data: string(r.Data[r.pos:]),
- }
- }
- return
- }
- case c == '\\' && inQuotes:
- wasEscape = !wasEscape
- continue
- case c == '"' && inQuotes:
- inQuotes = wasEscape
- case c == '"':
- inQuotes = true
- }
- wasEscape = false
- }
- r.pos = len(r.Data)
- r.fatalError = &LexerError{
- Reason: "EOF reached while skipping array/object or token",
- Offset: r.pos,
- Data: string(r.Data[r.pos:]),
- }
-}
-
-// Raw fetches the next item recursively as a data slice
-func (r *Lexer) Raw() []byte {
- r.SkipRecursive()
- if !r.Ok() {
- return nil
- }
- return r.Data[r.start:r.pos]
-}
-
-// IsStart returns whether the lexer is positioned at the start
-// of an input string.
-func (r *Lexer) IsStart() bool {
- return r.pos == 0
-}
-
-// Consumed reads all remaining bytes from the input, publishing an error if
-// there is anything but whitespace remaining.
-func (r *Lexer) Consumed() {
- if r.pos > len(r.Data) || !r.Ok() {
- return
- }
-
- for _, c := range r.Data[r.pos:] {
- if c != ' ' && c != '\t' && c != '\r' && c != '\n' {
- r.AddError(&LexerError{
- Reason: "invalid character '" + string(c) + "' after top-level value",
- Offset: r.pos,
- Data: string(r.Data[r.pos:]),
- })
- return
- }
-
- r.pos++
- r.start++
- }
-}
-
-func (r *Lexer) unsafeString(skipUnescape bool) (string, []byte) {
- if r.token.kind == tokenUndef && r.Ok() {
- r.FetchToken()
- }
- if !r.Ok() || r.token.kind != tokenString {
- r.errInvalidToken("string")
- return "", nil
- }
- if !skipUnescape {
- if err := r.unescapeStringToken(); err != nil {
- r.errInvalidToken("string")
- return "", nil
- }
- }
-
- bytes := r.token.byteValue
- ret := bytesToStr(r.token.byteValue)
- r.consume()
- return ret, bytes
-}
-
-// UnsafeString returns the string value if the token is a string literal.
-//
-// Warning: returned string may point to the input buffer, so the string should not outlive
-// the input buffer. Intended pattern of usage is as an argument to a switch statement.
-func (r *Lexer) UnsafeString() string {
- ret, _ := r.unsafeString(false)
- return ret
-}
-
-// UnsafeBytes returns the byte slice if the token is a string literal.
-func (r *Lexer) UnsafeBytes() []byte {
- _, ret := r.unsafeString(false)
- return ret
-}
-
-// UnsafeFieldName returns current member name string token
-func (r *Lexer) UnsafeFieldName(skipUnescape bool) string {
- ret, _ := r.unsafeString(skipUnescape)
- return ret
-}
-
-// String reads a string literal.
-func (r *Lexer) String() string {
- if r.token.kind == tokenUndef && r.Ok() {
- r.FetchToken()
- }
- if !r.Ok() || r.token.kind != tokenString {
- r.errInvalidToken("string")
- return ""
- }
- if err := r.unescapeStringToken(); err != nil {
- r.errInvalidToken("string")
- return ""
- }
- var ret string
- if r.token.byteValueCloned {
- ret = bytesToStr(r.token.byteValue)
- } else {
- ret = string(r.token.byteValue)
- }
- r.consume()
- return ret
-}
-
-// StringIntern reads a string literal, and performs string interning on it.
-func (r *Lexer) StringIntern() string {
- if r.token.kind == tokenUndef && r.Ok() {
- r.FetchToken()
- }
- if !r.Ok() || r.token.kind != tokenString {
- r.errInvalidToken("string")
- return ""
- }
- if err := r.unescapeStringToken(); err != nil {
- r.errInvalidToken("string")
- return ""
- }
- ret := intern.Bytes(r.token.byteValue)
- r.consume()
- return ret
-}
-
-// Bytes reads a string literal and base64 decodes it into a byte slice.
-func (r *Lexer) Bytes() []byte {
- if r.token.kind == tokenUndef && r.Ok() {
- r.FetchToken()
- }
- if !r.Ok() || r.token.kind != tokenString {
- r.errInvalidToken("string")
- return nil
- }
- if err := r.unescapeStringToken(); err != nil {
- r.errInvalidToken("string")
- return nil
- }
- ret := make([]byte, base64.StdEncoding.DecodedLen(len(r.token.byteValue)))
- n, err := base64.StdEncoding.Decode(ret, r.token.byteValue)
- if err != nil {
- r.fatalError = &LexerError{
- Reason: err.Error(),
- }
- return nil
- }
-
- r.consume()
- return ret[:n]
-}
-
-// Bool reads a true or false boolean keyword.
-func (r *Lexer) Bool() bool {
- if r.token.kind == tokenUndef && r.Ok() {
- r.FetchToken()
- }
- if !r.Ok() || r.token.kind != tokenBool {
- r.errInvalidToken("bool")
- return false
- }
- ret := r.token.boolValue
- r.consume()
- return ret
-}
-
-func (r *Lexer) number() string {
- if r.token.kind == tokenUndef && r.Ok() {
- r.FetchToken()
- }
- if !r.Ok() || r.token.kind != tokenNumber {
- r.errInvalidToken("number")
- return ""
- }
- ret := bytesToStr(r.token.byteValue)
- r.consume()
- return ret
-}
-
-func (r *Lexer) Uint8() uint8 {
- s := r.number()
- if !r.Ok() {
- return 0
- }
-
- n, err := strconv.ParseUint(s, 10, 8)
- if err != nil {
- r.addNonfatalError(&LexerError{
- Offset: r.start,
- Reason: err.Error(),
- Data: s,
- })
- }
- return uint8(n)
-}
-
-func (r *Lexer) Uint16() uint16 {
- s := r.number()
- if !r.Ok() {
- return 0
- }
-
- n, err := strconv.ParseUint(s, 10, 16)
- if err != nil {
- r.addNonfatalError(&LexerError{
- Offset: r.start,
- Reason: err.Error(),
- Data: s,
- })
- }
- return uint16(n)
-}
-
-func (r *Lexer) Uint32() uint32 {
- s := r.number()
- if !r.Ok() {
- return 0
- }
-
- n, err := strconv.ParseUint(s, 10, 32)
- if err != nil {
- r.addNonfatalError(&LexerError{
- Offset: r.start,
- Reason: err.Error(),
- Data: s,
- })
- }
- return uint32(n)
-}
-
-func (r *Lexer) Uint64() uint64 {
- s := r.number()
- if !r.Ok() {
- return 0
- }
-
- n, err := strconv.ParseUint(s, 10, 64)
- if err != nil {
- r.addNonfatalError(&LexerError{
- Offset: r.start,
- Reason: err.Error(),
- Data: s,
- })
- }
- return n
-}
-
-func (r *Lexer) Uint() uint {
- return uint(r.Uint64())
-}
-
-func (r *Lexer) Int8() int8 {
- s := r.number()
- if !r.Ok() {
- return 0
- }
-
- n, err := strconv.ParseInt(s, 10, 8)
- if err != nil {
- r.addNonfatalError(&LexerError{
- Offset: r.start,
- Reason: err.Error(),
- Data: s,
- })
- }
- return int8(n)
-}
-
-func (r *Lexer) Int16() int16 {
- s := r.number()
- if !r.Ok() {
- return 0
- }
-
- n, err := strconv.ParseInt(s, 10, 16)
- if err != nil {
- r.addNonfatalError(&LexerError{
- Offset: r.start,
- Reason: err.Error(),
- Data: s,
- })
- }
- return int16(n)
-}
-
-func (r *Lexer) Int32() int32 {
- s := r.number()
- if !r.Ok() {
- return 0
- }
-
- n, err := strconv.ParseInt(s, 10, 32)
- if err != nil {
- r.addNonfatalError(&LexerError{
- Offset: r.start,
- Reason: err.Error(),
- Data: s,
- })
- }
- return int32(n)
-}
-
-func (r *Lexer) Int64() int64 {
- s := r.number()
- if !r.Ok() {
- return 0
- }
-
- n, err := strconv.ParseInt(s, 10, 64)
- if err != nil {
- r.addNonfatalError(&LexerError{
- Offset: r.start,
- Reason: err.Error(),
- Data: s,
- })
- }
- return n
-}
-
-func (r *Lexer) Int() int {
- return int(r.Int64())
-}
-
-func (r *Lexer) Uint8Str() uint8 {
- s, b := r.unsafeString(false)
- if !r.Ok() {
- return 0
- }
-
- n, err := strconv.ParseUint(s, 10, 8)
- if err != nil {
- r.addNonfatalError(&LexerError{
- Offset: r.start,
- Reason: err.Error(),
- Data: string(b),
- })
- }
- return uint8(n)
-}
-
-func (r *Lexer) Uint16Str() uint16 {
- s, b := r.unsafeString(false)
- if !r.Ok() {
- return 0
- }
-
- n, err := strconv.ParseUint(s, 10, 16)
- if err != nil {
- r.addNonfatalError(&LexerError{
- Offset: r.start,
- Reason: err.Error(),
- Data: string(b),
- })
- }
- return uint16(n)
-}
-
-func (r *Lexer) Uint32Str() uint32 {
- s, b := r.unsafeString(false)
- if !r.Ok() {
- return 0
- }
-
- n, err := strconv.ParseUint(s, 10, 32)
- if err != nil {
- r.addNonfatalError(&LexerError{
- Offset: r.start,
- Reason: err.Error(),
- Data: string(b),
- })
- }
- return uint32(n)
-}
-
-func (r *Lexer) Uint64Str() uint64 {
- s, b := r.unsafeString(false)
- if !r.Ok() {
- return 0
- }
-
- n, err := strconv.ParseUint(s, 10, 64)
- if err != nil {
- r.addNonfatalError(&LexerError{
- Offset: r.start,
- Reason: err.Error(),
- Data: string(b),
- })
- }
- return n
-}
-
-func (r *Lexer) UintStr() uint {
- return uint(r.Uint64Str())
-}
-
-func (r *Lexer) UintptrStr() uintptr {
- return uintptr(r.Uint64Str())
-}
-
-func (r *Lexer) Int8Str() int8 {
- s, b := r.unsafeString(false)
- if !r.Ok() {
- return 0
- }
-
- n, err := strconv.ParseInt(s, 10, 8)
- if err != nil {
- r.addNonfatalError(&LexerError{
- Offset: r.start,
- Reason: err.Error(),
- Data: string(b),
- })
- }
- return int8(n)
-}
-
-func (r *Lexer) Int16Str() int16 {
- s, b := r.unsafeString(false)
- if !r.Ok() {
- return 0
- }
-
- n, err := strconv.ParseInt(s, 10, 16)
- if err != nil {
- r.addNonfatalError(&LexerError{
- Offset: r.start,
- Reason: err.Error(),
- Data: string(b),
- })
- }
- return int16(n)
-}
-
-func (r *Lexer) Int32Str() int32 {
- s, b := r.unsafeString(false)
- if !r.Ok() {
- return 0
- }
-
- n, err := strconv.ParseInt(s, 10, 32)
- if err != nil {
- r.addNonfatalError(&LexerError{
- Offset: r.start,
- Reason: err.Error(),
- Data: string(b),
- })
- }
- return int32(n)
-}
-
-func (r *Lexer) Int64Str() int64 {
- s, b := r.unsafeString(false)
- if !r.Ok() {
- return 0
- }
-
- n, err := strconv.ParseInt(s, 10, 64)
- if err != nil {
- r.addNonfatalError(&LexerError{
- Offset: r.start,
- Reason: err.Error(),
- Data: string(b),
- })
- }
- return n
-}
-
-func (r *Lexer) IntStr() int {
- return int(r.Int64Str())
-}
-
-func (r *Lexer) Float32() float32 {
- s := r.number()
- if !r.Ok() {
- return 0
- }
-
- n, err := strconv.ParseFloat(s, 32)
- if err != nil {
- r.addNonfatalError(&LexerError{
- Offset: r.start,
- Reason: err.Error(),
- Data: s,
- })
- }
- return float32(n)
-}
-
-func (r *Lexer) Float32Str() float32 {
- s, b := r.unsafeString(false)
- if !r.Ok() {
- return 0
- }
- n, err := strconv.ParseFloat(s, 32)
- if err != nil {
- r.addNonfatalError(&LexerError{
- Offset: r.start,
- Reason: err.Error(),
- Data: string(b),
- })
- }
- return float32(n)
-}
-
-func (r *Lexer) Float64() float64 {
- s := r.number()
- if !r.Ok() {
- return 0
- }
-
- n, err := strconv.ParseFloat(s, 64)
- if err != nil {
- r.addNonfatalError(&LexerError{
- Offset: r.start,
- Reason: err.Error(),
- Data: s,
- })
- }
- return n
-}
-
-func (r *Lexer) Float64Str() float64 {
- s, b := r.unsafeString(false)
- if !r.Ok() {
- return 0
- }
- n, err := strconv.ParseFloat(s, 64)
- if err != nil {
- r.addNonfatalError(&LexerError{
- Offset: r.start,
- Reason: err.Error(),
- Data: string(b),
- })
- }
- return n
-}
-
-func (r *Lexer) Error() error {
- return r.fatalError
-}
-
-func (r *Lexer) AddError(e error) {
- if r.fatalError == nil {
- r.fatalError = e
- }
-}
-
-func (r *Lexer) AddNonFatalError(e error) {
- r.addNonfatalError(&LexerError{
- Offset: r.start,
- Data: string(r.Data[r.start:r.pos]),
- Reason: e.Error(),
- })
-}
-
-func (r *Lexer) addNonfatalError(err *LexerError) {
- if r.UseMultipleErrors {
- // We don't want to add errors with the same offset.
- if len(r.multipleErrors) != 0 && r.multipleErrors[len(r.multipleErrors)-1].Offset == err.Offset {
- return
- }
- r.multipleErrors = append(r.multipleErrors, err)
- return
- }
- r.fatalError = err
-}
-
-func (r *Lexer) GetNonFatalErrors() []*LexerError {
- return r.multipleErrors
-}
-
-// JsonNumber fetches and json.Number from 'encoding/json' package.
-// Both int, float or string, contains them are valid values
-func (r *Lexer) JsonNumber() json.Number {
- if r.token.kind == tokenUndef && r.Ok() {
- r.FetchToken()
- }
- if !r.Ok() {
- r.errInvalidToken("json.Number")
- return json.Number("")
- }
-
- switch r.token.kind {
- case tokenString:
- return json.Number(r.String())
- case tokenNumber:
- return json.Number(r.Raw())
- case tokenNull:
- r.Null()
- return json.Number("")
- default:
- r.errSyntax()
- return json.Number("")
- }
-}
-
-// Interface fetches an interface{} analogous to the 'encoding/json' package.
-func (r *Lexer) Interface() interface{} {
- if r.token.kind == tokenUndef && r.Ok() {
- r.FetchToken()
- }
-
- if !r.Ok() {
- return nil
- }
- switch r.token.kind {
- case tokenString:
- return r.String()
- case tokenNumber:
- return r.Float64()
- case tokenBool:
- return r.Bool()
- case tokenNull:
- r.Null()
- return nil
- }
-
- if r.token.delimValue == '{' {
- r.consume()
-
- ret := map[string]interface{}{}
- for !r.IsDelim('}') {
- key := r.String()
- r.WantColon()
- ret[key] = r.Interface()
- r.WantComma()
- }
- r.Delim('}')
-
- if r.Ok() {
- return ret
- } else {
- return nil
- }
- } else if r.token.delimValue == '[' {
- r.consume()
-
- ret := []interface{}{}
- for !r.IsDelim(']') {
- ret = append(ret, r.Interface())
- r.WantComma()
- }
- r.Delim(']')
-
- if r.Ok() {
- return ret
- } else {
- return nil
- }
- }
- r.errSyntax()
- return nil
-}
-
-// WantComma requires a comma to be present before fetching next token.
-func (r *Lexer) WantComma() {
- r.wantSep = ','
- r.firstElement = false
-}
-
-// WantColon requires a colon to be present before fetching next token.
-func (r *Lexer) WantColon() {
- r.wantSep = ':'
- r.firstElement = false
-}
diff --git a/vendor/github.com/mailru/easyjson/jwriter/writer.go b/vendor/github.com/mailru/easyjson/jwriter/writer.go
deleted file mode 100644
index 2c5b20105b..0000000000
--- a/vendor/github.com/mailru/easyjson/jwriter/writer.go
+++ /dev/null
@@ -1,405 +0,0 @@
-// Package jwriter contains a JSON writer.
-package jwriter
-
-import (
- "io"
- "strconv"
- "unicode/utf8"
-
- "github.com/mailru/easyjson/buffer"
-)
-
-// Flags describe various encoding options. The behavior may be actually implemented in the encoder, but
-// Flags field in Writer is used to set and pass them around.
-type Flags int
-
-const (
- NilMapAsEmpty Flags = 1 << iota // Encode nil map as '{}' rather than 'null'.
- NilSliceAsEmpty // Encode nil slice as '[]' rather than 'null'.
-)
-
-// Writer is a JSON writer.
-type Writer struct {
- Flags Flags
-
- Error error
- Buffer buffer.Buffer
- NoEscapeHTML bool
-}
-
-// Size returns the size of the data that was written out.
-func (w *Writer) Size() int {
- return w.Buffer.Size()
-}
-
-// DumpTo outputs the data to given io.Writer, resetting the buffer.
-func (w *Writer) DumpTo(out io.Writer) (written int, err error) {
- return w.Buffer.DumpTo(out)
-}
-
-// BuildBytes returns writer data as a single byte slice. You can optionally provide one byte slice
-// as argument that it will try to reuse.
-func (w *Writer) BuildBytes(reuse ...[]byte) ([]byte, error) {
- if w.Error != nil {
- return nil, w.Error
- }
-
- return w.Buffer.BuildBytes(reuse...), nil
-}
-
-// ReadCloser returns an io.ReadCloser that can be used to read the data.
-// ReadCloser also resets the buffer.
-func (w *Writer) ReadCloser() (io.ReadCloser, error) {
- if w.Error != nil {
- return nil, w.Error
- }
-
- return w.Buffer.ReadCloser(), nil
-}
-
-// RawByte appends raw binary data to the buffer.
-func (w *Writer) RawByte(c byte) {
- w.Buffer.AppendByte(c)
-}
-
-// RawByte appends raw binary data to the buffer.
-func (w *Writer) RawString(s string) {
- w.Buffer.AppendString(s)
-}
-
-// Raw appends raw binary data to the buffer or sets the error if it is given. Useful for
-// calling with results of MarshalJSON-like functions.
-func (w *Writer) Raw(data []byte, err error) {
- switch {
- case w.Error != nil:
- return
- case err != nil:
- w.Error = err
- case len(data) > 0:
- w.Buffer.AppendBytes(data)
- default:
- w.RawString("null")
- }
-}
-
-// RawText encloses raw binary data in quotes and appends in to the buffer.
-// Useful for calling with results of MarshalText-like functions.
-func (w *Writer) RawText(data []byte, err error) {
- switch {
- case w.Error != nil:
- return
- case err != nil:
- w.Error = err
- case len(data) > 0:
- w.String(string(data))
- default:
- w.RawString("null")
- }
-}
-
-// Base64Bytes appends data to the buffer after base64 encoding it
-func (w *Writer) Base64Bytes(data []byte) {
- if data == nil {
- w.Buffer.AppendString("null")
- return
- }
- w.Buffer.AppendByte('"')
- w.base64(data)
- w.Buffer.AppendByte('"')
-}
-
-func (w *Writer) Uint8(n uint8) {
- w.Buffer.EnsureSpace(3)
- w.Buffer.Buf = strconv.AppendUint(w.Buffer.Buf, uint64(n), 10)
-}
-
-func (w *Writer) Uint16(n uint16) {
- w.Buffer.EnsureSpace(5)
- w.Buffer.Buf = strconv.AppendUint(w.Buffer.Buf, uint64(n), 10)
-}
-
-func (w *Writer) Uint32(n uint32) {
- w.Buffer.EnsureSpace(10)
- w.Buffer.Buf = strconv.AppendUint(w.Buffer.Buf, uint64(n), 10)
-}
-
-func (w *Writer) Uint(n uint) {
- w.Buffer.EnsureSpace(20)
- w.Buffer.Buf = strconv.AppendUint(w.Buffer.Buf, uint64(n), 10)
-}
-
-func (w *Writer) Uint64(n uint64) {
- w.Buffer.EnsureSpace(20)
- w.Buffer.Buf = strconv.AppendUint(w.Buffer.Buf, n, 10)
-}
-
-func (w *Writer) Int8(n int8) {
- w.Buffer.EnsureSpace(4)
- w.Buffer.Buf = strconv.AppendInt(w.Buffer.Buf, int64(n), 10)
-}
-
-func (w *Writer) Int16(n int16) {
- w.Buffer.EnsureSpace(6)
- w.Buffer.Buf = strconv.AppendInt(w.Buffer.Buf, int64(n), 10)
-}
-
-func (w *Writer) Int32(n int32) {
- w.Buffer.EnsureSpace(11)
- w.Buffer.Buf = strconv.AppendInt(w.Buffer.Buf, int64(n), 10)
-}
-
-func (w *Writer) Int(n int) {
- w.Buffer.EnsureSpace(21)
- w.Buffer.Buf = strconv.AppendInt(w.Buffer.Buf, int64(n), 10)
-}
-
-func (w *Writer) Int64(n int64) {
- w.Buffer.EnsureSpace(21)
- w.Buffer.Buf = strconv.AppendInt(w.Buffer.Buf, n, 10)
-}
-
-func (w *Writer) Uint8Str(n uint8) {
- w.Buffer.EnsureSpace(3)
- w.Buffer.Buf = append(w.Buffer.Buf, '"')
- w.Buffer.Buf = strconv.AppendUint(w.Buffer.Buf, uint64(n), 10)
- w.Buffer.Buf = append(w.Buffer.Buf, '"')
-}
-
-func (w *Writer) Uint16Str(n uint16) {
- w.Buffer.EnsureSpace(5)
- w.Buffer.Buf = append(w.Buffer.Buf, '"')
- w.Buffer.Buf = strconv.AppendUint(w.Buffer.Buf, uint64(n), 10)
- w.Buffer.Buf = append(w.Buffer.Buf, '"')
-}
-
-func (w *Writer) Uint32Str(n uint32) {
- w.Buffer.EnsureSpace(10)
- w.Buffer.Buf = append(w.Buffer.Buf, '"')
- w.Buffer.Buf = strconv.AppendUint(w.Buffer.Buf, uint64(n), 10)
- w.Buffer.Buf = append(w.Buffer.Buf, '"')
-}
-
-func (w *Writer) UintStr(n uint) {
- w.Buffer.EnsureSpace(20)
- w.Buffer.Buf = append(w.Buffer.Buf, '"')
- w.Buffer.Buf = strconv.AppendUint(w.Buffer.Buf, uint64(n), 10)
- w.Buffer.Buf = append(w.Buffer.Buf, '"')
-}
-
-func (w *Writer) Uint64Str(n uint64) {
- w.Buffer.EnsureSpace(20)
- w.Buffer.Buf = append(w.Buffer.Buf, '"')
- w.Buffer.Buf = strconv.AppendUint(w.Buffer.Buf, n, 10)
- w.Buffer.Buf = append(w.Buffer.Buf, '"')
-}
-
-func (w *Writer) UintptrStr(n uintptr) {
- w.Buffer.EnsureSpace(20)
- w.Buffer.Buf = append(w.Buffer.Buf, '"')
- w.Buffer.Buf = strconv.AppendUint(w.Buffer.Buf, uint64(n), 10)
- w.Buffer.Buf = append(w.Buffer.Buf, '"')
-}
-
-func (w *Writer) Int8Str(n int8) {
- w.Buffer.EnsureSpace(4)
- w.Buffer.Buf = append(w.Buffer.Buf, '"')
- w.Buffer.Buf = strconv.AppendInt(w.Buffer.Buf, int64(n), 10)
- w.Buffer.Buf = append(w.Buffer.Buf, '"')
-}
-
-func (w *Writer) Int16Str(n int16) {
- w.Buffer.EnsureSpace(6)
- w.Buffer.Buf = append(w.Buffer.Buf, '"')
- w.Buffer.Buf = strconv.AppendInt(w.Buffer.Buf, int64(n), 10)
- w.Buffer.Buf = append(w.Buffer.Buf, '"')
-}
-
-func (w *Writer) Int32Str(n int32) {
- w.Buffer.EnsureSpace(11)
- w.Buffer.Buf = append(w.Buffer.Buf, '"')
- w.Buffer.Buf = strconv.AppendInt(w.Buffer.Buf, int64(n), 10)
- w.Buffer.Buf = append(w.Buffer.Buf, '"')
-}
-
-func (w *Writer) IntStr(n int) {
- w.Buffer.EnsureSpace(21)
- w.Buffer.Buf = append(w.Buffer.Buf, '"')
- w.Buffer.Buf = strconv.AppendInt(w.Buffer.Buf, int64(n), 10)
- w.Buffer.Buf = append(w.Buffer.Buf, '"')
-}
-
-func (w *Writer) Int64Str(n int64) {
- w.Buffer.EnsureSpace(21)
- w.Buffer.Buf = append(w.Buffer.Buf, '"')
- w.Buffer.Buf = strconv.AppendInt(w.Buffer.Buf, n, 10)
- w.Buffer.Buf = append(w.Buffer.Buf, '"')
-}
-
-func (w *Writer) Float32(n float32) {
- w.Buffer.EnsureSpace(20)
- w.Buffer.Buf = strconv.AppendFloat(w.Buffer.Buf, float64(n), 'g', -1, 32)
-}
-
-func (w *Writer) Float32Str(n float32) {
- w.Buffer.EnsureSpace(20)
- w.Buffer.Buf = append(w.Buffer.Buf, '"')
- w.Buffer.Buf = strconv.AppendFloat(w.Buffer.Buf, float64(n), 'g', -1, 32)
- w.Buffer.Buf = append(w.Buffer.Buf, '"')
-}
-
-func (w *Writer) Float64(n float64) {
- w.Buffer.EnsureSpace(20)
- w.Buffer.Buf = strconv.AppendFloat(w.Buffer.Buf, n, 'g', -1, 64)
-}
-
-func (w *Writer) Float64Str(n float64) {
- w.Buffer.EnsureSpace(20)
- w.Buffer.Buf = append(w.Buffer.Buf, '"')
- w.Buffer.Buf = strconv.AppendFloat(w.Buffer.Buf, float64(n), 'g', -1, 64)
- w.Buffer.Buf = append(w.Buffer.Buf, '"')
-}
-
-func (w *Writer) Bool(v bool) {
- w.Buffer.EnsureSpace(5)
- if v {
- w.Buffer.Buf = append(w.Buffer.Buf, "true"...)
- } else {
- w.Buffer.Buf = append(w.Buffer.Buf, "false"...)
- }
-}
-
-const chars = "0123456789abcdef"
-
-func getTable(falseValues ...int) [128]bool {
- table := [128]bool{}
-
- for i := 0; i < 128; i++ {
- table[i] = true
- }
-
- for _, v := range falseValues {
- table[v] = false
- }
-
- return table
-}
-
-var (
- htmlEscapeTable = getTable(0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, '"', '&', '<', '>', '\\')
- htmlNoEscapeTable = getTable(0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, '"', '\\')
-)
-
-func (w *Writer) String(s string) {
- w.Buffer.AppendByte('"')
-
- // Portions of the string that contain no escapes are appended as
- // byte slices.
-
- p := 0 // last non-escape symbol
-
- escapeTable := &htmlEscapeTable
- if w.NoEscapeHTML {
- escapeTable = &htmlNoEscapeTable
- }
-
- for i := 0; i < len(s); {
- c := s[i]
-
- if c < utf8.RuneSelf {
- if escapeTable[c] {
- // single-width character, no escaping is required
- i++
- continue
- }
-
- w.Buffer.AppendString(s[p:i])
- switch c {
- case '\t':
- w.Buffer.AppendString(`\t`)
- case '\r':
- w.Buffer.AppendString(`\r`)
- case '\n':
- w.Buffer.AppendString(`\n`)
- case '\\':
- w.Buffer.AppendString(`\\`)
- case '"':
- w.Buffer.AppendString(`\"`)
- default:
- w.Buffer.AppendString(`\u00`)
- w.Buffer.AppendByte(chars[c>>4])
- w.Buffer.AppendByte(chars[c&0xf])
- }
-
- i++
- p = i
- continue
- }
-
- // broken utf
- runeValue, runeWidth := utf8.DecodeRuneInString(s[i:])
- if runeValue == utf8.RuneError && runeWidth == 1 {
- w.Buffer.AppendString(s[p:i])
- w.Buffer.AppendString(`\ufffd`)
- i++
- p = i
- continue
- }
-
- // jsonp stuff - tab separator and line separator
- if runeValue == '\u2028' || runeValue == '\u2029' {
- w.Buffer.AppendString(s[p:i])
- w.Buffer.AppendString(`\u202`)
- w.Buffer.AppendByte(chars[runeValue&0xf])
- i += runeWidth
- p = i
- continue
- }
- i += runeWidth
- }
- w.Buffer.AppendString(s[p:])
- w.Buffer.AppendByte('"')
-}
-
-const encode = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"
-const padChar = '='
-
-func (w *Writer) base64(in []byte) {
-
- if len(in) == 0 {
- return
- }
-
- w.Buffer.EnsureSpace(((len(in)-1)/3 + 1) * 4)
-
- si := 0
- n := (len(in) / 3) * 3
-
- for si < n {
- // Convert 3x 8bit source bytes into 4 bytes
- val := uint(in[si+0])<<16 | uint(in[si+1])<<8 | uint(in[si+2])
-
- w.Buffer.Buf = append(w.Buffer.Buf, encode[val>>18&0x3F], encode[val>>12&0x3F], encode[val>>6&0x3F], encode[val&0x3F])
-
- si += 3
- }
-
- remain := len(in) - si
- if remain == 0 {
- return
- }
-
- // Add the remaining small block
- val := uint(in[si+0]) << 16
- if remain == 2 {
- val |= uint(in[si+1]) << 8
- }
-
- w.Buffer.Buf = append(w.Buffer.Buf, encode[val>>18&0x3F], encode[val>>12&0x3F])
-
- switch remain {
- case 2:
- w.Buffer.Buf = append(w.Buffer.Buf, encode[val>>6&0x3F], byte(padChar))
- case 1:
- w.Buffer.Buf = append(w.Buffer.Buf, byte(padChar), byte(padChar))
- }
-}
diff --git a/vendor/github.com/opencontainers/runtime-spec/specs-go/config.go b/vendor/github.com/opencontainers/runtime-spec/specs-go/config.go
index 1aa0693b57..3ef333387b 100644
--- a/vendor/github.com/opencontainers/runtime-spec/specs-go/config.go
+++ b/vendor/github.com/opencontainers/runtime-spec/specs-go/config.go
@@ -31,6 +31,8 @@ type Spec struct {
VM *VM `json:"vm,omitempty" platform:"vm"`
// ZOS is platform-specific configuration for z/OS based containers.
ZOS *ZOS `json:"zos,omitempty" platform:"zos"`
+ // FreeBSD is platform-specific configuration for FreeBSD based containers.
+ FreeBSD *FreeBSD `json:"freebsd,omitempty" platform:"freebsd"`
}
// Scheduler represents the scheduling attributes for a process. It is based on
@@ -170,7 +172,7 @@ type Mount struct {
// Destination is the absolute path where the mount will be placed in the container.
Destination string `json:"destination"`
// Type specifies the mount kind.
- Type string `json:"type,omitempty" platform:"linux,solaris,zos"`
+ Type string `json:"type,omitempty" platform:"linux,solaris,zos,freebsd"`
// Source specifies the source path of the mount.
Source string `json:"source,omitempty"`
// Options are fstab style mount options.
@@ -236,6 +238,8 @@ type Linux struct {
Namespaces []LinuxNamespace `json:"namespaces,omitempty"`
// Devices are a list of device nodes that are created for the container
Devices []LinuxDevice `json:"devices,omitempty"`
+ // NetDevices are key-value pairs, keyed by network device name on the host, moved to the container's network namespace.
+ NetDevices map[string]LinuxNetDevice `json:"netDevices,omitempty"`
// Seccomp specifies the seccomp security settings for the container.
Seccomp *LinuxSeccomp `json:"seccomp,omitempty"`
// RootfsPropagation is the rootfs mount propagation mode for the container.
@@ -249,6 +253,8 @@ type Linux struct {
// IntelRdt contains Intel Resource Director Technology (RDT) information for
// handling resource constraints and monitoring metrics (e.g., L3 cache, memory bandwidth) for the container
IntelRdt *LinuxIntelRdt `json:"intelRdt,omitempty"`
+ // MemoryPolicy contains NUMA memory policy for the container.
+ MemoryPolicy *LinuxMemoryPolicy `json:"memoryPolicy,omitempty"`
// Personality contains configuration for the Linux personality syscall
Personality *LinuxPersonality `json:"personality,omitempty"`
// TimeOffsets specifies the offset for supporting time namespaces.
@@ -430,7 +436,7 @@ type LinuxCPU struct {
// LinuxPids for Linux cgroup 'pids' resource management (Linux 4.3)
type LinuxPids struct {
// Maximum number of PIDs. Default is "no limit".
- Limit int64 `json:"limit"`
+ Limit *int64 `json:"limit,omitempty"`
}
// LinuxNetwork identification and priority configuration
@@ -491,6 +497,12 @@ type LinuxDevice struct {
GID *uint32 `json:"gid,omitempty"`
}
+// LinuxNetDevice represents a single network device to be added to the container's network namespace
+type LinuxNetDevice struct {
+ // Name of the device in the container namespace
+ Name string `json:"name,omitempty"`
+}
+
// LinuxDeviceCgroup represents a device rule for the devices specified to
// the device controller
type LinuxDeviceCgroup struct {
@@ -678,6 +690,32 @@ type WindowsHyperV struct {
UtilityVMPath string `json:"utilityVMPath,omitempty"`
}
+// IOMems contains information about iomem addresses that should be passed to the VM.
+type IOMems struct {
+ // Guest Frame Number to map the iomem range. If GFN is not specified, the mapping will be done to the same Frame Number as was provided in FirstMFN.
+ FirstGFN *uint64 `json:"firstGFN,omitempty"`
+ // Physical page number of iomem regions.
+ FirstMFN *uint64 `json:"firstMFN"`
+ // Number of pages to be mapped.
+ NrMFNs *uint64 `json:"nrMFNs"`
+}
+
+// Hardware configuration for the VM image
+type HWConfig struct {
+ // Path to the container device-tree file that should be passed to the VM configuration.
+ DeviceTree string `json:"deviceTree,omitempty"`
+ // Number of virtual cpus for the VM.
+ VCPUs *uint32 `json:"vcpus,omitempty"`
+ // Maximum memory in bytes allocated to the VM.
+ Memory *uint64 `json:"memory,omitempty"`
+ // Host device tree nodes to passthrough to the VM.
+ DtDevs []string `json:"dtdevs,omitempty"`
+ // Allow auto-translated domains to access specific hardware I/O memory pages.
+ IOMems []IOMems `json:"iomems,omitempty"`
+ // Allows VM to access specific physical IRQs.
+ Irqs []uint32 `json:"irqs,omitempty"`
+}
+
// VM contains information for virtual-machine-based containers.
type VM struct {
// Hypervisor specifies hypervisor-related configuration for virtual-machine-based containers.
@@ -686,6 +724,8 @@ type VM struct {
Kernel VMKernel `json:"kernel"`
// Image specifies guest image related configuration for virtual-machine-based containers.
Image VMImage `json:"image,omitempty"`
+ // Hardware configuration that should be passed to the VM.
+ HwConfig *HWConfig `json:"hwconfig,omitempty"`
}
// VMHypervisor contains information about the hypervisor to use for a virtual machine.
@@ -828,23 +868,41 @@ type LinuxSyscall struct {
type LinuxIntelRdt struct {
// The identity for RDT Class of Service
ClosID string `json:"closID,omitempty"`
+
+ // Schemata specifies the complete schemata to be written as is to the
+ // schemata file in resctrl fs. Each element represents a single line in the schemata file.
+ // NOTE: This will overwrite schemas specified in the L3CacheSchema and/or
+ // MemBwSchema fields.
+ Schemata []string `json:"schemata,omitempty"`
+
// The schema for L3 cache id and capacity bitmask (CBM)
// Format: "L3:=;=;..."
+ // NOTE: Should not be specified if Schemata is non-empty.
L3CacheSchema string `json:"l3CacheSchema,omitempty"`
// The schema of memory bandwidth per L3 cache id
// Format: "MB:=bandwidth0;=bandwidth1;..."
// The unit of memory bandwidth is specified in "percentages" by
// default, and in "MBps" if MBA Software Controller is enabled.
+ // NOTE: Should not be specified if Schemata is non-empty.
MemBwSchema string `json:"memBwSchema,omitempty"`
- // EnableCMT is the flag to indicate if the Intel RDT CMT is enabled. CMT (Cache Monitoring Technology) supports monitoring of
- // the last-level cache (LLC) occupancy for the container.
- EnableCMT bool `json:"enableCMT,omitempty"`
+ // EnableMonitoring enables resctrl monitoring for the container. This will
+ // create a dedicated resctrl monitoring group for the container.
+ EnableMonitoring bool `json:"enableMonitoring,omitempty"`
+}
+
+// LinuxMemoryPolicy represents input for the set_mempolicy syscall.
+type LinuxMemoryPolicy struct {
+ // Mode for the set_mempolicy syscall.
+ Mode MemoryPolicyModeType `json:"mode"`
- // EnableMBM is the flag to indicate if the Intel RDT MBM is enabled. MBM (Memory Bandwidth Monitoring) supports monitoring of
- // total and local memory bandwidth for the container.
- EnableMBM bool `json:"enableMBM,omitempty"`
+ // Nodes representing the nodemask for the set_mempolicy syscall in comma separated ranges format.
+ // Format: "-,,-,..."
+ Nodes string `json:"nodes"`
+
+ // Flags for the set_mempolicy syscall.
+ Flags []MemoryPolicyFlagType `json:"flags,omitempty"`
}
// ZOS contains platform-specific configuration for z/OS based containers.
@@ -876,6 +934,26 @@ const (
ZOSUTSNamespace ZOSNamespaceType = "uts"
)
+type MemoryPolicyModeType string
+
+const (
+ MpolDefault MemoryPolicyModeType = "MPOL_DEFAULT"
+ MpolBind MemoryPolicyModeType = "MPOL_BIND"
+ MpolInterleave MemoryPolicyModeType = "MPOL_INTERLEAVE"
+ MpolWeightedInterleave MemoryPolicyModeType = "MPOL_WEIGHTED_INTERLEAVE"
+ MpolPreferred MemoryPolicyModeType = "MPOL_PREFERRED"
+ MpolPreferredMany MemoryPolicyModeType = "MPOL_PREFERRED_MANY"
+ MpolLocal MemoryPolicyModeType = "MPOL_LOCAL"
+)
+
+type MemoryPolicyFlagType string
+
+const (
+ MpolFNumaBalancing MemoryPolicyFlagType = "MPOL_F_NUMA_BALANCING"
+ MpolFRelativeNodes MemoryPolicyFlagType = "MPOL_F_RELATIVE_NODES"
+ MpolFStaticNodes MemoryPolicyFlagType = "MPOL_F_STATIC_NODES"
+)
+
// LinuxSchedulerPolicy represents different scheduling policies used with the Linux Scheduler
type LinuxSchedulerPolicy string
@@ -915,3 +993,75 @@ const (
// SchedFlagUtilClampMin represents the utilization clamp maximum scheduling flag
SchedFlagUtilClampMax LinuxSchedulerFlag = "SCHED_FLAG_UTIL_CLAMP_MAX"
)
+
+// FreeBSD contains platform-specific configuration for FreeBSD based containers.
+type FreeBSD struct {
+ // Devices which are accessible in the container
+ Devices []FreeBSDDevice `json:"devices,omitempty"`
+ // Jail definition for this container
+ Jail *FreeBSDJail `json:"jail,omitempty"`
+}
+
+type FreeBSDDevice struct {
+ // Path to the device, relative to /dev.
+ Path string `json:"path"`
+ // FileMode permission bits for the device.
+ Mode *os.FileMode `json:"mode,omitempty"`
+}
+
+// FreeBSDJail describes how to configure the container's jail
+type FreeBSDJail struct {
+ // Parent jail name - this can be used to share a single vnet
+ // across several containers
+ Parent string `json:"parent,omitempty"`
+ // Whether to use parent UTS names or override in the container
+ Host FreeBSDSharing `json:"host,omitempty"`
+ // IPv4 address sharing for the container
+ Ip4 FreeBSDSharing `json:"ip4,omitempty"`
+ // IPv4 addresses for the container
+ Ip4Addr []string `json:"ip4Addr,omitempty"`
+ // IPv6 address sharing for the container
+ Ip6 FreeBSDSharing `json:"ip6,omitempty"`
+ // IPv6 addresses for the container
+ Ip6Addr []string `json:"ip6Addr,omitempty"`
+ // Which network stack to use for the container
+ Vnet FreeBSDSharing `json:"vnet,omitempty"`
+ // If set, Ip4Addr and Ip6Addr addresses will be added to this interface
+ Interface string `json:"interface,omitempty"`
+ // List interfaces to be moved to the container's vnet
+ VnetInterfaces []string `json:"vnetInterfaces,omitempty"`
+ // SystemV IPC message sharing for the container
+ SysVMsg FreeBSDSharing `json:"sysvmsg,omitempty"`
+ // SystemV semaphore message sharing for the container
+ SysVSem FreeBSDSharing `json:"sysvsem,omitempty"`
+ // SystemV memory sharing for the container
+ SysVShm FreeBSDSharing `json:"sysvshm,omitempty"`
+ // Mount visibility (see jail(8) for details)
+ EnforceStatfs *int `json:"enforceStatfs,omitempty"`
+ // Jail capabilities
+ Allow *FreeBSDJailAllow `json:"allow,omitempty"`
+}
+
+// These values are used to control access to features in the container, either
+// disabling the feature, sharing state with the parent or creating new private
+// state in the container.
+type FreeBSDSharing string
+
+const (
+ FreeBSDShareDisable FreeBSDSharing = "disable"
+ FreeBSDShareNew FreeBSDSharing = "new"
+ FreeBSDShareInherit FreeBSDSharing = "inherit"
+)
+
+// FreeBSDJailAllow describes jail capabilities
+type FreeBSDJailAllow struct {
+ SetHostname bool `json:"setHostname,omitempty"`
+ RawSockets bool `json:"rawSockets,omitempty"`
+ Chflags bool `json:"chflags,omitempty"`
+ Mount []string `json:"mount,omitempty"`
+ Quotas bool `json:"quotas,omitempty"`
+ SocketAf bool `json:"socketAf,omitempty"`
+ Mlock bool `json:"mlock,omitempty"`
+ ReservedPorts bool `json:"reservedPorts,omitempty"`
+ Suser bool `json:"suser,omitempty"`
+}
diff --git a/vendor/github.com/opencontainers/runtime-spec/specs-go/version.go b/vendor/github.com/opencontainers/runtime-spec/specs-go/version.go
index 23234a9c58..0257dba3e7 100644
--- a/vendor/github.com/opencontainers/runtime-spec/specs-go/version.go
+++ b/vendor/github.com/opencontainers/runtime-spec/specs-go/version.go
@@ -6,9 +6,9 @@ const (
// VersionMajor is for an API incompatible changes
VersionMajor = 1
// VersionMinor is for functionality in a backwards-compatible manner
- VersionMinor = 2
+ VersionMinor = 3
// VersionPatch is for backwards-compatible bug fixes
- VersionPatch = 1
+ VersionPatch = 0
// VersionDev indicates development branch. Releases will be empty string.
VersionDev = ""
diff --git a/vendor/github.com/openshift/api/.ci-operator.yaml b/vendor/github.com/openshift/api/.ci-operator.yaml
index a3628cf240..1d88a59fdf 100644
--- a/vendor/github.com/openshift/api/.ci-operator.yaml
+++ b/vendor/github.com/openshift/api/.ci-operator.yaml
@@ -1,4 +1,4 @@
build_root_image:
name: release
namespace: openshift
- tag: rhel-9-release-golang-1.25-openshift-4.22
+ tag: rhel-9-release-golang-1.26-openshift-5.0
diff --git a/vendor/github.com/openshift/api/.golangci.yaml b/vendor/github.com/openshift/api/.golangci.yaml
index 608fb0ed2e..e4e5b97612 100644
--- a/vendor/github.com/openshift/api/.golangci.yaml
+++ b/vendor/github.com/openshift/api/.golangci.yaml
@@ -106,11 +106,21 @@ linters:
# This regex must always be updated in tandem with the regex in .golangci.go-validated.yaml that prevents `optionalfields` from being applied to the files in the path.
path: machine/v1beta1/(types_awsprovider.go|types_azureprovider.go|types_gcpprovider.go|types_vsphereprovider.go)|machine/v1alpha1/types_openstack.go
text: "optionalfields"
+ - linters:
+ - kubeapilinter
+ # osin/v1 types are config file APIs, not CRDs — validation is handled in Go code at config load time.
+ path: osin/v1/types.go
- linters:
- kubeapilinter
# Silence norefs lint for `Ref` field in ClusterAPI as it refers to an OCI image reference, not a kube object reference.
path: operator/v1alpha1/types_clusterapi.go
text: "noreferences: naming convention \"no-references\": field ClusterAPIInstallerComponentImage.Ref: field names should not contain reference-related words"
+ - linters:
+ - kubeapilinter
+ # PacemakerCluster intentionally marks Conditions as required with XValidation rules
+ # to enforce specific condition types are always present.
+ path: etcd/v1/types_pacemakercluster.go
+ text: "conditions: Conditions field in (PacemakerClusterStatus|PacemakerClusterNodeStatus|PacemakerClusterFencingAgentStatus|PacemakerClusterResourceStatus) is missing the following markers: optional"
- linters:
- kubeapilinter
path: features|payload-command/*.go
diff --git a/vendor/github.com/openshift/api/Dockerfile.ocp b/vendor/github.com/openshift/api/Dockerfile.ocp
index e04ec9fbc1..98870518c2 100644
--- a/vendor/github.com/openshift/api/Dockerfile.ocp
+++ b/vendor/github.com/openshift/api/Dockerfile.ocp
@@ -1,10 +1,10 @@
-FROM registry.ci.openshift.org/ocp/builder:rhel-9-golang-1.25-openshift-4.22 AS builder
+FROM registry.ci.openshift.org/ocp/builder:rhel-9-golang-1.26-openshift-5.0 AS builder
WORKDIR /go/src/github.com/openshift/api
COPY . .
ENV GO_PACKAGE github.com/openshift/api
RUN make build --warn-undefined-variables
-FROM registry.ci.openshift.org/ocp/4.22:base-rhel9
+FROM registry.ci.openshift.org/ocp/5.0:base-rhel9
# copy the built binaries to /usr/bin
COPY --from=builder /go/src/github.com/openshift/api/render /usr/bin/
diff --git a/vendor/github.com/openshift/api/Makefile b/vendor/github.com/openshift/api/Makefile
index 9b32b58e43..b6c0de378c 100644
--- a/vendor/github.com/openshift/api/Makefile
+++ b/vendor/github.com/openshift/api/Makefile
@@ -4,7 +4,7 @@ all: build
update: update-non-codegen update-codegen
RUNTIME ?= podman
-RUNTIME_IMAGE_NAME ?= registry.ci.openshift.org/openshift/release:rhel-9-release-golang-1.24-openshift-4.20
+RUNTIME_IMAGE_NAME ?= registry.ci.openshift.org/openshift/release:rhel-9-release-golang-1.26-openshift-5.0
EXCLUDE_DIRS := _output/ dependencymagnet/ hack/ third_party/ tls/ tools/ vendor/ tests/
GO_PACKAGES :=$(addsuffix ...,$(addprefix ./,$(filter-out $(EXCLUDE_DIRS), $(wildcard */))))
@@ -179,6 +179,27 @@ generate-with-container:
integration:
make -C tests integration
+# Run API review evals. Requires claude CLI.
+# EVAL_RUNS=5 Number of runs per test case (default: 1)
+# EVAL_THRESHOLD=0.8 Minimum pass rate (default: 0.8)
+# EVAL_GOLDEN_MODEL=... Model for golden tests (default: sonnet)
+# EVAL_INTEGRATION_MODEL=... Model for integration tests (default: opus)
+# EVAL_JUDGE_MODEL=... Model for judging results (default: haiku)
+# EVAL_GOLDEN_PROCS=4 Max parallel golden tests (default: 4)
+# EVAL_INTEGRATION_PROCS=2 Max parallel integration tests (default: 2)
+# EVAL_GINKGO_ARGS=... Extra ginkgo args
+.PHONY: eval
+eval:
+ $(MAKE) -C tests eval
+
+.PHONY: eval-golden
+eval-golden:
+ $(MAKE) -C tests eval-golden
+
+.PHONY: eval-integration
+eval-integration:
+ $(MAKE) -C tests eval-integration
+
tests-vendor:
make -C tests vendor
@@ -199,7 +220,7 @@ write-available-featuresets:
.PHONY: clean
clean:
- rm -f render write-available-featuresets models-schema
+ rm -f render write-available-featuresets
rm -rf tools/_output
VERSION ?= $(shell git describe --always --abbrev=7)
diff --git a/vendor/github.com/openshift/api/apiextensions/v1alpha1/doc.go b/vendor/github.com/openshift/api/apiextensions/v1alpha1/doc.go
index e5d665fbbc..ff9b7416ac 100644
--- a/vendor/github.com/openshift/api/apiextensions/v1alpha1/doc.go
+++ b/vendor/github.com/openshift/api/apiextensions/v1alpha1/doc.go
@@ -1,6 +1,7 @@
// +k8s:deepcopy-gen=package,register
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.apiextensions.v1alpha1
// +openshift:featuregated-schema-gen=true
// +groupName=apiextensions.openshift.io
diff --git a/vendor/github.com/openshift/api/apiextensions/v1alpha1/zz_generated.model_name.go b/vendor/github.com/openshift/api/apiextensions/v1alpha1/zz_generated.model_name.go
new file mode 100644
index 0000000000..1f0482e4f8
--- /dev/null
+++ b/vendor/github.com/openshift/api/apiextensions/v1alpha1/zz_generated.model_name.go
@@ -0,0 +1,61 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1alpha1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in APIExcludedField) OpenAPIModelName() string {
+ return "com.github.openshift.api.apiextensions.v1alpha1.APIExcludedField"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in APIVersions) OpenAPIModelName() string {
+ return "com.github.openshift.api.apiextensions.v1alpha1.APIVersions"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CRDData) OpenAPIModelName() string {
+ return "com.github.openshift.api.apiextensions.v1alpha1.CRDData"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CompatibilityRequirement) OpenAPIModelName() string {
+ return "com.github.openshift.api.apiextensions.v1alpha1.CompatibilityRequirement"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CompatibilityRequirementList) OpenAPIModelName() string {
+ return "com.github.openshift.api.apiextensions.v1alpha1.CompatibilityRequirementList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CompatibilityRequirementSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.apiextensions.v1alpha1.CompatibilityRequirementSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CompatibilityRequirementStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.apiextensions.v1alpha1.CompatibilityRequirementStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CompatibilitySchema) OpenAPIModelName() string {
+ return "com.github.openshift.api.apiextensions.v1alpha1.CompatibilitySchema"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CustomResourceDefinitionSchemaValidation) OpenAPIModelName() string {
+ return "com.github.openshift.api.apiextensions.v1alpha1.CustomResourceDefinitionSchemaValidation"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ObjectSchemaValidation) OpenAPIModelName() string {
+ return "com.github.openshift.api.apiextensions.v1alpha1.ObjectSchemaValidation"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ObservedCRD) OpenAPIModelName() string {
+ return "com.github.openshift.api.apiextensions.v1alpha1.ObservedCRD"
+}
diff --git a/vendor/github.com/openshift/api/apiserver/v1/doc.go b/vendor/github.com/openshift/api/apiserver/v1/doc.go
index cc6a8aa617..598fd6e754 100644
--- a/vendor/github.com/openshift/api/apiserver/v1/doc.go
+++ b/vendor/github.com/openshift/api/apiserver/v1/doc.go
@@ -1,6 +1,7 @@
// +k8s:deepcopy-gen=package,register
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.apiserver.v1
// +kubebuilder:validation:Optional
// +groupName=apiserver.openshift.io
diff --git a/vendor/github.com/openshift/api/apiserver/v1/zz_generated.model_name.go b/vendor/github.com/openshift/api/apiserver/v1/zz_generated.model_name.go
new file mode 100644
index 0000000000..69b62d04fb
--- /dev/null
+++ b/vendor/github.com/openshift/api/apiserver/v1/zz_generated.model_name.go
@@ -0,0 +1,46 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in APIRequestCount) OpenAPIModelName() string {
+ return "com.github.openshift.api.apiserver.v1.APIRequestCount"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in APIRequestCountList) OpenAPIModelName() string {
+ return "com.github.openshift.api.apiserver.v1.APIRequestCountList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in APIRequestCountSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.apiserver.v1.APIRequestCountSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in APIRequestCountStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.apiserver.v1.APIRequestCountStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PerNodeAPIRequestLog) OpenAPIModelName() string {
+ return "com.github.openshift.api.apiserver.v1.PerNodeAPIRequestLog"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PerResourceAPIRequestLog) OpenAPIModelName() string {
+ return "com.github.openshift.api.apiserver.v1.PerResourceAPIRequestLog"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PerUserAPIRequestCount) OpenAPIModelName() string {
+ return "com.github.openshift.api.apiserver.v1.PerUserAPIRequestCount"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PerVerbAPIRequestCount) OpenAPIModelName() string {
+ return "com.github.openshift.api.apiserver.v1.PerVerbAPIRequestCount"
+}
diff --git a/vendor/github.com/openshift/api/apps/.codegen.yaml b/vendor/github.com/openshift/api/apps/.codegen.yaml
new file mode 100644
index 0000000000..f7a37129a0
--- /dev/null
+++ b/vendor/github.com/openshift/api/apps/.codegen.yaml
@@ -0,0 +1,2 @@
+protobuf:
+ disabled: false
diff --git a/vendor/github.com/openshift/api/apps/v1/doc.go b/vendor/github.com/openshift/api/apps/v1/doc.go
index f0fb3f59a2..9ba23002df 100644
--- a/vendor/github.com/openshift/api/apps/v1/doc.go
+++ b/vendor/github.com/openshift/api/apps/v1/doc.go
@@ -2,6 +2,7 @@
// +k8s:conversion-gen=github.com/openshift/origin/pkg/apps/apis/apps
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.apps.v1
// +k8s:prerelease-lifecycle-gen=true
// +groupName=apps.openshift.io
diff --git a/vendor/github.com/openshift/api/apps/v1/zz_generated.model_name.go b/vendor/github.com/openshift/api/apps/v1/zz_generated.model_name.go
new file mode 100644
index 0000000000..3eea1fc875
--- /dev/null
+++ b/vendor/github.com/openshift/api/apps/v1/zz_generated.model_name.go
@@ -0,0 +1,116 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CustomDeploymentStrategyParams) OpenAPIModelName() string {
+ return "com.github.openshift.api.apps.v1.CustomDeploymentStrategyParams"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DeploymentCause) OpenAPIModelName() string {
+ return "com.github.openshift.api.apps.v1.DeploymentCause"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DeploymentCauseImageTrigger) OpenAPIModelName() string {
+ return "com.github.openshift.api.apps.v1.DeploymentCauseImageTrigger"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DeploymentCondition) OpenAPIModelName() string {
+ return "com.github.openshift.api.apps.v1.DeploymentCondition"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DeploymentConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.apps.v1.DeploymentConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DeploymentConfigList) OpenAPIModelName() string {
+ return "com.github.openshift.api.apps.v1.DeploymentConfigList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DeploymentConfigRollback) OpenAPIModelName() string {
+ return "com.github.openshift.api.apps.v1.DeploymentConfigRollback"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DeploymentConfigRollbackSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.apps.v1.DeploymentConfigRollbackSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DeploymentConfigSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.apps.v1.DeploymentConfigSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DeploymentConfigStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.apps.v1.DeploymentConfigStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DeploymentDetails) OpenAPIModelName() string {
+ return "com.github.openshift.api.apps.v1.DeploymentDetails"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DeploymentLog) OpenAPIModelName() string {
+ return "com.github.openshift.api.apps.v1.DeploymentLog"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DeploymentLogOptions) OpenAPIModelName() string {
+ return "com.github.openshift.api.apps.v1.DeploymentLogOptions"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DeploymentRequest) OpenAPIModelName() string {
+ return "com.github.openshift.api.apps.v1.DeploymentRequest"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DeploymentStrategy) OpenAPIModelName() string {
+ return "com.github.openshift.api.apps.v1.DeploymentStrategy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DeploymentTriggerImageChangeParams) OpenAPIModelName() string {
+ return "com.github.openshift.api.apps.v1.DeploymentTriggerImageChangeParams"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DeploymentTriggerPolicy) OpenAPIModelName() string {
+ return "com.github.openshift.api.apps.v1.DeploymentTriggerPolicy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ExecNewPodHook) OpenAPIModelName() string {
+ return "com.github.openshift.api.apps.v1.ExecNewPodHook"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in LifecycleHook) OpenAPIModelName() string {
+ return "com.github.openshift.api.apps.v1.LifecycleHook"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RecreateDeploymentStrategyParams) OpenAPIModelName() string {
+ return "com.github.openshift.api.apps.v1.RecreateDeploymentStrategyParams"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RollingDeploymentStrategyParams) OpenAPIModelName() string {
+ return "com.github.openshift.api.apps.v1.RollingDeploymentStrategyParams"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TagImageHook) OpenAPIModelName() string {
+ return "com.github.openshift.api.apps.v1.TagImageHook"
+}
diff --git a/vendor/github.com/openshift/api/authorization/.codegen.yaml b/vendor/github.com/openshift/api/authorization/.codegen.yaml
new file mode 100644
index 0000000000..f7a37129a0
--- /dev/null
+++ b/vendor/github.com/openshift/api/authorization/.codegen.yaml
@@ -0,0 +1,2 @@
+protobuf:
+ disabled: false
diff --git a/vendor/github.com/openshift/api/authorization/v1/doc.go b/vendor/github.com/openshift/api/authorization/v1/doc.go
index a66741dce6..8b4e927d63 100644
--- a/vendor/github.com/openshift/api/authorization/v1/doc.go
+++ b/vendor/github.com/openshift/api/authorization/v1/doc.go
@@ -2,6 +2,7 @@
// +k8s:conversion-gen=github.com/openshift/origin/pkg/authorization/apis/authorization
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.authorization.v1
// +kubebuilder:validation:Optional
// +groupName=authorization.openshift.io
diff --git a/vendor/github.com/openshift/api/authorization/v1/zz_generated.model_name.go b/vendor/github.com/openshift/api/authorization/v1/zz_generated.model_name.go
new file mode 100644
index 0000000000..47987773bf
--- /dev/null
+++ b/vendor/github.com/openshift/api/authorization/v1/zz_generated.model_name.go
@@ -0,0 +1,171 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Action) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.Action"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterRole) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.ClusterRole"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterRoleBinding) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.ClusterRoleBinding"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterRoleBindingList) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.ClusterRoleBindingList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterRoleList) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.ClusterRoleList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GroupRestriction) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.GroupRestriction"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IsPersonalSubjectAccessReview) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.IsPersonalSubjectAccessReview"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in LocalResourceAccessReview) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.LocalResourceAccessReview"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in LocalSubjectAccessReview) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.LocalSubjectAccessReview"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NamedClusterRole) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.NamedClusterRole"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NamedClusterRoleBinding) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.NamedClusterRoleBinding"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NamedRole) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.NamedRole"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NamedRoleBinding) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.NamedRoleBinding"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PolicyRule) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.PolicyRule"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ResourceAccessReview) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.ResourceAccessReview"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ResourceAccessReviewResponse) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.ResourceAccessReviewResponse"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Role) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.Role"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RoleBinding) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.RoleBinding"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RoleBindingList) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.RoleBindingList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RoleBindingRestriction) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.RoleBindingRestriction"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RoleBindingRestrictionList) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.RoleBindingRestrictionList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RoleBindingRestrictionSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.RoleBindingRestrictionSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RoleList) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.RoleList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SelfSubjectRulesReview) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.SelfSubjectRulesReview"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SelfSubjectRulesReviewSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.SelfSubjectRulesReviewSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ServiceAccountReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.ServiceAccountReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ServiceAccountRestriction) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.ServiceAccountRestriction"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SubjectAccessReview) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.SubjectAccessReview"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SubjectAccessReviewResponse) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.SubjectAccessReviewResponse"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SubjectRulesReview) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.SubjectRulesReview"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SubjectRulesReviewSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.SubjectRulesReviewSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SubjectRulesReviewStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.SubjectRulesReviewStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in UserRestriction) OpenAPIModelName() string {
+ return "com.github.openshift.api.authorization.v1.UserRestriction"
+}
diff --git a/vendor/github.com/openshift/api/build/.codegen.yaml b/vendor/github.com/openshift/api/build/.codegen.yaml
new file mode 100644
index 0000000000..f7a37129a0
--- /dev/null
+++ b/vendor/github.com/openshift/api/build/.codegen.yaml
@@ -0,0 +1,2 @@
+protobuf:
+ disabled: false
diff --git a/vendor/github.com/openshift/api/build/v1/doc.go b/vendor/github.com/openshift/api/build/v1/doc.go
index 9bc16f64b2..6fe1839e9a 100644
--- a/vendor/github.com/openshift/api/build/v1/doc.go
+++ b/vendor/github.com/openshift/api/build/v1/doc.go
@@ -2,6 +2,7 @@
// +k8s:conversion-gen=github.com/openshift/origin/pkg/build/apis/build
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.build.v1
// +groupName=build.openshift.io
// Package v1 is the v1 version of the API.
diff --git a/vendor/github.com/openshift/api/build/v1/zz_generated.model_name.go b/vendor/github.com/openshift/api/build/v1/zz_generated.model_name.go
new file mode 100644
index 0000000000..dd144e3aff
--- /dev/null
+++ b/vendor/github.com/openshift/api/build/v1/zz_generated.model_name.go
@@ -0,0 +1,301 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BinaryBuildRequestOptions) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.BinaryBuildRequestOptions"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BinaryBuildSource) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.BinaryBuildSource"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BitbucketWebHookCause) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.BitbucketWebHookCause"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Build) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.Build"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildCondition) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.BuildCondition"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.BuildConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildConfigList) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.BuildConfigList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildConfigSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.BuildConfigSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildConfigStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.BuildConfigStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildList) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.BuildList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildLog) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.BuildLog"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildLogOptions) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.BuildLogOptions"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildOutput) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.BuildOutput"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildPostCommitSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.BuildPostCommitSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildRequest) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.BuildRequest"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildSource) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.BuildSource"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.BuildSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.BuildStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildStatusOutput) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.BuildStatusOutput"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildStatusOutputTo) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.BuildStatusOutputTo"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildStrategy) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.BuildStrategy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildTriggerCause) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.BuildTriggerCause"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildTriggerPolicy) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.BuildTriggerPolicy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildVolume) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.BuildVolume"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildVolumeMount) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.BuildVolumeMount"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildVolumeSource) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.BuildVolumeSource"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CommonSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.CommonSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CommonWebHookCause) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.CommonWebHookCause"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConfigMapBuildSource) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.ConfigMapBuildSource"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CustomBuildStrategy) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.CustomBuildStrategy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DockerBuildStrategy) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.DockerBuildStrategy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DockerStrategyOptions) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.DockerStrategyOptions"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GenericWebHookCause) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.GenericWebHookCause"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GenericWebHookEvent) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.GenericWebHookEvent"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GitBuildSource) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.GitBuildSource"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GitHubWebHookCause) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.GitHubWebHookCause"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GitInfo) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.GitInfo"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GitLabWebHookCause) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.GitLabWebHookCause"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GitRefInfo) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.GitRefInfo"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GitSourceRevision) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.GitSourceRevision"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageChangeCause) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.ImageChangeCause"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageChangeTrigger) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.ImageChangeTrigger"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageChangeTriggerStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.ImageChangeTriggerStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageLabel) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.ImageLabel"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageSource) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.ImageSource"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageSourcePath) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.ImageSourcePath"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageStreamTagReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.ImageStreamTagReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in JenkinsPipelineBuildStrategy) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.JenkinsPipelineBuildStrategy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ProxyConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.ProxyConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SecretBuildSource) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.SecretBuildSource"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SecretLocalReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.SecretLocalReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SecretSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.SecretSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SourceBuildStrategy) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.SourceBuildStrategy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SourceControlUser) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.SourceControlUser"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SourceRevision) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.SourceRevision"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SourceStrategyOptions) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.SourceStrategyOptions"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in StageInfo) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.StageInfo"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in StepInfo) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.StepInfo"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in WebHookTrigger) OpenAPIModelName() string {
+ return "com.github.openshift.api.build.v1.WebHookTrigger"
+}
diff --git a/vendor/github.com/openshift/api/cloudnetwork/.codegen.yaml b/vendor/github.com/openshift/api/cloudnetwork/.codegen.yaml
index e69de29bb2..f7a37129a0 100644
--- a/vendor/github.com/openshift/api/cloudnetwork/.codegen.yaml
+++ b/vendor/github.com/openshift/api/cloudnetwork/.codegen.yaml
@@ -0,0 +1,2 @@
+protobuf:
+ disabled: false
diff --git a/vendor/github.com/openshift/api/cloudnetwork/v1/doc.go b/vendor/github.com/openshift/api/cloudnetwork/v1/doc.go
index 1d495ee24c..006a1705b6 100644
--- a/vendor/github.com/openshift/api/cloudnetwork/v1/doc.go
+++ b/vendor/github.com/openshift/api/cloudnetwork/v1/doc.go
@@ -1,5 +1,6 @@
// Package v1 contains API Schema definitions for the cloud network v1 API group
// +k8s:deepcopy-gen=package,register
+// +k8s:openapi-model-package=com.github.openshift.api.cloudnetwork.v1
// +groupName=cloud.network.openshift.io
// +kubebuilder:validation:Optional
package v1
diff --git a/vendor/github.com/openshift/api/cloudnetwork/v1/zz_generated.model_name.go b/vendor/github.com/openshift/api/cloudnetwork/v1/zz_generated.model_name.go
new file mode 100644
index 0000000000..5409883975
--- /dev/null
+++ b/vendor/github.com/openshift/api/cloudnetwork/v1/zz_generated.model_name.go
@@ -0,0 +1,26 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CloudPrivateIPConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.cloudnetwork.v1.CloudPrivateIPConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CloudPrivateIPConfigList) OpenAPIModelName() string {
+ return "com.github.openshift.api.cloudnetwork.v1.CloudPrivateIPConfigList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CloudPrivateIPConfigSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.cloudnetwork.v1.CloudPrivateIPConfigSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CloudPrivateIPConfigStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.cloudnetwork.v1.CloudPrivateIPConfigStatus"
+}
diff --git a/vendor/github.com/openshift/api/config/v1/doc.go b/vendor/github.com/openshift/api/config/v1/doc.go
index f994547583..867a4f43f9 100644
--- a/vendor/github.com/openshift/api/config/v1/doc.go
+++ b/vendor/github.com/openshift/api/config/v1/doc.go
@@ -1,6 +1,7 @@
// +k8s:deepcopy-gen=package,register
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.config.v1
// +openshift:featuregated-schema-gen=true
// +kubebuilder:validation:Optional
diff --git a/vendor/github.com/openshift/api/config/v1/register.go b/vendor/github.com/openshift/api/config/v1/register.go
index 222c7f0cc7..1f27d821ab 100644
--- a/vendor/github.com/openshift/api/config/v1/register.go
+++ b/vendor/github.com/openshift/api/config/v1/register.go
@@ -78,6 +78,8 @@ func addKnownTypes(scheme *runtime.Scheme) error {
&ClusterImagePolicyList{},
&InsightsDataGather{},
&InsightsDataGatherList{},
+ &CRIOCredentialProviderConfig{},
+ &CRIOCredentialProviderConfigList{},
)
metav1.AddToGroupVersion(scheme, GroupVersion)
return nil
diff --git a/vendor/github.com/openshift/api/config/v1/types.go b/vendor/github.com/openshift/api/config/v1/types.go
index 3e17ca0ccb..e7106ef7ab 100644
--- a/vendor/github.com/openshift/api/config/v1/types.go
+++ b/vendor/github.com/openshift/api/config/v1/types.go
@@ -284,7 +284,12 @@ type ClientConnectionOverrides struct {
}
// GenericControllerConfig provides information to configure a controller
+//
+// Compatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer).
+// +openshift:compatibility-gen:level=1
type GenericControllerConfig struct {
+ metav1.TypeMeta `json:",inline"`
+
// servingInfo is the HTTP serving information for the controller's endpoints
ServingInfo HTTPServingInfo `json:"servingInfo"`
diff --git a/vendor/github.com/openshift/api/config/v1/types_apiserver.go b/vendor/github.com/openshift/api/config/v1/types_apiserver.go
index 31d8881858..7de714ebfb 100644
--- a/vendor/github.com/openshift/api/config/v1/types_apiserver.go
+++ b/vendor/github.com/openshift/api/config/v1/types_apiserver.go
@@ -34,6 +34,7 @@ type APIServer struct {
Status APIServerStatus `json:"status"`
}
+// +openshift:validation:FeatureGateAwareXValidation:featureGate=TLSAdherence,rule="has(oldSelf.tlsAdherence) ? has(self.tlsAdherence) : true",message="tlsAdherence may not be removed once set"
type APIServerSpec struct {
// servingCert is the TLS cert info for serving secure traffic. If not specified, operator managed certificates
// will be used for serving secure traffic.
@@ -62,6 +63,39 @@ type APIServerSpec struct {
// The current default is the Intermediate profile.
// +optional
TLSSecurityProfile *TLSSecurityProfile `json:"tlsSecurityProfile,omitempty"`
+ // tlsAdherence controls if components in the cluster adhere to the TLS security profile
+ // configured on this APIServer resource.
+ //
+ // Valid values are "LegacyAdheringComponentsOnly" and "StrictAllComponents".
+ //
+ // When set to "LegacyAdheringComponentsOnly", components that already honor the
+ // cluster-wide TLS profile continue to do so. Components that do not already honor
+ // it continue to use their individual TLS configurations.
+ //
+ // When set to "StrictAllComponents", all components must honor the configured TLS
+ // profile unless they have a component-specific TLS configuration that overrides
+ // it. This mode is recommended for security-conscious deployments and is required
+ // for certain compliance frameworks.
+ //
+ // Note: Some components such as Kubelet and IngressController have their own
+ // dedicated TLS configuration mechanisms via KubeletConfig and IngressController
+ // CRs respectively. When these component-specific TLS configurations are set,
+ // they take precedence over the cluster-wide tlsSecurityProfile. When not set,
+ // these components fall back to the cluster-wide default.
+ //
+ // Components that encounter an unknown value for tlsAdherence should treat it
+ // as "StrictAllComponents" and log a warning to ensure forward compatibility
+ // while defaulting to the more secure behavior.
+ //
+ // This field is optional.
+ // When omitted, this means the user has no opinion and the platform is left
+ // to choose reasonable defaults. These defaults are subject to change over time.
+ // The current default is LegacyAdheringComponentsOnly.
+ //
+ // Once set, this field may be changed to a different value, but may not be removed.
+ // +openshift:enable:FeatureGate=TLSAdherence
+ // +optional
+ TLSAdherence TLSAdherencePolicy `json:"tlsAdherence,omitempty"`
// audit specifies the settings for audit configuration to be applied to all OpenShift-provided
// API servers in the cluster.
// +optional
@@ -175,7 +209,7 @@ type APIServerNamedServingCert struct {
}
// APIServerEncryption is used to encrypt sensitive resources on the cluster.
-// +openshift:validation:FeatureGateAwareXValidation:featureGate=KMSEncryptionProvider,rule="has(self.type) && self.type == 'KMS' ? has(self.kms) : !has(self.kms)",message="kms config is required when encryption type is KMS, and forbidden otherwise"
+// +openshift:validation:FeatureGateAwareXValidation:featureGate=KMSEncryption,rule="has(self.type) && self.type == 'KMS' ? has(self.kms) : !has(self.kms)",message="kms config is required when encryption type is KMS, and forbidden otherwise"
// +union
type APIServerEncryption struct {
// type defines what encryption type should be used to encrypt resources at the datastore layer.
@@ -204,14 +238,13 @@ type APIServerEncryption struct {
// managing the lifecyle of the encryption keys outside of the control plane.
// This allows integration with an external provider to manage the data encryption keys securely.
//
- // +openshift:enable:FeatureGate=KMSEncryptionProvider
+ // +openshift:enable:FeatureGate=KMSEncryption
// +unionMember
// +optional
- KMS *KMSConfig `json:"kms,omitempty"`
+ KMS KMSPluginConfig `json:"kms,omitempty,omitzero"`
}
// +openshift:validation:FeatureGateAwareEnum:featureGate="",enum="";identity;aescbc;aesgcm
-// +openshift:validation:FeatureGateAwareEnum:featureGate=KMSEncryptionProvider,enum="";identity;aescbc;aesgcm;KMS
// +openshift:validation:FeatureGateAwareEnum:featureGate=KMSEncryption,enum="";identity;aescbc;aesgcm;KMS
type EncryptionType string
@@ -237,6 +270,35 @@ const (
type APIServerStatus struct {
}
+// TLSAdherencePolicy defines which components adhere to the TLS security profile.
+// Implementors should use the ShouldHonorClusterTLSProfile helper function from library-go
+// rather than checking these values directly.
+// +kubebuilder:validation:Enum=LegacyAdheringComponentsOnly;StrictAllComponents
+type TLSAdherencePolicy string
+
+const (
+ // TLSAdherencePolicyNoOpinion represents an empty/unset value for tlsAdherence.
+ // This value cannot be explicitly set and is only present when the field is omitted.
+ // When the field is omitted, the cluster defaults to LegacyAdheringComponentsOnly
+ // behavior. Components should treat this the same as LegacyAdheringComponentsOnly.
+ TLSAdherencePolicyNoOpinion TLSAdherencePolicy = ""
+
+ // TLSAdherencePolicyLegacyAdheringComponentsOnly maintains backward-compatible behavior.
+ // Components that already honor the cluster-wide TLS profile (such as kube-apiserver,
+ // openshift-apiserver, oauth-apiserver, and others) continue to do so. Components that do
+ // not already honor it continue to use their individual TLS configurations (e.g.,
+ // IngressController.spec.tlsSecurityProfile, KubeletConfig.spec.tlsSecurityProfile,
+ // or component defaults). No additional components are required to start honoring the
+ // cluster-wide profile in this mode.
+ TLSAdherencePolicyLegacyAdheringComponentsOnly TLSAdherencePolicy = "LegacyAdheringComponentsOnly"
+
+ // TLSAdherencePolicyStrictAllComponents means all components must honor the configured TLS
+ // profile unless they have a component-specific TLS configuration that overrides it.
+ // This mode is recommended for security-conscious deployments and is required
+ // for certain compliance frameworks.
+ TLSAdherencePolicyStrictAllComponents TLSAdherencePolicy = "StrictAllComponents"
+)
+
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
// Compatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer).
diff --git a/vendor/github.com/openshift/api/config/v1/types_authentication.go b/vendor/github.com/openshift/api/config/v1/types_authentication.go
index 64d0f399b0..ab591284d9 100644
--- a/vendor/github.com/openshift/api/config/v1/types_authentication.go
+++ b/vendor/github.com/openshift/api/config/v1/types_authentication.go
@@ -5,7 +5,7 @@ import metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
// +genclient
// +genclient:nonNamespaced
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
-// +openshift:validation:FeatureGateAwareXValidation:featureGate=ExternalOIDC;ExternalOIDCWithUIDAndExtraClaimMappings;ExternalOIDCWithUpstreamParity,rule="!has(self.spec.oidcProviders) || self.spec.oidcProviders.all(p, !has(p.oidcClients) || p.oidcClients.all(specC, self.status.oidcClients.exists(statusC, statusC.componentNamespace == specC.componentNamespace && statusC.componentName == specC.componentName) || (has(oldSelf.spec.oidcProviders) && oldSelf.spec.oidcProviders.exists(oldP, oldP.name == p.name && has(oldP.oidcClients) && oldP.oidcClients.exists(oldC, oldC.componentNamespace == specC.componentNamespace && oldC.componentName == specC.componentName)))))",message="all oidcClients in the oidcProviders must match their componentName and componentNamespace to either a previously configured oidcClient or they must exist in the status.oidcClients"
+// +openshift:validation:FeatureGateAwareXValidation:featureGate=ExternalOIDC;ExternalOIDCWithUIDAndExtraClaimMappings;ExternalOIDCWithUpstreamParity;ExternalOIDCExternalClaimsSourcing,rule="!has(self.spec.oidcProviders) || self.spec.oidcProviders.all(p, !has(p.oidcClients) || p.oidcClients.all(specC, self.status.oidcClients.exists(statusC, statusC.componentNamespace == specC.componentNamespace && statusC.componentName == specC.componentName) || (has(oldSelf.spec.oidcProviders) && oldSelf.spec.oidcProviders.exists(oldP, oldP.name == p.name && has(oldP.oidcClients) && oldP.oidcClients.exists(oldC, oldC.componentNamespace == specC.componentNamespace && oldC.componentName == specC.componentName)))))",message="all oidcClients in the oidcProviders must match their componentName and componentNamespace to either a previously configured oidcClient or they must exist in the status.oidcClients"
// Authentication specifies cluster-wide settings for authentication (like OAuth and
// webhook token authenticators). The canonical name of an instance is `cluster`.
@@ -91,6 +91,7 @@ type AuthenticationSpec struct {
// +openshift:enable:FeatureGate=ExternalOIDC
// +openshift:enable:FeatureGate=ExternalOIDCWithUIDAndExtraClaimMappings
// +openshift:enable:FeatureGate=ExternalOIDCWithUpstreamParity
+ // +openshift:enable:FeatureGate=ExternalOIDCExternalClaimsSourcing
// +optional
OIDCProviders []OIDCProvider `json:"oidcProviders,omitempty"`
}
@@ -245,6 +246,36 @@ type OIDCProvider struct {
// +optional
// +openshift:enable:FeatureGate=ExternalOIDCWithUpstreamParity
UserValidationRules []TokenUserValidationRule `json:"userValidationRules,omitempty"`
+
+ // externalClaimsSources is an optional field that can be used to configure
+ // sources, external to the token provided in a request, in which claims
+ // should be fetched from and made available to the claim mapping process
+ // that is used to build the identity of a token holder.
+ //
+ // For example, fetching additional user metadata from an OIDC provider's UserInfo endpoint.
+ //
+ // When not specified, only claims present in the token itself will be available
+ // in the claim mapping process.
+ //
+ // When specified, at least one external claim source must be specified and no more than 5
+ // sources may be specified.
+ // All external claim sources must have unique claim mappings.
+ // When an external source responds and resolves additional claims successfully, they will
+ // be made available as claims during the claim mapping process.
+ // Externally sourced claims with the same name as a claim existing within the token will
+ // overwrite the claim data from the token with the externally sourced information.
+ // If an external source does not respond, responds with an error, or the additional
+ // claim data cannot be resolved from the response successfully it will not be
+ // included in the claim data passed to the claim mapping process.
+ //
+ // +openshift:enable:FeatureGate=ExternalOIDCExternalClaimsSourcing
+ //
+ // +optional
+ // +kubebuilder:validation:MinItems=1
+ // +kubebuilder:validation:MaxItems=5
+ // +kubebuilder:validation:XValidation:rule="self.all(s, s.mappings.all(m, self.filter(s2, s2.mappings.exists(m2, m2.name == m.name)).size() == 1))",message="mapping names must be unique across all external claim sources."
+ // +listType=atomic
+ ExternalClaimsSources []ExternalClaimsSource `json:"externalClaimsSources,omitempty"`
}
// +kubebuilder:validation:MinLength=1
@@ -618,6 +649,7 @@ type OIDCClientReference struct {
// +openshift:validation:FeatureGateAwareXValidation:featureGate=ExternalOIDC,rule="has(self.claim)",message="claim is required"
// +openshift:validation:FeatureGateAwareXValidation:featureGate=ExternalOIDCWithUIDAndExtraClaimMappings,rule="has(self.claim)",message="claim is required"
// +openshift:validation:FeatureGateAwareXValidation:featureGate=ExternalOIDCWithUpstreamParity,rule="has(self.claim) ? !has(self.expression) : has(self.expression)",message="precisely one of claim or expression must be set"
+// +openshift:validation:FeatureGateAwareXValidation:featureGate=ExternalOIDCWithUpstreamParity,rule="has(self.expression) && size(self.expression) > 0 ? !has(self.prefixPolicy) || self.prefixPolicy != 'Prefix' : true",message="prefixPolicy must not be set to 'Prefix' when expression is set"
type UsernameClaimMapping struct {
// claim is an optional field that configures the JWT token claim whose value is assigned to the cluster identity field associated with this mapping.
// claim is required when the ExternalOIDCWithUpstreamParity feature gate is not enabled.
@@ -650,11 +682,9 @@ type UsernameClaimMapping struct {
// Allowed values are 'Prefix', 'NoPrefix', and omitted (not provided or an empty string).
//
// When set to 'Prefix', the value specified in the prefix field will be prepended to the value of the JWT claim.
- //
// The prefix field must be set when prefixPolicy is 'Prefix'.
- //
+ // Must not be set to 'Prefix' when expression is set.
// When set to 'NoPrefix', no prefix will be prepended to the value of the JWT claim.
- //
// When omitted, this means no opinion and the platform is left to choose any prefixes that are applied which is subject to change over time.
// Currently, the platform prepends `{issuerURL}#` to the value of the JWT claim when the claim is not 'email'.
//
@@ -684,7 +714,7 @@ type UsernameClaimMapping struct {
// +enum
type UsernamePrefixPolicy string
-var (
+const (
// NoOpinion let's the cluster assign prefixes. If the username claim is email, there is no prefix
// If the username claim is anything else, it is prefixed by the issuerURL
NoOpinion UsernamePrefixPolicy = ""
@@ -710,12 +740,14 @@ type UsernamePrefix struct {
// PrefixedClaimMapping configures a claim mapping
// that allows for an optional prefix.
+// +openshift:validation:FeatureGateAwareXValidation:featureGate=ExternalOIDCWithUpstreamParity,rule="has(self.expression) && size(self.expression) > 0 ? (!has(self.prefix) || size(self.prefix) == 0) : true",message="prefix must not be set to a non-empty value when expression is set"
type PrefixedClaimMapping struct {
TokenClaimMapping `json:",inline"`
// prefix is an optional field that configures the prefix that will be applied to the cluster identity attribute during the process of mapping JWT claims to cluster identity attributes.
//
- // When omitted (""), no prefix is applied to the cluster identity attribute.
+ // When omitted or set to an empty string (""), no prefix is applied to the cluster identity attribute.
+ // Must not be set to a non-empty value when expression is set.
//
// Example: if `prefix` is set to "myoidc:" and the `claim` in JWT contains an array of strings "a", "b" and "c", the mapping will result in an array of string "myoidc:a", "myoidc:b" and "myoidc:c".
//
@@ -734,10 +766,10 @@ type TokenValidationRuleType string
const (
// TokenValidationRuleTypeRequiredClaim indicates that the token must contain a specific claim.
// Used as a value for TokenValidationRuleType.
- TokenValidationRuleTypeRequiredClaim = "RequiredClaim"
+ TokenValidationRuleTypeRequiredClaim TokenValidationRuleType = "RequiredClaim"
// TokenValidationRuleTypeCEL indicates that the token validation is defined via a CEL expression.
// Used as a value for TokenValidationRuleType.
- TokenValidationRuleTypeCEL = "CEL"
+ TokenValidationRuleTypeCEL TokenValidationRuleType = "CEL"
)
// TokenClaimValidationRule represents a validation rule based on token claims.
@@ -830,3 +862,355 @@ type TokenUserValidationRule struct {
// +kubebuilder:validation:MaxLength=256
Message string `json:"message,omitempty"`
}
+
+// ExternalClaimsSource provides the configuration for a single external claim source.
+type ExternalClaimsSource struct {
+ // authentication is an optional field that configures how the apiserver authenticates with an external claims source.
+ // When not specified, anonymous authentication is used which means no 'Authorization' header
+ // is sent in the HTTP request to fetch the external claims.
+ //
+ // +optional
+ Authentication ExternalSourceAuthentication `json:"authentication,omitzero"`
+
+ // tls is an optional field that configures the http client TLS
+ // settings when fetching external claims from this source.
+ //
+ // When omitted, system default TLS settings will be used
+ // for fetching claims from the external source.
+ //
+ // +optional
+ TLS ExternalSourceTLS `json:"tls,omitzero"`
+
+ // url is a required configuration of the URL
+ // for which the external claims are located.
+ //
+ // +required
+ URL SourceURL `json:"url,omitzero"`
+
+ // mappings is a required list of the claim
+ // and response handling expression pairs
+ // that produces the claims from the external source.
+ // mappings must have at least 1 entry and must not exceed 16 entries.
+ // Entries must have a unique name across all external claim sources.
+ //
+ // +required
+ // +listType=map
+ // +listMapKey=name
+ // +kubebuilder:validation:MinItems=1
+ // +kubebuilder:validation:MaxItems=16
+ Mappings []SourcedClaimMapping `json:"mappings,omitempty"`
+
+ // predicates is an optional list of constraints in
+ // which claims should attempt to be fetched from this
+ // external source.
+ //
+ // When omitted, claims are always fetched
+ // from this external source.
+ //
+ // When specified, all predicates must evaluate to 'true'
+ // before claims are attempted to be fetched from this external source.
+ // predicates must have at least 1 entry and must not exceed 16 entries.
+ // Entries must have unique expressions.
+ //
+ // +optional
+ // +listType=map
+ // +listMapKey=expression
+ // +kubebuilder:validation:MinItems=1
+ // +kubebuilder:validation:MaxItems=16
+ Predicates []ExternalSourcePredicate `json:"predicates,omitempty"`
+}
+
+// ExternalSourceAuthenticationType is the type of authentication that should be used
+// when fetching claims from an external source.
+//
+// +enum
+// +kubebuilder:validation:Enum=RequestProvidedToken;ClientCredential
+type ExternalSourceAuthenticationType string
+
+const (
+ // ExternalSourceAuthenticationTypeRequestProvidedToken is an ExternalSourceAuthenticationType
+ // that represents that the token being evaluated for authentication
+ // should be used for authenticating with the external claims source.
+ // This is useful for scenarios where a token has multiple audiences
+ // and scopes so that it can be used to access both the cluster and
+ // the UserInfo endpoint that contains additional information about the
+ // user not present in the token.
+ ExternalSourceAuthenticationTypeRequestProvidedToken ExternalSourceAuthenticationType = "RequestProvidedToken"
+
+ // ExternalSourceAuthenticationTypeClientCredential is an ExternalSourceAuthenticationType
+ // that represents that the authenticator should use the OAuth2
+ // client credentials grant flow to obtain an access token for
+ // authenticating with the external claims source.
+ // This is useful for scenarios such as fetching user information
+ // from Microsoft's Graph API where a separate client credential
+ // is needed to access the API.
+ ExternalSourceAuthenticationTypeClientCredential ExternalSourceAuthenticationType = "ClientCredential"
+)
+
+// ExternalSourceAuthentication configures how the apiserver should attempt
+// to authenticate with an external claims source.
+//
+// +kubebuilder:validation:XValidation:rule="self.type == 'ClientCredential' ? has(self.clientCredential) : !has(self.clientCredential)",message="clientCredential is required when type is ClientCredential, and forbidden otherwise"
+type ExternalSourceAuthentication struct {
+ // type is a required field that sets the type of
+ // authentication method used by the authenticator
+ // when fetching external claims.
+ //
+ // Allowed values are 'RequestProvidedToken' and 'ClientCredential'.
+ //
+ // When set to 'RequestProvidedToken', the authenticator will
+ // use the token provided to the kube-apiserver as part of the
+ // request to authenticate with the external claims source.
+ //
+ // When set to 'ClientCredential', the authenticator will
+ // use the configured client-id, client-secret, and token endpoint
+ // to fetch an access token using the OAuth2 client credentials grant
+ // flow. The fetched access token will then be used to authenticate
+ // with the external claims source.
+ //
+ // +required
+ Type ExternalSourceAuthenticationType `json:"type,omitempty"`
+
+ // clientCredential configures the client credentials
+ // and token endpoint to use to get an access token.
+ // clientCredential is required when type is 'ClientCredential', and forbidden otherwise.
+ //
+ // +optional
+ ClientCredential ClientCredentialConfig `json:"clientCredential,omitzero"`
+}
+
+// ExternalSourceTLS configures the TLS options that the apiserver uses as a client
+// when making a request to the external claim source.
+type ExternalSourceTLS struct {
+ // certificateAuthority is a required reference to a ConfigMap in the openshift-config
+ // namespace that contains the CA certificate to use to validate TLS connections with the external claims source.
+ // The key "ca-bundle.crt" must be present in the referenced ConfigMap and must contain the CA certificate to be used
+ // to verify the external source's TLS certificate.
+ //
+ // +required
+ CertificateAuthority ExternalSourceCertificateAuthorityConfigMapReference `json:"certificateAuthority,omitzero"`
+}
+
+// ClientCredentialConfig configures the client credentials and token endpoint
+// to use to get an access token via the OAuth2 client credentials grant flow.
+type ClientCredentialConfig struct {
+ // clientID is a required client identifier to use during the OAuth2 client credentials flow.
+ // clientID must be at least 1 character in length, must not exceed 256 characters in length,
+ // and must only contain printable ASCII characters.
+ //
+ // +required
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=256
+ // +kubebuilder:validation:XValidation:rule="self.matches('^[[:print:]]+$')",message="clientID must only contain printable ASCII characters"
+ ClientID string `json:"clientID,omitempty"`
+
+ // clientSecret is a required reference to a Secret in the openshift-config namespace to be used
+ // as the client secret during the OAuth2 client credentials flow.
+ //
+ // The key 'client-secret' is used to locate the client secret data in the Secret.
+ //
+ // +required
+ ClientSecret ClientSecretSecretReference `json:"clientSecret,omitzero"`
+
+ // tokenEndpoint is a required URL to query for an access token using
+ // the client credential OAuth2 flow.
+ // tokenEndpoint must be at least 1 character in length and must not exceed 2048 characters in length.
+ // tokenEndpoint must be a valid HTTPS URL.
+ // tokenEndpoint must have a host and a path.
+ // tokenEndpoint must not contain query parameters, fragments,
+ // or user information (e.g., "user:password@host").
+ //
+ // +required
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=2048
+ // +kubebuilder:validation:XValidation:rule="isURL(self)",message="tokenEndpoint must be a valid HTTPS url"
+ // +kubebuilder:validation:XValidation:rule="isURL(self) && url(self).getScheme() == 'https'",message="tokenEndpoint must be a valid HTTPS url"
+ // +kubebuilder:validation:XValidation:rule="isURL(self) && url(self).getHost() != ''",message="tokenEndpoint must have a hostname"
+ // +kubebuilder:validation:XValidation:rule="isURL(self) && url(self).getEscapedPath() != ''",message="tokenEndpoint must have a path"
+ // +kubebuilder:validation:XValidation:rule="isURL(self) && url(self).getQuery() == {}",message="tokenEndpoint must not have query parameters"
+ // +kubebuilder:validation:XValidation:rule="isURL(self) && self.find('#(.+)$') == ''",message="tokenEndpoint must not have a fragment"
+ // +kubebuilder:validation:XValidation:rule="isURL(self) && !self.matches('^https://[^/]+@.+$')",message="tokenEndpoint must not have user info"
+ TokenEndpoint string `json:"tokenEndpoint,omitempty"`
+
+ // scopes is an optional list of OAuth2 scopes to request when obtaining
+ // an access token.
+ //
+ // If not specified, the token endpoint's default scopes
+ // will be used.
+ //
+ // When specified, there must be at least 1 entry and must not exceed 16 entries.
+ // Each entry must be at least 1 character in length and must not exceed 256 characters in length.
+ // Each entry must only contain printable ASCII characters, excluding spaces, double quotes and backslashes.
+ // Entries must be unique.
+ //
+ // +optional
+ // +kubebuilder:validation:MinItems=1
+ // +kubebuilder:validation:MaxItems=16
+ // +listType=set
+ Scopes []OAuth2Scope `json:"scopes,omitempty"`
+
+ // tls is an optional field that allows configuring the TLS
+ // settings used to interact with the identity provider
+ // as an OAuth2 client.
+ //
+ // When omitted, system default TLS settings will be used
+ // for the OAuth2 client.
+ //
+ // +optional
+ TLS ExternalSourceTLS `json:"tls,omitzero"`
+}
+
+// OAuth2Scope is a string alias that represents an OAuth2 Scope as defined by https://datatracker.ietf.org/doc/html/rfc6749#appendix-A.4
+// Must be at least 1 character in length, must not exceed 256 characters in length and must only contain printable ASCII characters, excluding spaces, double quotes and backslashes.
+//
+// +kubebuilder:validation:XValidation:rule="self.matches('^[!#-[\\\\]-~]+$')",message="scopes must only contain printable ASCII characters excluding spaces, double quotes and backslashes"
+// +kubebuilder:validation:MinLength=1
+// +kubebuilder:validation:MaxLength=256
+type OAuth2Scope string
+
+// SourceURL configures the options used to build the URL that is queried for external claims.
+type SourceURL struct {
+ // hostname is a required hostname for which the external claims are located.
+ //
+ // It must be a valid DNS subdomain name as per RFC1123.
+ //
+ // This means that it must start and end with a lowercase alphanumeric character,
+ // must only consist of lowercase alphanumeric characters, '-', and '.'.
+ // hostname may optionally specify a port in the format ':{port}'.
+ // If a port is specified it must not exceed 65535.
+ //
+ // hostname must be at least 1 character in length.
+ // When specifying a port, hostname must not exceed 259 characters in length.
+ // When not specifying a port, hostname must not exceed 253 characters in length.
+ //
+ // +required
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=259
+ // +kubebuilder:validation:XValidation:rule="isURL('https://'+self)",message="hostname must be a valid hostname"
+ // +kubebuilder:validation:XValidation:rule="self.split(':')[0].matches('^[a-z0-9]([a-z0-9-]*[a-z0-9])?(\\\\.[a-z0-9]([a-z0-9-]*[a-z0-9])?)*$')",message="hostname before port must start and end with a lowercase alphanumeric character, and must only contain lowercase alphanumeric characters, '-' or '.'"
+ // +kubebuilder:validation:XValidation:rule="self.split(':').size() > 1 ? int(self.split(':')[1]) <= 65535 : true",message="port must not exceed 65535"
+ Hostname string `json:"hostname,omitempty"`
+
+ // pathExpression is a required CEL expression that returns a list
+ // of string values used to construct the URL path.
+ // Claims from the token used for the request to the kube-apiserver
+ // are made available via the `claims` variable.
+ // expression must be at least 1 character in length and must not exceed 1024 characters in length.
+ //
+ // Values in the returned list will be joined with the hostname using a forward slash
+ // (`/`) as a separator. Values in the returned list do not need to include the forward slash.
+ // If a forward slash is included in a returned value, it will be encoded as `%2F`.
+ //
+ // Example of a static path configuration:
+ //
+ // pathExpression: ['realms', 'k8s', 'protocol', 'openid-connect', 'userinfo']
+ //
+ // The above example would resolve to the path: '/realms/k8s/protocol/openid-connect/userinfo'
+ //
+ // Example of a dynamic path configuration:
+ //
+ // pathExpression: "['admin', 'realms', 'k8s', 'users'] + [claims.sub] + ['groups']"
+ //
+ // Assuming 'claims.sub' is set to '12345', the above example would resolve to the path: '/admin/realms/k8s/users/12345/groups'
+ //
+ // +required
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=1024
+ PathExpression string `json:"pathExpression,omitempty"`
+}
+
+// SourcedClaimMapping configures the mapping behavior for a single external claim
+// from the response the apiserver received from the external claim source.
+type SourcedClaimMapping struct {
+ // name is a required name of the claim that
+ // will be produced and made available during
+ // the claim-to-identity mapping process.
+ // name must consist of only lowercase alpha characters and underscores ('_').
+ // name must be at least 1 character and must not exceed 256 characters in length.
+ //
+ // +required
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=256
+ // +kubebuilder:validation:XValidation:rule="self.matches('^[a-z_]+$')",message="name must consist of only lowercase alpha characters and underscores"
+ Name string `json:"name,omitempty"`
+
+ // expression is a required CEL expression that
+ // will produce a value to be assigned to the claim.
+ // The full response body from the request to the
+ // external claim source is provided via the
+ // `response.body` variable.
+ //
+ // The contents of the `response.body` variable varies based on the response received
+ // from the external source. It is the responsibility of those configuring
+ // this expression to understand what is returned from the external source.
+ //
+ // expression must be at least 1 character and must not exceed 1024 characters in length.
+ //
+ // +required
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=1024
+ Expression string `json:"expression,omitempty"`
+}
+
+// ExternalSourcePredicate configures a singular condition
+// that must return true before the external source is queried
+// to retrieve external claims.
+type ExternalSourcePredicate struct {
+ // expression is a required CEL expression that
+ // is used to determine whether or not an external
+ // source should be used to fetch external claims.
+ //
+ // The expression must return a boolean value,
+ // where true means that the source should be consulted
+ // and false means that it should not.
+ //
+ // Claims from the token used for the request to the kube-apiserver
+ // are made available via the `claims` variable.
+ //
+ // The contents of the `claims` variable varies based on the claims that are
+ // present in the token being validated. It is the responsibility of those configuring this
+ // field to understand what claims the identity provider includes when issuing tokens.
+ //
+ // expression must be at least 1 character and must not exceed 1024 characters in length.
+ //
+ // +required
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=1024
+ Expression string `json:"expression,omitempty"`
+}
+
+// ExternalSourceCertificateAuthorityConfigMapReference is a reference to a ConfigMap in the openshift-config
+// namespace that should be used for configuring the certificate authority to be
+// used when sourcing claims from external sources.
+type ExternalSourceCertificateAuthorityConfigMapReference struct {
+ // name is the required name of the ConfigMap that exists in the openshift-config namespace.
+ // The key "ca-bundle.crt" must be present and must contain the CA certificate to be used
+ // to verify the external source's TLS certificate.
+ //
+ // It must be at least 1 character in length, must not exceed 253 characters in length,
+ // must start and end with a lowercase alphanumeric character, and must only contain
+ // lowercase alphanumeric characters, '-' or '.'.
+ //
+ // +required
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=253
+ // +kubebuilder:validation:XValidation:rule="self.matches('^[a-z0-9]([a-z0-9-]*[a-z0-9])?(\\\\.[a-z0-9]([a-z0-9-]*[a-z0-9])?)*$')",message="name must start and end with a lowercase alphanumeric character, and must only contain lowercase alphanumeric characters, '-' or '.'"
+ Name string `json:"name,omitempty"`
+}
+
+// ClientSecretSecretReference is a reference to a Secret in the openshift-config
+// namespace that should be used for configuring the client secret to be
+// used when sourcing claims from external sources with the client credential authentication flow.
+type ClientSecretSecretReference struct {
+ // name is the required name of the Secret that exists in the openshift-config namespace.
+ //
+ // It must be at least 1 character in length, must not exceed 253 characters in length,
+ // must start and end with a lowercase alphanumeric character, and must only contain
+ // lowercase alphanumeric characters, '-' or '.'.
+ //
+ // +required
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=253
+ // +kubebuilder:validation:XValidation:rule="self.matches('^[a-z0-9]([a-z0-9-]*[a-z0-9])?(\\\\.[a-z0-9]([a-z0-9-]*[a-z0-9])?)*$')",message="name must start and end with a lowercase alphanumeric character, and must only contain lowercase alphanumeric characters, '-' or '.'"
+ Name string `json:"name,omitempty"`
+}
diff --git a/vendor/github.com/openshift/api/config/v1/types_cluster_operator.go b/vendor/github.com/openshift/api/config/v1/types_cluster_operator.go
index 8323040389..e934e83550 100644
--- a/vendor/github.com/openshift/api/config/v1/types_cluster_operator.go
+++ b/vendor/github.com/openshift/api/config/v1/types_cluster_operator.go
@@ -160,8 +160,9 @@ const (
// is actively rolling out new code, propagating config changes (e.g, a version change), or otherwise
// moving from one steady state to another. Operators should not report
// Progressing when they are reconciling (without action) a previously known
- // state. Operators should not report Progressing only because DaemonSets owned by them
- // are adjusting to a new node from cluster scaleup or a node rebooting from cluster upgrade.
+ // state. Operators should not report Progressing only because resources owned by them,
+ // such as DaemonSets and Deployments, are adjusting to a new node from cluster scaleup
+ // or a node rebooting from cluster upgrade.
// If the observed cluster state has changed and the component is
// reacting to it (updated proxy configuration for instance), Progressing should become true
// since it is moving from one steady state to another.
diff --git a/vendor/github.com/openshift/api/config/v1/types_cluster_version.go b/vendor/github.com/openshift/api/config/v1/types_cluster_version.go
index 5f36f693de..9cb85f4c00 100644
--- a/vendor/github.com/openshift/api/config/v1/types_cluster_version.go
+++ b/vendor/github.com/openshift/api/config/v1/types_cluster_version.go
@@ -18,7 +18,8 @@ import (
// +kubebuilder:object:root=true
// +kubebuilder:subresource:status
// +kubebuilder:resource:path=clusterversions,scope=Cluster
-// +kubebuilder:validation:XValidation:rule="has(self.spec.capabilities) && has(self.spec.capabilities.additionalEnabledCapabilities) && self.spec.capabilities.baselineCapabilitySet == 'None' && 'marketplace' in self.spec.capabilities.additionalEnabledCapabilities ? 'OperatorLifecycleManager' in self.spec.capabilities.additionalEnabledCapabilities || (has(self.status) && has(self.status.capabilities) && has(self.status.capabilities.enabledCapabilities) && 'OperatorLifecycleManager' in self.status.capabilities.enabledCapabilities) : true",message="the `marketplace` capability requires the `OperatorLifecycleManager` capability, which is neither explicitly or implicitly enabled in this cluster, please enable the `OperatorLifecycleManager` capability"
+// +openshift:validation:FeatureGateAwareXValidation:featureGate="";CRDCompatibilityRequirementOperator;ClusterAPIMachineManagement,rule="has(self.spec.capabilities) && has(self.spec.capabilities.additionalEnabledCapabilities) && self.spec.capabilities.baselineCapabilitySet == 'None' && 'marketplace' in self.spec.capabilities.additionalEnabledCapabilities ? 'OperatorLifecycleManager' in self.spec.capabilities.additionalEnabledCapabilities || (has(self.status) && has(self.status.capabilities) && has(self.status.capabilities.enabledCapabilities) && 'OperatorLifecycleManager' in self.status.capabilities.enabledCapabilities) : true",message="the `marketplace` capability requires the `OperatorLifecycleManager` capability, which is neither explicitly or implicitly enabled in this cluster, please enable the `OperatorLifecycleManager` capability"
+// +openshift:validation:FeatureGateAwareXValidation:requiredFeatureGate=CRDCompatibilityRequirementOperator;ClusterAPIMachineManagement,rule="has(self.spec.capabilities) && has(self.spec.capabilities.additionalEnabledCapabilities) && 'ClusterAPI' in self.spec.capabilities.additionalEnabledCapabilities ? 'CompatibilityRequirements' in self.spec.capabilities.additionalEnabledCapabilities || (has(self.status) && has(self.status.capabilities) && has(self.status.capabilities.enabledCapabilities) && 'CompatibilityRequirements' in self.status.capabilities.enabledCapabilities) : true",message="the `ClusterAPI` capability requires the `CompatibilityRequirements` capability, which is neither explicitly or implicitly enabled in this cluster, please enable the `CompatibilityRequirements` capability"
// +kubebuilder:printcolumn:name=Version,JSONPath=.status.history[?(@.state=="Completed")].version,type=string
// +kubebuilder:printcolumn:name=Available,JSONPath=.status.conditions[?(@.type=="Available")].status,type=string
// +kubebuilder:printcolumn:name=Progressing,JSONPath=.status.conditions[?(@.type=="Progressing")].status,type=string
@@ -283,6 +284,16 @@ type UpdateHistory struct {
// ClusterID is string RFC4122 uuid.
type ClusterID string
+// UpdateMode defines how an update should be processed.
+// +enum
+// +kubebuilder:validation:Enum=Preflight
+type UpdateMode string
+
+const (
+ // UpdateModePreflight allows an update to be checked for compatibility without committing to updating the cluster.
+ UpdateModePreflight UpdateMode = "Preflight"
+)
+
// ClusterVersionArchitecture enumerates valid cluster architectures.
// +kubebuilder:validation:Enum="Multi";""
type ClusterVersionArchitecture string
@@ -294,7 +305,10 @@ const (
)
// ClusterVersionCapability enumerates optional, core cluster components.
-// +kubebuilder:validation:Enum=openshift-samples;baremetal;marketplace;Console;Insights;Storage;CSISnapshot;NodeTuning;MachineAPI;Build;DeploymentConfig;ImageRegistry;OperatorLifecycleManager;CloudCredential;Ingress;CloudControllerManager;OperatorLifecycleManagerV1
+// +openshift:validation:FeatureGateAwareEnum:featureGate="",enum=openshift-samples;baremetal;marketplace;Console;Insights;Storage;CSISnapshot;NodeTuning;MachineAPI;Build;DeploymentConfig;ImageRegistry;OperatorLifecycleManager;CloudCredential;Ingress;CloudControllerManager;OperatorLifecycleManagerV1
+// +openshift:validation:FeatureGateAwareEnum:featureGate=CRDCompatibilityRequirementOperator,enum=openshift-samples;baremetal;marketplace;Console;Insights;Storage;CSISnapshot;NodeTuning;MachineAPI;Build;DeploymentConfig;ImageRegistry;OperatorLifecycleManager;CloudCredential;Ingress;CloudControllerManager;OperatorLifecycleManagerV1;CompatibilityRequirements
+// +openshift:validation:FeatureGateAwareEnum:featureGate=ClusterAPIMachineManagement,enum=openshift-samples;baremetal;marketplace;Console;Insights;Storage;CSISnapshot;NodeTuning;MachineAPI;Build;DeploymentConfig;ImageRegistry;OperatorLifecycleManager;CloudCredential;Ingress;CloudControllerManager;OperatorLifecycleManagerV1;CompatibilityRequirements;ClusterAPI
+// +openshift:validation:FeatureGateAwareEnum:requiredFeatureGate=CRDCompatibilityRequirementOperator;ClusterAPIMachineManagement,enum=openshift-samples;baremetal;marketplace;Console;Insights;Storage;CSISnapshot;NodeTuning;MachineAPI;Build;DeploymentConfig;ImageRegistry;OperatorLifecycleManager;CloudCredential;Ingress;CloudControllerManager;OperatorLifecycleManagerV1;CompatibilityRequirements;ClusterAPI
type ClusterVersionCapability string
const (
@@ -415,6 +429,19 @@ const (
// Managers deployed on top of OpenShift. They help you to work with cloud
// provider API and embeds cloud-specific control logic.
ClusterVersionCapabilityCloudControllerManager ClusterVersionCapability = "CloudControllerManager"
+
+ // ClusterVersionCapabilityCompatibilityRequirements manages the Compatibility
+ // Requirements operator which enforces CRD compatibility constraints via
+ // validating webhooks.
+ ClusterVersionCapabilityCompatibilityRequirements ClusterVersionCapability = "CompatibilityRequirements"
+
+ // ClusterVersionCapabilityClusterAPI manages the Cluster API operator and
+ // controllers which provide forward-compatible machine management for
+ // OpenShift clusters.
+ //
+ // Note that Cluster API has a hard requirement on CompatibilityRequirements.
+ // CompatibilityRequirements cannot be disabled while Cluster API is enabled.
+ ClusterVersionCapabilityClusterAPI ClusterVersionCapability = "ClusterAPI"
)
// KnownClusterVersionCapabilities includes all known optional, core cluster components.
@@ -436,6 +463,8 @@ var KnownClusterVersionCapabilities = []ClusterVersionCapability{
ClusterVersionCapabilityCloudCredential,
ClusterVersionCapabilityIngress,
ClusterVersionCapabilityCloudControllerManager,
+ ClusterVersionCapabilityCompatibilityRequirements,
+ ClusterVersionCapabilityClusterAPI,
}
// ClusterVersionCapabilitySet defines sets of cluster version capabilities.
@@ -634,6 +663,8 @@ var ClusterVersionCapabilitySets = map[ClusterVersionCapabilitySet][]ClusterVers
ClusterVersionCapabilityCloudCredential,
ClusterVersionCapabilityIngress,
ClusterVersionCapabilityCloudControllerManager,
+ ClusterVersionCapabilityCompatibilityRequirements,
+ ClusterVersionCapabilityClusterAPI,
},
}
@@ -760,6 +791,22 @@ type Update struct {
// +listMapKey=name
// +optional
AcceptRisks []AcceptRisk `json:"acceptRisks,omitempty"`
+
+ // mode determines how an update should be processed.
+ // The only valid value is "Preflight".
+ // When omitted, the cluster performs a normal update by applying the specified version or image to the cluster.
+ // This is the standard update behavior.
+ // When set to "Preflight", the cluster runs compatibility checks against the target release without
+ // performing an actual update. Compatibility results, including any detected risks, are reported
+ // in status.conditionalUpdates and status.conditionalUpdateRisks alongside risks from the update
+ // recommendation service.
+ // This allows administrators to assess update readiness and address issues before committing to the update.
+ // Preflight mode is particularly useful for skip-level updates where upgrade compatibility needs to be
+ // verified across multiple minor versions.
+ // When mode is set to "Preflight", the same rules for version, image, and architecture apply as for normal updates.
+ // +openshift:enable:FeatureGate=ClusterUpdatePreflight
+ // +optional
+ Mode UpdateMode `json:"mode,omitempty"`
}
// AcceptRisk represents a risk that is considered acceptable.
diff --git a/vendor/github.com/openshift/api/config/v1/types_crio_credential_provider_config.go b/vendor/github.com/openshift/api/config/v1/types_crio_credential_provider_config.go
new file mode 100644
index 0000000000..3fe543aac8
--- /dev/null
+++ b/vendor/github.com/openshift/api/config/v1/types_crio_credential_provider_config.go
@@ -0,0 +1,186 @@
+package v1
+
+import metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
+
+// +genclient
+// +genclient:nonNamespaced
+// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
+
+// CRIOCredentialProviderConfig holds cluster-wide singleton resource configurations for CRI-O credential provider, the name of this instance is "cluster". CRI-O credential provider is a binary shipped with CRI-O that provides a way to obtain container image pull credentials from external sources.
+// For example, it can be used to fetch mirror registry credentials from secrets resources in the cluster within the same namespace the pod will be running in.
+// CRIOCredentialProviderConfig configuration specifies the pod image sources registries that should trigger the CRI-O credential provider execution, which will resolve the CRI-O mirror configurations and obtain the necessary credentials for pod creation.
+// Note: Configuration changes will only take effect after the kubelet restarts, which is automatically managed by the cluster during rollout.
+//
+// The resource is a singleton named "cluster".
+//
+// Compatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer).
+// +kubebuilder:object:root=true
+// +kubebuilder:resource:path=criocredentialproviderconfigs,scope=Cluster
+// +kubebuilder:subresource:status
+// +openshift:api-approved.openshift.io=https://github.com/openshift/api/pull/2725
+// +openshift:file-pattern=cvoRunLevel=0000_10,operatorName=config-operator,operatorOrdering=01
+// +openshift:enable:FeatureGate=CRIOCredentialProviderConfig
+// +openshift:compatibility-gen:level=1
+// +kubebuilder:validation:XValidation:rule="self.metadata.name == 'cluster'",message="criocredentialproviderconfig is a singleton, .metadata.name must be 'cluster'"
+type CRIOCredentialProviderConfig struct {
+ metav1.TypeMeta `json:",inline"`
+
+ // metadata is the standard object's metadata.
+ // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
+ // +optional
+ metav1.ObjectMeta `json:"metadata,omitzero"`
+
+ // spec defines the desired configuration of the CRI-O Credential Provider.
+ // This field is required and must be provided when creating the resource.
+ // +required
+ Spec *CRIOCredentialProviderConfigSpec `json:"spec,omitempty,omitzero"`
+
+ // status represents the current state of the CRIOCredentialProviderConfig.
+ // When omitted or nil, it indicates that the status has not yet been set by the controller.
+ // The controller will populate this field with validation conditions and operational state.
+ // +optional
+ Status CRIOCredentialProviderConfigStatus `json:"status,omitzero,omitempty"`
+}
+
+// CRIOCredentialProviderConfigSpec defines the desired configuration of the CRI-O Credential Provider.
+// +kubebuilder:validation:MinProperties=0
+type CRIOCredentialProviderConfigSpec struct {
+ // matchImages is a list of string patterns used to determine whether
+ // the CRI-O credential provider should be invoked for a given image. This list is
+ // passed to the kubelet CredentialProviderConfig, and if any pattern matches
+ // the requested image, CRI-O credential provider will be invoked to obtain credentials for pulling
+ // that image or its mirrors.
+ // Depending on the platform, the CRI-O credential provider may be installed alongside an existing platform specific provider.
+ // Conflicts between the existing platform specific provider image match configuration and this list will be handled by
+ // the following precedence rule: credentials from built-in kubelet providers (e.g., ECR, GCR, ACR) take precedence over those
+ // from the CRIOCredentialProviderConfig when both match the same image.
+ // To avoid uncertainty, it is recommended to avoid configuring your private image patterns to overlap with
+ // existing platform specific provider config(e.g., the entries from https://github.com/openshift/machine-config-operator/blob/main/templates/common/aws/files/etc-kubernetes-credential-providers-ecr-credential-provider.yaml).
+ // You can check the resource's Status conditions
+ // to see if any entries were ignored due to exact matches with known built-in provider patterns.
+ //
+ // This field is optional, the items of the list must contain between 1 and 50 entries.
+ // The list is treated as a set, so duplicate entries are not allowed.
+ //
+ // For more details, see:
+ // https://kubernetes.io/docs/tasks/administer-cluster/kubelet-credential-provider/
+ // https://github.com/cri-o/crio-credential-provider#architecture
+ //
+ // Each entry in matchImages is a pattern which can optionally contain a port and a path. Each entry must be no longer than 512 characters.
+ // Wildcards ('*') are supported for full subdomain labels, such as '*.k8s.io' or 'k8s.*.io',
+ // and for top-level domains, such as 'k8s.*' (which matches 'k8s.io' or 'k8s.net').
+ // A global wildcard '*' (matching any domain) is not allowed.
+ // Wildcards may replace an entire hostname label (e.g., *.example.com), but they cannot appear within a label (e.g., f*oo.example.com) and are not allowed in the port or path.
+ // For example, 'example.*.com' is valid, but 'exa*mple.*.com' is not.
+ // Each wildcard matches only a single domain label,
+ // so '*.io' does **not** match '*.k8s.io'.
+ //
+ // A match exists between an image and a matchImage when all of the below are true:
+ // Both contain the same number of domain parts and each part matches.
+ // The URL path of an matchImages must be a prefix of the target image URL path.
+ // If the matchImages contains a port, then the port must match in the image as well.
+ //
+ // Example values of matchImages:
+ // - 123456789.dkr.ecr.us-east-1.amazonaws.com
+ // - *.azurecr.io
+ // - gcr.io
+ // - *.*.registry.io
+ // - registry.io:8080/path
+ //
+ // +kubebuilder:validation:MaxItems=50
+ // +kubebuilder:validation:MinItems=1
+ // +listType=set
+ // +optional
+ MatchImages []MatchImage `json:"matchImages,omitempty"`
+}
+
+// MatchImage is a string pattern used to match container image registry addresses.
+// It must be a valid fully qualified domain name with optional wildcard, port, and path.
+// The maximum length is 512 characters.
+//
+// Wildcards ('*') are supported for full subdomain labels and top-level domains.
+// Each entry can optionally contain a port (e.g., :8080) and a path (e.g., /path).
+// Wildcards are not allowed in the port or path portions.
+//
+// Examples:
+// - "registry.io" - matches exactly registry.io
+// - "*.azurecr.io" - matches any single subdomain of azurecr.io
+// - "registry.io:8080/path" - matches with specific port and path prefix
+//
+// +kubebuilder:validation:MaxLength=512
+// +kubebuilder:validation:MinLength=1
+// +kubebuilder:validation:XValidation:rule="self != '*'",message="global wildcard '*' is not allowed"
+// +kubebuilder:validation:XValidation:rule=`self.matches('^((\\*|[a-z0-9]([a-z0-9-]*[a-z0-9])?)(\\.(\\*|[a-z0-9]([a-z0-9-]*[a-z0-9])?))*)(:[0-9]+)?(/[-a-z0-9._/]*)?$')`,message="invalid matchImages value, must be a valid fully qualified domain name in lowercase with optional wildcard, port, and path"
+type MatchImage string
+
+// +k8s:deepcopy-gen=true
+// CRIOCredentialProviderConfigStatus defines the observed state of CRIOCredentialProviderConfig
+// +kubebuilder:validation:MinProperties=1
+type CRIOCredentialProviderConfigStatus struct {
+ // conditions represent the latest available observations of the configuration state.
+ // When omitted, it indicates that no conditions have been reported yet.
+ // The maximum number of conditions is 16.
+ // Conditions are stored as a map keyed by condition type, ensuring uniqueness.
+ //
+ // Expected condition types include:
+ // "Validated": indicates whether the matchImages configuration is valid
+ // +optional
+ // +kubebuilder:validation:MaxItems=16
+ // +kubebuilder:validation:MinItems=1
+ // +listType=map
+ // +listMapKey=type
+ Conditions []metav1.Condition `json:"conditions,omitempty"`
+}
+
+// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
+
+// CRIOCredentialProviderConfigList contains a list of CRIOCredentialProviderConfig resources
+//
+// Compatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer).
+// +openshift:compatibility-gen:level=1
+type CRIOCredentialProviderConfigList struct {
+ metav1.TypeMeta `json:",inline"`
+
+ // metadata is the standard list's metadata.
+ // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
+ metav1.ListMeta `json:"metadata"`
+
+ Items []CRIOCredentialProviderConfig `json:"items"`
+}
+
+const (
+ // ConditionTypeValidated is a condition type that indicates whether the CRIOCredentialProviderConfig
+ // matchImages configuration has been validated successfully.
+ // When True, all matchImage patterns are valid and have been applied.
+ // When False, the configuration contains errors (see Reason for details).
+ // Possible reasons for False status:
+ // - ValidationFailed: matchImages contains invalid patterns
+ // - ConfigurationPartiallyApplied: some matchImage entries were ignored due to conflicts
+ ConditionTypeValidated = "Validated"
+
+ // ReasonValidationFailed is a condition reason used with ConditionTypeValidated=False
+ // to indicate that the matchImages configuration contains one or more invalid registry patterns
+ // that do not conform to the required format (valid FQDN with optional wildcard, port, and path).
+ ReasonValidationFailed = "ValidationFailed"
+
+ // ReasonConfigurationPartiallyApplied is a condition reason used with ConditionTypeValidated=False
+ // to indicate that some matchImage entries were ignored due to conflicts or overlapping patterns.
+ // The condition message will contain details about which entries were ignored and why.
+ ReasonConfigurationPartiallyApplied = "ConfigurationPartiallyApplied"
+
+ // ConditionTypeMachineConfigRendered is a condition type that indicates whether
+ // the CRIOCredentialProviderConfig has been successfully rendered into a
+ // MachineConfig object.
+ // When True, the corresponding MachineConfig is present in the cluster.
+ // When False, rendering failed.
+ ConditionTypeMachineConfigRendered = "MachineConfigRendered"
+
+ // ReasonMachineConfigRenderingSucceeded is a condition reason used with ConditionTypeMachineConfigRendered=True
+ // to indicate that the MachineConfig was successfully created/updated in the API server.
+ ReasonMachineConfigRenderingSucceeded = "MachineConfigRenderingSucceeded"
+
+ // ReasonMachineConfigRenderingFailed is a condition reason used with ConditionTypeMachineConfigRendered=False
+ // to indicate that the MachineConfig creation/update failed.
+ // The condition message will contain details about the failure.
+ ReasonMachineConfigRenderingFailed = "MachineConfigRenderingFailed"
+)
diff --git a/vendor/github.com/openshift/api/config/v1/types_dns.go b/vendor/github.com/openshift/api/config/v1/types_dns.go
index 06eb75ccf7..efbdc3ae54 100644
--- a/vendor/github.com/openshift/api/config/v1/types_dns.go
+++ b/vendor/github.com/openshift/api/config/v1/types_dns.go
@@ -134,7 +134,14 @@ type AWSDNSSpec struct {
// privateZoneIAMRole contains the ARN of an IAM role that should be assumed when performing
// operations on the cluster's private hosted zone specified in the cluster DNS config.
// When left empty, no role should be assumed.
- // +kubebuilder:validation:Pattern:=`^arn:(aws|aws-cn|aws-us-gov):iam::[0-9]{12}:role\/.*$`
+ //
+ // The ARN must follow the format: arn::iam:::role/, where:
+ // is the AWS partition (aws, aws-cn, aws-us-gov, or aws-eusc),
+ // is a 12-digit numeric identifier for the AWS account,
+ // is the IAM role name.
+ //
+ // +openshift:validation:FeatureGateAwareXValidation:featureGate="",rule=`matches(self, '^arn:(aws|aws-cn|aws-us-gov):iam::[0-9]{12}:role/.*$')`,message=`privateZoneIAMRole must be a valid AWS IAM role ARN in the format: arn::iam:::role/`
+ // +openshift:validation:FeatureGateAwareXValidation:featureGate=AWSEuropeanSovereignCloudInstall,rule=`matches(self, '^arn:(aws|aws-cn|aws-us-gov|aws-eusc):iam::[0-9]{12}:role/.*$')`,message=`privateZoneIAMRole must be a valid AWS IAM role ARN in the format: arn::iam:::role/`
// +optional
PrivateZoneIAMRole string `json:"privateZoneIAMRole"`
}
diff --git a/vendor/github.com/openshift/api/config/v1/types_image.go b/vendor/github.com/openshift/api/config/v1/types_image.go
index 82f46c8b6c..96fa349a67 100644
--- a/vendor/github.com/openshift/api/config/v1/types_image.go
+++ b/vendor/github.com/openshift/api/config/v1/types_image.go
@@ -165,20 +165,50 @@ type RegistryLocation struct {
// +kubebuilder:validation:XValidation:rule="has(self.blockedRegistries) ? !has(self.allowedRegistries) : true",message="Only one of blockedRegistries or allowedRegistries may be set"
type RegistrySources struct {
// insecureRegistries are registries which do not have a valid TLS certificates or only support HTTP connections.
+ // Each entry must be a valid registry scope in the format hostname[:port][/path],
+ // optionally prefixed with "*." for wildcard subdomains (e.g., "*.example.com").
+ // The hostname must consist of valid DNS labels separated by dots, where each label
+ // contains only alphanumeric characters and hyphens and does not start or end with a hyphen.
+ // Entries must not be empty, must not include tags (e.g., ":latest") or digests (e.g., "@sha256:..."),
+ // and must be at most 256 characters in length. The list may contain at most 1024 entries.
// +optional
// +listType=atomic
+ // +kubebuilder:validation:MaxItems=1024
+ // +kubebuilder:validation:items:MinLength=1
+ // +kubebuilder:validation:items:MaxLength=256
+ // +kubebuilder:validation:items:XValidation:rule="self.matches('^\\\\*(?:\\\\.(?:[a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9]))+$|^((?:[a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])(?:(?:\\\\.(?:[a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9]))+)?(?::[0-9]+)?)(?:(?:/[a-z0-9]+(?:(?:(?:[._]|__|[-]*)[a-z0-9]+)+)?)+)?$')",message="each registry must be a valid hostname[:port][/path] or wildcard *.hostname format without tags or digests"
InsecureRegistries []string `json:"insecureRegistries,omitempty"`
// blockedRegistries cannot be used for image pull and push actions. All other registries are permitted.
+ // Each entry must be a valid registry scope in the format hostname[:port][/path],
+ // optionally prefixed with "*." for wildcard subdomains (e.g., "*.example.com").
+ // The hostname must consist of valid DNS labels separated by dots, where each label
+ // contains only alphanumeric characters and hyphens and does not start or end with a hyphen.
+ // Entries must not be empty, must not include tags (e.g., ":latest") or digests (e.g., "@sha256:..."),
+ // and must be at most 256 characters in length. The list may contain at most 1024 entries.
//
// Only one of BlockedRegistries or AllowedRegistries may be set.
// +optional
// +listType=atomic
+ // +kubebuilder:validation:MaxItems=1024
+ // +kubebuilder:validation:items:MinLength=1
+ // +kubebuilder:validation:items:MaxLength=256
+ // +kubebuilder:validation:items:XValidation:rule="self.matches('^\\\\*(?:\\\\.(?:[a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9]))+$|^((?:[a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])(?:(?:\\\\.(?:[a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9]))+)?(?::[0-9]+)?)(?:(?:/[a-z0-9]+(?:(?:(?:[._]|__|[-]*)[a-z0-9]+)+)?)+)?$')",message="each registry must be a valid hostname[:port][/path] or wildcard *.hostname format without tags or digests"
BlockedRegistries []string `json:"blockedRegistries,omitempty"`
// allowedRegistries are the only registries permitted for image pull and push actions. All other registries are denied.
+ // Each entry must be a valid registry scope in the format hostname[:port][/path],
+ // optionally prefixed with "*." for wildcard subdomains (e.g., "*.example.com").
+ // The hostname must consist of valid DNS labels separated by dots, where each label
+ // contains only alphanumeric characters and hyphens and does not start or end with a hyphen.
+ // Entries must not be empty, must not include tags (e.g., ":latest") or digests (e.g., "@sha256:..."),
+ // and must be at most 256 characters in length. The list may contain at most 1024 entries.
//
// Only one of BlockedRegistries or AllowedRegistries may be set.
// +optional
// +listType=atomic
+ // +kubebuilder:validation:MaxItems=1024
+ // +kubebuilder:validation:items:MinLength=1
+ // +kubebuilder:validation:items:MaxLength=256
+ // +kubebuilder:validation:items:XValidation:rule="self.matches('^\\\\*(?:\\\\.(?:[a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9]))+$|^((?:[a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])(?:(?:\\\\.(?:[a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9]))+)?(?::[0-9]+)?)(?:(?:/[a-z0-9]+(?:(?:(?:[._]|__|[-]*)[a-z0-9]+)+)?)+)?$')",message="each registry must be a valid hostname[:port][/path] or wildcard *.hostname format without tags or digests"
AllowedRegistries []string `json:"allowedRegistries,omitempty"`
// containerRuntimeSearchRegistries are registries that will be searched when pulling images that do not have fully qualified
// domains in their pull specs. Registries will be searched in the order provided in the list.
diff --git a/vendor/github.com/openshift/api/config/v1/types_infrastructure.go b/vendor/github.com/openshift/api/config/v1/types_infrastructure.go
index 369ba1e7a0..a89377ef7d 100644
--- a/vendor/github.com/openshift/api/config/v1/types_infrastructure.go
+++ b/vendor/github.com/openshift/api/config/v1/types_infrastructure.go
@@ -19,6 +19,7 @@ import (
// +kubebuilder:resource:path=infrastructures,scope=Cluster
// +kubebuilder:subresource:status
// +kubebuilder:metadata:annotations=release.openshift.io/bootstrap-required=true
+// +openshift:validation:FeatureGateAwareXValidation:featureGate=MutableTopology,rule="!has(self.spec.controlPlaneTopology) || (has(oldSelf.spec.controlPlaneTopology) && self.spec.controlPlaneTopology == oldSelf.spec.controlPlaneTopology) || (has(self.status.controlPlaneTopology) && self.spec.controlPlaneTopology == self.status.controlPlaneTopology) || (has(self.status.controlPlaneTopology) && self.status.controlPlaneTopology == 'SingleReplica' && self.spec.controlPlaneTopology == 'HighlyAvailable')",message="spec.controlPlaneTopology must match status.controlPlaneTopology or be set to HighlyAvailable when status.controlPlaneTopology is SingleReplica"
type Infrastructure struct {
metav1.TypeMeta `json:",inline"`
@@ -55,6 +56,21 @@ type InfrastructureSpec struct {
// platformSpec holds desired information specific to the underlying
// infrastructure provider.
PlatformSpec PlatformSpec `json:"platformSpec,omitempty"`
+
+ // controlPlaneTopology expresses the desired topology configuration for control nodes.
+ //
+ // When status.controlPlaneTopology is 'SingleReplica' and spec.controlPlaneTopology is set to 'HighlyAvailable',
+ // a transition will be triggered to reconfigure the cluster from SingleReplica to HighlyAvailable.
+ //
+ // When left blank or status.controlPlaneTopology and spec.controlPlaneTopology are the same value,
+ // no changes are required and no transitions will be triggered.
+ //
+ // This value may be set to match status.controlPlaneTopology regardless of the current value.
+ //
+ // +openshift:enable:FeatureGate=MutableTopology
+ // +kubebuilder:validation:Enum=HighlyAvailable;SingleReplica
+ // +optional
+ ControlPlaneTopology TopologyMode `json:"controlPlaneTopology,omitempty"`
}
// InfrastructureStatus describes the infrastructure the cluster is leveraging.
@@ -102,11 +118,11 @@ type InfrastructureStatus struct {
// and the operators should not configure the operand for highly-available operation
// The 'External' mode indicates that the control plane is hosted externally to the cluster and that
// its components are not visible within the cluster.
+ // The 'HighlyAvailableArbiter' mode indicates that the control plane will consist of 2 control-plane nodes
+ // that run conventional services and 1 smaller sized arbiter node that runs a bare minimum of services to maintain quorum.
// +kubebuilder:default=HighlyAvailable
- // +openshift:validation:FeatureGateAwareEnum:featureGate="",enum=HighlyAvailable;SingleReplica;External
- // +openshift:validation:FeatureGateAwareEnum:featureGate=HighlyAvailableArbiter,enum=HighlyAvailable;HighlyAvailableArbiter;SingleReplica;External
- // +openshift:validation:FeatureGateAwareEnum:featureGate=DualReplica,enum=HighlyAvailable;SingleReplica;DualReplica;External
- // +openshift:validation:FeatureGateAwareEnum:requiredFeatureGate=HighlyAvailableArbiter;DualReplica,enum=HighlyAvailable;HighlyAvailableArbiter;SingleReplica;DualReplica;External
+ // +openshift:validation:FeatureGateAwareEnum:featureGate="",enum=HighlyAvailable;HighlyAvailableArbiter;SingleReplica;External
+ // +openshift:validation:FeatureGateAwareEnum:featureGate=DualReplica,enum=HighlyAvailable;HighlyAvailableArbiter;SingleReplica;DualReplica;External
// +optional
ControlPlaneTopology TopologyMode `json:"controlPlaneTopology"`
@@ -194,6 +210,21 @@ const (
DNSRecordsTypeInternal DNSRecordsType = "Internal"
)
+// VIPManagementType defines which mechanism manages the API and Ingress
+// VIPs on an on-premise cluster.
+// +kubebuilder:validation:Enum=Keepalived;BGP
+// +enum
+type VIPManagementType string
+
+const (
+ // VIPManagementTypeKeepalived means the VIPs are managed by the default
+ // keepalived/VRRP mechanism.
+ VIPManagementTypeKeepalived VIPManagementType = "Keepalived"
+ // VIPManagementTypeBGP means the VIPs are advertised via BGP by kube-vip
+ // (Routing Table Mode) and frr-k8s running as static pods.
+ VIPManagementTypeBGP VIPManagementType = "BGP"
+)
+
// PlatformType is a specific supported infrastructure provider.
// +kubebuilder:validation:Enum="";AWS;Azure;BareMetal;GCP;Libvirt;OpenStack;None;VSphere;oVirt;IBMCloud;KubeVirt;EquinixMetal;PowerVS;AlibabaCloud;Nutanix;External
type PlatformType string
@@ -295,7 +326,8 @@ type ExternalPlatformSpec struct {
// PlatformSpec holds the desired state specific to the underlying infrastructure provider
// of the current cluster. Since these are used at spec-level for the underlying cluster, it
// is supposed that only one of the spec structs is set.
-// +kubebuilder:validation:XValidation:rule="!has(oldSelf.vsphere) && has(self.vsphere) ? size(self.vsphere.vcenters) < 2 : true",message="vcenters can have at most 1 item when configured post-install"
+// +openshift:validation:FeatureGateAwareXValidation:featureGate="",rule="!has(oldSelf.vsphere) && has(self.vsphere) ? (has(self.vsphere.vcenters) && size(self.vsphere.vcenters) < 2) : true",message="vcenters can have at most 1 item when configured post-install"
+// +openshift:validation:FeatureGateAwareXValidation:featureGate=VSphereMultiVCenterDay2,rule="oldSelf.?vsphere.vcenters.hasValue() ? self.?vsphere.vcenters.hasValue() : true",message="vcenters is required once set and cannot be removed"
type PlatformSpec struct {
// type is the underlying infrastructure provider for the cluster. This
// value controls whether infrastructure automation such as service load
@@ -569,6 +601,15 @@ type AWSPlatformStatus struct {
// IPv4-only, or dual-stack networking with IPv4 or IPv6 as the primary
// protocol family.
//
+ // Valid values are:
+ // * "IPv4" (default): Cloud platform resources use IPv4 addressing only.
+ // * "DualStackIPv6Primary": Cloud platform resources use dual-stack networking with IPv6 as the primary protocol family.
+ // * "DualStackIPv4Primary": Cloud platform resources use dual-stack networking with IPv4 as the primary protocol family.
+ //
+ // When omitted, this field defaults to "IPv4".
+ //
+ // This field is immutable and cannot be changed once set.
+ //
// +default="IPv4"
// +kubebuilder:default="IPv4"
// +kubebuilder:validation:XValidation:rule="oldSelf == '' || self == oldSelf",message="ipFamily is immutable once set"
@@ -643,7 +684,6 @@ type AzurePlatformStatus struct {
//
// +default={"dnsType": "PlatformDefault"}
// +kubebuilder:default={"dnsType": "PlatformDefault"}
- // +openshift:enable:FeatureGate=AzureClusterHostedDNSInstall
// +optional
CloudLoadBalancerConfig *CloudLoadBalancerConfig `json:"cloudLoadBalancerConfig,omitempty"`
@@ -787,11 +827,29 @@ type GCPPlatformStatus struct {
//
// +default={"dnsType": "PlatformDefault"}
// +kubebuilder:default={"dnsType": "PlatformDefault"}
- // +openshift:enable:FeatureGate=GCPClusterHostedDNSInstall
// +optional
// +nullable
CloudLoadBalancerConfig *CloudLoadBalancerConfig `json:"cloudLoadBalancerConfig,omitempty"`
+ // universeDomain is the GCP universe domain for the cluster, detected from
+ // the installer credentials. Components with their own GCP credentials should
+ // read the universe domain from those credentials, as they are the authoritative
+ // source. This field is provided for components that do not have GCP credentials
+ // and for general observability.
+ //
+ // When omitted, standard public GCP (googleapis.com) is assumed.
+ //
+ // universeDomain is an optional field that, when specified, must be non-empty and at most
+ // 253 characters. It must be a valid DNS subdomain: containing only lowercase alphanumeric
+ // characters, '-' or '.', and starting and ending with an alphanumeric character.
+ //
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=253
+ // +kubebuilder:validation:XValidation:rule="!format.dns1123Subdomain().validate(self).hasValue()",message="universeDomain must be a valid DNS subdomain: contain no more than 253 characters, contain only lowercase alphanumeric characters, '-' or '.', and start and end with an alphanumeric character"
+ // +optional
+ // +openshift:enable:FeatureGate=GCPSovereignCloudInstall
+ UniverseDomain string `json:"universeDomain,omitempty"`
+
// This field was introduced and removed under tech preview.
// serviceEndpoints specifies endpoints that override the default endpoints
// used when creating clients to interact with GCP services.
@@ -1059,6 +1117,21 @@ type BareMetalPlatformStatus struct {
// +optional
LoadBalancer *BareMetalPlatformLoadBalancer `json:"loadBalancer,omitempty"`
+ // vipManagement indicates which VIP management mechanism is active
+ // on this cluster.
+ // Allowed values are `Keepalived`, `BGP`, and omitted.
+ // Once set to a non-empty value, this field is immutable.
+ // When set to `BGP`, kube-vip (Routing Table Mode) and frr-k8s are
+ // deployed as static pods to advertise VIPs via BGP, replacing the
+ // default keepalived/VRRP mechanism.
+ // When set to `Keepalived`, the default keepalived-based VIP
+ // management is used.
+ // When omitted, the default keepalived-based VIP management is used.
+ // +kubebuilder:validation:XValidation:rule="oldSelf == '' || self == oldSelf",message="vipManagement is immutable once set"
+ // +openshift:enable:FeatureGate=BGPBasedVIPManagement
+ // +optional
+ VIPManagement VIPManagementType `json:"vipManagement,omitempty"`
+
// dnsRecordsType determines whether records for api, api-int, and ingress
// are provided by the internal DNS service or externally.
// Allowed values are `Internal`, `External`, and omitted.
@@ -1408,6 +1481,9 @@ type VSpherePlatformFailureDomainSpec struct {
ZoneAffinity *VSphereFailureDomainZoneAffinity `json:"zoneAffinity,omitempty"`
// server is the fully-qualified domain name or the IP address of the vCenter server.
+ // This must match the server field of an entry in the vcenters list.
+ // The match is case-sensitive; the value must be specified exactly as it appears in the vcenters entry.
+ // The value must be between 1 and 255 characters long.
// +required
// +kubebuilder:validation:MinLength=1
// +kubebuilder:validation:MaxLength=255
@@ -1642,27 +1718,32 @@ type VSpherePlatformNodeNetworking struct {
// use these fields for configuration.
// +kubebuilder:validation:XValidation:rule="!has(oldSelf.apiServerInternalIPs) || has(self.apiServerInternalIPs)",message="apiServerInternalIPs list is required once set"
// +kubebuilder:validation:XValidation:rule="!has(oldSelf.ingressIPs) || has(self.ingressIPs)",message="ingressIPs list is required once set"
-// +kubebuilder:validation:XValidation:rule="!has(oldSelf.vcenters) && has(self.vcenters) ? size(self.vcenters) < 2 : true",message="vcenters can have at most 1 item when configured post-install"
+// +openshift:validation:FeatureGateAwareXValidation:featureGate=VSphereMultiVCenterDay2,rule="!has(self.failureDomains) || size(self.failureDomains) == 0 || (has(self.vcenters) && self.failureDomains.all(fd, self.vcenters.exists(vc, vc.server == fd.server)))",message="all failure domains must have a corresponding vCenter entry"
type VSpherePlatformSpec struct {
// vcenters holds the connection details for services to communicate with vCenter.
- // Currently, only a single vCenter is supported, but in tech preview 3 vCenters are supported.
+ // Up to 3 vCenters are supported.
// Once the cluster has been installed, you are unable to change the current number of defined
- // vCenters except in the case where the cluster has been upgraded from a version of OpenShift
- // where the vsphere platform spec was not present. You may make modifications to the existing
+ // vCenters except when 1.) the cluster has been upgraded from a version of OpenShift
+ // where the vsphere platform spec was not present or 2.) in TechPreview you are able to add and
+ // remove vCenters but may not remove all vCenters. You may make modifications to the existing
// vCenters that are defined in the vcenters list in order to match with any added or modified
// failure domains.
// ---
// + If VCenters is not defined use the existing cloud-config configmap defined
// + in openshift-config.
- // +kubebuilder:validation:MinItems=0
+ // +kubebuilder:validation:MinItems=1
// +kubebuilder:validation:MaxItems=3
- // +kubebuilder:validation:XValidation:rule="size(self) != size(oldSelf) ? size(oldSelf) == 0 && size(self) < 2 : true",message="vcenters cannot be added or removed once set"
+ // +openshift:validation:FeatureGateAwareXValidation:featureGate="",rule="size(self) != size(oldSelf) ? size(oldSelf) == 0 && size(self) < 2 : true",message="vcenters cannot be added or removed once set"
+ // +openshift:validation:FeatureGateAwareXValidation:featureGate=VSphereMultiVCenterDay2,rule="size(self) >= size(oldSelf) ? oldSelf.all(x, self.exists(y, y.server == x.server)) : true",message="Cannot add and remove vCenters at the same time"
+ // +openshift:validation:FeatureGateAwareXValidation:featureGate=VSphereMultiVCenterDay2,rule="size(self) < size(oldSelf) ? self.all(x, oldSelf.exists(y, y.server == x.server)) : true",message="Cannot add and remove vCenters at the same time"
+ // +kubebuilder:validation:XValidation:rule="self.all(x, self.exists_one(y, y.server == x.server))",message="vcenters must have unique server values"
// +listType=atomic
// +optional
VCenters []VSpherePlatformVCenterSpec `json:"vcenters,omitempty"`
// failureDomains contains the definition of region, zone and the vCenter topology.
// If this is omitted failure domains (regions and zones) will not be used.
+ // Each failure domain's server must match the server field of an entry in the vcenters list.
// +listType=map
// +listMapKey=name
// +optional
diff --git a/vendor/github.com/openshift/api/config/v1/types_ingress.go b/vendor/github.com/openshift/api/config/v1/types_ingress.go
index 26e0ebf218..622bce0345 100644
--- a/vendor/github.com/openshift/api/config/v1/types_ingress.go
+++ b/vendor/github.com/openshift/api/config/v1/types_ingress.go
@@ -64,10 +64,12 @@ type IngressSpec struct {
// To determine the set of configurable Routes, look at namespace and name of entries in the
// .status.componentRoutes list, where participating operators write the status of
// configurable routes.
+ // A maximum of 250 component routes may be configured.
// +optional
// +listType=map
// +listMapKey=namespace
// +listMapKey=name
+ // +kubebuilder:validation:MaxItems=250
ComponentRoutes []ComponentRouteSpec `json:"componentRoutes,omitempty"`
// requiredHSTSPolicies specifies HSTS policies that are required to be set on newly created or updated routes
@@ -164,6 +166,15 @@ const (
Classic AWSLBType = "Classic"
)
+// LabelValue is the value part of a Kubernetes label.
+// A label value must be either empty or 1-63 characters, consisting of
+// alphanumeric characters, '-', '_', or '.', starting and ending with
+// an alphanumeric character.
+// +kubebuilder:validation:MaxLength=63
+// +kubebuilder:validation:MinLength=0
+// +kubebuilder:validation:XValidation:rule="self == \"\" || self.matches('^[a-zA-Z0-9]([a-zA-Z0-9._-]*[a-zA-Z0-9])?$')",message="label values must be valid Kubernetes label values (at most 63 characters, alphanumeric, '-', '_', or '.', must start and end with alphanumeric)"
+type LabelValue string
+
// ConsumingUser is an alias for string which we add validation to. Currently only service accounts are supported.
// +kubebuilder:validation:Pattern="^system:serviceaccount:[a-z0-9]([-a-z0-9]*[a-z0-9])?:[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$"
// +kubebuilder:validation:MinLength=1
@@ -245,6 +256,33 @@ type ComponentRouteSpec struct {
// the Secret specification for a serving certificate will not be needed.
// +optional
ServingCertKeyPairSecret SecretNameReference `json:"servingCertKeyPairSecret"`
+
+ // labels defines additional labels to be applied to the route created
+ // for the component. These labels are used by the IngressController to
+ // determine which routes it should manage. Changing labels may cause the
+ // route to be reassigned to a different IngressController.
+ // When omitted, no additional labels are applied to the component route.
+ // When specified, labels must contain at least one entry, up to a maximum of 8.
+ // Label keys must be valid qualified names, consisting of a name segment and
+ // an optional prefix separated by a slash (/). The name segment must be at most
+ // 63 characters in length and must consist only of alphanumeric characters,
+ // dashes (-), underscores (_), and dots (.), and must start and end with
+ // alphanumeric characters. The prefix, if specified, must be a DNS subdomain:
+ // at most 253 characters in length, consisting of dot-separated segments where
+ // each segment starts and ends with an alphanumeric character.
+ // Label values must be either empty or 1-63 characters, consisting of
+ // alphanumeric characters, dashes (-), underscores (_), or dots (.),
+ // starting and ending with an alphanumeric character.
+ // Keys with the "kubernetes.io/", "k8s.io/", and "openshift.io/" prefixes are reserved and may not be used.
+ // +openshift:enable:FeatureGate=IngressComponentRouteLabels
+ // +optional
+ // +mapType=granular
+ // +kubebuilder:validation:MinProperties=1
+ // +kubebuilder:validation:MaxProperties=8
+ // +kubebuilder:validation:XValidation:rule="self.all(key, key.size() <= 63 && key.size() > 0)",message="label keys must be between 1 and 63 characters in length"
+ // +kubebuilder:validation:XValidation:rule="self.all(key, key.matches('^([a-z0-9]([a-z0-9\\\\-]*[a-z0-9])?(\\\\.[a-z0-9]([a-z0-9\\\\-]*[a-z0-9])?)*\\\\/)?[a-zA-Z0-9]([a-zA-Z0-9._-]*[a-zA-Z0-9])?$') && key.size() <= 253)",message="label keys must be valid qualified names, consisting of an optional DNS subdomain prefix of up to 253 characters followed by a slash and a name segment of 1-63 characters, that consists only of alphanumeric characters, dashes, underscores, and dots, and must start and end with an alphanumeric character"
+ // +kubebuilder:validation:XValidation:rule="self.all(key, !key.startsWith('kubernetes.io/') && !key.startsWith('k8s.io/') && !key.startsWith('openshift.io/'))",message="kubernetes.io/, k8s.io/, and openshift.io/ prefixed label keys are reserved and may not be used"
+ Labels map[string]LabelValue `json:"labels,omitempty"`
}
// ComponentRouteStatus contains information allowing configuration of a route's hostname and serving certificate.
diff --git a/vendor/github.com/openshift/api/config/v1/types_kmsencryption.go b/vendor/github.com/openshift/api/config/v1/types_kmsencryption.go
index 3293204fa4..e2f94ae1f3 100644
--- a/vendor/github.com/openshift/api/config/v1/types_kmsencryption.go
+++ b/vendor/github.com/openshift/api/config/v1/types_kmsencryption.go
@@ -1,55 +1,306 @@
package v1
-// KMSConfig defines the configuration for the KMS instance
-// that will be used with KMSEncryptionProvider encryption
-// +kubebuilder:validation:XValidation:rule="has(self.type) && self.type == 'AWS' ? has(self.aws) : !has(self.aws)",message="aws config is required when kms provider type is AWS, and forbidden otherwise"
+// KMSPluginConfig defines the configuration for the KMS instance
+// that will be used with KMS encryption
+// +kubebuilder:validation:XValidation:rule="self.type == 'Vault' ? has(self.vault) : !has(self.vault)",message="vault config is required when kms provider type is Vault, and forbidden otherwise"
// +union
-type KMSConfig struct {
+type KMSPluginConfig struct {
// type defines the kind of platform for the KMS provider.
- // Available provider types are AWS only.
+ // Allowed values are Vault.
+ // When set to Vault, the plugin connects to a HashiCorp Vault server for key management.
//
// +unionDiscriminator
// +required
Type KMSProviderType `json:"type"`
- // aws defines the key config for using an AWS KMS instance
- // for the encryption. The AWS KMS instance is managed
+ // vault defines the configuration for the Vault KMS plugin.
+ // The plugin connects to a Vault Enterprise server that is managed
// by the user outside the purview of the control plane.
+ // This field must be set when type is Vault, and must be unset otherwise.
//
// +unionMember
// +optional
- AWS *AWSKMSConfig `json:"aws,omitempty"`
+ Vault VaultKMSPluginConfig `json:"vault,omitempty,omitzero"`
+
+ // --- TOMBSTONE ---
+ // aws was a field that allowed configuring AWS KMS.
+ // It was never implemented and has been removed.
+ // The field name is reserved to prevent reuse.
+ //
+ // +optional
+ // AWS *AWSKMSConfig `json:"aws,omitempty"`
}
-// AWSKMSConfig defines the KMS config specific to AWS KMS provider
-type AWSKMSConfig struct {
- // keyARN specifies the Amazon Resource Name (ARN) of the AWS KMS key used for encryption.
- // The value must adhere to the format `arn:aws:kms:::key/`, where:
- // - `` is the AWS region consisting of lowercase letters and hyphens followed by a number.
- // - `` is a 12-digit numeric identifier for the AWS account.
- // - `` is a unique identifier for the KMS key, consisting of lowercase hexadecimal characters and hyphens.
+// --- TOMBSTONE ---
+// AWSKMSConfig was a type for AWS KMS configuration that was never implemented.
+// The type name is reserved to prevent reuse.
+//
+// type AWSKMSConfig struct {
+// KeyARN string `json:"keyARN"`
+// Region string `json:"region"`
+// }
+
+// KMSProviderType is a specific supported KMS provider
+// +kubebuilder:validation:Enum=Vault
+type KMSProviderType string
+
+const (
+ // VaultKMSProvider represents a supported KMS provider for use with HashiCorp Vault
+ VaultKMSProvider KMSProviderType = "Vault"
+
+ // --- TOMBSTONE ---
+ // AWSKMSProvider was a constant for AWS KMS support that was never implemented.
+ // The constant name is reserved to prevent reuse.
+ //
+ // AWSKMSProvider KMSProviderType = "AWS"
+)
+
+// VaultSecretReference references a secret in the openshift-config namespace.
+type VaultSecretReference struct {
+ // name is the metadata.name of the referenced secret in the openshift-config namespace.
+ // The name must be a valid DNS subdomain name: it must contain no more than 253 characters,
+ // contain only lowercase alphanumeric characters, '-' or '.', and start and end with an alphanumeric character.
//
- // +kubebuilder:validation:MaxLength=128
// +kubebuilder:validation:MinLength=1
- // +kubebuilder:validation:XValidation:rule="self.matches('^arn:aws:kms:[a-z0-9-]+:[0-9]{12}:key/[a-f0-9-]+$')",message="keyARN must follow the format `arn:aws:kms:::key/`. The account ID must be a 12 digit number and the region and key ID should consist only of lowercase hexadecimal characters and hyphens (-)."
+ // +kubebuilder:validation:MaxLength=253
+ // +kubebuilder:validation:XValidation:rule="self.matches('^[a-z0-9]([a-z0-9\\\\-]*[a-z0-9])?(\\\\.[a-z0-9]([a-z0-9\\\\-]*[a-z0-9])?)*$')",message="name must be a valid DNS subdomain name: contain no more than 253 characters, contain only lowercase alphanumeric characters, '-' or '.', and start and end with an alphanumeric character"
// +required
- KeyARN string `json:"keyARN"`
- // region specifies the AWS region where the KMS instance exists, and follows the format
- // `--`, e.g.: `us-east-1`.
- // Only lowercase letters and hyphens followed by numbers are allowed.
+ Name string `json:"name,omitempty"`
+}
+
+// VaultConfigMapReference references a ConfigMap in the openshift-config namespace.
+type VaultConfigMapReference struct {
+ // name is the metadata.name of the referenced ConfigMap in the openshift-config namespace.
+ // The name must be a valid DNS subdomain name: it must contain no more than 253 characters,
+ // contain only lowercase alphanumeric characters, '-' or '.', and start and end with an alphanumeric character.
//
- // +kubebuilder:validation:MaxLength=64
// +kubebuilder:validation:MinLength=1
- // +kubebuilder:validation:XValidation:rule="self.matches('^[a-z0-9]+(-[a-z0-9]+)*$')",message="region must be a valid AWS region, consisting of lowercase characters, digits and hyphens (-) only."
+ // +kubebuilder:validation:MaxLength=253
+ // +kubebuilder:validation:XValidation:rule="self.matches('^[a-z0-9]([a-z0-9\\\\-]*[a-z0-9])?(\\\\.[a-z0-9]([a-z0-9\\\\-]*[a-z0-9])?)*$')",message="name must be a valid DNS subdomain name: contain no more than 253 characters, contain only lowercase alphanumeric characters, '-' or '.', and start and end with an alphanumeric character"
// +required
- Region string `json:"region"`
+ Name string `json:"name,omitempty"`
}
-// KMSProviderType is a specific supported KMS provider
-// +kubebuilder:validation:Enum=AWS
-type KMSProviderType string
+// VaultAuthentication defines the authentication method used to authenticate with Vault.
+// +kubebuilder:validation:XValidation:rule="self.type == 'AppRole' ? has(self.appRole) : !has(self.appRole)",message="appRole config is required when authentication type is AppRole, and forbidden otherwise"
+// +union
+type VaultAuthentication struct {
+ // type defines the authentication method used to authenticate with Vault.
+ // Allowed values are AppRole.
+ // When set to AppRole, the plugin uses AppRole credentials to authenticate with Vault.
+ //
+ // +unionDiscriminator
+ // +required
+ Type VaultAuthenticationType `json:"type,omitempty"`
+
+ // appRole defines the configuration for AppRole authentication.
+ // This field must be set when type is AppRole, and must be unset otherwise.
+ //
+ // +unionMember
+ // +optional
+ AppRole VaultAppRoleAuthentication `json:"appRole,omitzero"`
+}
+
+// VaultAuthenticationType defines the authentication method type for Vault.
+// +kubebuilder:validation:Enum=AppRole
+type VaultAuthenticationType string
const (
- // AWSKMSProvider represents a supported KMS provider for use with AWS KMS
- AWSKMSProvider KMSProviderType = "AWS"
+ // VaultAuthenticationTypeAppRole represents AppRole authentication method.
+ VaultAuthenticationTypeAppRole VaultAuthenticationType = "AppRole"
)
+
+// VaultAppRoleAuthentication defines the configuration for AppRole authentication with Vault.
+type VaultAppRoleAuthentication struct {
+ // secret references a secret in the openshift-config namespace containing
+ // the AppRole credentials used to authenticate with Vault.
+ // The referenced Secret must contain two keys: "role-id" for the AppRole Role ID and "secret-id" for the AppRole Secret ID.
+ //
+ // +required
+ Secret VaultSecretReference `json:"secret,omitzero"`
+}
+
+// VaultKMSPluginConfig defines the KMS plugin configuration specific to Vault KMS
+type VaultKMSPluginConfig struct {
+ // kmsPluginImage specifies the container image for the HashiCorp Vault KMS plugin.
+ //
+ // The image must be a fully qualified OCI image pull spec with a SHA256 digest.
+ // The format is: host[:port][/namespace]/name@sha256:
+ // where the digest must be 64 characters long and consist only of lowercase hexadecimal characters, a-f and 0-9.
+ // The total length must be between 75 and 447 characters.
+ //
+ // Short names (e.g., "vault-plugin" or "hashicorp/vault-plugin") are not allowed.
+ // The registry hostname must be included and must contain at least one dot.
+ // Image tags (e.g., ":latest", ":v1.0.0") are not allowed.
+ //
+ // Consult the OpenShift documentation for compatible plugin versions with your cluster version,
+ // then obtain the image digest for that version from HashiCorp's container registry.
+ //
+ // For disconnected environments, mirror the plugin image to an accessible registry
+ // and reference the mirrored location with its digest.
+ //
+ // +kubebuilder:validation:MinLength=75
+ // +kubebuilder:validation:MaxLength=447
+ // +kubebuilder:validation:XValidation:rule=`(self.split('@').size() == 2 && self.split('@')[1].matches('^sha256:[a-f0-9]{64}$'))`,message="the OCI Image reference must end with a valid '@sha256:' suffix, where '' is 64 characters long"
+ // +kubebuilder:validation:XValidation:rule=`(self.split('@')[0].matches('^([a-zA-Z0-9-]+\\.)+[a-zA-Z0-9-]+(:[0-9]{2,5})?(/[a-zA-Z0-9-_.]+)+$'))`,message="the OCI Image name should follow the host[:port][/namespace]/name format, resembling a valid URL without the scheme. Short names are not allowed, the registry hostname must be included."
+ // +required
+ KMSPluginImage string `json:"kmsPluginImage,omitempty"`
+
+ // vaultAddress specifies the address of the HashiCorp Vault instance.
+ // The value must be a valid HTTPS URL containing only scheme, host, and optional port.
+ // Paths, user info, query parameters, and fragments are not allowed.
+ //
+ // Format: https://hostname[:port]
+ // Example: https://vault.example.com:8200
+ //
+ // The value must be between 1 and 512 characters.
+ //
+ // +kubebuilder:validation:XValidation:rule="isURL(self)",message="must be a valid URL"
+ // +kubebuilder:validation:XValidation:rule="isURL(self) && url(self).getScheme() == 'https'",message="must use the 'https' scheme"
+ // +kubebuilder:validation:XValidation:rule="isURL(self) && (url(self).getEscapedPath() == '' || url(self).getEscapedPath() == '/')",message="must not contain a path"
+ // +kubebuilder:validation:XValidation:rule="isURL(self) && url(self).getQuery() == {}",message="must not have a query"
+ // +kubebuilder:validation:XValidation:rule="self.find('#(.+)$') == ''",message="must not have a fragment"
+ // +kubebuilder:validation:XValidation:rule="self.find('@') == ''",message="must not have user info"
+ // +kubebuilder:validation:MaxLength=512
+ // +kubebuilder:validation:MinLength=1
+ // +required
+ VaultAddress string `json:"vaultAddress,omitempty"`
+
+ // vaultNamespace specifies the Vault namespace where the Transit secrets engine is mounted.
+ // This is only applicable for Vault Enterprise installations.
+ // When this field is not set, no namespace is used.
+ //
+ // The value must be between 1 and 4096 characters.
+ // The namespace cannot end with a forward slash, cannot contain spaces, and cannot be one of the reserved strings: root, sys, audit, auth, cubbyhole, or identity.
+ //
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=4096
+ // +kubebuilder:validation:XValidation:rule="!self.endsWith('/')",message="vaultNamespace cannot end with a forward slash"
+ // +kubebuilder:validation:XValidation:rule="!self.contains(' ')",message="vaultNamespace cannot contain spaces"
+ // +kubebuilder:validation:XValidation:rule="!(self in ['root', 'sys', 'audit', 'auth', 'cubbyhole', 'identity'])",message="vaultNamespace cannot be a reserved string (root, sys, audit, auth, cubbyhole, identity)"
+ // +optional
+ VaultNamespace string `json:"vaultNamespace,omitempty"`
+
+ // vaultAuthNamespace specifies the Vault namespace to use for authentication.
+ // This is only applicable for Vault Enterprise installations where authentication
+ // and Transit operations may be in different namespaces.
+ // When this field is not set, the value of vaultNamespace is used for both
+ // authentication and Transit key operations.
+ //
+ // The value must be between 1 and 4096 characters.
+ // The namespace cannot end with a forward slash, cannot contain spaces, and cannot be one of the reserved strings: root, sys, audit, auth, cubbyhole, or identity.
+ //
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=4096
+ // +kubebuilder:validation:XValidation:rule="!self.endsWith('/')",message="vaultAuthNamespace cannot end with a forward slash"
+ // +kubebuilder:validation:XValidation:rule="!self.contains(' ')",message="vaultAuthNamespace cannot contain spaces"
+ // +kubebuilder:validation:XValidation:rule="!(self in ['root', 'sys', 'audit', 'auth', 'cubbyhole', 'identity'])",message="vaultAuthNamespace cannot be a reserved string (root, sys, audit, auth, cubbyhole, identity)"
+ // +optional
+ VaultAuthNamespace string `json:"vaultAuthNamespace,omitempty"`
+
+ // tls contains the TLS configuration for connecting to the Vault server.
+ // When this field is not set, system default TLS settings are used.
+ // +optional
+ TLS VaultTLSConfig `json:"tls,omitzero"`
+
+ // authentication defines the authentication method used to authenticate with Vault.
+ //
+ // +required
+ Authentication VaultAuthentication `json:"authentication,omitzero"`
+
+ // vaultKeyPath specifies the full path to the encryption key in Vault's Transit secrets engine,
+ // combining the Transit engine mount path and the key name separated by "/keys/".
+ // Format: /keys/ (e.g., transit/keys/my-key, myteam/transit/keys/production-key).
+ //
+ // The total path length must be between 8 and 1542 characters.
+ // The path cannot start or end with a forward slash, cannot contain consecutive forward slashes,
+ // must only contain RFC 3986 unreserved characters (alphanumeric, hyphen, period, underscore, tilde)
+ // and forward slashes as path separators, and must not contain "." or ".." path segments.
+ // The key name must start and end with an alphanumeric character or underscore, and may contain
+ // alphanumeric characters, underscores, hyphens, and periods in the middle.
+ //
+ // +kubebuilder:validation:MinLength=8
+ // +kubebuilder:validation:MaxLength=1542
+ // +kubebuilder:validation:XValidation:rule="!self.startsWith('/')",message="vaultKeyPath cannot start with a forward slash"
+ // +kubebuilder:validation:XValidation:rule="!self.endsWith('/')",message="vaultKeyPath cannot end with a forward slash"
+ // +kubebuilder:validation:XValidation:rule="!self.contains('//')",message="vaultKeyPath cannot contain consecutive forward slashes"
+ // +kubebuilder:validation:XValidation:rule="self.matches('^[a-zA-Z0-9._~/-]+$')",message="vaultKeyPath must only contain RFC 3986 unreserved characters (alphanumeric, hyphen, period, underscore, tilde) and forward slashes"
+ // +kubebuilder:validation:XValidation:rule="self.split('/').filter(s, s == '.' || s == '..').size() == 0",message="vaultKeyPath must not contain '.' or '..' path segments"
+ // +kubebuilder:validation:XValidation:rule=`self.matches('^[a-zA-Z0-9._~-]+(/[a-zA-Z0-9._~-]+)*/keys/[a-zA-Z0-9_]([a-zA-Z0-9_.-]*[a-zA-Z0-9_])?$')`,message="vaultKeyPath must follow the format /keys/ where the key name starts and ends with an alphanumeric character or underscore and may contain alphanumeric characters, underscores, hyphens, and periods"
+ // +required
+ VaultKeyPath string `json:"vaultKeyPath,omitempty"`
+
+ // --- TOMBSTONE ---
+ // transitMount specifies the mount path of the Vault Transit engine.
+ // It has been replaced by vaultKeyPath which combines the mount and key into a single path.
+ // The field name is reserved to prevent reuse.
+ //
+ // The transit mount must be between 1 and 1024 characters, cannot start or
+ // end with a forward slash, cannot contain consecutive forward slashes, and
+ // must only contain RFC 3986 unreserved characters (alphanumeric, hyphen,
+ // period, underscore, tilde) and forward slashes as path separators.
+ //
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=1024
+ // +kubebuilder:validation:XValidation:rule="!self.startsWith('/')",message="transitMount cannot start with a forward slash"
+ // +kubebuilder:validation:XValidation:rule="!self.endsWith('/')",message="transitMount cannot end with a forward slash"
+ // +kubebuilder:validation:XValidation:rule="!self.contains('//')",message="transitMount cannot contain consecutive forward slashes"
+ // +kubebuilder:validation:XValidation:rule="self.matches('^[a-zA-Z0-9._~/-]+$')",message="transitMount must only contain RFC 3986 unreserved characters (alphanumeric, hyphen, period, underscore, tilde) and forward slashes"
+ // +required
+ // TransitMount string `json:"transitMount,omitempty"`
+
+ // --- TOMBSTONE ---
+ // transitKey specifies the name of the encryption key in Vault's Transit engine.
+ // This key is used to encrypt and decrypt data.
+ // It has been replaced by vaultKeyPath which combines the mount and key into a single path.
+ // The field name is reserved to prevent reuse.
+ //
+ // The transit key must be between 1 and 512 characters, cannot contain forward slashes,
+ // and must only contain alphanumeric characters, hyphens, periods, and underscores.
+ //
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=512
+ // +kubebuilder:validation:XValidation:rule="!self.contains('/')",message="transitKey cannot contain forward slashes"
+ // +kubebuilder:validation:XValidation:rule="self.matches('^[a-zA-Z0-9._-]+$')",message="transitKey must only contain alphanumeric characters, hyphens, periods, and underscores"
+ // +required
+ // TransitKey string `json:"transitKey,omitempty"`
+}
+
+// VaultTLSConfig contains TLS configuration for connecting to Vault.
+// +kubebuilder:validation:MinProperties=1
+type VaultTLSConfig struct {
+ // caBundle references a ConfigMap in the openshift-config namespace containing
+ // the CA certificate bundle used to verify the TLS connection to the Vault server.
+ // The referenced ConfigMap must contain the CA bundle in the key "ca-bundle.crt".
+ // When this field is not set, the system's trusted CA certificates are used.
+ //
+ // The namespace for the ConfigMap is openshift-config.
+ //
+ // Example ConfigMap:
+ // apiVersion: v1
+ // kind: ConfigMap
+ // metadata:
+ // name: vault-ca-bundle
+ // namespace: openshift-config
+ // data:
+ // ca-bundle.crt: |
+ // -----BEGIN CERTIFICATE-----
+ // ...
+ // -----END CERTIFICATE-----
+ //
+ // +optional
+ CABundle VaultConfigMapReference `json:"caBundle,omitzero"`
+
+ // serverName specifies the Server Name Indication (SNI) to use when connecting to Vault via TLS.
+ // This is useful when the Vault server's hostname doesn't match its TLS certificate.
+ // When this field is not set, the hostname from vaultAddress is used for SNI.
+ //
+ // The value must be a valid DNS hostname: it must contain no more than 253 characters,
+ // contain only lowercase alphanumeric characters, '-' or '.', and start and end with an alphanumeric character.
+ //
+ // +kubebuilder:validation:MaxLength=253
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:XValidation:rule="self.matches('^[a-z0-9]([a-z0-9\\\\-]*[a-z0-9])?(\\\\.[a-z0-9]([a-z0-9\\\\-]*[a-z0-9])?)*$')",message="serverName must be a valid DNS hostname: contain no more than 253 characters, contain only lowercase alphanumeric characters, '-' or '.', and start and end with an alphanumeric character"
+ // +optional
+ ServerName string `json:"serverName,omitempty"`
+}
diff --git a/vendor/github.com/openshift/api/config/v1/types_network.go b/vendor/github.com/openshift/api/config/v1/types_network.go
index fb8ed2fff7..80b022de9f 100644
--- a/vendor/github.com/openshift/api/config/v1/types_network.go
+++ b/vendor/github.com/openshift/api/config/v1/types_network.go
@@ -86,6 +86,13 @@ type NetworkSpec struct {
//
// +optional
NetworkDiagnostics NetworkDiagnostics `json:"networkDiagnostics"`
+
+ // networkObservability is an optional field that configures network observability installation
+ // during cluster deployment (day-0).
+ // When omitted, unless this is a SNO cluster, network observability will be installed if not already present, after that, no action taken.
+ // +openshift:enable:FeatureGate=NetworkObservabilityInstall
+ // +optional
+ NetworkObservability NetworkObservabilitySpec `json:"networkObservability,omitempty,omitzero"`
}
// NetworkStatus is the current network configuration.
@@ -304,3 +311,29 @@ type NetworkDiagnosticsTargetPlacement struct {
// +listType=atomic
Tolerations []corev1.Toleration `json:"tolerations"`
}
+
+// NetworkObservabilityInstallationPolicy is an enumeration of the available network observability installation policies
+// Valid values are "InstallAndEnable", "NoAction".
+// +kubebuilder:validation:Enum=InstallAndEnable;NoAction
+type NetworkObservabilityInstallationPolicy string
+
+const (
+ // NetworkObservabilityInstallAndEnable means that network observability should be installed and enabled during cluster deployment
+ // Since this was explicitly set to install, if the user remove NetworkObservability, it will be installed again unless the value of InstallationPolicy is changed
+ NetworkObservabilityInstallAndEnable NetworkObservabilityInstallationPolicy = "InstallAndEnable"
+ // NetworkObservabilityNoAction means that nothing will be done regarding Network Observability
+ NetworkObservabilityNoAction NetworkObservabilityInstallationPolicy = "NoAction"
+)
+
+// NetworkObservabilitySpec defines the configuration for network observability installation
+type NetworkObservabilitySpec struct {
+ // installationPolicy controls whether network observability is installed during cluster deployment.
+ // Valid values are "InstallAndEnable" and "NoAction".
+ // When set to "InstallAndEnable", ensure that network observability will be installed and enabled on the cluster. If already installed, no action taken, but if it gets uninstalled, it will install it again.
+ // When set to "NoAction", nothing will be done regarding Network observability.
+ // During the installation of NetworkObservability, the platform checks for any existing manual installations.
+ // If a successful installation using the OLMv0 or OLMv1 API is detected, it will be used.
+ // If the platform cannot determine how the current version was installed, or if the existing installation is incomplete, the installation process will stop.
+ // +required
+ InstallationPolicy NetworkObservabilityInstallationPolicy `json:"installationPolicy,omitempty"`
+}
diff --git a/vendor/github.com/openshift/api/config/v1/types_tlssecurityprofile.go b/vendor/github.com/openshift/api/config/v1/types_tlssecurityprofile.go
index 48657b0894..2e9be97aeb 100644
--- a/vendor/github.com/openshift/api/config/v1/types_tlssecurityprofile.go
+++ b/vendor/github.com/openshift/api/config/v1/types_tlssecurityprofile.go
@@ -7,10 +7,16 @@ type TLSSecurityProfile struct {
// type is one of Old, Intermediate, Modern or Custom. Custom provides the
// ability to specify individual TLS security profile parameters.
//
- // The profiles are based on version 5.7 of the Mozilla Server Side TLS
- // configuration guidelines. The cipher lists consist of the configuration's
- // "ciphersuites" followed by the Go-specific "ciphers" from the guidelines.
- // See: https://ssl-config.mozilla.org/guidelines/5.7.json
+ // The cipher and groups lists in these profiles are based on version 5.8 of the
+ // Mozilla Server Side TLS configuration guidelines.
+ // See: https://ssl-config.mozilla.org/guidelines/5.8.json
+ //
+ // The groups are listed in suggested preference order, with the most preferred group first.
+ // Note that not all platform components honor the ordering: Go-based components use Go's
+ // internal preference order and treat this list as a filter of allowed groups rather than
+ // an ordered preference.
+ // Note that X25519MLKEM768 is a post-quantum hybrid group that is not
+ // FIPS-approved and should be ignored by components running in FIPS mode.
//
// The profiles are intent based, so they may change over time as new ciphers are
// developed and existing ciphers are found to be insecure. Depending on
@@ -23,6 +29,10 @@ type TLSSecurityProfile struct {
// old is a TLS profile for use when services need to be accessed by very old
// clients or libraries and should be used only as a last resort.
//
+ // The supported groups list includes by default the following groups
+ // in suggested preference order (ordering may not be honored by all implementations):
+ // X25519MLKEM768, X25519, secp256r1, secp384r1.
+ //
// This profile is equivalent to a Custom profile specified as:
// minTLSVersion: VersionTLS10
// ciphers:
@@ -39,11 +49,14 @@ type TLSSecurityProfile struct {
// - ECDHE-RSA-AES128-SHA256
// - ECDHE-ECDSA-AES128-SHA
// - ECDHE-RSA-AES128-SHA
+ // - ECDHE-ECDSA-AES256-SHA384
+ // - ECDHE-RSA-AES256-SHA384
// - ECDHE-ECDSA-AES256-SHA
// - ECDHE-RSA-AES256-SHA
// - AES128-GCM-SHA256
// - AES256-GCM-SHA384
// - AES128-SHA256
+ // - AES256-SHA256
// - AES128-SHA
// - AES256-SHA
// - DES-CBC3-SHA
@@ -56,6 +69,10 @@ type TLSSecurityProfile struct {
// legacy clients and want to remain highly secure while being compatible with
// most clients currently in use.
//
+ // The supported groups list includes by default the following groups
+ // in suggested preference order (ordering may not be honored by all implementations):
+ // X25519MLKEM768, X25519, secp256r1, secp384r1.
+ //
// This profile is equivalent to a Custom profile specified as:
// minTLSVersion: VersionTLS12
// ciphers:
@@ -75,7 +92,9 @@ type TLSSecurityProfile struct {
// modern is a TLS security profile for use with clients that support TLS 1.3 and
// do not need backward compatibility for older clients.
- //
+ // The supported groups list includes by default the following groups
+ // in suggested preference order (ordering may not be honored by all implementations):
+ // X25519MLKEM768, X25519, secp256r1, secp384r1.
// This profile is equivalent to a Custom profile specified as:
// minTLSVersion: VersionTLS13
// ciphers:
@@ -88,8 +107,11 @@ type TLSSecurityProfile struct {
Modern *ModernTLSProfile `json:"modern,omitempty"`
// custom is a user-defined TLS security profile. Be extremely careful using a custom
- // profile as invalid configurations can be catastrophic. An example custom profile
- // looks like this:
+ // profile as invalid configurations can be catastrophic.
+ //
+ // The supported groups list for this profile is empty by default.
+ //
+ // An example custom profile looks like this:
//
// minTLSVersion: VersionTLS11
// ciphers:
@@ -142,6 +164,33 @@ const (
TLSProfileCustomType TLSProfileType = "Custom"
)
+// TLSGroup is a supported group identifier that can be used in TLSProfile.Groups.
+// There is a one-to-one mapping between these names and the group IDs defined
+// in Go's crypto/tls package based on IANA's "TLS Supported Groups" registry:
+// https://www.iana.org/assignments/tls-parameters/tls-parameters.xhtml#tls-parameters-8
+// Note that X25519MLKEM768 is a post-quantum hybrid group that is not
+// FIPS-approved and should be ignored by components running in FIPS mode.
+//
+// +kubebuilder:validation:Enum=X25519;secp256r1;secp384r1;secp521r1;X25519MLKEM768;SecP256r1MLKEM768;SecP384r1MLKEM1024
+type TLSGroup string
+
+const (
+ // TLSGroupX25519 represents X25519.
+ TLSGroupX25519 TLSGroup = "X25519"
+ // TLSGroupSecP256r1 represents P-256 (secp256r1).
+ TLSGroupSecP256r1 TLSGroup = "secp256r1"
+ // TLSGroupSecP384r1 represents P-384 (secp384r1).
+ TLSGroupSecP384r1 TLSGroup = "secp384r1"
+ // TLSGroupSecP521r1 represents P-521 (secp521r1).
+ TLSGroupSecP521r1 TLSGroup = "secp521r1"
+ // TLSGroupX25519MLKEM768 represents X25519MLKEM768.
+ TLSGroupX25519MLKEM768 TLSGroup = "X25519MLKEM768"
+ // TLSGroupSecP256r1MLKEM768 represents SecP256r1MLKEM768.
+ TLSGroupSecP256r1MLKEM768 TLSGroup = "SecP256r1MLKEM768"
+ // TLSGroupSecP384r1MLKEM1024 represents SecP384r1MLKEM1024.
+ TLSGroupSecP384r1MLKEM1024 TLSGroup = "SecP384r1MLKEM1024"
+)
+
// TLSProfileSpec is the desired behavior of a TLSSecurityProfile.
type TLSProfileSpec struct {
// ciphers is used to specify the cipher algorithms that are negotiated
@@ -155,6 +204,30 @@ type TLSProfileSpec struct {
// and are always enabled when TLS 1.3 is negotiated.
// +listType=atomic
Ciphers []string `json:"ciphers"`
+ // groups is an optional, ordered field used to specify the supported groups (formerly known as
+ // elliptic curves) that are used during the TLS handshake. The order of the groups represents
+ // a suggested preference, with the most preferred group first. Note that not all platform
+ // components honor the ordering: Go-based components use Go's internal preference order and
+ // treat this list as a filter of allowed groups rather than an ordered preference.
+ // Operators may remove entries their operands do not support.
+ //
+ // When omitted, this means no opinion and the platform is left to choose reasonable defaults which are
+ // subject to change over time and may be different per platform component depending on the underlying TLS
+ // libraries they use. If specified, the list must contain at least one and at most 7 groups,
+ // and each group must be unique.
+ //
+ // For example, to use X25519 and secp256r1 (yaml):
+ //
+ // groups:
+ // - X25519
+ // - secp256r1
+ //
+ // +optional
+ // +listType=set
+ // +kubebuilder:validation:MaxItems=7
+ // +kubebuilder:validation:MinItems=1
+ // +openshift:enable:FeatureGate=TLSGroupPreferences
+ Groups []TLSGroup `json:"groups,omitempty"`
// minTLSVersion is used to specify the minimal version of the TLS protocol
// that is negotiated during the TLS handshake. For example, to use TLS
// versions 1.1, 1.2 and 1.3 (yaml):
@@ -187,16 +260,22 @@ const (
// TLSProfiles contains a map of TLSProfileType names to TLSProfileSpec.
//
-// These profiles are based on version 5.7 of the Mozilla Server Side TLS
-// configuration guidelines. See: https://ssl-config.mozilla.org/guidelines/5.7.json
+// The cipher and groups lists in these profiles are based on version 5.8 of the
+// Mozilla Server Side TLS configuration guidelines.
+// See: https://ssl-config.mozilla.org/guidelines/5.8.json
//
// Each Ciphers slice is the configuration's "ciphersuites" followed by the
-// Go-specific "ciphers" from the guidelines JSON.
+// "ciphers" from the guidelines JSON.
+//
+// Groups are listed in suggested preference order, though Go-based components may use
+// their own internal ordering. TLSProfiles Old, Intermediate, Modern include by default
+// the following groups: X25519MLKEM768, X25519, secp256r1, secp384r1
//
// NOTE: The caller needs to make sure to check that these constants are valid
// for their binary. Not all entries map to values for all binaries. In the case
// of ties, the kube-apiserver wins. Do not fail, just be sure to include only
-// valid entries and everything will be ok.
+// valid entries and everything will be ok. In particular, X25519MLKEM768 is
+// not FIPS-approved and must be omitted by components running in FIPS mode.
var TLSProfiles = map[TLSProfileType]*TLSProfileSpec{
TLSProfileOldType: {
Ciphers: []string{
@@ -213,15 +292,24 @@ var TLSProfiles = map[TLSProfileType]*TLSProfileSpec{
"ECDHE-RSA-AES128-SHA256",
"ECDHE-ECDSA-AES128-SHA",
"ECDHE-RSA-AES128-SHA",
+ "ECDHE-ECDSA-AES256-SHA384",
+ "ECDHE-RSA-AES256-SHA384",
"ECDHE-ECDSA-AES256-SHA",
"ECDHE-RSA-AES256-SHA",
"AES128-GCM-SHA256",
"AES256-GCM-SHA384",
"AES128-SHA256",
+ "AES256-SHA256",
"AES128-SHA",
"AES256-SHA",
"DES-CBC3-SHA",
},
+ Groups: []TLSGroup{
+ TLSGroupX25519MLKEM768,
+ TLSGroupX25519,
+ TLSGroupSecP256r1,
+ TLSGroupSecP384r1,
+ },
MinTLSVersion: VersionTLS10,
},
TLSProfileIntermediateType: {
@@ -236,6 +324,12 @@ var TLSProfiles = map[TLSProfileType]*TLSProfileSpec{
"ECDHE-ECDSA-CHACHA20-POLY1305",
"ECDHE-RSA-CHACHA20-POLY1305",
},
+ Groups: []TLSGroup{
+ TLSGroupX25519MLKEM768,
+ TLSGroupX25519,
+ TLSGroupSecP256r1,
+ TLSGroupSecP384r1,
+ },
MinTLSVersion: VersionTLS12,
},
TLSProfileModernType: {
@@ -244,6 +338,12 @@ var TLSProfiles = map[TLSProfileType]*TLSProfileSpec{
"TLS_AES_256_GCM_SHA384",
"TLS_CHACHA20_POLY1305_SHA256",
},
+ Groups: []TLSGroup{
+ TLSGroupX25519MLKEM768,
+ TLSGroupX25519,
+ TLSGroupSecP256r1,
+ TLSGroupSecP384r1,
+ },
MinTLSVersion: VersionTLS13,
},
}
diff --git a/vendor/github.com/openshift/api/config/v1/zz_generated.deepcopy.go b/vendor/github.com/openshift/api/config/v1/zz_generated.deepcopy.go
index 30b85b78e9..4b194b226a 100644
--- a/vendor/github.com/openshift/api/config/v1/zz_generated.deepcopy.go
+++ b/vendor/github.com/openshift/api/config/v1/zz_generated.deepcopy.go
@@ -42,11 +42,7 @@ func (in *APIServer) DeepCopyObject() runtime.Object {
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *APIServerEncryption) DeepCopyInto(out *APIServerEncryption) {
*out = *in
- if in.KMS != nil {
- in, out := &in.KMS, &out.KMS
- *out = new(KMSConfig)
- (*in).DeepCopyInto(*out)
- }
+ out.KMS = in.KMS
return
}
@@ -148,7 +144,7 @@ func (in *APIServerSpec) DeepCopyInto(out *APIServerSpec) {
*out = make([]string, len(*in))
copy(*out, *in)
}
- in.Encryption.DeepCopyInto(&out.Encryption)
+ out.Encryption = in.Encryption
if in.TLSSecurityProfile != nil {
in, out := &in.TLSSecurityProfile, &out.TLSSecurityProfile
*out = new(TLSSecurityProfile)
@@ -216,22 +212,6 @@ func (in *AWSIngressSpec) DeepCopy() *AWSIngressSpec {
return out
}
-// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *AWSKMSConfig) DeepCopyInto(out *AWSKMSConfig) {
- *out = *in
- return
-}
-
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AWSKMSConfig.
-func (in *AWSKMSConfig) DeepCopy() *AWSKMSConfig {
- if in == nil {
- return nil
- }
- out := new(AWSKMSConfig)
- in.DeepCopyInto(out)
- return out
-}
-
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *AWSPlatformSpec) DeepCopyInto(out *AWSPlatformSpec) {
*out = *in
@@ -924,6 +904,115 @@ func (in *BuildSpec) DeepCopy() *BuildSpec {
return out
}
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *CRIOCredentialProviderConfig) DeepCopyInto(out *CRIOCredentialProviderConfig) {
+ *out = *in
+ out.TypeMeta = in.TypeMeta
+ in.ObjectMeta.DeepCopyInto(&out.ObjectMeta)
+ if in.Spec != nil {
+ in, out := &in.Spec, &out.Spec
+ *out = new(CRIOCredentialProviderConfigSpec)
+ (*in).DeepCopyInto(*out)
+ }
+ in.Status.DeepCopyInto(&out.Status)
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CRIOCredentialProviderConfig.
+func (in *CRIOCredentialProviderConfig) DeepCopy() *CRIOCredentialProviderConfig {
+ if in == nil {
+ return nil
+ }
+ out := new(CRIOCredentialProviderConfig)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
+func (in *CRIOCredentialProviderConfig) DeepCopyObject() runtime.Object {
+ if c := in.DeepCopy(); c != nil {
+ return c
+ }
+ return nil
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *CRIOCredentialProviderConfigList) DeepCopyInto(out *CRIOCredentialProviderConfigList) {
+ *out = *in
+ out.TypeMeta = in.TypeMeta
+ in.ListMeta.DeepCopyInto(&out.ListMeta)
+ if in.Items != nil {
+ in, out := &in.Items, &out.Items
+ *out = make([]CRIOCredentialProviderConfig, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CRIOCredentialProviderConfigList.
+func (in *CRIOCredentialProviderConfigList) DeepCopy() *CRIOCredentialProviderConfigList {
+ if in == nil {
+ return nil
+ }
+ out := new(CRIOCredentialProviderConfigList)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
+func (in *CRIOCredentialProviderConfigList) DeepCopyObject() runtime.Object {
+ if c := in.DeepCopy(); c != nil {
+ return c
+ }
+ return nil
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *CRIOCredentialProviderConfigSpec) DeepCopyInto(out *CRIOCredentialProviderConfigSpec) {
+ *out = *in
+ if in.MatchImages != nil {
+ in, out := &in.MatchImages, &out.MatchImages
+ *out = make([]MatchImage, len(*in))
+ copy(*out, *in)
+ }
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CRIOCredentialProviderConfigSpec.
+func (in *CRIOCredentialProviderConfigSpec) DeepCopy() *CRIOCredentialProviderConfigSpec {
+ if in == nil {
+ return nil
+ }
+ out := new(CRIOCredentialProviderConfigSpec)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *CRIOCredentialProviderConfigStatus) DeepCopyInto(out *CRIOCredentialProviderConfigStatus) {
+ *out = *in
+ if in.Conditions != nil {
+ in, out := &in.Conditions, &out.Conditions
+ *out = make([]metav1.Condition, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CRIOCredentialProviderConfigStatus.
+func (in *CRIOCredentialProviderConfigStatus) DeepCopy() *CRIOCredentialProviderConfigStatus {
+ if in == nil {
+ return nil
+ }
+ out := new(CRIOCredentialProviderConfigStatus)
+ in.DeepCopyInto(out)
+ return out
+}
+
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *CertInfo) DeepCopyInto(out *CertInfo) {
*out = *in
@@ -956,6 +1045,45 @@ func (in *ClientConnectionOverrides) DeepCopy() *ClientConnectionOverrides {
return out
}
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *ClientCredentialConfig) DeepCopyInto(out *ClientCredentialConfig) {
+ *out = *in
+ out.ClientSecret = in.ClientSecret
+ if in.Scopes != nil {
+ in, out := &in.Scopes, &out.Scopes
+ *out = make([]OAuth2Scope, len(*in))
+ copy(*out, *in)
+ }
+ out.TLS = in.TLS
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClientCredentialConfig.
+func (in *ClientCredentialConfig) DeepCopy() *ClientCredentialConfig {
+ if in == nil {
+ return nil
+ }
+ out := new(ClientCredentialConfig)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *ClientSecretSecretReference) DeepCopyInto(out *ClientSecretSecretReference) {
+ *out = *in
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClientSecretSecretReference.
+func (in *ClientSecretSecretReference) DeepCopy() *ClientSecretSecretReference {
+ if in == nil {
+ return nil
+ }
+ out := new(ClientSecretSecretReference)
+ in.DeepCopyInto(out)
+ return out
+}
+
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *CloudControllerManagerStatus) DeepCopyInto(out *CloudControllerManagerStatus) {
*out = *in
@@ -1512,6 +1640,13 @@ func (in *ComponentOverride) DeepCopy() *ComponentOverride {
func (in *ComponentRouteSpec) DeepCopyInto(out *ComponentRouteSpec) {
*out = *in
out.ServingCertKeyPairSecret = in.ServingCertKeyPairSecret
+ if in.Labels != nil {
+ in, out := &in.Labels, &out.Labels
+ *out = make(map[string]LabelValue, len(*in))
+ for key, val := range *in {
+ (*out)[key] = val
+ }
+ }
return
}
@@ -2103,6 +2238,35 @@ func (in *EtcdStorageConfig) DeepCopy() *EtcdStorageConfig {
return out
}
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *ExternalClaimsSource) DeepCopyInto(out *ExternalClaimsSource) {
+ *out = *in
+ in.Authentication.DeepCopyInto(&out.Authentication)
+ out.TLS = in.TLS
+ out.URL = in.URL
+ if in.Mappings != nil {
+ in, out := &in.Mappings, &out.Mappings
+ *out = make([]SourcedClaimMapping, len(*in))
+ copy(*out, *in)
+ }
+ if in.Predicates != nil {
+ in, out := &in.Predicates, &out.Predicates
+ *out = make([]ExternalSourcePredicate, len(*in))
+ copy(*out, *in)
+ }
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ExternalClaimsSource.
+func (in *ExternalClaimsSource) DeepCopy() *ExternalClaimsSource {
+ if in == nil {
+ return nil
+ }
+ out := new(ExternalClaimsSource)
+ in.DeepCopyInto(out)
+ return out
+}
+
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *ExternalIPConfig) DeepCopyInto(out *ExternalIPConfig) {
*out = *in
@@ -2188,6 +2352,72 @@ func (in *ExternalPlatformStatus) DeepCopy() *ExternalPlatformStatus {
return out
}
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *ExternalSourceAuthentication) DeepCopyInto(out *ExternalSourceAuthentication) {
+ *out = *in
+ in.ClientCredential.DeepCopyInto(&out.ClientCredential)
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ExternalSourceAuthentication.
+func (in *ExternalSourceAuthentication) DeepCopy() *ExternalSourceAuthentication {
+ if in == nil {
+ return nil
+ }
+ out := new(ExternalSourceAuthentication)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *ExternalSourceCertificateAuthorityConfigMapReference) DeepCopyInto(out *ExternalSourceCertificateAuthorityConfigMapReference) {
+ *out = *in
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ExternalSourceCertificateAuthorityConfigMapReference.
+func (in *ExternalSourceCertificateAuthorityConfigMapReference) DeepCopy() *ExternalSourceCertificateAuthorityConfigMapReference {
+ if in == nil {
+ return nil
+ }
+ out := new(ExternalSourceCertificateAuthorityConfigMapReference)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *ExternalSourcePredicate) DeepCopyInto(out *ExternalSourcePredicate) {
+ *out = *in
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ExternalSourcePredicate.
+func (in *ExternalSourcePredicate) DeepCopy() *ExternalSourcePredicate {
+ if in == nil {
+ return nil
+ }
+ out := new(ExternalSourcePredicate)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *ExternalSourceTLS) DeepCopyInto(out *ExternalSourceTLS) {
+ *out = *in
+ out.CertificateAuthority = in.CertificateAuthority
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ExternalSourceTLS.
+func (in *ExternalSourceTLS) DeepCopy() *ExternalSourceTLS {
+ if in == nil {
+ return nil
+ }
+ out := new(ExternalSourceTLS)
+ in.DeepCopyInto(out)
+ return out
+}
+
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *ExtraMapping) DeepCopyInto(out *ExtraMapping) {
*out = *in
@@ -2560,6 +2790,7 @@ func (in *GenericAPIServerConfig) DeepCopy() *GenericAPIServerConfig {
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *GenericControllerConfig) DeepCopyInto(out *GenericControllerConfig) {
*out = *in
+ out.TypeMeta = in.TypeMeta
in.ServingInfo.DeepCopyInto(&out.ServingInfo)
out.LeaderElection = in.LeaderElection
out.Authentication = in.Authentication
@@ -3690,7 +3921,9 @@ func (in *IngressSpec) DeepCopyInto(out *IngressSpec) {
if in.ComponentRoutes != nil {
in, out := &in.ComponentRoutes, &out.ComponentRoutes
*out = make([]ComponentRouteSpec, len(*in))
- copy(*out, *in)
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
}
if in.RequiredHSTSPolicies != nil {
in, out := &in.RequiredHSTSPolicies, &out.RequiredHSTSPolicies
@@ -3830,22 +4063,18 @@ func (in *IntermediateTLSProfile) DeepCopy() *IntermediateTLSProfile {
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *KMSConfig) DeepCopyInto(out *KMSConfig) {
+func (in *KMSPluginConfig) DeepCopyInto(out *KMSPluginConfig) {
*out = *in
- if in.AWS != nil {
- in, out := &in.AWS, &out.AWS
- *out = new(AWSKMSConfig)
- **out = **in
- }
+ out.Vault = in.Vault
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KMSConfig.
-func (in *KMSConfig) DeepCopy() *KMSConfig {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KMSPluginConfig.
+func (in *KMSPluginConfig) DeepCopy() *KMSPluginConfig {
if in == nil {
return nil
}
- out := new(KMSConfig)
+ out := new(KMSPluginConfig)
in.DeepCopyInto(out)
return out
}
@@ -4283,6 +4512,22 @@ func (in *NetworkMigration) DeepCopy() *NetworkMigration {
return out
}
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *NetworkObservabilitySpec) DeepCopyInto(out *NetworkObservabilitySpec) {
+ *out = *in
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NetworkObservabilitySpec.
+func (in *NetworkObservabilitySpec) DeepCopy() *NetworkObservabilitySpec {
+ if in == nil {
+ return nil
+ }
+ out := new(NetworkObservabilitySpec)
+ in.DeepCopyInto(out)
+ return out
+}
+
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *NetworkSpec) DeepCopyInto(out *NetworkSpec) {
*out = *in
@@ -4302,6 +4547,7 @@ func (in *NetworkSpec) DeepCopyInto(out *NetworkSpec) {
(*in).DeepCopyInto(*out)
}
in.NetworkDiagnostics.DeepCopyInto(&out.NetworkDiagnostics)
+ out.NetworkObservability = in.NetworkObservability
return
}
@@ -4847,6 +5093,13 @@ func (in *OIDCProvider) DeepCopyInto(out *OIDCProvider) {
*out = make([]TokenUserValidationRule, len(*in))
copy(*out, *in)
}
+ if in.ExternalClaimsSources != nil {
+ in, out := &in.ExternalClaimsSources, &out.ExternalClaimsSources
+ *out = make([]ExternalClaimsSource, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
return
}
@@ -6187,6 +6440,38 @@ func (in *SignatureStore) DeepCopy() *SignatureStore {
return out
}
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *SourceURL) DeepCopyInto(out *SourceURL) {
+ *out = *in
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SourceURL.
+func (in *SourceURL) DeepCopy() *SourceURL {
+ if in == nil {
+ return nil
+ }
+ out := new(SourceURL)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *SourcedClaimMapping) DeepCopyInto(out *SourcedClaimMapping) {
+ *out = *in
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SourcedClaimMapping.
+func (in *SourcedClaimMapping) DeepCopy() *SourcedClaimMapping {
+ if in == nil {
+ return nil
+ }
+ out := new(SourcedClaimMapping)
+ in.DeepCopyInto(out)
+ return out
+}
+
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *Storage) DeepCopyInto(out *Storage) {
*out = *in
@@ -6245,6 +6530,11 @@ func (in *TLSProfileSpec) DeepCopyInto(out *TLSProfileSpec) {
*out = make([]string, len(*in))
copy(*out, *in)
}
+ if in.Groups != nil {
+ in, out := &in.Groups, &out.Groups
+ *out = make([]TLSGroup, len(*in))
+ copy(*out, *in)
+ }
return
}
@@ -6901,6 +7191,107 @@ func (in *VSpherePlatformVCenterSpec) DeepCopy() *VSpherePlatformVCenterSpec {
return out
}
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *VaultAppRoleAuthentication) DeepCopyInto(out *VaultAppRoleAuthentication) {
+ *out = *in
+ out.Secret = in.Secret
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VaultAppRoleAuthentication.
+func (in *VaultAppRoleAuthentication) DeepCopy() *VaultAppRoleAuthentication {
+ if in == nil {
+ return nil
+ }
+ out := new(VaultAppRoleAuthentication)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *VaultAuthentication) DeepCopyInto(out *VaultAuthentication) {
+ *out = *in
+ out.AppRole = in.AppRole
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VaultAuthentication.
+func (in *VaultAuthentication) DeepCopy() *VaultAuthentication {
+ if in == nil {
+ return nil
+ }
+ out := new(VaultAuthentication)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *VaultConfigMapReference) DeepCopyInto(out *VaultConfigMapReference) {
+ *out = *in
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VaultConfigMapReference.
+func (in *VaultConfigMapReference) DeepCopy() *VaultConfigMapReference {
+ if in == nil {
+ return nil
+ }
+ out := new(VaultConfigMapReference)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *VaultKMSPluginConfig) DeepCopyInto(out *VaultKMSPluginConfig) {
+ *out = *in
+ out.TLS = in.TLS
+ out.Authentication = in.Authentication
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VaultKMSPluginConfig.
+func (in *VaultKMSPluginConfig) DeepCopy() *VaultKMSPluginConfig {
+ if in == nil {
+ return nil
+ }
+ out := new(VaultKMSPluginConfig)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *VaultSecretReference) DeepCopyInto(out *VaultSecretReference) {
+ *out = *in
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VaultSecretReference.
+func (in *VaultSecretReference) DeepCopy() *VaultSecretReference {
+ if in == nil {
+ return nil
+ }
+ out := new(VaultSecretReference)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *VaultTLSConfig) DeepCopyInto(out *VaultTLSConfig) {
+ *out = *in
+ out.CABundle = in.CABundle
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VaultTLSConfig.
+func (in *VaultTLSConfig) DeepCopy() *VaultTLSConfig {
+ if in == nil {
+ return nil
+ }
+ out := new(VaultTLSConfig)
+ in.DeepCopyInto(out)
+ return out
+}
+
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *WebhookTokenAuthenticator) DeepCopyInto(out *WebhookTokenAuthenticator) {
*out = *in
diff --git a/vendor/github.com/openshift/api/config/v1/zz_generated.featuregated-crd-manifests.yaml b/vendor/github.com/openshift/api/config/v1/zz_generated.featuregated-crd-manifests.yaml
index eb7c485e03..6e9daaae51 100644
--- a/vendor/github.com/openshift/api/config/v1/zz_generated.featuregated-crd-manifests.yaml
+++ b/vendor/github.com/openshift/api/config/v1/zz_generated.featuregated-crd-manifests.yaml
@@ -7,7 +7,8 @@ apiservers.config.openshift.io:
Category: ""
FeatureGates:
- KMSEncryption
- - KMSEncryptionProvider
+ - TLSAdherence
+ - TLSGroupPreferences
FilenameOperatorName: config-operator
FilenameOperatorOrdering: "01"
FilenameRunLevel: "0000_10"
@@ -31,6 +32,7 @@ authentications.config.openshift.io:
Category: ""
FeatureGates:
- ExternalOIDC
+ - ExternalOIDCExternalClaimsSourcing
- ExternalOIDCWithUIDAndExtraClaimMappings
- ExternalOIDCWithUpstreamParity
FilenameOperatorName: config-operator
@@ -68,6 +70,29 @@ builds.config.openshift.io:
TopLevelFeatureGates: []
Version: v1
+criocredentialproviderconfigs.config.openshift.io:
+ Annotations: {}
+ ApprovedPRNumber: https://github.com/openshift/api/pull/2725
+ CRDName: criocredentialproviderconfigs.config.openshift.io
+ Capability: ""
+ Category: ""
+ FeatureGates:
+ - CRIOCredentialProviderConfig
+ FilenameOperatorName: config-operator
+ FilenameOperatorOrdering: "01"
+ FilenameRunLevel: "0000_10"
+ GroupName: config.openshift.io
+ HasStatus: true
+ KindName: CRIOCredentialProviderConfig
+ Labels: {}
+ PluralName: criocredentialproviderconfigs
+ PrinterColumns: []
+ Scope: Cluster
+ ShortNames: null
+ TopLevelFeatureGates:
+ - CRIOCredentialProviderConfig
+ Version: v1
+
clusterimagepolicies.config.openshift.io:
Annotations: {}
ApprovedPRNumber: https://github.com/openshift/api/pull/2310
@@ -143,7 +168,11 @@ clusterversions.config.openshift.io:
Capability: ""
Category: ""
FeatureGates:
+ - CRDCompatibilityRequirementOperator
+ - CRDCompatibilityRequirementOperator+ClusterAPIMachineManagement
+ - ClusterAPIMachineManagement
- ClusterUpdateAcceptRisks
+ - ClusterUpdatePreflight
- ImageStreamImportMode
- SignatureStores
FilenameOperatorName: cluster-version-operator
@@ -204,7 +233,8 @@ dnses.config.openshift.io:
CRDName: dnses.config.openshift.io
Capability: ""
Category: ""
- FeatureGates: []
+ FeatureGates:
+ - AWSEuropeanSovereignCloudInstall
FilenameOperatorName: config-operator
FilenameOperatorOrdering: "01"
FilenameRunLevel: "0000_10"
@@ -366,17 +396,17 @@ infrastructures.config.openshift.io:
FeatureGates:
- AWSClusterHostedDNSInstall
- AWSDualStackInstall
- - AzureClusterHostedDNSInstall
- AzureDualStackInstall
+ - BGPBasedVIPManagement
- DualReplica
- DyanmicServiceEndpointIBMCloud
- - GCPClusterHostedDNSInstall
- - HighlyAvailableArbiter
- - HighlyAvailableArbiter+DualReplica
+ - GCPSovereignCloudInstall
+ - MutableTopology
- NutanixMultiSubnets
- OnPremDNSRecords
- VSphereHostVMGroupZonal
- VSphereMultiNetworks
+ - VSphereMultiVCenterDay2
FilenameOperatorName: config-operator
FilenameOperatorOrdering: "01"
FilenameRunLevel: "0000_10"
@@ -398,7 +428,8 @@ ingresses.config.openshift.io:
CRDName: ingresses.config.openshift.io
Capability: ""
Category: ""
- FeatureGates: []
+ FeatureGates:
+ - IngressComponentRouteLabels
FilenameOperatorName: config-operator
FilenameOperatorOrdering: "01"
FilenameRunLevel: "0000_10"
@@ -443,7 +474,8 @@ networks.config.openshift.io:
CRDName: networks.config.openshift.io
Capability: ""
Category: ""
- FeatureGates: []
+ FeatureGates:
+ - NetworkObservabilityInstall
FilenameOperatorName: config-operator
FilenameOperatorOrdering: "01"
FilenameRunLevel: "0000_10"
diff --git a/vendor/github.com/openshift/api/config/v1/zz_generated.model_name.go b/vendor/github.com/openshift/api/config/v1/zz_generated.model_name.go
new file mode 100644
index 0000000000..043c03ef5e
--- /dev/null
+++ b/vendor/github.com/openshift/api/config/v1/zz_generated.model_name.go
@@ -0,0 +1,1566 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in APIServer) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.APIServer"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in APIServerEncryption) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.APIServerEncryption"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in APIServerList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.APIServerList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in APIServerNamedServingCert) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.APIServerNamedServingCert"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in APIServerServingCerts) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.APIServerServingCerts"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in APIServerSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.APIServerSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in APIServerStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.APIServerStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AWSDNSSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.AWSDNSSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AWSIngressSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.AWSIngressSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AWSPlatformSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.AWSPlatformSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AWSPlatformStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.AWSPlatformStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AWSResourceTag) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.AWSResourceTag"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AWSServiceEndpoint) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.AWSServiceEndpoint"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AcceptRisk) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.AcceptRisk"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AdmissionConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.AdmissionConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AdmissionPluginConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.AdmissionPluginConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AlibabaCloudPlatformSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.AlibabaCloudPlatformSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AlibabaCloudPlatformStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.AlibabaCloudPlatformStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AlibabaCloudResourceTag) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.AlibabaCloudResourceTag"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Audit) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.Audit"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AuditConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.AuditConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AuditCustomRule) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.AuditCustomRule"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Authentication) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.Authentication"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AuthenticationList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.AuthenticationList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AuthenticationSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.AuthenticationSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AuthenticationStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.AuthenticationStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AzurePlatformSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.AzurePlatformSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AzurePlatformStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.AzurePlatformStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AzureResourceTag) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.AzureResourceTag"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BareMetalPlatformLoadBalancer) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.BareMetalPlatformLoadBalancer"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BareMetalPlatformSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.BareMetalPlatformSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BareMetalPlatformStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.BareMetalPlatformStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BasicAuthIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.BasicAuthIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Build) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.Build"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildDefaults) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.BuildDefaults"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.BuildList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildOverrides) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.BuildOverrides"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.BuildSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CRIOCredentialProviderConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.CRIOCredentialProviderConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CRIOCredentialProviderConfigList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.CRIOCredentialProviderConfigList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CRIOCredentialProviderConfigSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.CRIOCredentialProviderConfigSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CRIOCredentialProviderConfigStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.CRIOCredentialProviderConfigStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CertInfo) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.CertInfo"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClientConnectionOverrides) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ClientConnectionOverrides"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClientCredentialConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ClientCredentialConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClientSecretSecretReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ClientSecretSecretReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CloudControllerManagerStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.CloudControllerManagerStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CloudLoadBalancerConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.CloudLoadBalancerConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CloudLoadBalancerIPs) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.CloudLoadBalancerIPs"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterCondition) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ClusterCondition"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterImagePolicy) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ClusterImagePolicy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterImagePolicyList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ClusterImagePolicyList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterImagePolicySpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ClusterImagePolicySpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterImagePolicyStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ClusterImagePolicyStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterNetworkEntry) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ClusterNetworkEntry"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterOperator) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ClusterOperator"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterOperatorList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ClusterOperatorList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterOperatorSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ClusterOperatorSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterOperatorStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ClusterOperatorStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterOperatorStatusCondition) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ClusterOperatorStatusCondition"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterVersion) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ClusterVersion"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterVersionCapabilitiesSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ClusterVersionCapabilitiesSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterVersionCapabilitiesStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ClusterVersionCapabilitiesStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterVersionList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ClusterVersionList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterVersionSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ClusterVersionSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterVersionStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ClusterVersionStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ComponentOverride) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ComponentOverride"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ComponentRouteSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ComponentRouteSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ComponentRouteStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ComponentRouteStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConditionalUpdate) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ConditionalUpdate"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConditionalUpdateRisk) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ConditionalUpdateRisk"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConfigMapFileReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ConfigMapFileReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConfigMapNameReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ConfigMapNameReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Console) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.Console"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleAuthentication) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ConsoleAuthentication"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ConsoleList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ConsoleSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ConsoleStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Custom) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.Custom"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CustomFeatureGates) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.CustomFeatureGates"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CustomTLSProfile) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.CustomTLSProfile"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DNS) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.DNS"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DNSList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.DNSList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DNSPlatformSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.DNSPlatformSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DNSSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.DNSSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DNSStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.DNSStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DNSZone) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.DNSZone"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DelegatedAuthentication) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.DelegatedAuthentication"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DelegatedAuthorization) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.DelegatedAuthorization"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DeprecatedWebhookTokenAuthenticator) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.DeprecatedWebhookTokenAuthenticator"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EquinixMetalPlatformSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.EquinixMetalPlatformSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EquinixMetalPlatformStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.EquinixMetalPlatformStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EtcdConnectionInfo) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.EtcdConnectionInfo"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EtcdStorageConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.EtcdStorageConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ExternalClaimsSource) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ExternalClaimsSource"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ExternalIPConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ExternalIPConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ExternalIPPolicy) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ExternalIPPolicy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ExternalPlatformSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ExternalPlatformSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ExternalPlatformStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ExternalPlatformStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ExternalSourceAuthentication) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ExternalSourceAuthentication"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ExternalSourceCertificateAuthorityConfigMapReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ExternalSourceCertificateAuthorityConfigMapReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ExternalSourcePredicate) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ExternalSourcePredicate"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ExternalSourceTLS) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ExternalSourceTLS"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ExtraMapping) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ExtraMapping"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in FeatureGate) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.FeatureGate"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in FeatureGateAttributes) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.FeatureGateAttributes"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in FeatureGateDetails) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.FeatureGateDetails"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in FeatureGateList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.FeatureGateList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in FeatureGateSelection) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.FeatureGateSelection"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in FeatureGateSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.FeatureGateSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in FeatureGateStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.FeatureGateStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in FeatureGateTests) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.FeatureGateTests"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GCPPlatformSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.GCPPlatformSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GCPPlatformStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.GCPPlatformStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GCPResourceLabel) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.GCPResourceLabel"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GCPResourceTag) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.GCPResourceTag"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GatherConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.GatherConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GathererConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.GathererConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Gatherers) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.Gatherers"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GenericAPIServerConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.GenericAPIServerConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GenericControllerConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.GenericControllerConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GitHubIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.GitHubIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GitLabIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.GitLabIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GoogleIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.GoogleIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in HTPasswdIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.HTPasswdIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in HTTPServingInfo) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.HTTPServingInfo"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in HubSource) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.HubSource"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in HubSourceStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.HubSourceStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IBMCloudPlatformSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.IBMCloudPlatformSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IBMCloudPlatformStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.IBMCloudPlatformStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IBMCloudServiceEndpoint) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.IBMCloudServiceEndpoint"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.IdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IdentityProviderConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.IdentityProviderConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Image) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.Image"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageContentPolicy) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ImageContentPolicy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageContentPolicyList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ImageContentPolicyList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageContentPolicySpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ImageContentPolicySpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageDigestMirrorSet) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ImageDigestMirrorSet"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageDigestMirrorSetList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ImageDigestMirrorSetList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageDigestMirrorSetSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ImageDigestMirrorSetSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageDigestMirrorSetStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ImageDigestMirrorSetStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageDigestMirrors) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ImageDigestMirrors"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageLabel) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ImageLabel"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ImageList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImagePolicy) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ImagePolicy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImagePolicyFulcioCAWithRekorRootOfTrust) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ImagePolicyFulcioCAWithRekorRootOfTrust"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImagePolicyList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ImagePolicyList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImagePolicyPKIRootOfTrust) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ImagePolicyPKIRootOfTrust"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImagePolicyPublicKeyRootOfTrust) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ImagePolicyPublicKeyRootOfTrust"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImagePolicySpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ImagePolicySpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImagePolicyStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ImagePolicyStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageSigstoreVerificationPolicy) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ImageSigstoreVerificationPolicy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ImageSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ImageStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageTagMirrorSet) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ImageTagMirrorSet"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageTagMirrorSetList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ImageTagMirrorSetList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageTagMirrorSetSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ImageTagMirrorSetSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageTagMirrorSetStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ImageTagMirrorSetStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageTagMirrors) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ImageTagMirrors"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Infrastructure) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.Infrastructure"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in InfrastructureList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.InfrastructureList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in InfrastructureSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.InfrastructureSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in InfrastructureStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.InfrastructureStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Ingress) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.Ingress"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IngressList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.IngressList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IngressPlatformSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.IngressPlatformSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IngressSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.IngressSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IngressStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.IngressStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in InsightsDataGather) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.InsightsDataGather"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in InsightsDataGatherList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.InsightsDataGatherList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in InsightsDataGatherSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.InsightsDataGatherSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IntermediateTLSProfile) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.IntermediateTLSProfile"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KMSPluginConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.KMSPluginConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KeystoneIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.KeystoneIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KubeClientConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.KubeClientConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KubevirtPlatformSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.KubevirtPlatformSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KubevirtPlatformStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.KubevirtPlatformStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in LDAPAttributeMapping) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.LDAPAttributeMapping"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in LDAPIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.LDAPIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in LeaderElection) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.LeaderElection"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in LoadBalancer) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.LoadBalancer"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MTUMigration) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.MTUMigration"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MTUMigrationValues) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.MTUMigrationValues"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MaxAgePolicy) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.MaxAgePolicy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ModernTLSProfile) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ModernTLSProfile"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NamedCertificate) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.NamedCertificate"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Network) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.Network"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NetworkDiagnostics) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.NetworkDiagnostics"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NetworkDiagnosticsSourcePlacement) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.NetworkDiagnosticsSourcePlacement"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NetworkDiagnosticsTargetPlacement) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.NetworkDiagnosticsTargetPlacement"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NetworkList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.NetworkList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NetworkMigration) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.NetworkMigration"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NetworkObservabilitySpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.NetworkObservabilitySpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NetworkSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.NetworkSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NetworkStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.NetworkStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Node) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.Node"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.NodeList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.NodeSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.NodeStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NutanixFailureDomain) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.NutanixFailureDomain"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NutanixPlatformLoadBalancer) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.NutanixPlatformLoadBalancer"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NutanixPlatformSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.NutanixPlatformSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NutanixPlatformStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.NutanixPlatformStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NutanixPrismElementEndpoint) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.NutanixPrismElementEndpoint"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NutanixPrismEndpoint) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.NutanixPrismEndpoint"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NutanixResourceIdentifier) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.NutanixResourceIdentifier"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OAuth) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.OAuth"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OAuthList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.OAuthList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OAuthRemoteConnectionInfo) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.OAuthRemoteConnectionInfo"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OAuthSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.OAuthSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OAuthStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.OAuthStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OAuthTemplates) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.OAuthTemplates"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OIDCClientConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.OIDCClientConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OIDCClientReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.OIDCClientReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OIDCClientStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.OIDCClientStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OIDCProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.OIDCProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ObjectReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ObjectReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OldTLSProfile) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.OldTLSProfile"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OpenIDClaims) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.OpenIDClaims"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OpenIDIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.OpenIDIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OpenStackPlatformLoadBalancer) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.OpenStackPlatformLoadBalancer"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OpenStackPlatformSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.OpenStackPlatformSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OpenStackPlatformStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.OpenStackPlatformStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OperandVersion) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.OperandVersion"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OperatorHub) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.OperatorHub"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OperatorHubList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.OperatorHubList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OperatorHubSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.OperatorHubSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OperatorHubStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.OperatorHubStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OvirtPlatformLoadBalancer) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.OvirtPlatformLoadBalancer"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OvirtPlatformSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.OvirtPlatformSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OvirtPlatformStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.OvirtPlatformStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PKICertificateSubject) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.PKICertificateSubject"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PersistentVolumeClaimReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.PersistentVolumeClaimReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PersistentVolumeConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.PersistentVolumeConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PlatformSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.PlatformSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PlatformStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.PlatformStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PolicyFulcioSubject) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.PolicyFulcioSubject"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PolicyIdentity) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.PolicyIdentity"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PolicyMatchExactRepository) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.PolicyMatchExactRepository"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PolicyMatchRemapIdentity) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.PolicyMatchRemapIdentity"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PolicyRootOfTrust) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.PolicyRootOfTrust"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PowerVSPlatformSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.PowerVSPlatformSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PowerVSPlatformStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.PowerVSPlatformStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PowerVSServiceEndpoint) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.PowerVSServiceEndpoint"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PrefixedClaimMapping) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.PrefixedClaimMapping"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ProfileCustomizations) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ProfileCustomizations"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Project) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.Project"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ProjectList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ProjectList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ProjectSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ProjectSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ProjectStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ProjectStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PromQLClusterCondition) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.PromQLClusterCondition"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Proxy) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.Proxy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ProxyList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ProxyList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ProxySpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ProxySpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ProxyStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ProxyStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RegistryLocation) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.RegistryLocation"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RegistrySources) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.RegistrySources"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Release) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.Release"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RemoteConnectionInfo) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.RemoteConnectionInfo"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RepositoryDigestMirrors) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.RepositoryDigestMirrors"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RequestHeaderIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.RequestHeaderIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RequiredHSTSPolicy) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.RequiredHSTSPolicy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Scheduler) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.Scheduler"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SchedulerList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.SchedulerList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SchedulerSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.SchedulerSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SchedulerStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.SchedulerStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SecretNameReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.SecretNameReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ServingInfo) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.ServingInfo"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SignatureStore) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.SignatureStore"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SourceURL) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.SourceURL"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SourcedClaimMapping) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.SourcedClaimMapping"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Storage) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.Storage"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in StringSource) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.StringSource"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in StringSourceSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.StringSourceSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TLSProfileSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.TLSProfileSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TLSSecurityProfile) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.TLSSecurityProfile"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TemplateReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.TemplateReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TestDetails) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.TestDetails"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TestReporting) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.TestReporting"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TestReportingSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.TestReportingSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TestReportingStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.TestReportingStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TokenClaimMapping) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.TokenClaimMapping"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TokenClaimMappings) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.TokenClaimMappings"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TokenClaimOrExpressionMapping) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.TokenClaimOrExpressionMapping"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TokenClaimValidationCELRule) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.TokenClaimValidationCELRule"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TokenClaimValidationRule) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.TokenClaimValidationRule"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TokenConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.TokenConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TokenIssuer) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.TokenIssuer"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TokenRequiredClaim) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.TokenRequiredClaim"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TokenUserValidationRule) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.TokenUserValidationRule"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Update) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.Update"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in UpdateHistory) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.UpdateHistory"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in UsernameClaimMapping) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.UsernameClaimMapping"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in UsernamePrefix) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.UsernamePrefix"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in VSphereFailureDomainHostGroup) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.VSphereFailureDomainHostGroup"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in VSphereFailureDomainRegionAffinity) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.VSphereFailureDomainRegionAffinity"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in VSphereFailureDomainZoneAffinity) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.VSphereFailureDomainZoneAffinity"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in VSpherePlatformFailureDomainSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.VSpherePlatformFailureDomainSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in VSpherePlatformLoadBalancer) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.VSpherePlatformLoadBalancer"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in VSpherePlatformNodeNetworking) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.VSpherePlatformNodeNetworking"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in VSpherePlatformNodeNetworkingSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.VSpherePlatformNodeNetworkingSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in VSpherePlatformSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.VSpherePlatformSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in VSpherePlatformStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.VSpherePlatformStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in VSpherePlatformTopology) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.VSpherePlatformTopology"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in VSpherePlatformVCenterSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.VSpherePlatformVCenterSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in VaultAppRoleAuthentication) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.VaultAppRoleAuthentication"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in VaultAuthentication) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.VaultAuthentication"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in VaultConfigMapReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.VaultConfigMapReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in VaultKMSPluginConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.VaultKMSPluginConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in VaultSecretReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.VaultSecretReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in VaultTLSConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.VaultTLSConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in WebhookTokenAuthenticator) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1.WebhookTokenAuthenticator"
+}
diff --git a/vendor/github.com/openshift/api/config/v1/zz_generated.swagger_doc_generated.go b/vendor/github.com/openshift/api/config/v1/zz_generated.swagger_doc_generated.go
index 621dbbebdf..0519119af4 100644
--- a/vendor/github.com/openshift/api/config/v1/zz_generated.swagger_doc_generated.go
+++ b/vendor/github.com/openshift/api/config/v1/zz_generated.swagger_doc_generated.go
@@ -137,7 +137,7 @@ func (GenericAPIServerConfig) SwaggerDoc() map[string]string {
}
var map_GenericControllerConfig = map[string]string{
- "": "GenericControllerConfig provides information to configure a controller",
+ "": "GenericControllerConfig provides information to configure a controller\n\nCompatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer).",
"servingInfo": "servingInfo is the HTTP serving information for the controller's endpoints",
"leaderElection": "leaderElection provides information to elect a leader. Only override this if you have a specific need",
"authentication": "authentication allows configuration of authentication for the endpoints",
@@ -319,6 +319,7 @@ var map_APIServerSpec = map[string]string{
"additionalCORSAllowedOrigins": "additionalCORSAllowedOrigins lists additional, user-defined regular expressions describing hosts for which the API server allows access using the CORS headers. This may be needed to access the API and the integrated OAuth server from JavaScript applications. The values are regular expressions that correspond to the Golang regular expression language.",
"encryption": "encryption allows the configuration of encryption of resources at the datastore layer.",
"tlsSecurityProfile": "tlsSecurityProfile specifies settings for TLS connections for externally exposed servers.\n\nWhen omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The current default is the Intermediate profile.",
+ "tlsAdherence": "tlsAdherence controls if components in the cluster adhere to the TLS security profile configured on this APIServer resource.\n\nValid values are \"LegacyAdheringComponentsOnly\" and \"StrictAllComponents\".\n\nWhen set to \"LegacyAdheringComponentsOnly\", components that already honor the cluster-wide TLS profile continue to do so. Components that do not already honor it continue to use their individual TLS configurations.\n\nWhen set to \"StrictAllComponents\", all components must honor the configured TLS profile unless they have a component-specific TLS configuration that overrides it. This mode is recommended for security-conscious deployments and is required for certain compliance frameworks.\n\nNote: Some components such as Kubelet and IngressController have their own dedicated TLS configuration mechanisms via KubeletConfig and IngressController CRs respectively. When these component-specific TLS configurations are set, they take precedence over the cluster-wide tlsSecurityProfile. When not set, these components fall back to the cluster-wide default.\n\nComponents that encounter an unknown value for tlsAdherence should treat it as \"StrictAllComponents\" and log a warning to ensure forward compatibility while defaulting to the more secure behavior.\n\nThis field is optional. When omitted, this means the user has no opinion and the platform is left to choose reasonable defaults. These defaults are subject to change over time. The current default is LegacyAdheringComponentsOnly.\n\nOnce set, this field may be changed to a different value, but may not be removed.",
"audit": "audit specifies the settings for audit configuration to be applied to all OpenShift-provided API servers in the cluster.",
}
@@ -387,6 +388,28 @@ func (AuthenticationStatus) SwaggerDoc() map[string]string {
return map_AuthenticationStatus
}
+var map_ClientCredentialConfig = map[string]string{
+ "": "ClientCredentialConfig configures the client credentials and token endpoint to use to get an access token via the OAuth2 client credentials grant flow.",
+ "clientID": "clientID is a required client identifier to use during the OAuth2 client credentials flow. clientID must be at least 1 character in length, must not exceed 256 characters in length, and must only contain printable ASCII characters.",
+ "clientSecret": "clientSecret is a required reference to a Secret in the openshift-config namespace to be used as the client secret during the OAuth2 client credentials flow.\n\nThe key 'client-secret' is used to locate the client secret data in the Secret.",
+ "tokenEndpoint": "tokenEndpoint is a required URL to query for an access token using the client credential OAuth2 flow. tokenEndpoint must be at least 1 character in length and must not exceed 2048 characters in length. tokenEndpoint must be a valid HTTPS URL. tokenEndpoint must have a host and a path. tokenEndpoint must not contain query parameters, fragments, or user information (e.g., \"user:password@host\").",
+ "scopes": "scopes is an optional list of OAuth2 scopes to request when obtaining an access token.\n\nIf not specified, the token endpoint's default scopes will be used.\n\nWhen specified, there must be at least 1 entry and must not exceed 16 entries. Each entry must be at least 1 character in length and must not exceed 256 characters in length. Each entry must only contain printable ASCII characters, excluding spaces, double quotes and backslashes. Entries must be unique.",
+ "tls": "tls is an optional field that allows configuring the TLS settings used to interact with the identity provider as an OAuth2 client.\n\nWhen omitted, system default TLS settings will be used for the OAuth2 client.",
+}
+
+func (ClientCredentialConfig) SwaggerDoc() map[string]string {
+ return map_ClientCredentialConfig
+}
+
+var map_ClientSecretSecretReference = map[string]string{
+ "": "ClientSecretSecretReference is a reference to a Secret in the openshift-config namespace that should be used for configuring the client secret to be used when sourcing claims from external sources with the client credential authentication flow.",
+ "name": "name is the required name of the Secret that exists in the openshift-config namespace.\n\nIt must be at least 1 character in length, must not exceed 253 characters in length, must start and end with a lowercase alphanumeric character, and must only contain lowercase alphanumeric characters, '-' or '.'.",
+}
+
+func (ClientSecretSecretReference) SwaggerDoc() map[string]string {
+ return map_ClientSecretSecretReference
+}
+
var map_DeprecatedWebhookTokenAuthenticator = map[string]string{
"": "deprecatedWebhookTokenAuthenticator holds the necessary configuration options for a remote token authenticator. It's the same as WebhookTokenAuthenticator but it's missing the 'required' validation on KubeConfig field.",
"kubeConfig": "kubeConfig contains kube config file data which describes how to access the remote webhook service. For further details, see: https://kubernetes.io/docs/reference/access-authn-authz/authentication/#webhook-token-authentication The key \"kubeConfig\" is used to locate the data. If the secret or expected key is not found, the webhook is not honored. If the specified kube config data is not valid, the webhook is not honored. The namespace for this secret is determined by the point of use.",
@@ -396,6 +419,56 @@ func (DeprecatedWebhookTokenAuthenticator) SwaggerDoc() map[string]string {
return map_DeprecatedWebhookTokenAuthenticator
}
+var map_ExternalClaimsSource = map[string]string{
+ "": "ExternalClaimsSource provides the configuration for a single external claim source.",
+ "authentication": "authentication is an optional field that configures how the apiserver authenticates with an external claims source. When not specified, anonymous authentication is used which means no 'Authorization' header is sent in the HTTP request to fetch the external claims.",
+ "tls": "tls is an optional field that configures the http client TLS settings when fetching external claims from this source.\n\nWhen omitted, system default TLS settings will be used for fetching claims from the external source.",
+ "url": "url is a required configuration of the URL for which the external claims are located.",
+ "mappings": "mappings is a required list of the claim and response handling expression pairs that produces the claims from the external source. mappings must have at least 1 entry and must not exceed 16 entries. Entries must have a unique name across all external claim sources.",
+ "predicates": "predicates is an optional list of constraints in which claims should attempt to be fetched from this external source.\n\nWhen omitted, claims are always fetched from this external source.\n\nWhen specified, all predicates must evaluate to 'true' before claims are attempted to be fetched from this external source. predicates must have at least 1 entry and must not exceed 16 entries. Entries must have unique expressions.",
+}
+
+func (ExternalClaimsSource) SwaggerDoc() map[string]string {
+ return map_ExternalClaimsSource
+}
+
+var map_ExternalSourceAuthentication = map[string]string{
+ "": "ExternalSourceAuthentication configures how the apiserver should attempt to authenticate with an external claims source.",
+ "type": "type is a required field that sets the type of authentication method used by the authenticator when fetching external claims.\n\nAllowed values are 'RequestProvidedToken' and 'ClientCredential'.\n\nWhen set to 'RequestProvidedToken', the authenticator will use the token provided to the kube-apiserver as part of the request to authenticate with the external claims source.\n\nWhen set to 'ClientCredential', the authenticator will use the configured client-id, client-secret, and token endpoint to fetch an access token using the OAuth2 client credentials grant flow. The fetched access token will then be used to authenticate with the external claims source.",
+ "clientCredential": "clientCredential configures the client credentials and token endpoint to use to get an access token. clientCredential is required when type is 'ClientCredential', and forbidden otherwise.",
+}
+
+func (ExternalSourceAuthentication) SwaggerDoc() map[string]string {
+ return map_ExternalSourceAuthentication
+}
+
+var map_ExternalSourceCertificateAuthorityConfigMapReference = map[string]string{
+ "": "ExternalSourceCertificateAuthorityConfigMapReference is a reference to a ConfigMap in the openshift-config namespace that should be used for configuring the certificate authority to be used when sourcing claims from external sources.",
+ "name": "name is the required name of the ConfigMap that exists in the openshift-config namespace. The key \"ca-bundle.crt\" must be present and must contain the CA certificate to be used to verify the external source's TLS certificate.\n\nIt must be at least 1 character in length, must not exceed 253 characters in length, must start and end with a lowercase alphanumeric character, and must only contain lowercase alphanumeric characters, '-' or '.'.",
+}
+
+func (ExternalSourceCertificateAuthorityConfigMapReference) SwaggerDoc() map[string]string {
+ return map_ExternalSourceCertificateAuthorityConfigMapReference
+}
+
+var map_ExternalSourcePredicate = map[string]string{
+ "": "ExternalSourcePredicate configures a singular condition that must return true before the external source is queried to retrieve external claims.",
+ "expression": "expression is a required CEL expression that is used to determine whether or not an external source should be used to fetch external claims.\n\nThe expression must return a boolean value, where true means that the source should be consulted and false means that it should not.\n\nClaims from the token used for the request to the kube-apiserver are made available via the `claims` variable.\n\nThe contents of the `claims` variable varies based on the claims that are present in the token being validated. It is the responsibility of those configuring this field to understand what claims the identity provider includes when issuing tokens.\n\nexpression must be at least 1 character and must not exceed 1024 characters in length.",
+}
+
+func (ExternalSourcePredicate) SwaggerDoc() map[string]string {
+ return map_ExternalSourcePredicate
+}
+
+var map_ExternalSourceTLS = map[string]string{
+ "": "ExternalSourceTLS configures the TLS options that the apiserver uses as a client when making a request to the external claim source.",
+ "certificateAuthority": "certificateAuthority is a required reference to a ConfigMap in the openshift-config namespace that contains the CA certificate to use to validate TLS connections with the external claims source. The key \"ca-bundle.crt\" must be present in the referenced ConfigMap and must contain the CA certificate to be used to verify the external source's TLS certificate.",
+}
+
+func (ExternalSourceTLS) SwaggerDoc() map[string]string {
+ return map_ExternalSourceTLS
+}
+
var map_ExtraMapping = map[string]string{
"": "ExtraMapping allows specifying a key and CEL expression to evaluate the keys' value. It is used to create additional mappings and attributes added to a cluster identity from a provided authentication token.",
"key": "key is a required field that specifies the string to use as the extra attribute key.\n\nkey must be a domain-prefix path (e.g 'example.org/foo'). key must not exceed 510 characters in length. key must contain the '/' character, separating the domain and path characters. key must not be empty.\n\nThe domain portion of the key (string of characters prior to the '/') must be a valid RFC1123 subdomain. It must not exceed 253 characters in length. It must start and end with an alphanumeric character. It must only contain lower case alphanumeric characters and '-' or '.'. It must not use the reserved domains, or be subdomains of, \"kubernetes.io\", \"k8s.io\", and \"openshift.io\".\n\nThe path portion of the key (string of characters after the '/') must not be empty and must consist of at least one alphanumeric character, percent-encoded octets, '-', '.', '_', '~', '!', '$', '&', ''', '(', ')', '*', '+', ',', ';', '=', and ':'. It must not exceed 256 characters in length.",
@@ -444,12 +517,13 @@ func (OIDCClientStatus) SwaggerDoc() map[string]string {
}
var map_OIDCProvider = map[string]string{
- "name": "name is a required field that configures the unique human-readable identifier associated with the identity provider. It is used to distinguish between multiple identity providers and has no impact on token validation or authentication mechanics.\n\nname must not be an empty string (\"\").",
- "issuer": "issuer is a required field that configures how the platform interacts with the identity provider and how tokens issued from the identity provider are evaluated by the Kubernetes API server.",
- "oidcClients": "oidcClients is an optional field that configures how on-cluster, platform clients should request tokens from the identity provider. oidcClients must not exceed 20 entries and entries must have unique namespace/name pairs.",
- "claimMappings": "claimMappings is a required field that configures the rules to be used by the Kubernetes API server for translating claims in a JWT token, issued by the identity provider, to a cluster identity.",
- "claimValidationRules": "claimValidationRules is an optional field that configures the rules to be used by the Kubernetes API server for validating the claims in a JWT token issued by the identity provider.\n\nValidation rules are joined via an AND operation.",
- "userValidationRules": "userValidationRules is an optional field that configures the set of rules used to validate the cluster user identity that was constructed via mapping token claims to user identity attributes. Rules are CEL expressions that must evaluate to 'true' for authentication to succeed. If any rule in the chain of rules evaluates to 'false', authentication will fail. When specified, at least one rule must be specified and no more than 64 rules may be specified.",
+ "name": "name is a required field that configures the unique human-readable identifier associated with the identity provider. It is used to distinguish between multiple identity providers and has no impact on token validation or authentication mechanics.\n\nname must not be an empty string (\"\").",
+ "issuer": "issuer is a required field that configures how the platform interacts with the identity provider and how tokens issued from the identity provider are evaluated by the Kubernetes API server.",
+ "oidcClients": "oidcClients is an optional field that configures how on-cluster, platform clients should request tokens from the identity provider. oidcClients must not exceed 20 entries and entries must have unique namespace/name pairs.",
+ "claimMappings": "claimMappings is a required field that configures the rules to be used by the Kubernetes API server for translating claims in a JWT token, issued by the identity provider, to a cluster identity.",
+ "claimValidationRules": "claimValidationRules is an optional field that configures the rules to be used by the Kubernetes API server for validating the claims in a JWT token issued by the identity provider.\n\nValidation rules are joined via an AND operation.",
+ "userValidationRules": "userValidationRules is an optional field that configures the set of rules used to validate the cluster user identity that was constructed via mapping token claims to user identity attributes. Rules are CEL expressions that must evaluate to 'true' for authentication to succeed. If any rule in the chain of rules evaluates to 'false', authentication will fail. When specified, at least one rule must be specified and no more than 64 rules may be specified.",
+ "externalClaimsSources": "externalClaimsSources is an optional field that can be used to configure sources, external to the token provided in a request, in which claims should be fetched from and made available to the claim mapping process that is used to build the identity of a token holder.\n\nFor example, fetching additional user metadata from an OIDC provider's UserInfo endpoint.\n\nWhen not specified, only claims present in the token itself will be available in the claim mapping process.\n\nWhen specified, at least one external claim source must be specified and no more than 5 sources may be specified. All external claim sources must have unique claim mappings. When an external source responds and resolves additional claims successfully, they will be made available as claims during the claim mapping process. Externally sourced claims with the same name as a claim existing within the token will overwrite the claim data from the token with the externally sourced information. If an external source does not respond, responds with an error, or the additional claim data cannot be resolved from the response successfully it will not be included in the claim data passed to the claim mapping process.",
}
func (OIDCProvider) SwaggerDoc() map[string]string {
@@ -458,13 +532,33 @@ func (OIDCProvider) SwaggerDoc() map[string]string {
var map_PrefixedClaimMapping = map[string]string{
"": "PrefixedClaimMapping configures a claim mapping that allows for an optional prefix.",
- "prefix": "prefix is an optional field that configures the prefix that will be applied to the cluster identity attribute during the process of mapping JWT claims to cluster identity attributes.\n\nWhen omitted (\"\"), no prefix is applied to the cluster identity attribute.\n\nExample: if `prefix` is set to \"myoidc:\" and the `claim` in JWT contains an array of strings \"a\", \"b\" and \"c\", the mapping will result in an array of string \"myoidc:a\", \"myoidc:b\" and \"myoidc:c\".",
+ "prefix": "prefix is an optional field that configures the prefix that will be applied to the cluster identity attribute during the process of mapping JWT claims to cluster identity attributes.\n\nWhen omitted or set to an empty string (\"\"), no prefix is applied to the cluster identity attribute. Must not be set to a non-empty value when expression is set.\n\nExample: if `prefix` is set to \"myoidc:\" and the `claim` in JWT contains an array of strings \"a\", \"b\" and \"c\", the mapping will result in an array of string \"myoidc:a\", \"myoidc:b\" and \"myoidc:c\".",
}
func (PrefixedClaimMapping) SwaggerDoc() map[string]string {
return map_PrefixedClaimMapping
}
+var map_SourceURL = map[string]string{
+ "": "SourceURL configures the options used to build the URL that is queried for external claims.",
+ "hostname": "hostname is a required hostname for which the external claims are located.\n\nIt must be a valid DNS subdomain name as per RFC1123.\n\nThis means that it must start and end with a lowercase alphanumeric character, must only consist of lowercase alphanumeric characters, '-', and '.'. hostname may optionally specify a port in the format ':{port}'. If a port is specified it must not exceed 65535.\n\nhostname must be at least 1 character in length. When specifying a port, hostname must not exceed 259 characters in length. When not specifying a port, hostname must not exceed 253 characters in length.",
+ "pathExpression": "pathExpression is a required CEL expression that returns a list of string values used to construct the URL path. Claims from the token used for the request to the kube-apiserver are made available via the `claims` variable. expression must be at least 1 character in length and must not exceed 1024 characters in length.\n\nValues in the returned list will be joined with the hostname using a forward slash (`/`) as a separator. Values in the returned list do not need to include the forward slash. If a forward slash is included in a returned value, it will be encoded as `%2F`.\n\nExample of a static path configuration:\n\n pathExpression: ['realms', 'k8s', 'protocol', 'openid-connect', 'userinfo']\n\nThe above example would resolve to the path: '/realms/k8s/protocol/openid-connect/userinfo'\n\nExample of a dynamic path configuration:\n\n pathExpression: \"['admin', 'realms', 'k8s', 'users'] + [claims.sub] + ['groups']\"\n\nAssuming 'claims.sub' is set to '12345', the above example would resolve to the path: '/admin/realms/k8s/users/12345/groups'",
+}
+
+func (SourceURL) SwaggerDoc() map[string]string {
+ return map_SourceURL
+}
+
+var map_SourcedClaimMapping = map[string]string{
+ "": "SourcedClaimMapping configures the mapping behavior for a single external claim from the response the apiserver received from the external claim source.",
+ "name": "name is a required name of the claim that will be produced and made available during the claim-to-identity mapping process. name must consist of only lowercase alpha characters and underscores ('_'). name must be at least 1 character and must not exceed 256 characters in length.",
+ "expression": "expression is a required CEL expression that will produce a value to be assigned to the claim. The full response body from the request to the external claim source is provided via the `response.body` variable.\n\nThe contents of the `response.body` variable varies based on the response received from the external source. It is the responsibility of those configuring this expression to understand what is returned from the external source.\n\nexpression must be at least 1 character and must not exceed 1024 characters in length.",
+}
+
+func (SourcedClaimMapping) SwaggerDoc() map[string]string {
+ return map_SourcedClaimMapping
+}
+
var map_TokenClaimMapping = map[string]string{
"": "TokenClaimMapping allows specifying a JWT token claim to be used when mapping claims from an authentication token to cluster identities.",
"claim": "claim is an optional field for specifying the JWT token claim that is used in the mapping. The value of this claim will be assigned to the field in which this mapping is associated. claim must not exceed 256 characters in length. When set to the empty string `\"\"`, this means that no named claim should be used for the group mapping. claim is required when the ExternalOIDCWithUpstreamParity feature gate is not enabled.",
@@ -549,7 +643,7 @@ func (TokenUserValidationRule) SwaggerDoc() map[string]string {
var map_UsernameClaimMapping = map[string]string{
"claim": "claim is an optional field that configures the JWT token claim whose value is assigned to the cluster identity field associated with this mapping. claim is required when the ExternalOIDCWithUpstreamParity feature gate is not enabled. When the ExternalOIDCWithUpstreamParity feature gate is enabled, claim must not be set when expression is set.\n\nclaim must not be an empty string (\"\") and must not exceed 256 characters.",
"expression": "expression is an optional CEL expression used to derive the username from JWT claims.\n\nCEL expressions have access to the token claims through a CEL variable, 'claims'.\n\nexpression must be at least 1 character and must not exceed 1024 characters in length. expression must not be set when claim is set.",
- "prefixPolicy": "prefixPolicy is an optional field that configures how a prefix should be applied to the value of the JWT claim specified in the 'claim' field.\n\nAllowed values are 'Prefix', 'NoPrefix', and omitted (not provided or an empty string).\n\nWhen set to 'Prefix', the value specified in the prefix field will be prepended to the value of the JWT claim.\n\nThe prefix field must be set when prefixPolicy is 'Prefix'.\n\nWhen set to 'NoPrefix', no prefix will be prepended to the value of the JWT claim.\n\nWhen omitted, this means no opinion and the platform is left to choose any prefixes that are applied which is subject to change over time. Currently, the platform prepends `{issuerURL}#` to the value of the JWT claim when the claim is not 'email'.\n\nAs an example, consider the following scenario:\n\n `prefix` is unset, `issuerURL` is set to `https://myoidc.tld`,\n the JWT claims include \"username\":\"userA\" and \"email\":\"userA@myoidc.tld\",\n and `claim` is set to:\n - \"username\": the mapped value will be \"https://myoidc.tld#userA\"\n - \"email\": the mapped value will be \"userA@myoidc.tld\"",
+ "prefixPolicy": "prefixPolicy is an optional field that configures how a prefix should be applied to the value of the JWT claim specified in the 'claim' field.\n\nAllowed values are 'Prefix', 'NoPrefix', and omitted (not provided or an empty string).\n\nWhen set to 'Prefix', the value specified in the prefix field will be prepended to the value of the JWT claim. The prefix field must be set when prefixPolicy is 'Prefix'. Must not be set to 'Prefix' when expression is set. When set to 'NoPrefix', no prefix will be prepended to the value of the JWT claim. When omitted, this means no opinion and the platform is left to choose any prefixes that are applied which is subject to change over time. Currently, the platform prepends `{issuerURL}#` to the value of the JWT claim when the claim is not 'email'.\n\nAs an example, consider the following scenario:\n\n `prefix` is unset, `issuerURL` is set to `https://myoidc.tld`,\n the JWT claims include \"username\":\"userA\" and \"email\":\"userA@myoidc.tld\",\n and `claim` is set to:\n - \"username\": the mapped value will be \"https://myoidc.tld#userA\"\n - \"email\": the mapped value will be \"userA@myoidc.tld\"",
"prefix": "prefix configures the prefix that should be prepended to the value of the JWT claim.\n\nprefix must be set when prefixPolicy is set to 'Prefix' and must be unset otherwise.",
}
@@ -917,6 +1011,7 @@ var map_Update = map[string]string{
"image": "image is a container image location that contains the update. image should be used when the desired version does not exist in availableUpdates or history. When image is set, architecture cannot be specified. If both version and image are set, the version extracted from the referenced image must match the specified version.",
"force": "force allows an administrator to update to an image that has failed verification or upgradeable checks that are designed to keep your cluster safe. Only use this if: * you are testing unsigned release images in short-lived test clusters or * you are working around a known bug in the cluster-version\n operator and you have verified the authenticity of the provided\n image yourself.\nThe provided image will run with full administrative access to the cluster. Do not use this flag with images that come from unknown or potentially malicious sources.",
"acceptRisks": "acceptRisks is an optional set of names of conditional update risks that are considered acceptable. A conditional update is performed only if all of its risks are acceptable. This list may contain entries that apply to current, previous or future updates. The entries therefore may not map directly to a risk in .status.conditionalUpdateRisks. acceptRisks must not contain more than 1000 entries. Entries in this list must be unique.",
+ "mode": "mode determines how an update should be processed. The only valid value is \"Preflight\". When omitted, the cluster performs a normal update by applying the specified version or image to the cluster. This is the standard update behavior. When set to \"Preflight\", the cluster runs compatibility checks against the target release without performing an actual update. Compatibility results, including any detected risks, are reported in status.conditionalUpdates and status.conditionalUpdateRisks alongside risks from the update recommendation service. This allows administrators to assess update readiness and address issues before committing to the update. Preflight mode is particularly useful for skip-level updates where upgrade compatibility needs to be verified across multiple minor versions. When mode is set to \"Preflight\", the same rules for version, image, and architecture apply as for normal updates.",
}
func (Update) SwaggerDoc() map[string]string {
@@ -984,9 +1079,47 @@ func (ConsoleStatus) SwaggerDoc() map[string]string {
return map_ConsoleStatus
}
+var map_CRIOCredentialProviderConfig = map[string]string{
+ "": "CRIOCredentialProviderConfig holds cluster-wide singleton resource configurations for CRI-O credential provider, the name of this instance is \"cluster\". CRI-O credential provider is a binary shipped with CRI-O that provides a way to obtain container image pull credentials from external sources. For example, it can be used to fetch mirror registry credentials from secrets resources in the cluster within the same namespace the pod will be running in. CRIOCredentialProviderConfig configuration specifies the pod image sources registries that should trigger the CRI-O credential provider execution, which will resolve the CRI-O mirror configurations and obtain the necessary credentials for pod creation. Note: Configuration changes will only take effect after the kubelet restarts, which is automatically managed by the cluster during rollout.\n\nThe resource is a singleton named \"cluster\".\n\nCompatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer).",
+ "metadata": "metadata is the standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata",
+ "spec": "spec defines the desired configuration of the CRI-O Credential Provider. This field is required and must be provided when creating the resource.",
+ "status": "status represents the current state of the CRIOCredentialProviderConfig. When omitted or nil, it indicates that the status has not yet been set by the controller. The controller will populate this field with validation conditions and operational state.",
+}
+
+func (CRIOCredentialProviderConfig) SwaggerDoc() map[string]string {
+ return map_CRIOCredentialProviderConfig
+}
+
+var map_CRIOCredentialProviderConfigList = map[string]string{
+ "": "CRIOCredentialProviderConfigList contains a list of CRIOCredentialProviderConfig resources\n\nCompatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer).",
+ "metadata": "metadata is the standard list's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata",
+}
+
+func (CRIOCredentialProviderConfigList) SwaggerDoc() map[string]string {
+ return map_CRIOCredentialProviderConfigList
+}
+
+var map_CRIOCredentialProviderConfigSpec = map[string]string{
+ "": "CRIOCredentialProviderConfigSpec defines the desired configuration of the CRI-O Credential Provider.",
+ "matchImages": "matchImages is a list of string patterns used to determine whether the CRI-O credential provider should be invoked for a given image. This list is passed to the kubelet CredentialProviderConfig, and if any pattern matches the requested image, CRI-O credential provider will be invoked to obtain credentials for pulling that image or its mirrors. Depending on the platform, the CRI-O credential provider may be installed alongside an existing platform specific provider. Conflicts between the existing platform specific provider image match configuration and this list will be handled by the following precedence rule: credentials from built-in kubelet providers (e.g., ECR, GCR, ACR) take precedence over those from the CRIOCredentialProviderConfig when both match the same image. To avoid uncertainty, it is recommended to avoid configuring your private image patterns to overlap with existing platform specific provider config(e.g., the entries from https://github.com/openshift/machine-config-operator/blob/main/templates/common/aws/files/etc-kubernetes-credential-providers-ecr-credential-provider.yaml). You can check the resource's Status conditions to see if any entries were ignored due to exact matches with known built-in provider patterns.\n\nThis field is optional, the items of the list must contain between 1 and 50 entries. The list is treated as a set, so duplicate entries are not allowed.\n\nFor more details, see: https://kubernetes.io/docs/tasks/administer-cluster/kubelet-credential-provider/ https://github.com/cri-o/crio-credential-provider#architecture\n\nEach entry in matchImages is a pattern which can optionally contain a port and a path. Each entry must be no longer than 512 characters. Wildcards ('*') are supported for full subdomain labels, such as '*.k8s.io' or 'k8s.*.io', and for top-level domains, such as 'k8s.*' (which matches 'k8s.io' or 'k8s.net'). A global wildcard '*' (matching any domain) is not allowed. Wildcards may replace an entire hostname label (e.g., *.example.com), but they cannot appear within a label (e.g., f*oo.example.com) and are not allowed in the port or path. For example, 'example.*.com' is valid, but 'exa*mple.*.com' is not. Each wildcard matches only a single domain label, so '*.io' does **not** match '*.k8s.io'.\n\nA match exists between an image and a matchImage when all of the below are true: Both contain the same number of domain parts and each part matches. The URL path of an matchImages must be a prefix of the target image URL path. If the matchImages contains a port, then the port must match in the image as well.\n\nExample values of matchImages: - 123456789.dkr.ecr.us-east-1.amazonaws.com - *.azurecr.io - gcr.io - *.*.registry.io - registry.io:8080/path",
+}
+
+func (CRIOCredentialProviderConfigSpec) SwaggerDoc() map[string]string {
+ return map_CRIOCredentialProviderConfigSpec
+}
+
+var map_CRIOCredentialProviderConfigStatus = map[string]string{
+ "": "CRIOCredentialProviderConfigStatus defines the observed state of CRIOCredentialProviderConfig",
+ "conditions": "conditions represent the latest available observations of the configuration state. When omitted, it indicates that no conditions have been reported yet. The maximum number of conditions is 16. Conditions are stored as a map keyed by condition type, ensuring uniqueness.\n\nExpected condition types include: \"Validated\": indicates whether the matchImages configuration is valid",
+}
+
+func (CRIOCredentialProviderConfigStatus) SwaggerDoc() map[string]string {
+ return map_CRIOCredentialProviderConfigStatus
+}
+
var map_AWSDNSSpec = map[string]string{
"": "AWSDNSSpec contains DNS configuration specific to the Amazon Web Services cloud provider.",
- "privateZoneIAMRole": "privateZoneIAMRole contains the ARN of an IAM role that should be assumed when performing operations on the cluster's private hosted zone specified in the cluster DNS config. When left empty, no role should be assumed.",
+ "privateZoneIAMRole": "privateZoneIAMRole contains the ARN of an IAM role that should be assumed when performing operations on the cluster's private hosted zone specified in the cluster DNS config. When left empty, no role should be assumed.\n\nThe ARN must follow the format: arn::iam:::role/, where: is the AWS partition (aws, aws-cn, aws-us-gov, or aws-eusc), is a 12-digit numeric identifier for the AWS account, is the IAM role name.",
}
func (AWSDNSSpec) SwaggerDoc() map[string]string {
@@ -1163,9 +1296,9 @@ func (RegistryLocation) SwaggerDoc() map[string]string {
var map_RegistrySources = map[string]string{
"": "RegistrySources holds cluster-wide information about how to handle the registries config.",
- "insecureRegistries": "insecureRegistries are registries which do not have a valid TLS certificates or only support HTTP connections.",
- "blockedRegistries": "blockedRegistries cannot be used for image pull and push actions. All other registries are permitted.\n\nOnly one of BlockedRegistries or AllowedRegistries may be set.",
- "allowedRegistries": "allowedRegistries are the only registries permitted for image pull and push actions. All other registries are denied.\n\nOnly one of BlockedRegistries or AllowedRegistries may be set.",
+ "insecureRegistries": "insecureRegistries are registries which do not have a valid TLS certificates or only support HTTP connections. Each entry must be a valid registry scope in the format hostname[:port][/path], optionally prefixed with \"*.\" for wildcard subdomains (e.g., \"*.example.com\"). The hostname must consist of valid DNS labels separated by dots, where each label contains only alphanumeric characters and hyphens and does not start or end with a hyphen. Entries must not be empty, must not include tags (e.g., \":latest\") or digests (e.g., \"@sha256:...\"), and must be at most 256 characters in length. The list may contain at most 1024 entries.",
+ "blockedRegistries": "blockedRegistries cannot be used for image pull and push actions. All other registries are permitted. Each entry must be a valid registry scope in the format hostname[:port][/path], optionally prefixed with \"*.\" for wildcard subdomains (e.g., \"*.example.com\"). The hostname must consist of valid DNS labels separated by dots, where each label contains only alphanumeric characters and hyphens and does not start or end with a hyphen. Entries must not be empty, must not include tags (e.g., \":latest\") or digests (e.g., \"@sha256:...\"), and must be at most 256 characters in length. The list may contain at most 1024 entries.\n\nOnly one of BlockedRegistries or AllowedRegistries may be set.",
+ "allowedRegistries": "allowedRegistries are the only registries permitted for image pull and push actions. All other registries are denied. Each entry must be a valid registry scope in the format hostname[:port][/path], optionally prefixed with \"*.\" for wildcard subdomains (e.g., \"*.example.com\"). The hostname must consist of valid DNS labels separated by dots, where each label contains only alphanumeric characters and hyphens and does not start or end with a hyphen. Entries must not be empty, must not include tags (e.g., \":latest\") or digests (e.g., \"@sha256:...\"), and must be at most 256 characters in length. The list may contain at most 1024 entries.\n\nOnly one of BlockedRegistries or AllowedRegistries may be set.",
"containerRuntimeSearchRegistries": "containerRuntimeSearchRegistries are registries that will be searched when pulling images that do not have fully qualified domains in their pull specs. Registries will be searched in the order provided in the list. Note: this search list only works with the container runtime, i.e CRI-O. Will NOT work with builds or imagestream imports.",
}
@@ -1448,7 +1581,7 @@ var map_AWSPlatformStatus = map[string]string{
"serviceEndpoints": "serviceEndpoints list contains custom endpoints which will override default service endpoint of AWS Services. There must be only one ServiceEndpoint for a service.",
"resourceTags": "resourceTags is a list of additional tags to apply to AWS resources created for the cluster. See https://docs.aws.amazon.com/general/latest/gr/aws_tagging.html for information on tagging AWS resources. AWS supports a maximum of 50 tags per resource. OpenShift reserves 25 tags for its use, leaving 25 tags available for the user.",
"cloudLoadBalancerConfig": "cloudLoadBalancerConfig holds configuration related to DNS and cloud load balancers. It allows configuration of in-cluster DNS as an alternative to the platform default DNS implementation. When using the ClusterHosted DNS type, Load Balancer IP addresses must be provided for the API and internal API load balancers as well as the ingress load balancer.",
- "ipFamily": "ipFamily specifies the IP protocol family that should be used for AWS network resources. This controls whether AWS resources are created with IPv4-only, or dual-stack networking with IPv4 or IPv6 as the primary protocol family.",
+ "ipFamily": "ipFamily specifies the IP protocol family that should be used for AWS network resources. This controls whether AWS resources are created with IPv4-only, or dual-stack networking with IPv4 or IPv6 as the primary protocol family.\n\nValid values are: * \"IPv4\" (default): Cloud platform resources use IPv4 addressing only. * \"DualStackIPv6Primary\": Cloud platform resources use dual-stack networking with IPv6 as the primary protocol family. * \"DualStackIPv4Primary\": Cloud platform resources use dual-stack networking with IPv4 as the primary protocol family.\n\nWhen omitted, this field defaults to \"IPv4\".\n\nThis field is immutable and cannot be changed once set.",
}
func (AWSPlatformStatus) SwaggerDoc() map[string]string {
@@ -1565,6 +1698,7 @@ var map_BareMetalPlatformStatus = map[string]string{
"ingressIPs": "ingressIPs are the external IPs which route to the default ingress controller. The IPs are suitable targets of a wildcard DNS record used to resolve default route host names. In dual stack clusters this list contains two IPs otherwise only one.",
"nodeDNSIP": "nodeDNSIP is the IP address for the internal DNS used by the nodes. Unlike the one managed by the DNS operator, `NodeDNSIP` provides name resolution for the nodes themselves. There is no DNS-as-a-service for BareMetal deployments. In order to minimize necessary changes to the datacenter DNS, a DNS service is hosted as a static pod to serve those hostnames to the nodes in the cluster.",
"loadBalancer": "loadBalancer defines how the load balancer used by the cluster is configured.",
+ "vipManagement": "vipManagement indicates which VIP management mechanism is active on this cluster. Allowed values are `Keepalived`, `BGP`, and omitted. Once set to a non-empty value, this field is immutable. When set to `BGP`, kube-vip (Routing Table Mode) and frr-k8s are deployed as static pods to advertise VIPs via BGP, replacing the default keepalived/VRRP mechanism. When set to `Keepalived`, the default keepalived-based VIP management is used. When omitted, the default keepalived-based VIP management is used.",
"dnsRecordsType": "dnsRecordsType determines whether records for api, api-int, and ingress are provided by the internal DNS service or externally. Allowed values are `Internal`, `External`, and omitted. When set to `Internal`, records are provided by the internal infrastructure and no additional user configuration is required for the cluster to function. When set to `External`, records are not provided by the internal infrastructure and must be configured by the user on a DNS server outside the cluster. Cluster nodes must use this external server for their upstream DNS requests. This value may only be set when loadBalancer.type is set to UserManaged. When omitted, this means the user has no opinion and the platform is left to choose reasonable defaults. These defaults are subject to change over time. The current default is `Internal`.",
"machineNetworks": "machineNetworks are IP networks used to connect all the OpenShift cluster nodes.",
}
@@ -1654,6 +1788,7 @@ var map_GCPPlatformStatus = map[string]string{
"resourceLabels": "resourceLabels is a list of additional labels to apply to GCP resources created for the cluster. See https://cloud.google.com/compute/docs/labeling-resources for information on labeling GCP resources. GCP supports a maximum of 64 labels per resource. OpenShift reserves 32 labels for internal use, allowing 32 labels for user configuration.",
"resourceTags": "resourceTags is a list of additional tags to apply to GCP resources created for the cluster. See https://cloud.google.com/resource-manager/docs/tags/tags-overview for information on tagging GCP resources. GCP supports a maximum of 50 tags per resource.",
"cloudLoadBalancerConfig": "cloudLoadBalancerConfig holds configuration related to DNS and cloud load balancers. It allows configuration of in-cluster DNS as an alternative to the platform default DNS implementation. When using the ClusterHosted DNS type, Load Balancer IP addresses must be provided for the API and internal API load balancers as well as the ingress load balancer.",
+ "universeDomain": "universeDomain is the GCP universe domain for the cluster, detected from the installer credentials. Components with their own GCP credentials should read the universe domain from those credentials, as they are the authoritative source. This field is provided for components that do not have GCP credentials and for general observability.\n\nWhen omitted, standard public GCP (googleapis.com) is assumed.\n\nuniverseDomain is an optional field that, when specified, must be non-empty and at most 253 characters. It must be a valid DNS subdomain: containing only lowercase alphanumeric characters, '-' or '.', and starting and ending with an alphanumeric character.",
}
func (GCPPlatformStatus) SwaggerDoc() map[string]string {
@@ -1735,9 +1870,10 @@ func (InfrastructureList) SwaggerDoc() map[string]string {
}
var map_InfrastructureSpec = map[string]string{
- "": "InfrastructureSpec contains settings that apply to the cluster infrastructure.",
- "cloudConfig": "cloudConfig is a reference to a ConfigMap containing the cloud provider configuration file. This configuration file is used to configure the Kubernetes cloud provider integration when using the built-in cloud provider integration or the external cloud controller manager. The namespace for this config map is openshift-config.\n\ncloudConfig should only be consumed by the kube_cloud_config controller. The controller is responsible for using the user configuration in the spec for various platforms and combining that with the user provided ConfigMap in this field to create a stitched kube cloud config. The controller generates a ConfigMap `kube-cloud-config` in `openshift-config-managed` namespace with the kube cloud config is stored in `cloud.conf` key. All the clients are expected to use the generated ConfigMap only.",
- "platformSpec": "platformSpec holds desired information specific to the underlying infrastructure provider.",
+ "": "InfrastructureSpec contains settings that apply to the cluster infrastructure.",
+ "cloudConfig": "cloudConfig is a reference to a ConfigMap containing the cloud provider configuration file. This configuration file is used to configure the Kubernetes cloud provider integration when using the built-in cloud provider integration or the external cloud controller manager. The namespace for this config map is openshift-config.\n\ncloudConfig should only be consumed by the kube_cloud_config controller. The controller is responsible for using the user configuration in the spec for various platforms and combining that with the user provided ConfigMap in this field to create a stitched kube cloud config. The controller generates a ConfigMap `kube-cloud-config` in `openshift-config-managed` namespace with the kube cloud config is stored in `cloud.conf` key. All the clients are expected to use the generated ConfigMap only.",
+ "platformSpec": "platformSpec holds desired information specific to the underlying infrastructure provider.",
+ "controlPlaneTopology": "controlPlaneTopology expresses the desired topology configuration for control nodes.\n\nWhen status.controlPlaneTopology is 'SingleReplica' and spec.controlPlaneTopology is set to 'HighlyAvailable', a transition will be triggered to reconfigure the cluster from SingleReplica to HighlyAvailable.\n\nWhen left blank or status.controlPlaneTopology and spec.controlPlaneTopology are the same value, no changes are required and no transitions will be triggered.\n\nThis value may be set to match status.controlPlaneTopology regardless of the current value.",
}
func (InfrastructureSpec) SwaggerDoc() map[string]string {
@@ -1752,7 +1888,7 @@ var map_InfrastructureStatus = map[string]string{
"etcdDiscoveryDomain": "etcdDiscoveryDomain is the domain used to fetch the SRV records for discovering etcd servers and clients. For more info: https://github.com/etcd-io/etcd/blob/329be66e8b3f9e2e6af83c123ff89297e49ebd15/Documentation/op-guide/clustering.md#dns-discovery deprecated: as of 4.7, this field is no longer set or honored. It will be removed in a future release.",
"apiServerURL": "apiServerURL is a valid URI with scheme 'https', address and optionally a port (defaulting to 443). apiServerURL can be used by components like the web console to tell users where to find the Kubernetes API.",
"apiServerInternalURI": "apiServerInternalURL is a valid URI with scheme 'https', address and optionally a port (defaulting to 443). apiServerInternalURL can be used by components like kubelets, to contact the Kubernetes API server using the infrastructure provider rather than Kubernetes networking.",
- "controlPlaneTopology": "controlPlaneTopology expresses the expectations for operands that normally run on control nodes. The default is 'HighlyAvailable', which represents the behavior operators have in a \"normal\" cluster. The 'SingleReplica' mode will be used in single-node deployments and the operators should not configure the operand for highly-available operation The 'External' mode indicates that the control plane is hosted externally to the cluster and that its components are not visible within the cluster.",
+ "controlPlaneTopology": "controlPlaneTopology expresses the expectations for operands that normally run on control nodes. The default is 'HighlyAvailable', which represents the behavior operators have in a \"normal\" cluster. The 'SingleReplica' mode will be used in single-node deployments and the operators should not configure the operand for highly-available operation The 'External' mode indicates that the control plane is hosted externally to the cluster and that its components are not visible within the cluster. The 'HighlyAvailableArbiter' mode indicates that the control plane will consist of 2 control-plane nodes that run conventional services and 1 smaller sized arbiter node that runs a bare minimum of services to maintain quorum.",
"infrastructureTopology": "infrastructureTopology expresses the expectations for infrastructure services that do not run on control plane nodes, usually indicated by a node selector for a `role` value other than `master`. The default is 'HighlyAvailable', which represents the behavior operators have in a \"normal\" cluster. The 'SingleReplica' mode will be used in single-node deployments and the operators should not configure the operand for highly-available operation NOTE: External topology mode is not applicable for this field.",
"cpuPartitioning": "cpuPartitioning expresses if CPU partitioning is a currently enabled feature in the cluster. CPU Partitioning means that this cluster can support partitioning workloads to specific CPU Sets. Valid values are \"None\" and \"AllNodes\". When omitted, the default value is \"None\". The default value of \"None\" indicates that no nodes will be setup with CPU partitioning. The \"AllNodes\" value indicates that all nodes have been setup with CPU partitioning, and can then be further configured via the PerformanceProfile API.",
}
@@ -2040,7 +2176,7 @@ var map_VSpherePlatformFailureDomainSpec = map[string]string{
"zone": "zone defines the name of a zone tag that will be attached to a vCenter cluster. The tag category in vCenter must be named openshift-zone.",
"regionAffinity": "regionAffinity holds the type of region, Datacenter or ComputeCluster. When set to Datacenter, this means the region is a vCenter Datacenter as defined in topology. When set to ComputeCluster, this means the region is a vCenter Cluster as defined in topology.",
"zoneAffinity": "zoneAffinity holds the type of the zone and the hostGroup which vmGroup and the hostGroup names in vCenter corresponds to a vm-host group of type Virtual Machine and Host respectively. Is also contains the vmHostRule which is an affinity vm-host rule in vCenter.",
- "server": "server is the fully-qualified domain name or the IP address of the vCenter server.",
+ "server": "server is the fully-qualified domain name or the IP address of the vCenter server. This must match the server field of an entry in the vcenters list. The match is case-sensitive; the value must be specified exactly as it appears in the vcenters entry. The value must be between 1 and 255 characters long.",
"topology": "topology describes a given failure domain using vSphere constructs",
}
@@ -2080,8 +2216,8 @@ func (VSpherePlatformNodeNetworkingSpec) SwaggerDoc() map[string]string {
var map_VSpherePlatformSpec = map[string]string{
"": "VSpherePlatformSpec holds the desired state of the vSphere infrastructure provider. In the future the cloud provider operator, storage operator and machine operator will use these fields for configuration.",
- "vcenters": "vcenters holds the connection details for services to communicate with vCenter. Currently, only a single vCenter is supported, but in tech preview 3 vCenters are supported. Once the cluster has been installed, you are unable to change the current number of defined vCenters except in the case where the cluster has been upgraded from a version of OpenShift where the vsphere platform spec was not present. You may make modifications to the existing vCenters that are defined in the vcenters list in order to match with any added or modified failure domains.",
- "failureDomains": "failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used.",
+ "vcenters": "vcenters holds the connection details for services to communicate with vCenter. Up to 3 vCenters are supported. Once the cluster has been installed, you are unable to change the current number of defined vCenters except when 1.) the cluster has been upgraded from a version of OpenShift where the vsphere platform spec was not present or 2.) in TechPreview you are able to add and remove vCenters but may not remove all vCenters. You may make modifications to the existing vCenters that are defined in the vcenters list in order to match with any added or modified failure domains.",
+ "failureDomains": "failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. Each failure domain's server must match the server field of an entry in the vcenters list.",
"nodeNetworking": "nodeNetworking contains the definition of internal and external network constraints for assigning the node's networking. If this field is omitted, networking defaults to the legacy address selection behavior which is to only support a single address and return the first one found.",
"apiServerInternalIPs": "apiServerInternalIPs are the IP addresses to contact the Kubernetes API server that can be used by components inside the cluster, like kubelets using the infrastructure rather than Kubernetes networking. These are the IPs for a self-hosted load balancer in front of the API servers. In dual stack clusters this list contains two IP addresses, one from IPv4 family and one from IPv6. In single stack clusters a single IP address is expected. When omitted, values from the status.apiServerInternalIPs will be used. Once set, the list cannot be completely removed (but its second entry can).",
"ingressIPs": "ingressIPs are the external IPs which route to the default ingress controller. The IPs are suitable targets of a wildcard DNS record used to resolve default route host names. In dual stack clusters this list contains two IP addresses, one from IPv4 family and one from IPv6. In single stack clusters a single IP address is expected. When omitted, values from the status.ingressIPs will be used. Once set, the list cannot be completely removed (but its second entry can).",
@@ -2149,6 +2285,7 @@ var map_ComponentRouteSpec = map[string]string{
"name": "name is the logical name of the route to customize.\n\nThe namespace and name of this componentRoute must match a corresponding entry in the list of status.componentRoutes if the route is to be customized.",
"hostname": "hostname is the hostname that should be used by the route.",
"servingCertKeyPairSecret": "servingCertKeyPairSecret is a reference to a secret of type `kubernetes.io/tls` in the openshift-config namespace. The serving cert/key pair must match and will be used by the operator to fulfill the intent of serving with this name. If the custom hostname uses the default routing suffix of the cluster, the Secret specification for a serving certificate will not be needed.",
+ "labels": "labels defines additional labels to be applied to the route created for the component. These labels are used by the IngressController to determine which routes it should manage. Changing labels may cause the route to be reassigned to a different IngressController. When omitted, no additional labels are applied to the component route. When specified, labels must contain at least one entry, up to a maximum of 8. Label keys must be valid qualified names, consisting of a name segment and an optional prefix separated by a slash (/). The name segment must be at most 63 characters in length and must consist only of alphanumeric characters, dashes (-), underscores (_), and dots (.), and must start and end with alphanumeric characters. The prefix, if specified, must be a DNS subdomain: at most 253 characters in length, consisting of dot-separated segments where each segment starts and ends with an alphanumeric character. Label values must be either empty or 1-63 characters, consisting of alphanumeric characters, dashes (-), underscores (_), or dots (.), starting and ending with an alphanumeric character. Keys with the \"kubernetes.io/\", \"k8s.io/\", and \"openshift.io/\" prefixes are reserved and may not be used.",
}
func (ComponentRouteSpec) SwaggerDoc() map[string]string {
@@ -2203,7 +2340,7 @@ func (IngressPlatformSpec) SwaggerDoc() map[string]string {
var map_IngressSpec = map[string]string{
"domain": "domain is used to generate a default host name for a route when the route's host name is empty. The generated host name will follow this pattern: \"..\".\n\nIt is also used as the default wildcard domain suffix for ingress. The default ingresscontroller domain will follow this pattern: \"*.\".\n\nOnce set, changing domain is not currently supported.",
"appsDomain": "appsDomain is an optional domain to use instead of the one specified in the domain field when a Route is created without specifying an explicit host. If appsDomain is nonempty, this value is used to generate default host values for Route. Unlike domain, appsDomain may be modified after installation. This assumes a new ingresscontroller has been setup with a wildcard certificate.",
- "componentRoutes": "componentRoutes is an optional list of routes that are managed by OpenShift components that a cluster-admin is able to configure the hostname and serving certificate for. The namespace and name of each route in this list should match an existing entry in the status.componentRoutes list.\n\nTo determine the set of configurable Routes, look at namespace and name of entries in the .status.componentRoutes list, where participating operators write the status of configurable routes.",
+ "componentRoutes": "componentRoutes is an optional list of routes that are managed by OpenShift components that a cluster-admin is able to configure the hostname and serving certificate for. The namespace and name of each route in this list should match an existing entry in the status.componentRoutes list.\n\nTo determine the set of configurable Routes, look at namespace and name of entries in the .status.componentRoutes list, where participating operators write the status of configurable routes. A maximum of 250 component routes may be configured.",
"requiredHSTSPolicies": "requiredHSTSPolicies specifies HSTS policies that are required to be set on newly created or updated routes matching the domainPattern/s and namespaceSelector/s that are specified in the policy. Each requiredHSTSPolicy must have at least a domainPattern and a maxAge to validate a route HSTS Policy route annotation, and affect route admission.\n\nA candidate route is checked for HSTS Policies if it has the HSTS Policy route annotation: \"haproxy.router.openshift.io/hsts_header\" E.g. haproxy.router.openshift.io/hsts_header: max-age=31536000;preload;includeSubDomains\n\n- For each candidate route, if it matches a requiredHSTSPolicy domainPattern and optional namespaceSelector, then the maxAge, preloadPolicy, and includeSubdomainsPolicy must be valid to be admitted. Otherwise, the route is rejected. - The first match, by domainPattern and optional namespaceSelector, in the ordering of the RequiredHSTSPolicies determines the route's admission status. - If the candidate route doesn't match any requiredHSTSPolicy domainPattern and optional namespaceSelector, then it may use any HSTS Policy annotation.\n\nThe HSTS policy configuration may be changed after routes have already been created. An update to a previously admitted route may then fail if the updated route does not conform to the updated HSTS policy configuration. However, changing the HSTS policy configuration will not cause a route that is already admitted to stop working.\n\nNote that if there are no RequiredHSTSPolicies, any HSTS Policy annotation on the route is valid.",
"loadBalancer": "loadBalancer contains the load balancer details in general which are not only specific to the underlying infrastructure provider of the current cluster and are required for Ingress Controller to work on OpenShift.",
}
@@ -2327,24 +2464,76 @@ func (Storage) SwaggerDoc() map[string]string {
return map_Storage
}
-var map_AWSKMSConfig = map[string]string{
- "": "AWSKMSConfig defines the KMS config specific to AWS KMS provider",
- "keyARN": "keyARN specifies the Amazon Resource Name (ARN) of the AWS KMS key used for encryption. The value must adhere to the format `arn:aws:kms:::key/`, where: - `` is the AWS region consisting of lowercase letters and hyphens followed by a number. - `` is a 12-digit numeric identifier for the AWS account. - `` is a unique identifier for the KMS key, consisting of lowercase hexadecimal characters and hyphens.",
- "region": "region specifies the AWS region where the KMS instance exists, and follows the format `--`, e.g.: `us-east-1`. Only lowercase letters and hyphens followed by numbers are allowed.",
+var map_KMSPluginConfig = map[string]string{
+ "": "KMSPluginConfig defines the configuration for the KMS instance that will be used with KMS encryption",
+ "type": "type defines the kind of platform for the KMS provider. Allowed values are Vault. When set to Vault, the plugin connects to a HashiCorp Vault server for key management.",
+ "vault": "vault defines the configuration for the Vault KMS plugin. The plugin connects to a Vault Enterprise server that is managed by the user outside the purview of the control plane. This field must be set when type is Vault, and must be unset otherwise.",
}
-func (AWSKMSConfig) SwaggerDoc() map[string]string {
- return map_AWSKMSConfig
+func (KMSPluginConfig) SwaggerDoc() map[string]string {
+ return map_KMSPluginConfig
}
-var map_KMSConfig = map[string]string{
- "": "KMSConfig defines the configuration for the KMS instance that will be used with KMSEncryptionProvider encryption",
- "type": "type defines the kind of platform for the KMS provider. Available provider types are AWS only.",
- "aws": "aws defines the key config for using an AWS KMS instance for the encryption. The AWS KMS instance is managed by the user outside the purview of the control plane.",
+var map_VaultAppRoleAuthentication = map[string]string{
+ "": "VaultAppRoleAuthentication defines the configuration for AppRole authentication with Vault.",
+ "secret": "secret references a secret in the openshift-config namespace containing the AppRole credentials used to authenticate with Vault. The referenced Secret must contain two keys: \"role-id\" for the AppRole Role ID and \"secret-id\" for the AppRole Secret ID.",
}
-func (KMSConfig) SwaggerDoc() map[string]string {
- return map_KMSConfig
+func (VaultAppRoleAuthentication) SwaggerDoc() map[string]string {
+ return map_VaultAppRoleAuthentication
+}
+
+var map_VaultAuthentication = map[string]string{
+ "": "VaultAuthentication defines the authentication method used to authenticate with Vault.",
+ "type": "type defines the authentication method used to authenticate with Vault. Allowed values are AppRole. When set to AppRole, the plugin uses AppRole credentials to authenticate with Vault.",
+ "appRole": "appRole defines the configuration for AppRole authentication. This field must be set when type is AppRole, and must be unset otherwise.",
+}
+
+func (VaultAuthentication) SwaggerDoc() map[string]string {
+ return map_VaultAuthentication
+}
+
+var map_VaultConfigMapReference = map[string]string{
+ "": "VaultConfigMapReference references a ConfigMap in the openshift-config namespace.",
+ "name": "name is the metadata.name of the referenced ConfigMap in the openshift-config namespace. The name must be a valid DNS subdomain name: it must contain no more than 253 characters, contain only lowercase alphanumeric characters, '-' or '.', and start and end with an alphanumeric character.",
+}
+
+func (VaultConfigMapReference) SwaggerDoc() map[string]string {
+ return map_VaultConfigMapReference
+}
+
+var map_VaultKMSPluginConfig = map[string]string{
+ "": "VaultKMSPluginConfig defines the KMS plugin configuration specific to Vault KMS",
+ "kmsPluginImage": "kmsPluginImage specifies the container image for the HashiCorp Vault KMS plugin.\n\nThe image must be a fully qualified OCI image pull spec with a SHA256 digest. The format is: host[:port][/namespace]/name@sha256: where the digest must be 64 characters long and consist only of lowercase hexadecimal characters, a-f and 0-9. The total length must be between 75 and 447 characters.\n\nShort names (e.g., \"vault-plugin\" or \"hashicorp/vault-plugin\") are not allowed. The registry hostname must be included and must contain at least one dot. Image tags (e.g., \":latest\", \":v1.0.0\") are not allowed.\n\nConsult the OpenShift documentation for compatible plugin versions with your cluster version, then obtain the image digest for that version from HashiCorp's container registry.\n\nFor disconnected environments, mirror the plugin image to an accessible registry and reference the mirrored location with its digest.",
+ "vaultAddress": "vaultAddress specifies the address of the HashiCorp Vault instance. The value must be a valid HTTPS URL containing only scheme, host, and optional port. Paths, user info, query parameters, and fragments are not allowed.\n\nFormat: https://hostname[:port] Example: https://vault.example.com:8200\n\nThe value must be between 1 and 512 characters.",
+ "vaultNamespace": "vaultNamespace specifies the Vault namespace where the Transit secrets engine is mounted. This is only applicable for Vault Enterprise installations. When this field is not set, no namespace is used.\n\nThe value must be between 1 and 4096 characters. The namespace cannot end with a forward slash, cannot contain spaces, and cannot be one of the reserved strings: root, sys, audit, auth, cubbyhole, or identity.",
+ "vaultAuthNamespace": "vaultAuthNamespace specifies the Vault namespace to use for authentication. This is only applicable for Vault Enterprise installations where authentication and Transit operations may be in different namespaces. When this field is not set, the value of vaultNamespace is used for both authentication and Transit key operations.\n\nThe value must be between 1 and 4096 characters. The namespace cannot end with a forward slash, cannot contain spaces, and cannot be one of the reserved strings: root, sys, audit, auth, cubbyhole, or identity.",
+ "tls": "tls contains the TLS configuration for connecting to the Vault server. When this field is not set, system default TLS settings are used.",
+ "authentication": "authentication defines the authentication method used to authenticate with Vault.",
+ "vaultKeyPath": "vaultKeyPath specifies the full path to the encryption key in Vault's Transit secrets engine, combining the Transit engine mount path and the key name separated by \"/keys/\". Format: /keys/ (e.g., transit/keys/my-key, myteam/transit/keys/production-key).\n\nThe total path length must be between 8 and 1542 characters. The path cannot start or end with a forward slash, cannot contain consecutive forward slashes, must only contain RFC 3986 unreserved characters (alphanumeric, hyphen, period, underscore, tilde) and forward slashes as path separators, and must not contain \".\" or \"..\" path segments. The key name must start and end with an alphanumeric character or underscore, and may contain alphanumeric characters, underscores, hyphens, and periods in the middle.",
+}
+
+func (VaultKMSPluginConfig) SwaggerDoc() map[string]string {
+ return map_VaultKMSPluginConfig
+}
+
+var map_VaultSecretReference = map[string]string{
+ "": "VaultSecretReference references a secret in the openshift-config namespace.",
+ "name": "name is the metadata.name of the referenced secret in the openshift-config namespace. The name must be a valid DNS subdomain name: it must contain no more than 253 characters, contain only lowercase alphanumeric characters, '-' or '.', and start and end with an alphanumeric character.",
+}
+
+func (VaultSecretReference) SwaggerDoc() map[string]string {
+ return map_VaultSecretReference
+}
+
+var map_VaultTLSConfig = map[string]string{
+ "": "VaultTLSConfig contains TLS configuration for connecting to Vault.",
+ "caBundle": "caBundle references a ConfigMap in the openshift-config namespace containing the CA certificate bundle used to verify the TLS connection to the Vault server. The referenced ConfigMap must contain the CA bundle in the key \"ca-bundle.crt\". When this field is not set, the system's trusted CA certificates are used.\n\nThe namespace for the ConfigMap is openshift-config.\n\nExample ConfigMap:\n apiVersion: v1\n kind: ConfigMap\n metadata:\n name: vault-ca-bundle\n namespace: openshift-config\n data:\n ca-bundle.crt: |",
+ "serverName": "serverName specifies the Server Name Indication (SNI) to use when connecting to Vault via TLS. This is useful when the Vault server's hostname doesn't match its TLS certificate. When this field is not set, the hostname from vaultAddress is used for SNI.\n\nThe value must be a valid DNS hostname: it must contain no more than 253 characters, contain only lowercase alphanumeric characters, '-' or '.', and start and end with an alphanumeric character.",
+}
+
+func (VaultTLSConfig) SwaggerDoc() map[string]string {
+ return map_VaultTLSConfig
}
var map_ClusterNetworkEntry = map[string]string{
@@ -2457,6 +2646,15 @@ func (NetworkMigration) SwaggerDoc() map[string]string {
return map_NetworkMigration
}
+var map_NetworkObservabilitySpec = map[string]string{
+ "": "NetworkObservabilitySpec defines the configuration for network observability installation",
+ "installationPolicy": "installationPolicy controls whether network observability is installed during cluster deployment. Valid values are \"InstallAndEnable\" and \"NoAction\". When set to \"InstallAndEnable\", ensure that network observability will be installed and enabled on the cluster. If already installed, no action taken, but if it gets uninstalled, it will install it again. When set to \"NoAction\", nothing will be done regarding Network observability. During the installation of NetworkObservability, the platform checks for any existing manual installations. If a successful installation using the OLMv0 or OLMv1 API is detected, it will be used. If the platform cannot determine how the current version was installed, or if the existing installation is incomplete, the installation process will stop.",
+}
+
+func (NetworkObservabilitySpec) SwaggerDoc() map[string]string {
+ return map_NetworkObservabilitySpec
+}
+
var map_NetworkSpec = map[string]string{
"": "NetworkSpec is the desired network configuration. As a general rule, this SHOULD NOT be read directly. Instead, you should consume the NetworkStatus, as it indicates the currently deployed configuration. Currently, most spec fields are immutable after installation. Please view the individual ones for further details on each.",
"clusterNetwork": "IP address pool to use for pod IPs. This field is immutable after installation.",
@@ -2465,6 +2663,7 @@ var map_NetworkSpec = map[string]string{
"externalIP": "externalIP defines configuration for controllers that affect Service.ExternalIP. If nil, then ExternalIP is not allowed to be set.",
"serviceNodePortRange": "The port range allowed for Services of type NodePort. If not specified, the default of 30000-32767 will be used. Such Services without a NodePort specified will have one automatically allocated from this range. This parameter can be updated after the cluster is installed.",
"networkDiagnostics": "networkDiagnostics defines network diagnostics configuration.\n\nTakes precedence over spec.disableNetworkDiagnostics in network.operator.openshift.io. If networkDiagnostics is not specified or is empty, and the spec.disableNetworkDiagnostics flag in network.operator.openshift.io is set to true, the network diagnostics feature will be disabled.",
+ "networkObservability": "networkObservability is an optional field that configures network observability installation during cluster deployment (day-0). When omitted, unless this is a SNO cluster, network observability will be installed if not already present, after that, no action taken.",
}
func (NetworkSpec) SwaggerDoc() map[string]string {
@@ -3007,6 +3206,7 @@ func (OldTLSProfile) SwaggerDoc() map[string]string {
var map_TLSProfileSpec = map[string]string{
"": "TLSProfileSpec is the desired behavior of a TLSSecurityProfile.",
"ciphers": "ciphers is used to specify the cipher algorithms that are negotiated during the TLS handshake. Operators may remove entries that their operands do not support. For example, to use only ECDHE-RSA-AES128-GCM-SHA256 (yaml):\n\n ciphers:\n - ECDHE-RSA-AES128-GCM-SHA256\n\nTLS 1.3 cipher suites (e.g. TLS_AES_128_GCM_SHA256) are not configurable and are always enabled when TLS 1.3 is negotiated.",
+ "groups": "groups is an optional, ordered field used to specify the supported groups (formerly known as elliptic curves) that are used during the TLS handshake. The order of the groups represents a suggested preference, with the most preferred group first. Note that not all platform components honor the ordering: Go-based components use Go's internal preference order and treat this list as a filter of allowed groups rather than an ordered preference. Operators may remove entries their operands do not support.\n\nWhen omitted, this means no opinion and the platform is left to choose reasonable defaults which are subject to change over time and may be different per platform component depending on the underlying TLS libraries they use. If specified, the list must contain at least one and at most 7 groups, and each group must be unique.\n\nFor example, to use X25519 and secp256r1 (yaml):\n\n groups:\n - X25519\n - secp256r1",
"minTLSVersion": "minTLSVersion is used to specify the minimal version of the TLS protocol that is negotiated during the TLS handshake. For example, to use TLS versions 1.1, 1.2 and 1.3 (yaml):\n\n minTLSVersion: VersionTLS11",
}
@@ -3016,11 +3216,11 @@ func (TLSProfileSpec) SwaggerDoc() map[string]string {
var map_TLSSecurityProfile = map[string]string{
"": "TLSSecurityProfile defines the schema for a TLS security profile. This object is used by operators to apply TLS security settings to operands.",
- "type": "type is one of Old, Intermediate, Modern or Custom. Custom provides the ability to specify individual TLS security profile parameters.\n\nThe profiles are based on version 5.7 of the Mozilla Server Side TLS configuration guidelines. The cipher lists consist of the configuration's \"ciphersuites\" followed by the Go-specific \"ciphers\" from the guidelines. See: https://ssl-config.mozilla.org/guidelines/5.7.json\n\nThe profiles are intent based, so they may change over time as new ciphers are developed and existing ciphers are found to be insecure. Depending on precisely which ciphers are available to a process, the list may be reduced.",
- "old": "old is a TLS profile for use when services need to be accessed by very old clients or libraries and should be used only as a last resort.\n\nThis profile is equivalent to a Custom profile specified as:\n minTLSVersion: VersionTLS10\n ciphers:\n - TLS_AES_128_GCM_SHA256\n - TLS_AES_256_GCM_SHA384\n - TLS_CHACHA20_POLY1305_SHA256\n - ECDHE-ECDSA-AES128-GCM-SHA256\n - ECDHE-RSA-AES128-GCM-SHA256\n - ECDHE-ECDSA-AES256-GCM-SHA384\n - ECDHE-RSA-AES256-GCM-SHA384\n - ECDHE-ECDSA-CHACHA20-POLY1305\n - ECDHE-RSA-CHACHA20-POLY1305\n - ECDHE-ECDSA-AES128-SHA256\n - ECDHE-RSA-AES128-SHA256\n - ECDHE-ECDSA-AES128-SHA\n - ECDHE-RSA-AES128-SHA\n - ECDHE-ECDSA-AES256-SHA\n - ECDHE-RSA-AES256-SHA\n - AES128-GCM-SHA256\n - AES256-GCM-SHA384\n - AES128-SHA256\n - AES128-SHA\n - AES256-SHA\n - DES-CBC3-SHA",
- "intermediate": "intermediate is a TLS profile for use when you do not need compatibility with legacy clients and want to remain highly secure while being compatible with most clients currently in use.\n\nThis profile is equivalent to a Custom profile specified as:\n minTLSVersion: VersionTLS12\n ciphers:\n - TLS_AES_128_GCM_SHA256\n - TLS_AES_256_GCM_SHA384\n - TLS_CHACHA20_POLY1305_SHA256\n - ECDHE-ECDSA-AES128-GCM-SHA256\n - ECDHE-RSA-AES128-GCM-SHA256\n - ECDHE-ECDSA-AES256-GCM-SHA384\n - ECDHE-RSA-AES256-GCM-SHA384\n - ECDHE-ECDSA-CHACHA20-POLY1305\n - ECDHE-RSA-CHACHA20-POLY1305",
- "modern": "modern is a TLS security profile for use with clients that support TLS 1.3 and do not need backward compatibility for older clients.\n\nThis profile is equivalent to a Custom profile specified as:\n minTLSVersion: VersionTLS13\n ciphers:\n - TLS_AES_128_GCM_SHA256\n - TLS_AES_256_GCM_SHA384\n - TLS_CHACHA20_POLY1305_SHA256",
- "custom": "custom is a user-defined TLS security profile. Be extremely careful using a custom profile as invalid configurations can be catastrophic. An example custom profile looks like this:\n\n minTLSVersion: VersionTLS11\n ciphers:\n - ECDHE-ECDSA-CHACHA20-POLY1305\n - ECDHE-RSA-CHACHA20-POLY1305\n - ECDHE-RSA-AES128-GCM-SHA256\n - ECDHE-ECDSA-AES128-GCM-SHA256",
+ "type": "type is one of Old, Intermediate, Modern or Custom. Custom provides the ability to specify individual TLS security profile parameters.\n\nThe cipher and groups lists in these profiles are based on version 5.8 of the Mozilla Server Side TLS configuration guidelines. See: https://ssl-config.mozilla.org/guidelines/5.8.json\n\nThe groups are listed in suggested preference order, with the most preferred group first. Note that not all platform components honor the ordering: Go-based components use Go's internal preference order and treat this list as a filter of allowed groups rather than an ordered preference. Note that X25519MLKEM768 is a post-quantum hybrid group that is not FIPS-approved and should be ignored by components running in FIPS mode.\n\nThe profiles are intent based, so they may change over time as new ciphers are developed and existing ciphers are found to be insecure. Depending on precisely which ciphers are available to a process, the list may be reduced.",
+ "old": "old is a TLS profile for use when services need to be accessed by very old clients or libraries and should be used only as a last resort.\n\nThe supported groups list includes by default the following groups in suggested preference order (ordering may not be honored by all implementations): X25519MLKEM768, X25519, secp256r1, secp384r1.\n\nThis profile is equivalent to a Custom profile specified as:\n minTLSVersion: VersionTLS10\n ciphers:\n - TLS_AES_128_GCM_SHA256\n - TLS_AES_256_GCM_SHA384\n - TLS_CHACHA20_POLY1305_SHA256\n - ECDHE-ECDSA-AES128-GCM-SHA256\n - ECDHE-RSA-AES128-GCM-SHA256\n - ECDHE-ECDSA-AES256-GCM-SHA384\n - ECDHE-RSA-AES256-GCM-SHA384\n - ECDHE-ECDSA-CHACHA20-POLY1305\n - ECDHE-RSA-CHACHA20-POLY1305\n - ECDHE-ECDSA-AES128-SHA256\n - ECDHE-RSA-AES128-SHA256\n - ECDHE-ECDSA-AES128-SHA\n - ECDHE-RSA-AES128-SHA\n - ECDHE-ECDSA-AES256-SHA384\n - ECDHE-RSA-AES256-SHA384\n - ECDHE-ECDSA-AES256-SHA\n - ECDHE-RSA-AES256-SHA\n - AES128-GCM-SHA256\n - AES256-GCM-SHA384\n - AES128-SHA256\n - AES256-SHA256\n - AES128-SHA\n - AES256-SHA\n - DES-CBC3-SHA",
+ "intermediate": "intermediate is a TLS profile for use when you do not need compatibility with legacy clients and want to remain highly secure while being compatible with most clients currently in use.\n\nThe supported groups list includes by default the following groups in suggested preference order (ordering may not be honored by all implementations): X25519MLKEM768, X25519, secp256r1, secp384r1.\n\nThis profile is equivalent to a Custom profile specified as:\n minTLSVersion: VersionTLS12\n ciphers:\n - TLS_AES_128_GCM_SHA256\n - TLS_AES_256_GCM_SHA384\n - TLS_CHACHA20_POLY1305_SHA256\n - ECDHE-ECDSA-AES128-GCM-SHA256\n - ECDHE-RSA-AES128-GCM-SHA256\n - ECDHE-ECDSA-AES256-GCM-SHA384\n - ECDHE-RSA-AES256-GCM-SHA384\n - ECDHE-ECDSA-CHACHA20-POLY1305\n - ECDHE-RSA-CHACHA20-POLY1305",
+ "modern": "modern is a TLS security profile for use with clients that support TLS 1.3 and do not need backward compatibility for older clients. The supported groups list includes by default the following groups in suggested preference order (ordering may not be honored by all implementations): X25519MLKEM768, X25519, secp256r1, secp384r1. This profile is equivalent to a Custom profile specified as:\n minTLSVersion: VersionTLS13\n ciphers:\n - TLS_AES_128_GCM_SHA256\n - TLS_AES_256_GCM_SHA384\n - TLS_CHACHA20_POLY1305_SHA256",
+ "custom": "custom is a user-defined TLS security profile. Be extremely careful using a custom profile as invalid configurations can be catastrophic.\n\nThe supported groups list for this profile is empty by default.\n\nAn example custom profile looks like this:\n\n minTLSVersion: VersionTLS11\n ciphers:\n - ECDHE-ECDSA-CHACHA20-POLY1305\n - ECDHE-RSA-CHACHA20-POLY1305\n - ECDHE-RSA-AES128-GCM-SHA256\n - ECDHE-ECDSA-AES128-GCM-SHA256",
}
func (TLSSecurityProfile) SwaggerDoc() map[string]string {
diff --git a/vendor/github.com/openshift/api/config/v1alpha1/doc.go b/vendor/github.com/openshift/api/config/v1alpha1/doc.go
index 20d4485739..65333883b5 100644
--- a/vendor/github.com/openshift/api/config/v1alpha1/doc.go
+++ b/vendor/github.com/openshift/api/config/v1alpha1/doc.go
@@ -1,6 +1,7 @@
// +k8s:deepcopy-gen=package,register
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.config.v1alpha1
// +kubebuilder:validation:Optional
// +groupName=config.openshift.io
diff --git a/vendor/github.com/openshift/api/config/v1alpha1/register.go b/vendor/github.com/openshift/api/config/v1alpha1/register.go
index 383d19e7e6..1d84b71079 100644
--- a/vendor/github.com/openshift/api/config/v1alpha1/register.go
+++ b/vendor/github.com/openshift/api/config/v1alpha1/register.go
@@ -36,10 +36,6 @@ func addKnownTypes(scheme *runtime.Scheme) error {
&InsightsDataGatherList{},
&Backup{},
&BackupList{},
- &ImagePolicy{},
- &ImagePolicyList{},
- &ClusterImagePolicy{},
- &ClusterImagePolicyList{},
&CRIOCredentialProviderConfig{},
&CRIOCredentialProviderConfigList{},
&PKI{},
diff --git a/vendor/github.com/openshift/api/config/v1alpha1/types_cluster_image_policy.go b/vendor/github.com/openshift/api/config/v1alpha1/types_cluster_image_policy.go
deleted file mode 100644
index e8d7603d7b..0000000000
--- a/vendor/github.com/openshift/api/config/v1alpha1/types_cluster_image_policy.go
+++ /dev/null
@@ -1,80 +0,0 @@
-package v1alpha1
-
-import metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
-
-// +genclient
-// +genclient:nonNamespaced
-// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
-
-// ClusterImagePolicy holds cluster-wide configuration for image signature verification
-//
-// Compatibility level 4: No compatibility is provided, the API can change at any point for any reason. These capabilities should not be used by applications needing long term support.
-// +kubebuilder:object:root=true
-// +kubebuilder:resource:path=clusterimagepolicies,scope=Cluster
-// +kubebuilder:subresource:status
-// +openshift:api-approved.openshift.io=https://github.com/openshift/api/pull/1457
-// +openshift:file-pattern=cvoRunLevel=0000_10,operatorName=config-operator,operatorOrdering=01
-// +openshift:enable:FeatureGate=SigstoreImageVerification
-// +openshift:compatibility-gen:level=4
-type ClusterImagePolicy struct {
- metav1.TypeMeta `json:",inline"`
-
- // metadata is the standard object's metadata.
- // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
- metav1.ObjectMeta `json:"metadata,omitempty"`
-
- // spec contains the configuration for the cluster image policy.
- // +required
- Spec ClusterImagePolicySpec `json:"spec"`
- // status contains the observed state of the resource.
- // +optional
- Status ClusterImagePolicyStatus `json:"status,omitempty"`
-}
-
-// CLusterImagePolicySpec is the specification of the ClusterImagePolicy custom resource.
-type ClusterImagePolicySpec struct {
- // scopes defines the list of image identities assigned to a policy. Each item refers to a scope in a registry implementing the "Docker Registry HTTP API V2".
- // Scopes matching individual images are named Docker references in the fully expanded form, either using a tag or digest. For example, docker.io/library/busybox:latest (not busybox:latest).
- // More general scopes are prefixes of individual-image scopes, and specify a repository (by omitting the tag or digest), a repository
- // namespace, or a registry host (by only specifying the host name and possibly a port number) or a wildcard expression starting with `*.`, for matching all subdomains (not including a port number).
- // Wildcards are only supported for subdomain matching, and may not be used in the middle of the host, i.e. *.example.com is a valid case, but example*.*.com is not.
- // If multiple scopes match a given image, only the policy requirements for the most specific scope apply. The policy requirements for more general scopes are ignored.
- // In addition to setting a policy appropriate for your own deployed applications, make sure that a policy on the OpenShift image repositories
- // quay.io/openshift-release-dev/ocp-release, quay.io/openshift-release-dev/ocp-v4.0-art-dev (or on a more general scope) allows deployment of the OpenShift images required for cluster operation.
- // If a scope is configured in both the ClusterImagePolicy and the ImagePolicy, or if the scope in ImagePolicy is nested under one of the scopes from the ClusterImagePolicy, only the policy from the ClusterImagePolicy will be applied.
- // For additional details about the format, please refer to the document explaining the docker transport field,
- // which can be found at: https://github.com/containers/image/blob/main/docs/containers-policy.json.5.md#docker
- // +required
- // +kubebuilder:validation:MaxItems=256
- // +listType=set
- Scopes []ImageScope `json:"scopes"`
- // policy contains configuration to allow scopes to be verified, and defines how
- // images not matching the verification policy will be treated.
- // +required
- Policy ImageSigstoreVerificationPolicy `json:"policy"`
-}
-
-// +k8s:deepcopy-gen=true
-type ClusterImagePolicyStatus struct {
- // conditions provide details on the status of this API Resource.
- // +listType=map
- // +listMapKey=type
- // +optional
- Conditions []metav1.Condition `json:"conditions,omitempty"`
-}
-
-// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
-
-// ClusterImagePolicyList is a list of ClusterImagePolicy resources
-//
-// Compatibility level 4: No compatibility is provided, the API can change at any point for any reason. These capabilities should not be used by applications needing long term support.
-// +openshift:compatibility-gen:level=4
-type ClusterImagePolicyList struct {
- metav1.TypeMeta `json:",inline"`
-
- // metadata is the standard list's metadata.
- // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
- metav1.ListMeta `json:"metadata"`
-
- Items []ClusterImagePolicy `json:"items"`
-}
diff --git a/vendor/github.com/openshift/api/config/v1alpha1/types_cluster_monitoring.go b/vendor/github.com/openshift/api/config/v1alpha1/types_cluster_monitoring.go
index e72f537f99..98f8d7dc59 100644
--- a/vendor/github.com/openshift/api/config/v1alpha1/types_cluster_monitoring.go
+++ b/vendor/github.com/openshift/api/config/v1alpha1/types_cluster_monitoring.go
@@ -89,6 +89,19 @@ type ClusterMonitoringSpec struct {
// The current default value is `DefaultConfig`.
// +optional
AlertmanagerConfig AlertmanagerConfig `json:"alertmanagerConfig,omitempty,omitzero"`
+ // prometheusConfig provides configuration options for the default platform Prometheus instance
+ // that runs in the `openshift-monitoring` namespace. This configuration applies only to the
+ // platform Prometheus instance; user-workload Prometheus instances are configured separately.
+ //
+ // This field allows you to customize how the platform Prometheus is deployed and operated, including:
+ // - Pod scheduling (node selectors, tolerations, topology spread constraints)
+ // - Resource allocation (CPU, memory requests/limits)
+ // - Retention policies (how long metrics are stored)
+ // - External integrations (remote write, additional alertmanagers)
+ //
+ // This field is optional. When omitted, the platform chooses reasonable defaults, which may change over time.
+ // +optional
+ PrometheusConfig PrometheusConfig `json:"prometheusConfig,omitempty,omitzero"`
// metricsServerConfig is an optional field that can be used to configure the Kubernetes Metrics Server that runs in the openshift-monitoring namespace.
// Specifically, it can configure how the Metrics Server instance is deployed, pod scheduling, its audit policy and log verbosity.
// When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
@@ -107,82 +120,69 @@ type ClusterMonitoringSpec struct {
// When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
// +optional
PrometheusOperatorAdmissionWebhookConfig PrometheusOperatorAdmissionWebhookConfig `json:"prometheusOperatorAdmissionWebhookConfig,omitempty,omitzero"`
-}
-
-// UserDefinedMonitoring config for user-defined projects.
-type UserDefinedMonitoring struct {
- // mode defines the different configurations of UserDefinedMonitoring
- // Valid values are Disabled and NamespaceIsolated
- // Disabled disables monitoring for user-defined projects. This restricts the default monitoring stack, installed in the openshift-monitoring project, to monitor only platform namespaces, which prevents any custom monitoring configurations or resources from being applied to user-defined namespaces.
- // NamespaceIsolated enables monitoring for user-defined projects with namespace-scoped tenancy. This ensures that metrics, alerts, and monitoring data are isolated at the namespace level.
- // The current default value is `Disabled`.
- // +required
- // +kubebuilder:validation:Enum=Disabled;NamespaceIsolated
- Mode UserDefinedMode `json:"mode"`
-}
-
-// UserDefinedMode specifies mode for UserDefine Monitoring
-// +enum
-type UserDefinedMode string
-
-const (
- // UserDefinedDisabled disables monitoring for user-defined projects. This restricts the default monitoring stack, installed in the openshift-monitoring project, to monitor only platform namespaces, which prevents any custom monitoring configurations or resources from being applied to user-defined namespaces.
- UserDefinedDisabled UserDefinedMode = "Disabled"
- // UserDefinedNamespaceIsolated enables monitoring for user-defined projects with namespace-scoped tenancy. This ensures that metrics, alerts, and monitoring data are isolated at the namespace level.
- UserDefinedNamespaceIsolated UserDefinedMode = "NamespaceIsolated"
-)
-
-// alertmanagerConfig provides configuration options for the default Alertmanager instance
-// that runs in the `openshift-monitoring` namespace. Use this configuration to control
-// whether the default Alertmanager is deployed, how it logs, and how its pods are scheduled.
-// +kubebuilder:validation:XValidation:rule="self.deploymentMode == 'CustomConfig' ? has(self.customConfig) : !has(self.customConfig)",message="customConfig is required when deploymentMode is CustomConfig, and forbidden otherwise"
-type AlertmanagerConfig struct {
- // deploymentMode determines whether the default Alertmanager instance should be deployed
- // as part of the monitoring stack.
- // Allowed values are Disabled, DefaultConfig, and CustomConfig.
- // When set to Disabled, the Alertmanager instance will not be deployed.
- // When set to DefaultConfig, the platform will deploy Alertmanager with default settings.
- // When set to CustomConfig, the Alertmanager will be deployed with custom configuration.
- //
- // +unionDiscriminator
- // +required
- DeploymentMode AlertManagerDeployMode `json:"deploymentMode,omitempty"`
-
- // customConfig must be set when deploymentMode is CustomConfig, and must be unset otherwise.
- // When set to CustomConfig, the Alertmanager will be deployed with custom configuration.
+ // openShiftStateMetricsConfig is an optional field that can be used to configure the openshift-state-metrics
+ // agent that runs in the openshift-monitoring namespace. The openshift-state-metrics agent generates metrics
+ // about the state of OpenShift-specific Kubernetes objects, such as routes, builds, and deployments.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
// +optional
- CustomConfig AlertmanagerCustomConfig `json:"customConfig,omitempty,omitzero"`
+ OpenShiftStateMetricsConfig OpenShiftStateMetricsConfig `json:"openShiftStateMetricsConfig,omitempty,omitzero"`
+ // telemeterClientConfig is an optional field that can be used to configure the Telemeter Client
+ // component that runs in the openshift-monitoring namespace. The Telemeter Client collects
+ // selected monitoring metrics and forwards them to Red Hat for telemetry purposes.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // When set, at least one field must be specified within telemeterClientConfig.
+ // +optional
+ TelemeterClientConfig TelemeterClientConfig `json:"telemeterClientConfig,omitempty,omitzero"`
+ // thanosQuerierConfig is an optional field that can be used to configure the Thanos Querier
+ // component that runs in the openshift-monitoring namespace. The Thanos Querier provides
+ // a global query view by aggregating and deduplicating metrics from multiple Prometheus instances.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The current default deploys the Thanos Querier on linux nodes with 5m CPU and 12Mi memory
+ // requests, and no custom tolerations or topology spread constraints.
+ // When set, at least one field must be specified within thanosQuerierConfig.
+ // +optional
+ ThanosQuerierConfig ThanosQuerierConfig `json:"thanosQuerierConfig,omitempty,omitzero"`
+ // nodeExporterConfig is an optional field that can be used to configure the node-exporter agent
+ // that runs as a DaemonSet in the openshift-monitoring namespace. The node-exporter agent collects
+ // hardware and OS-level metrics from every node in the cluster.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // +optional
+ NodeExporterConfig NodeExporterConfig `json:"nodeExporterConfig,omitempty,omitzero"`
+ // monitoringPluginConfig is an optional field that can be used to configure the monitoring plugin
+ // that runs as a dynamic plugin of the OpenShift web console. The monitoring plugin provides
+ // the monitoring UI in the OpenShift web console for visualizing metrics, alerts, and dashboards.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The current default deploys the monitoring-plugin as a single-replica Deployment
+ // on linux nodes with 10m CPU and 50Mi memory requests, and no custom tolerations
+ // or topology spread constraints.
+ // When set, at least one field must be specified within monitoringPluginConfig.
+ // +optional
+ MonitoringPluginConfig MonitoringPluginConfig `json:"monitoringPluginConfig,omitempty,omitzero"`
+ // kubeStateMetricsConfig is an optional field that can be used to configure the kube-state-metrics
+ // agent that runs in the openshift-monitoring namespace. kube-state-metrics generates metrics about
+ // the state of Kubernetes objects such as Deployments, Nodes, and Pods.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // +optional
+ KubeStateMetricsConfig KubeStateMetricsConfig `json:"kubeStateMetricsConfig,omitempty,omitzero"`
}
-// AlertmanagerCustomConfig represents the configuration for a custom Alertmanager deployment.
-// alertmanagerCustomConfig provides configuration options for the default Alertmanager instance
-// that runs in the `openshift-monitoring` namespace. Use this configuration to control
-// whether the default Alertmanager is deployed, how it logs, and how its pods are scheduled.
+// OpenShiftStateMetricsConfig provides configuration options for the openshift-state-metrics agent
+// that runs in the `openshift-monitoring` namespace. The openshift-state-metrics agent generates
+// metrics about the state of OpenShift-specific Kubernetes objects, such as routes, builds, and deployments.
// +kubebuilder:validation:MinProperties=1
-type AlertmanagerCustomConfig struct {
- // logLevel defines the verbosity of logs emitted by Alertmanager.
- // This field allows users to control the amount and severity of logs generated, which can be useful
- // for debugging issues or reducing noise in production environments.
- // Allowed values are Error, Warn, Info, and Debug.
- // When set to Error, only errors will be logged.
- // When set to Warn, both warnings and errors will be logged.
- // When set to Info, general information, warnings, and errors will all be logged.
- // When set to Debug, detailed debugging information will be logged.
- // When omitted, this means no opinion and the platform is left to choose a reasonable default, that is subject to change over time.
- // The current default value is `Info`.
- // +optional
- LogLevel LogLevel `json:"logLevel,omitempty"`
- // nodeSelector defines the nodes on which the Pods are scheduled
+type OpenShiftStateMetricsConfig struct {
+ // nodeSelector defines the nodes on which the Pods are scheduled.
// nodeSelector is optional.
//
// When omitted, this means the user has no opinion and the platform is left
// to choose reasonable defaults. These defaults are subject to change over time.
// The current default value is `kubernetes.io/os: linux`.
+ // When specified, nodeSelector must contain at least 1 entry and must not contain more than 10 entries.
// +optional
// +kubebuilder:validation:MinProperties=1
// +kubebuilder:validation:MaxProperties=10
NodeSelector map[string]string `json:"nodeSelector,omitempty"`
- // resources defines the compute resource requests and limits for the Alertmanager container.
+ // resources defines the compute resource requests and limits for the openshift-state-metrics container.
// This includes CPU, memory and HugePages constraints to help control scheduling and resource usage.
// When not specified, defaults are used by the platform. Requests cannot exceed limits.
// This field is optional.
@@ -191,41 +191,20 @@ type AlertmanagerCustomConfig struct {
// The current default values are:
// resources:
// - name: cpu
- // request: 4m
+ // request: 1m
// limit: null
// - name: memory
- // request: 40Mi
+ // request: 32Mi
// limit: null
- // Maximum length for this list is 10.
+ // Maximum length for this list is 5.
// Minimum length for this list is 1.
// Each resource name must be unique within this list.
// +optional
// +listType=map
// +listMapKey=name
- // +kubebuilder:validation:MaxItems=10
+ // +kubebuilder:validation:MaxItems=5
// +kubebuilder:validation:MinItems=1
Resources []ContainerResource `json:"resources,omitempty"`
- // secrets defines a list of secrets that need to be mounted into the Alertmanager.
- // The secrets must reside within the same namespace as the Alertmanager object.
- // They will be added as volumes named secret- and mounted at
- // /etc/alertmanager/secrets/ within the 'alertmanager' container of
- // the Alertmanager Pods.
- //
- // These secrets can be used to authenticate Alertmanager with endpoint receivers.
- // For example, you can use secrets to:
- // - Provide certificates for TLS authentication with receivers that require private CA certificates
- // - Store credentials for Basic HTTP authentication with receivers that require password-based auth
- // - Store any other authentication credentials needed by your alert receivers
- //
- // This field is optional.
- // Maximum length for this list is 10.
- // Minimum length for this list is 1.
- // Entries in this list must be unique.
- // +optional
- // +kubebuilder:validation:MaxItems=10
- // +kubebuilder:validation:MinItems=1
- // +listType=set
- Secrets []SecretName `json:"secrets,omitempty"`
// tolerations defines tolerations for the pods.
// tolerations is optional.
//
@@ -239,7 +218,7 @@ type AlertmanagerCustomConfig struct {
// +listType=atomic
// +optional
Tolerations []v1.Toleration `json:"tolerations,omitempty"`
- // topologySpreadConstraints defines rules for how Alertmanager Pods should be distributed
+ // topologySpreadConstraints defines rules for how openshift-state-metrics Pods should be distributed
// across topology domains such as zones, nodes, or other user-defined labels.
// topologySpreadConstraints is optional.
// This helps improve high availability and resource efficiency by avoiding placing
@@ -258,136 +237,2334 @@ type AlertmanagerCustomConfig struct {
// +listMapKey=whenUnsatisfiable
// +optional
TopologySpreadConstraints []v1.TopologySpreadConstraint `json:"topologySpreadConstraints,omitempty"`
- // volumeClaimTemplate Defines persistent storage for Alertmanager. Use this setting to
- // configure the persistent volume claim, including storage class, volume
- // size, and name.
- // If omitted, the Pod uses ephemeral storage and alert data will not persist
- // across restarts.
+}
+
+// NodeExporterConfig provides configuration options for the node-exporter agent
+// that runs as a DaemonSet in the `openshift-monitoring` namespace. The node-exporter agent collects
+// hardware and OS-level metrics from every node in the cluster, including CPU, memory, disk, and
+// network statistics.
+// At least one field must be specified.
+// +kubebuilder:validation:MinProperties=1
+type NodeExporterConfig struct {
+ // resources defines the compute resource requests and limits for the node-exporter container.
+ // This includes CPU, memory and HugePages constraints to help control scheduling and resource usage.
+ // When not specified, defaults are used by the platform. Requests cannot exceed limits.
// This field is optional.
+ // More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/
+ // This is a simplified API that maps to Kubernetes ResourceRequirements.
+ // The current default values are:
+ // resources:
+ // - name: cpu
+ // request: 8m
+ // limit: null
+ // - name: memory
+ // request: 32Mi
+ // limit: null
+ // ---
+ // maxItems is set to 5 to stay within the Kubernetes CRD CEL validation cost budget.
+ // See the MaxItems comment near the ContainerResource type definition for details.
+ // Minimum length for this list is 1.
+ // Each resource name must be unique within this list.
+ // +optional
+ // +listType=map
+ // +listMapKey=name
+ // +kubebuilder:validation:MaxItems=5
+ // +kubebuilder:validation:MinItems=1
+ Resources []ContainerResource `json:"resources,omitempty"`
+
+ // --- TOMBSTONE ---
+ // nodeSelector was a field that defined the nodes on which the Pods are scheduled.
+ // It was removed because node-exporter runs as a DaemonSet on all nodes,
+ // and the CMO does not support this field.
+ // The field name "nodeSelector" and json tag are reserved to prevent reuse
+ // with a different backing type.
+ //
// +optional
- VolumeClaimTemplate *v1.PersistentVolumeClaim `json:"volumeClaimTemplate,omitempty"`
+ // NodeSelector map[string]string `json:"nodeSelector,omitempty"`
+
+ // --- TOMBSTONE ---
+ // tolerations was a field that defined tolerations for the pods.
+ // It was removed because node-exporter runs as a DaemonSet on all nodes,
+ // and the CMO does not support this field.
+ // The field name "tolerations" and json tag are reserved to prevent reuse
+ // with a different backing type.
+ //
+ // +optional
+ // Tolerations []v1.Toleration `json:"tolerations,omitempty"`
+
+ // collectors configures which node-exporter metric collectors are enabled.
+ // collectors is optional.
+ // Each collector can be individually enabled or disabled. Some collectors may have
+ // additional configuration options.
+ //
+ // When omitted, this means no opinion and the platform is left to choose a reasonable
+ // default, which is subject to change over time.
+ // +optional
+ Collectors NodeExporterCollectorConfig `json:"collectors,omitempty,omitzero"`
+ // maxProcs sets the target number of CPUs on which the node-exporter process will run.
+ // maxProcs is optional.
+ // Use this setting to override the default value, which is set either to 4 or to the number
+ // of CPUs on the host, whichever is smaller.
+ // The default value is computed at runtime and set via the GOMAXPROCS environment variable before
+ // node-exporter is launched.
+ // If a kernel deadlock occurs or if performance degrades when reading from sysfs concurrently,
+ // you can change this value to 1, which limits node-exporter to running on one CPU.
+ // For nodes with a high CPU count, setting the limit to a low number saves resources by preventing
+ // Go routines from being scheduled to run on all CPUs. However, I/O performance degrades if the
+ // maxProcs value is set too low and there are many metrics to collect.
+ // The minimum value is 1 and the maximum value is 1024.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is min(4, number of host CPUs).
+ // +optional
+ // +kubebuilder:validation:Minimum=1
+ // +kubebuilder:validation:Maximum=1024
+ MaxProcs int32 `json:"maxProcs,omitempty"`
+ // ignoredNetworkDevices is a list of regular expression patterns that match network devices
+ // to be excluded from the relevant collector configuration such as netdev, netclass, and ethtool.
+ // ignoredNetworkDevices is optional.
+ //
+ // When omitted, the Cluster Monitoring Operator uses a predefined list of devices to be excluded
+ // to minimize the impact on memory usage.
+ // When set as an empty list, no devices are excluded.
+ // If you modify this setting, monitor the prometheus-k8s deployment closely for excessive memory usage.
+ // Maximum length for this list is 50.
+ // Each entry must be at least 1 character and at most 1024 characters long.
+ // +kubebuilder:validation:MaxItems=50
+ // +kubebuilder:validation:MinItems=0
+ // +listType=set
+ // +optional
+ IgnoredNetworkDevices *[]NodeExporterIgnoredNetworkDevice `json:"ignoredNetworkDevices,omitempty"`
}
-// AlertManagerDeployMode defines the deployment state of the platform Alertmanager instance.
-//
-// Possible values:
-// - "Disabled": The Alertmanager instance will not be deployed.
-// - "DefaultConfig": The Alertmanager instance will be deployed with default settings.
-// - "CustomConfig": The Alertmanager instance will be deployed with custom configuration.
-// +kubebuilder:validation:Enum=Disabled;DefaultConfig;CustomConfig
-type AlertManagerDeployMode string
+// NodeExporterIgnoredNetworkDevice is a string that is interpreted as a Go regular expression
+// pattern by the controller to match network device names to exclude from node-exporter
+// metric collection for collectors such as netdev, netclass, and ethtool.
+// Invalid regular expressions will cause a controller-level error at runtime.
+// Must be at least 1 character and at most 1024 characters.
+// +kubebuilder:validation:MinLength=1
+// +kubebuilder:validation:MaxLength=1024
+type NodeExporterIgnoredNetworkDevice string
+
+// NodeExporterCollectorCollectionPolicy declares whether a node-exporter collector should collect metrics.
+// Valid values are "Collect" and "DoNotCollect".
+// +kubebuilder:validation:Enum=Collect;DoNotCollect
+// +enum
+type NodeExporterCollectorCollectionPolicy string
const (
- // AlertManagerModeDisabled means the Alertmanager instance will not be deployed.
- AlertManagerDeployModeDisabled AlertManagerDeployMode = "Disabled"
- // AlertManagerModeDefaultConfig means the Alertmanager instance will be deployed with default settings.
- AlertManagerDeployModeDefaultConfig AlertManagerDeployMode = "DefaultConfig"
- // AlertManagerModeCustomConfig means the Alertmanager instance will be deployed with custom configuration.
- AlertManagerDeployModeCustomConfig AlertManagerDeployMode = "CustomConfig"
+ // NodeExporterCollectorCollectionPolicyCollect means the collector is active and will produce metrics.
+ NodeExporterCollectorCollectionPolicyCollect NodeExporterCollectorCollectionPolicy = "Collect"
+ // NodeExporterCollectorCollectionPolicyDoNotCollect means the collector is inactive and will not produce metrics.
+ NodeExporterCollectorCollectionPolicyDoNotCollect NodeExporterCollectorCollectionPolicy = "DoNotCollect"
)
-// logLevel defines the verbosity of logs emitted by Alertmanager.
-// Valid values are Error, Warn, Info and Debug.
-// +kubebuilder:validation:Enum=Error;Warn;Info;Debug
-type LogLevel string
+// NodeExporterNetclassStatsGatherer identifies how the netclass collector gathers device statistics
+// (for example via sysfs or netlink, as implemented in node_exporter).
+// Valid values are "Sysfs" and "Netlink".
+// +kubebuilder:validation:Enum=Sysfs;Netlink
+// +enum
+type NodeExporterNetclassStatsGatherer string
const (
- // Error only errors will be logged.
- LogLevelError LogLevel = "Error"
- // Warn, both warnings and errors will be logged.
- LogLevelWarn LogLevel = "Warn"
- // Info, general information, warnings, and errors will all be logged.
- LogLevelInfo LogLevel = "Info"
- // Debug, detailed debugging information will be logged.
- LogLevelDebug LogLevel = "Debug"
+ // NodeExporterNetclassStatsGathererSysfs uses the sysfs-based implementation.
+ NodeExporterNetclassStatsGathererSysfs NodeExporterNetclassStatsGatherer = "Sysfs"
+ // NodeExporterNetclassStatsGathererNetlink uses the netlink-based implementation.
+ NodeExporterNetclassStatsGathererNetlink NodeExporterNetclassStatsGatherer = "Netlink"
)
-// ContainerResource defines a single resource requirement for a container.
-// +kubebuilder:validation:XValidation:rule="has(self.request) || has(self.limit)",message="at least one of request or limit must be set"
-// +kubebuilder:validation:XValidation:rule="!(has(self.request) && has(self.limit)) || quantity(self.limit).compareTo(quantity(self.request)) >= 0",message="limit must be greater than or equal to request"
-type ContainerResource struct {
- // name of the resource (e.g. "cpu", "memory", "hugepages-2Mi").
+// NodeExporterCollectorConfig defines settings for individual collectors
+// of the node-exporter agent. Each collector can be individually set to collect or not collect metrics.
+// At least one collector must be specified.
+// +kubebuilder:validation:MinProperties=1
+type NodeExporterCollectorConfig struct {
+ // cpuFreq configures the cpufreq collector, which collects CPU frequency statistics.
+ // cpuFreq is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is disabled.
+ // Consider enabling when you need to observe CPU frequency scaling; expect higher CPU usage on
+ // many-core nodes when collectionPolicy is Collect.
+ // +optional
+ CpuFreq NodeExporterCollectorCpufreqConfig `json:"cpuFreq,omitempty,omitzero"`
+ // tcpStat configures the tcpstat collector, which collects TCP connection statistics.
+ // tcpStat is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is disabled.
+ // Enable when debugging TCP connection behavior or capacity at the node level.
+ // +optional
+ TcpStat NodeExporterCollectorTcpStatConfig `json:"tcpStat,omitempty,omitzero"`
+ // ethtool configures the ethtool collector, which collects ethernet device statistics.
+ // ethtool is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is disabled.
+ // Enable when you need NIC driver-level ethtool metrics beyond generic netdev counters.
+ // +optional
+ Ethtool NodeExporterCollectorEthtoolConfig `json:"ethtool,omitempty,omitzero"`
+ // netDev configures the netdev collector, which collects network device statistics.
+ // netDev is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is enabled.
+ // Turn off if you must reduce per-interface metric cardinality on hosts with many virtual interfaces.
+ // +optional
+ NetDev NodeExporterCollectorNetDevConfig `json:"netDev,omitempty,omitzero"`
+ // netClass configures the netclass collector, which collects information about network devices.
+ // netClass is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is enabled with netlink mode active.
+ // Use statsGatherer when sysfs vs netlink implementation matters or when matching node_exporter tuning.
+ // +optional
+ NetClass NodeExporterCollectorNetClassConfig `json:"netClass,omitempty,omitzero"`
+ // buddyInfo configures the buddyinfo collector, which collects statistics about memory
+ // fragmentation from the node_buddyinfo_blocks metric. This metric collects data from /proc/buddyinfo.
+ // buddyInfo is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is disabled.
+ // Enable when investigating kernel memory fragmentation; typically for advanced troubleshooting only.
+ // +optional
+ BuddyInfo NodeExporterCollectorBuddyInfoConfig `json:"buddyInfo,omitempty,omitzero"`
+ // mountStats configures the mountstats collector, which collects statistics about NFS volume
+ // I/O activities.
+ // mountStats is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is disabled.
+ // Enabling this collector may produce metrics with high cardinality. If you enable this
+ // collector, closely monitor the prometheus-k8s deployment for excessive memory usage.
+ // Enable when you care about per-mount NFS client statistics.
+ // +optional
+ MountStats NodeExporterCollectorMountStatsConfig `json:"mountStats,omitempty,omitzero"`
+ // ksmd configures the ksmd collector, which collects statistics from the kernel same-page
+ // merger daemon.
+ // ksmd is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is disabled.
+ // Enable on nodes where KSM is in use and you want visibility into merging activity.
+ // +optional
+ Ksmd NodeExporterCollectorKSMDConfig `json:"ksmd,omitempty,omitzero"`
+ // processes configures the processes collector, which collects statistics from processes and
+ // threads running in the system.
+ // processes is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is disabled.
+ // Enable for process/thread-level insight; can be expensive on busy nodes.
+ // +optional
+ Processes NodeExporterCollectorProcessesConfig `json:"processes,omitempty,omitzero"`
+ // systemd configures the systemd collector, which collects statistics on the systemd daemon
+ // and its managed services.
+ // systemd is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is disabled.
+ // Enabling this collector with a long list of selected units may produce metrics with high
+ // cardinality. If you enable this collector, closely monitor the prometheus-k8s deployment
+ // for excessive memory usage.
+ // Enable when you need metrics for specific units; scope units carefully.
+ // +optional
+ Systemd NodeExporterCollectorSystemdConfig `json:"systemd,omitempty,omitzero"`
+ // softirqs configures the softirqs collector, which exposes detailed softirq statistics
+ // from /proc/softirqs.
+ // softirqs is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is disabled.
+ // Enable when you need visibility into kernel softirq processing across CPUs.
+ // +optional
+ Softirqs NodeExporterCollectorSoftirqsConfig `json:"softirqs,omitempty,omitzero"`
+ // deviceMapperMultipath configures the dmmultipath collector, which collects statistics
+ // about DM-Multipath devices.
+ // deviceMapperMultipath is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is enabled.
+ // +optional
+ DeviceMapperMultipath NodeExporterCollectorDeviceMapperMultipathConfig `json:"deviceMapperMultipath,omitzero"`
+ // zoneinfo configures the zoneinfo collector, which exposes per-zone memory page counts,
+ // watermarks, and protection thresholds from /proc/zoneinfo.
+ // zoneinfo is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is to not collect zoneinfo metrics.
+ // Enable when you need visibility into kernel memory zone allocation and pressure.
+ // +optional
+ Zoneinfo NodeExporterCollectorZoneinfoConfig `json:"zoneinfo,omitzero"`
+ // nvmExpressSubsystem configures the nvmesubsystem collector, which
+ // collects statistics about NVM Express (NVMe) subsystem devices.
+ // nvmExpressSubsystem is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is enabled.
+ // +optional
+ NVMExpressSubsystem NodeExporterCollectorNVMExpressSubsystemConfig `json:"nvmExpressSubsystem,omitzero"`
+ // interrupts configures the interrupts collector, which exposes interrupt counts
+ // from /proc/interrupts.
+ // interrupts is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is disabled.
+ // The interrupts collector can produce a large number of metrics depending on the hardware
+ // and interrupt sources present. When enabled, the collect field with at least one include
+ // pattern is required to explicitly select which interrupt lines are collected.
+ // +optional
+ Interrupts NodeExporterCollectorInterruptsConfig `json:"interrupts,omitempty,omitzero"`
+}
+
+// NodeExporterCollectorCpufreqConfig provides configuration for the cpufreq collector
+// of the node-exporter agent. The cpufreq collector collects CPU frequency statistics.
+// It is disabled by default.
+type NodeExporterCollectorCpufreqConfig struct {
+ // collectionPolicy declares whether the cpufreq collector collects metrics.
// This field is required.
- // name must consist only of alphanumeric characters, `-`, `_` and `.` and must start and end with an alphanumeric character.
+ // Valid values are "Collect" and "DoNotCollect".
+ // When set to "Collect", the cpufreq collector is active and CPU frequency statistics are collected.
+ // When set to "DoNotCollect", the cpufreq collector is inactive.
// +required
- // +kubebuilder:validation:MinLength=1
- // +kubebuilder:validation:MaxLength=253
- // +kubebuilder:validation:XValidation:rule="!format.qualifiedName().validate(self).hasValue()",message="name must consist only of alphanumeric characters, `-`, `_` and `.` and must start and end with an alphanumeric character"
- Name string `json:"name,omitempty"`
+ CollectionPolicy NodeExporterCollectorCollectionPolicy `json:"collectionPolicy,omitempty"`
+}
- // request is the minimum amount of the resource required (e.g. "2Mi", "1Gi").
- // This field is optional.
- // When limit is specified, request cannot be greater than limit.
+// NodeExporterCollectorTcpStatConfig provides configuration for the tcpstat collector
+// of the node-exporter agent. The tcpstat collector collects TCP connection statistics.
+// It is disabled by default.
+type NodeExporterCollectorTcpStatConfig struct {
+ // collectionPolicy declares whether the tcpstat collector collects metrics.
+ // This field is required.
+ // Valid values are "Collect" and "DoNotCollect".
+ // When set to "Collect", the tcpstat collector is active and TCP connection statistics are collected.
+ // When set to "DoNotCollect", the tcpstat collector is inactive.
+ // +required
+ CollectionPolicy NodeExporterCollectorCollectionPolicy `json:"collectionPolicy,omitempty"`
+}
+
+// NodeExporterCollectorEthtoolConfig provides configuration for the ethtool collector
+// of the node-exporter agent. The ethtool collector collects ethernet device statistics.
+// It is disabled by default.
+type NodeExporterCollectorEthtoolConfig struct {
+ // collectionPolicy declares whether the ethtool collector collects metrics.
+ // This field is required.
+ // Valid values are "Collect" and "DoNotCollect".
+ // When set to "Collect", the ethtool collector is active and ethernet device statistics are collected.
+ // When set to "DoNotCollect", the ethtool collector is inactive.
+ // +required
+ CollectionPolicy NodeExporterCollectorCollectionPolicy `json:"collectionPolicy,omitempty"`
+}
+
+// NodeExporterCollectorNetDevConfig provides configuration for the netdev collector
+// of the node-exporter agent. The netdev collector collects network device statistics
+// such as bytes, packets, errors, and drops per device.
+// It is enabled by default.
+type NodeExporterCollectorNetDevConfig struct {
+ // collectionPolicy declares whether the netdev collector collects metrics.
+ // This field is required.
+ // Valid values are "Collect" and "DoNotCollect".
+ // When set to "Collect", the netdev collector is active and network device statistics are collected.
+ // When set to "DoNotCollect", the netdev collector is inactive and the corresponding metrics become unavailable.
+ // +required
+ CollectionPolicy NodeExporterCollectorCollectionPolicy `json:"collectionPolicy,omitempty"`
+}
+
+// NodeExporterCollectorNetClassConfig provides configuration for the netclass collector
+// of the node-exporter agent. The netclass collector collects information about network devices
+// such as network speed, MTU, and carrier status.
+// It is enabled by default.
+// When collectionPolicy is DoNotCollect, the collect field must not be set.
+// +kubebuilder:validation:XValidation:rule="has(self.collectionPolicy) && self.collectionPolicy == 'Collect' ? true : !has(self.collect)",message="collect may be set when collectionPolicy is Collect, and forbidden otherwise"
+// +union
+type NodeExporterCollectorNetClassConfig struct {
+ // collectionPolicy declares whether the netclass collector collects metrics.
+ // This field is required.
+ // Valid values are "Collect" and "DoNotCollect".
+ // When set to "Collect", the netclass collector is active and network class information is collected.
+ // When set to "DoNotCollect", the netclass collector is inactive and the corresponding metrics become unavailable.
+ // When set to "DoNotCollect", the collect field must not be set.
+ // +unionDiscriminator
+ // +required
+ CollectionPolicy NodeExporterCollectorCollectionPolicy `json:"collectionPolicy,omitempty"`
+ // collect contains configuration options that apply only when the netclass collector is actively collecting metrics
+ // (i.e. when collectionPolicy is Collect).
+ // collect is optional and may be omitted even when collectionPolicy is Collect.
+ // collect may only be set when collectionPolicy is Collect.
+ // When set, at least one field must be specified within collect.
+ // +unionMember
// +optional
- // +kubebuilder:validation:XIntOrString
- // +kubebuilder:validation:MaxLength=20
+ Collect NodeExporterCollectorNetClassCollectConfig `json:"collect,omitzero,omitempty"`
+}
+
+// NodeExporterCollectorNetClassCollectConfig holds configuration options for the netclass collector
+// when it is actively collecting metrics. At least one field must be specified.
+// +kubebuilder:validation:MinProperties=1
+type NodeExporterCollectorNetClassCollectConfig struct {
+ // statsGatherer selects which implementation the netclass collector uses to gather statistics (sysfs or netlink).
+ // statsGatherer is optional.
+ // Valid values are "Sysfs" and "Netlink".
+ // When set to "Netlink", the netlink implementation is used; when set to "Sysfs", the sysfs implementation is used.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is Netlink.
+ // +optional
+ StatsGatherer NodeExporterNetclassStatsGatherer `json:"statsGatherer,omitempty"`
+}
+
+// NodeExporterCollectorBuddyInfoConfig provides configuration for the buddyinfo collector
+// of the node-exporter agent. The buddyinfo collector collects statistics about memory fragmentation
+// from the node_buddyinfo_blocks metric using data from /proc/buddyinfo.
+// It is disabled by default.
+type NodeExporterCollectorBuddyInfoConfig struct {
+ // collectionPolicy declares whether the buddyinfo collector collects metrics.
+ // This field is required.
+ // Valid values are "Collect" and "DoNotCollect".
+ // When set to "Collect", the buddyinfo collector is active and memory fragmentation statistics are collected.
+ // When set to "DoNotCollect", the buddyinfo collector is inactive.
+ // +required
+ CollectionPolicy NodeExporterCollectorCollectionPolicy `json:"collectionPolicy,omitempty"`
+}
+
+// NodeExporterCollectorMountStatsConfig provides configuration for the mountstats collector
+// of the node-exporter agent. The mountstats collector collects statistics about NFS volume I/O activities.
+// It is disabled by default.
+// Enabling this collector may produce metrics with high cardinality. If you enable this
+// collector, closely monitor the prometheus-k8s deployment for excessive memory usage.
+type NodeExporterCollectorMountStatsConfig struct {
+ // collectionPolicy declares whether the mountstats collector collects metrics.
+ // This field is required.
+ // Valid values are "Collect" and "DoNotCollect".
+ // When set to "Collect", the mountstats collector is active and NFS volume I/O statistics are collected.
+ // When set to "DoNotCollect", the mountstats collector is inactive.
+ // +required
+ CollectionPolicy NodeExporterCollectorCollectionPolicy `json:"collectionPolicy,omitempty"`
+}
+
+// NodeExporterCollectorKSMDConfig provides configuration for the ksmd collector
+// of the node-exporter agent. The ksmd collector collects statistics from the kernel
+// same-page merger daemon.
+// It is disabled by default.
+type NodeExporterCollectorKSMDConfig struct {
+ // collectionPolicy declares whether the ksmd collector collects metrics.
+ // This field is required.
+ // Valid values are "Collect" and "DoNotCollect".
+ // When set to "Collect", the ksmd collector is active and kernel same-page merger statistics are collected.
+ // When set to "DoNotCollect", the ksmd collector is inactive.
+ // +required
+ CollectionPolicy NodeExporterCollectorCollectionPolicy `json:"collectionPolicy,omitempty"`
+}
+
+// NodeExporterCollectorProcessesConfig provides configuration for the processes collector
+// of the node-exporter agent. The processes collector collects statistics from processes and threads
+// running in the system.
+// It is disabled by default.
+type NodeExporterCollectorProcessesConfig struct {
+ // collectionPolicy declares whether the processes collector collects metrics.
+ // This field is required.
+ // Valid values are "Collect" and "DoNotCollect".
+ // When set to "Collect", the processes collector is active and process/thread statistics are collected.
+ // When set to "DoNotCollect", the processes collector is inactive.
+ // +required
+ CollectionPolicy NodeExporterCollectorCollectionPolicy `json:"collectionPolicy,omitempty"`
+}
+
+// NodeExporterCollectorSystemdConfig provides configuration for the systemd collector
+// of the node-exporter agent. The systemd collector collects statistics on the systemd daemon
+// and its managed services.
+// It is disabled by default.
+// Enabling this collector with a long list of selected units may produce metrics with high
+// cardinality. If you enable this collector, closely monitor the prometheus-k8s deployment
+// for excessive memory usage.
+// When collectionPolicy is DoNotCollect, the collect field must not be set.
+// +kubebuilder:validation:XValidation:rule="has(self.collectionPolicy) && self.collectionPolicy == 'Collect' ? true : !has(self.collect)",message="collect may be set when collectionPolicy is Collect, and forbidden otherwise"
+// +union
+type NodeExporterCollectorSystemdConfig struct {
+ // collectionPolicy declares whether the systemd collector collects metrics.
+ // This field is required.
+ // Valid values are "Collect" and "DoNotCollect".
+ // When set to "Collect", the systemd collector is active and systemd unit statistics are collected.
+ // When set to "DoNotCollect", the systemd collector is inactive and the collect field must not be set.
+ // +unionDiscriminator
+ // +required
+ CollectionPolicy NodeExporterCollectorCollectionPolicy `json:"collectionPolicy,omitempty"`
+ // collect contains configuration options that apply only when the systemd collector is actively collecting metrics
+ // (i.e. when collectionPolicy is Collect).
+ // collect is optional and may be omitted even when collectionPolicy is Collect.
+ // collect may only be set when collectionPolicy is Collect.
+ // When set, at least one field must be specified within collect.
+ // +unionMember
+ // +optional
+ Collect NodeExporterCollectorSystemdCollectConfig `json:"collect,omitzero,omitempty"`
+}
+
+// NodeExporterCollectorSystemdCollectConfig holds configuration options for the systemd collector
+// when it is actively collecting metrics. At least one field must be specified.
+// +kubebuilder:validation:MinProperties=1
+type NodeExporterCollectorSystemdCollectConfig struct {
+ // units is a list of regular expression patterns that match systemd units to be included
+ // by the systemd collector.
+ // units is optional.
+ // By default, the list is empty, so the collector exposes no metrics for systemd units.
+ // Each entry is a regular expression pattern and must be at least 1 character and at most 1024 characters.
+ // Maximum length for this list is 50.
+ // Minimum length for this list is 1.
+ // Entries in this list must be unique.
+ // +kubebuilder:validation:MaxItems=50
+ // +kubebuilder:validation:MinItems=1
+ // +listType=set
+ // +optional
+ Units []NodeExporterSystemdUnit `json:"units,omitempty"`
+}
+
+// NodeExporterSystemdUnit is a string that is interpreted as a Go regular expression
+// pattern by the controller to match systemd unit names.
+// Invalid regular expressions will cause a controller-level error at runtime.
+// Must be at least 1 character and at most 1024 characters.
+// +kubebuilder:validation:MinLength=1
+// +kubebuilder:validation:MaxLength=1024
+type NodeExporterSystemdUnit string
+
+// NodeExporterCollectorSoftirqsConfig provides configuration for the softirqs collector
+// of the node-exporter agent. The softirqs collector exposes detailed softirq statistics
+// from /proc/softirqs.
+// It is disabled by default.
+type NodeExporterCollectorSoftirqsConfig struct {
+ // collectionPolicy declares whether the softirqs collector collects metrics.
+ // This field is required.
+ // Valid values are "Collect" and "DoNotCollect".
+ // When set to "Collect", the softirqs collector is active and softirq statistics are collected.
+ // When set to "DoNotCollect", the softirqs collector is inactive.
+ // +required
+ CollectionPolicy NodeExporterCollectorCollectionPolicy `json:"collectionPolicy,omitempty"`
+}
+
+// NodeExporterCollectorDeviceMapperMultipathConfig provides configuration for the dmmultipath collector
+// of the node-exporter agent. The dmmultipath collector collects statistics about
+// DM-Multipath devices.
+// It is enabled by default.
+type NodeExporterCollectorDeviceMapperMultipathConfig struct {
+ // collectionPolicy declares whether the dmmultipath collector collects metrics.
+ // This field is required.
+ // Valid values are "Collect" and "DoNotCollect".
+ // When set to "Collect", the dmmultipath collector is active and DM-Multipath device statistics are collected.
+ // When set to "DoNotCollect", the dmmultipath collector is inactive and the corresponding metrics become unavailable.
+ // +required
+ CollectionPolicy NodeExporterCollectorCollectionPolicy `json:"collectionPolicy,omitempty"`
+}
+
+// NodeExporterCollectorZoneinfoConfig provides configuration for the zoneinfo collector
+// of the node-exporter agent. The zoneinfo collector exposes per-zone memory page counts,
+// watermarks, and protection thresholds from /proc/zoneinfo.
+// By default, the zoneinfo collector does not collect metrics.
+type NodeExporterCollectorZoneinfoConfig struct {
+ // collectionPolicy declares whether the zoneinfo collector collects metrics.
+ // This field is required.
+ // Valid values are "Collect" and "DoNotCollect".
+ // When set to "Collect", the zoneinfo collector is active and zone memory statistics are collected.
+ // When set to "DoNotCollect", the zoneinfo collector is inactive.
+ // +required
+ CollectionPolicy NodeExporterCollectorCollectionPolicy `json:"collectionPolicy,omitempty"`
+}
+
+// NodeExporterCollectorNVMExpressSubsystemConfig provides configuration for
+// the nvmesubsystem collector of the node-exporter agent. The nvmesubsystem
+// collector collects statistics about NVM Express (NVMe) subsystem devices.
+// It is enabled by default.
+type NodeExporterCollectorNVMExpressSubsystemConfig struct {
+ // collectionPolicy declares whether the nvmesubsystem collector collects metrics.
+ // This field is required.
+ // Valid values are "Collect" and "DoNotCollect".
+ // When set to "Collect", the nvmesubsystem collector is active and NVMe subsystem statistics are collected.
+ // When set to "DoNotCollect", the nvmesubsystem collector is inactive and the corresponding metrics become unavailable.
+ // +required
+ CollectionPolicy NodeExporterCollectorCollectionPolicy `json:"collectionPolicy,omitempty"`
+}
+
+// NodeExporterCollectorInterruptsConfig provides configuration for the interrupts collector
+// of the node-exporter agent. The interrupts collector exposes interrupt counts
+// from /proc/interrupts.
+// It is disabled by default.
+// The interrupts collector can produce a large number of metrics depending on the hardware
+// and interrupt sources present. When enabled, the collect field with at least one include
+// pattern is required to explicitly select which interrupt lines are collected.
+// When collectionPolicy is Collect, the collect field must be set with at least one include pattern.
+// When collectionPolicy is DoNotCollect, the collect field must not be set.
+// +kubebuilder:validation:XValidation:rule="has(self.collectionPolicy) && self.collectionPolicy == 'Collect' ? has(self.collect) : !has(self.collect)",message="collect is required when collectionPolicy is Collect, and forbidden otherwise"
+// +union
+type NodeExporterCollectorInterruptsConfig struct {
+ // collectionPolicy declares whether the interrupts collector collects metrics.
+ // This field is required.
+ // Valid values are "Collect" and "DoNotCollect".
+ // When set to "Collect", the interrupts collector is active and the collect field must be set
+ // with at least one include pattern to select which interrupt lines are collected.
+ // When set to "DoNotCollect", the interrupts collector is inactive and the collect field must not be set.
+ // +unionDiscriminator
+ // +required
+ CollectionPolicy NodeExporterCollectorCollectionPolicy `json:"collectionPolicy,omitempty"`
+ // collect contains configuration options that apply only when the interrupts collector is actively collecting metrics
+ // (i.e. when collectionPolicy is Collect).
+ // collect is required when collectionPolicy is Collect and must contain at least one include pattern
+ // to explicitly select which interrupt lines are collected.
+ // collect must not be set when collectionPolicy is DoNotCollect.
+ // When set, at least one field must be specified within collect.
+ // +unionMember
+ // +optional
+ Collect NodeExporterCollectorInterruptsCollectConfig `json:"collect,omitzero,omitempty"`
+}
+
+// NodeExporterCollectorInterruptsCollectConfig holds configuration options for the interrupts collector
+// when it is actively collecting metrics. At least one field must be specified.
+// +kubebuilder:validation:MinProperties=1
+type NodeExporterCollectorInterruptsCollectConfig struct {
+ // include is a list of regular expression patterns that select which interrupt lines to collect.
+ // This field is required.
+ // Each line in /proc/interrupts is matched against the same string node-exporter uses:
+ // the IRQ name, info, and devices fields joined with ";", for example "LOC;77;IO-APIC 2-edge ...".
+ // Patterns are combined with OR into a single expression anchored on both ends,
+ // so each pattern must match the entire string (use ".*" where needed).
+ // Each entry must be at least 1 character, at most 1024 characters, and only contain printable ASCII characters.
+ // Maximum length for this list is 50.
+ // Minimum length for this list is 1.
+ // Entries in this list must be unique.
+ // +kubebuilder:validation:MaxItems=50
+ // +kubebuilder:validation:MinItems=1
+ // +listType=set
+ // +required
+ Include []NodeExporterInterruptsIncludePattern `json:"include,omitempty"`
+}
+
+// NodeExporterInterruptsIncludePattern is a string that is interpreted as a Go regular expression
+// pattern by the controller to match interrupt line names.
+// Invalid regular expressions will cause a controller-level error at runtime.
+// Must be at least 1 character and at most 1024 characters.
+// Must contain only printable ASCII characters (no control characters).
+// +kubebuilder:validation:MinLength=1
+// +kubebuilder:validation:MaxLength=1024
+// +kubebuilder:validation:XValidation:rule="self.matches('^[\\\\x20-\\\\x7E]+$')",message="must contain only printable ASCII characters (no control characters)"
+type NodeExporterInterruptsIncludePattern string
+
+// MonitoringPluginConfig provides configuration options for the monitoring plugin
+// that runs as a dynamic plugin of the OpenShift web console.
+// The monitoring plugin provides the monitoring UI in the OpenShift web console
+// for visualizing metrics, alerts, and dashboards.
+// At least one field must be specified; an empty monitoringPluginConfig object is not allowed.
+// +kubebuilder:validation:MinProperties=1
+type MonitoringPluginConfig struct {
+ // nodeSelector defines the nodes on which the Pods are scheduled.
+ // nodeSelector is optional.
+ //
+ // When omitted, this means the user has no opinion and the platform is left
+ // to choose reasonable defaults. These defaults are subject to change over time.
+ // The current default value is `kubernetes.io/os: linux`.
+ // When specified, nodeSelector must contain at least 1 entry and must not contain more than 10 entries.
+ // +optional
+ // +kubebuilder:validation:MinProperties=1
+ // +kubebuilder:validation:MaxProperties=10
+ NodeSelector map[string]string `json:"nodeSelector,omitempty"`
+ // resources defines the compute resource requests and limits for the monitoring-plugin container.
+ // This includes CPU, memory and HugePages constraints to help control scheduling and resource usage.
+ // When not specified, defaults are used by the platform. Requests cannot exceed limits.
+ // This field is optional.
+ // More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/
+ // This is a simplified API that maps to Kubernetes ResourceRequirements.
+ // The current default values are:
+ // resources:
+ // - name: cpu
+ // request: 10m
+ // - name: memory
+ // request: 50Mi
+ //
+ // When specified, resources must contain at least 1 entry and must not exceed 5 entries.
+ // +optional
+ // +listType=map
+ // +listMapKey=name
+ // +kubebuilder:validation:MaxItems=5
+ // +kubebuilder:validation:MinItems=1
+ Resources []ContainerResource `json:"resources,omitempty"`
+ // tolerations defines the tolerations required for the monitoring-plugin Pods.
+ // This field is optional.
+ //
+ // When omitted, the monitoring-plugin Pods will not have any tolerations, which
+ // means they will only be scheduled on nodes with no taints.
+ // When specified, tolerations must contain at least 1 entry and must not contain more than 10 entries.
+ // +optional
+ // +listType=atomic
+ // +kubebuilder:validation:MinItems=1
+ // +kubebuilder:validation:MaxItems=10
+ Tolerations []v1.Toleration `json:"tolerations,omitempty"`
+ // topologySpreadConstraints defines rules for how monitoring-plugin Pods should be distributed
+ // across topology domains such as zones, nodes, or other user-defined labels.
+ // topologySpreadConstraints is optional.
+ // This helps improve high availability and resource efficiency by avoiding placing
+ // too many replicas in the same failure domain.
+ //
+ // When omitted, this means no opinion and the platform is left to choose a default, which is subject to change over time.
+ // This field maps directly to the `topologySpreadConstraints` field in the Pod spec.
+ // Default is empty list.
+ // When specified, this list must contain at least 1 entry and must not exceed 10 entries.
+ // +kubebuilder:validation:MaxItems=10
+ // +kubebuilder:validation:MinItems=1
+ // +listType=map
+ // +listMapKey=topologyKey
+ // +listMapKey=whenUnsatisfiable
+ // +optional
+ TopologySpreadConstraints []v1.TopologySpreadConstraint `json:"topologySpreadConstraints,omitempty"`
+}
+
+// UserDefinedMonitoring config for user-defined projects.
+type UserDefinedMonitoring struct {
+ // mode defines the different configurations of UserDefinedMonitoring
+ // Valid values are Disabled and NamespaceIsolated
+ // Disabled disables monitoring for user-defined projects. This restricts the default monitoring stack, installed in the openshift-monitoring project, to monitor only platform namespaces, which prevents any custom monitoring configurations or resources from being applied to user-defined namespaces.
+ // NamespaceIsolated enables monitoring for user-defined projects with namespace-scoped tenancy. This ensures that metrics, alerts, and monitoring data are isolated at the namespace level.
+ // The current default value is `Disabled`.
+ // +required
+ // +kubebuilder:validation:Enum=Disabled;NamespaceIsolated
+ Mode UserDefinedMode `json:"mode"`
+}
+
+// UserDefinedMode specifies mode for UserDefine Monitoring
+// +enum
+type UserDefinedMode string
+
+const (
+ // UserDefinedDisabled disables monitoring for user-defined projects. This restricts the default monitoring stack, installed in the openshift-monitoring project, to monitor only platform namespaces, which prevents any custom monitoring configurations or resources from being applied to user-defined namespaces.
+ UserDefinedDisabled UserDefinedMode = "Disabled"
+ // UserDefinedNamespaceIsolated enables monitoring for user-defined projects with namespace-scoped tenancy. This ensures that metrics, alerts, and monitoring data are isolated at the namespace level.
+ UserDefinedNamespaceIsolated UserDefinedMode = "NamespaceIsolated"
+)
+
+// alertmanagerConfig provides configuration options for the default Alertmanager instance
+// that runs in the `openshift-monitoring` namespace. Use this configuration to control
+// whether the default Alertmanager is deployed, how it logs, and how its pods are scheduled.
+// +kubebuilder:validation:XValidation:rule="self.deploymentMode == 'CustomConfig' ? has(self.customConfig) : !has(self.customConfig)",message="customConfig is required when deploymentMode is CustomConfig, and forbidden otherwise"
+type AlertmanagerConfig struct {
+ // deploymentMode determines whether the default Alertmanager instance should be deployed
+ // as part of the monitoring stack.
+ // Allowed values are Disabled, DefaultConfig, and CustomConfig.
+ // When set to Disabled, the Alertmanager instance will not be deployed.
+ // When set to DefaultConfig, the platform will deploy Alertmanager with default settings.
+ // When set to CustomConfig, the Alertmanager will be deployed with custom configuration.
+ //
+ // +unionDiscriminator
+ // +required
+ DeploymentMode AlertManagerDeployMode `json:"deploymentMode,omitempty"`
+
+ // customConfig must be set when deploymentMode is CustomConfig, and must be unset otherwise.
+ // When set to CustomConfig, the Alertmanager will be deployed with custom configuration.
+ // +optional
+ CustomConfig AlertmanagerCustomConfig `json:"customConfig,omitempty,omitzero"`
+}
+
+// UserAlertmanagerConfigSelection controls whether the platform Alertmanager selects
+// AlertmanagerConfig resources from user-defined namespaces.
+// +enum
+type UserAlertmanagerConfigSelection string
+
+const (
+ // UserAlertmanagerConfigSelectionSelectable enables user-defined namespaces to be selected
+ // for AlertmanagerConfig lookups on the platform Alertmanager.
+ UserAlertmanagerConfigSelectionSelectable UserAlertmanagerConfigSelection = "Selectable"
+ // UserAlertmanagerConfigSelectionNone disables user-defined namespaces from being selected
+ // for AlertmanagerConfig lookups on the platform Alertmanager.
+ UserAlertmanagerConfigSelectionNone UserAlertmanagerConfigSelection = "None"
+)
+
+// AlertmanagerCustomConfig represents the configuration for a custom Alertmanager deployment.
+// alertmanagerCustomConfig provides configuration options for the default Alertmanager instance
+// that runs in the `openshift-monitoring` namespace. Use this configuration to control
+// whether user-defined namespaces are selected for AlertmanagerConfig lookups, how it logs,
+// and how its pods are scheduled.
+// +kubebuilder:validation:MinProperties=1
+type AlertmanagerCustomConfig struct {
+ // userAlertmanagerConfigSelection is an optional field that controls whether user-defined
+ // namespaces can be selected for AlertmanagerConfig lookups on the platform Alertmanager
+ // instance in the `openshift-monitoring` namespace.
+ // Valid values are Selectable and None.
+ // When set to Selectable, the platform Alertmanager discovers AlertmanagerConfig resources
+ // in user-defined namespaces. This is equivalent to `enableUserAlertmanagerConfig: true` in
+ // the cluster-monitoring-config ConfigMap.
+ // When set to None, user-defined namespaces are not selected for AlertmanagerConfig lookups
+ // on the platform Alertmanager. This is equivalent to `enableUserAlertmanagerConfig: false`
+ // in the cluster-monitoring-config ConfigMap.
+ // This setting only applies when the user-workload monitoring Alertmanager is not enabled.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The current default value is `None`.
+ // +optional
+ // +kubebuilder:validation:Enum=Selectable;None
+ UserAlertmanagerConfigSelection UserAlertmanagerConfigSelection `json:"userAlertmanagerConfigSelection,omitempty"`
+ // logLevel defines the verbosity of logs emitted by Alertmanager.
+ // This field allows users to control the amount and severity of logs generated, which can be useful
+ // for debugging issues or reducing noise in production environments.
+ // Allowed values are Error, Warn, Info, and Debug.
+ // When set to Error, only errors will be logged.
+ // When set to Warn, both warnings and errors will be logged.
+ // When set to Info, general information, warnings, and errors will all be logged.
+ // When set to Debug, detailed debugging information will be logged.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, that is subject to change over time.
+ // The current default value is `Info`.
+ // +optional
+ LogLevel LogLevel `json:"logLevel,omitempty"`
+ // nodeSelector defines the nodes on which the Pods are scheduled
+ // nodeSelector is optional.
+ //
+ // When omitted, this means the user has no opinion and the platform is left
+ // to choose reasonable defaults. These defaults are subject to change over time.
+ // The current default value is `kubernetes.io/os: linux`.
+ // +optional
+ // +kubebuilder:validation:MinProperties=1
+ // +kubebuilder:validation:MaxProperties=10
+ NodeSelector map[string]string `json:"nodeSelector,omitempty"`
+ // resources defines the compute resource requests and limits for the Alertmanager container.
+ // This includes CPU, memory and HugePages constraints to help control scheduling and resource usage.
+ // When not specified, defaults are used by the platform. Requests cannot exceed limits.
+ // This field is optional.
+ // More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/
+ // This is a simplified API that maps to Kubernetes ResourceRequirements.
+ // The current default values are:
+ // resources:
+ // - name: cpu
+ // request: 4m
+ // limit: null
+ // - name: memory
+ // request: 40Mi
+ // limit: null
+ // Maximum length for this list is 5.
+ // Minimum length for this list is 1.
+ // Each resource name must be unique within this list.
+ // +optional
+ // +listType=map
+ // +listMapKey=name
+ // +kubebuilder:validation:MaxItems=5
+ // +kubebuilder:validation:MinItems=1
+ Resources []ContainerResource `json:"resources,omitempty"`
+ // secrets defines a list of secrets that need to be mounted into the Alertmanager.
+ // The secrets must reside within the same namespace as the Alertmanager object.
+ // They will be added as volumes named secret- and mounted at
+ // /etc/alertmanager/secrets/ within the 'alertmanager' container of
+ // the Alertmanager Pods.
+ //
+ // These secrets can be used to authenticate Alertmanager with endpoint receivers.
+ // For example, you can use secrets to:
+ // - Provide certificates for TLS authentication with receivers that require private CA certificates
+ // - Store credentials for Basic HTTP authentication with receivers that require password-based auth
+ // - Store any other authentication credentials needed by your alert receivers
+ //
+ // This field is optional.
+ // Maximum length for this list is 10.
+ // Minimum length for this list is 1.
+ // Entries in this list must be unique.
+ // +optional
+ // +kubebuilder:validation:MaxItems=10
+ // +kubebuilder:validation:MinItems=1
+ // +listType=set
+ Secrets []SecretName `json:"secrets,omitempty"`
+ // tolerations defines tolerations for the pods.
+ // tolerations is optional.
+ //
+ // When omitted, this means the user has no opinion and the platform is left
+ // to choose reasonable defaults. These defaults are subject to change over time.
+ // Defaults are empty/unset.
+ // Maximum length for this list is 10.
+ // Minimum length for this list is 1.
+ // +kubebuilder:validation:MaxItems=10
+ // +kubebuilder:validation:MinItems=1
+ // +listType=atomic
+ // +optional
+ Tolerations []v1.Toleration `json:"tolerations,omitempty"`
+ // topologySpreadConstraints defines rules for how Alertmanager Pods should be distributed
+ // across topology domains such as zones, nodes, or other user-defined labels.
+ // topologySpreadConstraints is optional.
+ // This helps improve high availability and resource efficiency by avoiding placing
+ // too many replicas in the same failure domain.
+ //
+ // When omitted, this means no opinion and the platform is left to choose a default, which is subject to change over time.
+ // This field maps directly to the `topologySpreadConstraints` field in the Pod spec.
+ // Default is empty list.
+ // Maximum length for this list is 10.
+ // Minimum length for this list is 1.
+ // Entries must have unique topologyKey and whenUnsatisfiable pairs.
+ // +kubebuilder:validation:MaxItems=10
+ // +kubebuilder:validation:MinItems=1
+ // +listType=map
+ // +listMapKey=topologyKey
+ // +listMapKey=whenUnsatisfiable
+ // +optional
+ TopologySpreadConstraints []v1.TopologySpreadConstraint `json:"topologySpreadConstraints,omitempty"`
+ // volumeClaimTemplate defines persistent storage for Alertmanager. Use this setting to
+ // configure the persistent volume claim, including storage class and volume size.
+ // If omitted, the Pod uses ephemeral storage and alert data will not persist
+ // across restarts.
+ // +optional
+ VolumeClaimTemplate *v1.PersistentVolumeClaim `json:"volumeClaimTemplate,omitempty,omitzero"`
+}
+
+// AlertManagerDeployMode defines the deployment state of the platform Alertmanager instance.
+//
+// Possible values:
+// - "Disabled": The Alertmanager instance will not be deployed.
+// - "DefaultConfig": The Alertmanager instance will be deployed with default settings.
+// - "CustomConfig": The Alertmanager instance will be deployed with custom configuration.
+// +kubebuilder:validation:Enum=Disabled;DefaultConfig;CustomConfig
+type AlertManagerDeployMode string
+
+const (
+ // AlertManagerModeDisabled means the Alertmanager instance will not be deployed.
+ AlertManagerDeployModeDisabled AlertManagerDeployMode = "Disabled"
+ // AlertManagerModeDefaultConfig means the Alertmanager instance will be deployed with default settings.
+ AlertManagerDeployModeDefaultConfig AlertManagerDeployMode = "DefaultConfig"
+ // AlertManagerModeCustomConfig means the Alertmanager instance will be deployed with custom configuration.
+ AlertManagerDeployModeCustomConfig AlertManagerDeployMode = "CustomConfig"
+)
+
+// LogLevel defines the verbosity of logs emitted by Alertmanager.
+// Valid values are Error, Warn, Info and Debug.
+// +kubebuilder:validation:Enum=Error;Warn;Info;Debug
+type LogLevel string
+
+const (
+ // LogLevelError only errors will be logged.
+ LogLevelError LogLevel = "Error"
+ // LogLevelWarn, both warnings and errors will be logged.
+ LogLevelWarn LogLevel = "Warn"
+ // LogLevelInfo, general information, warnings, and errors will all be logged.
+ LogLevelInfo LogLevel = "Info"
+ // LogLevelDebug, detailed debugging information will be logged.
+ LogLevelDebug LogLevel = "Debug"
+)
+
+// MaxItems on []ContainerResource fields is kept at 5 to stay within the
+// Kubernetes CRD CEL validation cost budget (StaticEstimatedCRDCostLimit).
+// The quantity() CEL function has a high fixed estimated cost per invocation,
+// and the limit-vs-request comparison rule is costed per maxItems per location.
+// With multiple structs in ClusterMonitoringSpec embedding []ContainerResource,
+// maxItems > 5 causes the total estimated rule cost to exceed the budget.
+
+// ContainerResource defines a single resource requirement for a container.
+// +kubebuilder:validation:XValidation:rule="has(self.request) || has(self.limit)",message="at least one of request or limit must be set"
+// +kubebuilder:validation:XValidation:rule="!(has(self.request) && has(self.limit)) || quantity(self.limit).compareTo(quantity(self.request)) >= 0",message="limit must be greater than or equal to request"
+type ContainerResource struct {
+ // name of the resource (e.g. "cpu", "memory", "hugepages-2Mi").
+ // This field is required.
+ // name must consist only of alphanumeric characters, `-`, `_` and `.` and must start and end with an alphanumeric character.
+ // +required
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=253
+ // +kubebuilder:validation:XValidation:rule="!format.qualifiedName().validate(self).hasValue()",message="name must consist only of alphanumeric characters, `-`, `_` and `.` and must start and end with an alphanumeric character"
+ Name string `json:"name,omitempty"`
+
+ // request is the minimum amount of the resource required (e.g. "2Mi", "1Gi").
+ // This field is optional.
+ // When limit is specified, request cannot be greater than limit.
+ // The value must be greater than 0 when specified.
+ // +optional
+ // +kubebuilder:validation:XIntOrString
+ // +kubebuilder:validation:MaxLength=20
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:XValidation:rule="quantity(self).isGreaterThan(quantity('0'))",message="request must be a positive, non-zero quantity"
+ Request resource.Quantity `json:"request,omitempty"`
+
+ // limit is the maximum amount of the resource allowed (e.g. "2Mi", "1Gi").
+ // This field is optional.
+ // When request is specified, limit cannot be less than request.
+ // The value must be greater than 0 when specified.
+ // +optional
+ // +kubebuilder:validation:XIntOrString
+ // +kubebuilder:validation:MaxLength=20
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:XValidation:rule="quantity(self).isGreaterThan(quantity('0'))",message="limit must be a positive, non-zero quantity"
+ Limit resource.Quantity `json:"limit,omitempty"`
+}
+
+// SecretName is a type that represents the name of a Secret in the same namespace.
+// It must be at most 253 characters in length.
+// +kubebuilder:validation:XValidation:rule="!format.dns1123Subdomain().validate(self).hasValue()",message="a lowercase RFC 1123 subdomain must consist of lower case alphanumeric characters, '-' or '.', and must start and end with an alphanumeric character."
+// +kubebuilder:validation:MaxLength=63
+type SecretName string
+
+// MetricsServerConfig provides configuration options for the Metrics Server instance
+// that runs in the `openshift-monitoring` namespace. Use this configuration to control
+// how the Metrics Server instance is deployed, how it logs, and how its pods are scheduled.
+// +kubebuilder:validation:MinProperties=1
+type MetricsServerConfig struct {
+ // audit defines the audit configuration used by the Metrics Server instance.
+ // audit is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, that is subject to change over time.
+ //The current default sets audit.profile to Metadata
+ // +optional
+ Audit Audit `json:"audit,omitempty,omitzero"`
+ // nodeSelector defines the nodes on which the Pods are scheduled
+ // nodeSelector is optional.
+ //
+ // When omitted, this means the user has no opinion and the platform is left
+ // to choose reasonable defaults. These defaults are subject to change over time.
+ // The current default value is `kubernetes.io/os: linux`.
+ // +optional
+ // +kubebuilder:validation:MinProperties=1
+ // +kubebuilder:validation:MaxProperties=10
+ NodeSelector map[string]string `json:"nodeSelector,omitempty"`
+ // tolerations defines tolerations for the pods.
+ // tolerations is optional.
+ //
+ // When omitted, this means the user has no opinion and the platform is left
+ // to choose reasonable defaults. These defaults are subject to change over time.
+ // Defaults are empty/unset.
+ // Maximum length for this list is 10.
+ // Minimum length for this list is 1.
+ // +kubebuilder:validation:MaxItems=10
+ // +kubebuilder:validation:MinItems=1
+ // +listType=atomic
+ // +optional
+ Tolerations []v1.Toleration `json:"tolerations,omitempty"`
+ // verbosity defines the verbosity of log messages for Metrics Server.
+ // Valid values are Errors, Info, Trace, TraceAll and omitted.
+ // When set to Errors, only critical messages and errors are logged.
+ // When set to Info, only basic information messages are logged.
+ // When set to Trace, information useful for general debugging is logged.
+ // When set to TraceAll, detailed information about metric scraping is logged.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, that is subject to change over time.
+ // The current default value is `Errors`
+ // +optional
+ Verbosity VerbosityLevel `json:"verbosity,omitempty,omitzero"`
+ // resources defines the compute resource requests and limits for the Metrics Server container.
+ // This includes CPU, memory and HugePages constraints to help control scheduling and resource usage.
+ // When not specified, defaults are used by the platform. Requests cannot exceed limits.
+ // This field is optional.
+ // More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/
+ // This is a simplified API that maps to Kubernetes ResourceRequirements.
+ // The current default values are:
+ // resources:
+ // - name: cpu
+ // request: 4m
+ // limit: null
+ // - name: memory
+ // request: 40Mi
+ // limit: null
+ // Maximum length for this list is 5.
+ // Minimum length for this list is 1.
+ // Each resource name must be unique within this list.
+ // +optional
+ // +listType=map
+ // +listMapKey=name
+ // +kubebuilder:validation:MaxItems=5
+ // +kubebuilder:validation:MinItems=1
+ Resources []ContainerResource `json:"resources,omitempty"`
+ // topologySpreadConstraints defines rules for how Metrics Server Pods should be distributed
+ // across topology domains such as zones, nodes, or other user-defined labels.
+ // topologySpreadConstraints is optional.
+ // This helps improve high availability and resource efficiency by avoiding placing
+ // too many replicas in the same failure domain.
+ //
+ // When omitted, this means no opinion and the platform is left to choose a default, which is subject to change over time.
+ // This field maps directly to the `topologySpreadConstraints` field in the Pod spec.
+ // Default is empty list.
+ // Maximum length for this list is 10.
+ // Minimum length for this list is 1.
+ // Entries must have unique topologyKey and whenUnsatisfiable pairs.
+ // +kubebuilder:validation:MaxItems=10
+ // +kubebuilder:validation:MinItems=1
+ // +listType=map
+ // +listMapKey=topologyKey
+ // +listMapKey=whenUnsatisfiable
+ // +optional
+ TopologySpreadConstraints []v1.TopologySpreadConstraint `json:"topologySpreadConstraints,omitempty"`
+}
+
+// PrometheusOperatorConfig provides configuration options for the Prometheus Operator instance
+// Use this configuration to control how the Prometheus Operator instance is deployed, how it logs, and how its pods are scheduled.
+// +kubebuilder:validation:MinProperties=1
+type PrometheusOperatorConfig struct {
+ // logLevel defines the verbosity of logs emitted by Prometheus Operator.
+ // This field allows users to control the amount and severity of logs generated, which can be useful
+ // for debugging issues or reducing noise in production environments.
+ // Allowed values are Error, Warn, Info, and Debug.
+ // When set to Error, only errors will be logged.
+ // When set to Warn, both warnings and errors will be logged.
+ // When set to Info, general information, warnings, and errors will all be logged.
+ // When set to Debug, detailed debugging information will be logged.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, that is subject to change over time.
+ // The current default value is `Info`.
+ // +optional
+ LogLevel LogLevel `json:"logLevel,omitempty"`
+ // nodeSelector defines the nodes on which the Pods are scheduled
+ // nodeSelector is optional.
+ //
+ // When omitted, this means the user has no opinion and the platform is left
+ // to choose reasonable defaults. These defaults are subject to change over time.
+ // The current default value is `kubernetes.io/os: linux`.
+ // When specified, nodeSelector must contain at least 1 entry and must not contain more than 10 entries.
+ // +optional
+ // +kubebuilder:validation:MinProperties=1
+ // +kubebuilder:validation:MaxProperties=10
+ NodeSelector map[string]string `json:"nodeSelector,omitempty"`
+ // resources defines the compute resource requests and limits for the Prometheus Operator container.
+ // This includes CPU, memory and HugePages constraints to help control scheduling and resource usage.
+ // When not specified, defaults are used by the platform. Requests cannot exceed limits.
+ // This field is optional.
+ // More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/
+ // This is a simplified API that maps to Kubernetes ResourceRequirements.
+ // The current default values are:
+ // resources:
+ // - name: cpu
+ // request: 4m
+ // limit: null
+ // - name: memory
+ // request: 40Mi
+ // limit: null
+ // Maximum length for this list is 5.
+ // Minimum length for this list is 1.
+ // Each resource name must be unique within this list.
+ // +optional
+ // +listType=map
+ // +listMapKey=name
+ // +kubebuilder:validation:MaxItems=5
+ // +kubebuilder:validation:MinItems=1
+ Resources []ContainerResource `json:"resources,omitempty"`
+ // tolerations defines tolerations for the pods.
+ // tolerations is optional.
+ //
+ // When omitted, this means the user has no opinion and the platform is left
+ // to choose reasonable defaults. These defaults are subject to change over time.
+ // Defaults are empty/unset.
+ // Maximum length for this list is 10.
+ // Minimum length for this list is 1.
+ // +kubebuilder:validation:MaxItems=10
+ // +kubebuilder:validation:MinItems=1
+ // +listType=atomic
+ // +optional
+ Tolerations []v1.Toleration `json:"tolerations,omitempty"`
+ // topologySpreadConstraints defines rules for how Prometheus Operator Pods should be distributed
+ // across topology domains such as zones, nodes, or other user-defined labels.
+ // topologySpreadConstraints is optional.
+ // This helps improve high availability and resource efficiency by avoiding placing
+ // too many replicas in the same failure domain.
+ //
+ // When omitted, this means no opinion and the platform is left to choose a default, which is subject to change over time.
+ // This field maps directly to the `topologySpreadConstraints` field in the Pod spec.
+ // Default is empty list.
+ // Maximum length for this list is 10.
+ // Minimum length for this list is 1.
+ // Entries must have unique topologyKey and whenUnsatisfiable pairs.
+ // +kubebuilder:validation:MaxItems=10
+ // +kubebuilder:validation:MinItems=1
+ // +listType=map
+ // +listMapKey=topologyKey
+ // +listMapKey=whenUnsatisfiable
+ // +optional
+ TopologySpreadConstraints []v1.TopologySpreadConstraint `json:"topologySpreadConstraints,omitempty"`
+}
+
+// PrometheusOperatorAdmissionWebhookConfig provides configuration options for the admission webhook
+// component of Prometheus Operator that runs in the `openshift-monitoring` namespace. The admission
+// webhook validates PrometheusRule and AlertmanagerConfig objects, mutates PrometheusRule annotations,
+// and converts AlertmanagerConfig objects between API versions.
+// +kubebuilder:validation:MinProperties=1
+type PrometheusOperatorAdmissionWebhookConfig struct {
+ // resources defines the compute resource requests and limits for the
+ // prometheus-operator-admission-webhook container.
+ // This includes CPU, memory and HugePages constraints to help control scheduling and resource usage.
+ // When not specified, defaults are used by the platform. Requests cannot exceed limits.
+ // This field is optional.
+ // More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/
+ // This is a simplified API that maps to Kubernetes ResourceRequirements.
+ // The current default values are:
+ // resources:
+ // - name: cpu
+ // request: 5m
+ // limit: null
+ // - name: memory
+ // request: 30Mi
+ // limit: null
+ // Maximum length for this list is 5.
+ // Minimum length for this list is 1.
+ // Each resource name must be unique within this list.
+ // +optional
+ // +listType=map
+ // +listMapKey=name
+ // +kubebuilder:validation:MaxItems=5
+ // +kubebuilder:validation:MinItems=1
+ Resources []ContainerResource `json:"resources,omitempty"`
+ // topologySpreadConstraints defines rules for how admission webhook Pods should be distributed
+ // across topology domains such as zones, nodes, or other user-defined labels.
+ // topologySpreadConstraints is optional.
+ // This helps improve high availability and resource efficiency by avoiding placing
+ // too many replicas in the same failure domain.
+ //
+ // When omitted, this means no opinion and the platform is left to choose a default, which is subject to change over time.
+ // This field maps directly to the `topologySpreadConstraints` field in the Pod spec.
+ // Default is empty list.
+ // Maximum length for this list is 10.
+ // Minimum length for this list is 1.
+ // Entries must have unique topologyKey and whenUnsatisfiable pairs.
+ // +kubebuilder:validation:MaxItems=10
+ // +kubebuilder:validation:MinItems=1
+ // +listType=map
+ // +listMapKey=topologyKey
+ // +listMapKey=whenUnsatisfiable
+ // +optional
+ TopologySpreadConstraints []v1.TopologySpreadConstraint `json:"topologySpreadConstraints,omitempty"`
+}
+
+// PrometheusConfig provides configuration options for the Prometheus instance.
+// Use this configuration to control
+// Prometheus deployment, pod scheduling, resource allocation, retention policies, and external integrations.
+// +kubebuilder:validation:MinProperties=1
+type PrometheusConfig struct {
+ // additionalAlertmanagerConfigs configures additional Alertmanager instances that receive alerts from
+ // the Prometheus component. This is useful for organizations that need to:
+ // - Send alerts to external monitoring systems (like PagerDuty, Slack, or custom webhooks)
+ // - Route different types of alerts to different teams or systems
+ // - Integrate with existing enterprise alerting infrastructure
+ // - Maintain separate alert routing for compliance or organizational requirements
+ // When omitted, no additional Alertmanager instances are configured (default behavior).
+ // When provided, at least one configuration must be specified (minimum 1, maximum 10 items).
+ // Entries must have unique names (name is the list key).
+ // +optional
+ // +kubebuilder:validation:MinItems=1
+ // +kubebuilder:validation:MaxItems=10
+ // +listType=map
+ // +listMapKey=name
+ AdditionalAlertmanagerConfigs []AdditionalAlertmanagerConfig `json:"additionalAlertmanagerConfigs,omitempty"`
+ // enforcedBodySizeLimitBytes enforces a body size limit (in bytes) for Prometheus scraped metrics.
+ // If a scraped target's body response is larger than the limit, the scrape will fail.
+ // This helps protect Prometheus from targets that return excessively large responses.
+ // The value is specified in bytes (e.g., 4194304 for 4MB, 1073741824 for 1GB).
+ // When omitted, the Cluster Monitoring Operator automatically calculates an appropriate
+ // limit based on cluster capacity. Set an explicit value to override the automatic calculation.
+ // Minimum value is 10240 (10kB).
+ // Maximum value is 1073741824 (1GB).
+ // +kubebuilder:validation:Minimum=10240
+ // +kubebuilder:validation:Maximum=1073741824
+ // +optional
+ EnforcedBodySizeLimitBytes int64 `json:"enforcedBodySizeLimitBytes,omitempty"`
+ // externalLabels defines labels to be attached to time series and alerts
+ // when communicating with external systems such as federation, remote storage,
+ // and Alertmanager. These labels are not stored with metrics on disk; they are
+ // only added when data leaves Prometheus (e.g., during federation queries,
+ // remote write, or alert notifications).
+ // At least 1 label must be specified when set, with a maximum of 50 labels allowed.
+ // Each label key must be unique within this list.
+ // When omitted, no external labels are applied.
+ // +optional
+ // +kubebuilder:validation:MinItems=1
+ // +kubebuilder:validation:MaxItems=50
+ // +listType=map
+ // +listMapKey=key
+ ExternalLabels []Label `json:"externalLabels,omitempty"`
+ // logLevel defines the verbosity of logs emitted by Prometheus.
+ // This field allows users to control the amount and severity of logs generated, which can be useful
+ // for debugging issues or reducing noise in production environments.
+ // Allowed values are Error, Warn, Info, and Debug.
+ // When set to Error, only errors will be logged.
+ // When set to Warn, both warnings and errors will be logged.
+ // When set to Info, general information, warnings, and errors will all be logged.
+ // When set to Debug, detailed debugging information will be logged.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, that is subject to change over time.
+ // The current default value is `Info`.
+ // +optional
+ LogLevel LogLevel `json:"logLevel,omitempty"`
+ // nodeSelector defines the nodes on which the Pods are scheduled.
+ // nodeSelector is optional.
+ //
+ // When omitted, this means the user has no opinion and the platform is left
+ // to choose reasonable defaults. These defaults are subject to change over time.
+ // The current default value is `kubernetes.io/os: linux`.
+ // When specified, nodeSelector must contain at least one key-value pair (minimum of 1)
+ // and must not contain more than 10 entries.
+ // +optional
+ // +kubebuilder:validation:MinProperties=1
+ // +kubebuilder:validation:MaxProperties=10
+ NodeSelector map[string]string `json:"nodeSelector,omitempty"`
+ // queryLogFile specifies the file to which PromQL queries are logged.
+ // This setting can be either a filename, in which
+ // case the queries are saved to an `emptyDir` volume
+ // at `/var/log/prometheus`, or a full path to a location where
+ // an `emptyDir` volume will be mounted and the queries saved.
+ // Writing to `/dev/stderr`, `/dev/stdout` or `/dev/null` is supported, but
+ // writing to any other `/dev/` path is not supported. Relative paths are
+ // also not supported.
+ // By default, PromQL queries are not logged.
+ // Must be an absolute path starting with `/` or a simple filename without path separators.
+ // Must not contain consecutive slashes, end with a slash, or include '..' path traversal.
+ // Must contain only alphanumeric characters, '.', '_', '-', or '/'.
+ // Must be between 1 and 255 characters in length.
+ // +optional
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=255
+ // +kubebuilder:validation:XValidation:rule="self.matches('^[a-zA-Z0-9._/-]+$')",message="must contain only alphanumeric characters, '.', '_', '-', or '/'"
+ // +kubebuilder:validation:XValidation:rule="self.startsWith('/') || !self.contains('/')",message="must be an absolute path starting with '/' or a simple filename without '/'"
+ // +kubebuilder:validation:XValidation:rule="!self.startsWith('/dev/') || self in ['/dev/stdout', '/dev/stderr', '/dev/null']",message="only /dev/stdout, /dev/stderr, and /dev/null are allowed as /dev/ paths"
+ // +kubebuilder:validation:XValidation:rule="!self.contains('//') && !self.endsWith('/') && !self.contains('..')",message="must not contain '//', end with '/', or contain '..'"
+ QueryLogFile string `json:"queryLogFile,omitempty"`
+ // remoteWrite defines the remote write configuration, including URL, authentication, and relabeling settings.
+ // Remote write allows Prometheus to send metrics it collects to external long-term storage systems.
+ // When omitted, no remote write endpoints are configured.
+ // When provided, at least one configuration must be specified (minimum 1, maximum 10 items).
+ // Entries must have unique names (name is the list key).
+ // +kubebuilder:validation:MinItems=1
+ // +kubebuilder:validation:MaxItems=10
+ // +listType=map
+ // +listMapKey=name
+ // +optional
+ RemoteWrite []RemoteWriteSpec `json:"remoteWrite,omitempty"`
+ // resources defines the compute resource requests and limits for the Prometheus container.
+ // This includes CPU, memory and HugePages constraints to help control scheduling and resource usage.
+ // When not specified, defaults are used by the platform. Requests cannot exceed limits.
+ // This field is optional.
+ // More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/
+ // This is a simplified API that maps to Kubernetes ResourceRequirements.
+ // The current default values are:
+ // resources:
+ // - name: cpu
+ // request: 4m
+ // limit: null
+ // - name: memory
+ // request: 40Mi
+ // limit: null
+ // Maximum length for this list is 5.
+ // Minimum length for this list is 1.
+ // Each resource name must be unique within this list.
+ // +optional
+ // +listType=map
+ // +listMapKey=name
+ // +kubebuilder:validation:MaxItems=5
+ // +kubebuilder:validation:MinItems=1
+ Resources []ContainerResource `json:"resources,omitempty"`
+ // retention configures how long Prometheus retains metrics data and how much storage it can use.
+ // When omitted, the platform chooses reasonable defaults (currently 15d retention, no size limit).
+ // +optional
+ Retention Retention `json:"retention,omitempty,omitzero"`
+ // tolerations defines tolerations for the pods.
+ // tolerations is optional.
+ //
+ // When omitted, this means the user has no opinion and the platform is left
+ // to choose reasonable defaults. These defaults are subject to change over time.
+ // Defaults are empty/unset.
+ // Maximum length for this list is 10
+ // Minimum length for this list is 1
+ // +kubebuilder:validation:MaxItems=10
+ // +kubebuilder:validation:MinItems=1
+ // +listType=atomic
+ // +optional
+ Tolerations []v1.Toleration `json:"tolerations,omitempty"`
+ // topologySpreadConstraints defines rules for how Prometheus Pods should be distributed
+ // across topology domains such as zones, nodes, or other user-defined labels.
+ // topologySpreadConstraints is optional.
+ // This helps improve high availability and resource efficiency by avoiding placing
+ // too many replicas in the same failure domain.
+ //
+ // When omitted, this means no opinion and the platform is left to choose a default, which is subject to change over time.
+ // This field maps directly to the `topologySpreadConstraints` field in the Pod spec.
+ // Default is empty list.
+ // Maximum length for this list is 10.
+ // Minimum length for this list is 1
+ // Entries must have unique topologyKey and whenUnsatisfiable pairs.
+ // +kubebuilder:validation:MaxItems=10
+ // +kubebuilder:validation:MinItems=1
+ // +listType=map
+ // +listMapKey=topologyKey
+ // +listMapKey=whenUnsatisfiable
+ // +optional
+ TopologySpreadConstraints []v1.TopologySpreadConstraint `json:"topologySpreadConstraints,omitempty"`
+ // collectionProfile defines the metrics collection profile that Prometheus uses to collect
+ // metrics from the platform components. Supported values are `Full` or
+ // `Minimal`. In the `Full` profile (default), Prometheus collects all
+ // metrics that are exposed by the platform components. In the `Minimal`
+ // profile, Prometheus only collects metrics necessary for the default
+ // platform alerts, recording rules, telemetry and console dashboards.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The default value is `Full`.
+ // +optional
+ CollectionProfile CollectionProfile `json:"collectionProfile,omitempty"`
+ // volumeClaimTemplate defines persistent storage for Prometheus. Use this setting to
+ // configure the persistent volume claim, including storage class and volume size.
+ // If omitted, the Pod uses ephemeral storage and Prometheus data will not persist
+ // across restarts.
+ // +optional
+ VolumeClaimTemplate *v1.PersistentVolumeClaim `json:"volumeClaimTemplate,omitempty,omitzero"`
+}
+
+// AlertmanagerScheme defines the URL scheme to use when communicating with Alertmanager instances.
+// +kubebuilder:validation:Enum=HTTP;HTTPS
+type AlertmanagerScheme string
+
+const (
+ AlertmanagerSchemeHTTP AlertmanagerScheme = "HTTP"
+ AlertmanagerSchemeHTTPS AlertmanagerScheme = "HTTPS"
+)
+
+// AdditionalAlertmanagerConfig represents configuration for additional Alertmanager instances.
+// The `AdditionalAlertmanagerConfig` resource defines settings for how a
+// component communicates with additional Alertmanager instances.
+type AdditionalAlertmanagerConfig struct {
+ // name is a unique identifier for this Alertmanager configuration entry.
+ // The name must be a valid DNS subdomain (RFC 1123): lowercase alphanumeric characters,
+ // hyphens, or periods, and must start and end with an alphanumeric character.
+ // Minimum length is 1 character (empty string is invalid).
+ // Maximum length is 253 characters.
+ // +kubebuilder:validation:MaxLength=253
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:XValidation:rule="!format.dns1123Subdomain().validate(self).hasValue()",message="a lowercase RFC 1123 subdomain must consist of lower case alphanumeric characters, '-' or '.', and must start and end with an alphanumeric character."
+ // +required
+ Name string `json:"name,omitempty"`
+ // authorization configures the authentication method for Alertmanager connections.
+ // Supports bearer token authentication. When omitted, no authentication is used.
+ // +optional
+ Authorization AuthorizationConfig `json:"authorization,omitempty,omitzero"`
+ // pathPrefix defines an optional URL path prefix to prepend to the Alertmanager API endpoints.
+ // For example, if your Alertmanager is behind a reverse proxy at "/alertmanager/",
+ // set this to "/alertmanager" so requests go to "/alertmanager/api/v1/alerts" instead of "/api/v1/alerts".
+ // This is commonly needed when Alertmanager is deployed behind ingress controllers or load balancers.
+ // When no prefix is needed, omit this field; do not set it to "/" as that would produce paths with double slashes (e.g. "//api/v1/alerts").
+ // Must start with "/", must not end with "/", and must not be exactly "/".
+ // Must not contain query strings ("?") or fragments ("#").
+ // +kubebuilder:validation:MaxLength=255
+ // +kubebuilder:validation:MinLength=2
+ // +kubebuilder:validation:XValidation:rule="self.startsWith('/')",message="pathPrefix must start with '/'"
+ // +kubebuilder:validation:XValidation:rule="!self.endsWith('/')",message="pathPrefix must not end with '/'"
+ // +kubebuilder:validation:XValidation:rule="self != '/'",message="pathPrefix must not be '/' (would produce double slashes in request path); omit for no prefix"
+ // +kubebuilder:validation:XValidation:rule="!self.contains('?') && !self.contains('#')",message="pathPrefix must not contain '?' or '#'"
+ // +optional
+ PathPrefix string `json:"pathPrefix,omitempty"`
+ // scheme defines the URL scheme to use when communicating with Alertmanager
+ // instances.
+ // Possible values are `HTTP` or `HTTPS`.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The current default value is `HTTP`.
+ // +optional
+ Scheme AlertmanagerScheme `json:"scheme,omitempty"`
+ // staticConfigs is a list of statically configured Alertmanager endpoints in the form
+ // of `:`. Each entry must be a valid hostname, IPv4 address, or IPv6 address
+ // (in brackets) followed by a colon and a valid port number (1-65535).
+ // Examples: "alertmanager.example.com:9093", "192.168.1.100:9093", "[::1]:9093"
+ // At least one endpoint must be specified (minimum 1, maximum 10 endpoints).
+ // Each entry must be unique and non-empty (empty string is invalid).
+ // +kubebuilder:validation:MinItems=1
+ // +kubebuilder:validation:MaxItems=10
+ // +kubebuilder:validation:items:MinLength=1
+ // +kubebuilder:validation:items:MaxLength=255
+ // +kubebuilder:validation:items:XValidation:rule="isURL('http://' + self) && size(url('http://' + self).getHostname()) > 0 && size(url('http://' + self).getPort()) > 0 && int(url('http://' + self).getPort()) >= 1 && int(url('http://' + self).getPort()) <= 65535",message="must be a valid 'host:port' where host is a DNS name, IPv4, or IPv6 address (in brackets), and port is 1-65535"
+ // +listType=set
+ // +required
+ StaticConfigs []string `json:"staticConfigs,omitempty"`
+ // timeoutSeconds defines the timeout in seconds for requests to Alertmanager.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // Currently the default is 10 seconds.
+ // Minimum value is 1 second.
+ // Maximum value is 600 seconds (10 minutes).
+ // +kubebuilder:validation:Minimum=1
+ // +kubebuilder:validation:Maximum=600
+ // +optional
+ TimeoutSeconds int32 `json:"timeoutSeconds,omitempty"`
+ // tlsConfig defines the TLS settings to use for Alertmanager connections.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // +optional
+ TLSConfig TLSConfig `json:"tlsConfig,omitempty,omitzero"`
+}
+
+// Label represents a key/value pair for external labels.
+type Label struct {
+ // key is the name of the label.
+ // Prometheus supports UTF-8 label names, so any valid UTF-8 string is allowed.
+ // Must be between 1 and 128 characters in length.
+ // +required
+ // +kubebuilder:validation:MaxLength=128
+ // +kubebuilder:validation:MinLength=1
+ Key string `json:"key,omitempty"`
+ // value is the value of the label.
+ // Must be between 1 and 128 characters in length.
+ // +required
+ // +kubebuilder:validation:MaxLength=128
+ // +kubebuilder:validation:MinLength=1
+ Value string `json:"value,omitempty"`
+}
+
+// RemoteWriteSpec represents configuration for remote write endpoints.
+type RemoteWriteSpec struct {
+ // url is the URL of the remote write endpoint.
+ // Must be a valid URL with http or https scheme and a non-empty hostname.
+ // Query parameters, fragments, and user information (e.g. user:password@host) are not allowed.
+ // Empty string is invalid. Must be between 1 and 2048 characters in length.
+ // +required
+ // +kubebuilder:validation:MaxLength=2048
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:XValidation:rule="isURL(self)",message="must be a valid URL"
+ // +kubebuilder:validation:XValidation:rule="!isURL(self) || url(self).getScheme() == 'http' || url(self).getScheme() == 'https'",message="must use http or https scheme"
+ // +kubebuilder:validation:XValidation:rule="!isURL(self) || size(url(self).getHostname()) > 0",message="must have a non-empty hostname"
+ // +kubebuilder:validation:XValidation:rule="!isURL(self) || url(self).getQuery().size() == 0",message="query parameters are not allowed"
+ // +kubebuilder:validation:XValidation:rule="!self.matches('.*#.*')",message="fragments are not allowed"
+ // +kubebuilder:validation:XValidation:rule="!self.matches('.*@.*')",message="user information (e.g. user:password@host) is not allowed"
+ URL string `json:"url,omitempty"`
+ // name is a required identifier for this remote write configuration (name is the list key for the remoteWrite list).
+ // This name is used in metrics and logging to differentiate remote write queues.
+ // Must contain only alphanumeric characters, hyphens, and underscores.
+ // Must be between 1 and 63 characters in length.
+ // +required
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=63
+ // +kubebuilder:validation:XValidation:rule="self.matches('^[a-zA-Z0-9_-]+$')",message="must contain only alphanumeric characters, hyphens, and underscores"
+ Name string `json:"name,omitempty"`
+ // messageVersion defines the Remote Write message's version to use when writing to the endpoint.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The default value is "V1.0".
+ // When set to "V1.0", Prometheus uses the `prometheus.WriteRequest` protobuf message introduced in Remote Write 1.0.
+ // When set to "V2.0", Prometheus uses the `io.prometheus.write.v2.Request` protobuf message introduced in Remote Write 2.0.
+ // +optional
+ MessageVersion RemoteWriteMessageVersion `json:"messageVersion,omitempty,omitzero"`
+ // authorization defines the authorization method for the remote write endpoint.
+ // When omitted, no authorization is performed.
+ // When set, type must be one of Authorization, BasicAuth, OAuth2, SigV4, or ServiceAccount; the corresponding nested config must be set (ServiceAccount has no config).
+ // +optional
+ AuthorizationConfig RemoteWriteAuthorization `json:"authorization,omitzero"`
+ // headers specifies the custom HTTP headers to be sent along with each remote write request.
+ // Sending custom headers makes the configuration of a proxy in between optional and helps the
+ // receiver recognize the given source better.
+ // Clients MAY allow users to send custom HTTP headers; they MUST NOT allow users to configure
+ // them in such a way as to send reserved headers. Headers set by Prometheus cannot be overwritten.
+ // When omitted, no custom headers are sent.
+ // Maximum of 50 headers can be specified. Each header name must be unique.
+ // Each header name must contain only alphanumeric characters, hyphens, and underscores, and must not be a reserved Prometheus header (Host, Authorization, Content-Encoding, Content-Type, X-Prometheus-Remote-Write-Version, User-Agent, Connection, Keep-Alive, Proxy-Authenticate, Proxy-Authorization, WWW-Authenticate).
+ // +optional
+ // +kubebuilder:validation:MinItems=0
+ // +kubebuilder:validation:MaxItems=50
+ // +kubebuilder:validation:items:XValidation:rule="self.name.matches('^[a-zA-Z0-9_-]+$')",message="header name must contain only alphanumeric characters, hyphens, and underscores"
+ // +kubebuilder:validation:items:XValidation:rule="!self.name.matches('(?i)^(host|authorization|content-encoding|content-type|x-prometheus-remote-write-version|user-agent|connection|keep-alive|proxy-authenticate|proxy-authorization|www-authenticate)$')",message="header name must not be a reserved Prometheus header (Host, Authorization, Content-Encoding, Content-Type, X-Prometheus-Remote-Write-Version, User-Agent, Connection, Keep-Alive, Proxy-Authenticate, Proxy-Authorization, WWW-Authenticate)"
+ // +listType=map
+ // +listMapKey=name
+ Headers []PrometheusRemoteWriteHeader `json:"headers,omitempty"`
+ // metadataConfig configures the sending of series metadata to remote storage.
+ // When omitted, no metadata is sent.
+ // When set to sendPolicy: Default, metadata is sent using platform-chosen defaults (e.g. send interval 30 seconds).
+ // When set to sendPolicy: Custom, metadata is sent using the settings in the custom field (e.g. custom.sendIntervalSeconds).
+ // +optional
+ MetadataConfig MetadataConfig `json:"metadataConfig,omitempty,omitzero"`
+ // proxyUrl defines an optional proxy URL.
+ // If the cluster-wide proxy is enabled, it replaces the proxyUrl setting.
+ // The cluster-wide proxy supports both HTTP and HTTPS proxies, with HTTPS taking precedence.
+ // When omitted, no proxy is used.
+ // Must be a valid URL with http or https scheme.
+ // Must be between 1 and 2048 characters in length.
+ // +optional
+ // +kubebuilder:validation:MaxLength=2048
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:XValidation:rule="isURL(self) && (url(self).getScheme() == 'http' || url(self).getScheme() == 'https')",message="must be a valid URL with http or https scheme"
+ ProxyURL string `json:"proxyUrl,omitempty"`
+ // queueConfig allows tuning configuration for remote write queue parameters.
+ // When omitted, default queue configuration is used.
+ // +optional
+ QueueConfig QueueConfig `json:"queueConfig,omitempty,omitzero"`
+ // remoteTimeoutSeconds defines the timeout in seconds for requests to the remote write endpoint.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // Minimum value is 1 second.
+ // Maximum value is 600 seconds (10 minutes).
+ // +optional
+ // +kubebuilder:validation:Minimum=1
+ // +kubebuilder:validation:Maximum=600
+ RemoteTimeoutSeconds int32 `json:"remoteTimeoutSeconds,omitempty"`
+ // exemplarsMode controls whether exemplars are sent via remote write.
+ // Valid values are "Send", "DoNotSend" and omitted.
+ // When set to "Send", Prometheus is configured to store a maximum of 100,000 exemplars in memory and send them with remote write.
+ // Note that this setting only applies to user-defined monitoring. It is not applicable to default in-cluster monitoring.
+ // When omitted or set to "DoNotSend", exemplars are not sent.
+ // +optional
+ ExemplarsMode ExemplarsMode `json:"exemplarsMode,omitempty"`
+ // tlsConfig defines TLS authentication settings for the remote write endpoint.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // +optional
+ TLSConfig TLSConfig `json:"tlsConfig,omitempty,omitzero"`
+ // writeRelabelConfigs is a list of relabeling rules to apply before sending data to the remote endpoint.
+ // When omitted, no relabeling is performed and all metrics are sent as-is.
+ // Minimum of 1 and maximum of 10 relabeling rules can be specified.
+ // Each rule must have a unique name.
+ // +optional
+ // +kubebuilder:validation:MinItems=1
+ // +kubebuilder:validation:MaxItems=10
+ // +listType=map
+ // +listMapKey=name
+ WriteRelabelConfigs []RelabelConfig `json:"writeRelabelConfigs,omitempty"`
+}
+
+// PrometheusRemoteWriteHeader defines a custom HTTP header for remote write requests.
+// The header name must not be one of the reserved headers set by Prometheus (Host, Authorization, Content-Encoding, Content-Type, X-Prometheus-Remote-Write-Version, User-Agent, Connection, Keep-Alive, Proxy-Authenticate, Proxy-Authorization, WWW-Authenticate).
+// Header names must contain only case-insensitive alphanumeric characters, hyphens (-), and underscores (_); other characters (e.g. emoji) are rejected by validation.
+// Validation is enforced on the Headers field in RemoteWriteSpec.
+type PrometheusRemoteWriteHeader struct {
+ // name is the HTTP header name. Must not be a reserved header (see type documentation).
+ // Must contain only alphanumeric characters, hyphens, and underscores; invalid characters are rejected. Must be between 1 and 256 characters.
+ // +required
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=256
+ Name string `json:"name,omitempty"`
+ // value is the HTTP header value. Must be at most 4096 characters.
+ // +required
+ // +kubebuilder:validation:MinLength=0
+ // +kubebuilder:validation:MaxLength=4096
+ Value *string `json:"value,omitempty"`
+}
+
+// BasicAuth defines basic authentication settings for the remote write endpoint URL.
+type BasicAuth struct {
+ // username defines the secret reference containing the username for basic authentication.
+ // The secret must exist in the openshift-monitoring namespace.
+ // +required
+ Username SecretKeySelector `json:"username,omitzero,omitempty"`
+ // password defines the secret reference containing the password for basic authentication.
+ // The secret must exist in the openshift-monitoring namespace.
+ // +required
+ Password SecretKeySelector `json:"password,omitzero,omitempty"`
+}
+
+// RemoteWriteAuthorizationType defines the authorization method for remote write endpoints.
+// +kubebuilder:validation:Enum=Authorization;BasicAuth;OAuth2;SigV4;ServiceAccount
+type RemoteWriteAuthorizationType string
+
+const (
+ // RemoteWriteAuthorizationTypeAuthorization indicates authorization credentials from a secret.
+ // The secret key contains the credentials (e.g. a Bearer token). Use the authorization field.
+ RemoteWriteAuthorizationTypeAuthorization RemoteWriteAuthorizationType = "Authorization"
+ // RemoteWriteAuthorizationTypeBasicAuth indicates HTTP basic authentication.
+ RemoteWriteAuthorizationTypeBasicAuth RemoteWriteAuthorizationType = "BasicAuth"
+ // RemoteWriteAuthorizationTypeOAuth2 indicates OAuth2 client credentials.
+ RemoteWriteAuthorizationTypeOAuth2 RemoteWriteAuthorizationType = "OAuth2"
+ // RemoteWriteAuthorizationTypeSigV4 indicates AWS Signature Version 4.
+ RemoteWriteAuthorizationTypeSigV4 RemoteWriteAuthorizationType = "SigV4"
+ // RemoteWriteAuthorizationTypeServiceAccount indicates use of the pod's service account token for machine identity.
+ // No additional field is required; the operator configures the token path.
+ RemoteWriteAuthorizationTypeServiceAccount RemoteWriteAuthorizationType = "ServiceAccount"
+
+ // --- TOMBSTONE ---
+ // RemoteWriteAuthorizationTypeBearerToken was a constant for bearer token authentication from a secret.
+ // It has been removed in favor of RemoteWriteAuthorizationTypeAuthorization. The constant name is reserved to prevent reuse.
+ //
+ // RemoteWriteAuthorizationTypeBearerToken RemoteWriteAuthorizationType = "BearerToken"
+
+ // --- TOMBSTONE ---
+ // RemoteWriteAuthorizationTypeSafeAuthorization was a constant for authorization credentials from a secret (Prometheus SafeAuthorization pattern).
+ // It has been removed in favor of RemoteWriteAuthorizationTypeAuthorization. The constant name is reserved to prevent reuse.
+ //
+ // RemoteWriteAuthorizationTypeSafeAuthorization RemoteWriteAuthorizationType = "SafeAuthorization"
+)
+
+// RemoteWriteAuthorization defines the authorization method for a remote write endpoint.
+// Nested config requirements depend on the type discriminator: Authorization requires authorization,
+// BasicAuth requires basicAuth, OAuth2 requires oauth2, SigV4 requires sigv4, and ServiceAccount forbids all nested configs.
+// +kubebuilder:validation:XValidation:rule="has(self.type) && self.type == 'Authorization' ? has(self.authorization) : !has(self.authorization)",message="authorization is required when type is Authorization, and forbidden otherwise"
+// +kubebuilder:validation:XValidation:rule="has(self.type) && self.type == 'BasicAuth' ? has(self.basicAuth) : !has(self.basicAuth)",message="basicAuth is required when type is BasicAuth, and forbidden otherwise"
+// +kubebuilder:validation:XValidation:rule="has(self.type) && self.type == 'OAuth2' ? has(self.oauth2) : !has(self.oauth2)",message="oauth2 is required when type is OAuth2, and forbidden otherwise"
+// +kubebuilder:validation:XValidation:rule="has(self.type) && self.type == 'SigV4' ? has(self.sigv4) : !has(self.sigv4)",message="sigv4 is required when type is SigV4, and forbidden otherwise"
+// +union
+type RemoteWriteAuthorization struct {
+ // type specifies the authorization method to use.
+ // Allowed values are Authorization, BasicAuth, OAuth2, SigV4, and ServiceAccount.
+ //
+ // When set to Authorization, credentials are read from a single Secret key. The secret key typically contains a Bearer token. Use the authorization field.
+ //
+ // When set to BasicAuth, HTTP basic authentication is used; the basicAuth field (username and password from Secrets) must be set.
+ //
+ // When set to OAuth2, OAuth2 client credentials flow is used; the oauth2 field (clientId, clientSecret, tokenUrl) must be set.
+ //
+ // When set to SigV4, AWS Signature Version 4 is used for authentication; the sigv4 field must be set.
+ //
+ // When set to ServiceAccount, the pod's service account token is used for machine identity. No additional field is required; the operator configures the token path.
+ // +unionDiscriminator
+ // +required
+ Type RemoteWriteAuthorizationType `json:"type,omitempty"`
+ // authorization defines the secret reference containing the authorization credentials (e.g. Bearer token).
+ // Required when type is "Authorization", and forbidden otherwise.
+ // The secret must exist in the openshift-monitoring namespace.
+ // +unionMember=Authorization
+ // +optional
+ Authorization SecretKeySelector `json:"authorization,omitempty,omitzero"`
+ // basicAuth defines HTTP basic authentication credentials.
+ // Required when type is "BasicAuth", and forbidden otherwise.
+ // +unionMember
+ // +optional
+ BasicAuth BasicAuth `json:"basicAuth,omitempty,omitzero"`
+ // oauth2 defines OAuth2 client credentials authentication.
+ // Required when type is "OAuth2", and forbidden otherwise.
+ // +unionMember
+ // +optional
+ OAuth2 OAuth2 `json:"oauth2,omitempty,omitzero"`
+ // sigv4 defines AWS Signature Version 4 authentication.
+ // Required when type is "SigV4", and forbidden otherwise.
+ // +unionMember
+ // +optional
+ Sigv4 Sigv4 `json:"sigv4,omitempty,omitzero"`
+
+ // --- TOMBSTONE ---
+ // bearerToken was a field for bearer token authentication from a secret.
+ // It has been removed in favor of authorization. The field name is reserved to prevent reuse.
+ //
+ // +unionMember
+ // +optional
+ // BearerToken SecretKeySelector `json:"bearerToken,omitempty,omitzero"`
+
+ // --- TOMBSTONE ---
+ // safeAuthorization was a field for authorization credentials from a secret (Prometheus SafeAuthorization pattern).
+ // It has been removed in favor of authorization. The field name is reserved to prevent reuse.
+ //
+ // +unionMember
+ // +optional
+ // SafeAuthorization *v1.SecretKeySelector `json:"safeAuthorization,omitempty"`
+}
+
+// RemoteWriteMessageVersion defines the version of the remote-write protocol.
+// +kubebuilder:validation:Enum=V1.0;V2.0
+type RemoteWriteMessageVersion string
+
+const (
+ // RemoteWriteMessageVersion1_0 indicates the version 1.0 of the remote-write protocol.
+ RemoteWriteMessageVersion1_0 RemoteWriteMessageVersion = "V1.0"
+ // RemoteWriteMessageVersion2_0 indicates the version 2.0 of the remote-write protocol.
+ RemoteWriteMessageVersion2_0 RemoteWriteMessageVersion = "V2.0"
+)
+
+// MetadataConfigSendPolicy defines whether to send metadata with platform defaults or with custom settings.
+// +kubebuilder:validation:Enum=Default;Custom
+type MetadataConfigSendPolicy string
+
+const (
+ // MetadataConfigSendPolicyDefault indicates metadata is sent using platform-chosen defaults (e.g. send interval 30 seconds).
+ MetadataConfigSendPolicyDefault MetadataConfigSendPolicy = "Default"
+ // MetadataConfigSendPolicyCustom indicates metadata is sent using the settings in the custom field.
+ MetadataConfigSendPolicyCustom MetadataConfigSendPolicy = "Custom"
+)
+
+// MetadataConfig defines whether and how to send series metadata to remote write storage.
+// +kubebuilder:validation:XValidation:rule="self.sendPolicy == 'Default' ? self.custom.sendIntervalSeconds == 0 : true",message="custom is forbidden when sendPolicy is Default"
+type MetadataConfig struct {
+ // sendPolicy specifies whether to send metadata and how it is configured.
+ // Default: send metadata using platform-chosen defaults (e.g. send interval 30 seconds).
+ // Custom: send metadata using the settings in the custom field.
+ // +required
+ SendPolicy MetadataConfigSendPolicy `json:"sendPolicy,omitempty"`
+ // custom defines custom metadata send settings. Required when sendPolicy is Custom (must have at least one property), and forbidden when sendPolicy is Default.
+ // +optional
+ Custom MetadataConfigCustom `json:"custom,omitempty,omitzero"`
+}
+
+// MetadataConfigCustom defines custom settings for sending series metadata when sendPolicy is Custom.
+// At least one property must be set when sendPolicy is Custom (e.g. sendIntervalSeconds).
+// +kubebuilder:validation:MinProperties=1
+type MetadataConfigCustom struct {
+ // sendIntervalSeconds is the interval in seconds at which metadata is sent.
+ // When omitted, the platform chooses a reasonable default (e.g. 30 seconds).
+ // Minimum value is 1 second. Maximum value is 86400 seconds (24 hours).
+ // +optional
+ // +kubebuilder:validation:Minimum=1
+ // +kubebuilder:validation:Maximum=86400
+ SendIntervalSeconds int32 `json:"sendIntervalSeconds,omitempty"`
+}
+
+// OAuth2 defines OAuth2 authentication settings for the remote write endpoint.
+type OAuth2 struct {
+ // clientId defines the secret reference containing the OAuth2 client ID.
+ // The secret must exist in the openshift-monitoring namespace.
+ // +required
+ ClientID SecretKeySelector `json:"clientId,omitzero,omitempty"`
+ // clientSecret defines the secret reference containing the OAuth2 client secret.
+ // The secret must exist in the openshift-monitoring namespace.
+ // +required
+ ClientSecret SecretKeySelector `json:"clientSecret,omitzero,omitempty"`
+ // tokenUrl is the URL to fetch the token from.
+ // Must be a valid URL with http or https scheme.
+ // Must be between 1 and 2048 characters in length.
+ // +required
+ // +kubebuilder:validation:MaxLength=2048
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:XValidation:rule="isURL(self)",message="must be a valid URL"
+ // +kubebuilder:validation:XValidation:rule="!isURL(self) || url(self).getScheme() == 'http' || url(self).getScheme() == 'https'",message="must use http or https scheme"
+ TokenURL string `json:"tokenUrl,omitempty"`
+ // scopes is a list of OAuth2 scopes to request.
+ // When omitted, no scopes are requested.
+ // Maximum of 20 scopes can be specified.
+ // Each scope must be between 1 and 256 characters.
+ // +optional
+ // +kubebuilder:validation:MinItems=0
+ // +kubebuilder:validation:MaxItems=20
+ // +kubebuilder:validation:items:MinLength=1
+ // +kubebuilder:validation:items:MaxLength=256
+ // +listType=atomic
+ Scopes []string `json:"scopes,omitempty"`
+ // endpointParams defines additional parameters to append to the token URL.
+ // When omitted, no additional parameters are sent.
+ // Maximum of 20 parameters can be specified. Entries must have unique names (name is the list key).
+ // +optional
+ // +kubebuilder:validation:MinItems=0
+ // +kubebuilder:validation:MaxItems=20
+ // +listType=map
+ // +listMapKey=name
+ EndpointParams []OAuth2EndpointParam `json:"endpointParams,omitempty"`
+}
+
+// OAuth2EndpointParam defines a name/value parameter for the OAuth2 token URL.
+type OAuth2EndpointParam struct {
+ // name is the parameter name. Must be between 1 and 256 characters.
+ // +required
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=256
+ Name string `json:"name,omitempty"`
+ // value is the optional parameter value. When omitted, the query parameter is applied as ?name (no value).
+ // When set (including to the empty string), it is applied as ?name=value. Empty string may be used when the
+ // external system expects a parameter with an empty value (e.g. ?parameter="").
+ // Must be between 0 and 2048 characters when present (aligned with common URL length recommendations).
+ // +optional
+ // +kubebuilder:validation:MinLength=0
+ // +kubebuilder:validation:MaxLength=2048
+ Value *string `json:"value,omitempty"`
+}
+
+// QueueConfig allows tuning configuration for remote write queue parameters.
+// Configure this when you need to control throughput, backpressure, or retry behavior—for example to avoid overloading the remote endpoint, to reduce memory usage, or to tune for high-cardinality workloads. Consider capacity, maxShards, and batchSendDeadlineSeconds for throughput; minBackoffMilliseconds and maxBackoffMilliseconds for retries; and rateLimitedAction when the remote returns HTTP 429.
+// +kubebuilder:validation:MinProperties=1
+type QueueConfig struct {
+ // capacity is the number of samples to buffer per shard before we start dropping them.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The default value is 10000.
+ // Minimum value is 1.
+ // Maximum value is 1000000.
+ // +optional
+ // +kubebuilder:validation:Minimum=1
+ // +kubebuilder:validation:Maximum=1000000
+ Capacity int32 `json:"capacity,omitempty"`
+ // maxShards is the maximum number of shards, i.e. amount of concurrency.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The default value is 200.
+ // Minimum value is 1.
+ // Maximum value is 10000.
+ // +optional
+ // +kubebuilder:validation:Minimum=1
+ // +kubebuilder:validation:Maximum=10000
+ MaxShards int32 `json:"maxShards,omitempty"`
+ // minShards is the minimum number of shards, i.e. amount of concurrency.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The default value is 1.
+ // Minimum value is 1.
+ // Maximum value is 10000.
+ // +optional
+ // +kubebuilder:validation:Minimum=1
+ // +kubebuilder:validation:Maximum=10000
+ MinShards int32 `json:"minShards,omitempty"`
+ // maxSamplesPerSend is the maximum number of samples per send.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The default value is 1000.
+ // Minimum value is 1.
+ // Maximum value is 100000.
+ // +optional
+ // +kubebuilder:validation:Minimum=1
+ // +kubebuilder:validation:Maximum=100000
+ MaxSamplesPerSend int32 `json:"maxSamplesPerSend,omitempty"`
+ // batchSendDeadlineSeconds is the maximum time in seconds a sample will wait in buffer before being sent.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // Minimum value is 1 second.
+ // Maximum value is 3600 seconds (1 hour).
+ // +optional
+ // +kubebuilder:validation:Minimum=1
+ // +kubebuilder:validation:Maximum=3600
+ BatchSendDeadlineSeconds int32 `json:"batchSendDeadlineSeconds,omitempty"`
+ // minBackoffMilliseconds is the minimum retry delay in milliseconds.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // Minimum value is 1 millisecond.
+ // Maximum value is 3600000 milliseconds (1 hour).
+ // +optional
+ // +kubebuilder:validation:Minimum=1
+ // +kubebuilder:validation:Maximum=3600000
+ MinBackoffMilliseconds int32 `json:"minBackoffMilliseconds,omitempty"`
+ // maxBackoffMilliseconds is the maximum retry delay in milliseconds.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // Minimum value is 1 millisecond.
+ // Maximum value is 3600000 milliseconds (1 hour).
+ // +optional
+ // +kubebuilder:validation:Minimum=1
+ // +kubebuilder:validation:Maximum=3600000
+ MaxBackoffMilliseconds int32 `json:"maxBackoffMilliseconds,omitempty"`
+ // rateLimitedAction controls what to do when the remote write endpoint returns HTTP 429 (Too Many Requests).
+ // When omitted, no retries are performed on rate limit responses.
+ // When set to "Retry", Prometheus will retry such requests using the backoff settings above.
+ // Valid value when set is "Retry".
+ // +optional
+ RateLimitedAction RateLimitedAction `json:"rateLimitedAction,omitempty"`
+}
+
+// Sigv4 defines AWS Signature Version 4 authentication settings.
+// At least one of region, accessKey/secretKey, profile, or roleArn must be set so the platform can perform authentication.
+// +kubebuilder:validation:MinProperties=1
+type Sigv4 struct {
+ // region is the AWS region.
+ // When omitted, the region is derived from the environment or instance metadata.
+ // Must be between 1 and 128 characters.
+ // +optional
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=128
+ Region string `json:"region,omitempty"`
+ // accessKey defines the secret reference containing the AWS access key ID.
+ // The secret must exist in the openshift-monitoring namespace.
+ // When omitted, the access key is derived from the environment or instance metadata.
+ // +optional
+ AccessKey SecretKeySelector `json:"accessKey,omitempty,omitzero"`
+ // secretKey defines the secret reference containing the AWS secret access key.
+ // The secret must exist in the openshift-monitoring namespace.
+ // When omitted, the secret key is derived from the environment or instance metadata.
+ // +optional
+ SecretKey SecretKeySelector `json:"secretKey,omitempty,omitzero"`
+ // profile is the named AWS profile used to authenticate.
+ // When omitted, the default profile is used.
+ // Must be between 1 and 128 characters.
+ // +optional
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=128
+ Profile string `json:"profile,omitempty"`
+ // roleArn is the AWS Role ARN, an alternative to using AWS API keys.
+ // When omitted, API keys are used for authentication.
+ // Must be a valid AWS ARN format (e.g., "arn:aws:iam::123456789012:role/MyRole").
+ // Must be between 1 and 512 characters.
+ // +optional
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=512
+ // +kubebuilder:validation:XValidation:rule=`self.startsWith('arn:aws') && self.matches('^arn:aws(-[a-z]+)?:iam::[0-9]{12}:role/.+$')`,message="must be a valid AWS IAM role ARN (e.g., arn:aws:iam::123456789012:role/MyRole)"
+ RoleArn string `json:"roleArn,omitempty"`
+}
+
+// RelabelConfig represents a relabeling rule.
+type RelabelConfig struct {
+ // name is a unique identifier for this relabel configuration.
+ // Must contain only alphanumeric characters, hyphens, and underscores.
+ // Must be between 1 and 63 characters in length.
+ // +required
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=63
+ // +kubebuilder:validation:XValidation:rule="self.matches('^[a-zA-Z0-9_-]+$')",message="must contain only alphanumeric characters, hyphens, and underscores"
+ Name string `json:"name,omitempty"`
+
+ // sourceLabels specifies which label names to extract from each series for this relabeling rule.
+ // The values of these labels are joined together using the configured separator,
+ // and the resulting string is then matched against the regular expression.
+ // If a referenced label does not exist on a series, Prometheus substitutes an empty string.
+ // When omitted, the rule operates without extracting source labels (useful for actions like labelmap).
+ // Minimum of 1 and maximum of 10 source labels can be specified, each between 1 and 128 characters.
+ // Each entry must be unique.
+ // Label names beginning with "__" (two underscores) are reserved for internal Prometheus use and are not allowed.
+ // Label names SHOULD start with a letter (a-z, A-Z) or underscore (_), followed by zero or more letters, digits (0-9), or underscores for best compatibility.
+ // While Prometheus supports UTF-8 characters in label names (since v3.0.0), using the recommended character set
+ // ensures better compatibility with the wider ecosystem (tooling, third-party instrumentation, etc.).
+ // +optional
+ // +kubebuilder:validation:MinItems=1
+ // +kubebuilder:validation:MaxItems=10
+ // +kubebuilder:validation:items:MinLength=1
+ // +kubebuilder:validation:items:MaxLength=128
+ // +kubebuilder:validation:items:XValidation:rule="!self.startsWith('__')",message="label names beginning with '__' (two underscores) are reserved for internal Prometheus use and are not allowed"
+ // +listType=set
+ SourceLabels []string `json:"sourceLabels,omitempty"`
+
+ // separator is the character sequence used to join source label values.
+ // Common examples: ";", ",", "::", "|||".
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The default value is ";".
+ // Must be between 1 and 5 characters in length when specified.
+ // +optional
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=5
+ Separator string `json:"separator,omitempty"`
+
+ // regex is the regular expression to match against the concatenated source label values.
+ // Must be a valid RE2 regular expression (https://github.com/google/re2/wiki/Syntax).
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The default value is "(.*)" to match everything.
+ // Must be between 1 and 1000 characters in length when specified.
+ // +optional
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=1000
+ Regex string `json:"regex,omitempty"`
+
+ // action defines the action to perform on the matched labels and its configuration.
+ // Exactly one action-specific configuration must be specified based on the action type.
+ // +required
+ Action RelabelActionConfig `json:"action,omitzero"`
+}
+
+// RelabelActionConfig represents the action to perform and its configuration.
+// Exactly one action-specific configuration must be specified based on the action type.
+// +kubebuilder:validation:XValidation:rule="has(self.type) && self.type == 'Replace' ? has(self.replace) : !has(self.replace)",message="replace is required when type is Replace, and forbidden otherwise"
+// +kubebuilder:validation:XValidation:rule="has(self.type) && self.type == 'HashMod' ? has(self.hashMod) : !has(self.hashMod)",message="hashMod is required when type is HashMod, and forbidden otherwise"
+// +kubebuilder:validation:XValidation:rule="has(self.type) && self.type == 'Lowercase' ? has(self.lowercase) : !has(self.lowercase)",message="lowercase is required when type is Lowercase, and forbidden otherwise"
+// +kubebuilder:validation:XValidation:rule="has(self.type) && self.type == 'Uppercase' ? has(self.uppercase) : !has(self.uppercase)",message="uppercase is required when type is Uppercase, and forbidden otherwise"
+// +kubebuilder:validation:XValidation:rule="has(self.type) && self.type == 'KeepEqual' ? has(self.keepEqual) : !has(self.keepEqual)",message="keepEqual is required when type is KeepEqual, and forbidden otherwise"
+// +kubebuilder:validation:XValidation:rule="has(self.type) && self.type == 'DropEqual' ? has(self.dropEqual) : !has(self.dropEqual)",message="dropEqual is required when type is DropEqual, and forbidden otherwise"
+// +kubebuilder:validation:XValidation:rule="has(self.type) && self.type == 'LabelMap' ? has(self.labelMap) : !has(self.labelMap)",message="labelMap is required when type is LabelMap, and forbidden otherwise"
+// +union
+type RelabelActionConfig struct {
+ // type specifies the action to perform on the matched labels.
+ // Allowed values are Replace, Lowercase, Uppercase, Keep, Drop, KeepEqual, DropEqual, HashMod, LabelMap, LabelDrop, LabelKeep.
+ //
+ // When set to Replace, regex is matched against the concatenated source_labels; target_label is set to replacement with match group references (${1}, ${2}, ...) substituted. If regex does not match, no replacement takes place.
+ //
+ // When set to Lowercase, the concatenated source_labels are mapped to their lower case. Requires Prometheus >= v2.36.0.
+ //
+ // When set to Uppercase, the concatenated source_labels are mapped to their upper case. Requires Prometheus >= v2.36.0.
+ //
+ // When set to Keep, targets for which regex does not match the concatenated source_labels are dropped.
+ //
+ // When set to Drop, targets for which regex matches the concatenated source_labels are dropped.
+ //
+ // When set to KeepEqual, targets for which the concatenated source_labels do not match target_label are dropped. Requires Prometheus >= v2.41.0.
+ //
+ // When set to DropEqual, targets for which the concatenated source_labels do match target_label are dropped. Requires Prometheus >= v2.41.0.
+ //
+ // When set to HashMod, target_label is set to the modulus of a hash of the concatenated source_labels.
+ //
+ // When set to LabelMap, regex is matched against all source label names (not just source_labels); matching label values are copied to new names given by replacement with ${1}, ${2}, ... substituted.
+ //
+ // When set to LabelDrop, regex is matched against all label names; any label that matches is removed.
+ //
+ // When set to LabelKeep, regex is matched against all label names; any label that does not match is removed.
+ // +required
+ // +unionDiscriminator
+ Type RelabelAction `json:"type,omitempty"`
+
+ // replace configures the Replace action.
+ // Required when type is Replace, and forbidden otherwise.
+ // +unionMember
+ // +optional
+ Replace ReplaceActionConfig `json:"replace,omitempty,omitzero"`
+
+ // hashMod configures the HashMod action.
+ // Required when type is HashMod, and forbidden otherwise.
+ // +unionMember
+ // +optional
+ HashMod HashModActionConfig `json:"hashMod,omitempty,omitzero"`
+
+ // labelMap configures the LabelMap action.
+ // Required when type is LabelMap, and forbidden otherwise.
+ // +unionMember
+ // +optional
+ LabelMap LabelMapActionConfig `json:"labelMap,omitempty,omitzero"`
+
+ // lowercase configures the Lowercase action.
+ // Required when type is Lowercase, and forbidden otherwise.
+ // Requires Prometheus >= v2.36.0.
+ // +unionMember
+ // +optional
+ Lowercase LowercaseActionConfig `json:"lowercase,omitempty,omitzero"`
+
+ // uppercase configures the Uppercase action.
+ // Required when type is Uppercase, and forbidden otherwise.
+ // Requires Prometheus >= v2.36.0.
+ // +unionMember
+ // +optional
+ Uppercase UppercaseActionConfig `json:"uppercase,omitempty,omitzero"`
+
+ // keepEqual configures the KeepEqual action.
+ // Required when type is KeepEqual, and forbidden otherwise.
+ // Requires Prometheus >= v2.41.0.
+ // +unionMember
+ // +optional
+ KeepEqual KeepEqualActionConfig `json:"keepEqual,omitempty,omitzero"`
+
+ // dropEqual configures the DropEqual action.
+ // Required when type is DropEqual, and forbidden otherwise.
+ // Requires Prometheus >= v2.41.0.
+ // +unionMember
+ // +optional
+ DropEqual DropEqualActionConfig `json:"dropEqual,omitempty,omitzero"`
+}
+
+// ReplaceActionConfig configures the Replace action.
+// Regex is matched against the concatenated source_labels; target_label is set to replacement with match group references (${1}, ${2}, ...) substituted. No replacement if regex does not match.
+type ReplaceActionConfig struct {
+ // targetLabel is the label name where the replacement result is written.
+ // Must be between 1 and 128 characters in length.
+ // +required
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=128
+ TargetLabel string `json:"targetLabel,omitempty"`
+
+ // replacement is the value written to target_label when regex matches; match group references (${1}, ${2}, ...) are substituted.
+ // Required when using the Replace action so the intended behavior is explicit and the platform does not need to apply defaults.
+ // Use "$1" for the first capture group, "$2" for the second, etc. Use an empty string ("") to explicitly clear the target label value.
+ // Must be between 0 and 255 characters in length.
+ // +required
+ // +kubebuilder:validation:MinLength=0
+ // +kubebuilder:validation:MaxLength=255
+ Replacement *string `json:"replacement,omitempty"`
+}
+
+// HashModActionConfig configures the HashMod action.
+// target_label is set to the modulus of a hash of the concatenated source_labels (target = hash % modulus).
+type HashModActionConfig struct {
+ // targetLabel is the label name where the hash modulus result is written.
+ // Must be between 1 and 128 characters in length.
+ // +required
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=128
+ TargetLabel string `json:"targetLabel,omitempty"`
+
+ // modulus is the divisor applied to the hash of the concatenated source label values (target = hash % modulus).
+ // Required when using the HashMod action so the intended behavior is explicit.
+ // Must be between 1 and 1000000.
+ // +required
+ // +kubebuilder:validation:Minimum=1
+ // +kubebuilder:validation:Maximum=1000000
+ Modulus int64 `json:"modulus,omitempty"`
+}
+
+// LowercaseActionConfig configures the Lowercase action.
+// Maps the concatenated source_labels to their lower case and writes to target_label.
+// Requires Prometheus >= v2.36.0.
+type LowercaseActionConfig struct {
+ // targetLabel is the label name where the lower-cased value is written.
+ // Must be between 1 and 128 characters in length.
+ // +required
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=128
+ TargetLabel string `json:"targetLabel,omitempty"`
+}
+
+// UppercaseActionConfig configures the Uppercase action.
+// Maps the concatenated source_labels to their upper case and writes to target_label.
+// Requires Prometheus >= v2.36.0.
+type UppercaseActionConfig struct {
+ // targetLabel is the label name where the upper-cased value is written.
+ // Must be between 1 and 128 characters in length.
+ // +required
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=128
+ TargetLabel string `json:"targetLabel,omitempty"`
+}
+
+// KeepEqualActionConfig configures the KeepEqual action.
+// Drops targets for which the concatenated source_labels do not match the value of target_label.
+// Requires Prometheus >= v2.41.0.
+type KeepEqualActionConfig struct {
+ // targetLabel is the label name whose value is compared to the concatenated source_labels; targets that do not match are dropped.
+ // Must be between 1 and 128 characters in length.
+ // +required
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=128
+ TargetLabel string `json:"targetLabel,omitempty"`
+}
+
+// DropEqualActionConfig configures the DropEqual action.
+// Drops targets for which the concatenated source_labels do match the value of target_label.
+// Requires Prometheus >= v2.41.0.
+type DropEqualActionConfig struct {
+ // targetLabel is the label name whose value is compared to the concatenated source_labels; targets that match are dropped.
+ // Must be between 1 and 128 characters in length.
+ // +required
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=128
+ TargetLabel string `json:"targetLabel,omitempty"`
+}
+
+// LabelMapActionConfig configures the LabelMap action.
+// Regex is matched against all source label names (not just source_labels). Matching label values are copied to new label names given by replacement, with match group references (${1}, ${2}, ...) substituted.
+type LabelMapActionConfig struct {
+ // replacement is the template for new label names; match group references (${1}, ${2}, ...) are substituted from the matched label name.
+ // Required when using the LabelMap action so the intended behavior is explicit and the platform does not need to apply defaults.
+ // Use "$1" for the first capture group, "$2" for the second, etc.
+ // Must be between 1 and 255 characters in length. Empty string is invalid as it would produce invalid label names.
+ // +required
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=255
+ Replacement string `json:"replacement,omitempty"`
+}
+
+// TLSConfig represents TLS configuration for Alertmanager connections.
+// At least one TLS configuration option must be specified.
+// For mutual TLS (mTLS), both cert and key must be specified together, or both omitted.
+// +kubebuilder:validation:MinProperties=1
+// +kubebuilder:validation:XValidation:rule="(has(self.cert) && has(self.key)) || (!has(self.cert) && !has(self.key))",message="cert and key must both be specified together for mutual TLS, or both be omitted"
+type TLSConfig struct {
+ // ca is an optional CA certificate to use for TLS connections.
+ // When omitted, the system's default CA bundle is used.
+ // +optional
+ CA SecretKeySelector `json:"ca,omitempty,omitzero"`
+ // cert is an optional client certificate to use for mutual TLS connections.
+ // When omitted, no client certificate is presented.
+ // +optional
+ Cert SecretKeySelector `json:"cert,omitempty,omitzero"`
+ // key is an optional client key to use for mutual TLS connections.
+ // When omitted, no client key is used.
+ // +optional
+ Key SecretKeySelector `json:"key,omitempty,omitzero"`
+ // serverName is an optional server name to use for TLS connections.
+ // When specified, must be a valid DNS subdomain as per RFC 1123.
+ // When omitted, the server name is derived from the URL.
+ // Must be between 1 and 253 characters in length.
+ // +optional
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=253
+ // +kubebuilder:validation:XValidation:rule="!format.dns1123Subdomain().validate(self).hasValue()",message="must be a valid DNS subdomain (lowercase alphanumeric characters, '-' or '.', start and end with alphanumeric)"
+ ServerName string `json:"serverName,omitempty"`
+ // certificateVerification determines the policy for TLS certificate verification.
+ // Allowed values are "Verify" (performs certificate verification, secure) and "SkipVerify" (skips verification, insecure).
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The default value is "Verify".
+ // +optional
+ CertificateVerification CertificateVerificationType `json:"certificateVerification,omitempty"`
+}
+
+// CertificateVerificationType defines the TLS certificate verification policy.
+// +kubebuilder:validation:Enum=Verify;SkipVerify
+type CertificateVerificationType string
+
+const (
+ // CertificateVerificationVerify performs certificate verification (secure, recommended).
+ CertificateVerificationVerify CertificateVerificationType = "Verify"
+ // CertificateVerificationSkipVerify skips certificate verification (insecure, use with caution).
+ CertificateVerificationSkipVerify CertificateVerificationType = "SkipVerify"
+)
+
+// AuthorizationType defines the type of authentication to use.
+// +kubebuilder:validation:Enum=BearerToken
+type AuthorizationType string
+
+const (
+ // AuthorizationTypeBearerToken indicates bearer token authentication.
+ AuthorizationTypeBearerToken AuthorizationType = "BearerToken"
+)
+
+// AuthorizationConfig defines the authentication method for Alertmanager connections.
+// +kubebuilder:validation:XValidation:rule="has(self.type) && self.type == 'BearerToken' ? has(self.bearerToken) : !has(self.bearerToken)",message="bearerToken is required when type is BearerToken"
+// +union
+type AuthorizationConfig struct {
+ // type specifies the authentication type to use.
+ // Valid value is "BearerToken" (bearer token authentication).
+ // When set to BearerToken, the bearerToken field must be specified.
+ // +unionDiscriminator
+ // +required
+ Type AuthorizationType `json:"type,omitempty"`
+ // bearerToken defines the secret reference containing the bearer token.
+ // Required when type is "BearerToken", and forbidden otherwise.
+ // The secret must exist in the openshift-monitoring namespace.
+ // +optional
+ BearerToken SecretKeySelector `json:"bearerToken,omitempty,omitzero"`
+}
+
+// SecretKeySelector selects a key of a Secret in the `openshift-monitoring` namespace.
+// +structType=atomic
+type SecretKeySelector struct {
+ // name is the name of the secret in the `openshift-monitoring` namespace to select from.
+ // Must be a valid Kubernetes secret name (lowercase alphanumeric, '-' or '.', start/end with alphanumeric).
+ // Must be between 1 and 253 characters in length.
+ // +required
// +kubebuilder:validation:MinLength=1
- // +kubebuilder:validation:XValidation:rule="isQuantity(self) && quantity(self).isGreaterThan(quantity('0'))",message="request must be a positive, non-zero quantity"
- Request resource.Quantity `json:"request,omitempty"`
+ // +kubebuilder:validation:MaxLength=253
+ // +kubebuilder:validation:XValidation:rule="!format.dns1123Subdomain().validate(self).hasValue()",message="must be a valid secret name (lowercase alphanumeric characters, '-' or '.', start and end with alphanumeric)"
+ Name string `json:"name,omitempty"`
+ // key is the key of the secret to select from.
+ // Must consist of alphanumeric characters, '-', '_', or '.'.
+ // Must be between 1 and 253 characters in length.
+ // +required
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=253
+ // +kubebuilder:validation:XValidation:rule="self.matches('^[a-zA-Z0-9._-]+$')",message="must contain only alphanumeric characters, '-', '_', or '.'"
+ Key string `json:"key,omitempty"`
+}
- // limit is the maximum amount of the resource allowed (e.g. "2Mi", "1Gi").
- // This field is optional.
- // When request is specified, limit cannot be less than request.
- // The value must be greater than 0 when specified.
+// Retention configures how long Prometheus retains metrics data and how much storage it can use.
+// +kubebuilder:validation:MinProperties=1
+type Retention struct {
+ // TOMBSTONE: This field has been tombstoned in favor of the `duration` field. This tombstone will be dropped when promoting this API to v1.
+ // ---
+ // durationInDays specifies how many days Prometheus will retain metrics data.
+ // Prometheus automatically deletes data older than this duration.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The default value is 15.
+ // Minimum value is 1 day.
+ // Maximum value is 365 days (1 year).
+ // Former marker: kubebuilder:validation:Minimum=1
+ // Former marker: kubebuilder:validation:Maximum=365
+ // Former marker: optional
+ // DurationInDays int32 `json:"durationInDays,omitempty"`
+
+ // TOMBSTONE: This field has been tombstoned in favor of the `size` field. This tombstone will be dropped when promoting this API to v1.
+ // ---
+ // sizeInGiB specifies the maximum storage size in gibibytes (GiB) that Prometheus
+ // can use for data blocks and the write-ahead log (WAL).
+ // When the limit is reached, Prometheus will delete oldest data first.
+ // When omitted, no size limit is enforced and Prometheus uses available PersistentVolume capacity.
+ // Minimum value is 1 GiB.
+ // Maximum value is 16384 GiB (16 TiB).
+ // Former marker: kubebuilder:validation:Minimum=1
+ // Former marker: kubebuilder:validation:Maximum=16384
+ // Former marker: optional
+ // SizeInGiB int32 `json:"sizeInGiB,omitempty"`
+
+ // duration is an optional field that specifies how long Prometheus retains metrics data.
+ // Valid values are Prometheus-style duration strings with unit suffixes y, w, d, h, m, s, or ms
+ // (for example, "15d", "24h", or "5d1h30m"). Each unit value must be a positive integer.
+ // Composite durations must follow the fixed unit order y, w, d, h, m, s, ms.
+ // Must be at least 1 character and at most 64 characters.
+ // When set to "0", time-based retention is disabled. This is the only supported form for disabling
+ // time-based retention; other zero-duration representations such as "0d", "0h", or "0y" are rejected.
+ // Prometheus automatically deletes data older than this duration.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The current default value is `15d`.
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=64
+ // +kubebuilder:validation:XValidation:rule=`self == "0" || self.matches('^([1-9][0-9]*y)?([1-9][0-9]*w)?([1-9][0-9]*d)?([1-9][0-9]*h)?([1-9][0-9]*m)?([1-9][0-9]*s)?([1-9][0-9]*ms)?$')`,message=`must be "0" to disable time-based retention, or a duration string with only positive unit values`
// +optional
- // +kubebuilder:validation:XIntOrString
- // +kubebuilder:validation:MaxLength=20
+ Duration string `json:"duration,omitempty"`
+
+ // size is an optional field that specifies the maximum storage size that Prometheus
+ // can use for data blocks and the write-ahead log (WAL).
+ // Valid values are byte-size strings with an optional decimal prefix and a unit suffix B, KB, MB, GB,
+ // TB, EB, PB, or their binary equivalents KiB, MiB, GiB, TiB, EiB, PiB (for example, "500MiB", "10GiB").
+ // The numeric value must be greater than zero.
+ // Must be at least 1 character and at most 32 characters.
+ // When set to "0", no size limit is enforced. This is the only supported form for disabling size-based
+ // retention; other zero-size representations such as "0B" or "0MiB" are rejected.
+ // When the limit is reached, Prometheus deletes oldest data first.
+ // When omitted, no size limit is enforced and Prometheus uses available PersistentVolume capacity.
// +kubebuilder:validation:MinLength=1
- // +kubebuilder:validation:XValidation:rule="isQuantity(self) && quantity(self).isGreaterThan(quantity('0'))",message="limit must be a positive, non-zero quantity"
- Limit resource.Quantity `json:"limit,omitempty"`
+ // +kubebuilder:validation:MaxLength=32
+ // +kubebuilder:validation:XValidation:rule=`self == "0" || self.matches('^([1-9][0-9]*([.][0-9]+)?|[0-9]*[.][1-9][0-9]*)((K|M|G|T|E|P)i?)?B$')`,message=`must be "0" to disable size-based retention, or a positive byte-size string`
+ // +optional
+ Size string `json:"size,omitempty"`
}
-// SecretName is a type that represents the name of a Secret in the same namespace.
-// It must be at most 253 characters in length.
-// +kubebuilder:validation:XValidation:rule="!format.dns1123Subdomain().validate(self).hasValue()",message="a lowercase RFC 1123 subdomain must consist of lower case alphanumeric characters, '-' or '.', and must start and end with an alphanumeric character."
-// +kubebuilder:validation:MaxLength=63
-type SecretName string
+// RelabelAction defines the action to perform in a relabeling rule.
+// +kubebuilder:validation:Enum=Replace;Keep;Drop;HashMod;LabelMap;LabelDrop;LabelKeep;Lowercase;Uppercase;KeepEqual;DropEqual
+type RelabelAction string
-// MetricsServerConfig provides configuration options for the Metrics Server instance
-// that runs in the `openshift-monitoring` namespace. Use this configuration to control
-// how the Metrics Server instance is deployed, how it logs, and how its pods are scheduled.
+const (
+ // RelabelActionReplace: match regex against concatenated source_labels; set target_label to replacement with ${1}, ${2}, ... substituted. No replacement if regex does not match.
+ RelabelActionReplace RelabelAction = "Replace"
+ // RelabelActionLowercase: map the concatenated source_labels to their lower case.
+ RelabelActionLowercase RelabelAction = "Lowercase"
+ // RelabelActionUppercase: map the concatenated source_labels to their upper case.
+ RelabelActionUppercase RelabelAction = "Uppercase"
+ // RelabelActionKeep: drop targets for which regex does not match the concatenated source_labels.
+ RelabelActionKeep RelabelAction = "Keep"
+ // RelabelActionDrop: drop targets for which regex matches the concatenated source_labels.
+ RelabelActionDrop RelabelAction = "Drop"
+ // RelabelActionKeepEqual: drop targets for which the concatenated source_labels do not match target_label.
+ RelabelActionKeepEqual RelabelAction = "KeepEqual"
+ // RelabelActionDropEqual: drop targets for which the concatenated source_labels do match target_label.
+ RelabelActionDropEqual RelabelAction = "DropEqual"
+ // RelabelActionHashMod: set target_label to the modulus of a hash of the concatenated source_labels.
+ RelabelActionHashMod RelabelAction = "HashMod"
+ // RelabelActionLabelMap: match regex against all source label names; copy matching label values to new names given by replacement with ${1}, ${2}, ... substituted.
+ RelabelActionLabelMap RelabelAction = "LabelMap"
+ // RelabelActionLabelDrop: match regex against all label names; any label that matches is removed.
+ RelabelActionLabelDrop RelabelAction = "LabelDrop"
+ // RelabelActionLabelKeep: match regex against all label names; any label that does not match is removed.
+ RelabelActionLabelKeep RelabelAction = "LabelKeep"
+)
+
+// CollectionProfile defines the metrics collection profile for Prometheus.
+// +kubebuilder:validation:Enum=Full;Minimal
+type CollectionProfile string
+
+const (
+ // CollectionProfileFull means Prometheus collects all metrics that are exposed by the platform components.
+ CollectionProfileFull CollectionProfile = "Full"
+ // CollectionProfileMinimal means Prometheus only collects metrics necessary for the default
+ // platform alerts, recording rules, telemetry and console dashboards.
+ CollectionProfileMinimal CollectionProfile = "Minimal"
+)
+
+// TelemeterClientConfig provides configuration options for the Telemeter Client component
+// that runs in the `openshift-monitoring` namespace. The Telemeter Client collects selected
+// monitoring metrics and forwards them to Red Hat for telemetry purposes.
+// At least one field must be specified.
// +kubebuilder:validation:MinProperties=1
-type MetricsServerConfig struct {
- // audit defines the audit configuration used by the Metrics Server instance.
- // audit is optional.
- // When omitted, this means no opinion and the platform is left to choose a reasonable default, that is subject to change over time.
- //The current default sets audit.profile to Metadata
- // +optional
- Audit Audit `json:"audit,omitempty,omitzero"`
- // nodeSelector defines the nodes on which the Pods are scheduled
+type TelemeterClientConfig struct {
+ // nodeSelector defines the nodes on which the Pods are scheduled.
// nodeSelector is optional.
//
// When omitted, this means the user has no opinion and the platform is left
// to choose reasonable defaults. These defaults are subject to change over time.
// The current default value is `kubernetes.io/os: linux`.
+ // When specified, nodeSelector must contain at least 1 entry and must not contain more than 10 entries.
// +optional
// +kubebuilder:validation:MinProperties=1
// +kubebuilder:validation:MaxProperties=10
NodeSelector map[string]string `json:"nodeSelector,omitempty"`
- // tolerations defines tolerations for the pods.
- // tolerations is optional.
- //
- // When omitted, this means the user has no opinion and the platform is left
- // to choose reasonable defaults. These defaults are subject to change over time.
- // Defaults are empty/unset.
- // Maximum length for this list is 10.
- // Minimum length for this list is 1.
- // +kubebuilder:validation:MaxItems=10
- // +kubebuilder:validation:MinItems=1
- // +listType=atomic
- // +optional
- Tolerations []v1.Toleration `json:"tolerations,omitempty"`
- // verbosity defines the verbosity of log messages for Metrics Server.
- // Valid values are Errors, Info, Trace, TraceAll and omitted.
- // When set to Errors, only critical messages and errors are logged.
- // When set to Info, only basic information messages are logged.
- // When set to Trace, information useful for general debugging is logged.
- // When set to TraceAll, detailed information about metric scraping is logged.
- // When omitted, this means no opinion and the platform is left to choose a reasonable default, that is subject to change over time.
- // The current default value is `Errors`
- // +optional
- Verbosity VerbosityLevel `json:"verbosity,omitempty,omitzero"`
- // resources defines the compute resource requests and limits for the Metrics Server container.
+ // resources defines the compute resource requests and limits for the Telemeter Client container.
// This includes CPU, memory and HugePages constraints to help control scheduling and resource usage.
// When not specified, defaults are used by the platform. Requests cannot exceed limits.
// This field is optional.
@@ -396,21 +2573,34 @@ type MetricsServerConfig struct {
// The current default values are:
// resources:
// - name: cpu
- // request: 4m
+ // request: 1m
// limit: null
// - name: memory
// request: 40Mi
// limit: null
- // Maximum length for this list is 10.
+ // Maximum length for this list is 5.
// Minimum length for this list is 1.
// Each resource name must be unique within this list.
// +optional
// +listType=map
// +listMapKey=name
- // +kubebuilder:validation:MaxItems=10
+ // +kubebuilder:validation:MaxItems=5
// +kubebuilder:validation:MinItems=1
Resources []ContainerResource `json:"resources,omitempty"`
- // topologySpreadConstraints defines rules for how Metrics Server Pods should be distributed
+ // tolerations defines tolerations for the pods.
+ // tolerations is optional.
+ //
+ // When omitted, this means the user has no opinion and the platform is left
+ // to choose reasonable defaults. These defaults are subject to change over time.
+ // Defaults are empty/unset.
+ // Maximum length for this list is 10.
+ // Minimum length for this list is 1.
+ // +kubebuilder:validation:MaxItems=10
+ // +kubebuilder:validation:MinItems=1
+ // +listType=atomic
+ // +optional
+ Tolerations []v1.Toleration `json:"tolerations,omitempty"`
+ // topologySpreadConstraints defines rules for how Telemeter Client Pods should be distributed
// across topology domains such as zones, nodes, or other user-defined labels.
// topologySpreadConstraints is optional.
// This helps improve high availability and resource efficiency by avoiding placing
@@ -431,13 +2621,13 @@ type MetricsServerConfig struct {
TopologySpreadConstraints []v1.TopologySpreadConstraint `json:"topologySpreadConstraints,omitempty"`
}
-// PrometheusOperatorConfig provides configuration options for the Prometheus Operator instance
-// Use this configuration to control how the Prometheus Operator instance is deployed, how it logs, and how its pods are scheduled.
+// ThanosQuerierConfig provides configuration options for the Thanos Querier component
+// that runs in the `openshift-monitoring` namespace.
+// At least one field must be specified; an empty thanosQuerierConfig object is not allowed.
// +kubebuilder:validation:MinProperties=1
-type PrometheusOperatorConfig struct {
- // logLevel defines the verbosity of logs emitted by Prometheus Operator.
- // This field allows users to control the amount and severity of logs generated, which can be useful
- // for debugging issues or reducing noise in production environments.
+type ThanosQuerierConfig struct {
+ // logLevel defines the verbosity of logs emitted by Thanos Querier.
+ // logLevel is optional.
// Allowed values are Error, Warn, Info, and Debug.
// When set to Error, only errors will be logged.
// When set to Warn, both warnings and errors will be logged.
@@ -447,7 +2637,24 @@ type PrometheusOperatorConfig struct {
// The current default value is `Info`.
// +optional
LogLevel LogLevel `json:"logLevel,omitempty"`
- // nodeSelector defines the nodes on which the Pods are scheduled
+ // requestLogging configures request logging for Thanos Querier.
+ // requestLogging is optional.
+ // When provided, the policy field within is required.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, that is subject to change over time.
+ // The current default behavior is to not log any requests.
+ // +optional
+ RequestLogging ThanosQuerierRequestLoggingConfig `json:"requestLogging,omitempty,omitzero"`
+ // crossOriginRequestPolicy configures the CORS (Cross-Origin Resource Sharing) policy
+ // for Thanos Querier's HTTP endpoints.
+ // crossOriginRequestPolicy is optional.
+ // Valid values are "AllowAll" and "DenyAll".
+ // When set to "AllowAll", CORS headers are added to responses, allowing cross-origin requests from any domain.
+ // When set to "DenyAll", no CORS headers are added and cross-origin requests are rejected by the browser.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, that is subject to change over time.
+ // The current default value is "DenyAll".
+ // +optional
+ CrossOriginRequestPolicy CrossOriginRequestPolicy `json:"crossOriginRequestPolicy,omitempty"`
+ // nodeSelector defines the nodes on which the Pods are scheduled.
// nodeSelector is optional.
//
// When omitted, this means the user has no opinion and the platform is left
@@ -458,27 +2665,27 @@ type PrometheusOperatorConfig struct {
// +kubebuilder:validation:MinProperties=1
// +kubebuilder:validation:MaxProperties=10
NodeSelector map[string]string `json:"nodeSelector,omitempty"`
- // resources defines the compute resource requests and limits for the Prometheus Operator container.
- // This includes CPU, memory and HugePages constraints to help control scheduling and resource usage.
- // When not specified, defaults are used by the platform. Requests cannot exceed limits.
- // This field is optional.
+ // resources defines the compute resource requests and limits for the Thanos Querier container.
+ // resources is optional.
+ //
+ // When omitted, this means the user has no opinion and the platform is left
+ // to choose reasonable defaults. These defaults are subject to change over time.
+ // Requests cannot exceed limits.
// More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/
// This is a simplified API that maps to Kubernetes ResourceRequirements.
// The current default values are:
// resources:
// - name: cpu
- // request: 4m
- // limit: null
+ // request: 5m
// - name: memory
- // request: 40Mi
- // limit: null
- // Maximum length for this list is 10.
+ // request: 12Mi
+ // Maximum length for this list is 5.
// Minimum length for this list is 1.
// Each resource name must be unique within this list.
// +optional
// +listType=map
// +listMapKey=name
- // +kubebuilder:validation:MaxItems=10
+ // +kubebuilder:validation:MaxItems=5
// +kubebuilder:validation:MinItems=1
Resources []ContainerResource `json:"resources,omitempty"`
// tolerations defines tolerations for the pods.
@@ -494,7 +2701,7 @@ type PrometheusOperatorConfig struct {
// +listType=atomic
// +optional
Tolerations []v1.Toleration `json:"tolerations,omitempty"`
- // topologySpreadConstraints defines rules for how Prometheus Operator Pods should be distributed
+ // topologySpreadConstraints defines rules for how Thanos Querier Pods should be distributed
// across topology domains such as zones, nodes, or other user-defined labels.
// topologySpreadConstraints is optional.
// This helps improve high availability and resource efficiency by avoiding placing
@@ -502,7 +2709,7 @@ type PrometheusOperatorConfig struct {
//
// When omitted, this means no opinion and the platform is left to choose a default, which is subject to change over time.
// This field maps directly to the `topologySpreadConstraints` field in the Pod spec.
- // Default is empty list.
+ // Defaults are empty/unset.
// Maximum length for this list is 10.
// Minimum length for this list is 1.
// Entries must have unique topologyKey and whenUnsatisfiable pairs.
@@ -515,57 +2722,42 @@ type PrometheusOperatorConfig struct {
TopologySpreadConstraints []v1.TopologySpreadConstraint `json:"topologySpreadConstraints,omitempty"`
}
-// PrometheusOperatorAdmissionWebhookConfig provides configuration options for the admission webhook
-// component of Prometheus Operator that runs in the `openshift-monitoring` namespace. The admission
-// webhook validates PrometheusRule and AlertmanagerConfig objects, mutates PrometheusRule annotations,
-// and converts AlertmanagerConfig objects between API versions.
-// +kubebuilder:validation:MinProperties=1
-type PrometheusOperatorAdmissionWebhookConfig struct {
- // resources defines the compute resource requests and limits for the
- // prometheus-operator-admission-webhook container.
- // This includes CPU, memory and HugePages constraints to help control scheduling and resource usage.
- // When not specified, defaults are used by the platform. Requests cannot exceed limits.
- // This field is optional.
- // More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/
- // This is a simplified API that maps to Kubernetes ResourceRequirements.
- // The current default values are:
- // resources:
- // - name: cpu
- // request: 5m
- // limit: null
- // - name: memory
- // request: 30Mi
- // limit: null
- // Maximum length for this list is 10.
- // Minimum length for this list is 1.
- // Each resource name must be unique within this list.
- // +optional
- // +listType=map
- // +listMapKey=name
- // +kubebuilder:validation:MaxItems=10
- // +kubebuilder:validation:MinItems=1
- Resources []ContainerResource `json:"resources,omitempty"`
- // topologySpreadConstraints defines rules for how admission webhook Pods should be distributed
- // across topology domains such as zones, nodes, or other user-defined labels.
- // topologySpreadConstraints is optional.
- // This helps improve high availability and resource efficiency by avoiding placing
- // too many replicas in the same failure domain.
- //
- // When omitted, this means no opinion and the platform is left to choose a default, which is subject to change over time.
- // This field maps directly to the `topologySpreadConstraints` field in the Pod spec.
- // Default is empty list.
- // Maximum length for this list is 10.
- // Minimum length for this list is 1.
- // Entries must have unique topologyKey and whenUnsatisfiable pairs.
- // +kubebuilder:validation:MaxItems=10
- // +kubebuilder:validation:MinItems=1
- // +listType=map
- // +listMapKey=topologyKey
- // +listMapKey=whenUnsatisfiable
- // +optional
- TopologySpreadConstraints []v1.TopologySpreadConstraint `json:"topologySpreadConstraints,omitempty"`
+// ThanosQuerierRequestLoggingConfig configures request logging for Thanos Querier.
+type ThanosQuerierRequestLoggingConfig struct {
+ // policy determines which HTTP and gRPC requests are logged by Thanos Querier.
+ // Valid values are "AllRequests" and "NoRequests".
+ // When set to "AllRequests", every request received by Thanos Querier is logged with method, path, and response status.
+ // The log level for request logs is derived from the logLevel field.
+ // When set to "NoRequests", request logging is turned off.
+ // +required
+ Policy RequestLoggingPolicy `json:"policy,omitempty"`
}
+// RequestLoggingPolicy controls which HTTP and gRPC requests are logged.
+// Valid values are "AllRequests" and "NoRequests".
+// +kubebuilder:validation:Enum=AllRequests;NoRequests
+type RequestLoggingPolicy string
+
+const (
+ // RequestLoggingPolicyAllRequests enables logging of all incoming requests.
+ RequestLoggingPolicyAllRequests RequestLoggingPolicy = "AllRequests"
+ // RequestLoggingPolicyNoRequests disables request logging.
+ RequestLoggingPolicyNoRequests RequestLoggingPolicy = "NoRequests"
+)
+
+// CrossOriginRequestPolicy controls the CORS (Cross-Origin Resource Sharing) policy
+// for Thanos Querier's HTTP endpoints.
+// Valid values are "AllowAll" and "DenyAll".
+// +kubebuilder:validation:Enum=AllowAll;DenyAll
+type CrossOriginRequestPolicy string
+
+const (
+ // CrossOriginRequestPolicyAllowAll sets CORS headers allowing requests from any origin.
+ CrossOriginRequestPolicyAllowAll CrossOriginRequestPolicy = "AllowAll"
+ // CrossOriginRequestPolicyDenyAll does not set CORS headers, rejecting cross-origin requests.
+ CrossOriginRequestPolicyDenyAll CrossOriginRequestPolicy = "DenyAll"
+)
+
// AuditProfile defines the audit log level for the Metrics Server.
// +kubebuilder:validation:Enum=None;Metadata;Request;RequestResponse
type AuditProfile string
@@ -596,6 +2788,27 @@ const (
VerbosityLevelTraceAll VerbosityLevel = "TraceAll"
)
+// ExemplarsMode defines whether exemplars are sent via remote write.
+// +kubebuilder:validation:Enum=Send;DoNotSend
+type ExemplarsMode string
+
+const (
+ // ExemplarsModeSend means exemplars are sent via remote write.
+ ExemplarsModeSend ExemplarsMode = "Send"
+ // ExemplarsModeDoNotSend means exemplars are not sent via remote write.
+ ExemplarsModeDoNotSend ExemplarsMode = "DoNotSend"
+)
+
+// RateLimitedAction defines what to do when the remote write endpoint returns HTTP 429 (Too Many Requests).
+// Omission of this field means do not retry. When set, the only valid value is Retry.
+// +kubebuilder:validation:Enum=Retry
+type RateLimitedAction string
+
+const (
+ // RateLimitedActionRetry means requests will be retried on HTTP 429 responses.
+ RateLimitedActionRetry RateLimitedAction = "Retry"
+)
+
// Audit profile configurations
type Audit struct {
// profile is a required field for configuring the audit log level of the Kubernetes Metrics Server.
@@ -610,3 +2823,154 @@ type Audit struct {
// +required
Profile AuditProfile `json:"profile,omitempty"`
}
+
+// KubeStateMetricsConfig provides configuration options for the kube-state-metrics agent
+// that runs in the `openshift-monitoring` namespace. kube-state-metrics generates metrics
+// about the state of Kubernetes objects such as Deployments, Nodes, and Pods.
+// +kubebuilder:validation:MinProperties=1
+type KubeStateMetricsConfig struct {
+ // nodeSelector defines the nodes on which the Pods are scheduled.
+ // nodeSelector is optional.
+ //
+ // When omitted, this means the user has no opinion and the platform is left
+ // to choose reasonable defaults. These defaults are subject to change over time.
+ // The current default value is `kubernetes.io/os: linux`.
+ // When specified, nodeSelector must contain at least 1 entry and must not contain more than 10 entries.
+ // +optional
+ // +kubebuilder:validation:MinProperties=1
+ // +kubebuilder:validation:MaxProperties=10
+ NodeSelector map[string]string `json:"nodeSelector,omitempty"`
+ // resources defines the compute resource requests and limits for the kube-state-metrics container.
+ // This includes CPU, memory and HugePages constraints to help control scheduling and resource usage.
+ // When not specified, defaults are used by the platform. Requests cannot exceed limits.
+ // This field is optional.
+ // More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/
+ // This is a simplified API that maps to Kubernetes ResourceRequirements.
+ // The current default values are:
+ // resources:
+ // - name: cpu
+ // request: 4m
+ // limit: null
+ // - name: memory
+ // request: 40Mi
+ // limit: null
+ // Maximum length for this list is 5.
+ // Minimum length for this list is 1.
+ // Each resource name must be unique within this list.
+ // +optional
+ // +listType=map
+ // +listMapKey=name
+ // +kubebuilder:validation:MaxItems=5
+ // +kubebuilder:validation:MinItems=1
+ Resources []ContainerResource `json:"resources,omitempty"`
+ // tolerations defines tolerations for the pods.
+ // tolerations is optional.
+ //
+ // When omitted, no tolerations are applied. This default is subject to change over time.
+ // When specified, tolerations must contain at least 1 entry and must not contain more than 10 entries.
+ // Each toleration's operator, when specified, must be either "Exists" or "Equal".
+ // Each toleration's effect, when specified, must be one of "NoSchedule", "PreferNoSchedule", or "NoExecute".
+ // An empty or unset effect means match all effects.
+ // +kubebuilder:validation:MaxItems=10
+ // +kubebuilder:validation:MinItems=1
+ // +listType=atomic
+ // +kubebuilder:validation:XValidation:rule="self.all(t, !has(t.operator) || t.operator == 'Exists' || t.operator == 'Equal')",message="operator must be either Exists or Equal"
+ // +kubebuilder:validation:XValidation:rule="self.all(t, !has(t.effect) || t.effect == 'NoSchedule' || t.effect == 'PreferNoSchedule' || t.effect == 'NoExecute' || t.effect == '')",message="effect must be NoSchedule, PreferNoSchedule, NoExecute, or empty"
+ // +optional
+ Tolerations []v1.Toleration `json:"tolerations,omitempty"`
+ // topologySpreadConstraints defines rules for how kube-state-metrics Pods should be distributed
+ // across topology domains such as zones, nodes, or other user-defined labels.
+ // topologySpreadConstraints is optional.
+ // This helps improve high availability and resource efficiency by avoiding placing
+ // too many replicas in the same failure domain.
+ //
+ // This field maps directly to the `topologySpreadConstraints` field in the Pod spec.
+ // When omitted, no topology spread constraints are applied. This default is subject to change over time.
+ // When specified, topologySpreadConstraints must contain at least 1 entry and must not contain more than 10 entries.
+ // Entries must have unique topologyKey and whenUnsatisfiable pairs.
+ // Each entry's whenUnsatisfiable must be either "DoNotSchedule" or "ScheduleAnyway".
+ // Each entry's maxSkew must be at least 1.
+ // When minDomains is specified, it must be at least 1 and whenUnsatisfiable must be "DoNotSchedule".
+ // +kubebuilder:validation:MaxItems=10
+ // +kubebuilder:validation:MinItems=1
+ // +listType=map
+ // +listMapKey=topologyKey
+ // +listMapKey=whenUnsatisfiable
+ // +kubebuilder:validation:XValidation:rule="self.all(c, c.whenUnsatisfiable == 'DoNotSchedule' || c.whenUnsatisfiable == 'ScheduleAnyway')",message="whenUnsatisfiable must be either DoNotSchedule or ScheduleAnyway"
+ // +kubebuilder:validation:XValidation:rule="self.all(c, c.maxSkew >= 1)",message="maxSkew must be at least 1"
+ // +kubebuilder:validation:XValidation:rule="self.all(c, !has(c.minDomains) || c.minDomains >= 1)",message="minDomains must be at least 1"
+ // +kubebuilder:validation:XValidation:rule="self.all(c, !has(c.minDomains) || c.whenUnsatisfiable == 'DoNotSchedule')",message="minDomains can only be used when whenUnsatisfiable is DoNotSchedule"
+ // +optional
+ TopologySpreadConstraints []v1.TopologySpreadConstraint `json:"topologySpreadConstraints,omitempty"`
+ // additionalResourceLabels defines additional Kubernetes resource labels to expose as metrics
+ // in kube-state-metrics.
+ // Currently, only "Job" and "CronJob" resources are supported due to cardinality concerns.
+ // Each entry specifies a resource name and a list of Kubernetes label names to expose.
+ // Use "*" in the labels list to expose all labels for a given resource.
+ // additionalResourceLabels is optional.
+ // When omitted, no additional Kubernetes object labels are exposed as metrics
+ // by kube-state-metrics beyond its built-in metric labels (e.g. namespace, job_name).
+ // Use this field to opt in to exposing specific Kubernetes labels as metric labels
+ // for the supported resource types.
+ // Minimum length for this list is 1.
+ // Maximum length for this list is 2.
+ // Each resource name must be unique within this list.
+ // +optional
+ // +kubebuilder:validation:MaxItems=2
+ // +kubebuilder:validation:MinItems=1
+ // +listType=map
+ // +listMapKey=resource
+ AdditionalResourceLabels []KubeStateMetricsResourceLabels `json:"additionalResourceLabels,omitempty"`
+}
+
+// KubeStateMetricsResourceName is the name of a Kubernetes resource whose labels can be exposed
+// as metrics by kube-state-metrics. Currently, only "Job" and "CronJob" are supported
+// due to cardinality concerns.
+// Valid values are "Job" and "CronJob".
+// +kubebuilder:validation:Enum=Job;CronJob
+type KubeStateMetricsResourceName string
+
+const (
+ // KubeStateMetricsResourceJob indicates the Kubernetes Job resource.
+ KubeStateMetricsResourceJob KubeStateMetricsResourceName = "Job"
+ // KubeStateMetricsResourceCronJob indicates the Kubernetes CronJob resource.
+ KubeStateMetricsResourceCronJob KubeStateMetricsResourceName = "CronJob"
+)
+
+// KubeStateMetricsLabelName is the name of a Kubernetes label to expose as a metric
+// via kube-state-metrics. Use "*" to expose all labels for a resource.
+// Must be either the wildcard "*" or a valid Kubernetes label key.
+// A valid label key has an optional DNS subdomain prefix followed by a "/" and a name segment,
+// or just a name segment without a prefix. The name segment must be 63 characters or fewer,
+// beginning and ending with an alphanumeric character, with dashes, underscores, dots, and
+// alphanumerics in between.
+// Must be at least 1 character and at most 253 characters in length.
+// +kubebuilder:validation:MinLength=1
+// +kubebuilder:validation:MaxLength=253
+// +kubebuilder:validation:XValidation:rule="self == '*' || !format.qualifiedName().validate(self).hasValue()",message="must be a valid Kubernetes label key or the wildcard '*'"
+type KubeStateMetricsLabelName string
+
+// KubeStateMetricsResourceLabels defines which Kubernetes labels to expose as metrics
+// for a given resource type in kube-state-metrics.
+type KubeStateMetricsResourceLabels struct {
+ // resource is the Kubernetes resource name whose labels should be exposed as metrics.
+ // Currently, only "Job" and "CronJob" are supported due to cardinality concerns.
+ // Valid values are "Job" and "CronJob".
+ // This field is required.
+ // +required
+ Resource KubeStateMetricsResourceName `json:"resource,omitempty"`
+ // labels is the list of Kubernetes label names to expose as metrics for this resource.
+ // Use "*" to expose all labels for the specified resource.
+ // When "*" is specified, it must be the only entry in the list; mixing "*" with
+ // specific label names is not allowed.
+ // This field is required.
+ // Each label name must be unique within this list.
+ // Minimum length for this list is 1.
+ // Maximum length for this list is 50.
+ // +required
+ // +kubebuilder:validation:MinItems=1
+ // +kubebuilder:validation:MaxItems=50
+ // +listType=set
+ // +kubebuilder:validation:XValidation:rule="!self.exists(l, l == '*') || self.size() == 1",message="when '*' is specified, no other labels may be listed"
+ Labels []KubeStateMetricsLabelName `json:"labels,omitempty"`
+}
diff --git a/vendor/github.com/openshift/api/config/v1alpha1/types_image_policy.go b/vendor/github.com/openshift/api/config/v1alpha1/types_image_policy.go
deleted file mode 100644
index 977ca3dde3..0000000000
--- a/vendor/github.com/openshift/api/config/v1alpha1/types_image_policy.go
+++ /dev/null
@@ -1,289 +0,0 @@
-package v1alpha1
-
-import metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
-
-// +genclient
-// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
-
-// ImagePolicy holds namespace-wide configuration for image signature verification
-//
-// Compatibility level 4: No compatibility is provided, the API can change at any point for any reason. These capabilities should not be used by applications needing long term support.
-// +kubebuilder:object:root=true
-// +kubebuilder:resource:path=imagepolicies,scope=Namespaced
-// +kubebuilder:subresource:status
-// +openshift:api-approved.openshift.io=https://github.com/openshift/api/pull/1457
-// +openshift:file-pattern=cvoRunLevel=0000_10,operatorName=config-operator,operatorOrdering=01
-// +openshift:enable:FeatureGate=SigstoreImageVerification
-// +openshift:compatibility-gen:level=4
-type ImagePolicy struct {
- metav1.TypeMeta `json:",inline"`
-
- // metadata is the standard object's metadata.
- // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
- metav1.ObjectMeta `json:"metadata,omitempty"`
-
- // spec holds user settable values for configuration
- // +required
- Spec ImagePolicySpec `json:"spec"`
- // status contains the observed state of the resource.
- // +optional
- Status ImagePolicyStatus `json:"status,omitempty"`
-}
-
-// ImagePolicySpec is the specification of the ImagePolicy CRD.
-type ImagePolicySpec struct {
- // scopes defines the list of image identities assigned to a policy. Each item refers to a scope in a registry implementing the "Docker Registry HTTP API V2".
- // Scopes matching individual images are named Docker references in the fully expanded form, either using a tag or digest. For example, docker.io/library/busybox:latest (not busybox:latest).
- // More general scopes are prefixes of individual-image scopes, and specify a repository (by omitting the tag or digest), a repository
- // namespace, or a registry host (by only specifying the host name and possibly a port number) or a wildcard expression starting with `*.`, for matching all subdomains (not including a port number).
- // Wildcards are only supported for subdomain matching, and may not be used in the middle of the host, i.e. *.example.com is a valid case, but example*.*.com is not.
- // If multiple scopes match a given image, only the policy requirements for the most specific scope apply. The policy requirements for more general scopes are ignored.
- // In addition to setting a policy appropriate for your own deployed applications, make sure that a policy on the OpenShift image repositories
- // quay.io/openshift-release-dev/ocp-release, quay.io/openshift-release-dev/ocp-v4.0-art-dev (or on a more general scope) allows deployment of the OpenShift images required for cluster operation.
- // If a scope is configured in both the ClusterImagePolicy and the ImagePolicy, or if the scope in ImagePolicy is nested under one of the scopes from the ClusterImagePolicy, only the policy from the ClusterImagePolicy will be applied.
- // For additional details about the format, please refer to the document explaining the docker transport field,
- // which can be found at: https://github.com/containers/image/blob/main/docs/containers-policy.json.5.md#docker
- // +required
- // +kubebuilder:validation:MaxItems=256
- // +listType=set
- Scopes []ImageScope `json:"scopes"`
- // policy contains configuration to allow scopes to be verified, and defines how
- // images not matching the verification policy will be treated.
- // +required
- Policy ImageSigstoreVerificationPolicy `json:"policy"`
-}
-
-// +kubebuilder:validation:XValidation:rule="size(self.split('/')[0].split('.')) == 1 ? self.split('/')[0].split('.')[0].split(':')[0] == 'localhost' : true",message="invalid image scope format, scope must contain a fully qualified domain name or 'localhost'"
-// +kubebuilder:validation:XValidation:rule=`self.contains('*') ? self.matches('^\\*(?:\\.(?:[a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9]))+$') : true`,message="invalid image scope with wildcard, a wildcard can only be at the start of the domain and is only supported for subdomain matching, not path matching"
-// +kubebuilder:validation:XValidation:rule=`!self.contains('*') ? self.matches('^((((?:[a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])(?:\\.(?:[a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9]))+(?::[0-9]+)?)|(localhost(?::[0-9]+)?))(?:(?:/[a-z0-9]+(?:(?:(?:[._]|__|[-]*)[a-z0-9]+)+)?)+)?)(?::([\\w][\\w.-]{0,127}))?(?:@([A-Za-z][A-Za-z0-9]*(?:[-_+.][A-Za-z][A-Za-z0-9]*)*[:][[:xdigit:]]{32,}))?$') : true`,message="invalid repository namespace or image specification in the image scope"
-// +kubebuilder:validation:MaxLength=512
-type ImageScope string
-
-// ImageSigstoreVerificationPolicy defines the verification policy for the items in the scopes list.
-type ImageSigstoreVerificationPolicy struct {
- // rootOfTrust specifies the root of trust for the policy.
- // +required
- RootOfTrust PolicyRootOfTrust `json:"rootOfTrust"`
- // signedIdentity specifies what image identity the signature claims about the image. The required matchPolicy field specifies the approach used in the verification process to verify the identity in the signature and the actual image identity, the default matchPolicy is "MatchRepoDigestOrExact".
- // +optional
- SignedIdentity PolicyIdentity `json:"signedIdentity,omitempty"`
-}
-
-// PolicyRootOfTrust defines the root of trust based on the selected policyType.
-// +union
-// +kubebuilder:validation:XValidation:rule="has(self.policyType) && self.policyType == 'PublicKey' ? has(self.publicKey) : !has(self.publicKey)",message="publicKey is required when policyType is PublicKey, and forbidden otherwise"
-// +kubebuilder:validation:XValidation:rule="has(self.policyType) && self.policyType == 'FulcioCAWithRekor' ? has(self.fulcioCAWithRekor) : !has(self.fulcioCAWithRekor)",message="fulcioCAWithRekor is required when policyType is FulcioCAWithRekor, and forbidden otherwise"
-// +openshift:validation:FeatureGateAwareXValidation:featureGate=SigstoreImageVerificationPKI,rule="has(self.policyType) && self.policyType == 'PKI' ? has(self.pki) : !has(self.pki)",message="pki is required when policyType is PKI, and forbidden otherwise"
-type PolicyRootOfTrust struct {
- // policyType serves as the union's discriminator. Users are required to assign a value to this field, choosing one of the policy types that define the root of trust.
- // "PublicKey" indicates that the policy relies on a sigstore publicKey and may optionally use a Rekor verification.
- // "FulcioCAWithRekor" indicates that the policy is based on the Fulcio certification and incorporates a Rekor verification.
- // "PKI" indicates that the policy is based on the certificates from Bring Your Own Public Key Infrastructure (BYOPKI). This value is enabled by turning on the SigstoreImageVerificationPKI feature gate.
- // +unionDiscriminator
- // +required
- PolicyType PolicyType `json:"policyType"`
- // publicKey defines the root of trust based on a sigstore public key.
- // +optional
- PublicKey *ImagePolicyPublicKeyRootOfTrust `json:"publicKey,omitempty"`
- // fulcioCAWithRekor defines the root of trust based on the Fulcio certificate and the Rekor public key.
- // For more information about Fulcio and Rekor, please refer to the document at:
- // https://github.com/sigstore/fulcio and https://github.com/sigstore/rekor
- // +optional
- FulcioCAWithRekor *ImagePolicyFulcioCAWithRekorRootOfTrust `json:"fulcioCAWithRekor,omitempty"`
- // pki defines the root of trust based on Bring Your Own Public Key Infrastructure (BYOPKI) Root CA(s) and corresponding intermediate certificates.
- // +optional
- // +openshift:enable:FeatureGate=SigstoreImageVerificationPKI
- PKI *ImagePolicyPKIRootOfTrust `json:"pki,omitempty"`
-}
-
-// +openshift:validation:FeatureGateAwareEnum:featureGate="",enum=PublicKey;FulcioCAWithRekor
-// +openshift:validation:FeatureGateAwareEnum:featureGate=SigstoreImageVerificationPKI,enum=PublicKey;FulcioCAWithRekor;PKI
-type PolicyType string
-
-const (
- PublicKeyRootOfTrust PolicyType = "PublicKey"
- FulcioCAWithRekorRootOfTrust PolicyType = "FulcioCAWithRekor"
- PKIRootOfTrust PolicyType = "PKI"
-)
-
-// ImagePolicyPublicKeyRootOfTrust defines the root of trust based on a sigstore public key.
-type ImagePolicyPublicKeyRootOfTrust struct {
- // keyData contains inline base64-encoded data for the PEM format public key.
- // KeyData must be at most 8192 characters.
- // +required
- // +kubebuilder:validation:MaxLength=8192
- KeyData []byte `json:"keyData"`
- // rekorKeyData contains inline base64-encoded data for the PEM format from the Rekor public key.
- // rekorKeyData must be at most 8192 characters.
- // +optional
- // +kubebuilder:validation:MaxLength=8192
- RekorKeyData []byte `json:"rekorKeyData,omitempty"`
-}
-
-// ImagePolicyFulcioCAWithRekorRootOfTrust defines the root of trust based on the Fulcio certificate and the Rekor public key.
-type ImagePolicyFulcioCAWithRekorRootOfTrust struct {
- // fulcioCAData contains inline base64-encoded data for the PEM format fulcio CA.
- // fulcioCAData must be at most 8192 characters.
- // +required
- // +kubebuilder:validation:MaxLength=8192
- FulcioCAData []byte `json:"fulcioCAData"`
- // rekorKeyData contains inline base64-encoded data for the PEM format from the Rekor public key.
- // rekorKeyData must be at most 8192 characters.
- // +required
- // +kubebuilder:validation:MaxLength=8192
- RekorKeyData []byte `json:"rekorKeyData"`
- // fulcioSubject specifies OIDC issuer and the email of the Fulcio authentication configuration.
- // +required
- FulcioSubject PolicyFulcioSubject `json:"fulcioSubject"`
-}
-
-// PolicyFulcioSubject defines the OIDC issuer and the email of the Fulcio authentication configuration.
-type PolicyFulcioSubject struct {
- // oidcIssuer contains the expected OIDC issuer. It will be verified that the Fulcio-issued certificate contains a (Fulcio-defined) certificate extension pointing at this OIDC issuer URL. When Fulcio issues certificates, it includes a value based on an URL inside the client-provided ID token.
- // Example: "https://expected.OIDC.issuer/"
- // +required
- // +kubebuilder:validation:XValidation:rule="isURL(self)",message="oidcIssuer must be a valid URL"
- OIDCIssuer string `json:"oidcIssuer"`
- // signedEmail holds the email address the the Fulcio certificate is issued for.
- // Example: "expected-signing-user@example.com"
- // +required
- // +kubebuilder:validation:XValidation:rule=`self.matches('^\\S+@\\S+$')`,message="invalid email address"
- SignedEmail string `json:"signedEmail"`
-}
-
-// ImagePolicyPKIRootOfTrust defines the root of trust based on Root CA(s) and corresponding intermediate certificates.
-type ImagePolicyPKIRootOfTrust struct {
- // caRootsData contains base64-encoded data of a certificate bundle PEM file, which contains one or more CA roots in the PEM format. The total length of the data must not exceed 8192 characters.
- // +required
- // +kubebuilder:validation:MaxLength=8192
- // +kubebuilder:validation:XValidation:rule="string(self).startsWith('-----BEGIN CERTIFICATE-----')",message="the caRootsData must start with base64 encoding of '-----BEGIN CERTIFICATE-----'."
- // +kubebuilder:validation:XValidation:rule="string(self).endsWith('-----END CERTIFICATE-----\\n') || string(self).endsWith('-----END CERTIFICATE-----')",message="the caRootsData must end with base64 encoding of '-----END CERTIFICATE-----'."
- // +kubebuilder:validation:XValidation:rule="string(self).findAll('-----BEGIN CERTIFICATE-----').size() == string(self).findAll('-----END CERTIFICATE-----').size()",message="caRootsData must be base64 encoding of valid PEM format data contain the same number of '-----BEGIN CERTIFICATE-----' and '-----END CERTIFICATE-----' markers."
- CertificateAuthorityRootsData []byte `json:"caRootsData"`
- // caIntermediatesData contains base64-encoded data of a certificate bundle PEM file, which contains one or more intermediate certificates in the PEM format. The total length of the data must not exceed 8192 characters.
- // caIntermediatesData requires caRootsData to be set.
- // +optional
- // +kubebuilder:validation:XValidation:rule="string(self).startsWith('-----BEGIN CERTIFICATE-----')",message="the caIntermediatesData must start with base64 encoding of '-----BEGIN CERTIFICATE-----'."
- // +kubebuilder:validation:XValidation:rule="string(self).endsWith('-----END CERTIFICATE-----\\n') || string(self).endsWith('-----END CERTIFICATE-----')",message="the caIntermediatesData must end with base64 encoding of '-----END CERTIFICATE-----'."
- // +kubebuilder:validation:XValidation:rule="string(self).findAll('-----BEGIN CERTIFICATE-----').size() == string(self).findAll('-----END CERTIFICATE-----').size()",message="caIntermediatesData must be base64 encoding of valid PEM format data contain the same number of '-----BEGIN CERTIFICATE-----' and '-----END CERTIFICATE-----' markers."
- // +kubebuilder:validation:MaxLength=8192
- CertificateAuthorityIntermediatesData []byte `json:"caIntermediatesData,omitempty"`
-
- // pkiCertificateSubject defines the requirements imposed on the subject to which the certificate was issued.
- // +required
- PKICertificateSubject PKICertificateSubject `json:"pkiCertificateSubject"`
-}
-
-// PKICertificateSubject defines the requirements imposed on the subject to which the certificate was issued.
-// +kubebuilder:validation:XValidation:rule="has(self.email) || has(self.hostname)", message="at least one of email or hostname must be set in pkiCertificateSubject"
-// +openshift:enable:FeatureGate=SigstoreImageVerificationPKI
-type PKICertificateSubject struct {
- // email specifies the expected email address imposed on the subject to which the certificate was issued, and must match the email address listed in the Subject Alternative Name (SAN) field of the certificate.
- // The email should be a valid email address and at most 320 characters in length.
- // +optional
- // +kubebuilder:validation:MaxLength:=320
- // +kubebuilder:validation:XValidation:rule=`self.matches('^\\S+@\\S+$')`,message="invalid email address in pkiCertificateSubject"
- Email string `json:"email,omitempty"`
- // hostname specifies the expected hostname imposed on the subject to which the certificate was issued, and it must match the hostname listed in the Subject Alternative Name (SAN) DNS field of the certificate.
- // The hostname should be a valid dns 1123 subdomain name, optionally prefixed by '*.', and at most 253 characters in length.
- // It should consist only of lowercase alphanumeric characters, hyphens, periods and the optional preceding asterisk.
- // +optional
- // +kubebuilder:validation:MaxLength:=253
- // +kubebuilder:validation:XValidation:rule="self.startsWith('*.') ? !format.dns1123Subdomain().validate(self.replace('*.', '', 1)).hasValue() : !format.dns1123Subdomain().validate(self).hasValue()",message="hostname should be a valid dns 1123 subdomain name, optionally prefixed by '*.'. It should consist only of lowercase alphanumeric characters, hyphens, periods and the optional preceding asterisk."
- Hostname string `json:"hostname,omitempty"`
-}
-
-// PolicyIdentity defines image identity the signature claims about the image. When omitted, the default matchPolicy is "MatchRepoDigestOrExact".
-// +kubebuilder:validation:XValidation:rule="(has(self.matchPolicy) && self.matchPolicy == 'ExactRepository') ? has(self.exactRepository) : !has(self.exactRepository)",message="exactRepository is required when matchPolicy is ExactRepository, and forbidden otherwise"
-// +kubebuilder:validation:XValidation:rule="(has(self.matchPolicy) && self.matchPolicy == 'RemapIdentity') ? has(self.remapIdentity) : !has(self.remapIdentity)",message="remapIdentity is required when matchPolicy is RemapIdentity, and forbidden otherwise"
-// +union
-type PolicyIdentity struct {
- // matchPolicy sets the type of matching to be used.
- // Valid values are "MatchRepoDigestOrExact", "MatchRepository", "ExactRepository", "RemapIdentity". When omitted, the default value is "MatchRepoDigestOrExact".
- // If set matchPolicy to ExactRepository, then the exactRepository must be specified.
- // If set matchPolicy to RemapIdentity, then the remapIdentity must be specified.
- // "MatchRepoDigestOrExact" means that the identity in the signature must be in the same repository as the image identity if the image identity is referenced by a digest. Otherwise, the identity in the signature must be the same as the image identity.
- // "MatchRepository" means that the identity in the signature must be in the same repository as the image identity.
- // "ExactRepository" means that the identity in the signature must be in the same repository as a specific identity specified by "repository".
- // "RemapIdentity" means that the signature must be in the same as the remapped image identity. Remapped image identity is obtained by replacing the "prefix" with the specified “signedPrefix” if the the image identity matches the specified remapPrefix.
- // +unionDiscriminator
- // +required
- MatchPolicy IdentityMatchPolicy `json:"matchPolicy"`
- // exactRepository is required if matchPolicy is set to "ExactRepository".
- // +optional
- PolicyMatchExactRepository *PolicyMatchExactRepository `json:"exactRepository,omitempty"`
- // remapIdentity is required if matchPolicy is set to "RemapIdentity".
- // +optional
- PolicyMatchRemapIdentity *PolicyMatchRemapIdentity `json:"remapIdentity,omitempty"`
-}
-
-// +kubebuilder:validation:MaxLength=512
-// +kubebuilder:validation:XValidation:rule=`self.matches('.*:([\\w][\\w.-]{0,127})$')? self.matches('^(localhost:[0-9]+)$'): true`,message="invalid repository or prefix in the signedIdentity, should not include the tag or digest"
-// +kubebuilder:validation:XValidation:rule=`self.matches('^(((?:[a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])(?:\\.(?:[a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9]))+(?::[0-9]+)?)|(localhost(?::[0-9]+)?))(?:(?:/[a-z0-9]+(?:(?:(?:[._]|__|[-]*)[a-z0-9]+)+)?)+)?$')`,message="invalid repository or prefix in the signedIdentity"
-type IdentityRepositoryPrefix string
-
-type PolicyMatchExactRepository struct {
- // repository is the reference of the image identity to be matched.
- // The value should be a repository name (by omitting the tag or digest) in a registry implementing the "Docker Registry HTTP API V2". For example, docker.io/library/busybox
- // +required
- Repository IdentityRepositoryPrefix `json:"repository"`
-}
-
-type PolicyMatchRemapIdentity struct {
- // prefix is the prefix of the image identity to be matched.
- // If the image identity matches the specified prefix, that prefix is replaced by the specified “signedPrefix” (otherwise it is used as unchanged and no remapping takes place).
- // This useful when verifying signatures for a mirror of some other repository namespace that preserves the vendor’s repository structure.
- // The prefix and signedPrefix values can be either host[:port] values (matching exactly the same host[:port], string), repository namespaces,
- // or repositories (i.e. they must not contain tags/digests), and match as prefixes of the fully expanded form.
- // For example, docker.io/library/busybox (not busybox) to specify that single repository, or docker.io/library (not an empty string) to specify the parent namespace of docker.io/library/busybox.
- // +required
- Prefix IdentityRepositoryPrefix `json:"prefix"`
- // signedPrefix is the prefix of the image identity to be matched in the signature. The format is the same as "prefix". The values can be either host[:port] values (matching exactly the same host[:port], string), repository namespaces,
- // or repositories (i.e. they must not contain tags/digests), and match as prefixes of the fully expanded form.
- // For example, docker.io/library/busybox (not busybox) to specify that single repository, or docker.io/library (not an empty string) to specify the parent namespace of docker.io/library/busybox.
- // +required
- SignedPrefix IdentityRepositoryPrefix `json:"signedPrefix"`
-}
-
-// IdentityMatchPolicy defines the type of matching for "matchPolicy".
-// +kubebuilder:validation:Enum=MatchRepoDigestOrExact;MatchRepository;ExactRepository;RemapIdentity
-type IdentityMatchPolicy string
-
-const (
- IdentityMatchPolicyMatchRepoDigestOrExact IdentityMatchPolicy = "MatchRepoDigestOrExact"
- IdentityMatchPolicyMatchRepository IdentityMatchPolicy = "MatchRepository"
- IdentityMatchPolicyExactRepository IdentityMatchPolicy = "ExactRepository"
- IdentityMatchPolicyRemapIdentity IdentityMatchPolicy = "RemapIdentity"
-)
-
-// +k8s:deepcopy-gen=true
-type ImagePolicyStatus struct {
- // conditions provide details on the status of this API Resource.
- // +listType=map
- // +listMapKey=type
- // +optional
- Conditions []metav1.Condition `json:"conditions,omitempty"`
-}
-
-// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
-
-// ImagePolicyList is a list of ImagePolicy resources
-//
-// Compatibility level 4: No compatibility is provided, the API can change at any point for any reason. These capabilities should not be used by applications needing long term support.
-// +openshift:compatibility-gen:level=4
-type ImagePolicyList struct {
- metav1.TypeMeta `json:",inline"`
-
- // metadata is the standard list's metadata.
- // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
- metav1.ListMeta `json:"metadata"`
-
- Items []ImagePolicy `json:"items"`
-}
-
-const (
- // ImagePolicyPending indicates that the customer resource contains a policy that cannot take effect. It is either overwritten by a global policy or the image scope is not valid.
- ImagePolicyPending = "Pending"
- // ImagePolicyApplied indicates that the policy has been applied
- ImagePolicyApplied = "Applied"
-)
diff --git a/vendor/github.com/openshift/api/config/v1alpha1/zz_generated.deepcopy.go b/vendor/github.com/openshift/api/config/v1alpha1/zz_generated.deepcopy.go
index e28a94dbef..598f38fc5d 100644
--- a/vendor/github.com/openshift/api/config/v1alpha1/zz_generated.deepcopy.go
+++ b/vendor/github.com/openshift/api/config/v1alpha1/zz_generated.deepcopy.go
@@ -11,6 +11,29 @@ import (
runtime "k8s.io/apimachinery/pkg/runtime"
)
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *AdditionalAlertmanagerConfig) DeepCopyInto(out *AdditionalAlertmanagerConfig) {
+ *out = *in
+ out.Authorization = in.Authorization
+ if in.StaticConfigs != nil {
+ in, out := &in.StaticConfigs, &out.StaticConfigs
+ *out = make([]string, len(*in))
+ copy(*out, *in)
+ }
+ out.TLSConfig = in.TLSConfig
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AdditionalAlertmanagerConfig.
+func (in *AdditionalAlertmanagerConfig) DeepCopy() *AdditionalAlertmanagerConfig {
+ if in == nil {
+ return nil
+ }
+ out := new(AdditionalAlertmanagerConfig)
+ in.DeepCopyInto(out)
+ return out
+}
+
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *AlertmanagerConfig) DeepCopyInto(out *AlertmanagerConfig) {
*out = *in
@@ -98,6 +121,23 @@ func (in *Audit) DeepCopy() *Audit {
return out
}
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *AuthorizationConfig) DeepCopyInto(out *AuthorizationConfig) {
+ *out = *in
+ out.BearerToken = in.BearerToken
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AuthorizationConfig.
+func (in *AuthorizationConfig) DeepCopy() *AuthorizationConfig {
+ if in == nil {
+ return nil
+ }
+ out := new(AuthorizationConfig)
+ in.DeepCopyInto(out)
+ return out
+}
+
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *Backup) DeepCopyInto(out *Backup) {
*out = *in
@@ -192,6 +232,24 @@ func (in *BackupStatus) DeepCopy() *BackupStatus {
return out
}
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *BasicAuth) DeepCopyInto(out *BasicAuth) {
+ *out = *in
+ out.Username = in.Username
+ out.Password = in.Password
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BasicAuth.
+func (in *BasicAuth) DeepCopy() *BasicAuth {
+ if in == nil {
+ return nil
+ }
+ out := new(BasicAuth)
+ in.DeepCopyInto(out)
+ return out
+}
+
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *CRIOCredentialProviderConfig) DeepCopyInto(out *CRIOCredentialProviderConfig) {
*out = *in
@@ -318,112 +376,6 @@ func (in *CertificateConfig) DeepCopy() *CertificateConfig {
return out
}
-// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *ClusterImagePolicy) DeepCopyInto(out *ClusterImagePolicy) {
- *out = *in
- out.TypeMeta = in.TypeMeta
- in.ObjectMeta.DeepCopyInto(&out.ObjectMeta)
- in.Spec.DeepCopyInto(&out.Spec)
- in.Status.DeepCopyInto(&out.Status)
- return
-}
-
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterImagePolicy.
-func (in *ClusterImagePolicy) DeepCopy() *ClusterImagePolicy {
- if in == nil {
- return nil
- }
- out := new(ClusterImagePolicy)
- in.DeepCopyInto(out)
- return out
-}
-
-// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
-func (in *ClusterImagePolicy) DeepCopyObject() runtime.Object {
- if c := in.DeepCopy(); c != nil {
- return c
- }
- return nil
-}
-
-// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *ClusterImagePolicyList) DeepCopyInto(out *ClusterImagePolicyList) {
- *out = *in
- out.TypeMeta = in.TypeMeta
- in.ListMeta.DeepCopyInto(&out.ListMeta)
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]ClusterImagePolicy, len(*in))
- for i := range *in {
- (*in)[i].DeepCopyInto(&(*out)[i])
- }
- }
- return
-}
-
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterImagePolicyList.
-func (in *ClusterImagePolicyList) DeepCopy() *ClusterImagePolicyList {
- if in == nil {
- return nil
- }
- out := new(ClusterImagePolicyList)
- in.DeepCopyInto(out)
- return out
-}
-
-// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
-func (in *ClusterImagePolicyList) DeepCopyObject() runtime.Object {
- if c := in.DeepCopy(); c != nil {
- return c
- }
- return nil
-}
-
-// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *ClusterImagePolicySpec) DeepCopyInto(out *ClusterImagePolicySpec) {
- *out = *in
- if in.Scopes != nil {
- in, out := &in.Scopes, &out.Scopes
- *out = make([]ImageScope, len(*in))
- copy(*out, *in)
- }
- in.Policy.DeepCopyInto(&out.Policy)
- return
-}
-
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterImagePolicySpec.
-func (in *ClusterImagePolicySpec) DeepCopy() *ClusterImagePolicySpec {
- if in == nil {
- return nil
- }
- out := new(ClusterImagePolicySpec)
- in.DeepCopyInto(out)
- return out
-}
-
-// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *ClusterImagePolicyStatus) DeepCopyInto(out *ClusterImagePolicyStatus) {
- *out = *in
- if in.Conditions != nil {
- in, out := &in.Conditions, &out.Conditions
- *out = make([]metav1.Condition, len(*in))
- for i := range *in {
- (*in)[i].DeepCopyInto(&(*out)[i])
- }
- }
- return
-}
-
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterImagePolicyStatus.
-func (in *ClusterImagePolicyStatus) DeepCopy() *ClusterImagePolicyStatus {
- if in == nil {
- return nil
- }
- out := new(ClusterImagePolicyStatus)
- in.DeepCopyInto(out)
- return out
-}
-
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *ClusterMonitoring) DeepCopyInto(out *ClusterMonitoring) {
*out = *in
@@ -490,9 +442,16 @@ func (in *ClusterMonitoringSpec) DeepCopyInto(out *ClusterMonitoringSpec) {
*out = *in
out.UserDefined = in.UserDefined
in.AlertmanagerConfig.DeepCopyInto(&out.AlertmanagerConfig)
+ in.PrometheusConfig.DeepCopyInto(&out.PrometheusConfig)
in.MetricsServerConfig.DeepCopyInto(&out.MetricsServerConfig)
in.PrometheusOperatorConfig.DeepCopyInto(&out.PrometheusOperatorConfig)
in.PrometheusOperatorAdmissionWebhookConfig.DeepCopyInto(&out.PrometheusOperatorAdmissionWebhookConfig)
+ in.OpenShiftStateMetricsConfig.DeepCopyInto(&out.OpenShiftStateMetricsConfig)
+ in.TelemeterClientConfig.DeepCopyInto(&out.TelemeterClientConfig)
+ in.ThanosQuerierConfig.DeepCopyInto(&out.ThanosQuerierConfig)
+ in.NodeExporterConfig.DeepCopyInto(&out.NodeExporterConfig)
+ in.MonitoringPluginConfig.DeepCopyInto(&out.MonitoringPluginConfig)
+ in.KubeStateMetricsConfig.DeepCopyInto(&out.KubeStateMetricsConfig)
return
}
@@ -574,6 +533,22 @@ func (in *DefaultCertificateConfig) DeepCopy() *DefaultCertificateConfig {
return out
}
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *DropEqualActionConfig) DeepCopyInto(out *DropEqualActionConfig) {
+ *out = *in
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DropEqualActionConfig.
+func (in *DropEqualActionConfig) DeepCopy() *DropEqualActionConfig {
+ if in == nil {
+ return nil
+ }
+ out := new(DropEqualActionConfig)
+ in.DeepCopyInto(out)
+ return out
+}
+
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *ECDSAKeyConfig) DeepCopyInto(out *ECDSAKeyConfig) {
*out = *in
@@ -634,68 +609,57 @@ func (in *GatherConfig) DeepCopy() *GatherConfig {
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *ImagePolicy) DeepCopyInto(out *ImagePolicy) {
+func (in *HashModActionConfig) DeepCopyInto(out *HashModActionConfig) {
*out = *in
- out.TypeMeta = in.TypeMeta
- in.ObjectMeta.DeepCopyInto(&out.ObjectMeta)
- in.Spec.DeepCopyInto(&out.Spec)
- in.Status.DeepCopyInto(&out.Status)
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ImagePolicy.
-func (in *ImagePolicy) DeepCopy() *ImagePolicy {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HashModActionConfig.
+func (in *HashModActionConfig) DeepCopy() *HashModActionConfig {
if in == nil {
return nil
}
- out := new(ImagePolicy)
+ out := new(HashModActionConfig)
in.DeepCopyInto(out)
return out
}
-// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
-func (in *ImagePolicy) DeepCopyObject() runtime.Object {
- if c := in.DeepCopy(); c != nil {
- return c
- }
- return nil
-}
-
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *ImagePolicyFulcioCAWithRekorRootOfTrust) DeepCopyInto(out *ImagePolicyFulcioCAWithRekorRootOfTrust) {
+func (in *InsightsDataGather) DeepCopyInto(out *InsightsDataGather) {
*out = *in
- if in.FulcioCAData != nil {
- in, out := &in.FulcioCAData, &out.FulcioCAData
- *out = make([]byte, len(*in))
- copy(*out, *in)
- }
- if in.RekorKeyData != nil {
- in, out := &in.RekorKeyData, &out.RekorKeyData
- *out = make([]byte, len(*in))
- copy(*out, *in)
- }
- out.FulcioSubject = in.FulcioSubject
+ out.TypeMeta = in.TypeMeta
+ in.ObjectMeta.DeepCopyInto(&out.ObjectMeta)
+ in.Spec.DeepCopyInto(&out.Spec)
+ out.Status = in.Status
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ImagePolicyFulcioCAWithRekorRootOfTrust.
-func (in *ImagePolicyFulcioCAWithRekorRootOfTrust) DeepCopy() *ImagePolicyFulcioCAWithRekorRootOfTrust {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new InsightsDataGather.
+func (in *InsightsDataGather) DeepCopy() *InsightsDataGather {
if in == nil {
return nil
}
- out := new(ImagePolicyFulcioCAWithRekorRootOfTrust)
+ out := new(InsightsDataGather)
in.DeepCopyInto(out)
return out
}
+// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
+func (in *InsightsDataGather) DeepCopyObject() runtime.Object {
+ if c := in.DeepCopy(); c != nil {
+ return c
+ }
+ return nil
+}
+
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *ImagePolicyList) DeepCopyInto(out *ImagePolicyList) {
+func (in *InsightsDataGatherList) DeepCopyInto(out *InsightsDataGatherList) {
*out = *in
out.TypeMeta = in.TypeMeta
in.ListMeta.DeepCopyInto(&out.ListMeta)
if in.Items != nil {
in, out := &in.Items, &out.Items
- *out = make([]ImagePolicy, len(*in))
+ *out = make([]InsightsDataGather, len(*in))
for i := range *in {
(*in)[i].DeepCopyInto(&(*out)[i])
}
@@ -703,18 +667,18 @@ func (in *ImagePolicyList) DeepCopyInto(out *ImagePolicyList) {
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ImagePolicyList.
-func (in *ImagePolicyList) DeepCopy() *ImagePolicyList {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new InsightsDataGatherList.
+func (in *InsightsDataGatherList) DeepCopy() *InsightsDataGatherList {
if in == nil {
return nil
}
- out := new(ImagePolicyList)
+ out := new(InsightsDataGatherList)
in.DeepCopyInto(out)
return out
}
// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
-func (in *ImagePolicyList) DeepCopyObject() runtime.Object {
+func (in *InsightsDataGatherList) DeepCopyObject() runtime.Object {
if c := in.DeepCopy(); c != nil {
return c
}
@@ -722,86 +686,106 @@ func (in *ImagePolicyList) DeepCopyObject() runtime.Object {
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *ImagePolicyPKIRootOfTrust) DeepCopyInto(out *ImagePolicyPKIRootOfTrust) {
+func (in *InsightsDataGatherSpec) DeepCopyInto(out *InsightsDataGatherSpec) {
*out = *in
- if in.CertificateAuthorityRootsData != nil {
- in, out := &in.CertificateAuthorityRootsData, &out.CertificateAuthorityRootsData
- *out = make([]byte, len(*in))
- copy(*out, *in)
- }
- if in.CertificateAuthorityIntermediatesData != nil {
- in, out := &in.CertificateAuthorityIntermediatesData, &out.CertificateAuthorityIntermediatesData
- *out = make([]byte, len(*in))
- copy(*out, *in)
- }
- out.PKICertificateSubject = in.PKICertificateSubject
+ in.GatherConfig.DeepCopyInto(&out.GatherConfig)
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ImagePolicyPKIRootOfTrust.
-func (in *ImagePolicyPKIRootOfTrust) DeepCopy() *ImagePolicyPKIRootOfTrust {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new InsightsDataGatherSpec.
+func (in *InsightsDataGatherSpec) DeepCopy() *InsightsDataGatherSpec {
if in == nil {
return nil
}
- out := new(ImagePolicyPKIRootOfTrust)
+ out := new(InsightsDataGatherSpec)
in.DeepCopyInto(out)
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *ImagePolicyPublicKeyRootOfTrust) DeepCopyInto(out *ImagePolicyPublicKeyRootOfTrust) {
+func (in *InsightsDataGatherStatus) DeepCopyInto(out *InsightsDataGatherStatus) {
*out = *in
- if in.KeyData != nil {
- in, out := &in.KeyData, &out.KeyData
- *out = make([]byte, len(*in))
- copy(*out, *in)
- }
- if in.RekorKeyData != nil {
- in, out := &in.RekorKeyData, &out.RekorKeyData
- *out = make([]byte, len(*in))
- copy(*out, *in)
- }
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ImagePolicyPublicKeyRootOfTrust.
-func (in *ImagePolicyPublicKeyRootOfTrust) DeepCopy() *ImagePolicyPublicKeyRootOfTrust {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new InsightsDataGatherStatus.
+func (in *InsightsDataGatherStatus) DeepCopy() *InsightsDataGatherStatus {
if in == nil {
return nil
}
- out := new(ImagePolicyPublicKeyRootOfTrust)
+ out := new(InsightsDataGatherStatus)
in.DeepCopyInto(out)
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *ImagePolicySpec) DeepCopyInto(out *ImagePolicySpec) {
+func (in *KeepEqualActionConfig) DeepCopyInto(out *KeepEqualActionConfig) {
*out = *in
- if in.Scopes != nil {
- in, out := &in.Scopes, &out.Scopes
- *out = make([]ImageScope, len(*in))
- copy(*out, *in)
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KeepEqualActionConfig.
+func (in *KeepEqualActionConfig) DeepCopy() *KeepEqualActionConfig {
+ if in == nil {
+ return nil
}
- in.Policy.DeepCopyInto(&out.Policy)
+ out := new(KeepEqualActionConfig)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *KeyConfig) DeepCopyInto(out *KeyConfig) {
+ *out = *in
+ out.RSA = in.RSA
+ out.ECDSA = in.ECDSA
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ImagePolicySpec.
-func (in *ImagePolicySpec) DeepCopy() *ImagePolicySpec {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KeyConfig.
+func (in *KeyConfig) DeepCopy() *KeyConfig {
if in == nil {
return nil
}
- out := new(ImagePolicySpec)
+ out := new(KeyConfig)
in.DeepCopyInto(out)
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *ImagePolicyStatus) DeepCopyInto(out *ImagePolicyStatus) {
+func (in *KubeStateMetricsConfig) DeepCopyInto(out *KubeStateMetricsConfig) {
*out = *in
- if in.Conditions != nil {
- in, out := &in.Conditions, &out.Conditions
- *out = make([]metav1.Condition, len(*in))
+ if in.NodeSelector != nil {
+ in, out := &in.NodeSelector, &out.NodeSelector
+ *out = make(map[string]string, len(*in))
+ for key, val := range *in {
+ (*out)[key] = val
+ }
+ }
+ if in.Resources != nil {
+ in, out := &in.Resources, &out.Resources
+ *out = make([]ContainerResource, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ if in.Tolerations != nil {
+ in, out := &in.Tolerations, &out.Tolerations
+ *out = make([]v1.Toleration, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ if in.TopologySpreadConstraints != nil {
+ in, out := &in.TopologySpreadConstraints, &out.TopologySpreadConstraints
+ *out = make([]v1.TopologySpreadConstraint, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ if in.AdditionalResourceLabels != nil {
+ in, out := &in.AdditionalResourceLabels, &out.AdditionalResourceLabels
+ *out = make([]KubeStateMetricsResourceLabels, len(*in))
for i := range *in {
(*in)[i].DeepCopyInto(&(*out)[i])
}
@@ -809,142 +793,114 @@ func (in *ImagePolicyStatus) DeepCopyInto(out *ImagePolicyStatus) {
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ImagePolicyStatus.
-func (in *ImagePolicyStatus) DeepCopy() *ImagePolicyStatus {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KubeStateMetricsConfig.
+func (in *KubeStateMetricsConfig) DeepCopy() *KubeStateMetricsConfig {
if in == nil {
return nil
}
- out := new(ImagePolicyStatus)
+ out := new(KubeStateMetricsConfig)
in.DeepCopyInto(out)
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *ImageSigstoreVerificationPolicy) DeepCopyInto(out *ImageSigstoreVerificationPolicy) {
+func (in *KubeStateMetricsResourceLabels) DeepCopyInto(out *KubeStateMetricsResourceLabels) {
*out = *in
- in.RootOfTrust.DeepCopyInto(&out.RootOfTrust)
- in.SignedIdentity.DeepCopyInto(&out.SignedIdentity)
+ if in.Labels != nil {
+ in, out := &in.Labels, &out.Labels
+ *out = make([]KubeStateMetricsLabelName, len(*in))
+ copy(*out, *in)
+ }
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ImageSigstoreVerificationPolicy.
-func (in *ImageSigstoreVerificationPolicy) DeepCopy() *ImageSigstoreVerificationPolicy {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KubeStateMetricsResourceLabels.
+func (in *KubeStateMetricsResourceLabels) DeepCopy() *KubeStateMetricsResourceLabels {
if in == nil {
return nil
}
- out := new(ImageSigstoreVerificationPolicy)
+ out := new(KubeStateMetricsResourceLabels)
in.DeepCopyInto(out)
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *InsightsDataGather) DeepCopyInto(out *InsightsDataGather) {
+func (in *Label) DeepCopyInto(out *Label) {
*out = *in
- out.TypeMeta = in.TypeMeta
- in.ObjectMeta.DeepCopyInto(&out.ObjectMeta)
- in.Spec.DeepCopyInto(&out.Spec)
- out.Status = in.Status
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new InsightsDataGather.
-func (in *InsightsDataGather) DeepCopy() *InsightsDataGather {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Label.
+func (in *Label) DeepCopy() *Label {
if in == nil {
return nil
}
- out := new(InsightsDataGather)
+ out := new(Label)
in.DeepCopyInto(out)
return out
}
-// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
-func (in *InsightsDataGather) DeepCopyObject() runtime.Object {
- if c := in.DeepCopy(); c != nil {
- return c
- }
- return nil
-}
-
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *InsightsDataGatherList) DeepCopyInto(out *InsightsDataGatherList) {
+func (in *LabelMapActionConfig) DeepCopyInto(out *LabelMapActionConfig) {
*out = *in
- out.TypeMeta = in.TypeMeta
- in.ListMeta.DeepCopyInto(&out.ListMeta)
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]InsightsDataGather, len(*in))
- for i := range *in {
- (*in)[i].DeepCopyInto(&(*out)[i])
- }
- }
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new InsightsDataGatherList.
-func (in *InsightsDataGatherList) DeepCopy() *InsightsDataGatherList {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LabelMapActionConfig.
+func (in *LabelMapActionConfig) DeepCopy() *LabelMapActionConfig {
if in == nil {
return nil
}
- out := new(InsightsDataGatherList)
+ out := new(LabelMapActionConfig)
in.DeepCopyInto(out)
return out
}
-// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
-func (in *InsightsDataGatherList) DeepCopyObject() runtime.Object {
- if c := in.DeepCopy(); c != nil {
- return c
- }
- return nil
-}
-
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *InsightsDataGatherSpec) DeepCopyInto(out *InsightsDataGatherSpec) {
+func (in *LowercaseActionConfig) DeepCopyInto(out *LowercaseActionConfig) {
*out = *in
- in.GatherConfig.DeepCopyInto(&out.GatherConfig)
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new InsightsDataGatherSpec.
-func (in *InsightsDataGatherSpec) DeepCopy() *InsightsDataGatherSpec {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LowercaseActionConfig.
+func (in *LowercaseActionConfig) DeepCopy() *LowercaseActionConfig {
if in == nil {
return nil
}
- out := new(InsightsDataGatherSpec)
+ out := new(LowercaseActionConfig)
in.DeepCopyInto(out)
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *InsightsDataGatherStatus) DeepCopyInto(out *InsightsDataGatherStatus) {
+func (in *MetadataConfig) DeepCopyInto(out *MetadataConfig) {
*out = *in
+ out.Custom = in.Custom
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new InsightsDataGatherStatus.
-func (in *InsightsDataGatherStatus) DeepCopy() *InsightsDataGatherStatus {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MetadataConfig.
+func (in *MetadataConfig) DeepCopy() *MetadataConfig {
if in == nil {
return nil
}
- out := new(InsightsDataGatherStatus)
+ out := new(MetadataConfig)
in.DeepCopyInto(out)
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *KeyConfig) DeepCopyInto(out *KeyConfig) {
+func (in *MetadataConfigCustom) DeepCopyInto(out *MetadataConfigCustom) {
*out = *in
- out.RSA = in.RSA
- out.ECDSA = in.ECDSA
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KeyConfig.
-func (in *KeyConfig) DeepCopy() *KeyConfig {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MetadataConfigCustom.
+func (in *MetadataConfigCustom) DeepCopy() *MetadataConfigCustom {
if in == nil {
return nil
}
- out := new(KeyConfig)
+ out := new(MetadataConfigCustom)
in.DeepCopyInto(out)
return out
}
@@ -995,438 +951,1237 @@ func (in *MetricsServerConfig) DeepCopy() *MetricsServerConfig {
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *PKI) DeepCopyInto(out *PKI) {
+func (in *MonitoringPluginConfig) DeepCopyInto(out *MonitoringPluginConfig) {
*out = *in
- out.TypeMeta = in.TypeMeta
- in.ObjectMeta.DeepCopyInto(&out.ObjectMeta)
- out.Spec = in.Spec
+ if in.NodeSelector != nil {
+ in, out := &in.NodeSelector, &out.NodeSelector
+ *out = make(map[string]string, len(*in))
+ for key, val := range *in {
+ (*out)[key] = val
+ }
+ }
+ if in.Resources != nil {
+ in, out := &in.Resources, &out.Resources
+ *out = make([]ContainerResource, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ if in.Tolerations != nil {
+ in, out := &in.Tolerations, &out.Tolerations
+ *out = make([]v1.Toleration, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ if in.TopologySpreadConstraints != nil {
+ in, out := &in.TopologySpreadConstraints, &out.TopologySpreadConstraints
+ *out = make([]v1.TopologySpreadConstraint, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PKI.
-func (in *PKI) DeepCopy() *PKI {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MonitoringPluginConfig.
+func (in *MonitoringPluginConfig) DeepCopy() *MonitoringPluginConfig {
if in == nil {
return nil
}
- out := new(PKI)
+ out := new(MonitoringPluginConfig)
in.DeepCopyInto(out)
return out
}
-// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
-func (in *PKI) DeepCopyObject() runtime.Object {
- if c := in.DeepCopy(); c != nil {
- return c
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *NodeExporterCollectorBuddyInfoConfig) DeepCopyInto(out *NodeExporterCollectorBuddyInfoConfig) {
+ *out = *in
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeExporterCollectorBuddyInfoConfig.
+func (in *NodeExporterCollectorBuddyInfoConfig) DeepCopy() *NodeExporterCollectorBuddyInfoConfig {
+ if in == nil {
+ return nil
}
- return nil
+ out := new(NodeExporterCollectorBuddyInfoConfig)
+ in.DeepCopyInto(out)
+ return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *PKICertificateManagement) DeepCopyInto(out *PKICertificateManagement) {
+func (in *NodeExporterCollectorConfig) DeepCopyInto(out *NodeExporterCollectorConfig) {
*out = *in
- out.Custom = in.Custom
+ out.CpuFreq = in.CpuFreq
+ out.TcpStat = in.TcpStat
+ out.Ethtool = in.Ethtool
+ out.NetDev = in.NetDev
+ out.NetClass = in.NetClass
+ out.BuddyInfo = in.BuddyInfo
+ out.MountStats = in.MountStats
+ out.Ksmd = in.Ksmd
+ out.Processes = in.Processes
+ in.Systemd.DeepCopyInto(&out.Systemd)
+ out.Softirqs = in.Softirqs
+ out.DeviceMapperMultipath = in.DeviceMapperMultipath
+ out.Zoneinfo = in.Zoneinfo
+ out.NVMExpressSubsystem = in.NVMExpressSubsystem
+ in.Interrupts.DeepCopyInto(&out.Interrupts)
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PKICertificateManagement.
-func (in *PKICertificateManagement) DeepCopy() *PKICertificateManagement {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeExporterCollectorConfig.
+func (in *NodeExporterCollectorConfig) DeepCopy() *NodeExporterCollectorConfig {
if in == nil {
return nil
}
- out := new(PKICertificateManagement)
+ out := new(NodeExporterCollectorConfig)
in.DeepCopyInto(out)
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *PKICertificateSubject) DeepCopyInto(out *PKICertificateSubject) {
+func (in *NodeExporterCollectorCpufreqConfig) DeepCopyInto(out *NodeExporterCollectorCpufreqConfig) {
*out = *in
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PKICertificateSubject.
-func (in *PKICertificateSubject) DeepCopy() *PKICertificateSubject {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeExporterCollectorCpufreqConfig.
+func (in *NodeExporterCollectorCpufreqConfig) DeepCopy() *NodeExporterCollectorCpufreqConfig {
if in == nil {
return nil
}
- out := new(PKICertificateSubject)
+ out := new(NodeExporterCollectorCpufreqConfig)
in.DeepCopyInto(out)
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *PKIList) DeepCopyInto(out *PKIList) {
+func (in *NodeExporterCollectorDeviceMapperMultipathConfig) DeepCopyInto(out *NodeExporterCollectorDeviceMapperMultipathConfig) {
*out = *in
- out.TypeMeta = in.TypeMeta
- in.ListMeta.DeepCopyInto(&out.ListMeta)
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]PKI, len(*in))
- for i := range *in {
- (*in)[i].DeepCopyInto(&(*out)[i])
- }
- }
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PKIList.
-func (in *PKIList) DeepCopy() *PKIList {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeExporterCollectorDeviceMapperMultipathConfig.
+func (in *NodeExporterCollectorDeviceMapperMultipathConfig) DeepCopy() *NodeExporterCollectorDeviceMapperMultipathConfig {
if in == nil {
return nil
}
- out := new(PKIList)
+ out := new(NodeExporterCollectorDeviceMapperMultipathConfig)
in.DeepCopyInto(out)
return out
}
-// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
-func (in *PKIList) DeepCopyObject() runtime.Object {
- if c := in.DeepCopy(); c != nil {
- return c
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *NodeExporterCollectorEthtoolConfig) DeepCopyInto(out *NodeExporterCollectorEthtoolConfig) {
+ *out = *in
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeExporterCollectorEthtoolConfig.
+func (in *NodeExporterCollectorEthtoolConfig) DeepCopy() *NodeExporterCollectorEthtoolConfig {
+ if in == nil {
+ return nil
}
- return nil
+ out := new(NodeExporterCollectorEthtoolConfig)
+ in.DeepCopyInto(out)
+ return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *PKIProfile) DeepCopyInto(out *PKIProfile) {
+func (in *NodeExporterCollectorInterruptsCollectConfig) DeepCopyInto(out *NodeExporterCollectorInterruptsCollectConfig) {
*out = *in
- out.Defaults = in.Defaults
- out.SignerCertificates = in.SignerCertificates
- out.ServingCertificates = in.ServingCertificates
- out.ClientCertificates = in.ClientCertificates
+ if in.Include != nil {
+ in, out := &in.Include, &out.Include
+ *out = make([]NodeExporterInterruptsIncludePattern, len(*in))
+ copy(*out, *in)
+ }
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PKIProfile.
-func (in *PKIProfile) DeepCopy() *PKIProfile {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeExporterCollectorInterruptsCollectConfig.
+func (in *NodeExporterCollectorInterruptsCollectConfig) DeepCopy() *NodeExporterCollectorInterruptsCollectConfig {
if in == nil {
return nil
}
- out := new(PKIProfile)
+ out := new(NodeExporterCollectorInterruptsCollectConfig)
in.DeepCopyInto(out)
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *PKISpec) DeepCopyInto(out *PKISpec) {
+func (in *NodeExporterCollectorInterruptsConfig) DeepCopyInto(out *NodeExporterCollectorInterruptsConfig) {
*out = *in
- out.CertificateManagement = in.CertificateManagement
+ in.Collect.DeepCopyInto(&out.Collect)
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PKISpec.
-func (in *PKISpec) DeepCopy() *PKISpec {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeExporterCollectorInterruptsConfig.
+func (in *NodeExporterCollectorInterruptsConfig) DeepCopy() *NodeExporterCollectorInterruptsConfig {
if in == nil {
return nil
}
- out := new(PKISpec)
+ out := new(NodeExporterCollectorInterruptsConfig)
in.DeepCopyInto(out)
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *PersistentVolumeClaimReference) DeepCopyInto(out *PersistentVolumeClaimReference) {
+func (in *NodeExporterCollectorKSMDConfig) DeepCopyInto(out *NodeExporterCollectorKSMDConfig) {
*out = *in
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PersistentVolumeClaimReference.
-func (in *PersistentVolumeClaimReference) DeepCopy() *PersistentVolumeClaimReference {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeExporterCollectorKSMDConfig.
+func (in *NodeExporterCollectorKSMDConfig) DeepCopy() *NodeExporterCollectorKSMDConfig {
if in == nil {
return nil
}
- out := new(PersistentVolumeClaimReference)
+ out := new(NodeExporterCollectorKSMDConfig)
in.DeepCopyInto(out)
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *PersistentVolumeConfig) DeepCopyInto(out *PersistentVolumeConfig) {
+func (in *NodeExporterCollectorMountStatsConfig) DeepCopyInto(out *NodeExporterCollectorMountStatsConfig) {
*out = *in
- out.Claim = in.Claim
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PersistentVolumeConfig.
-func (in *PersistentVolumeConfig) DeepCopy() *PersistentVolumeConfig {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeExporterCollectorMountStatsConfig.
+func (in *NodeExporterCollectorMountStatsConfig) DeepCopy() *NodeExporterCollectorMountStatsConfig {
if in == nil {
return nil
}
- out := new(PersistentVolumeConfig)
+ out := new(NodeExporterCollectorMountStatsConfig)
in.DeepCopyInto(out)
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *PolicyFulcioSubject) DeepCopyInto(out *PolicyFulcioSubject) {
+func (in *NodeExporterCollectorNVMExpressSubsystemConfig) DeepCopyInto(out *NodeExporterCollectorNVMExpressSubsystemConfig) {
*out = *in
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PolicyFulcioSubject.
-func (in *PolicyFulcioSubject) DeepCopy() *PolicyFulcioSubject {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeExporterCollectorNVMExpressSubsystemConfig.
+func (in *NodeExporterCollectorNVMExpressSubsystemConfig) DeepCopy() *NodeExporterCollectorNVMExpressSubsystemConfig {
if in == nil {
return nil
}
- out := new(PolicyFulcioSubject)
+ out := new(NodeExporterCollectorNVMExpressSubsystemConfig)
in.DeepCopyInto(out)
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *PolicyIdentity) DeepCopyInto(out *PolicyIdentity) {
+func (in *NodeExporterCollectorNetClassCollectConfig) DeepCopyInto(out *NodeExporterCollectorNetClassCollectConfig) {
*out = *in
- if in.PolicyMatchExactRepository != nil {
- in, out := &in.PolicyMatchExactRepository, &out.PolicyMatchExactRepository
- *out = new(PolicyMatchExactRepository)
- **out = **in
- }
- if in.PolicyMatchRemapIdentity != nil {
- in, out := &in.PolicyMatchRemapIdentity, &out.PolicyMatchRemapIdentity
- *out = new(PolicyMatchRemapIdentity)
- **out = **in
- }
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PolicyIdentity.
-func (in *PolicyIdentity) DeepCopy() *PolicyIdentity {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeExporterCollectorNetClassCollectConfig.
+func (in *NodeExporterCollectorNetClassCollectConfig) DeepCopy() *NodeExporterCollectorNetClassCollectConfig {
if in == nil {
return nil
}
- out := new(PolicyIdentity)
+ out := new(NodeExporterCollectorNetClassCollectConfig)
in.DeepCopyInto(out)
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *PolicyMatchExactRepository) DeepCopyInto(out *PolicyMatchExactRepository) {
+func (in *NodeExporterCollectorNetClassConfig) DeepCopyInto(out *NodeExporterCollectorNetClassConfig) {
*out = *in
+ out.Collect = in.Collect
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PolicyMatchExactRepository.
-func (in *PolicyMatchExactRepository) DeepCopy() *PolicyMatchExactRepository {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeExporterCollectorNetClassConfig.
+func (in *NodeExporterCollectorNetClassConfig) DeepCopy() *NodeExporterCollectorNetClassConfig {
if in == nil {
return nil
}
- out := new(PolicyMatchExactRepository)
+ out := new(NodeExporterCollectorNetClassConfig)
in.DeepCopyInto(out)
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *PolicyMatchRemapIdentity) DeepCopyInto(out *PolicyMatchRemapIdentity) {
+func (in *NodeExporterCollectorNetDevConfig) DeepCopyInto(out *NodeExporterCollectorNetDevConfig) {
*out = *in
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PolicyMatchRemapIdentity.
-func (in *PolicyMatchRemapIdentity) DeepCopy() *PolicyMatchRemapIdentity {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeExporterCollectorNetDevConfig.
+func (in *NodeExporterCollectorNetDevConfig) DeepCopy() *NodeExporterCollectorNetDevConfig {
if in == nil {
return nil
}
- out := new(PolicyMatchRemapIdentity)
+ out := new(NodeExporterCollectorNetDevConfig)
in.DeepCopyInto(out)
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *PolicyRootOfTrust) DeepCopyInto(out *PolicyRootOfTrust) {
+func (in *NodeExporterCollectorProcessesConfig) DeepCopyInto(out *NodeExporterCollectorProcessesConfig) {
*out = *in
- if in.PublicKey != nil {
- in, out := &in.PublicKey, &out.PublicKey
- *out = new(ImagePolicyPublicKeyRootOfTrust)
- (*in).DeepCopyInto(*out)
- }
- if in.FulcioCAWithRekor != nil {
- in, out := &in.FulcioCAWithRekor, &out.FulcioCAWithRekor
- *out = new(ImagePolicyFulcioCAWithRekorRootOfTrust)
- (*in).DeepCopyInto(*out)
- }
- if in.PKI != nil {
- in, out := &in.PKI, &out.PKI
- *out = new(ImagePolicyPKIRootOfTrust)
- (*in).DeepCopyInto(*out)
- }
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PolicyRootOfTrust.
-func (in *PolicyRootOfTrust) DeepCopy() *PolicyRootOfTrust {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeExporterCollectorProcessesConfig.
+func (in *NodeExporterCollectorProcessesConfig) DeepCopy() *NodeExporterCollectorProcessesConfig {
if in == nil {
return nil
}
- out := new(PolicyRootOfTrust)
+ out := new(NodeExporterCollectorProcessesConfig)
in.DeepCopyInto(out)
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *PrometheusOperatorAdmissionWebhookConfig) DeepCopyInto(out *PrometheusOperatorAdmissionWebhookConfig) {
+func (in *NodeExporterCollectorSoftirqsConfig) DeepCopyInto(out *NodeExporterCollectorSoftirqsConfig) {
*out = *in
- if in.Resources != nil {
- in, out := &in.Resources, &out.Resources
- *out = make([]ContainerResource, len(*in))
- for i := range *in {
- (*in)[i].DeepCopyInto(&(*out)[i])
- }
- }
- if in.TopologySpreadConstraints != nil {
- in, out := &in.TopologySpreadConstraints, &out.TopologySpreadConstraints
- *out = make([]v1.TopologySpreadConstraint, len(*in))
- for i := range *in {
- (*in)[i].DeepCopyInto(&(*out)[i])
- }
- }
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PrometheusOperatorAdmissionWebhookConfig.
-func (in *PrometheusOperatorAdmissionWebhookConfig) DeepCopy() *PrometheusOperatorAdmissionWebhookConfig {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeExporterCollectorSoftirqsConfig.
+func (in *NodeExporterCollectorSoftirqsConfig) DeepCopy() *NodeExporterCollectorSoftirqsConfig {
if in == nil {
return nil
}
- out := new(PrometheusOperatorAdmissionWebhookConfig)
+ out := new(NodeExporterCollectorSoftirqsConfig)
in.DeepCopyInto(out)
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *PrometheusOperatorConfig) DeepCopyInto(out *PrometheusOperatorConfig) {
+func (in *NodeExporterCollectorSystemdCollectConfig) DeepCopyInto(out *NodeExporterCollectorSystemdCollectConfig) {
*out = *in
- if in.NodeSelector != nil {
- in, out := &in.NodeSelector, &out.NodeSelector
- *out = make(map[string]string, len(*in))
- for key, val := range *in {
- (*out)[key] = val
- }
- }
- if in.Resources != nil {
- in, out := &in.Resources, &out.Resources
- *out = make([]ContainerResource, len(*in))
- for i := range *in {
- (*in)[i].DeepCopyInto(&(*out)[i])
- }
- }
- if in.Tolerations != nil {
- in, out := &in.Tolerations, &out.Tolerations
- *out = make([]v1.Toleration, len(*in))
- for i := range *in {
- (*in)[i].DeepCopyInto(&(*out)[i])
- }
- }
- if in.TopologySpreadConstraints != nil {
- in, out := &in.TopologySpreadConstraints, &out.TopologySpreadConstraints
- *out = make([]v1.TopologySpreadConstraint, len(*in))
- for i := range *in {
- (*in)[i].DeepCopyInto(&(*out)[i])
- }
+ if in.Units != nil {
+ in, out := &in.Units, &out.Units
+ *out = make([]NodeExporterSystemdUnit, len(*in))
+ copy(*out, *in)
}
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PrometheusOperatorConfig.
-func (in *PrometheusOperatorConfig) DeepCopy() *PrometheusOperatorConfig {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeExporterCollectorSystemdCollectConfig.
+func (in *NodeExporterCollectorSystemdCollectConfig) DeepCopy() *NodeExporterCollectorSystemdCollectConfig {
if in == nil {
return nil
}
- out := new(PrometheusOperatorConfig)
+ out := new(NodeExporterCollectorSystemdCollectConfig)
in.DeepCopyInto(out)
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *RSAKeyConfig) DeepCopyInto(out *RSAKeyConfig) {
+func (in *NodeExporterCollectorSystemdConfig) DeepCopyInto(out *NodeExporterCollectorSystemdConfig) {
*out = *in
+ in.Collect.DeepCopyInto(&out.Collect)
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RSAKeyConfig.
-func (in *RSAKeyConfig) DeepCopy() *RSAKeyConfig {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeExporterCollectorSystemdConfig.
+func (in *NodeExporterCollectorSystemdConfig) DeepCopy() *NodeExporterCollectorSystemdConfig {
if in == nil {
return nil
}
- out := new(RSAKeyConfig)
+ out := new(NodeExporterCollectorSystemdConfig)
in.DeepCopyInto(out)
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *RetentionNumberConfig) DeepCopyInto(out *RetentionNumberConfig) {
+func (in *NodeExporterCollectorTcpStatConfig) DeepCopyInto(out *NodeExporterCollectorTcpStatConfig) {
*out = *in
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RetentionNumberConfig.
-func (in *RetentionNumberConfig) DeepCopy() *RetentionNumberConfig {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeExporterCollectorTcpStatConfig.
+func (in *NodeExporterCollectorTcpStatConfig) DeepCopy() *NodeExporterCollectorTcpStatConfig {
if in == nil {
return nil
}
- out := new(RetentionNumberConfig)
+ out := new(NodeExporterCollectorTcpStatConfig)
in.DeepCopyInto(out)
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *RetentionPolicy) DeepCopyInto(out *RetentionPolicy) {
+func (in *NodeExporterCollectorZoneinfoConfig) DeepCopyInto(out *NodeExporterCollectorZoneinfoConfig) {
*out = *in
- if in.RetentionNumber != nil {
- in, out := &in.RetentionNumber, &out.RetentionNumber
- *out = new(RetentionNumberConfig)
- **out = **in
- }
- if in.RetentionSize != nil {
- in, out := &in.RetentionSize, &out.RetentionSize
- *out = new(RetentionSizeConfig)
- **out = **in
- }
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RetentionPolicy.
-func (in *RetentionPolicy) DeepCopy() *RetentionPolicy {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeExporterCollectorZoneinfoConfig.
+func (in *NodeExporterCollectorZoneinfoConfig) DeepCopy() *NodeExporterCollectorZoneinfoConfig {
if in == nil {
return nil
}
- out := new(RetentionPolicy)
+ out := new(NodeExporterCollectorZoneinfoConfig)
in.DeepCopyInto(out)
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *RetentionSizeConfig) DeepCopyInto(out *RetentionSizeConfig) {
+func (in *NodeExporterConfig) DeepCopyInto(out *NodeExporterConfig) {
*out = *in
+ if in.Resources != nil {
+ in, out := &in.Resources, &out.Resources
+ *out = make([]ContainerResource, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ in.Collectors.DeepCopyInto(&out.Collectors)
+ if in.IgnoredNetworkDevices != nil {
+ in, out := &in.IgnoredNetworkDevices, &out.IgnoredNetworkDevices
+ *out = new([]NodeExporterIgnoredNetworkDevice)
+ if **in != nil {
+ in, out := *in, *out
+ *out = make([]NodeExporterIgnoredNetworkDevice, len(*in))
+ copy(*out, *in)
+ }
+ }
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RetentionSizeConfig.
-func (in *RetentionSizeConfig) DeepCopy() *RetentionSizeConfig {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeExporterConfig.
+func (in *NodeExporterConfig) DeepCopy() *NodeExporterConfig {
if in == nil {
return nil
}
- out := new(RetentionSizeConfig)
+ out := new(NodeExporterConfig)
in.DeepCopyInto(out)
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
-func (in *Storage) DeepCopyInto(out *Storage) {
+func (in *OAuth2) DeepCopyInto(out *OAuth2) {
*out = *in
- if in.PersistentVolume != nil {
- in, out := &in.PersistentVolume, &out.PersistentVolume
- *out = new(PersistentVolumeConfig)
- **out = **in
+ out.ClientID = in.ClientID
+ out.ClientSecret = in.ClientSecret
+ if in.Scopes != nil {
+ in, out := &in.Scopes, &out.Scopes
+ *out = make([]string, len(*in))
+ copy(*out, *in)
+ }
+ if in.EndpointParams != nil {
+ in, out := &in.EndpointParams, &out.EndpointParams
+ *out = make([]OAuth2EndpointParam, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
}
return
}
-// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Storage.
-func (in *Storage) DeepCopy() *Storage {
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OAuth2.
+func (in *OAuth2) DeepCopy() *OAuth2 {
if in == nil {
return nil
}
- out := new(Storage)
+ out := new(OAuth2)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *OAuth2EndpointParam) DeepCopyInto(out *OAuth2EndpointParam) {
+ *out = *in
+ if in.Value != nil {
+ in, out := &in.Value, &out.Value
+ *out = new(string)
+ **out = **in
+ }
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OAuth2EndpointParam.
+func (in *OAuth2EndpointParam) DeepCopy() *OAuth2EndpointParam {
+ if in == nil {
+ return nil
+ }
+ out := new(OAuth2EndpointParam)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *OpenShiftStateMetricsConfig) DeepCopyInto(out *OpenShiftStateMetricsConfig) {
+ *out = *in
+ if in.NodeSelector != nil {
+ in, out := &in.NodeSelector, &out.NodeSelector
+ *out = make(map[string]string, len(*in))
+ for key, val := range *in {
+ (*out)[key] = val
+ }
+ }
+ if in.Resources != nil {
+ in, out := &in.Resources, &out.Resources
+ *out = make([]ContainerResource, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ if in.Tolerations != nil {
+ in, out := &in.Tolerations, &out.Tolerations
+ *out = make([]v1.Toleration, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ if in.TopologySpreadConstraints != nil {
+ in, out := &in.TopologySpreadConstraints, &out.TopologySpreadConstraints
+ *out = make([]v1.TopologySpreadConstraint, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OpenShiftStateMetricsConfig.
+func (in *OpenShiftStateMetricsConfig) DeepCopy() *OpenShiftStateMetricsConfig {
+ if in == nil {
+ return nil
+ }
+ out := new(OpenShiftStateMetricsConfig)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *PKI) DeepCopyInto(out *PKI) {
+ *out = *in
+ out.TypeMeta = in.TypeMeta
+ in.ObjectMeta.DeepCopyInto(&out.ObjectMeta)
+ out.Spec = in.Spec
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PKI.
+func (in *PKI) DeepCopy() *PKI {
+ if in == nil {
+ return nil
+ }
+ out := new(PKI)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
+func (in *PKI) DeepCopyObject() runtime.Object {
+ if c := in.DeepCopy(); c != nil {
+ return c
+ }
+ return nil
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *PKICertificateManagement) DeepCopyInto(out *PKICertificateManagement) {
+ *out = *in
+ out.Custom = in.Custom
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PKICertificateManagement.
+func (in *PKICertificateManagement) DeepCopy() *PKICertificateManagement {
+ if in == nil {
+ return nil
+ }
+ out := new(PKICertificateManagement)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *PKIList) DeepCopyInto(out *PKIList) {
+ *out = *in
+ out.TypeMeta = in.TypeMeta
+ in.ListMeta.DeepCopyInto(&out.ListMeta)
+ if in.Items != nil {
+ in, out := &in.Items, &out.Items
+ *out = make([]PKI, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PKIList.
+func (in *PKIList) DeepCopy() *PKIList {
+ if in == nil {
+ return nil
+ }
+ out := new(PKIList)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
+func (in *PKIList) DeepCopyObject() runtime.Object {
+ if c := in.DeepCopy(); c != nil {
+ return c
+ }
+ return nil
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *PKIProfile) DeepCopyInto(out *PKIProfile) {
+ *out = *in
+ out.Defaults = in.Defaults
+ out.SignerCertificates = in.SignerCertificates
+ out.ServingCertificates = in.ServingCertificates
+ out.ClientCertificates = in.ClientCertificates
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PKIProfile.
+func (in *PKIProfile) DeepCopy() *PKIProfile {
+ if in == nil {
+ return nil
+ }
+ out := new(PKIProfile)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *PKISpec) DeepCopyInto(out *PKISpec) {
+ *out = *in
+ out.CertificateManagement = in.CertificateManagement
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PKISpec.
+func (in *PKISpec) DeepCopy() *PKISpec {
+ if in == nil {
+ return nil
+ }
+ out := new(PKISpec)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *PersistentVolumeClaimReference) DeepCopyInto(out *PersistentVolumeClaimReference) {
+ *out = *in
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PersistentVolumeClaimReference.
+func (in *PersistentVolumeClaimReference) DeepCopy() *PersistentVolumeClaimReference {
+ if in == nil {
+ return nil
+ }
+ out := new(PersistentVolumeClaimReference)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *PersistentVolumeConfig) DeepCopyInto(out *PersistentVolumeConfig) {
+ *out = *in
+ out.Claim = in.Claim
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PersistentVolumeConfig.
+func (in *PersistentVolumeConfig) DeepCopy() *PersistentVolumeConfig {
+ if in == nil {
+ return nil
+ }
+ out := new(PersistentVolumeConfig)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *PrometheusConfig) DeepCopyInto(out *PrometheusConfig) {
+ *out = *in
+ if in.AdditionalAlertmanagerConfigs != nil {
+ in, out := &in.AdditionalAlertmanagerConfigs, &out.AdditionalAlertmanagerConfigs
+ *out = make([]AdditionalAlertmanagerConfig, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ if in.ExternalLabels != nil {
+ in, out := &in.ExternalLabels, &out.ExternalLabels
+ *out = make([]Label, len(*in))
+ copy(*out, *in)
+ }
+ if in.NodeSelector != nil {
+ in, out := &in.NodeSelector, &out.NodeSelector
+ *out = make(map[string]string, len(*in))
+ for key, val := range *in {
+ (*out)[key] = val
+ }
+ }
+ if in.RemoteWrite != nil {
+ in, out := &in.RemoteWrite, &out.RemoteWrite
+ *out = make([]RemoteWriteSpec, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ if in.Resources != nil {
+ in, out := &in.Resources, &out.Resources
+ *out = make([]ContainerResource, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ out.Retention = in.Retention
+ if in.Tolerations != nil {
+ in, out := &in.Tolerations, &out.Tolerations
+ *out = make([]v1.Toleration, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ if in.TopologySpreadConstraints != nil {
+ in, out := &in.TopologySpreadConstraints, &out.TopologySpreadConstraints
+ *out = make([]v1.TopologySpreadConstraint, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ if in.VolumeClaimTemplate != nil {
+ in, out := &in.VolumeClaimTemplate, &out.VolumeClaimTemplate
+ *out = new(v1.PersistentVolumeClaim)
+ (*in).DeepCopyInto(*out)
+ }
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PrometheusConfig.
+func (in *PrometheusConfig) DeepCopy() *PrometheusConfig {
+ if in == nil {
+ return nil
+ }
+ out := new(PrometheusConfig)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *PrometheusOperatorAdmissionWebhookConfig) DeepCopyInto(out *PrometheusOperatorAdmissionWebhookConfig) {
+ *out = *in
+ if in.Resources != nil {
+ in, out := &in.Resources, &out.Resources
+ *out = make([]ContainerResource, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ if in.TopologySpreadConstraints != nil {
+ in, out := &in.TopologySpreadConstraints, &out.TopologySpreadConstraints
+ *out = make([]v1.TopologySpreadConstraint, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PrometheusOperatorAdmissionWebhookConfig.
+func (in *PrometheusOperatorAdmissionWebhookConfig) DeepCopy() *PrometheusOperatorAdmissionWebhookConfig {
+ if in == nil {
+ return nil
+ }
+ out := new(PrometheusOperatorAdmissionWebhookConfig)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *PrometheusOperatorConfig) DeepCopyInto(out *PrometheusOperatorConfig) {
+ *out = *in
+ if in.NodeSelector != nil {
+ in, out := &in.NodeSelector, &out.NodeSelector
+ *out = make(map[string]string, len(*in))
+ for key, val := range *in {
+ (*out)[key] = val
+ }
+ }
+ if in.Resources != nil {
+ in, out := &in.Resources, &out.Resources
+ *out = make([]ContainerResource, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ if in.Tolerations != nil {
+ in, out := &in.Tolerations, &out.Tolerations
+ *out = make([]v1.Toleration, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ if in.TopologySpreadConstraints != nil {
+ in, out := &in.TopologySpreadConstraints, &out.TopologySpreadConstraints
+ *out = make([]v1.TopologySpreadConstraint, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PrometheusOperatorConfig.
+func (in *PrometheusOperatorConfig) DeepCopy() *PrometheusOperatorConfig {
+ if in == nil {
+ return nil
+ }
+ out := new(PrometheusOperatorConfig)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *PrometheusRemoteWriteHeader) DeepCopyInto(out *PrometheusRemoteWriteHeader) {
+ *out = *in
+ if in.Value != nil {
+ in, out := &in.Value, &out.Value
+ *out = new(string)
+ **out = **in
+ }
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PrometheusRemoteWriteHeader.
+func (in *PrometheusRemoteWriteHeader) DeepCopy() *PrometheusRemoteWriteHeader {
+ if in == nil {
+ return nil
+ }
+ out := new(PrometheusRemoteWriteHeader)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *QueueConfig) DeepCopyInto(out *QueueConfig) {
+ *out = *in
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new QueueConfig.
+func (in *QueueConfig) DeepCopy() *QueueConfig {
+ if in == nil {
+ return nil
+ }
+ out := new(QueueConfig)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *RSAKeyConfig) DeepCopyInto(out *RSAKeyConfig) {
+ *out = *in
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RSAKeyConfig.
+func (in *RSAKeyConfig) DeepCopy() *RSAKeyConfig {
+ if in == nil {
+ return nil
+ }
+ out := new(RSAKeyConfig)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *RelabelActionConfig) DeepCopyInto(out *RelabelActionConfig) {
+ *out = *in
+ in.Replace.DeepCopyInto(&out.Replace)
+ out.HashMod = in.HashMod
+ out.LabelMap = in.LabelMap
+ out.Lowercase = in.Lowercase
+ out.Uppercase = in.Uppercase
+ out.KeepEqual = in.KeepEqual
+ out.DropEqual = in.DropEqual
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RelabelActionConfig.
+func (in *RelabelActionConfig) DeepCopy() *RelabelActionConfig {
+ if in == nil {
+ return nil
+ }
+ out := new(RelabelActionConfig)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *RelabelConfig) DeepCopyInto(out *RelabelConfig) {
+ *out = *in
+ if in.SourceLabels != nil {
+ in, out := &in.SourceLabels, &out.SourceLabels
+ *out = make([]string, len(*in))
+ copy(*out, *in)
+ }
+ in.Action.DeepCopyInto(&out.Action)
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RelabelConfig.
+func (in *RelabelConfig) DeepCopy() *RelabelConfig {
+ if in == nil {
+ return nil
+ }
+ out := new(RelabelConfig)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *RemoteWriteAuthorization) DeepCopyInto(out *RemoteWriteAuthorization) {
+ *out = *in
+ out.Authorization = in.Authorization
+ out.BasicAuth = in.BasicAuth
+ in.OAuth2.DeepCopyInto(&out.OAuth2)
+ out.Sigv4 = in.Sigv4
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RemoteWriteAuthorization.
+func (in *RemoteWriteAuthorization) DeepCopy() *RemoteWriteAuthorization {
+ if in == nil {
+ return nil
+ }
+ out := new(RemoteWriteAuthorization)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *RemoteWriteSpec) DeepCopyInto(out *RemoteWriteSpec) {
+ *out = *in
+ in.AuthorizationConfig.DeepCopyInto(&out.AuthorizationConfig)
+ if in.Headers != nil {
+ in, out := &in.Headers, &out.Headers
+ *out = make([]PrometheusRemoteWriteHeader, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ out.MetadataConfig = in.MetadataConfig
+ out.QueueConfig = in.QueueConfig
+ out.TLSConfig = in.TLSConfig
+ if in.WriteRelabelConfigs != nil {
+ in, out := &in.WriteRelabelConfigs, &out.WriteRelabelConfigs
+ *out = make([]RelabelConfig, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RemoteWriteSpec.
+func (in *RemoteWriteSpec) DeepCopy() *RemoteWriteSpec {
+ if in == nil {
+ return nil
+ }
+ out := new(RemoteWriteSpec)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *ReplaceActionConfig) DeepCopyInto(out *ReplaceActionConfig) {
+ *out = *in
+ if in.Replacement != nil {
+ in, out := &in.Replacement, &out.Replacement
+ *out = new(string)
+ **out = **in
+ }
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ReplaceActionConfig.
+func (in *ReplaceActionConfig) DeepCopy() *ReplaceActionConfig {
+ if in == nil {
+ return nil
+ }
+ out := new(ReplaceActionConfig)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *Retention) DeepCopyInto(out *Retention) {
+ *out = *in
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Retention.
+func (in *Retention) DeepCopy() *Retention {
+ if in == nil {
+ return nil
+ }
+ out := new(Retention)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *RetentionNumberConfig) DeepCopyInto(out *RetentionNumberConfig) {
+ *out = *in
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RetentionNumberConfig.
+func (in *RetentionNumberConfig) DeepCopy() *RetentionNumberConfig {
+ if in == nil {
+ return nil
+ }
+ out := new(RetentionNumberConfig)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *RetentionPolicy) DeepCopyInto(out *RetentionPolicy) {
+ *out = *in
+ if in.RetentionNumber != nil {
+ in, out := &in.RetentionNumber, &out.RetentionNumber
+ *out = new(RetentionNumberConfig)
+ **out = **in
+ }
+ if in.RetentionSize != nil {
+ in, out := &in.RetentionSize, &out.RetentionSize
+ *out = new(RetentionSizeConfig)
+ **out = **in
+ }
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RetentionPolicy.
+func (in *RetentionPolicy) DeepCopy() *RetentionPolicy {
+ if in == nil {
+ return nil
+ }
+ out := new(RetentionPolicy)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *RetentionSizeConfig) DeepCopyInto(out *RetentionSizeConfig) {
+ *out = *in
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RetentionSizeConfig.
+func (in *RetentionSizeConfig) DeepCopy() *RetentionSizeConfig {
+ if in == nil {
+ return nil
+ }
+ out := new(RetentionSizeConfig)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *SecretKeySelector) DeepCopyInto(out *SecretKeySelector) {
+ *out = *in
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SecretKeySelector.
+func (in *SecretKeySelector) DeepCopy() *SecretKeySelector {
+ if in == nil {
+ return nil
+ }
+ out := new(SecretKeySelector)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *Sigv4) DeepCopyInto(out *Sigv4) {
+ *out = *in
+ out.AccessKey = in.AccessKey
+ out.SecretKey = in.SecretKey
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Sigv4.
+func (in *Sigv4) DeepCopy() *Sigv4 {
+ if in == nil {
+ return nil
+ }
+ out := new(Sigv4)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *Storage) DeepCopyInto(out *Storage) {
+ *out = *in
+ if in.PersistentVolume != nil {
+ in, out := &in.PersistentVolume, &out.PersistentVolume
+ *out = new(PersistentVolumeConfig)
+ **out = **in
+ }
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Storage.
+func (in *Storage) DeepCopy() *Storage {
+ if in == nil {
+ return nil
+ }
+ out := new(Storage)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *TLSConfig) DeepCopyInto(out *TLSConfig) {
+ *out = *in
+ out.CA = in.CA
+ out.Cert = in.Cert
+ out.Key = in.Key
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TLSConfig.
+func (in *TLSConfig) DeepCopy() *TLSConfig {
+ if in == nil {
+ return nil
+ }
+ out := new(TLSConfig)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *TelemeterClientConfig) DeepCopyInto(out *TelemeterClientConfig) {
+ *out = *in
+ if in.NodeSelector != nil {
+ in, out := &in.NodeSelector, &out.NodeSelector
+ *out = make(map[string]string, len(*in))
+ for key, val := range *in {
+ (*out)[key] = val
+ }
+ }
+ if in.Resources != nil {
+ in, out := &in.Resources, &out.Resources
+ *out = make([]ContainerResource, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ if in.Tolerations != nil {
+ in, out := &in.Tolerations, &out.Tolerations
+ *out = make([]v1.Toleration, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ if in.TopologySpreadConstraints != nil {
+ in, out := &in.TopologySpreadConstraints, &out.TopologySpreadConstraints
+ *out = make([]v1.TopologySpreadConstraint, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TelemeterClientConfig.
+func (in *TelemeterClientConfig) DeepCopy() *TelemeterClientConfig {
+ if in == nil {
+ return nil
+ }
+ out := new(TelemeterClientConfig)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *ThanosQuerierConfig) DeepCopyInto(out *ThanosQuerierConfig) {
+ *out = *in
+ out.RequestLogging = in.RequestLogging
+ if in.NodeSelector != nil {
+ in, out := &in.NodeSelector, &out.NodeSelector
+ *out = make(map[string]string, len(*in))
+ for key, val := range *in {
+ (*out)[key] = val
+ }
+ }
+ if in.Resources != nil {
+ in, out := &in.Resources, &out.Resources
+ *out = make([]ContainerResource, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ if in.Tolerations != nil {
+ in, out := &in.Tolerations, &out.Tolerations
+ *out = make([]v1.Toleration, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ if in.TopologySpreadConstraints != nil {
+ in, out := &in.TopologySpreadConstraints, &out.TopologySpreadConstraints
+ *out = make([]v1.TopologySpreadConstraint, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ThanosQuerierConfig.
+func (in *ThanosQuerierConfig) DeepCopy() *ThanosQuerierConfig {
+ if in == nil {
+ return nil
+ }
+ out := new(ThanosQuerierConfig)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *ThanosQuerierRequestLoggingConfig) DeepCopyInto(out *ThanosQuerierRequestLoggingConfig) {
+ *out = *in
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ThanosQuerierRequestLoggingConfig.
+func (in *ThanosQuerierRequestLoggingConfig) DeepCopy() *ThanosQuerierRequestLoggingConfig {
+ if in == nil {
+ return nil
+ }
+ out := new(ThanosQuerierRequestLoggingConfig)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *UppercaseActionConfig) DeepCopyInto(out *UppercaseActionConfig) {
+ *out = *in
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new UppercaseActionConfig.
+func (in *UppercaseActionConfig) DeepCopy() *UppercaseActionConfig {
+ if in == nil {
+ return nil
+ }
+ out := new(UppercaseActionConfig)
in.DeepCopyInto(out)
return out
}
diff --git a/vendor/github.com/openshift/api/config/v1alpha1/zz_generated.featuregated-crd-manifests.yaml b/vendor/github.com/openshift/api/config/v1alpha1/zz_generated.featuregated-crd-manifests.yaml
index dc2d249a99..b2a1241937 100644
--- a/vendor/github.com/openshift/api/config/v1alpha1/zz_generated.featuregated-crd-manifests.yaml
+++ b/vendor/github.com/openshift/api/config/v1alpha1/zz_generated.featuregated-crd-manifests.yaml
@@ -44,30 +44,6 @@ criocredentialproviderconfigs.config.openshift.io:
- CRIOCredentialProviderConfig
Version: v1alpha1
-clusterimagepolicies.config.openshift.io:
- Annotations: {}
- ApprovedPRNumber: https://github.com/openshift/api/pull/1457
- CRDName: clusterimagepolicies.config.openshift.io
- Capability: ""
- Category: ""
- FeatureGates:
- - SigstoreImageVerification
- - SigstoreImageVerificationPKI
- FilenameOperatorName: config-operator
- FilenameOperatorOrdering: "01"
- FilenameRunLevel: "0000_10"
- GroupName: config.openshift.io
- HasStatus: true
- KindName: ClusterImagePolicy
- Labels: {}
- PluralName: clusterimagepolicies
- PrinterColumns: []
- Scope: Cluster
- ShortNames: null
- TopLevelFeatureGates:
- - SigstoreImageVerification
- Version: v1alpha1
-
clustermonitorings.config.openshift.io:
Annotations:
description: Cluster Monitoring Operators configuration API
@@ -92,30 +68,6 @@ clustermonitorings.config.openshift.io:
- ClusterMonitoringConfig
Version: v1alpha1
-imagepolicies.config.openshift.io:
- Annotations: {}
- ApprovedPRNumber: https://github.com/openshift/api/pull/1457
- CRDName: imagepolicies.config.openshift.io
- Capability: ""
- Category: ""
- FeatureGates:
- - SigstoreImageVerification
- - SigstoreImageVerificationPKI
- FilenameOperatorName: config-operator
- FilenameOperatorOrdering: "01"
- FilenameRunLevel: "0000_10"
- GroupName: config.openshift.io
- HasStatus: true
- KindName: ImagePolicy
- Labels: {}
- PluralName: imagepolicies
- PrinterColumns: []
- Scope: Namespaced
- ShortNames: null
- TopLevelFeatureGates:
- - SigstoreImageVerification
- Version: v1alpha1
-
insightsdatagathers.config.openshift.io:
Annotations: {}
ApprovedPRNumber: https://github.com/openshift/api/pull/1245
diff --git a/vendor/github.com/openshift/api/config/v1alpha1/zz_generated.model_name.go b/vendor/github.com/openshift/api/config/v1alpha1/zz_generated.model_name.go
new file mode 100644
index 0000000000..8159016737
--- /dev/null
+++ b/vendor/github.com/openshift/api/config/v1alpha1/zz_generated.model_name.go
@@ -0,0 +1,486 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1alpha1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AdditionalAlertmanagerConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.AdditionalAlertmanagerConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AlertmanagerConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.AlertmanagerConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AlertmanagerCustomConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.AlertmanagerCustomConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Audit) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.Audit"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AuthorizationConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.AuthorizationConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Backup) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.Backup"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BackupList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.BackupList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BackupSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.BackupSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BackupStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.BackupStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BasicAuth) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.BasicAuth"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CRIOCredentialProviderConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.CRIOCredentialProviderConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CRIOCredentialProviderConfigList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.CRIOCredentialProviderConfigList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CRIOCredentialProviderConfigSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.CRIOCredentialProviderConfigSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CRIOCredentialProviderConfigStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.CRIOCredentialProviderConfigStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CertificateConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.CertificateConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterMonitoring) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.ClusterMonitoring"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterMonitoringList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.ClusterMonitoringList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterMonitoringSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.ClusterMonitoringSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterMonitoringStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.ClusterMonitoringStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ContainerResource) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.ContainerResource"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CustomPKIPolicy) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.CustomPKIPolicy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DefaultCertificateConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.DefaultCertificateConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DropEqualActionConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.DropEqualActionConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ECDSAKeyConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.ECDSAKeyConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EtcdBackupSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.EtcdBackupSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GatherConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.GatherConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in HashModActionConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.HashModActionConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in InsightsDataGather) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.InsightsDataGather"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in InsightsDataGatherList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.InsightsDataGatherList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in InsightsDataGatherSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.InsightsDataGatherSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in InsightsDataGatherStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.InsightsDataGatherStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KeepEqualActionConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.KeepEqualActionConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KeyConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.KeyConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KubeStateMetricsConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.KubeStateMetricsConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KubeStateMetricsResourceLabels) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.KubeStateMetricsResourceLabels"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Label) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.Label"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in LabelMapActionConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.LabelMapActionConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in LowercaseActionConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.LowercaseActionConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MetadataConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.MetadataConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MetadataConfigCustom) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.MetadataConfigCustom"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MetricsServerConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.MetricsServerConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MonitoringPluginConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.MonitoringPluginConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeExporterCollectorBuddyInfoConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.NodeExporterCollectorBuddyInfoConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeExporterCollectorConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.NodeExporterCollectorConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeExporterCollectorCpufreqConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.NodeExporterCollectorCpufreqConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeExporterCollectorDeviceMapperMultipathConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.NodeExporterCollectorDeviceMapperMultipathConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeExporterCollectorEthtoolConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.NodeExporterCollectorEthtoolConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeExporterCollectorInterruptsCollectConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.NodeExporterCollectorInterruptsCollectConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeExporterCollectorInterruptsConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.NodeExporterCollectorInterruptsConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeExporterCollectorKSMDConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.NodeExporterCollectorKSMDConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeExporterCollectorMountStatsConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.NodeExporterCollectorMountStatsConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeExporterCollectorNVMExpressSubsystemConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.NodeExporterCollectorNVMExpressSubsystemConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeExporterCollectorNetClassCollectConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.NodeExporterCollectorNetClassCollectConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeExporterCollectorNetClassConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.NodeExporterCollectorNetClassConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeExporterCollectorNetDevConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.NodeExporterCollectorNetDevConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeExporterCollectorProcessesConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.NodeExporterCollectorProcessesConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeExporterCollectorSoftirqsConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.NodeExporterCollectorSoftirqsConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeExporterCollectorSystemdCollectConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.NodeExporterCollectorSystemdCollectConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeExporterCollectorSystemdConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.NodeExporterCollectorSystemdConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeExporterCollectorTcpStatConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.NodeExporterCollectorTcpStatConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeExporterCollectorZoneinfoConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.NodeExporterCollectorZoneinfoConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeExporterConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.NodeExporterConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OAuth2) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.OAuth2"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OAuth2EndpointParam) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.OAuth2EndpointParam"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OpenShiftStateMetricsConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.OpenShiftStateMetricsConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PKI) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.PKI"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PKICertificateManagement) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.PKICertificateManagement"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PKIList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.PKIList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PKIProfile) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.PKIProfile"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PKISpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.PKISpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PersistentVolumeClaimReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.PersistentVolumeClaimReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PersistentVolumeConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.PersistentVolumeConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PrometheusConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.PrometheusConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PrometheusOperatorAdmissionWebhookConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.PrometheusOperatorAdmissionWebhookConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PrometheusOperatorConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.PrometheusOperatorConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PrometheusRemoteWriteHeader) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.PrometheusRemoteWriteHeader"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in QueueConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.QueueConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RSAKeyConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.RSAKeyConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RelabelActionConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.RelabelActionConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RelabelConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.RelabelConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RemoteWriteAuthorization) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.RemoteWriteAuthorization"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RemoteWriteSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.RemoteWriteSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ReplaceActionConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.ReplaceActionConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Retention) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.Retention"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RetentionNumberConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.RetentionNumberConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RetentionPolicy) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.RetentionPolicy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RetentionSizeConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.RetentionSizeConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SecretKeySelector) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.SecretKeySelector"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Sigv4) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.Sigv4"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Storage) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.Storage"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TLSConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.TLSConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TelemeterClientConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.TelemeterClientConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ThanosQuerierConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.ThanosQuerierConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ThanosQuerierRequestLoggingConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.ThanosQuerierRequestLoggingConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in UppercaseActionConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.UppercaseActionConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in UserDefinedMonitoring) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha1.UserDefinedMonitoring"
+}
diff --git a/vendor/github.com/openshift/api/config/v1alpha1/zz_generated.swagger_doc_generated.go b/vendor/github.com/openshift/api/config/v1alpha1/zz_generated.swagger_doc_generated.go
index e43dc7b236..99d9b5a66f 100644
--- a/vendor/github.com/openshift/api/config/v1alpha1/zz_generated.swagger_doc_generated.go
+++ b/vendor/github.com/openshift/api/config/v1alpha1/zz_generated.swagger_doc_generated.go
@@ -80,42 +80,19 @@ func (RetentionSizeConfig) SwaggerDoc() map[string]string {
return map_RetentionSizeConfig
}
-var map_ClusterImagePolicy = map[string]string{
- "": "ClusterImagePolicy holds cluster-wide configuration for image signature verification\n\nCompatibility level 4: No compatibility is provided, the API can change at any point for any reason. These capabilities should not be used by applications needing long term support.",
- "metadata": "metadata is the standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata",
- "spec": "spec contains the configuration for the cluster image policy.",
- "status": "status contains the observed state of the resource.",
-}
-
-func (ClusterImagePolicy) SwaggerDoc() map[string]string {
- return map_ClusterImagePolicy
-}
-
-var map_ClusterImagePolicyList = map[string]string{
- "": "ClusterImagePolicyList is a list of ClusterImagePolicy resources\n\nCompatibility level 4: No compatibility is provided, the API can change at any point for any reason. These capabilities should not be used by applications needing long term support.",
- "metadata": "metadata is the standard list's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata",
-}
-
-func (ClusterImagePolicyList) SwaggerDoc() map[string]string {
- return map_ClusterImagePolicyList
+var map_AdditionalAlertmanagerConfig = map[string]string{
+ "": "AdditionalAlertmanagerConfig represents configuration for additional Alertmanager instances. The `AdditionalAlertmanagerConfig` resource defines settings for how a component communicates with additional Alertmanager instances.",
+ "name": "name is a unique identifier for this Alertmanager configuration entry. The name must be a valid DNS subdomain (RFC 1123): lowercase alphanumeric characters, hyphens, or periods, and must start and end with an alphanumeric character. Minimum length is 1 character (empty string is invalid). Maximum length is 253 characters.",
+ "authorization": "authorization configures the authentication method for Alertmanager connections. Supports bearer token authentication. When omitted, no authentication is used.",
+ "pathPrefix": "pathPrefix defines an optional URL path prefix to prepend to the Alertmanager API endpoints. For example, if your Alertmanager is behind a reverse proxy at \"/alertmanager/\", set this to \"/alertmanager\" so requests go to \"/alertmanager/api/v1/alerts\" instead of \"/api/v1/alerts\". This is commonly needed when Alertmanager is deployed behind ingress controllers or load balancers. When no prefix is needed, omit this field; do not set it to \"/\" as that would produce paths with double slashes (e.g. \"//api/v1/alerts\"). Must start with \"/\", must not end with \"/\", and must not be exactly \"/\". Must not contain query strings (\"?\") or fragments (\"#\").",
+ "scheme": "scheme defines the URL scheme to use when communicating with Alertmanager instances. Possible values are `HTTP` or `HTTPS`. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The current default value is `HTTP`.",
+ "staticConfigs": "staticConfigs is a list of statically configured Alertmanager endpoints in the form of `:`. Each entry must be a valid hostname, IPv4 address, or IPv6 address (in brackets) followed by a colon and a valid port number (1-65535). Examples: \"alertmanager.example.com:9093\", \"192.168.1.100:9093\", \"[::1]:9093\" At least one endpoint must be specified (minimum 1, maximum 10 endpoints). Each entry must be unique and non-empty (empty string is invalid).",
+ "timeoutSeconds": "timeoutSeconds defines the timeout in seconds for requests to Alertmanager. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. Currently the default is 10 seconds. Minimum value is 1 second. Maximum value is 600 seconds (10 minutes).",
+ "tlsConfig": "tlsConfig defines the TLS settings to use for Alertmanager connections. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.",
}
-var map_ClusterImagePolicySpec = map[string]string{
- "": "CLusterImagePolicySpec is the specification of the ClusterImagePolicy custom resource.",
- "scopes": "scopes defines the list of image identities assigned to a policy. Each item refers to a scope in a registry implementing the \"Docker Registry HTTP API V2\". Scopes matching individual images are named Docker references in the fully expanded form, either using a tag or digest. For example, docker.io/library/busybox:latest (not busybox:latest). More general scopes are prefixes of individual-image scopes, and specify a repository (by omitting the tag or digest), a repository namespace, or a registry host (by only specifying the host name and possibly a port number) or a wildcard expression starting with `*.`, for matching all subdomains (not including a port number). Wildcards are only supported for subdomain matching, and may not be used in the middle of the host, i.e. *.example.com is a valid case, but example*.*.com is not. If multiple scopes match a given image, only the policy requirements for the most specific scope apply. The policy requirements for more general scopes are ignored. In addition to setting a policy appropriate for your own deployed applications, make sure that a policy on the OpenShift image repositories quay.io/openshift-release-dev/ocp-release, quay.io/openshift-release-dev/ocp-v4.0-art-dev (or on a more general scope) allows deployment of the OpenShift images required for cluster operation. If a scope is configured in both the ClusterImagePolicy and the ImagePolicy, or if the scope in ImagePolicy is nested under one of the scopes from the ClusterImagePolicy, only the policy from the ClusterImagePolicy will be applied. For additional details about the format, please refer to the document explaining the docker transport field, which can be found at: https://github.com/containers/image/blob/main/docs/containers-policy.json.5.md#docker",
- "policy": "policy contains configuration to allow scopes to be verified, and defines how images not matching the verification policy will be treated.",
-}
-
-func (ClusterImagePolicySpec) SwaggerDoc() map[string]string {
- return map_ClusterImagePolicySpec
-}
-
-var map_ClusterImagePolicyStatus = map[string]string{
- "conditions": "conditions provide details on the status of this API Resource.",
-}
-
-func (ClusterImagePolicyStatus) SwaggerDoc() map[string]string {
- return map_ClusterImagePolicyStatus
+func (AdditionalAlertmanagerConfig) SwaggerDoc() map[string]string {
+ return map_AdditionalAlertmanagerConfig
}
var map_AlertmanagerConfig = map[string]string{
@@ -129,14 +106,15 @@ func (AlertmanagerConfig) SwaggerDoc() map[string]string {
}
var map_AlertmanagerCustomConfig = map[string]string{
- "": "AlertmanagerCustomConfig represents the configuration for a custom Alertmanager deployment. alertmanagerCustomConfig provides configuration options for the default Alertmanager instance that runs in the `openshift-monitoring` namespace. Use this configuration to control whether the default Alertmanager is deployed, how it logs, and how its pods are scheduled.",
- "logLevel": "logLevel defines the verbosity of logs emitted by Alertmanager. This field allows users to control the amount and severity of logs generated, which can be useful for debugging issues or reducing noise in production environments. Allowed values are Error, Warn, Info, and Debug. When set to Error, only errors will be logged. When set to Warn, both warnings and errors will be logged. When set to Info, general information, warnings, and errors will all be logged. When set to Debug, detailed debugging information will be logged. When omitted, this means no opinion and the platform is left to choose a reasonable default, that is subject to change over time. The current default value is `Info`.",
- "nodeSelector": "nodeSelector defines the nodes on which the Pods are scheduled nodeSelector is optional.\n\nWhen omitted, this means the user has no opinion and the platform is left to choose reasonable defaults. These defaults are subject to change over time. The current default value is `kubernetes.io/os: linux`.",
- "resources": "resources defines the compute resource requests and limits for the Alertmanager container. This includes CPU, memory and HugePages constraints to help control scheduling and resource usage. When not specified, defaults are used by the platform. Requests cannot exceed limits. This field is optional. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ This is a simplified API that maps to Kubernetes ResourceRequirements. The current default values are:\n resources:\n - name: cpu\n request: 4m\n limit: null\n - name: memory\n request: 40Mi\n limit: null\nMaximum length for this list is 10. Minimum length for this list is 1. Each resource name must be unique within this list.",
- "secrets": "secrets defines a list of secrets that need to be mounted into the Alertmanager. The secrets must reside within the same namespace as the Alertmanager object. They will be added as volumes named secret- and mounted at /etc/alertmanager/secrets/ within the 'alertmanager' container of the Alertmanager Pods.\n\nThese secrets can be used to authenticate Alertmanager with endpoint receivers. For example, you can use secrets to: - Provide certificates for TLS authentication with receivers that require private CA certificates - Store credentials for Basic HTTP authentication with receivers that require password-based auth - Store any other authentication credentials needed by your alert receivers\n\nThis field is optional. Maximum length for this list is 10. Minimum length for this list is 1. Entries in this list must be unique.",
- "tolerations": "tolerations defines tolerations for the pods. tolerations is optional.\n\nWhen omitted, this means the user has no opinion and the platform is left to choose reasonable defaults. These defaults are subject to change over time. Defaults are empty/unset. Maximum length for this list is 10. Minimum length for this list is 1.",
- "topologySpreadConstraints": "topologySpreadConstraints defines rules for how Alertmanager Pods should be distributed across topology domains such as zones, nodes, or other user-defined labels. topologySpreadConstraints is optional. This helps improve high availability and resource efficiency by avoiding placing too many replicas in the same failure domain.\n\nWhen omitted, this means no opinion and the platform is left to choose a default, which is subject to change over time. This field maps directly to the `topologySpreadConstraints` field in the Pod spec. Default is empty list. Maximum length for this list is 10. Minimum length for this list is 1. Entries must have unique topologyKey and whenUnsatisfiable pairs.",
- "volumeClaimTemplate": "volumeClaimTemplate Defines persistent storage for Alertmanager. Use this setting to configure the persistent volume claim, including storage class, volume size, and name. If omitted, the Pod uses ephemeral storage and alert data will not persist across restarts. This field is optional.",
+ "": "AlertmanagerCustomConfig represents the configuration for a custom Alertmanager deployment. alertmanagerCustomConfig provides configuration options for the default Alertmanager instance that runs in the `openshift-monitoring` namespace. Use this configuration to control whether user-defined namespaces are selected for AlertmanagerConfig lookups, how it logs, and how its pods are scheduled.",
+ "userAlertmanagerConfigSelection": "userAlertmanagerConfigSelection is an optional field that controls whether user-defined namespaces can be selected for AlertmanagerConfig lookups on the platform Alertmanager instance in the `openshift-monitoring` namespace. Valid values are Selectable and None. When set to Selectable, the platform Alertmanager discovers AlertmanagerConfig resources in user-defined namespaces. This is equivalent to `enableUserAlertmanagerConfig: true` in the cluster-monitoring-config ConfigMap. When set to None, user-defined namespaces are not selected for AlertmanagerConfig lookups on the platform Alertmanager. This is equivalent to `enableUserAlertmanagerConfig: false` in the cluster-monitoring-config ConfigMap. This setting only applies when the user-workload monitoring Alertmanager is not enabled. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The current default value is `None`.",
+ "logLevel": "logLevel defines the verbosity of logs emitted by Alertmanager. This field allows users to control the amount and severity of logs generated, which can be useful for debugging issues or reducing noise in production environments. Allowed values are Error, Warn, Info, and Debug. When set to Error, only errors will be logged. When set to Warn, both warnings and errors will be logged. When set to Info, general information, warnings, and errors will all be logged. When set to Debug, detailed debugging information will be logged. When omitted, this means no opinion and the platform is left to choose a reasonable default, that is subject to change over time. The current default value is `Info`.",
+ "nodeSelector": "nodeSelector defines the nodes on which the Pods are scheduled nodeSelector is optional.\n\nWhen omitted, this means the user has no opinion and the platform is left to choose reasonable defaults. These defaults are subject to change over time. The current default value is `kubernetes.io/os: linux`.",
+ "resources": "resources defines the compute resource requests and limits for the Alertmanager container. This includes CPU, memory and HugePages constraints to help control scheduling and resource usage. When not specified, defaults are used by the platform. Requests cannot exceed limits. This field is optional. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ This is a simplified API that maps to Kubernetes ResourceRequirements. The current default values are:\n resources:\n - name: cpu\n request: 4m\n limit: null\n - name: memory\n request: 40Mi\n limit: null\nMaximum length for this list is 5. Minimum length for this list is 1. Each resource name must be unique within this list.",
+ "secrets": "secrets defines a list of secrets that need to be mounted into the Alertmanager. The secrets must reside within the same namespace as the Alertmanager object. They will be added as volumes named secret- and mounted at /etc/alertmanager/secrets/ within the 'alertmanager' container of the Alertmanager Pods.\n\nThese secrets can be used to authenticate Alertmanager with endpoint receivers. For example, you can use secrets to: - Provide certificates for TLS authentication with receivers that require private CA certificates - Store credentials for Basic HTTP authentication with receivers that require password-based auth - Store any other authentication credentials needed by your alert receivers\n\nThis field is optional. Maximum length for this list is 10. Minimum length for this list is 1. Entries in this list must be unique.",
+ "tolerations": "tolerations defines tolerations for the pods. tolerations is optional.\n\nWhen omitted, this means the user has no opinion and the platform is left to choose reasonable defaults. These defaults are subject to change over time. Defaults are empty/unset. Maximum length for this list is 10. Minimum length for this list is 1.",
+ "topologySpreadConstraints": "topologySpreadConstraints defines rules for how Alertmanager Pods should be distributed across topology domains such as zones, nodes, or other user-defined labels. topologySpreadConstraints is optional. This helps improve high availability and resource efficiency by avoiding placing too many replicas in the same failure domain.\n\nWhen omitted, this means no opinion and the platform is left to choose a default, which is subject to change over time. This field maps directly to the `topologySpreadConstraints` field in the Pod spec. Default is empty list. Maximum length for this list is 10. Minimum length for this list is 1. Entries must have unique topologyKey and whenUnsatisfiable pairs.",
+ "volumeClaimTemplate": "volumeClaimTemplate defines persistent storage for Alertmanager. Use this setting to configure the persistent volume claim, including storage class and volume size. If omitted, the Pod uses ephemeral storage and alert data will not persist across restarts.",
}
func (AlertmanagerCustomConfig) SwaggerDoc() map[string]string {
@@ -152,6 +130,26 @@ func (Audit) SwaggerDoc() map[string]string {
return map_Audit
}
+var map_AuthorizationConfig = map[string]string{
+ "": "AuthorizationConfig defines the authentication method for Alertmanager connections.",
+ "type": "type specifies the authentication type to use. Valid value is \"BearerToken\" (bearer token authentication). When set to BearerToken, the bearerToken field must be specified.",
+ "bearerToken": "bearerToken defines the secret reference containing the bearer token. Required when type is \"BearerToken\", and forbidden otherwise. The secret must exist in the openshift-monitoring namespace.",
+}
+
+func (AuthorizationConfig) SwaggerDoc() map[string]string {
+ return map_AuthorizationConfig
+}
+
+var map_BasicAuth = map[string]string{
+ "": "BasicAuth defines basic authentication settings for the remote write endpoint URL.",
+ "username": "username defines the secret reference containing the username for basic authentication. The secret must exist in the openshift-monitoring namespace.",
+ "password": "password defines the secret reference containing the password for basic authentication. The secret must exist in the openshift-monitoring namespace.",
+}
+
+func (BasicAuth) SwaggerDoc() map[string]string {
+ return map_BasicAuth
+}
+
var map_ClusterMonitoring = map[string]string{
"": "ClusterMonitoring is the Custom Resource object which holds the current status of Cluster Monitoring Operator. CMO is a central component of the monitoring stack.\n\nCompatibility level 4: No compatibility is provided, the API can change at any point for any reason. These capabilities should not be used by applications needing long term support. ClusterMonitoring is the Schema for the Cluster Monitoring Operators API",
"metadata": "metadata is the standard object metadata.",
@@ -177,9 +175,16 @@ var map_ClusterMonitoringSpec = map[string]string{
"": "ClusterMonitoringSpec defines the desired state of Cluster Monitoring Operator",
"userDefined": "userDefined set the deployment mode for user-defined monitoring in addition to the default platform monitoring. userDefined is optional. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The current default value is `Disabled`.",
"alertmanagerConfig": "alertmanagerConfig allows users to configure how the default Alertmanager instance should be deployed in the `openshift-monitoring` namespace. alertmanagerConfig is optional. When omitted, this means no opinion and the platform is left to choose a reasonable default, that is subject to change over time. The current default value is `DefaultConfig`.",
+ "prometheusConfig": "prometheusConfig provides configuration options for the default platform Prometheus instance that runs in the `openshift-monitoring` namespace. This configuration applies only to the platform Prometheus instance; user-workload Prometheus instances are configured separately.\n\nThis field allows you to customize how the platform Prometheus is deployed and operated, including:\n - Pod scheduling (node selectors, tolerations, topology spread constraints)\n - Resource allocation (CPU, memory requests/limits)\n - Retention policies (how long metrics are stored)\n - External integrations (remote write, additional alertmanagers)\n\nThis field is optional. When omitted, the platform chooses reasonable defaults, which may change over time.",
"metricsServerConfig": "metricsServerConfig is an optional field that can be used to configure the Kubernetes Metrics Server that runs in the openshift-monitoring namespace. Specifically, it can configure how the Metrics Server instance is deployed, pod scheduling, its audit policy and log verbosity. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.",
"prometheusOperatorConfig": "prometheusOperatorConfig is an optional field that can be used to configure the Prometheus Operator component. Specifically, it can configure how the Prometheus Operator instance is deployed, pod scheduling, and resource allocation. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.",
"prometheusOperatorAdmissionWebhookConfig": "prometheusOperatorAdmissionWebhookConfig is an optional field that can be used to configure the admission webhook component of Prometheus Operator that runs in the openshift-monitoring namespace. The admission webhook validates PrometheusRule and AlertmanagerConfig objects to ensure they are semantically valid, mutates PrometheusRule annotations, and converts AlertmanagerConfig objects between API versions. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.",
+ "openShiftStateMetricsConfig": "openShiftStateMetricsConfig is an optional field that can be used to configure the openshift-state-metrics agent that runs in the openshift-monitoring namespace. The openshift-state-metrics agent generates metrics about the state of OpenShift-specific Kubernetes objects, such as routes, builds, and deployments. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.",
+ "telemeterClientConfig": "telemeterClientConfig is an optional field that can be used to configure the Telemeter Client component that runs in the openshift-monitoring namespace. The Telemeter Client collects selected monitoring metrics and forwards them to Red Hat for telemetry purposes. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. When set, at least one field must be specified within telemeterClientConfig.",
+ "thanosQuerierConfig": "thanosQuerierConfig is an optional field that can be used to configure the Thanos Querier component that runs in the openshift-monitoring namespace. The Thanos Querier provides a global query view by aggregating and deduplicating metrics from multiple Prometheus instances. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The current default deploys the Thanos Querier on linux nodes with 5m CPU and 12Mi memory requests, and no custom tolerations or topology spread constraints. When set, at least one field must be specified within thanosQuerierConfig.",
+ "nodeExporterConfig": "nodeExporterConfig is an optional field that can be used to configure the node-exporter agent that runs as a DaemonSet in the openshift-monitoring namespace. The node-exporter agent collects hardware and OS-level metrics from every node in the cluster. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.",
+ "monitoringPluginConfig": "monitoringPluginConfig is an optional field that can be used to configure the monitoring plugin that runs as a dynamic plugin of the OpenShift web console. The monitoring plugin provides the monitoring UI in the OpenShift web console for visualizing metrics, alerts, and dashboards. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The current default deploys the monitoring-plugin as a single-replica Deployment on linux nodes with 10m CPU and 50Mi memory requests, and no custom tolerations or topology spread constraints. When set, at least one field must be specified within monitoringPluginConfig.",
+ "kubeStateMetricsConfig": "kubeStateMetricsConfig is an optional field that can be used to configure the kube-state-metrics agent that runs in the openshift-monitoring namespace. kube-state-metrics generates metrics about the state of Kubernetes objects such as Deployments, Nodes, and Pods. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.",
}
func (ClusterMonitoringSpec) SwaggerDoc() map[string]string {
@@ -197,7 +202,7 @@ func (ClusterMonitoringStatus) SwaggerDoc() map[string]string {
var map_ContainerResource = map[string]string{
"": "ContainerResource defines a single resource requirement for a container.",
"name": "name of the resource (e.g. \"cpu\", \"memory\", \"hugepages-2Mi\"). This field is required. name must consist only of alphanumeric characters, `-`, `_` and `.` and must start and end with an alphanumeric character.",
- "request": "request is the minimum amount of the resource required (e.g. \"2Mi\", \"1Gi\"). This field is optional. When limit is specified, request cannot be greater than limit.",
+ "request": "request is the minimum amount of the resource required (e.g. \"2Mi\", \"1Gi\"). This field is optional. When limit is specified, request cannot be greater than limit. The value must be greater than 0 when specified.",
"limit": "limit is the maximum amount of the resource allowed (e.g. \"2Mi\", \"1Gi\"). This field is optional. When request is specified, limit cannot be less than request. The value must be greater than 0 when specified.",
}
@@ -205,13 +210,111 @@ func (ContainerResource) SwaggerDoc() map[string]string {
return map_ContainerResource
}
+var map_DropEqualActionConfig = map[string]string{
+ "": "DropEqualActionConfig configures the DropEqual action. Drops targets for which the concatenated source_labels do match the value of target_label. Requires Prometheus >= v2.41.0.",
+ "targetLabel": "targetLabel is the label name whose value is compared to the concatenated source_labels; targets that match are dropped. Must be between 1 and 128 characters in length.",
+}
+
+func (DropEqualActionConfig) SwaggerDoc() map[string]string {
+ return map_DropEqualActionConfig
+}
+
+var map_HashModActionConfig = map[string]string{
+ "": "HashModActionConfig configures the HashMod action. target_label is set to the modulus of a hash of the concatenated source_labels (target = hash % modulus).",
+ "targetLabel": "targetLabel is the label name where the hash modulus result is written. Must be between 1 and 128 characters in length.",
+ "modulus": "modulus is the divisor applied to the hash of the concatenated source label values (target = hash % modulus). Required when using the HashMod action so the intended behavior is explicit. Must be between 1 and 1000000.",
+}
+
+func (HashModActionConfig) SwaggerDoc() map[string]string {
+ return map_HashModActionConfig
+}
+
+var map_KeepEqualActionConfig = map[string]string{
+ "": "KeepEqualActionConfig configures the KeepEqual action. Drops targets for which the concatenated source_labels do not match the value of target_label. Requires Prometheus >= v2.41.0.",
+ "targetLabel": "targetLabel is the label name whose value is compared to the concatenated source_labels; targets that do not match are dropped. Must be between 1 and 128 characters in length.",
+}
+
+func (KeepEqualActionConfig) SwaggerDoc() map[string]string {
+ return map_KeepEqualActionConfig
+}
+
+var map_KubeStateMetricsConfig = map[string]string{
+ "": "KubeStateMetricsConfig provides configuration options for the kube-state-metrics agent that runs in the `openshift-monitoring` namespace. kube-state-metrics generates metrics about the state of Kubernetes objects such as Deployments, Nodes, and Pods.",
+ "nodeSelector": "nodeSelector defines the nodes on which the Pods are scheduled. nodeSelector is optional.\n\nWhen omitted, this means the user has no opinion and the platform is left to choose reasonable defaults. These defaults are subject to change over time. The current default value is `kubernetes.io/os: linux`. When specified, nodeSelector must contain at least 1 entry and must not contain more than 10 entries.",
+ "resources": "resources defines the compute resource requests and limits for the kube-state-metrics container. This includes CPU, memory and HugePages constraints to help control scheduling and resource usage. When not specified, defaults are used by the platform. Requests cannot exceed limits. This field is optional. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ This is a simplified API that maps to Kubernetes ResourceRequirements. The current default values are:\n resources:\n - name: cpu\n request: 4m\n limit: null\n - name: memory\n request: 40Mi\n limit: null\nMaximum length for this list is 5. Minimum length for this list is 1. Each resource name must be unique within this list.",
+ "tolerations": "tolerations defines tolerations for the pods. tolerations is optional.\n\nWhen omitted, no tolerations are applied. This default is subject to change over time. When specified, tolerations must contain at least 1 entry and must not contain more than 10 entries. Each toleration's operator, when specified, must be either \"Exists\" or \"Equal\". Each toleration's effect, when specified, must be one of \"NoSchedule\", \"PreferNoSchedule\", or \"NoExecute\". An empty or unset effect means match all effects.",
+ "topologySpreadConstraints": "topologySpreadConstraints defines rules for how kube-state-metrics Pods should be distributed across topology domains such as zones, nodes, or other user-defined labels. topologySpreadConstraints is optional. This helps improve high availability and resource efficiency by avoiding placing too many replicas in the same failure domain.\n\nThis field maps directly to the `topologySpreadConstraints` field in the Pod spec. When omitted, no topology spread constraints are applied. This default is subject to change over time. When specified, topologySpreadConstraints must contain at least 1 entry and must not contain more than 10 entries. Entries must have unique topologyKey and whenUnsatisfiable pairs. Each entry's whenUnsatisfiable must be either \"DoNotSchedule\" or \"ScheduleAnyway\". Each entry's maxSkew must be at least 1. When minDomains is specified, it must be at least 1 and whenUnsatisfiable must be \"DoNotSchedule\".",
+ "additionalResourceLabels": "additionalResourceLabels defines additional Kubernetes resource labels to expose as metrics in kube-state-metrics. Currently, only \"Job\" and \"CronJob\" resources are supported due to cardinality concerns. Each entry specifies a resource name and a list of Kubernetes label names to expose. Use \"*\" in the labels list to expose all labels for a given resource. additionalResourceLabels is optional. When omitted, no additional Kubernetes object labels are exposed as metrics by kube-state-metrics beyond its built-in metric labels (e.g. namespace, job_name). Use this field to opt in to exposing specific Kubernetes labels as metric labels for the supported resource types. Minimum length for this list is 1. Maximum length for this list is 2. Each resource name must be unique within this list.",
+}
+
+func (KubeStateMetricsConfig) SwaggerDoc() map[string]string {
+ return map_KubeStateMetricsConfig
+}
+
+var map_KubeStateMetricsResourceLabels = map[string]string{
+ "": "KubeStateMetricsResourceLabels defines which Kubernetes labels to expose as metrics for a given resource type in kube-state-metrics.",
+ "resource": "resource is the Kubernetes resource name whose labels should be exposed as metrics. Currently, only \"Job\" and \"CronJob\" are supported due to cardinality concerns. Valid values are \"Job\" and \"CronJob\". This field is required.",
+ "labels": "labels is the list of Kubernetes label names to expose as metrics for this resource. Use \"*\" to expose all labels for the specified resource. When \"*\" is specified, it must be the only entry in the list; mixing \"*\" with specific label names is not allowed. This field is required. Each label name must be unique within this list. Minimum length for this list is 1. Maximum length for this list is 50.",
+}
+
+func (KubeStateMetricsResourceLabels) SwaggerDoc() map[string]string {
+ return map_KubeStateMetricsResourceLabels
+}
+
+var map_Label = map[string]string{
+ "": "Label represents a key/value pair for external labels.",
+ "key": "key is the name of the label. Prometheus supports UTF-8 label names, so any valid UTF-8 string is allowed. Must be between 1 and 128 characters in length.",
+ "value": "value is the value of the label. Must be between 1 and 128 characters in length.",
+}
+
+func (Label) SwaggerDoc() map[string]string {
+ return map_Label
+}
+
+var map_LabelMapActionConfig = map[string]string{
+ "": "LabelMapActionConfig configures the LabelMap action. Regex is matched against all source label names (not just source_labels). Matching label values are copied to new label names given by replacement, with match group references (${1}, ${2}, ...) substituted.",
+ "replacement": "replacement is the template for new label names; match group references (${1}, ${2}, ...) are substituted from the matched label name. Required when using the LabelMap action so the intended behavior is explicit and the platform does not need to apply defaults. Use \"$1\" for the first capture group, \"$2\" for the second, etc. Must be between 1 and 255 characters in length. Empty string is invalid as it would produce invalid label names.",
+}
+
+func (LabelMapActionConfig) SwaggerDoc() map[string]string {
+ return map_LabelMapActionConfig
+}
+
+var map_LowercaseActionConfig = map[string]string{
+ "": "LowercaseActionConfig configures the Lowercase action. Maps the concatenated source_labels to their lower case and writes to target_label. Requires Prometheus >= v2.36.0.",
+ "targetLabel": "targetLabel is the label name where the lower-cased value is written. Must be between 1 and 128 characters in length.",
+}
+
+func (LowercaseActionConfig) SwaggerDoc() map[string]string {
+ return map_LowercaseActionConfig
+}
+
+var map_MetadataConfig = map[string]string{
+ "": "MetadataConfig defines whether and how to send series metadata to remote write storage.",
+ "sendPolicy": "sendPolicy specifies whether to send metadata and how it is configured. Default: send metadata using platform-chosen defaults (e.g. send interval 30 seconds). Custom: send metadata using the settings in the custom field.",
+ "custom": "custom defines custom metadata send settings. Required when sendPolicy is Custom (must have at least one property), and forbidden when sendPolicy is Default.",
+}
+
+func (MetadataConfig) SwaggerDoc() map[string]string {
+ return map_MetadataConfig
+}
+
+var map_MetadataConfigCustom = map[string]string{
+ "": "MetadataConfigCustom defines custom settings for sending series metadata when sendPolicy is Custom. At least one property must be set when sendPolicy is Custom (e.g. sendIntervalSeconds).",
+ "sendIntervalSeconds": "sendIntervalSeconds is the interval in seconds at which metadata is sent. When omitted, the platform chooses a reasonable default (e.g. 30 seconds). Minimum value is 1 second. Maximum value is 86400 seconds (24 hours).",
+}
+
+func (MetadataConfigCustom) SwaggerDoc() map[string]string {
+ return map_MetadataConfigCustom
+}
+
var map_MetricsServerConfig = map[string]string{
"": "MetricsServerConfig provides configuration options for the Metrics Server instance that runs in the `openshift-monitoring` namespace. Use this configuration to control how the Metrics Server instance is deployed, how it logs, and how its pods are scheduled.",
"audit": "audit defines the audit configuration used by the Metrics Server instance. audit is optional. When omitted, this means no opinion and the platform is left to choose a reasonable default, that is subject to change over time. The current default sets audit.profile to Metadata",
"nodeSelector": "nodeSelector defines the nodes on which the Pods are scheduled nodeSelector is optional.\n\nWhen omitted, this means the user has no opinion and the platform is left to choose reasonable defaults. These defaults are subject to change over time. The current default value is `kubernetes.io/os: linux`.",
"tolerations": "tolerations defines tolerations for the pods. tolerations is optional.\n\nWhen omitted, this means the user has no opinion and the platform is left to choose reasonable defaults. These defaults are subject to change over time. Defaults are empty/unset. Maximum length for this list is 10. Minimum length for this list is 1.",
"verbosity": "verbosity defines the verbosity of log messages for Metrics Server. Valid values are Errors, Info, Trace, TraceAll and omitted. When set to Errors, only critical messages and errors are logged. When set to Info, only basic information messages are logged. When set to Trace, information useful for general debugging is logged. When set to TraceAll, detailed information about metric scraping is logged. When omitted, this means no opinion and the platform is left to choose a reasonable default, that is subject to change over time. The current default value is `Errors`",
- "resources": "resources defines the compute resource requests and limits for the Metrics Server container. This includes CPU, memory and HugePages constraints to help control scheduling and resource usage. When not specified, defaults are used by the platform. Requests cannot exceed limits. This field is optional. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ This is a simplified API that maps to Kubernetes ResourceRequirements. The current default values are:\n resources:\n - name: cpu\n request: 4m\n limit: null\n - name: memory\n request: 40Mi\n limit: null\nMaximum length for this list is 10. Minimum length for this list is 1. Each resource name must be unique within this list.",
+ "resources": "resources defines the compute resource requests and limits for the Metrics Server container. This includes CPU, memory and HugePages constraints to help control scheduling and resource usage. When not specified, defaults are used by the platform. Requests cannot exceed limits. This field is optional. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ This is a simplified API that maps to Kubernetes ResourceRequirements. The current default values are:\n resources:\n - name: cpu\n request: 4m\n limit: null\n - name: memory\n request: 40Mi\n limit: null\nMaximum length for this list is 5. Minimum length for this list is 1. Each resource name must be unique within this list.",
"topologySpreadConstraints": "topologySpreadConstraints defines rules for how Metrics Server Pods should be distributed across topology domains such as zones, nodes, or other user-defined labels. topologySpreadConstraints is optional. This helps improve high availability and resource efficiency by avoiding placing too many replicas in the same failure domain.\n\nWhen omitted, this means no opinion and the platform is left to choose a default, which is subject to change over time. This field maps directly to the `topologySpreadConstraints` field in the Pod spec. Default is empty list. Maximum length for this list is 10. Minimum length for this list is 1. Entries must have unique topologyKey and whenUnsatisfiable pairs.",
}
@@ -219,9 +322,277 @@ func (MetricsServerConfig) SwaggerDoc() map[string]string {
return map_MetricsServerConfig
}
+var map_MonitoringPluginConfig = map[string]string{
+ "": "MonitoringPluginConfig provides configuration options for the monitoring plugin that runs as a dynamic plugin of the OpenShift web console. The monitoring plugin provides the monitoring UI in the OpenShift web console for visualizing metrics, alerts, and dashboards. At least one field must be specified; an empty monitoringPluginConfig object is not allowed.",
+ "nodeSelector": "nodeSelector defines the nodes on which the Pods are scheduled. nodeSelector is optional.\n\nWhen omitted, this means the user has no opinion and the platform is left to choose reasonable defaults. These defaults are subject to change over time. The current default value is `kubernetes.io/os: linux`. When specified, nodeSelector must contain at least 1 entry and must not contain more than 10 entries.",
+ "resources": "resources defines the compute resource requests and limits for the monitoring-plugin container. This includes CPU, memory and HugePages constraints to help control scheduling and resource usage. When not specified, defaults are used by the platform. Requests cannot exceed limits. This field is optional. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ This is a simplified API that maps to Kubernetes ResourceRequirements. The current default values are:\n resources:\n - name: cpu\n request: 10m\n - name: memory\n request: 50Mi\n\nWhen specified, resources must contain at least 1 entry and must not exceed 5 entries.",
+ "tolerations": "tolerations defines the tolerations required for the monitoring-plugin Pods. This field is optional.\n\nWhen omitted, the monitoring-plugin Pods will not have any tolerations, which means they will only be scheduled on nodes with no taints. When specified, tolerations must contain at least 1 entry and must not contain more than 10 entries.",
+ "topologySpreadConstraints": "topologySpreadConstraints defines rules for how monitoring-plugin Pods should be distributed across topology domains such as zones, nodes, or other user-defined labels. topologySpreadConstraints is optional. This helps improve high availability and resource efficiency by avoiding placing too many replicas in the same failure domain.\n\nWhen omitted, this means no opinion and the platform is left to choose a default, which is subject to change over time. This field maps directly to the `topologySpreadConstraints` field in the Pod spec. Default is empty list. When specified, this list must contain at least 1 entry and must not exceed 10 entries.",
+}
+
+func (MonitoringPluginConfig) SwaggerDoc() map[string]string {
+ return map_MonitoringPluginConfig
+}
+
+var map_NodeExporterCollectorBuddyInfoConfig = map[string]string{
+ "": "NodeExporterCollectorBuddyInfoConfig provides configuration for the buddyinfo collector of the node-exporter agent. The buddyinfo collector collects statistics about memory fragmentation from the node_buddyinfo_blocks metric using data from /proc/buddyinfo. It is disabled by default.",
+ "collectionPolicy": "collectionPolicy declares whether the buddyinfo collector collects metrics. This field is required. Valid values are \"Collect\" and \"DoNotCollect\". When set to \"Collect\", the buddyinfo collector is active and memory fragmentation statistics are collected. When set to \"DoNotCollect\", the buddyinfo collector is inactive.",
+}
+
+func (NodeExporterCollectorBuddyInfoConfig) SwaggerDoc() map[string]string {
+ return map_NodeExporterCollectorBuddyInfoConfig
+}
+
+var map_NodeExporterCollectorConfig = map[string]string{
+ "": "NodeExporterCollectorConfig defines settings for individual collectors of the node-exporter agent. Each collector can be individually set to collect or not collect metrics. At least one collector must be specified.",
+ "cpuFreq": "cpuFreq configures the cpufreq collector, which collects CPU frequency statistics. cpuFreq is optional. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The current default is disabled. Consider enabling when you need to observe CPU frequency scaling; expect higher CPU usage on many-core nodes when collectionPolicy is Collect.",
+ "tcpStat": "tcpStat configures the tcpstat collector, which collects TCP connection statistics. tcpStat is optional. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The current default is disabled. Enable when debugging TCP connection behavior or capacity at the node level.",
+ "ethtool": "ethtool configures the ethtool collector, which collects ethernet device statistics. ethtool is optional. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The current default is disabled. Enable when you need NIC driver-level ethtool metrics beyond generic netdev counters.",
+ "netDev": "netDev configures the netdev collector, which collects network device statistics. netDev is optional. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The current default is enabled. Turn off if you must reduce per-interface metric cardinality on hosts with many virtual interfaces.",
+ "netClass": "netClass configures the netclass collector, which collects information about network devices. netClass is optional. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The current default is enabled with netlink mode active. Use statsGatherer when sysfs vs netlink implementation matters or when matching node_exporter tuning.",
+ "buddyInfo": "buddyInfo configures the buddyinfo collector, which collects statistics about memory fragmentation from the node_buddyinfo_blocks metric. This metric collects data from /proc/buddyinfo. buddyInfo is optional. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The current default is disabled. Enable when investigating kernel memory fragmentation; typically for advanced troubleshooting only.",
+ "mountStats": "mountStats configures the mountstats collector, which collects statistics about NFS volume I/O activities. mountStats is optional. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The current default is disabled. Enabling this collector may produce metrics with high cardinality. If you enable this collector, closely monitor the prometheus-k8s deployment for excessive memory usage. Enable when you care about per-mount NFS client statistics.",
+ "ksmd": "ksmd configures the ksmd collector, which collects statistics from the kernel same-page merger daemon. ksmd is optional. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The current default is disabled. Enable on nodes where KSM is in use and you want visibility into merging activity.",
+ "processes": "processes configures the processes collector, which collects statistics from processes and threads running in the system. processes is optional. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The current default is disabled. Enable for process/thread-level insight; can be expensive on busy nodes.",
+ "systemd": "systemd configures the systemd collector, which collects statistics on the systemd daemon and its managed services. systemd is optional. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The current default is disabled. Enabling this collector with a long list of selected units may produce metrics with high cardinality. If you enable this collector, closely monitor the prometheus-k8s deployment for excessive memory usage. Enable when you need metrics for specific units; scope units carefully.",
+ "softirqs": "softirqs configures the softirqs collector, which exposes detailed softirq statistics from /proc/softirqs. softirqs is optional. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The current default is disabled. Enable when you need visibility into kernel softirq processing across CPUs.",
+ "deviceMapperMultipath": "deviceMapperMultipath configures the dmmultipath collector, which collects statistics about DM-Multipath devices. deviceMapperMultipath is optional. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The current default is enabled.",
+ "zoneinfo": "zoneinfo configures the zoneinfo collector, which exposes per-zone memory page counts, watermarks, and protection thresholds from /proc/zoneinfo. zoneinfo is optional. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The current default is to not collect zoneinfo metrics. Enable when you need visibility into kernel memory zone allocation and pressure.",
+ "nvmExpressSubsystem": "nvmExpressSubsystem configures the nvmesubsystem collector, which collects statistics about NVM Express (NVMe) subsystem devices. nvmExpressSubsystem is optional. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The current default is enabled.",
+ "interrupts": "interrupts configures the interrupts collector, which exposes interrupt counts from /proc/interrupts. interrupts is optional. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The current default is disabled. The interrupts collector can produce a large number of metrics depending on the hardware and interrupt sources present. When enabled, the collect field with at least one include pattern is required to explicitly select which interrupt lines are collected.",
+}
+
+func (NodeExporterCollectorConfig) SwaggerDoc() map[string]string {
+ return map_NodeExporterCollectorConfig
+}
+
+var map_NodeExporterCollectorCpufreqConfig = map[string]string{
+ "": "NodeExporterCollectorCpufreqConfig provides configuration for the cpufreq collector of the node-exporter agent. The cpufreq collector collects CPU frequency statistics. It is disabled by default.",
+ "collectionPolicy": "collectionPolicy declares whether the cpufreq collector collects metrics. This field is required. Valid values are \"Collect\" and \"DoNotCollect\". When set to \"Collect\", the cpufreq collector is active and CPU frequency statistics are collected. When set to \"DoNotCollect\", the cpufreq collector is inactive.",
+}
+
+func (NodeExporterCollectorCpufreqConfig) SwaggerDoc() map[string]string {
+ return map_NodeExporterCollectorCpufreqConfig
+}
+
+var map_NodeExporterCollectorDeviceMapperMultipathConfig = map[string]string{
+ "": "NodeExporterCollectorDeviceMapperMultipathConfig provides configuration for the dmmultipath collector of the node-exporter agent. The dmmultipath collector collects statistics about DM-Multipath devices. It is enabled by default.",
+ "collectionPolicy": "collectionPolicy declares whether the dmmultipath collector collects metrics. This field is required. Valid values are \"Collect\" and \"DoNotCollect\". When set to \"Collect\", the dmmultipath collector is active and DM-Multipath device statistics are collected. When set to \"DoNotCollect\", the dmmultipath collector is inactive and the corresponding metrics become unavailable.",
+}
+
+func (NodeExporterCollectorDeviceMapperMultipathConfig) SwaggerDoc() map[string]string {
+ return map_NodeExporterCollectorDeviceMapperMultipathConfig
+}
+
+var map_NodeExporterCollectorEthtoolConfig = map[string]string{
+ "": "NodeExporterCollectorEthtoolConfig provides configuration for the ethtool collector of the node-exporter agent. The ethtool collector collects ethernet device statistics. It is disabled by default.",
+ "collectionPolicy": "collectionPolicy declares whether the ethtool collector collects metrics. This field is required. Valid values are \"Collect\" and \"DoNotCollect\". When set to \"Collect\", the ethtool collector is active and ethernet device statistics are collected. When set to \"DoNotCollect\", the ethtool collector is inactive.",
+}
+
+func (NodeExporterCollectorEthtoolConfig) SwaggerDoc() map[string]string {
+ return map_NodeExporterCollectorEthtoolConfig
+}
+
+var map_NodeExporterCollectorInterruptsCollectConfig = map[string]string{
+ "": "NodeExporterCollectorInterruptsCollectConfig holds configuration options for the interrupts collector when it is actively collecting metrics. At least one field must be specified.",
+ "include": "include is a list of regular expression patterns that select which interrupt lines to collect. This field is required. Each line in /proc/interrupts is matched against the same string node-exporter uses: the IRQ name, info, and devices fields joined with \";\", for example \"LOC;77;IO-APIC 2-edge ...\". Patterns are combined with OR into a single expression anchored on both ends, so each pattern must match the entire string (use \".*\" where needed). Each entry must be at least 1 character, at most 1024 characters, and only contain printable ASCII characters. Maximum length for this list is 50. Minimum length for this list is 1. Entries in this list must be unique.",
+}
+
+func (NodeExporterCollectorInterruptsCollectConfig) SwaggerDoc() map[string]string {
+ return map_NodeExporterCollectorInterruptsCollectConfig
+}
+
+var map_NodeExporterCollectorInterruptsConfig = map[string]string{
+ "": "NodeExporterCollectorInterruptsConfig provides configuration for the interrupts collector of the node-exporter agent. The interrupts collector exposes interrupt counts from /proc/interrupts. It is disabled by default. The interrupts collector can produce a large number of metrics depending on the hardware and interrupt sources present. When enabled, the collect field with at least one include pattern is required to explicitly select which interrupt lines are collected. When collectionPolicy is Collect, the collect field must be set with at least one include pattern. When collectionPolicy is DoNotCollect, the collect field must not be set.",
+ "collectionPolicy": "collectionPolicy declares whether the interrupts collector collects metrics. This field is required. Valid values are \"Collect\" and \"DoNotCollect\". When set to \"Collect\", the interrupts collector is active and the collect field must be set with at least one include pattern to select which interrupt lines are collected. When set to \"DoNotCollect\", the interrupts collector is inactive and the collect field must not be set.",
+ "collect": "collect contains configuration options that apply only when the interrupts collector is actively collecting metrics (i.e. when collectionPolicy is Collect). collect is required when collectionPolicy is Collect and must contain at least one include pattern to explicitly select which interrupt lines are collected. collect must not be set when collectionPolicy is DoNotCollect. When set, at least one field must be specified within collect.",
+}
+
+func (NodeExporterCollectorInterruptsConfig) SwaggerDoc() map[string]string {
+ return map_NodeExporterCollectorInterruptsConfig
+}
+
+var map_NodeExporterCollectorKSMDConfig = map[string]string{
+ "": "NodeExporterCollectorKSMDConfig provides configuration for the ksmd collector of the node-exporter agent. The ksmd collector collects statistics from the kernel same-page merger daemon. It is disabled by default.",
+ "collectionPolicy": "collectionPolicy declares whether the ksmd collector collects metrics. This field is required. Valid values are \"Collect\" and \"DoNotCollect\". When set to \"Collect\", the ksmd collector is active and kernel same-page merger statistics are collected. When set to \"DoNotCollect\", the ksmd collector is inactive.",
+}
+
+func (NodeExporterCollectorKSMDConfig) SwaggerDoc() map[string]string {
+ return map_NodeExporterCollectorKSMDConfig
+}
+
+var map_NodeExporterCollectorMountStatsConfig = map[string]string{
+ "": "NodeExporterCollectorMountStatsConfig provides configuration for the mountstats collector of the node-exporter agent. The mountstats collector collects statistics about NFS volume I/O activities. It is disabled by default. Enabling this collector may produce metrics with high cardinality. If you enable this collector, closely monitor the prometheus-k8s deployment for excessive memory usage.",
+ "collectionPolicy": "collectionPolicy declares whether the mountstats collector collects metrics. This field is required. Valid values are \"Collect\" and \"DoNotCollect\". When set to \"Collect\", the mountstats collector is active and NFS volume I/O statistics are collected. When set to \"DoNotCollect\", the mountstats collector is inactive.",
+}
+
+func (NodeExporterCollectorMountStatsConfig) SwaggerDoc() map[string]string {
+ return map_NodeExporterCollectorMountStatsConfig
+}
+
+var map_NodeExporterCollectorNVMExpressSubsystemConfig = map[string]string{
+ "": "NodeExporterCollectorNVMExpressSubsystemConfig provides configuration for the nvmesubsystem collector of the node-exporter agent. The nvmesubsystem collector collects statistics about NVM Express (NVMe) subsystem devices. It is enabled by default.",
+ "collectionPolicy": "collectionPolicy declares whether the nvmesubsystem collector collects metrics. This field is required. Valid values are \"Collect\" and \"DoNotCollect\". When set to \"Collect\", the nvmesubsystem collector is active and NVMe subsystem statistics are collected. When set to \"DoNotCollect\", the nvmesubsystem collector is inactive and the corresponding metrics become unavailable.",
+}
+
+func (NodeExporterCollectorNVMExpressSubsystemConfig) SwaggerDoc() map[string]string {
+ return map_NodeExporterCollectorNVMExpressSubsystemConfig
+}
+
+var map_NodeExporterCollectorNetClassCollectConfig = map[string]string{
+ "": "NodeExporterCollectorNetClassCollectConfig holds configuration options for the netclass collector when it is actively collecting metrics. At least one field must be specified.",
+ "statsGatherer": "statsGatherer selects which implementation the netclass collector uses to gather statistics (sysfs or netlink). statsGatherer is optional. Valid values are \"Sysfs\" and \"Netlink\". When set to \"Netlink\", the netlink implementation is used; when set to \"Sysfs\", the sysfs implementation is used. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The current default is Netlink.",
+}
+
+func (NodeExporterCollectorNetClassCollectConfig) SwaggerDoc() map[string]string {
+ return map_NodeExporterCollectorNetClassCollectConfig
+}
+
+var map_NodeExporterCollectorNetClassConfig = map[string]string{
+ "": "NodeExporterCollectorNetClassConfig provides configuration for the netclass collector of the node-exporter agent. The netclass collector collects information about network devices such as network speed, MTU, and carrier status. It is enabled by default. When collectionPolicy is DoNotCollect, the collect field must not be set.",
+ "collectionPolicy": "collectionPolicy declares whether the netclass collector collects metrics. This field is required. Valid values are \"Collect\" and \"DoNotCollect\". When set to \"Collect\", the netclass collector is active and network class information is collected. When set to \"DoNotCollect\", the netclass collector is inactive and the corresponding metrics become unavailable. When set to \"DoNotCollect\", the collect field must not be set.",
+ "collect": "collect contains configuration options that apply only when the netclass collector is actively collecting metrics (i.e. when collectionPolicy is Collect). collect is optional and may be omitted even when collectionPolicy is Collect. collect may only be set when collectionPolicy is Collect. When set, at least one field must be specified within collect.",
+}
+
+func (NodeExporterCollectorNetClassConfig) SwaggerDoc() map[string]string {
+ return map_NodeExporterCollectorNetClassConfig
+}
+
+var map_NodeExporterCollectorNetDevConfig = map[string]string{
+ "": "NodeExporterCollectorNetDevConfig provides configuration for the netdev collector of the node-exporter agent. The netdev collector collects network device statistics such as bytes, packets, errors, and drops per device. It is enabled by default.",
+ "collectionPolicy": "collectionPolicy declares whether the netdev collector collects metrics. This field is required. Valid values are \"Collect\" and \"DoNotCollect\". When set to \"Collect\", the netdev collector is active and network device statistics are collected. When set to \"DoNotCollect\", the netdev collector is inactive and the corresponding metrics become unavailable.",
+}
+
+func (NodeExporterCollectorNetDevConfig) SwaggerDoc() map[string]string {
+ return map_NodeExporterCollectorNetDevConfig
+}
+
+var map_NodeExporterCollectorProcessesConfig = map[string]string{
+ "": "NodeExporterCollectorProcessesConfig provides configuration for the processes collector of the node-exporter agent. The processes collector collects statistics from processes and threads running in the system. It is disabled by default.",
+ "collectionPolicy": "collectionPolicy declares whether the processes collector collects metrics. This field is required. Valid values are \"Collect\" and \"DoNotCollect\". When set to \"Collect\", the processes collector is active and process/thread statistics are collected. When set to \"DoNotCollect\", the processes collector is inactive.",
+}
+
+func (NodeExporterCollectorProcessesConfig) SwaggerDoc() map[string]string {
+ return map_NodeExporterCollectorProcessesConfig
+}
+
+var map_NodeExporterCollectorSoftirqsConfig = map[string]string{
+ "": "NodeExporterCollectorSoftirqsConfig provides configuration for the softirqs collector of the node-exporter agent. The softirqs collector exposes detailed softirq statistics from /proc/softirqs. It is disabled by default.",
+ "collectionPolicy": "collectionPolicy declares whether the softirqs collector collects metrics. This field is required. Valid values are \"Collect\" and \"DoNotCollect\". When set to \"Collect\", the softirqs collector is active and softirq statistics are collected. When set to \"DoNotCollect\", the softirqs collector is inactive.",
+}
+
+func (NodeExporterCollectorSoftirqsConfig) SwaggerDoc() map[string]string {
+ return map_NodeExporterCollectorSoftirqsConfig
+}
+
+var map_NodeExporterCollectorSystemdCollectConfig = map[string]string{
+ "": "NodeExporterCollectorSystemdCollectConfig holds configuration options for the systemd collector when it is actively collecting metrics. At least one field must be specified.",
+ "units": "units is a list of regular expression patterns that match systemd units to be included by the systemd collector. units is optional. By default, the list is empty, so the collector exposes no metrics for systemd units. Each entry is a regular expression pattern and must be at least 1 character and at most 1024 characters. Maximum length for this list is 50. Minimum length for this list is 1. Entries in this list must be unique.",
+}
+
+func (NodeExporterCollectorSystemdCollectConfig) SwaggerDoc() map[string]string {
+ return map_NodeExporterCollectorSystemdCollectConfig
+}
+
+var map_NodeExporterCollectorSystemdConfig = map[string]string{
+ "": "NodeExporterCollectorSystemdConfig provides configuration for the systemd collector of the node-exporter agent. The systemd collector collects statistics on the systemd daemon and its managed services. It is disabled by default. Enabling this collector with a long list of selected units may produce metrics with high cardinality. If you enable this collector, closely monitor the prometheus-k8s deployment for excessive memory usage. When collectionPolicy is DoNotCollect, the collect field must not be set.",
+ "collectionPolicy": "collectionPolicy declares whether the systemd collector collects metrics. This field is required. Valid values are \"Collect\" and \"DoNotCollect\". When set to \"Collect\", the systemd collector is active and systemd unit statistics are collected. When set to \"DoNotCollect\", the systemd collector is inactive and the collect field must not be set.",
+ "collect": "collect contains configuration options that apply only when the systemd collector is actively collecting metrics (i.e. when collectionPolicy is Collect). collect is optional and may be omitted even when collectionPolicy is Collect. collect may only be set when collectionPolicy is Collect. When set, at least one field must be specified within collect.",
+}
+
+func (NodeExporterCollectorSystemdConfig) SwaggerDoc() map[string]string {
+ return map_NodeExporterCollectorSystemdConfig
+}
+
+var map_NodeExporterCollectorTcpStatConfig = map[string]string{
+ "": "NodeExporterCollectorTcpStatConfig provides configuration for the tcpstat collector of the node-exporter agent. The tcpstat collector collects TCP connection statistics. It is disabled by default.",
+ "collectionPolicy": "collectionPolicy declares whether the tcpstat collector collects metrics. This field is required. Valid values are \"Collect\" and \"DoNotCollect\". When set to \"Collect\", the tcpstat collector is active and TCP connection statistics are collected. When set to \"DoNotCollect\", the tcpstat collector is inactive.",
+}
+
+func (NodeExporterCollectorTcpStatConfig) SwaggerDoc() map[string]string {
+ return map_NodeExporterCollectorTcpStatConfig
+}
+
+var map_NodeExporterCollectorZoneinfoConfig = map[string]string{
+ "": "NodeExporterCollectorZoneinfoConfig provides configuration for the zoneinfo collector of the node-exporter agent. The zoneinfo collector exposes per-zone memory page counts, watermarks, and protection thresholds from /proc/zoneinfo. By default, the zoneinfo collector does not collect metrics.",
+ "collectionPolicy": "collectionPolicy declares whether the zoneinfo collector collects metrics. This field is required. Valid values are \"Collect\" and \"DoNotCollect\". When set to \"Collect\", the zoneinfo collector is active and zone memory statistics are collected. When set to \"DoNotCollect\", the zoneinfo collector is inactive.",
+}
+
+func (NodeExporterCollectorZoneinfoConfig) SwaggerDoc() map[string]string {
+ return map_NodeExporterCollectorZoneinfoConfig
+}
+
+var map_NodeExporterConfig = map[string]string{
+ "": "NodeExporterConfig provides configuration options for the node-exporter agent that runs as a DaemonSet in the `openshift-monitoring` namespace. The node-exporter agent collects hardware and OS-level metrics from every node in the cluster, including CPU, memory, disk, and network statistics. At least one field must be specified.",
+ "resources": "resources defines the compute resource requests and limits for the node-exporter container. This includes CPU, memory and HugePages constraints to help control scheduling and resource usage. When not specified, defaults are used by the platform. Requests cannot exceed limits. This field is optional. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ This is a simplified API that maps to Kubernetes ResourceRequirements. The current default values are:\n resources:\n - name: cpu\n request: 8m\n limit: null\n - name: memory\n request: 32Mi\n limit: null",
+ "collectors": "collectors configures which node-exporter metric collectors are enabled. collectors is optional. Each collector can be individually enabled or disabled. Some collectors may have additional configuration options.\n\nWhen omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.",
+ "maxProcs": "maxProcs sets the target number of CPUs on which the node-exporter process will run. maxProcs is optional. Use this setting to override the default value, which is set either to 4 or to the number of CPUs on the host, whichever is smaller. The default value is computed at runtime and set via the GOMAXPROCS environment variable before node-exporter is launched. If a kernel deadlock occurs or if performance degrades when reading from sysfs concurrently, you can change this value to 1, which limits node-exporter to running on one CPU. For nodes with a high CPU count, setting the limit to a low number saves resources by preventing Go routines from being scheduled to run on all CPUs. However, I/O performance degrades if the maxProcs value is set too low and there are many metrics to collect. The minimum value is 1 and the maximum value is 1024. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The current default is min(4, number of host CPUs).",
+ "ignoredNetworkDevices": "ignoredNetworkDevices is a list of regular expression patterns that match network devices to be excluded from the relevant collector configuration such as netdev, netclass, and ethtool. ignoredNetworkDevices is optional.\n\nWhen omitted, the Cluster Monitoring Operator uses a predefined list of devices to be excluded to minimize the impact on memory usage. When set as an empty list, no devices are excluded. If you modify this setting, monitor the prometheus-k8s deployment closely for excessive memory usage. Maximum length for this list is 50. Each entry must be at least 1 character and at most 1024 characters long.",
+}
+
+func (NodeExporterConfig) SwaggerDoc() map[string]string {
+ return map_NodeExporterConfig
+}
+
+var map_OAuth2 = map[string]string{
+ "": "OAuth2 defines OAuth2 authentication settings for the remote write endpoint.",
+ "clientId": "clientId defines the secret reference containing the OAuth2 client ID. The secret must exist in the openshift-monitoring namespace.",
+ "clientSecret": "clientSecret defines the secret reference containing the OAuth2 client secret. The secret must exist in the openshift-monitoring namespace.",
+ "tokenUrl": "tokenUrl is the URL to fetch the token from. Must be a valid URL with http or https scheme. Must be between 1 and 2048 characters in length.",
+ "scopes": "scopes is a list of OAuth2 scopes to request. When omitted, no scopes are requested. Maximum of 20 scopes can be specified. Each scope must be between 1 and 256 characters.",
+ "endpointParams": "endpointParams defines additional parameters to append to the token URL. When omitted, no additional parameters are sent. Maximum of 20 parameters can be specified. Entries must have unique names (name is the list key).",
+}
+
+func (OAuth2) SwaggerDoc() map[string]string {
+ return map_OAuth2
+}
+
+var map_OAuth2EndpointParam = map[string]string{
+ "": "OAuth2EndpointParam defines a name/value parameter for the OAuth2 token URL.",
+ "name": "name is the parameter name. Must be between 1 and 256 characters.",
+ "value": "value is the optional parameter value. When omitted, the query parameter is applied as ?name (no value). When set (including to the empty string), it is applied as ?name=value. Empty string may be used when the external system expects a parameter with an empty value (e.g. ?parameter=\"\"). Must be between 0 and 2048 characters when present (aligned with common URL length recommendations).",
+}
+
+func (OAuth2EndpointParam) SwaggerDoc() map[string]string {
+ return map_OAuth2EndpointParam
+}
+
+var map_OpenShiftStateMetricsConfig = map[string]string{
+ "": "OpenShiftStateMetricsConfig provides configuration options for the openshift-state-metrics agent that runs in the `openshift-monitoring` namespace. The openshift-state-metrics agent generates metrics about the state of OpenShift-specific Kubernetes objects, such as routes, builds, and deployments.",
+ "nodeSelector": "nodeSelector defines the nodes on which the Pods are scheduled. nodeSelector is optional.\n\nWhen omitted, this means the user has no opinion and the platform is left to choose reasonable defaults. These defaults are subject to change over time. The current default value is `kubernetes.io/os: linux`. When specified, nodeSelector must contain at least 1 entry and must not contain more than 10 entries.",
+ "resources": "resources defines the compute resource requests and limits for the openshift-state-metrics container. This includes CPU, memory and HugePages constraints to help control scheduling and resource usage. When not specified, defaults are used by the platform. Requests cannot exceed limits. This field is optional. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ This is a simplified API that maps to Kubernetes ResourceRequirements. The current default values are:\n resources:\n - name: cpu\n request: 1m\n limit: null\n - name: memory\n request: 32Mi\n limit: null\nMaximum length for this list is 5. Minimum length for this list is 1. Each resource name must be unique within this list.",
+ "tolerations": "tolerations defines tolerations for the pods. tolerations is optional.\n\nWhen omitted, this means the user has no opinion and the platform is left to choose reasonable defaults. These defaults are subject to change over time. Defaults are empty/unset. Maximum length for this list is 10. Minimum length for this list is 1.",
+ "topologySpreadConstraints": "topologySpreadConstraints defines rules for how openshift-state-metrics Pods should be distributed across topology domains such as zones, nodes, or other user-defined labels. topologySpreadConstraints is optional. This helps improve high availability and resource efficiency by avoiding placing too many replicas in the same failure domain.\n\nWhen omitted, this means no opinion and the platform is left to choose a default, which is subject to change over time. This field maps directly to the `topologySpreadConstraints` field in the Pod spec. Default is empty list. Maximum length for this list is 10. Minimum length for this list is 1. Entries must have unique topologyKey and whenUnsatisfiable pairs.",
+}
+
+func (OpenShiftStateMetricsConfig) SwaggerDoc() map[string]string {
+ return map_OpenShiftStateMetricsConfig
+}
+
+var map_PrometheusConfig = map[string]string{
+ "": "PrometheusConfig provides configuration options for the Prometheus instance. Use this configuration to control Prometheus deployment, pod scheduling, resource allocation, retention policies, and external integrations.",
+ "additionalAlertmanagerConfigs": "additionalAlertmanagerConfigs configures additional Alertmanager instances that receive alerts from the Prometheus component. This is useful for organizations that need to:\n - Send alerts to external monitoring systems (like PagerDuty, Slack, or custom webhooks)\n - Route different types of alerts to different teams or systems\n - Integrate with existing enterprise alerting infrastructure\n - Maintain separate alert routing for compliance or organizational requirements\nWhen omitted, no additional Alertmanager instances are configured (default behavior). When provided, at least one configuration must be specified (minimum 1, maximum 10 items). Entries must have unique names (name is the list key).",
+ "enforcedBodySizeLimitBytes": "enforcedBodySizeLimitBytes enforces a body size limit (in bytes) for Prometheus scraped metrics. If a scraped target's body response is larger than the limit, the scrape will fail. This helps protect Prometheus from targets that return excessively large responses. The value is specified in bytes (e.g., 4194304 for 4MB, 1073741824 for 1GB). When omitted, the Cluster Monitoring Operator automatically calculates an appropriate limit based on cluster capacity. Set an explicit value to override the automatic calculation. Minimum value is 10240 (10kB). Maximum value is 1073741824 (1GB).",
+ "externalLabels": "externalLabels defines labels to be attached to time series and alerts when communicating with external systems such as federation, remote storage, and Alertmanager. These labels are not stored with metrics on disk; they are only added when data leaves Prometheus (e.g., during federation queries, remote write, or alert notifications). At least 1 label must be specified when set, with a maximum of 50 labels allowed. Each label key must be unique within this list. When omitted, no external labels are applied.",
+ "logLevel": "logLevel defines the verbosity of logs emitted by Prometheus. This field allows users to control the amount and severity of logs generated, which can be useful for debugging issues or reducing noise in production environments. Allowed values are Error, Warn, Info, and Debug. When set to Error, only errors will be logged. When set to Warn, both warnings and errors will be logged. When set to Info, general information, warnings, and errors will all be logged. When set to Debug, detailed debugging information will be logged. When omitted, this means no opinion and the platform is left to choose a reasonable default, that is subject to change over time. The current default value is `Info`.",
+ "nodeSelector": "nodeSelector defines the nodes on which the Pods are scheduled. nodeSelector is optional.\n\nWhen omitted, this means the user has no opinion and the platform is left to choose reasonable defaults. These defaults are subject to change over time. The current default value is `kubernetes.io/os: linux`. When specified, nodeSelector must contain at least one key-value pair (minimum of 1) and must not contain more than 10 entries.",
+ "queryLogFile": "queryLogFile specifies the file to which PromQL queries are logged. This setting can be either a filename, in which case the queries are saved to an `emptyDir` volume at `/var/log/prometheus`, or a full path to a location where an `emptyDir` volume will be mounted and the queries saved. Writing to `/dev/stderr`, `/dev/stdout` or `/dev/null` is supported, but writing to any other `/dev/` path is not supported. Relative paths are also not supported. By default, PromQL queries are not logged. Must be an absolute path starting with `/` or a simple filename without path separators. Must not contain consecutive slashes, end with a slash, or include '..' path traversal. Must contain only alphanumeric characters, '.', '_', '-', or '/'. Must be between 1 and 255 characters in length.",
+ "remoteWrite": "remoteWrite defines the remote write configuration, including URL, authentication, and relabeling settings. Remote write allows Prometheus to send metrics it collects to external long-term storage systems. When omitted, no remote write endpoints are configured. When provided, at least one configuration must be specified (minimum 1, maximum 10 items). Entries must have unique names (name is the list key).",
+ "resources": "resources defines the compute resource requests and limits for the Prometheus container. This includes CPU, memory and HugePages constraints to help control scheduling and resource usage. When not specified, defaults are used by the platform. Requests cannot exceed limits. This field is optional. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ This is a simplified API that maps to Kubernetes ResourceRequirements. The current default values are:\n resources:\n - name: cpu\n request: 4m\n limit: null\n - name: memory\n request: 40Mi\n limit: null\nMaximum length for this list is 5. Minimum length for this list is 1. Each resource name must be unique within this list.",
+ "retention": "retention configures how long Prometheus retains metrics data and how much storage it can use. When omitted, the platform chooses reasonable defaults (currently 15d retention, no size limit).",
+ "tolerations": "tolerations defines tolerations for the pods. tolerations is optional.\n\nWhen omitted, this means the user has no opinion and the platform is left to choose reasonable defaults. These defaults are subject to change over time. Defaults are empty/unset. Maximum length for this list is 10 Minimum length for this list is 1",
+ "topologySpreadConstraints": "topologySpreadConstraints defines rules for how Prometheus Pods should be distributed across topology domains such as zones, nodes, or other user-defined labels. topologySpreadConstraints is optional. This helps improve high availability and resource efficiency by avoiding placing too many replicas in the same failure domain.\n\nWhen omitted, this means no opinion and the platform is left to choose a default, which is subject to change over time. This field maps directly to the `topologySpreadConstraints` field in the Pod spec. Default is empty list. Maximum length for this list is 10. Minimum length for this list is 1 Entries must have unique topologyKey and whenUnsatisfiable pairs.",
+ "collectionProfile": "collectionProfile defines the metrics collection profile that Prometheus uses to collect metrics from the platform components. Supported values are `Full` or `Minimal`. In the `Full` profile (default), Prometheus collects all metrics that are exposed by the platform components. In the `Minimal` profile, Prometheus only collects metrics necessary for the default platform alerts, recording rules, telemetry and console dashboards. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The default value is `Full`.",
+ "volumeClaimTemplate": "volumeClaimTemplate defines persistent storage for Prometheus. Use this setting to configure the persistent volume claim, including storage class and volume size. If omitted, the Pod uses ephemeral storage and Prometheus data will not persist across restarts.",
+}
+
+func (PrometheusConfig) SwaggerDoc() map[string]string {
+ return map_PrometheusConfig
+}
+
var map_PrometheusOperatorAdmissionWebhookConfig = map[string]string{
"": "PrometheusOperatorAdmissionWebhookConfig provides configuration options for the admission webhook component of Prometheus Operator that runs in the `openshift-monitoring` namespace. The admission webhook validates PrometheusRule and AlertmanagerConfig objects, mutates PrometheusRule annotations, and converts AlertmanagerConfig objects between API versions.",
- "resources": "resources defines the compute resource requests and limits for the prometheus-operator-admission-webhook container. This includes CPU, memory and HugePages constraints to help control scheduling and resource usage. When not specified, defaults are used by the platform. Requests cannot exceed limits. This field is optional. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ This is a simplified API that maps to Kubernetes ResourceRequirements. The current default values are:\n resources:\n - name: cpu\n request: 5m\n limit: null\n - name: memory\n request: 30Mi\n limit: null\nMaximum length for this list is 10. Minimum length for this list is 1. Each resource name must be unique within this list.",
+ "resources": "resources defines the compute resource requests and limits for the prometheus-operator-admission-webhook container. This includes CPU, memory and HugePages constraints to help control scheduling and resource usage. When not specified, defaults are used by the platform. Requests cannot exceed limits. This field is optional. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ This is a simplified API that maps to Kubernetes ResourceRequirements. The current default values are:\n resources:\n - name: cpu\n request: 5m\n limit: null\n - name: memory\n request: 30Mi\n limit: null\nMaximum length for this list is 5. Minimum length for this list is 1. Each resource name must be unique within this list.",
"topologySpreadConstraints": "topologySpreadConstraints defines rules for how admission webhook Pods should be distributed across topology domains such as zones, nodes, or other user-defined labels. topologySpreadConstraints is optional. This helps improve high availability and resource efficiency by avoiding placing too many replicas in the same failure domain.\n\nWhen omitted, this means no opinion and the platform is left to choose a default, which is subject to change over time. This field maps directly to the `topologySpreadConstraints` field in the Pod spec. Default is empty list. Maximum length for this list is 10. Minimum length for this list is 1. Entries must have unique topologyKey and whenUnsatisfiable pairs.",
}
@@ -233,7 +604,7 @@ var map_PrometheusOperatorConfig = map[string]string{
"": "PrometheusOperatorConfig provides configuration options for the Prometheus Operator instance Use this configuration to control how the Prometheus Operator instance is deployed, how it logs, and how its pods are scheduled.",
"logLevel": "logLevel defines the verbosity of logs emitted by Prometheus Operator. This field allows users to control the amount and severity of logs generated, which can be useful for debugging issues or reducing noise in production environments. Allowed values are Error, Warn, Info, and Debug. When set to Error, only errors will be logged. When set to Warn, both warnings and errors will be logged. When set to Info, general information, warnings, and errors will all be logged. When set to Debug, detailed debugging information will be logged. When omitted, this means no opinion and the platform is left to choose a reasonable default, that is subject to change over time. The current default value is `Info`.",
"nodeSelector": "nodeSelector defines the nodes on which the Pods are scheduled nodeSelector is optional.\n\nWhen omitted, this means the user has no opinion and the platform is left to choose reasonable defaults. These defaults are subject to change over time. The current default value is `kubernetes.io/os: linux`. When specified, nodeSelector must contain at least 1 entry and must not contain more than 10 entries.",
- "resources": "resources defines the compute resource requests and limits for the Prometheus Operator container. This includes CPU, memory and HugePages constraints to help control scheduling and resource usage. When not specified, defaults are used by the platform. Requests cannot exceed limits. This field is optional. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ This is a simplified API that maps to Kubernetes ResourceRequirements. The current default values are:\n resources:\n - name: cpu\n request: 4m\n limit: null\n - name: memory\n request: 40Mi\n limit: null\nMaximum length for this list is 10. Minimum length for this list is 1. Each resource name must be unique within this list.",
+ "resources": "resources defines the compute resource requests and limits for the Prometheus Operator container. This includes CPU, memory and HugePages constraints to help control scheduling and resource usage. When not specified, defaults are used by the platform. Requests cannot exceed limits. This field is optional. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ This is a simplified API that maps to Kubernetes ResourceRequirements. The current default values are:\n resources:\n - name: cpu\n request: 4m\n limit: null\n - name: memory\n request: 40Mi\n limit: null\nMaximum length for this list is 5. Minimum length for this list is 1. Each resource name must be unique within this list.",
"tolerations": "tolerations defines tolerations for the pods. tolerations is optional.\n\nWhen omitted, this means the user has no opinion and the platform is left to choose reasonable defaults. These defaults are subject to change over time. Defaults are empty/unset. Maximum length for this list is 10. Minimum length for this list is 1.",
"topologySpreadConstraints": "topologySpreadConstraints defines rules for how Prometheus Operator Pods should be distributed across topology domains such as zones, nodes, or other user-defined labels. topologySpreadConstraints is optional. This helps improve high availability and resource efficiency by avoiding placing too many replicas in the same failure domain.\n\nWhen omitted, this means no opinion and the platform is left to choose a default, which is subject to change over time. This field maps directly to the `topologySpreadConstraints` field in the Pod spec. Default is empty list. Maximum length for this list is 10. Minimum length for this list is 1. Entries must have unique topologyKey and whenUnsatisfiable pairs.",
}
@@ -242,191 +613,240 @@ func (PrometheusOperatorConfig) SwaggerDoc() map[string]string {
return map_PrometheusOperatorConfig
}
-var map_UserDefinedMonitoring = map[string]string{
- "": "UserDefinedMonitoring config for user-defined projects.",
- "mode": "mode defines the different configurations of UserDefinedMonitoring Valid values are Disabled and NamespaceIsolated Disabled disables monitoring for user-defined projects. This restricts the default monitoring stack, installed in the openshift-monitoring project, to monitor only platform namespaces, which prevents any custom monitoring configurations or resources from being applied to user-defined namespaces. NamespaceIsolated enables monitoring for user-defined projects with namespace-scoped tenancy. This ensures that metrics, alerts, and monitoring data are isolated at the namespace level. The current default value is `Disabled`.",
+var map_PrometheusRemoteWriteHeader = map[string]string{
+ "": "PrometheusRemoteWriteHeader defines a custom HTTP header for remote write requests. The header name must not be one of the reserved headers set by Prometheus (Host, Authorization, Content-Encoding, Content-Type, X-Prometheus-Remote-Write-Version, User-Agent, Connection, Keep-Alive, Proxy-Authenticate, Proxy-Authorization, WWW-Authenticate). Header names must contain only case-insensitive alphanumeric characters, hyphens (-), and underscores (_); other characters (e.g. emoji) are rejected by validation. Validation is enforced on the Headers field in RemoteWriteSpec.",
+ "name": "name is the HTTP header name. Must not be a reserved header (see type documentation). Must contain only alphanumeric characters, hyphens, and underscores; invalid characters are rejected. Must be between 1 and 256 characters.",
+ "value": "value is the HTTP header value. Must be at most 4096 characters.",
}
-func (UserDefinedMonitoring) SwaggerDoc() map[string]string {
- return map_UserDefinedMonitoring
+func (PrometheusRemoteWriteHeader) SwaggerDoc() map[string]string {
+ return map_PrometheusRemoteWriteHeader
}
-var map_CRIOCredentialProviderConfig = map[string]string{
- "": "CRIOCredentialProviderConfig holds cluster-wide singleton resource configurations for CRI-O credential provider, the name of this instance is \"cluster\". CRI-O credential provider is a binary shipped with CRI-O that provides a way to obtain container image pull credentials from external sources. For example, it can be used to fetch mirror registry credentials from secrets resources in the cluster within the same namespace the pod will be running in. CRIOCredentialProviderConfig configuration specifies the pod image sources registries that should trigger the CRI-O credential provider execution, which will resolve the CRI-O mirror configurations and obtain the necessary credentials for pod creation. Note: Configuration changes will only take effect after the kubelet restarts, which is automatically managed by the cluster during rollout.\n\nThe resource is a singleton named \"cluster\".\n\nCompatibility level 4: No compatibility is provided, the API can change at any point for any reason. These capabilities should not be used by applications needing long term support.",
- "metadata": "metadata is the standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata",
- "spec": "spec defines the desired configuration of the CRI-O Credential Provider. This field is required and must be provided when creating the resource.",
- "status": "status represents the current state of the CRIOCredentialProviderConfig. When omitted or nil, it indicates that the status has not yet been set by the controller. The controller will populate this field with validation conditions and operational state.",
+var map_QueueConfig = map[string]string{
+ "": "QueueConfig allows tuning configuration for remote write queue parameters. Configure this when you need to control throughput, backpressure, or retry behavior—for example to avoid overloading the remote endpoint, to reduce memory usage, or to tune for high-cardinality workloads. Consider capacity, maxShards, and batchSendDeadlineSeconds for throughput; minBackoffMilliseconds and maxBackoffMilliseconds for retries; and rateLimitedAction when the remote returns HTTP 429.",
+ "capacity": "capacity is the number of samples to buffer per shard before we start dropping them. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The default value is 10000. Minimum value is 1. Maximum value is 1000000.",
+ "maxShards": "maxShards is the maximum number of shards, i.e. amount of concurrency. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The default value is 200. Minimum value is 1. Maximum value is 10000.",
+ "minShards": "minShards is the minimum number of shards, i.e. amount of concurrency. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The default value is 1. Minimum value is 1. Maximum value is 10000.",
+ "maxSamplesPerSend": "maxSamplesPerSend is the maximum number of samples per send. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The default value is 1000. Minimum value is 1. Maximum value is 100000.",
+ "batchSendDeadlineSeconds": "batchSendDeadlineSeconds is the maximum time in seconds a sample will wait in buffer before being sent. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. Minimum value is 1 second. Maximum value is 3600 seconds (1 hour).",
+ "minBackoffMilliseconds": "minBackoffMilliseconds is the minimum retry delay in milliseconds. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. Minimum value is 1 millisecond. Maximum value is 3600000 milliseconds (1 hour).",
+ "maxBackoffMilliseconds": "maxBackoffMilliseconds is the maximum retry delay in milliseconds. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. Minimum value is 1 millisecond. Maximum value is 3600000 milliseconds (1 hour).",
+ "rateLimitedAction": "rateLimitedAction controls what to do when the remote write endpoint returns HTTP 429 (Too Many Requests). When omitted, no retries are performed on rate limit responses. When set to \"Retry\", Prometheus will retry such requests using the backoff settings above. Valid value when set is \"Retry\".",
}
-func (CRIOCredentialProviderConfig) SwaggerDoc() map[string]string {
- return map_CRIOCredentialProviderConfig
+func (QueueConfig) SwaggerDoc() map[string]string {
+ return map_QueueConfig
}
-var map_CRIOCredentialProviderConfigList = map[string]string{
- "": "CRIOCredentialProviderConfigList contains a list of CRIOCredentialProviderConfig resources\n\nCompatibility level 4: No compatibility is provided, the API can change at any point for any reason. These capabilities should not be used by applications needing long term support.",
- "metadata": "metadata is the standard list's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata",
+var map_RelabelActionConfig = map[string]string{
+ "": "RelabelActionConfig represents the action to perform and its configuration. Exactly one action-specific configuration must be specified based on the action type.",
+ "type": "type specifies the action to perform on the matched labels. Allowed values are Replace, Lowercase, Uppercase, Keep, Drop, KeepEqual, DropEqual, HashMod, LabelMap, LabelDrop, LabelKeep.\n\nWhen set to Replace, regex is matched against the concatenated source_labels; target_label is set to replacement with match group references (${1}, ${2}, ...) substituted. If regex does not match, no replacement takes place.\n\nWhen set to Lowercase, the concatenated source_labels are mapped to their lower case. Requires Prometheus >= v2.36.0.\n\nWhen set to Uppercase, the concatenated source_labels are mapped to their upper case. Requires Prometheus >= v2.36.0.\n\nWhen set to Keep, targets for which regex does not match the concatenated source_labels are dropped.\n\nWhen set to Drop, targets for which regex matches the concatenated source_labels are dropped.\n\nWhen set to KeepEqual, targets for which the concatenated source_labels do not match target_label are dropped. Requires Prometheus >= v2.41.0.\n\nWhen set to DropEqual, targets for which the concatenated source_labels do match target_label are dropped. Requires Prometheus >= v2.41.0.\n\nWhen set to HashMod, target_label is set to the modulus of a hash of the concatenated source_labels.\n\nWhen set to LabelMap, regex is matched against all source label names (not just source_labels); matching label values are copied to new names given by replacement with ${1}, ${2}, ... substituted.\n\nWhen set to LabelDrop, regex is matched against all label names; any label that matches is removed.\n\nWhen set to LabelKeep, regex is matched against all label names; any label that does not match is removed.",
+ "replace": "replace configures the Replace action. Required when type is Replace, and forbidden otherwise.",
+ "hashMod": "hashMod configures the HashMod action. Required when type is HashMod, and forbidden otherwise.",
+ "labelMap": "labelMap configures the LabelMap action. Required when type is LabelMap, and forbidden otherwise.",
+ "lowercase": "lowercase configures the Lowercase action. Required when type is Lowercase, and forbidden otherwise. Requires Prometheus >= v2.36.0.",
+ "uppercase": "uppercase configures the Uppercase action. Required when type is Uppercase, and forbidden otherwise. Requires Prometheus >= v2.36.0.",
+ "keepEqual": "keepEqual configures the KeepEqual action. Required when type is KeepEqual, and forbidden otherwise. Requires Prometheus >= v2.41.0.",
+ "dropEqual": "dropEqual configures the DropEqual action. Required when type is DropEqual, and forbidden otherwise. Requires Prometheus >= v2.41.0.",
}
-func (CRIOCredentialProviderConfigList) SwaggerDoc() map[string]string {
- return map_CRIOCredentialProviderConfigList
+func (RelabelActionConfig) SwaggerDoc() map[string]string {
+ return map_RelabelActionConfig
}
-var map_CRIOCredentialProviderConfigSpec = map[string]string{
- "": "CRIOCredentialProviderConfigSpec defines the desired configuration of the CRI-O Credential Provider.",
- "matchImages": "matchImages is a list of string patterns used to determine whether the CRI-O credential provider should be invoked for a given image. This list is passed to the kubelet CredentialProviderConfig, and if any pattern matches the requested image, CRI-O credential provider will be invoked to obtain credentials for pulling that image or its mirrors. Depending on the platform, the CRI-O credential provider may be installed alongside an existing platform specific provider. Conflicts between the existing platform specific provider image match configuration and this list will be handled by the following precedence rule: credentials from built-in kubelet providers (e.g., ECR, GCR, ACR) take precedence over those from the CRIOCredentialProviderConfig when both match the same image. To avoid uncertainty, it is recommended to avoid configuring your private image patterns to overlap with existing platform specific provider config(e.g., the entries from https://github.com/openshift/machine-config-operator/blob/main/templates/common/aws/files/etc-kubernetes-credential-providers-ecr-credential-provider.yaml). You can check the resource's Status conditions to see if any entries were ignored due to exact matches with known built-in provider patterns.\n\nThis field is optional, the items of the list must contain between 1 and 50 entries. The list is treated as a set, so duplicate entries are not allowed.\n\nFor more details, see: https://kubernetes.io/docs/tasks/administer-cluster/kubelet-credential-provider/ https://github.com/cri-o/crio-credential-provider#architecture\n\nEach entry in matchImages is a pattern which can optionally contain a port and a path. Each entry must be no longer than 512 characters. Wildcards ('*') are supported for full subdomain labels, such as '*.k8s.io' or 'k8s.*.io', and for top-level domains, such as 'k8s.*' (which matches 'k8s.io' or 'k8s.net'). A global wildcard '*' (matching any domain) is not allowed. Wildcards may replace an entire hostname label (e.g., *.example.com), but they cannot appear within a label (e.g., f*oo.example.com) and are not allowed in the port or path. For example, 'example.*.com' is valid, but 'exa*mple.*.com' is not. Each wildcard matches only a single domain label, so '*.io' does **not** match '*.k8s.io'.\n\nA match exists between an image and a matchImage when all of the below are true: Both contain the same number of domain parts and each part matches. The URL path of an matchImages must be a prefix of the target image URL path. If the matchImages contains a port, then the port must match in the image as well.\n\nExample values of matchImages: - 123456789.dkr.ecr.us-east-1.amazonaws.com - *.azurecr.io - gcr.io - *.*.registry.io - registry.io:8080/path",
+var map_RelabelConfig = map[string]string{
+ "": "RelabelConfig represents a relabeling rule.",
+ "name": "name is a unique identifier for this relabel configuration. Must contain only alphanumeric characters, hyphens, and underscores. Must be between 1 and 63 characters in length.",
+ "sourceLabels": "sourceLabels specifies which label names to extract from each series for this relabeling rule. The values of these labels are joined together using the configured separator, and the resulting string is then matched against the regular expression. If a referenced label does not exist on a series, Prometheus substitutes an empty string. When omitted, the rule operates without extracting source labels (useful for actions like labelmap). Minimum of 1 and maximum of 10 source labels can be specified, each between 1 and 128 characters. Each entry must be unique. Label names beginning with \"__\" (two underscores) are reserved for internal Prometheus use and are not allowed. Label names SHOULD start with a letter (a-z, A-Z) or underscore (_), followed by zero or more letters, digits (0-9), or underscores for best compatibility. While Prometheus supports UTF-8 characters in label names (since v3.0.0), using the recommended character set ensures better compatibility with the wider ecosystem (tooling, third-party instrumentation, etc.).",
+ "separator": "separator is the character sequence used to join source label values. Common examples: \";\", \",\", \"::\", \"|||\". When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The default value is \";\". Must be between 1 and 5 characters in length when specified.",
+ "regex": "regex is the regular expression to match against the concatenated source label values. Must be a valid RE2 regular expression (https://github.com/google/re2/wiki/Syntax). When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The default value is \"(.*)\" to match everything. Must be between 1 and 1000 characters in length when specified.",
+ "action": "action defines the action to perform on the matched labels and its configuration. Exactly one action-specific configuration must be specified based on the action type.",
}
-func (CRIOCredentialProviderConfigSpec) SwaggerDoc() map[string]string {
- return map_CRIOCredentialProviderConfigSpec
+func (RelabelConfig) SwaggerDoc() map[string]string {
+ return map_RelabelConfig
}
-var map_CRIOCredentialProviderConfigStatus = map[string]string{
- "": "CRIOCredentialProviderConfigStatus defines the observed state of CRIOCredentialProviderConfig",
- "conditions": "conditions represent the latest available observations of the configuration state. When omitted, it indicates that no conditions have been reported yet. The maximum number of conditions is 16. Conditions are stored as a map keyed by condition type, ensuring uniqueness.\n\nExpected condition types include: \"Validated\": indicates whether the matchImages configuration is valid",
+var map_RemoteWriteAuthorization = map[string]string{
+ "": "RemoteWriteAuthorization defines the authorization method for a remote write endpoint. Nested config requirements depend on the type discriminator: Authorization requires authorization, BasicAuth requires basicAuth, OAuth2 requires oauth2, SigV4 requires sigv4, and ServiceAccount forbids all nested configs.",
+ "type": "type specifies the authorization method to use. Allowed values are Authorization, BasicAuth, OAuth2, SigV4, and ServiceAccount.\n\nWhen set to Authorization, credentials are read from a single Secret key. The secret key typically contains a Bearer token. Use the authorization field.\n\nWhen set to BasicAuth, HTTP basic authentication is used; the basicAuth field (username and password from Secrets) must be set.\n\nWhen set to OAuth2, OAuth2 client credentials flow is used; the oauth2 field (clientId, clientSecret, tokenUrl) must be set.\n\nWhen set to SigV4, AWS Signature Version 4 is used for authentication; the sigv4 field must be set.\n\nWhen set to ServiceAccount, the pod's service account token is used for machine identity. No additional field is required; the operator configures the token path.",
+ "authorization": "authorization defines the secret reference containing the authorization credentials (e.g. Bearer token). Required when type is \"Authorization\", and forbidden otherwise. The secret must exist in the openshift-monitoring namespace.",
+ "basicAuth": "basicAuth defines HTTP basic authentication credentials. Required when type is \"BasicAuth\", and forbidden otherwise.",
+ "oauth2": "oauth2 defines OAuth2 client credentials authentication. Required when type is \"OAuth2\", and forbidden otherwise.",
+ "sigv4": "sigv4 defines AWS Signature Version 4 authentication. Required when type is \"SigV4\", and forbidden otherwise.",
}
-func (CRIOCredentialProviderConfigStatus) SwaggerDoc() map[string]string {
- return map_CRIOCredentialProviderConfigStatus
+func (RemoteWriteAuthorization) SwaggerDoc() map[string]string {
+ return map_RemoteWriteAuthorization
}
-var map_ImagePolicy = map[string]string{
- "": "ImagePolicy holds namespace-wide configuration for image signature verification\n\nCompatibility level 4: No compatibility is provided, the API can change at any point for any reason. These capabilities should not be used by applications needing long term support.",
- "metadata": "metadata is the standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata",
- "spec": "spec holds user settable values for configuration",
- "status": "status contains the observed state of the resource.",
+var map_RemoteWriteSpec = map[string]string{
+ "": "RemoteWriteSpec represents configuration for remote write endpoints.",
+ "url": "url is the URL of the remote write endpoint. Must be a valid URL with http or https scheme and a non-empty hostname. Query parameters, fragments, and user information (e.g. user:password@host) are not allowed. Empty string is invalid. Must be between 1 and 2048 characters in length.",
+ "name": "name is a required identifier for this remote write configuration (name is the list key for the remoteWrite list). This name is used in metrics and logging to differentiate remote write queues. Must contain only alphanumeric characters, hyphens, and underscores. Must be between 1 and 63 characters in length.",
+ "messageVersion": "messageVersion defines the Remote Write message's version to use when writing to the endpoint. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The default value is \"V1.0\". When set to \"V1.0\", Prometheus uses the `prometheus.WriteRequest` protobuf message introduced in Remote Write 1.0. When set to \"V2.0\", Prometheus uses the `io.prometheus.write.v2.Request` protobuf message introduced in Remote Write 2.0.",
+ "authorization": "authorization defines the authorization method for the remote write endpoint. When omitted, no authorization is performed. When set, type must be one of Authorization, BasicAuth, OAuth2, SigV4, or ServiceAccount; the corresponding nested config must be set (ServiceAccount has no config).",
+ "headers": "headers specifies the custom HTTP headers to be sent along with each remote write request. Sending custom headers makes the configuration of a proxy in between optional and helps the receiver recognize the given source better. Clients MAY allow users to send custom HTTP headers; they MUST NOT allow users to configure them in such a way as to send reserved headers. Headers set by Prometheus cannot be overwritten. When omitted, no custom headers are sent. Maximum of 50 headers can be specified. Each header name must be unique. Each header name must contain only alphanumeric characters, hyphens, and underscores, and must not be a reserved Prometheus header (Host, Authorization, Content-Encoding, Content-Type, X-Prometheus-Remote-Write-Version, User-Agent, Connection, Keep-Alive, Proxy-Authenticate, Proxy-Authorization, WWW-Authenticate).",
+ "metadataConfig": "metadataConfig configures the sending of series metadata to remote storage. When omitted, no metadata is sent. When set to sendPolicy: Default, metadata is sent using platform-chosen defaults (e.g. send interval 30 seconds). When set to sendPolicy: Custom, metadata is sent using the settings in the custom field (e.g. custom.sendIntervalSeconds).",
+ "proxyUrl": "proxyUrl defines an optional proxy URL. If the cluster-wide proxy is enabled, it replaces the proxyUrl setting. The cluster-wide proxy supports both HTTP and HTTPS proxies, with HTTPS taking precedence. When omitted, no proxy is used. Must be a valid URL with http or https scheme. Must be between 1 and 2048 characters in length.",
+ "queueConfig": "queueConfig allows tuning configuration for remote write queue parameters. When omitted, default queue configuration is used.",
+ "remoteTimeoutSeconds": "remoteTimeoutSeconds defines the timeout in seconds for requests to the remote write endpoint. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. Minimum value is 1 second. Maximum value is 600 seconds (10 minutes).",
+ "exemplarsMode": "exemplarsMode controls whether exemplars are sent via remote write. Valid values are \"Send\", \"DoNotSend\" and omitted. When set to \"Send\", Prometheus is configured to store a maximum of 100,000 exemplars in memory and send them with remote write. Note that this setting only applies to user-defined monitoring. It is not applicable to default in-cluster monitoring. When omitted or set to \"DoNotSend\", exemplars are not sent.",
+ "tlsConfig": "tlsConfig defines TLS authentication settings for the remote write endpoint. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.",
+ "writeRelabelConfigs": "writeRelabelConfigs is a list of relabeling rules to apply before sending data to the remote endpoint. When omitted, no relabeling is performed and all metrics are sent as-is. Minimum of 1 and maximum of 10 relabeling rules can be specified. Each rule must have a unique name.",
}
-func (ImagePolicy) SwaggerDoc() map[string]string {
- return map_ImagePolicy
+func (RemoteWriteSpec) SwaggerDoc() map[string]string {
+ return map_RemoteWriteSpec
}
-var map_ImagePolicyFulcioCAWithRekorRootOfTrust = map[string]string{
- "": "ImagePolicyFulcioCAWithRekorRootOfTrust defines the root of trust based on the Fulcio certificate and the Rekor public key.",
- "fulcioCAData": "fulcioCAData contains inline base64-encoded data for the PEM format fulcio CA. fulcioCAData must be at most 8192 characters.",
- "rekorKeyData": "rekorKeyData contains inline base64-encoded data for the PEM format from the Rekor public key. rekorKeyData must be at most 8192 characters.",
- "fulcioSubject": "fulcioSubject specifies OIDC issuer and the email of the Fulcio authentication configuration.",
+var map_ReplaceActionConfig = map[string]string{
+ "": "ReplaceActionConfig configures the Replace action. Regex is matched against the concatenated source_labels; target_label is set to replacement with match group references (${1}, ${2}, ...) substituted. No replacement if regex does not match.",
+ "targetLabel": "targetLabel is the label name where the replacement result is written. Must be between 1 and 128 characters in length.",
+ "replacement": "replacement is the value written to target_label when regex matches; match group references (${1}, ${2}, ...) are substituted. Required when using the Replace action so the intended behavior is explicit and the platform does not need to apply defaults. Use \"$1\" for the first capture group, \"$2\" for the second, etc. Use an empty string (\"\") to explicitly clear the target label value. Must be between 0 and 255 characters in length.",
}
-func (ImagePolicyFulcioCAWithRekorRootOfTrust) SwaggerDoc() map[string]string {
- return map_ImagePolicyFulcioCAWithRekorRootOfTrust
+func (ReplaceActionConfig) SwaggerDoc() map[string]string {
+ return map_ReplaceActionConfig
}
-var map_ImagePolicyList = map[string]string{
- "": "ImagePolicyList is a list of ImagePolicy resources\n\nCompatibility level 4: No compatibility is provided, the API can change at any point for any reason. These capabilities should not be used by applications needing long term support.",
- "metadata": "metadata is the standard list's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata",
+var map_Retention = map[string]string{
+ "": "Retention configures how long Prometheus retains metrics data and how much storage it can use.",
+ "duration": "duration is an optional field that specifies how long Prometheus retains metrics data. Valid values are Prometheus-style duration strings with unit suffixes y, w, d, h, m, s, or ms (for example, \"15d\", \"24h\", or \"5d1h30m\"). Each unit value must be a positive integer. Composite durations must follow the fixed unit order y, w, d, h, m, s, ms. Must be at least 1 character and at most 64 characters. When set to \"0\", time-based retention is disabled. This is the only supported form for disabling time-based retention; other zero-duration representations such as \"0d\", \"0h\", or \"0y\" are rejected. Prometheus automatically deletes data older than this duration. When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The current default value is `15d`.",
+ "size": "size is an optional field that specifies the maximum storage size that Prometheus can use for data blocks and the write-ahead log (WAL). Valid values are byte-size strings with an optional decimal prefix and a unit suffix B, KB, MB, GB, TB, EB, PB, or their binary equivalents KiB, MiB, GiB, TiB, EiB, PiB (for example, \"500MiB\", \"10GiB\"). The numeric value must be greater than zero. Must be at least 1 character and at most 32 characters. When set to \"0\", no size limit is enforced. This is the only supported form for disabling size-based retention; other zero-size representations such as \"0B\" or \"0MiB\" are rejected. When the limit is reached, Prometheus deletes oldest data first. When omitted, no size limit is enforced and Prometheus uses available PersistentVolume capacity.",
}
-func (ImagePolicyList) SwaggerDoc() map[string]string {
- return map_ImagePolicyList
+func (Retention) SwaggerDoc() map[string]string {
+ return map_Retention
}
-var map_ImagePolicyPKIRootOfTrust = map[string]string{
- "": "ImagePolicyPKIRootOfTrust defines the root of trust based on Root CA(s) and corresponding intermediate certificates.",
- "caRootsData": "caRootsData contains base64-encoded data of a certificate bundle PEM file, which contains one or more CA roots in the PEM format. The total length of the data must not exceed 8192 characters. ",
- "caIntermediatesData": "caIntermediatesData contains base64-encoded data of a certificate bundle PEM file, which contains one or more intermediate certificates in the PEM format. The total length of the data must not exceed 8192 characters. caIntermediatesData requires caRootsData to be set. ",
- "pkiCertificateSubject": "pkiCertificateSubject defines the requirements imposed on the subject to which the certificate was issued.",
+var map_SecretKeySelector = map[string]string{
+ "": "SecretKeySelector selects a key of a Secret in the `openshift-monitoring` namespace.",
+ "name": "name is the name of the secret in the `openshift-monitoring` namespace to select from. Must be a valid Kubernetes secret name (lowercase alphanumeric, '-' or '.', start/end with alphanumeric). Must be between 1 and 253 characters in length.",
+ "key": "key is the key of the secret to select from. Must consist of alphanumeric characters, '-', '_', or '.'. Must be between 1 and 253 characters in length.",
}
-func (ImagePolicyPKIRootOfTrust) SwaggerDoc() map[string]string {
- return map_ImagePolicyPKIRootOfTrust
+func (SecretKeySelector) SwaggerDoc() map[string]string {
+ return map_SecretKeySelector
}
-var map_ImagePolicyPublicKeyRootOfTrust = map[string]string{
- "": "ImagePolicyPublicKeyRootOfTrust defines the root of trust based on a sigstore public key.",
- "keyData": "keyData contains inline base64-encoded data for the PEM format public key. KeyData must be at most 8192 characters.",
- "rekorKeyData": "rekorKeyData contains inline base64-encoded data for the PEM format from the Rekor public key. rekorKeyData must be at most 8192 characters.",
+var map_Sigv4 = map[string]string{
+ "": "Sigv4 defines AWS Signature Version 4 authentication settings. At least one of region, accessKey/secretKey, profile, or roleArn must be set so the platform can perform authentication.",
+ "region": "region is the AWS region. When omitted, the region is derived from the environment or instance metadata. Must be between 1 and 128 characters.",
+ "accessKey": "accessKey defines the secret reference containing the AWS access key ID. The secret must exist in the openshift-monitoring namespace. When omitted, the access key is derived from the environment or instance metadata.",
+ "secretKey": "secretKey defines the secret reference containing the AWS secret access key. The secret must exist in the openshift-monitoring namespace. When omitted, the secret key is derived from the environment or instance metadata.",
+ "profile": "profile is the named AWS profile used to authenticate. When omitted, the default profile is used. Must be between 1 and 128 characters.",
+ "roleArn": "roleArn is the AWS Role ARN, an alternative to using AWS API keys. When omitted, API keys are used for authentication. Must be a valid AWS ARN format (e.g., \"arn:aws:iam::123456789012:role/MyRole\"). Must be between 1 and 512 characters.",
}
-func (ImagePolicyPublicKeyRootOfTrust) SwaggerDoc() map[string]string {
- return map_ImagePolicyPublicKeyRootOfTrust
+func (Sigv4) SwaggerDoc() map[string]string {
+ return map_Sigv4
}
-var map_ImagePolicySpec = map[string]string{
- "": "ImagePolicySpec is the specification of the ImagePolicy CRD.",
- "scopes": "scopes defines the list of image identities assigned to a policy. Each item refers to a scope in a registry implementing the \"Docker Registry HTTP API V2\". Scopes matching individual images are named Docker references in the fully expanded form, either using a tag or digest. For example, docker.io/library/busybox:latest (not busybox:latest). More general scopes are prefixes of individual-image scopes, and specify a repository (by omitting the tag or digest), a repository namespace, or a registry host (by only specifying the host name and possibly a port number) or a wildcard expression starting with `*.`, for matching all subdomains (not including a port number). Wildcards are only supported for subdomain matching, and may not be used in the middle of the host, i.e. *.example.com is a valid case, but example*.*.com is not. If multiple scopes match a given image, only the policy requirements for the most specific scope apply. The policy requirements for more general scopes are ignored. In addition to setting a policy appropriate for your own deployed applications, make sure that a policy on the OpenShift image repositories quay.io/openshift-release-dev/ocp-release, quay.io/openshift-release-dev/ocp-v4.0-art-dev (or on a more general scope) allows deployment of the OpenShift images required for cluster operation. If a scope is configured in both the ClusterImagePolicy and the ImagePolicy, or if the scope in ImagePolicy is nested under one of the scopes from the ClusterImagePolicy, only the policy from the ClusterImagePolicy will be applied. For additional details about the format, please refer to the document explaining the docker transport field, which can be found at: https://github.com/containers/image/blob/main/docs/containers-policy.json.5.md#docker",
- "policy": "policy contains configuration to allow scopes to be verified, and defines how images not matching the verification policy will be treated.",
+var map_TLSConfig = map[string]string{
+ "": "TLSConfig represents TLS configuration for Alertmanager connections. At least one TLS configuration option must be specified. For mutual TLS (mTLS), both cert and key must be specified together, or both omitted.",
+ "ca": "ca is an optional CA certificate to use for TLS connections. When omitted, the system's default CA bundle is used.",
+ "cert": "cert is an optional client certificate to use for mutual TLS connections. When omitted, no client certificate is presented.",
+ "key": "key is an optional client key to use for mutual TLS connections. When omitted, no client key is used.",
+ "serverName": "serverName is an optional server name to use for TLS connections. When specified, must be a valid DNS subdomain as per RFC 1123. When omitted, the server name is derived from the URL. Must be between 1 and 253 characters in length.",
+ "certificateVerification": "certificateVerification determines the policy for TLS certificate verification. Allowed values are \"Verify\" (performs certificate verification, secure) and \"SkipVerify\" (skips verification, insecure). When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. The default value is \"Verify\".",
}
-func (ImagePolicySpec) SwaggerDoc() map[string]string {
- return map_ImagePolicySpec
+func (TLSConfig) SwaggerDoc() map[string]string {
+ return map_TLSConfig
}
-var map_ImagePolicyStatus = map[string]string{
- "conditions": "conditions provide details on the status of this API Resource.",
+var map_TelemeterClientConfig = map[string]string{
+ "": "TelemeterClientConfig provides configuration options for the Telemeter Client component that runs in the `openshift-monitoring` namespace. The Telemeter Client collects selected monitoring metrics and forwards them to Red Hat for telemetry purposes. At least one field must be specified.",
+ "nodeSelector": "nodeSelector defines the nodes on which the Pods are scheduled. nodeSelector is optional.\n\nWhen omitted, this means the user has no opinion and the platform is left to choose reasonable defaults. These defaults are subject to change over time. The current default value is `kubernetes.io/os: linux`. When specified, nodeSelector must contain at least 1 entry and must not contain more than 10 entries.",
+ "resources": "resources defines the compute resource requests and limits for the Telemeter Client container. This includes CPU, memory and HugePages constraints to help control scheduling and resource usage. When not specified, defaults are used by the platform. Requests cannot exceed limits. This field is optional. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ This is a simplified API that maps to Kubernetes ResourceRequirements. The current default values are:\n resources:\n - name: cpu\n request: 1m\n limit: null\n - name: memory\n request: 40Mi\n limit: null\nMaximum length for this list is 5. Minimum length for this list is 1. Each resource name must be unique within this list.",
+ "tolerations": "tolerations defines tolerations for the pods. tolerations is optional.\n\nWhen omitted, this means the user has no opinion and the platform is left to choose reasonable defaults. These defaults are subject to change over time. Defaults are empty/unset. Maximum length for this list is 10. Minimum length for this list is 1.",
+ "topologySpreadConstraints": "topologySpreadConstraints defines rules for how Telemeter Client Pods should be distributed across topology domains such as zones, nodes, or other user-defined labels. topologySpreadConstraints is optional. This helps improve high availability and resource efficiency by avoiding placing too many replicas in the same failure domain.\n\nWhen omitted, this means no opinion and the platform is left to choose a default, which is subject to change over time. This field maps directly to the `topologySpreadConstraints` field in the Pod spec. Default is empty list. Maximum length for this list is 10. Minimum length for this list is 1. Entries must have unique topologyKey and whenUnsatisfiable pairs.",
}
-func (ImagePolicyStatus) SwaggerDoc() map[string]string {
- return map_ImagePolicyStatus
+func (TelemeterClientConfig) SwaggerDoc() map[string]string {
+ return map_TelemeterClientConfig
}
-var map_ImageSigstoreVerificationPolicy = map[string]string{
- "": "ImageSigstoreVerificationPolicy defines the verification policy for the items in the scopes list.",
- "rootOfTrust": "rootOfTrust specifies the root of trust for the policy.",
- "signedIdentity": "signedIdentity specifies what image identity the signature claims about the image. The required matchPolicy field specifies the approach used in the verification process to verify the identity in the signature and the actual image identity, the default matchPolicy is \"MatchRepoDigestOrExact\".",
+var map_ThanosQuerierConfig = map[string]string{
+ "": "ThanosQuerierConfig provides configuration options for the Thanos Querier component that runs in the `openshift-monitoring` namespace. At least one field must be specified; an empty thanosQuerierConfig object is not allowed.",
+ "logLevel": "logLevel defines the verbosity of logs emitted by Thanos Querier. logLevel is optional. Allowed values are Error, Warn, Info, and Debug. When set to Error, only errors will be logged. When set to Warn, both warnings and errors will be logged. When set to Info, general information, warnings, and errors will all be logged. When set to Debug, detailed debugging information will be logged. When omitted, this means no opinion and the platform is left to choose a reasonable default, that is subject to change over time. The current default value is `Info`.",
+ "requestLogging": "requestLogging configures request logging for Thanos Querier. requestLogging is optional. When provided, the policy field within is required. When omitted, this means no opinion and the platform is left to choose a reasonable default, that is subject to change over time. The current default behavior is to not log any requests.",
+ "crossOriginRequestPolicy": "crossOriginRequestPolicy configures the CORS (Cross-Origin Resource Sharing) policy for Thanos Querier's HTTP endpoints. crossOriginRequestPolicy is optional. Valid values are \"AllowAll\" and \"DenyAll\". When set to \"AllowAll\", CORS headers are added to responses, allowing cross-origin requests from any domain. When set to \"DenyAll\", no CORS headers are added and cross-origin requests are rejected by the browser. When omitted, this means no opinion and the platform is left to choose a reasonable default, that is subject to change over time. The current default value is \"DenyAll\".",
+ "nodeSelector": "nodeSelector defines the nodes on which the Pods are scheduled. nodeSelector is optional.\n\nWhen omitted, this means the user has no opinion and the platform is left to choose reasonable defaults. These defaults are subject to change over time. The current default value is `kubernetes.io/os: linux`. When specified, nodeSelector must contain at least 1 entry and must not contain more than 10 entries.",
+ "resources": "resources defines the compute resource requests and limits for the Thanos Querier container. resources is optional.\n\nWhen omitted, this means the user has no opinion and the platform is left to choose reasonable defaults. These defaults are subject to change over time. Requests cannot exceed limits. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ This is a simplified API that maps to Kubernetes ResourceRequirements. The current default values are:\n resources:\n - name: cpu\n request: 5m\n - name: memory\n request: 12Mi\nMaximum length for this list is 5. Minimum length for this list is 1. Each resource name must be unique within this list.",
+ "tolerations": "tolerations defines tolerations for the pods. tolerations is optional.\n\nWhen omitted, this means the user has no opinion and the platform is left to choose reasonable defaults. These defaults are subject to change over time. Defaults are empty/unset. Maximum length for this list is 10. Minimum length for this list is 1.",
+ "topologySpreadConstraints": "topologySpreadConstraints defines rules for how Thanos Querier Pods should be distributed across topology domains such as zones, nodes, or other user-defined labels. topologySpreadConstraints is optional. This helps improve high availability and resource efficiency by avoiding placing too many replicas in the same failure domain.\n\nWhen omitted, this means no opinion and the platform is left to choose a default, which is subject to change over time. This field maps directly to the `topologySpreadConstraints` field in the Pod spec. Defaults are empty/unset. Maximum length for this list is 10. Minimum length for this list is 1. Entries must have unique topologyKey and whenUnsatisfiable pairs.",
}
-func (ImageSigstoreVerificationPolicy) SwaggerDoc() map[string]string {
- return map_ImageSigstoreVerificationPolicy
+func (ThanosQuerierConfig) SwaggerDoc() map[string]string {
+ return map_ThanosQuerierConfig
}
-var map_PKICertificateSubject = map[string]string{
- "": "PKICertificateSubject defines the requirements imposed on the subject to which the certificate was issued.",
- "email": "email specifies the expected email address imposed on the subject to which the certificate was issued, and must match the email address listed in the Subject Alternative Name (SAN) field of the certificate. The email should be a valid email address and at most 320 characters in length.",
- "hostname": "hostname specifies the expected hostname imposed on the subject to which the certificate was issued, and it must match the hostname listed in the Subject Alternative Name (SAN) DNS field of the certificate. The hostname should be a valid dns 1123 subdomain name, optionally prefixed by '*.', and at most 253 characters in length. It should consist only of lowercase alphanumeric characters, hyphens, periods and the optional preceding asterisk.",
+var map_ThanosQuerierRequestLoggingConfig = map[string]string{
+ "": "ThanosQuerierRequestLoggingConfig configures request logging for Thanos Querier.",
+ "policy": "policy determines which HTTP and gRPC requests are logged by Thanos Querier. Valid values are \"AllRequests\" and \"NoRequests\". When set to \"AllRequests\", every request received by Thanos Querier is logged with method, path, and response status. The log level for request logs is derived from the logLevel field. When set to \"NoRequests\", request logging is turned off.",
}
-func (PKICertificateSubject) SwaggerDoc() map[string]string {
- return map_PKICertificateSubject
+func (ThanosQuerierRequestLoggingConfig) SwaggerDoc() map[string]string {
+ return map_ThanosQuerierRequestLoggingConfig
}
-var map_PolicyFulcioSubject = map[string]string{
- "": "PolicyFulcioSubject defines the OIDC issuer and the email of the Fulcio authentication configuration.",
- "oidcIssuer": "oidcIssuer contains the expected OIDC issuer. It will be verified that the Fulcio-issued certificate contains a (Fulcio-defined) certificate extension pointing at this OIDC issuer URL. When Fulcio issues certificates, it includes a value based on an URL inside the client-provided ID token. Example: \"https://expected.OIDC.issuer/\"",
- "signedEmail": "signedEmail holds the email address the the Fulcio certificate is issued for. Example: \"expected-signing-user@example.com\"",
+var map_UppercaseActionConfig = map[string]string{
+ "": "UppercaseActionConfig configures the Uppercase action. Maps the concatenated source_labels to their upper case and writes to target_label. Requires Prometheus >= v2.36.0.",
+ "targetLabel": "targetLabel is the label name where the upper-cased value is written. Must be between 1 and 128 characters in length.",
}
-func (PolicyFulcioSubject) SwaggerDoc() map[string]string {
- return map_PolicyFulcioSubject
+func (UppercaseActionConfig) SwaggerDoc() map[string]string {
+ return map_UppercaseActionConfig
}
-var map_PolicyIdentity = map[string]string{
- "": "PolicyIdentity defines image identity the signature claims about the image. When omitted, the default matchPolicy is \"MatchRepoDigestOrExact\".",
- "matchPolicy": "matchPolicy sets the type of matching to be used. Valid values are \"MatchRepoDigestOrExact\", \"MatchRepository\", \"ExactRepository\", \"RemapIdentity\". When omitted, the default value is \"MatchRepoDigestOrExact\". If set matchPolicy to ExactRepository, then the exactRepository must be specified. If set matchPolicy to RemapIdentity, then the remapIdentity must be specified. \"MatchRepoDigestOrExact\" means that the identity in the signature must be in the same repository as the image identity if the image identity is referenced by a digest. Otherwise, the identity in the signature must be the same as the image identity. \"MatchRepository\" means that the identity in the signature must be in the same repository as the image identity. \"ExactRepository\" means that the identity in the signature must be in the same repository as a specific identity specified by \"repository\". \"RemapIdentity\" means that the signature must be in the same as the remapped image identity. Remapped image identity is obtained by replacing the \"prefix\" with the specified “signedPrefix” if the the image identity matches the specified remapPrefix.",
- "exactRepository": "exactRepository is required if matchPolicy is set to \"ExactRepository\".",
- "remapIdentity": "remapIdentity is required if matchPolicy is set to \"RemapIdentity\".",
+var map_UserDefinedMonitoring = map[string]string{
+ "": "UserDefinedMonitoring config for user-defined projects.",
+ "mode": "mode defines the different configurations of UserDefinedMonitoring Valid values are Disabled and NamespaceIsolated Disabled disables monitoring for user-defined projects. This restricts the default monitoring stack, installed in the openshift-monitoring project, to monitor only platform namespaces, which prevents any custom monitoring configurations or resources from being applied to user-defined namespaces. NamespaceIsolated enables monitoring for user-defined projects with namespace-scoped tenancy. This ensures that metrics, alerts, and monitoring data are isolated at the namespace level. The current default value is `Disabled`.",
}
-func (PolicyIdentity) SwaggerDoc() map[string]string {
- return map_PolicyIdentity
+func (UserDefinedMonitoring) SwaggerDoc() map[string]string {
+ return map_UserDefinedMonitoring
+}
+
+var map_CRIOCredentialProviderConfig = map[string]string{
+ "": "CRIOCredentialProviderConfig holds cluster-wide singleton resource configurations for CRI-O credential provider, the name of this instance is \"cluster\". CRI-O credential provider is a binary shipped with CRI-O that provides a way to obtain container image pull credentials from external sources. For example, it can be used to fetch mirror registry credentials from secrets resources in the cluster within the same namespace the pod will be running in. CRIOCredentialProviderConfig configuration specifies the pod image sources registries that should trigger the CRI-O credential provider execution, which will resolve the CRI-O mirror configurations and obtain the necessary credentials for pod creation. Note: Configuration changes will only take effect after the kubelet restarts, which is automatically managed by the cluster during rollout.\n\nThe resource is a singleton named \"cluster\".\n\nCompatibility level 4: No compatibility is provided, the API can change at any point for any reason. These capabilities should not be used by applications needing long term support.",
+ "metadata": "metadata is the standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata",
+ "spec": "spec defines the desired configuration of the CRI-O Credential Provider. This field is required and must be provided when creating the resource.",
+ "status": "status represents the current state of the CRIOCredentialProviderConfig. When omitted or nil, it indicates that the status has not yet been set by the controller. The controller will populate this field with validation conditions and operational state.",
}
-var map_PolicyMatchExactRepository = map[string]string{
- "repository": "repository is the reference of the image identity to be matched. The value should be a repository name (by omitting the tag or digest) in a registry implementing the \"Docker Registry HTTP API V2\". For example, docker.io/library/busybox",
+func (CRIOCredentialProviderConfig) SwaggerDoc() map[string]string {
+ return map_CRIOCredentialProviderConfig
+}
+
+var map_CRIOCredentialProviderConfigList = map[string]string{
+ "": "CRIOCredentialProviderConfigList contains a list of CRIOCredentialProviderConfig resources\n\nCompatibility level 4: No compatibility is provided, the API can change at any point for any reason. These capabilities should not be used by applications needing long term support.",
+ "metadata": "metadata is the standard list's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata",
}
-func (PolicyMatchExactRepository) SwaggerDoc() map[string]string {
- return map_PolicyMatchExactRepository
+func (CRIOCredentialProviderConfigList) SwaggerDoc() map[string]string {
+ return map_CRIOCredentialProviderConfigList
}
-var map_PolicyMatchRemapIdentity = map[string]string{
- "prefix": "prefix is the prefix of the image identity to be matched. If the image identity matches the specified prefix, that prefix is replaced by the specified “signedPrefix” (otherwise it is used as unchanged and no remapping takes place). This useful when verifying signatures for a mirror of some other repository namespace that preserves the vendor’s repository structure. The prefix and signedPrefix values can be either host[:port] values (matching exactly the same host[:port], string), repository namespaces, or repositories (i.e. they must not contain tags/digests), and match as prefixes of the fully expanded form. For example, docker.io/library/busybox (not busybox) to specify that single repository, or docker.io/library (not an empty string) to specify the parent namespace of docker.io/library/busybox.",
- "signedPrefix": "signedPrefix is the prefix of the image identity to be matched in the signature. The format is the same as \"prefix\". The values can be either host[:port] values (matching exactly the same host[:port], string), repository namespaces, or repositories (i.e. they must not contain tags/digests), and match as prefixes of the fully expanded form. For example, docker.io/library/busybox (not busybox) to specify that single repository, or docker.io/library (not an empty string) to specify the parent namespace of docker.io/library/busybox.",
+var map_CRIOCredentialProviderConfigSpec = map[string]string{
+ "": "CRIOCredentialProviderConfigSpec defines the desired configuration of the CRI-O Credential Provider.",
+ "matchImages": "matchImages is a list of string patterns used to determine whether the CRI-O credential provider should be invoked for a given image. This list is passed to the kubelet CredentialProviderConfig, and if any pattern matches the requested image, CRI-O credential provider will be invoked to obtain credentials for pulling that image or its mirrors. Depending on the platform, the CRI-O credential provider may be installed alongside an existing platform specific provider. Conflicts between the existing platform specific provider image match configuration and this list will be handled by the following precedence rule: credentials from built-in kubelet providers (e.g., ECR, GCR, ACR) take precedence over those from the CRIOCredentialProviderConfig when both match the same image. To avoid uncertainty, it is recommended to avoid configuring your private image patterns to overlap with existing platform specific provider config(e.g., the entries from https://github.com/openshift/machine-config-operator/blob/main/templates/common/aws/files/etc-kubernetes-credential-providers-ecr-credential-provider.yaml). You can check the resource's Status conditions to see if any entries were ignored due to exact matches with known built-in provider patterns.\n\nThis field is optional, the items of the list must contain between 1 and 50 entries. The list is treated as a set, so duplicate entries are not allowed.\n\nFor more details, see: https://kubernetes.io/docs/tasks/administer-cluster/kubelet-credential-provider/ https://github.com/cri-o/crio-credential-provider#architecture\n\nEach entry in matchImages is a pattern which can optionally contain a port and a path. Each entry must be no longer than 512 characters. Wildcards ('*') are supported for full subdomain labels, such as '*.k8s.io' or 'k8s.*.io', and for top-level domains, such as 'k8s.*' (which matches 'k8s.io' or 'k8s.net'). A global wildcard '*' (matching any domain) is not allowed. Wildcards may replace an entire hostname label (e.g., *.example.com), but they cannot appear within a label (e.g., f*oo.example.com) and are not allowed in the port or path. For example, 'example.*.com' is valid, but 'exa*mple.*.com' is not. Each wildcard matches only a single domain label, so '*.io' does **not** match '*.k8s.io'.\n\nA match exists between an image and a matchImage when all of the below are true: Both contain the same number of domain parts and each part matches. The URL path of an matchImages must be a prefix of the target image URL path. If the matchImages contains a port, then the port must match in the image as well.\n\nExample values of matchImages: - 123456789.dkr.ecr.us-east-1.amazonaws.com - *.azurecr.io - gcr.io - *.*.registry.io - registry.io:8080/path",
}
-func (PolicyMatchRemapIdentity) SwaggerDoc() map[string]string {
- return map_PolicyMatchRemapIdentity
+func (CRIOCredentialProviderConfigSpec) SwaggerDoc() map[string]string {
+ return map_CRIOCredentialProviderConfigSpec
}
-var map_PolicyRootOfTrust = map[string]string{
- "": "PolicyRootOfTrust defines the root of trust based on the selected policyType.",
- "policyType": "policyType serves as the union's discriminator. Users are required to assign a value to this field, choosing one of the policy types that define the root of trust. \"PublicKey\" indicates that the policy relies on a sigstore publicKey and may optionally use a Rekor verification. \"FulcioCAWithRekor\" indicates that the policy is based on the Fulcio certification and incorporates a Rekor verification. \"PKI\" indicates that the policy is based on the certificates from Bring Your Own Public Key Infrastructure (BYOPKI). This value is enabled by turning on the SigstoreImageVerificationPKI feature gate.",
- "publicKey": "publicKey defines the root of trust based on a sigstore public key.",
- "fulcioCAWithRekor": "fulcioCAWithRekor defines the root of trust based on the Fulcio certificate and the Rekor public key. For more information about Fulcio and Rekor, please refer to the document at: https://github.com/sigstore/fulcio and https://github.com/sigstore/rekor",
- "pki": "pki defines the root of trust based on Bring Your Own Public Key Infrastructure (BYOPKI) Root CA(s) and corresponding intermediate certificates.",
+var map_CRIOCredentialProviderConfigStatus = map[string]string{
+ "": "CRIOCredentialProviderConfigStatus defines the observed state of CRIOCredentialProviderConfig",
+ "conditions": "conditions represent the latest available observations of the configuration state. When omitted, it indicates that no conditions have been reported yet. The maximum number of conditions is 16. Conditions are stored as a map keyed by condition type, ensuring uniqueness.\n\nExpected condition types include: \"Validated\": indicates whether the matchImages configuration is valid",
}
-func (PolicyRootOfTrust) SwaggerDoc() map[string]string {
- return map_PolicyRootOfTrust
+func (CRIOCredentialProviderConfigStatus) SwaggerDoc() map[string]string {
+ return map_CRIOCredentialProviderConfigStatus
}
var map_GatherConfig = map[string]string{
diff --git a/vendor/github.com/openshift/api/config/v1alpha2/doc.go b/vendor/github.com/openshift/api/config/v1alpha2/doc.go
index 15ac6b4972..5777844e2a 100644
--- a/vendor/github.com/openshift/api/config/v1alpha2/doc.go
+++ b/vendor/github.com/openshift/api/config/v1alpha2/doc.go
@@ -1,6 +1,7 @@
// +k8s:deepcopy-gen=package,register
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.config.v1alpha2
// +groupName=config.openshift.io
// Package v1alpha2 is the v1alpha2 version of the API.
diff --git a/vendor/github.com/openshift/api/config/v1alpha2/zz_generated.model_name.go b/vendor/github.com/openshift/api/config/v1alpha2/zz_generated.model_name.go
new file mode 100644
index 0000000000..d05e8558c7
--- /dev/null
+++ b/vendor/github.com/openshift/api/config/v1alpha2/zz_generated.model_name.go
@@ -0,0 +1,61 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1alpha2
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Custom) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha2.Custom"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GatherConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha2.GatherConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GathererConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha2.GathererConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Gatherers) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha2.Gatherers"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in InsightsDataGather) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha2.InsightsDataGather"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in InsightsDataGatherList) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha2.InsightsDataGatherList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in InsightsDataGatherSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha2.InsightsDataGatherSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in InsightsDataGatherStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha2.InsightsDataGatherStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PersistentVolumeClaimReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha2.PersistentVolumeClaimReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PersistentVolumeConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha2.PersistentVolumeConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Storage) OpenAPIModelName() string {
+ return "com.github.openshift.api.config.v1alpha2.Storage"
+}
diff --git a/vendor/github.com/openshift/api/console/v1/doc.go b/vendor/github.com/openshift/api/console/v1/doc.go
index c08b5b519b..f6c62bd19b 100644
--- a/vendor/github.com/openshift/api/console/v1/doc.go
+++ b/vendor/github.com/openshift/api/console/v1/doc.go
@@ -1,6 +1,7 @@
// +k8s:deepcopy-gen=package,register
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.console.v1
// +groupName=console.openshift.io
// Package v1 is the v1 version of the API.
diff --git a/vendor/github.com/openshift/api/console/v1/types_console_plugin.go b/vendor/github.com/openshift/api/console/v1/types_console_plugin.go
index 0160a4a242..c63db50d52 100644
--- a/vendor/github.com/openshift/api/console/v1/types_console_plugin.go
+++ b/vendor/github.com/openshift/api/console/v1/types_console_plugin.go
@@ -90,7 +90,6 @@ type ConsolePluginSpec struct {
// OpenShift web console server CSP response header:
// Content-Security-Policy: default-src 'self'; base-uri 'self'; script-src 'self' https://script1.com/ https://script2.com/ https://script3.com/; font-src 'self' https://font1.com/ https://font2.com/; img-src 'self' https://img1.com/; style-src 'self'; frame-src 'none'; object-src 'none'
//
- // +openshift:enable:FeatureGate=ConsolePluginContentSecurityPolicy
// +kubebuilder:validation:MaxItems=5
// +kubebuilder:validation:XValidation:rule="self.map(x, x.values.map(y, y.size()).sum()).sum() < 8192",message="the total combined size of values of all directives must not exceed 8192 (8kb)"
// +listType=map
diff --git a/vendor/github.com/openshift/api/console/v1/zz_generated.featuregated-crd-manifests.yaml b/vendor/github.com/openshift/api/console/v1/zz_generated.featuregated-crd-manifests.yaml
index caa676e691..26524d0a17 100644
--- a/vendor/github.com/openshift/api/console/v1/zz_generated.featuregated-crd-manifests.yaml
+++ b/vendor/github.com/openshift/api/console/v1/zz_generated.featuregated-crd-manifests.yaml
@@ -137,8 +137,7 @@ consoleplugins.console.openshift.io:
CRDName: consoleplugins.console.openshift.io
Capability: Console
Category: ""
- FeatureGates:
- - ConsolePluginContentSecurityPolicy
+ FeatureGates: []
FilenameOperatorName: ""
FilenameOperatorOrdering: "90"
FilenameRunLevel: ""
diff --git a/vendor/github.com/openshift/api/console/v1/zz_generated.model_name.go b/vendor/github.com/openshift/api/console/v1/zz_generated.model_name.go
new file mode 100644
index 0000000000..d5c9c2bc52
--- /dev/null
+++ b/vendor/github.com/openshift/api/console/v1/zz_generated.model_name.go
@@ -0,0 +1,226 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ApplicationMenuSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ApplicationMenuSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CLIDownloadLink) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.CLIDownloadLink"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleCLIDownload) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleCLIDownload"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleCLIDownloadList) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleCLIDownloadList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleCLIDownloadSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleCLIDownloadSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleExternalLogLink) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleExternalLogLink"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleExternalLogLinkList) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleExternalLogLinkList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleExternalLogLinkSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleExternalLogLinkSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleLink) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleLink"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleLinkList) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleLinkList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleLinkSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleLinkSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleNotification) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleNotification"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleNotificationList) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleNotificationList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleNotificationSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleNotificationSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsolePlugin) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsolePlugin"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsolePluginBackend) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsolePluginBackend"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsolePluginCSP) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsolePluginCSP"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsolePluginI18n) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsolePluginI18n"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsolePluginList) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsolePluginList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsolePluginProxy) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsolePluginProxy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsolePluginProxyEndpoint) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsolePluginProxyEndpoint"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsolePluginProxyServiceConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsolePluginProxyServiceConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsolePluginService) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsolePluginService"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsolePluginSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsolePluginSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleQuickStart) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleQuickStart"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleQuickStartList) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleQuickStartList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleQuickStartSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleQuickStartSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleQuickStartTask) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleQuickStartTask"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleQuickStartTaskReview) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleQuickStartTaskReview"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleQuickStartTaskSummary) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleQuickStartTaskSummary"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleSample) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleSample"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleSampleContainerImportSource) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleSampleContainerImportSource"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleSampleContainerImportSourceService) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleSampleContainerImportSourceService"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleSampleGitImportSource) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleSampleGitImportSource"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleSampleGitImportSourceRepository) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleSampleGitImportSourceRepository"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleSampleGitImportSourceService) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleSampleGitImportSourceService"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleSampleList) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleSampleList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleSampleSource) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleSampleSource"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleSampleSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleSampleSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleYAMLSample) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleYAMLSample"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleYAMLSampleList) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleYAMLSampleList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleYAMLSampleSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.ConsoleYAMLSampleSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Link) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.Link"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NamespaceDashboardSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.console.v1.NamespaceDashboardSpec"
+}
diff --git a/vendor/github.com/openshift/api/envtest-releases.yaml b/vendor/github.com/openshift/api/envtest-releases.yaml
index e495e02796..4705c327e0 100644
--- a/vendor/github.com/openshift/api/envtest-releases.yaml
+++ b/vendor/github.com/openshift/api/envtest-releases.yaml
@@ -1,4 +1,30 @@
releases:
+ v1.28.15:
+ envtest-v1.28.15-darwin-amd64.tar.gz:
+ hash: 79e04e7e264e6907da73d27c04d50be7bfa702b059e66f21331c9c8e16daa6ff960e750c1910804b7aa2a5bd79488a5bd082b76a7bab003e613a2cdbb2a8b80d
+ selfLink: https://storage.googleapis.com/openshift-kubebuilder-tools/envtest-v1.28.15-darwin-amd64.tar.gz
+ envtest-v1.28.15-darwin-arm64.tar.gz:
+ hash: 9646d169cf5161793ded60fa2ffde705d8fdde7c7c77833be9a77909f5804b909f28d56b2b0b93bd200d8057db3e37da9fe1683368ae38777ea62609135d0b4d
+ selfLink: https://storage.googleapis.com/openshift-kubebuilder-tools/envtest-v1.28.15-darwin-arm64.tar.gz
+ envtest-v1.28.15-linux-amd64.tar.gz:
+ hash: bc7e3deabbb3c7ee5e572e1392041af9d2fa40a51eb88dcabdaf57ff2a476e81efbd837a87f1f0849a5083dcb7c0b4b2fc16107da4cf3308805eee377fb383c1
+ selfLink: https://storage.googleapis.com/openshift-kubebuilder-tools/envtest-v1.28.15-linux-amd64.tar.gz
+ envtest-v1.28.15-linux-arm64.tar.gz:
+ hash: 17ec8d5f7de118b66d1621d8b25b4f0a891e4a641d5e845d14c0da4cb2e258b6bf788fe6b5334b27beb12d9e67f7c8f2c2ded6023bf9a7e79ac3b483b8cdfcc2
+ selfLink: https://storage.googleapis.com/openshift-kubebuilder-tools/envtest-v1.28.15-linux-arm64.tar.gz
+ v1.29.7:
+ envtest-v1.29.7-darwin-amd64.tar.gz:
+ hash: 4a97f9162ee882632aafda20e562dfb4011879f9ec6c8ffa4922e566933fc35292171cc837b50860e2e91238d820931a1fb8c3280541a180f6e9057178c71889
+ selfLink: https://storage.googleapis.com/openshift-kubebuilder-tools/envtest-v1.29.7-darwin-amd64.tar.gz
+ envtest-v1.29.7-darwin-arm64.tar.gz:
+ hash: e810e04c14b1bba79c90c755ecb8b13094132a86339e78d1fe39029b9825b90b663d538b29d6ab4d905c22728efdf278881ee3f434f2215bc77157dee90a2bde
+ selfLink: https://storage.googleapis.com/openshift-kubebuilder-tools/envtest-v1.29.7-darwin-arm64.tar.gz
+ envtest-v1.29.7-linux-amd64.tar.gz:
+ hash: 91dcf683c95541691b8b9fdd332b0d3df56f8969b57c14797e990b9861ad71b2954f402913b5579f6afb99dce19817ba49542e2e276c7f70aeeb857a5ec1d57c
+ selfLink: https://storage.googleapis.com/openshift-kubebuilder-tools/envtest-v1.29.7-linux-amd64.tar.gz
+ envtest-v1.29.7-linux-arm64.tar.gz:
+ hash: 912333dee15e9cc068ebc5ef25591e16b9732cc70c23435efa72af352cffa9c25236d3982db910bd3a06172e9d57fc0d50585996f17c66ae1b80f0e2d3ef37b5
+ selfLink: https://storage.googleapis.com/openshift-kubebuilder-tools/envtest-v1.29.7-linux-arm64.tar.gz
v1.30.3:
envtest-v1.30.3-darwin-amd64.tar.gz:
hash: 81ab2ad5841522976d9a5fc58642b745cf308230b0f2e634acfb2d5c8f288ef837f7b82144a5e91db607d86885101e06dd473a68bcac0d71be2297edc4aaa92e
@@ -77,3 +103,29 @@ releases:
envtest-v1.34.1-linux-arm64.tar.gz:
hash: e2ee7e47ceeba56624fd869922ab9851200482ef835c09fe3dd57c9806a992a7e1f56641906510ebb095514953aa8a3af68d45a82be45b94981a50e894ac6e42
selfLink: https://storage.googleapis.com/openshift-kubebuilder-tools/envtest-v1.34.1-linux-arm64.tar.gz
+ v1.35.1:
+ envtest-v1.35.1-darwin-amd64.tar.gz:
+ hash: 8b788ca564d0d2d49000b572b9c83a87f71978b7dcbb0c969dde5bf8923869dcb5860b8f905af9a3772431ba7e575c4215d1bcfa5d2857bd8db440272f252ddd
+ selfLink: https://storage.googleapis.com/openshift-kubebuilder-tools/envtest-v1.35.1-darwin-amd64.tar.gz
+ envtest-v1.35.1-darwin-arm64.tar.gz:
+ hash: d650d7a96c69efdc7321579d597b9dbd9ef71df5ea1e0f00815edb31eb0f4a40599fe223b9d0f2a114be32657ff842136a3ab65e646b08a0fce50d6871bcec71
+ selfLink: https://storage.googleapis.com/openshift-kubebuilder-tools/envtest-v1.35.1-darwin-arm64.tar.gz
+ envtest-v1.35.1-linux-amd64.tar.gz:
+ hash: 70e4e66f842d53cce174a3499feb04e0493ada374148c687da4e7ddc0e20e10dd6fa5e2cd765bd80b7d3dca3cd8388460503a0335e15f71212b333386fb3c2b1
+ selfLink: https://storage.googleapis.com/openshift-kubebuilder-tools/envtest-v1.35.1-linux-amd64.tar.gz
+ envtest-v1.35.1-linux-arm64.tar.gz:
+ hash: 309308f9c66f9e2e5192c65a333a388faaaa903841f26f8a96b8f13a5eb3039bcbb818ef6ddbb5803a9cfa9b25e37249a0aed5d472badb25539696569923f87f
+ selfLink: https://storage.googleapis.com/openshift-kubebuilder-tools/envtest-v1.35.1-linux-arm64.tar.gz
+ v1.36.2:
+ envtest-v1.36.2-darwin-amd64.tar.gz:
+ hash: ca924b4435784f12ac3c2513a78d9c6527bb83f2cece48e07d017616843cb67d2ec5836b7a83818f8817c3e0b4de1319c55ead061f3e41c05553a40bf240017a
+ selfLink: https://storage.googleapis.com/openshift-kubebuilder-tools/envtest-v1.36.2-darwin-amd64.tar.gz
+ envtest-v1.36.2-darwin-arm64.tar.gz:
+ hash: f5e45f660fb2abb05a55093bfd3f9594ca91b074a86126112b4645d463bc4b0e0b10261da26420c4dfbef18d189ab92da6c881c347159541481185e157d37d92
+ selfLink: https://storage.googleapis.com/openshift-kubebuilder-tools/envtest-v1.36.2-darwin-arm64.tar.gz
+ envtest-v1.36.2-linux-amd64.tar.gz:
+ hash: 4322b73b1d43c7a16fb46819d2e8a95e34ab2412bcc502c75231c61bdd799a2b43916e12c11f5f0251573260e60a641e34f67e81da37d2726abfcca1720b1e73
+ selfLink: https://storage.googleapis.com/openshift-kubebuilder-tools/envtest-v1.36.2-linux-amd64.tar.gz
+ envtest-v1.36.2-linux-arm64.tar.gz:
+ hash: bbe6810d76c91349cdee6daf65a6a9289010d48ddc2c42d9e163897a927b6ff7de9d0addc75bd54721cfa5048f8aafcac06a950efa59f4a686f037d1386811de
+ selfLink: https://storage.googleapis.com/openshift-kubebuilder-tools/envtest-v1.36.2-linux-arm64.tar.gz
diff --git a/vendor/github.com/openshift/api/etcd/install.go b/vendor/github.com/openshift/api/etcd/install.go
index 7e7474152c..659816d814 100644
--- a/vendor/github.com/openshift/api/etcd/install.go
+++ b/vendor/github.com/openshift/api/etcd/install.go
@@ -5,6 +5,7 @@ import (
"k8s.io/apimachinery/pkg/runtime/schema"
v1alpha1 "github.com/openshift/api/etcd/v1alpha1"
+ v1 "github.com/openshift/api/etcd/v1"
)
const (
@@ -12,7 +13,7 @@ const (
)
var (
- schemeBuilder = runtime.NewSchemeBuilder(v1alpha1.Install)
+ schemeBuilder = runtime.NewSchemeBuilder(v1.Install, v1alpha1.Install)
// Install is a function which adds every version of this group to a scheme
Install = schemeBuilder.AddToScheme
)
diff --git a/vendor/github.com/openshift/api/etcd/v1/Makefile b/vendor/github.com/openshift/api/etcd/v1/Makefile
new file mode 100644
index 0000000000..6fa6435a24
--- /dev/null
+++ b/vendor/github.com/openshift/api/etcd/v1/Makefile
@@ -0,0 +1,3 @@
+.PHONY: test
+test:
+ make -C ../../tests test GINKGO_EXTRA_ARGS=--focus="etcd.openshift.io/v1"
diff --git a/vendor/github.com/openshift/api/etcd/v1/doc.go b/vendor/github.com/openshift/api/etcd/v1/doc.go
new file mode 100644
index 0000000000..d1c4632de8
--- /dev/null
+++ b/vendor/github.com/openshift/api/etcd/v1/doc.go
@@ -0,0 +1,7 @@
+// +k8s:deepcopy-gen=package,register
+// +k8s:defaulter-gen=TypeMeta
+// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.etcd.v1
+// +openshift:featuregated-schema-gen=true
+// +groupName=etcd.openshift.io
+package v1
diff --git a/vendor/github.com/openshift/api/etcd/v1/register.go b/vendor/github.com/openshift/api/etcd/v1/register.go
new file mode 100644
index 0000000000..1b59263043
--- /dev/null
+++ b/vendor/github.com/openshift/api/etcd/v1/register.go
@@ -0,0 +1,39 @@
+package v1
+
+import (
+ metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
+ "k8s.io/apimachinery/pkg/runtime"
+ "k8s.io/apimachinery/pkg/runtime/schema"
+)
+
+var (
+ GroupName = "etcd.openshift.io"
+ GroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1"}
+ schemeBuilder = runtime.NewSchemeBuilder(addKnownTypes)
+ // Install is a function which adds this version to a scheme
+ Install = schemeBuilder.AddToScheme
+
+ // SchemeGroupVersion generated code relies on this name
+ // Deprecated
+ SchemeGroupVersion = GroupVersion
+ // AddToScheme exists solely to keep the old generators creating valid code
+ // DEPRECATED
+ AddToScheme = schemeBuilder.AddToScheme
+)
+
+// Resource generated code relies on this being here, but it logically belongs to the group
+// DEPRECATED
+func Resource(resource string) schema.GroupResource {
+ return schema.GroupResource{Group: GroupName, Resource: resource}
+}
+
+func addKnownTypes(scheme *runtime.Scheme) error {
+ metav1.AddToGroupVersion(scheme, GroupVersion)
+
+ scheme.AddKnownTypes(GroupVersion,
+ &PacemakerCluster{},
+ &PacemakerClusterList{},
+ )
+
+ return nil
+}
diff --git a/vendor/github.com/openshift/api/etcd/v1/types_pacemakercluster.go b/vendor/github.com/openshift/api/etcd/v1/types_pacemakercluster.go
new file mode 100644
index 0000000000..a481f5e1bd
--- /dev/null
+++ b/vendor/github.com/openshift/api/etcd/v1/types_pacemakercluster.go
@@ -0,0 +1,737 @@
+package v1
+
+import (
+ metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
+)
+
+// PacemakerCluster is used in Two Node OpenShift with Fencing deployments to monitor the health
+// of etcd running under pacemaker.
+
+// Cluster-level condition types for PacemakerCluster.status.conditions
+const (
+ // ClusterHealthyConditionType tracks the overall health of the pacemaker cluster.
+ // This is an aggregate condition that reflects the health of all cluster-level conditions and node health.
+ // Specifically, it aggregates the following conditions:
+ // - ClusterInServiceConditionType
+ // - ClusterNodeCountAsExpectedConditionType
+ // - NodeHealthyConditionType (for each node)
+ // When True, the cluster is healthy with reason "ClusterHealthy".
+ // When False, the cluster is unhealthy with reason "ClusterUnhealthy".
+ ClusterHealthyConditionType = "Healthy"
+
+ // ClusterInServiceConditionType tracks whether the cluster is in service (not in maintenance mode).
+ // Maintenance mode is a cluster-wide setting that prevents pacemaker from starting or stopping resources.
+ // When True, the cluster is in service with reason "InService". This is the normal operating state.
+ // When False, the cluster is in maintenance mode with reason "InMaintenance". This is an unexpected state.
+ ClusterInServiceConditionType = "InService"
+
+ // ClusterNodeCountAsExpectedConditionType tracks whether the cluster has the expected number of nodes.
+ // For Two Node OpenShift with Fencing, we are expecting exactly 2 nodes.
+ // When True, the expected number of nodes are present with reason "AsExpected".
+ // When False, the node count is incorrect with reason "InsufficientNodes" or "ExcessiveNodes".
+ ClusterNodeCountAsExpectedConditionType = "NodeCountAsExpected"
+)
+
+// ClusterHealthy condition reasons
+const (
+ // ClusterHealthyReasonHealthy means the pacemaker cluster is healthy and operating normally.
+ ClusterHealthyReasonHealthy = "ClusterHealthy"
+
+ // ClusterHealthyReasonUnhealthy means the pacemaker cluster has issues that need investigation.
+ ClusterHealthyReasonUnhealthy = "ClusterUnhealthy"
+)
+
+// ClusterInService condition reasons
+const (
+ // ClusterInServiceReasonInService means the cluster is in service (not in maintenance mode).
+ // This is the normal operating state.
+ ClusterInServiceReasonInService = "InService"
+
+ // ClusterInServiceReasonInMaintenance means the cluster is in maintenance mode.
+ // In maintenance mode, pacemaker will not start or stop any resources. Entering and exiting this state requires
+ // manual user intervention, and is unexpected during normal cluster operation.
+ ClusterInServiceReasonInMaintenance = "InMaintenance"
+)
+
+// ClusterNodeCountAsExpected condition reasons
+const (
+ // ClusterNodeCountAsExpectedReasonAsExpected means the expected number of nodes are present.
+ // For Two Node OpenShift with Fencing, we are expecting exactly 2 nodes. This is the expected healthy state.
+ ClusterNodeCountAsExpectedReasonAsExpected = "AsExpected"
+
+ // ClusterNodeCountAsExpectedReasonInsufficientNodes means fewer nodes than expected are present.
+ // For Two Node OpenShift with Fencing, this means that less than 2 nodes are present. Under normal operation, this will only happen during
+ // a node replacement operation. It's also possible to enter this state with manual user intervention, but
+ // will also require user intervention to restore normal functionality.
+ ClusterNodeCountAsExpectedReasonInsufficientNodes = "InsufficientNodes"
+
+ // ClusterNodeCountAsExpectedReasonExcessiveNodes means more nodes than expected are present.
+ // For Two Node OpenShift with Fencing, this means more than 2 nodes are present. This should be investigated as it is unexpected and should
+ // never happen during normal cluster operation. It is possible to enter this state with manual user intervention,
+ // but will also require user intervention to restore normal functionality.
+ ClusterNodeCountAsExpectedReasonExcessiveNodes = "ExcessiveNodes"
+)
+
+// Node-level condition types for PacemakerCluster.status.nodes[].conditions
+const (
+ // NodeHealthyConditionType tracks the overall health of a node in the pacemaker cluster.
+ // This is an aggregate condition that reflects the health of all node-level conditions and resource health.
+ // Specifically, it aggregates the following conditions:
+ // - NodeOnlineConditionType
+ // - NodeInServiceConditionType
+ // - NodeActiveConditionType
+ // - NodeReadyConditionType
+ // - NodeCleanConditionType
+ // - NodeMemberConditionType
+ // - NodeFencingAvailableConditionType
+ // - NodeFencingHealthyConditionType
+ // - ResourceHealthyConditionType (for each resource in the node's resources list)
+ // When True, the node is healthy with reason "NodeHealthy".
+ // When False, the node is unhealthy with reason "NodeUnhealthy".
+ NodeHealthyConditionType = "Healthy"
+
+ // NodeOnlineConditionType tracks whether a node is online.
+ // When True, the node is online with reason "Online". This is the normal operating state.
+ // When False, the node is offline with reason "Offline". This can occur during reboots, failures, maintenance, or replacement.
+ NodeOnlineConditionType = "Online"
+
+ // NodeInServiceConditionType tracks whether a node is in service (not in maintenance mode).
+ // A node in maintenance mode is ignored by pacemaker while maintenance mode is active.
+ // When True, the node is in service with reason "InService". This is the normal operating state.
+ // When False, the node is in maintenance mode with reason "InMaintenance". This is an unexpected state.
+ NodeInServiceConditionType = "InService"
+
+ // NodeActiveConditionType tracks whether a node is active (not in standby mode).
+ // When a node enters standby mode, pacemaker moves its resources to other nodes in the cluster.
+ // In Two Node OpenShift with Fencing, we do not use standby mode during normal operation.
+ // When True, the node is active with reason "Active". This is the normal operating state.
+ // When False, the node is in standby mode with reason "Standby". This is an unexpected state.
+ NodeActiveConditionType = "Active"
+
+ // NodeReadyConditionType tracks whether a node is ready (not in a pending state).
+ // A node in a pending state is in the process of joining or leaving the cluster.
+ // When True, the node is ready with reason "Ready". This is the normal operating state.
+ // When False, the node is pending with reason "Pending". This is expected to be temporary.
+ NodeReadyConditionType = "Ready"
+
+ // NodeCleanConditionType tracks whether a node is in a clean state.
+ // An unclean state means that pacemaker was unable to confirm the node's state, which signifies issues
+ // in fencing, communication, or configuration.
+ // When True, the node is clean with reason "Clean". This is the normal operating state.
+ // When False, the node is unclean with reason "Unclean". This is an unexpected state.
+ NodeCleanConditionType = "Clean"
+
+ // NodeMemberConditionType tracks whether a node is a member of the cluster.
+ // Some configurations may use remote nodes or ping nodes, which are nodes that are not members.
+ // For Two Node OpenShift with Fencing, we expect both nodes to be members.
+ // When True, the node is a member with reason "Member". This is the normal operating state.
+ // When False, the node is not a member with reason "NotMember". This is an unexpected state.
+ NodeMemberConditionType = "Member"
+
+ // NodeFencingAvailableConditionType tracks whether a node can be fenced by at least one fencing agent.
+ // For Two Node OpenShift with Fencing, each node needs at least one healthy fencing agent to ensure
+ // that the cluster can recover from a node failure via STONITH (Shoot The Other Node In The Head).
+ // When True, at least one fencing agent is healthy with reason "FencingAvailable".
+ // When False, all fencing agents are unhealthy with reason "FencingUnavailable". This is a critical
+ // state that should degrade the operator.
+ NodeFencingAvailableConditionType = "FencingAvailable"
+
+ // NodeFencingHealthyConditionType tracks whether all fencing agents for a node are healthy.
+ // This is an aggregate condition that reflects the health of all fencing agents targeting this node.
+ // When True, all fencing agents are healthy with reason "FencingHealthy".
+ // When False, one or more fencing agents are unhealthy with reason "FencingUnhealthy". Warning events
+ // should be emitted for failing agents, but the operator should not be degraded if FencingAvailable is True.
+ NodeFencingHealthyConditionType = "FencingHealthy"
+)
+
+// NodeHealthy condition reasons
+const (
+ // NodeHealthyReasonHealthy means the node is healthy and operating normally.
+ NodeHealthyReasonHealthy = "NodeHealthy"
+
+ // NodeHealthyReasonUnhealthy means the node has issues that need investigation.
+ NodeHealthyReasonUnhealthy = "NodeUnhealthy"
+)
+
+// NodeOnline condition reasons
+const (
+ // NodeOnlineReasonOnline means the node is online. This is the normal operating state.
+ NodeOnlineReasonOnline = "Online"
+
+ // NodeOnlineReasonOffline means the node is offline.
+ NodeOnlineReasonOffline = "Offline"
+)
+
+// NodeInService condition reasons
+const (
+ // NodeInServiceReasonInService means the node is in service (not in maintenance mode).
+ // This is the normal operating state.
+ NodeInServiceReasonInService = "InService"
+
+ // NodeInServiceReasonInMaintenance means the node is in maintenance mode.
+ // This is an unexpected state.
+ NodeInServiceReasonInMaintenance = "InMaintenance"
+)
+
+// NodeActive condition reasons
+const (
+ // NodeActiveReasonActive means the node is active (not in standby mode).
+ // This is the normal operating state.
+ NodeActiveReasonActive = "Active"
+
+ // NodeActiveReasonStandby means the node is in standby mode.
+ // This is an unexpected state.
+ NodeActiveReasonStandby = "Standby"
+)
+
+// NodeReady condition reasons
+const (
+ // NodeReadyReasonReady means the node is ready (not in a pending state).
+ // This is the normal operating state.
+ NodeReadyReasonReady = "Ready"
+
+ // NodeReadyReasonPending means the node is joining or leaving the cluster.
+ // This state is expected to be temporary.
+ NodeReadyReasonPending = "Pending"
+)
+
+// NodeClean condition reasons
+const (
+ // NodeCleanReasonClean means the node is in a clean state.
+ // This is the normal operating state.
+ NodeCleanReasonClean = "Clean"
+
+ // NodeCleanReasonUnclean means the node is in an unclean state.
+ // Pacemaker was unable to confirm the node's state, which signifies issues in fencing, communication, or configuration.
+ // This is an unexpected state.
+ NodeCleanReasonUnclean = "Unclean"
+)
+
+// NodeMember condition reasons
+const (
+ // NodeMemberReasonMember means the node is a member of the cluster.
+ // For Two Node OpenShift with Fencing, we expect both nodes to be members. This is the normal operating state.
+ NodeMemberReasonMember = "Member"
+
+ // NodeMemberReasonNotMember means the node is not a member of the cluster.
+ // This is an unexpected state.
+ NodeMemberReasonNotMember = "NotMember"
+)
+
+// NodeFencingAvailable condition reasons
+const (
+ // NodeFencingAvailableReasonAvailable means at least one fencing agent for this node is healthy.
+ // The cluster can fence this node if needed. This is the normal operating state.
+ NodeFencingAvailableReasonAvailable = "FencingAvailable"
+
+ // NodeFencingAvailableReasonUnavailable means all fencing agents for this node are unhealthy.
+ // The cluster cannot fence this node, which compromises high availability.
+ // This is a critical state that should degrade the operator.
+ NodeFencingAvailableReasonUnavailable = "FencingUnavailable"
+)
+
+// NodeFencingHealthy condition reasons
+const (
+ // NodeFencingHealthyReasonHealthy means all fencing agents for this node are healthy.
+ // This is the ideal operating state with full redundancy.
+ NodeFencingHealthyReasonHealthy = "FencingHealthy"
+
+ // NodeFencingHealthyReasonUnhealthy means one or more fencing agents for this node are unhealthy.
+ // Warning events should be emitted for failing agents, but the operator should not be degraded
+ // if FencingAvailable is still True.
+ NodeFencingHealthyReasonUnhealthy = "FencingUnhealthy"
+)
+
+// Resource-level condition types for PacemakerCluster.status.nodes[].resources[].conditions
+const (
+ // ResourceHealthyConditionType tracks the overall health of a pacemaker resource.
+ // This is an aggregate condition that reflects the health of all resource-level conditions.
+ // Specifically, it aggregates the following conditions:
+ // - ResourceInServiceConditionType
+ // - ResourceManagedConditionType
+ // - ResourceEnabledConditionType
+ // - ResourceOperationalConditionType
+ // - ResourceActiveConditionType
+ // - ResourceStartedConditionType
+ // - ResourceSchedulableConditionType
+ // When True, the resource is healthy with reason "ResourceHealthy".
+ // When False, the resource is unhealthy with reason "ResourceUnhealthy".
+ ResourceHealthyConditionType = "Healthy"
+
+ // ResourceInServiceConditionType tracks whether a resource is in service (not in maintenance mode).
+ // Resources in maintenance mode are not monitored or moved by pacemaker.
+ // In Two Node OpenShift with Fencing, we do not expect any resources to be in maintenance mode.
+ // When True, the resource is in service with reason "InService". This is the normal operating state.
+ // When False, the resource is in maintenance mode with reason "InMaintenance". This is an unexpected state.
+ ResourceInServiceConditionType = "InService"
+
+ // ResourceManagedConditionType tracks whether a resource is managed by pacemaker.
+ // Resources that are not managed by pacemaker are effectively invisible to the pacemaker HA logic.
+ // For Two Node OpenShift with Fencing, all resources are expected to be managed.
+ // When True, the resource is managed with reason "Managed". This is the normal operating state.
+ // When False, the resource is not managed with reason "Unmanaged". This is an unexpected state.
+ ResourceManagedConditionType = "Managed"
+
+ // ResourceEnabledConditionType tracks whether a resource is enabled.
+ // Resources that are disabled are stopped and not automatically managed or started by the cluster.
+ // In Two Node OpenShift with Fencing, we do not expect any resources to be disabled.
+ // When True, the resource is enabled with reason "Enabled". This is the normal operating state.
+ // When False, the resource is disabled with reason "Disabled". This is an unexpected state.
+ ResourceEnabledConditionType = "Enabled"
+
+ // ResourceOperationalConditionType tracks whether a resource is operational (not failed).
+ // A failed resource is one that is not able to start or is in an error state.
+ // When True, the resource is operational with reason "Operational". This is the normal operating state.
+ // When False, the resource has failed with reason "Failed". This is an unexpected state.
+ ResourceOperationalConditionType = "Operational"
+
+ // ResourceActiveConditionType tracks whether a resource is active.
+ // An active resource is running on a cluster node.
+ // In Two Node OpenShift with Fencing, all resources are expected to be active.
+ // When True, the resource is active with reason "Active". This is the normal operating state.
+ // When False, the resource is not active with reason "Inactive". This is an unexpected state.
+ ResourceActiveConditionType = "Active"
+
+ // ResourceStartedConditionType tracks whether a resource is started.
+ // It's normal for a resource like etcd to become stopped in the event of a quorum loss event because
+ // the pacemaker recovery logic will fence a node and restore etcd quorum on the surviving node as a cluster-of-one.
+ // A resource that stays stopped for an extended period of time is an unexpected state and should be investigated.
+ // When True, the resource is started with reason "Started". This is the normal operating state.
+ // When False, the resource is not started with reason "Stopped". This is expected to be temporary.
+ ResourceStartedConditionType = "Started"
+
+ // ResourceSchedulableConditionType tracks whether a resource is schedulable (not blocked).
+ // A resource that is not schedulable is unable to start or move to a different node.
+ // In Two Node OpenShift with Fencing, we do not expect any resources to be unschedulable.
+ // When True, the resource is schedulable with reason "Schedulable". This is the normal operating state.
+ // When False, the resource is not schedulable with reason "Unschedulable". This is an unexpected state.
+ ResourceSchedulableConditionType = "Schedulable"
+)
+
+// ResourceHealthy condition reasons
+const (
+ // ResourceHealthyReasonHealthy means the resource is healthy and operating normally.
+ ResourceHealthyReasonHealthy = "ResourceHealthy"
+
+ // ResourceHealthyReasonUnhealthy means the resource has issues that need investigation.
+ ResourceHealthyReasonUnhealthy = "ResourceUnhealthy"
+)
+
+// ResourceInService condition reasons
+const (
+ // ResourceInServiceReasonInService means the resource is in service (not in maintenance mode).
+ // This is the normal operating state.
+ ResourceInServiceReasonInService = "InService"
+
+ // ResourceInServiceReasonInMaintenance means the resource is in maintenance mode.
+ // Resources in maintenance mode are not monitored or moved by pacemaker. This is an unexpected state.
+ ResourceInServiceReasonInMaintenance = "InMaintenance"
+)
+
+// ResourceManaged condition reasons
+const (
+ // ResourceManagedReasonManaged means the resource is managed by pacemaker.
+ // This is the normal operating state.
+ ResourceManagedReasonManaged = "Managed"
+
+ // ResourceManagedReasonUnmanaged means the resource is not managed by pacemaker.
+ // Resources that are not managed by pacemaker are effectively invisible to the pacemaker HA logic.
+ // This is an unexpected state.
+ ResourceManagedReasonUnmanaged = "Unmanaged"
+)
+
+// ResourceEnabled condition reasons
+const (
+ // ResourceEnabledReasonEnabled means the resource is enabled.
+ // This is the normal operating state.
+ ResourceEnabledReasonEnabled = "Enabled"
+
+ // ResourceEnabledReasonDisabled means the resource is disabled.
+ // Resources that are disabled are stopped and not automatically managed or started by the cluster.
+ // This is an unexpected state.
+ ResourceEnabledReasonDisabled = "Disabled"
+)
+
+// ResourceOperational condition reasons
+const (
+ // ResourceOperationalReasonOperational means the resource is operational (not failed).
+ // This is the normal operating state.
+ ResourceOperationalReasonOperational = "Operational"
+
+ // ResourceOperationalReasonFailed means the resource has failed.
+ // A failed resource is one that is not able to start or is in an error state. This is an unexpected state.
+ ResourceOperationalReasonFailed = "Failed"
+)
+
+// ResourceActive condition reasons
+const (
+ // ResourceActiveReasonActive means the resource is active.
+ // An active resource is running on a cluster node. This is the normal operating state.
+ ResourceActiveReasonActive = "Active"
+
+ // ResourceActiveReasonInactive means the resource is not active.
+ // This is an unexpected state.
+ ResourceActiveReasonInactive = "Inactive"
+)
+
+// ResourceStarted condition reasons
+const (
+ // ResourceStartedReasonStarted means the resource is started.
+ // This is the normal operating state.
+ ResourceStartedReasonStarted = "Started"
+
+ // ResourceStartedReasonStopped means the resource is stopped.
+ // It's normal for a resource like etcd to become stopped in the event of a quorum loss event because
+ // the pacemaker recovery logic will fence a node and restore etcd quorum on the surviving node as a cluster-of-one.
+ // A resource that stays stopped for an extended period of time is an unexpected state and should be investigated.
+ ResourceStartedReasonStopped = "Stopped"
+)
+
+// ResourceSchedulable condition reasons
+const (
+ // ResourceSchedulableReasonSchedulable means the resource is schedulable (not blocked).
+ // This is the normal operating state.
+ ResourceSchedulableReasonSchedulable = "Schedulable"
+
+ // ResourceSchedulableReasonUnschedulable means the resource is not schedulable (blocked).
+ // A resource that is not schedulable is unable to start or move to a different node. This is an unexpected state.
+ ResourceSchedulableReasonUnschedulable = "Unschedulable"
+)
+
+// PacemakerNodeAddressType represents the type of a node address.
+// Currently only InternalIP is supported.
+// +kubebuilder:validation:Enum=InternalIP
+// +enum
+type PacemakerNodeAddressType string
+
+const (
+ // PacemakerNodeInternalIP is an internal IP address assigned to the node.
+ // This is typically the IP address used for intra-cluster communication.
+ PacemakerNodeInternalIP PacemakerNodeAddressType = "InternalIP"
+)
+
+// PacemakerNodeAddress contains information for a node's address.
+// This is similar to corev1.NodeAddress but adds validation for IP addresses.
+type PacemakerNodeAddress struct {
+ // type is the type of node address.
+ // Currently only "InternalIP" is supported.
+ // +required
+ Type PacemakerNodeAddressType `json:"type,omitempty"`
+
+ // address is the node address.
+ // For InternalIP, this must be a valid global unicast IPv4 or IPv6 address in canonical form.
+ // Canonical form means the shortest standard representation (e.g., "192.168.1.1" not "192.168.001.001",
+ // or "2001:db8::1" not "2001:0db8::1"). Maximum length is 39 characters (full IPv6 address).
+ // Global unicast includes private/RFC1918 addresses but excludes loopback, link-local, and multicast.
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=39
+ // +kubebuilder:validation:XValidation:rule="isIP(self) && ip.isCanonical(self) && ip(self).isGlobalUnicast()",message="must be a valid global unicast IPv4 or IPv6 address in canonical form"
+ // +required
+ Address string `json:"address,omitempty"`
+}
+
+// PacemakerClusterResourceName represents the name of a pacemaker resource.
+// Fencing agents are tracked separately in the fencingAgents field.
+// +kubebuilder:validation:Enum=Kubelet;Etcd
+// +enum
+type PacemakerClusterResourceName string
+
+// PacemakerClusterResourceName values
+const (
+ // PacemakerClusterResourceNameKubelet is the kubelet pacemaker resource.
+ // The kubelet resource is a prerequisite for etcd in Two Node OpenShift with Fencing deployments.
+ PacemakerClusterResourceNameKubelet PacemakerClusterResourceName = "Kubelet"
+
+ // PacemakerClusterResourceNameEtcd is the etcd pacemaker resource.
+ // The etcd resource may temporarily transition to stopped during pacemaker quorum-recovery operations.
+ PacemakerClusterResourceNameEtcd PacemakerClusterResourceName = "Etcd"
+)
+
+// FencingMethod represents the method used by a fencing agent to isolate failed nodes.
+// Valid values are "Redfish" and "IPMI".
+// +kubebuilder:validation:Enum=Redfish;IPMI
+// +enum
+type FencingMethod string
+
+// FencingMethod values
+const (
+ // FencingMethodRedfish uses Redfish, a standard RESTful API for server management.
+ FencingMethodRedfish FencingMethod = "Redfish"
+
+ // FencingMethodIPMI uses IPMI (Intelligent Platform Management Interface), a hardware management interface.
+ FencingMethodIPMI FencingMethod = "IPMI"
+)
+
+// +genclient
+// +genclient:nonNamespaced
+// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
+// PacemakerCluster represents the current state of the pacemaker cluster as reported by the pcs status command.
+// PacemakerCluster is a cluster-scoped singleton resource. The name of this instance is "cluster". This
+// resource provides a view into the health and status of a pacemaker-managed cluster in Two Node OpenShift with Fencing deployments.
+//
+// Compatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer).
+// +openshift:compatibility-gen:level=1
+// +kubebuilder:object:root=true
+// +kubebuilder:resource:path=pacemakerclusters,scope=Cluster,singular=pacemakercluster
+// +kubebuilder:subresource:status
+// +openshift:api-approved.openshift.io=https://github.com/openshift/api/pull/2544
+// +openshift:file-pattern=cvoRunLevel=0000_25,operatorName=etcd,operatorOrdering=01,operatorComponent=two-node-fencing
+// +openshift:enable:FeatureGate=DualReplica
+// +kubebuilder:validation:XValidation:rule="self.metadata.name == 'cluster'",message="PacemakerCluster must be named 'cluster'"
+// +kubebuilder:validation:XValidation:rule="!has(oldSelf.status) || has(self.status)",message="status may not be removed once set"
+type PacemakerCluster struct {
+ metav1.TypeMeta `json:",inline"`
+
+ // metadata is the standard object's metadata.
+ // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
+ // +required
+ metav1.ObjectMeta `json:"metadata,omitempty"`
+
+ // status contains the actual pacemaker cluster status information collected from the cluster.
+ // The goal of this status is to be able to quickly identify if pacemaker is in a healthy state.
+ // In Two Node OpenShift with Fencing, a healthy pacemaker cluster has 2 nodes, both of which have healthy kubelet, etcd, and fencing resources.
+ // This field is optional on creation - the status collector populates it immediately after creating
+ // the resource via the status subresource.
+ // +optional
+ Status PacemakerClusterStatus `json:"status,omitzero"`
+}
+
+// PacemakerClusterStatus contains the actual pacemaker cluster status information. As part of validating the status
+// object, we need to ensure that the lastUpdated timestamp may not be set to an earlier timestamp than the current value.
+// The validation rule checks if oldSelf has lastUpdated before comparing, to handle the initial status creation case.
+// +kubebuilder:validation:XValidation:rule="!has(oldSelf.lastUpdated) || self.lastUpdated >= oldSelf.lastUpdated",message="lastUpdated may not be set to an earlier timestamp"
+type PacemakerClusterStatus struct {
+ // conditions represent the observations of the pacemaker cluster's current state.
+ // Known condition types are: "Healthy", "InService", "NodeCountAsExpected".
+ // The "Healthy" condition is an aggregate that tracks the overall health of the cluster.
+ // The "InService" condition tracks whether the cluster is in service (not in maintenance mode).
+ // The "NodeCountAsExpected" condition tracks whether the expected number of nodes are present.
+ // Each of these conditions is required, so the array must contain at least 3 items.
+ // +listType=map
+ // +listMapKey=type
+ // +kubebuilder:validation:MinItems=3
+ // +kubebuilder:validation:MaxItems=8
+ // +kubebuilder:validation:XValidation:rule="self.exists(c, c.type == 'Healthy')",message="conditions must contain a condition of type Healthy"
+ // +kubebuilder:validation:XValidation:rule="self.exists(c, c.type == 'InService')",message="conditions must contain a condition of type InService"
+ // +kubebuilder:validation:XValidation:rule="self.exists(c, c.type == 'NodeCountAsExpected')",message="conditions must contain a condition of type NodeCountAsExpected"
+ // +required
+ Conditions []metav1.Condition `json:"conditions,omitempty"`
+
+ // lastUpdated is the timestamp when this status was last updated. This is useful for identifying
+ // stale status reports. It must be a valid timestamp in RFC3339 format. Once set, this field cannot
+ // be removed and cannot be set to an earlier timestamp than the current value.
+ // +kubebuilder:validation:Format=date-time
+ // +required
+ LastUpdated metav1.Time `json:"lastUpdated,omitempty,omitzero"`
+
+ // nodes provides detailed status for each control-plane node in the Pacemaker cluster.
+ // While Pacemaker supports up to 32 nodes, the limit is set to 5 (max OpenShift control-plane nodes).
+ // For Two Node OpenShift with Fencing, exactly 2 nodes are expected in a healthy cluster.
+ // An empty list indicates a catastrophic failure where Pacemaker reports no nodes.
+ // +listType=map
+ // +listMapKey=nodeName
+ // +kubebuilder:validation:MinItems=0
+ // +kubebuilder:validation:MaxItems=5
+ // +required
+ Nodes *[]PacemakerClusterNodeStatus `json:"nodes,omitempty"`
+}
+
+// PacemakerClusterNodeStatus represents the status of a single node in the pacemaker cluster including
+// the node's conditions and the health of critical resources running on that node.
+type PacemakerClusterNodeStatus struct {
+ // conditions represent the observations of the node's current state.
+ // Known condition types are: "Healthy", "Online", "InService", "Active", "Ready", "Clean", "Member",
+ // "FencingAvailable", "FencingHealthy".
+ // The "Healthy" condition is an aggregate that tracks the overall health of the node.
+ // The "Online" condition tracks whether the node is online.
+ // The "InService" condition tracks whether the node is in service (not in maintenance mode).
+ // The "Active" condition tracks whether the node is active (not in standby mode).
+ // The "Ready" condition tracks whether the node is ready (not in a pending state).
+ // The "Clean" condition tracks whether the node is in a clean (status known) state.
+ // The "Member" condition tracks whether the node is a member of the cluster.
+ // The "FencingAvailable" condition tracks whether this node can be fenced by at least one healthy agent.
+ // The "FencingHealthy" condition tracks whether all fencing agents for this node are healthy.
+ // Each of these conditions is required, so the array must contain at least 9 items.
+ // +listType=map
+ // +listMapKey=type
+ // +kubebuilder:validation:MinItems=9
+ // +kubebuilder:validation:MaxItems=16
+ // +kubebuilder:validation:XValidation:rule="self.exists(c, c.type == 'Healthy')",message="conditions must contain a condition of type Healthy"
+ // +kubebuilder:validation:XValidation:rule="self.exists(c, c.type == 'Online')",message="conditions must contain a condition of type Online"
+ // +kubebuilder:validation:XValidation:rule="self.exists(c, c.type == 'InService')",message="conditions must contain a condition of type InService"
+ // +kubebuilder:validation:XValidation:rule="self.exists(c, c.type == 'Active')",message="conditions must contain a condition of type Active"
+ // +kubebuilder:validation:XValidation:rule="self.exists(c, c.type == 'Ready')",message="conditions must contain a condition of type Ready"
+ // +kubebuilder:validation:XValidation:rule="self.exists(c, c.type == 'Clean')",message="conditions must contain a condition of type Clean"
+ // +kubebuilder:validation:XValidation:rule="self.exists(c, c.type == 'Member')",message="conditions must contain a condition of type Member"
+ // +kubebuilder:validation:XValidation:rule="self.exists(c, c.type == 'FencingAvailable')",message="conditions must contain a condition of type FencingAvailable"
+ // +kubebuilder:validation:XValidation:rule="self.exists(c, c.type == 'FencingHealthy')",message="conditions must contain a condition of type FencingHealthy"
+ // +required
+ Conditions []metav1.Condition `json:"conditions,omitempty"`
+
+ // nodeName is the name of the node. This is expected to match the Kubernetes node's name, which must be a lowercase
+ // RFC 1123 subdomain consisting of lowercase alphanumeric characters, '-' or '.', starting and ending with
+ // an alphanumeric character, and be at most 253 characters in length.
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=253
+ // +kubebuilder:validation:XValidation:rule="!format.dns1123Subdomain().validate(self).hasValue()",message="nodeName must be a lowercase RFC 1123 subdomain consisting of lowercase alphanumeric characters, '-' or '.', and must start and end with an alphanumeric character"
+ // +required
+ NodeName string `json:"nodeName,omitempty"`
+
+ // addresses is a list of IP addresses for the node.
+ // Pacemaker allows multiple IP addresses for Corosync communication between nodes.
+ // The first address in this list is used for IP-based peer URLs for etcd membership.
+ // Each address must be a valid global unicast IPv4 or IPv6 address in canonical form
+ // (e.g., "192.168.1.1" not "192.168.001.001", or "2001:db8::1" not "2001:0db8::1").
+ // This excludes loopback, link-local, and multicast addresses.
+ // +listType=atomic
+ // +kubebuilder:validation:MinItems=1
+ // +kubebuilder:validation:MaxItems=8
+ // +required
+ Addresses []PacemakerNodeAddress `json:"addresses,omitempty"`
+
+ // resources contains the status of pacemaker resources scheduled on this node.
+ // Each resource entry includes the resource name and its health conditions.
+ // For Two Node OpenShift with Fencing, we track Kubelet and Etcd resources per node.
+ // Both resources are required to be present, so the array must contain at least 2 items.
+ // Valid resource names are "Kubelet" and "Etcd".
+ // Fencing agents are tracked separately in the fencingAgents field.
+ // +listType=map
+ // +listMapKey=name
+ // +kubebuilder:validation:MinItems=2
+ // +kubebuilder:validation:MaxItems=8
+ // +kubebuilder:validation:XValidation:rule="self.exists(r, r.name == 'Kubelet')",message="resources must contain a resource named Kubelet"
+ // +kubebuilder:validation:XValidation:rule="self.exists(r, r.name == 'Etcd')",message="resources must contain a resource named Etcd"
+ // +required
+ Resources []PacemakerClusterResourceStatus `json:"resources,omitempty"`
+
+ // fencingAgents contains the status of fencing agents that can fence this node.
+ // Unlike resources (which are scheduled to run on this node), fencing agents are mapped
+ // to the node they can fence (their target), not the node where monitoring operations run.
+ // Each fencing agent entry includes a unique name, fencing type, target node, and health conditions.
+ // A node is considered fence-capable if at least one fencing agent is healthy.
+ // A healthy node is expected to have at least 1 fencing agent, but the list may be empty
+ // when fencing agent discovery fails.
+ // Names must be unique within this array.
+ // +listType=map
+ // +listMapKey=name
+ // +kubebuilder:validation:MinItems=0
+ // +kubebuilder:validation:MaxItems=8
+ // +kubebuilder:validation:XValidation:rule="self.all(x, self.exists_one(y, x.name == y.name))",message="fencing agent names must be unique"
+ // +required
+ FencingAgents []PacemakerClusterFencingAgentStatus `json:"fencingAgents,omitempty"`
+}
+
+// PacemakerClusterFencingAgentStatus represents the status of a fencing agent that can fence a node.
+// Fencing agents are STONITH (Shoot The Other Node In The Head) devices used to isolate failed nodes.
+// Unlike regular pacemaker resources, fencing agents are mapped to their target node (the node they
+// can fence), not the node where their monitoring operations are scheduled.
+type PacemakerClusterFencingAgentStatus struct {
+ // conditions represent the observations of the fencing agent's current state.
+ // Known condition types are: "Healthy", "InService", "Managed", "Enabled", "Operational",
+ // "Active", "Started", "Schedulable".
+ // The "Healthy" condition is an aggregate that tracks the overall health of the fencing agent.
+ // The "InService" condition tracks whether the fencing agent is in service (not in maintenance mode).
+ // The "Managed" condition tracks whether the fencing agent is managed by pacemaker.
+ // The "Enabled" condition tracks whether the fencing agent is enabled.
+ // The "Operational" condition tracks whether the fencing agent is operational (not failed).
+ // The "Active" condition tracks whether the fencing agent is active (available to be used).
+ // The "Started" condition tracks whether the fencing agent is started.
+ // The "Schedulable" condition tracks whether the fencing agent is schedulable (not blocked).
+ // Each of these conditions is required, so the array must contain at least 8 items.
+ // +listType=map
+ // +listMapKey=type
+ // +kubebuilder:validation:MinItems=8
+ // +kubebuilder:validation:MaxItems=16
+ // +kubebuilder:validation:XValidation:rule="self.exists(c, c.type == 'Healthy')",message="conditions must contain a condition of type Healthy"
+ // +kubebuilder:validation:XValidation:rule="self.exists(c, c.type == 'InService')",message="conditions must contain a condition of type InService"
+ // +kubebuilder:validation:XValidation:rule="self.exists(c, c.type == 'Managed')",message="conditions must contain a condition of type Managed"
+ // +kubebuilder:validation:XValidation:rule="self.exists(c, c.type == 'Enabled')",message="conditions must contain a condition of type Enabled"
+ // +kubebuilder:validation:XValidation:rule="self.exists(c, c.type == 'Operational')",message="conditions must contain a condition of type Operational"
+ // +kubebuilder:validation:XValidation:rule="self.exists(c, c.type == 'Active')",message="conditions must contain a condition of type Active"
+ // +kubebuilder:validation:XValidation:rule="self.exists(c, c.type == 'Started')",message="conditions must contain a condition of type Started"
+ // +kubebuilder:validation:XValidation:rule="self.exists(c, c.type == 'Schedulable')",message="conditions must contain a condition of type Schedulable"
+ // +required
+ Conditions []metav1.Condition `json:"conditions,omitempty"`
+
+ // name is the unique identifier for this fencing agent (e.g., "master-0_redfish").
+ // The name must be unique within the fencingAgents array for this node.
+ // It may contain alphanumeric characters, dots, hyphens, and underscores.
+ // Maximum length is 300 characters, providing headroom beyond the typical format of
+ // _ (253 for RFC 1123 node name + 1 underscore + type).
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=300
+ // +kubebuilder:validation:XValidation:rule="self.matches('^[a-zA-Z0-9._-]+$')",message="name must contain only alphanumeric characters, dots, hyphens, and underscores"
+ // +required
+ Name string `json:"name,omitempty"`
+
+ // method is the fencing method used by this agent.
+ // Valid values are "Redfish" and "IPMI".
+ // Redfish is a standard RESTful API for server management.
+ // IPMI (Intelligent Platform Management Interface) is a hardware management interface.
+ // +required
+ Method FencingMethod `json:"method,omitempty"`
+}
+
+// PacemakerClusterResourceStatus represents the status of a pacemaker resource scheduled on a node.
+// A pacemaker resource is a unit of work managed by pacemaker. In pacemaker terminology, resources are services or
+// applications that pacemaker monitors, starts, stops, and moves between nodes to maintain high availability.
+// For Two Node OpenShift with Fencing, we track two resources per node:
+// - Kubelet (the Kubernetes node agent and a prerequisite for etcd)
+// - Etcd (the distributed key-value store)
+//
+// Fencing agents are tracked separately in the fencingAgents field because they are mapped to
+// their target node (the node they can fence), not the node where monitoring operations are scheduled.
+type PacemakerClusterResourceStatus struct {
+ // conditions represent the observations of the resource's current state.
+ // Known condition types are: "Healthy", "InService", "Managed", "Enabled", "Operational",
+ // "Active", "Started", "Schedulable".
+ // The "Healthy" condition is an aggregate that tracks the overall health of the resource.
+ // The "InService" condition tracks whether the resource is in service (not in maintenance mode).
+ // The "Managed" condition tracks whether the resource is managed by pacemaker.
+ // The "Enabled" condition tracks whether the resource is enabled.
+ // The "Operational" condition tracks whether the resource is operational (not failed).
+ // The "Active" condition tracks whether the resource is active (available to be used).
+ // The "Started" condition tracks whether the resource is started.
+ // The "Schedulable" condition tracks whether the resource is schedulable (not blocked).
+ // Each of these conditions is required, so the array must contain at least 8 items.
+ // +listType=map
+ // +listMapKey=type
+ // +kubebuilder:validation:MinItems=8
+ // +kubebuilder:validation:MaxItems=16
+ // +kubebuilder:validation:XValidation:rule="self.exists(c, c.type == 'Healthy')",message="conditions must contain a condition of type Healthy"
+ // +kubebuilder:validation:XValidation:rule="self.exists(c, c.type == 'InService')",message="conditions must contain a condition of type InService"
+ // +kubebuilder:validation:XValidation:rule="self.exists(c, c.type == 'Managed')",message="conditions must contain a condition of type Managed"
+ // +kubebuilder:validation:XValidation:rule="self.exists(c, c.type == 'Enabled')",message="conditions must contain a condition of type Enabled"
+ // +kubebuilder:validation:XValidation:rule="self.exists(c, c.type == 'Operational')",message="conditions must contain a condition of type Operational"
+ // +kubebuilder:validation:XValidation:rule="self.exists(c, c.type == 'Active')",message="conditions must contain a condition of type Active"
+ // +kubebuilder:validation:XValidation:rule="self.exists(c, c.type == 'Started')",message="conditions must contain a condition of type Started"
+ // +kubebuilder:validation:XValidation:rule="self.exists(c, c.type == 'Schedulable')",message="conditions must contain a condition of type Schedulable"
+ // +required
+ Conditions []metav1.Condition `json:"conditions,omitempty"`
+
+ // name is the name of the pacemaker resource.
+ // Valid values are "Kubelet" and "Etcd".
+ // The Kubelet resource is a prerequisite for etcd in Two Node OpenShift with Fencing deployments.
+ // The Etcd resource may temporarily transition to stopped during pacemaker quorum-recovery operations.
+ // Fencing agents are tracked separately in the node's fencingAgents field.
+ // +required
+ Name PacemakerClusterResourceName `json:"name,omitempty"`
+}
+
+// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
+// PacemakerClusterList contains a list of PacemakerCluster objects. PacemakerCluster is a cluster-scoped singleton
+// resource; only one instance named "cluster" may exist. This list type exists only to satisfy Kubernetes API
+// conventions.
+//
+// Compatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer).
+// +openshift:compatibility-gen:level=1
+type PacemakerClusterList struct {
+ metav1.TypeMeta `json:",inline"`
+
+ // metadata is the standard list's metadata.
+ // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
+ metav1.ListMeta `json:"metadata,omitempty"`
+
+ // items is a list of PacemakerCluster objects.
+ Items []PacemakerCluster `json:"items"`
+}
diff --git a/vendor/github.com/openshift/api/etcd/v1/zz_generated.deepcopy.go b/vendor/github.com/openshift/api/etcd/v1/zz_generated.deepcopy.go
new file mode 100644
index 0000000000..c529240e40
--- /dev/null
+++ b/vendor/github.com/openshift/api/etcd/v1/zz_generated.deepcopy.go
@@ -0,0 +1,210 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1
+
+import (
+ metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
+ runtime "k8s.io/apimachinery/pkg/runtime"
+)
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *PacemakerCluster) DeepCopyInto(out *PacemakerCluster) {
+ *out = *in
+ out.TypeMeta = in.TypeMeta
+ in.ObjectMeta.DeepCopyInto(&out.ObjectMeta)
+ in.Status.DeepCopyInto(&out.Status)
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PacemakerCluster.
+func (in *PacemakerCluster) DeepCopy() *PacemakerCluster {
+ if in == nil {
+ return nil
+ }
+ out := new(PacemakerCluster)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
+func (in *PacemakerCluster) DeepCopyObject() runtime.Object {
+ if c := in.DeepCopy(); c != nil {
+ return c
+ }
+ return nil
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *PacemakerClusterFencingAgentStatus) DeepCopyInto(out *PacemakerClusterFencingAgentStatus) {
+ *out = *in
+ if in.Conditions != nil {
+ in, out := &in.Conditions, &out.Conditions
+ *out = make([]metav1.Condition, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PacemakerClusterFencingAgentStatus.
+func (in *PacemakerClusterFencingAgentStatus) DeepCopy() *PacemakerClusterFencingAgentStatus {
+ if in == nil {
+ return nil
+ }
+ out := new(PacemakerClusterFencingAgentStatus)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *PacemakerClusterList) DeepCopyInto(out *PacemakerClusterList) {
+ *out = *in
+ out.TypeMeta = in.TypeMeta
+ in.ListMeta.DeepCopyInto(&out.ListMeta)
+ if in.Items != nil {
+ in, out := &in.Items, &out.Items
+ *out = make([]PacemakerCluster, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PacemakerClusterList.
+func (in *PacemakerClusterList) DeepCopy() *PacemakerClusterList {
+ if in == nil {
+ return nil
+ }
+ out := new(PacemakerClusterList)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
+func (in *PacemakerClusterList) DeepCopyObject() runtime.Object {
+ if c := in.DeepCopy(); c != nil {
+ return c
+ }
+ return nil
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *PacemakerClusterNodeStatus) DeepCopyInto(out *PacemakerClusterNodeStatus) {
+ *out = *in
+ if in.Conditions != nil {
+ in, out := &in.Conditions, &out.Conditions
+ *out = make([]metav1.Condition, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ if in.Addresses != nil {
+ in, out := &in.Addresses, &out.Addresses
+ *out = make([]PacemakerNodeAddress, len(*in))
+ copy(*out, *in)
+ }
+ if in.Resources != nil {
+ in, out := &in.Resources, &out.Resources
+ *out = make([]PacemakerClusterResourceStatus, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ if in.FencingAgents != nil {
+ in, out := &in.FencingAgents, &out.FencingAgents
+ *out = make([]PacemakerClusterFencingAgentStatus, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PacemakerClusterNodeStatus.
+func (in *PacemakerClusterNodeStatus) DeepCopy() *PacemakerClusterNodeStatus {
+ if in == nil {
+ return nil
+ }
+ out := new(PacemakerClusterNodeStatus)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *PacemakerClusterResourceStatus) DeepCopyInto(out *PacemakerClusterResourceStatus) {
+ *out = *in
+ if in.Conditions != nil {
+ in, out := &in.Conditions, &out.Conditions
+ *out = make([]metav1.Condition, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PacemakerClusterResourceStatus.
+func (in *PacemakerClusterResourceStatus) DeepCopy() *PacemakerClusterResourceStatus {
+ if in == nil {
+ return nil
+ }
+ out := new(PacemakerClusterResourceStatus)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *PacemakerClusterStatus) DeepCopyInto(out *PacemakerClusterStatus) {
+ *out = *in
+ if in.Conditions != nil {
+ in, out := &in.Conditions, &out.Conditions
+ *out = make([]metav1.Condition, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ in.LastUpdated.DeepCopyInto(&out.LastUpdated)
+ if in.Nodes != nil {
+ in, out := &in.Nodes, &out.Nodes
+ *out = new([]PacemakerClusterNodeStatus)
+ if **in != nil {
+ in, out := *in, *out
+ *out = make([]PacemakerClusterNodeStatus, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ }
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PacemakerClusterStatus.
+func (in *PacemakerClusterStatus) DeepCopy() *PacemakerClusterStatus {
+ if in == nil {
+ return nil
+ }
+ out := new(PacemakerClusterStatus)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *PacemakerNodeAddress) DeepCopyInto(out *PacemakerNodeAddress) {
+ *out = *in
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PacemakerNodeAddress.
+func (in *PacemakerNodeAddress) DeepCopy() *PacemakerNodeAddress {
+ if in == nil {
+ return nil
+ }
+ out := new(PacemakerNodeAddress)
+ in.DeepCopyInto(out)
+ return out
+}
diff --git a/vendor/github.com/openshift/api/etcd/v1/zz_generated.featuregated-crd-manifests.yaml b/vendor/github.com/openshift/api/etcd/v1/zz_generated.featuregated-crd-manifests.yaml
new file mode 100644
index 0000000000..1a11a877c4
--- /dev/null
+++ b/vendor/github.com/openshift/api/etcd/v1/zz_generated.featuregated-crd-manifests.yaml
@@ -0,0 +1,23 @@
+pacemakerclusters.etcd.openshift.io:
+ Annotations: {}
+ ApprovedPRNumber: https://github.com/openshift/api/pull/2544
+ CRDName: pacemakerclusters.etcd.openshift.io
+ Capability: ""
+ Category: ""
+ FeatureGates:
+ - DualReplica
+ FilenameOperatorName: etcd
+ FilenameOperatorOrdering: "01"
+ FilenameRunLevel: "0000_25"
+ GroupName: etcd.openshift.io
+ HasStatus: true
+ KindName: PacemakerCluster
+ Labels: {}
+ PluralName: pacemakerclusters
+ PrinterColumns: []
+ Scope: Cluster
+ ShortNames: null
+ TopLevelFeatureGates:
+ - DualReplica
+ Version: v1
+
diff --git a/vendor/github.com/openshift/api/etcd/v1/zz_generated.model_name.go b/vendor/github.com/openshift/api/etcd/v1/zz_generated.model_name.go
new file mode 100644
index 0000000000..9e13a7167e
--- /dev/null
+++ b/vendor/github.com/openshift/api/etcd/v1/zz_generated.model_name.go
@@ -0,0 +1,41 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PacemakerCluster) OpenAPIModelName() string {
+ return "com.github.openshift.api.etcd.v1.PacemakerCluster"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PacemakerClusterFencingAgentStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.etcd.v1.PacemakerClusterFencingAgentStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PacemakerClusterList) OpenAPIModelName() string {
+ return "com.github.openshift.api.etcd.v1.PacemakerClusterList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PacemakerClusterNodeStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.etcd.v1.PacemakerClusterNodeStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PacemakerClusterResourceStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.etcd.v1.PacemakerClusterResourceStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PacemakerClusterStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.etcd.v1.PacemakerClusterStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PacemakerNodeAddress) OpenAPIModelName() string {
+ return "com.github.openshift.api.etcd.v1.PacemakerNodeAddress"
+}
diff --git a/vendor/github.com/openshift/api/etcd/v1/zz_generated.swagger_doc_generated.go b/vendor/github.com/openshift/api/etcd/v1/zz_generated.swagger_doc_generated.go
new file mode 100644
index 0000000000..e9e47b47cf
--- /dev/null
+++ b/vendor/github.com/openshift/api/etcd/v1/zz_generated.swagger_doc_generated.go
@@ -0,0 +1,89 @@
+package v1
+
+// This file contains a collection of methods that can be used from go-restful to
+// generate Swagger API documentation for its models. Please read this PR for more
+// information on the implementation: https://github.com/emicklei/go-restful/pull/215
+//
+// TODOs are ignored from the parser (e.g. TODO(andronat):... || TODO:...) if and only if
+// they are on one line! For multiple line or blocks that you want to ignore use ---.
+// Any context after a --- is ignored.
+//
+// Those methods can be generated by using hack/update-swagger-docs.sh
+
+// AUTO-GENERATED FUNCTIONS START HERE
+var map_PacemakerCluster = map[string]string{
+ "": "PacemakerCluster represents the current state of the pacemaker cluster as reported by the pcs status command. PacemakerCluster is a cluster-scoped singleton resource. The name of this instance is \"cluster\". This resource provides a view into the health and status of a pacemaker-managed cluster in Two Node OpenShift with Fencing deployments.\n\nCompatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer).",
+ "metadata": "metadata is the standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata",
+ "status": "status contains the actual pacemaker cluster status information collected from the cluster. The goal of this status is to be able to quickly identify if pacemaker is in a healthy state. In Two Node OpenShift with Fencing, a healthy pacemaker cluster has 2 nodes, both of which have healthy kubelet, etcd, and fencing resources. This field is optional on creation - the status collector populates it immediately after creating the resource via the status subresource.",
+}
+
+func (PacemakerCluster) SwaggerDoc() map[string]string {
+ return map_PacemakerCluster
+}
+
+var map_PacemakerClusterFencingAgentStatus = map[string]string{
+ "": "PacemakerClusterFencingAgentStatus represents the status of a fencing agent that can fence a node. Fencing agents are STONITH (Shoot The Other Node In The Head) devices used to isolate failed nodes. Unlike regular pacemaker resources, fencing agents are mapped to their target node (the node they can fence), not the node where their monitoring operations are scheduled.",
+ "conditions": "conditions represent the observations of the fencing agent's current state. Known condition types are: \"Healthy\", \"InService\", \"Managed\", \"Enabled\", \"Operational\", \"Active\", \"Started\", \"Schedulable\". The \"Healthy\" condition is an aggregate that tracks the overall health of the fencing agent. The \"InService\" condition tracks whether the fencing agent is in service (not in maintenance mode). The \"Managed\" condition tracks whether the fencing agent is managed by pacemaker. The \"Enabled\" condition tracks whether the fencing agent is enabled. The \"Operational\" condition tracks whether the fencing agent is operational (not failed). The \"Active\" condition tracks whether the fencing agent is active (available to be used). The \"Started\" condition tracks whether the fencing agent is started. The \"Schedulable\" condition tracks whether the fencing agent is schedulable (not blocked). Each of these conditions is required, so the array must contain at least 8 items.",
+ "name": "name is the unique identifier for this fencing agent (e.g., \"master-0_redfish\"). The name must be unique within the fencingAgents array for this node. It may contain alphanumeric characters, dots, hyphens, and underscores. Maximum length is 300 characters, providing headroom beyond the typical format of _ (253 for RFC 1123 node name + 1 underscore + type).",
+ "method": "method is the fencing method used by this agent. Valid values are \"Redfish\" and \"IPMI\". Redfish is a standard RESTful API for server management. IPMI (Intelligent Platform Management Interface) is a hardware management interface.",
+}
+
+func (PacemakerClusterFencingAgentStatus) SwaggerDoc() map[string]string {
+ return map_PacemakerClusterFencingAgentStatus
+}
+
+var map_PacemakerClusterList = map[string]string{
+ "": "PacemakerClusterList contains a list of PacemakerCluster objects. PacemakerCluster is a cluster-scoped singleton resource; only one instance named \"cluster\" may exist. This list type exists only to satisfy Kubernetes API conventions.\n\nCompatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer).",
+ "metadata": "metadata is the standard list's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata",
+ "items": "items is a list of PacemakerCluster objects.",
+}
+
+func (PacemakerClusterList) SwaggerDoc() map[string]string {
+ return map_PacemakerClusterList
+}
+
+var map_PacemakerClusterNodeStatus = map[string]string{
+ "": "PacemakerClusterNodeStatus represents the status of a single node in the pacemaker cluster including the node's conditions and the health of critical resources running on that node.",
+ "conditions": "conditions represent the observations of the node's current state. Known condition types are: \"Healthy\", \"Online\", \"InService\", \"Active\", \"Ready\", \"Clean\", \"Member\", \"FencingAvailable\", \"FencingHealthy\". The \"Healthy\" condition is an aggregate that tracks the overall health of the node. The \"Online\" condition tracks whether the node is online. The \"InService\" condition tracks whether the node is in service (not in maintenance mode). The \"Active\" condition tracks whether the node is active (not in standby mode). The \"Ready\" condition tracks whether the node is ready (not in a pending state). The \"Clean\" condition tracks whether the node is in a clean (status known) state. The \"Member\" condition tracks whether the node is a member of the cluster. The \"FencingAvailable\" condition tracks whether this node can be fenced by at least one healthy agent. The \"FencingHealthy\" condition tracks whether all fencing agents for this node are healthy. Each of these conditions is required, so the array must contain at least 9 items.",
+ "nodeName": "nodeName is the name of the node. This is expected to match the Kubernetes node's name, which must be a lowercase RFC 1123 subdomain consisting of lowercase alphanumeric characters, '-' or '.', starting and ending with an alphanumeric character, and be at most 253 characters in length.",
+ "addresses": "addresses is a list of IP addresses for the node. Pacemaker allows multiple IP addresses for Corosync communication between nodes. The first address in this list is used for IP-based peer URLs for etcd membership. Each address must be a valid global unicast IPv4 or IPv6 address in canonical form (e.g., \"192.168.1.1\" not \"192.168.001.001\", or \"2001:db8::1\" not \"2001:0db8::1\"). This excludes loopback, link-local, and multicast addresses.",
+ "resources": "resources contains the status of pacemaker resources scheduled on this node. Each resource entry includes the resource name and its health conditions. For Two Node OpenShift with Fencing, we track Kubelet and Etcd resources per node. Both resources are required to be present, so the array must contain at least 2 items. Valid resource names are \"Kubelet\" and \"Etcd\". Fencing agents are tracked separately in the fencingAgents field.",
+ "fencingAgents": "fencingAgents contains the status of fencing agents that can fence this node. Unlike resources (which are scheduled to run on this node), fencing agents are mapped to the node they can fence (their target), not the node where monitoring operations run. Each fencing agent entry includes a unique name, fencing type, target node, and health conditions. A node is considered fence-capable if at least one fencing agent is healthy. A healthy node is expected to have at least 1 fencing agent, but the list may be empty when fencing agent discovery fails. Names must be unique within this array.",
+}
+
+func (PacemakerClusterNodeStatus) SwaggerDoc() map[string]string {
+ return map_PacemakerClusterNodeStatus
+}
+
+var map_PacemakerClusterResourceStatus = map[string]string{
+ "": "PacemakerClusterResourceStatus represents the status of a pacemaker resource scheduled on a node. A pacemaker resource is a unit of work managed by pacemaker. In pacemaker terminology, resources are services or applications that pacemaker monitors, starts, stops, and moves between nodes to maintain high availability. For Two Node OpenShift with Fencing, we track two resources per node:\n - Kubelet (the Kubernetes node agent and a prerequisite for etcd)\n - Etcd (the distributed key-value store)\n\nFencing agents are tracked separately in the fencingAgents field because they are mapped to their target node (the node they can fence), not the node where monitoring operations are scheduled.",
+ "conditions": "conditions represent the observations of the resource's current state. Known condition types are: \"Healthy\", \"InService\", \"Managed\", \"Enabled\", \"Operational\", \"Active\", \"Started\", \"Schedulable\". The \"Healthy\" condition is an aggregate that tracks the overall health of the resource. The \"InService\" condition tracks whether the resource is in service (not in maintenance mode). The \"Managed\" condition tracks whether the resource is managed by pacemaker. The \"Enabled\" condition tracks whether the resource is enabled. The \"Operational\" condition tracks whether the resource is operational (not failed). The \"Active\" condition tracks whether the resource is active (available to be used). The \"Started\" condition tracks whether the resource is started. The \"Schedulable\" condition tracks whether the resource is schedulable (not blocked). Each of these conditions is required, so the array must contain at least 8 items.",
+ "name": "name is the name of the pacemaker resource. Valid values are \"Kubelet\" and \"Etcd\". The Kubelet resource is a prerequisite for etcd in Two Node OpenShift with Fencing deployments. The Etcd resource may temporarily transition to stopped during pacemaker quorum-recovery operations. Fencing agents are tracked separately in the node's fencingAgents field.",
+}
+
+func (PacemakerClusterResourceStatus) SwaggerDoc() map[string]string {
+ return map_PacemakerClusterResourceStatus
+}
+
+var map_PacemakerClusterStatus = map[string]string{
+ "": "PacemakerClusterStatus contains the actual pacemaker cluster status information. As part of validating the status object, we need to ensure that the lastUpdated timestamp may not be set to an earlier timestamp than the current value. The validation rule checks if oldSelf has lastUpdated before comparing, to handle the initial status creation case.",
+ "conditions": "conditions represent the observations of the pacemaker cluster's current state. Known condition types are: \"Healthy\", \"InService\", \"NodeCountAsExpected\". The \"Healthy\" condition is an aggregate that tracks the overall health of the cluster. The \"InService\" condition tracks whether the cluster is in service (not in maintenance mode). The \"NodeCountAsExpected\" condition tracks whether the expected number of nodes are present. Each of these conditions is required, so the array must contain at least 3 items.",
+ "lastUpdated": "lastUpdated is the timestamp when this status was last updated. This is useful for identifying stale status reports. It must be a valid timestamp in RFC3339 format. Once set, this field cannot be removed and cannot be set to an earlier timestamp than the current value.",
+ "nodes": "nodes provides detailed status for each control-plane node in the Pacemaker cluster. While Pacemaker supports up to 32 nodes, the limit is set to 5 (max OpenShift control-plane nodes). For Two Node OpenShift with Fencing, exactly 2 nodes are expected in a healthy cluster. An empty list indicates a catastrophic failure where Pacemaker reports no nodes.",
+}
+
+func (PacemakerClusterStatus) SwaggerDoc() map[string]string {
+ return map_PacemakerClusterStatus
+}
+
+var map_PacemakerNodeAddress = map[string]string{
+ "": "PacemakerNodeAddress contains information for a node's address. This is similar to corev1.NodeAddress but adds validation for IP addresses.",
+ "type": "type is the type of node address. Currently only \"InternalIP\" is supported.",
+ "address": "address is the node address. For InternalIP, this must be a valid global unicast IPv4 or IPv6 address in canonical form. Canonical form means the shortest standard representation (e.g., \"192.168.1.1\" not \"192.168.001.001\", or \"2001:db8::1\" not \"2001:0db8::1\"). Maximum length is 39 characters (full IPv6 address). Global unicast includes private/RFC1918 addresses but excludes loopback, link-local, and multicast.",
+}
+
+func (PacemakerNodeAddress) SwaggerDoc() map[string]string {
+ return map_PacemakerNodeAddress
+}
+
+// AUTO-GENERATED FUNCTIONS END HERE
diff --git a/vendor/github.com/openshift/api/etcd/v1alpha1/doc.go b/vendor/github.com/openshift/api/etcd/v1alpha1/doc.go
index aea92fb381..c93f9a586c 100644
--- a/vendor/github.com/openshift/api/etcd/v1alpha1/doc.go
+++ b/vendor/github.com/openshift/api/etcd/v1alpha1/doc.go
@@ -1,6 +1,7 @@
// +k8s:deepcopy-gen=package,register
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.etcd.v1alpha1
// +openshift:featuregated-schema-gen=true
// +groupName=etcd.openshift.io
package v1alpha1
diff --git a/vendor/github.com/openshift/api/etcd/v1alpha1/types_pacemakercluster.go b/vendor/github.com/openshift/api/etcd/v1alpha1/types_pacemakercluster.go
index ab06d0e390..b627413474 100644
--- a/vendor/github.com/openshift/api/etcd/v1alpha1/types_pacemakercluster.go
+++ b/vendor/github.com/openshift/api/etcd/v1alpha1/types_pacemakercluster.go
@@ -609,11 +609,12 @@ type PacemakerClusterNodeStatus struct {
// to the node they can fence (their target), not the node where monitoring operations run.
// Each fencing agent entry includes a unique name, fencing type, target node, and health conditions.
// A node is considered fence-capable if at least one fencing agent is healthy.
- // Expected to have 1 fencing agent per node, but up to 8 are supported for redundancy.
+ // A healthy node is expected to have at least 1 fencing agent, but the list may be empty
+ // when fencing agent discovery fails.
// Names must be unique within this array.
// +listType=map
// +listMapKey=name
- // +kubebuilder:validation:MinItems=1
+ // +kubebuilder:validation:MinItems=0
// +kubebuilder:validation:MaxItems=8
// +kubebuilder:validation:XValidation:rule="self.all(x, self.exists_one(y, x.name == y.name))",message="fencing agent names must be unique"
// +required
diff --git a/vendor/github.com/openshift/api/etcd/v1alpha1/zz_generated.model_name.go b/vendor/github.com/openshift/api/etcd/v1alpha1/zz_generated.model_name.go
new file mode 100644
index 0000000000..11fac8dad4
--- /dev/null
+++ b/vendor/github.com/openshift/api/etcd/v1alpha1/zz_generated.model_name.go
@@ -0,0 +1,41 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1alpha1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PacemakerCluster) OpenAPIModelName() string {
+ return "com.github.openshift.api.etcd.v1alpha1.PacemakerCluster"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PacemakerClusterFencingAgentStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.etcd.v1alpha1.PacemakerClusterFencingAgentStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PacemakerClusterList) OpenAPIModelName() string {
+ return "com.github.openshift.api.etcd.v1alpha1.PacemakerClusterList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PacemakerClusterNodeStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.etcd.v1alpha1.PacemakerClusterNodeStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PacemakerClusterResourceStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.etcd.v1alpha1.PacemakerClusterResourceStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PacemakerClusterStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.etcd.v1alpha1.PacemakerClusterStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PacemakerNodeAddress) OpenAPIModelName() string {
+ return "com.github.openshift.api.etcd.v1alpha1.PacemakerNodeAddress"
+}
diff --git a/vendor/github.com/openshift/api/etcd/v1alpha1/zz_generated.swagger_doc_generated.go b/vendor/github.com/openshift/api/etcd/v1alpha1/zz_generated.swagger_doc_generated.go
index 62e1c3ebd7..dc6f224288 100644
--- a/vendor/github.com/openshift/api/etcd/v1alpha1/zz_generated.swagger_doc_generated.go
+++ b/vendor/github.com/openshift/api/etcd/v1alpha1/zz_generated.swagger_doc_generated.go
@@ -48,7 +48,7 @@ var map_PacemakerClusterNodeStatus = map[string]string{
"nodeName": "nodeName is the name of the node. This is expected to match the Kubernetes node's name, which must be a lowercase RFC 1123 subdomain consisting of lowercase alphanumeric characters, '-' or '.', starting and ending with an alphanumeric character, and be at most 253 characters in length.",
"addresses": "addresses is a list of IP addresses for the node. Pacemaker allows multiple IP addresses for Corosync communication between nodes. The first address in this list is used for IP-based peer URLs for etcd membership. Each address must be a valid global unicast IPv4 or IPv6 address in canonical form (e.g., \"192.168.1.1\" not \"192.168.001.001\", or \"2001:db8::1\" not \"2001:0db8::1\"). This excludes loopback, link-local, and multicast addresses.",
"resources": "resources contains the status of pacemaker resources scheduled on this node. Each resource entry includes the resource name and its health conditions. For Two Node OpenShift with Fencing, we track Kubelet and Etcd resources per node. Both resources are required to be present, so the array must contain at least 2 items. Valid resource names are \"Kubelet\" and \"Etcd\". Fencing agents are tracked separately in the fencingAgents field.",
- "fencingAgents": "fencingAgents contains the status of fencing agents that can fence this node. Unlike resources (which are scheduled to run on this node), fencing agents are mapped to the node they can fence (their target), not the node where monitoring operations run. Each fencing agent entry includes a unique name, fencing type, target node, and health conditions. A node is considered fence-capable if at least one fencing agent is healthy. Expected to have 1 fencing agent per node, but up to 8 are supported for redundancy. Names must be unique within this array.",
+ "fencingAgents": "fencingAgents contains the status of fencing agents that can fence this node. Unlike resources (which are scheduled to run on this node), fencing agents are mapped to the node they can fence (their target), not the node where monitoring operations run. Each fencing agent entry includes a unique name, fencing type, target node, and health conditions. A node is considered fence-capable if at least one fencing agent is healthy. A healthy node is expected to have at least 1 fencing agent, but the list may be empty when fencing agent discovery fails. Names must be unique within this array.",
}
func (PacemakerClusterNodeStatus) SwaggerDoc() map[string]string {
diff --git a/vendor/github.com/openshift/api/features.md b/vendor/github.com/openshift/api/features.md
index 45074e6497..e466369e5b 100644
--- a/vendor/github.com/openshift/api/features.md
+++ b/vendor/github.com/openshift/api/features.md
@@ -3,38 +3,40 @@
| ClientsAllowCBOR| | | | | | | | |
| ClusterAPIInstall| | | | | | | | |
| EventedPLEG| | | | | | | | |
+| MachineAPIMigrationAzure| | | | | | | | |
+| MachineAPIMigrationBareMetal| | | | | | | | |
+| MachineAPIMigrationGCP| | | | | | | | |
+| MachineAPIMigrationPowerVS| | | | | | | | |
| MachineAPIOperatorDisableMachineHealthCheckController| | | | | | | | |
| MultiArchInstallAzure| | | | | | | | |
| ShortCertRotation| | | | | | | | |
+| KarpenterOperator| | | | Enabled | | | | |
+| MutableTopology| | | | Enabled | | | | |
+| AuthenticationComponentProxy| | | | Enabled | | | | Enabled |
+| BGPBasedVIPManagement| | | Enabled | Enabled | | | | |
| ClusterAPIComputeInstall| | | Enabled | Enabled | | | | |
| ClusterAPIControlPlaneInstall| | | Enabled | Enabled | | | | |
+| ClusterUpdatePreflight| | | Enabled | Enabled | | | | |
+| ConfidentialCluster| | | Enabled | Enabled | | | | |
| Example2| | | Enabled | Enabled | | | | |
-| ExternalOIDCExternalClaimsSourcing| | | Enabled | Enabled | | | | |
-| ExternalSnapshotMetadata| | | Enabled | Enabled | | | | |
-| KMSEncryptionProvider| | | Enabled | Enabled | | | | |
| MachineAPIMigrationVSphere| | | Enabled | Enabled | | | | |
| NetworkConnect| | | Enabled | Enabled | | | | |
| NewOLMBoxCutterRuntime| | | | Enabled | | | | Enabled |
| NewOLMCatalogdAPIV1Metas| | | | Enabled | | | | Enabled |
-| NewOLMPreflightPermissionChecks| | | | Enabled | | | | Enabled |
-| NoRegistryClusterInstall| | | | Enabled | | | | Enabled |
+| NewOLMConfigAPI| | | | Enabled | | | | Enabled |
+| NewOLMOwnSingleNamespace| | | | Enabled | | | | Enabled |
| ProvisioningRequestAvailable| | | Enabled | Enabled | | | | |
| AWSClusterHostedDNS| | | Enabled | Enabled | | | Enabled | Enabled |
-| AWSClusterHostedDNSInstall| | | Enabled | Enabled | | | Enabled | Enabled |
| AWSDedicatedHosts| | | Enabled | Enabled | | | Enabled | Enabled |
-| AWSDualStackInstall| | | Enabled | Enabled | | | Enabled | Enabled |
-| AWSServiceLBNetworkSecurityGroup| | | Enabled | Enabled | | | Enabled | Enabled |
-| AdditionalStorageConfig| | | Enabled | Enabled | | | Enabled | Enabled |
+| AWSEuropeanSovereignCloudInstall| | | Enabled | Enabled | | | Enabled | Enabled |
| AutomatedEtcdBackup| | | Enabled | Enabled | | | Enabled | Enabled |
-| AzureClusterHostedDNSInstall| | | Enabled | Enabled | | | Enabled | Enabled |
| AzureDedicatedHosts| | | Enabled | Enabled | | | Enabled | Enabled |
| AzureDualStackInstall| | | Enabled | Enabled | | | Enabled | Enabled |
| AzureMultiDisk| | | Enabled | Enabled | | | Enabled | Enabled |
-| BootImageSkewEnforcement| | | Enabled | Enabled | | | Enabled | Enabled |
| BootcNodeManagement| | | Enabled | Enabled | | | Enabled | Enabled |
| CBORServingAndStorage| | | Enabled | Enabled | | | Enabled | Enabled |
| CRDCompatibilityRequirementOperator| | | Enabled | Enabled | | | Enabled | Enabled |
-| CRIOCredentialProviderConfig| | | Enabled | Enabled | | | Enabled | Enabled |
+| CRIOCredentialProviderConfig| | Enabled | | Enabled | | Enabled | | Enabled |
| ClientsPreferCBOR| | | Enabled | Enabled | | | Enabled | Enabled |
| ClusterAPIInstallIBMCloud| | | Enabled | Enabled | | | Enabled | Enabled |
| ClusterAPIMachineManagement| | | Enabled | Enabled | | | Enabled | Enabled |
@@ -50,23 +52,19 @@
| ClusterVersionOperatorConfiguration| | | Enabled | Enabled | | | Enabled | Enabled |
| ConfigurablePKI| | | Enabled | Enabled | | | Enabled | Enabled |
| DNSNameResolver| | | Enabled | Enabled | | | Enabled | Enabled |
-| DRAPartitionableDevices| | | Enabled | Enabled | | | Enabled | Enabled |
-| DualReplica| | | Enabled | Enabled | | | Enabled | Enabled |
| DyanmicServiceEndpointIBMCloud| | | Enabled | Enabled | | | Enabled | Enabled |
-| EVPN| | | Enabled | Enabled | | | Enabled | Enabled |
| EtcdBackendQuota| | | Enabled | Enabled | | | Enabled | Enabled |
-| EventTTL| | | Enabled | Enabled | | | Enabled | Enabled |
| Example| | | Enabled | Enabled | | | Enabled | Enabled |
-| ExternalOIDCWithUpstreamParity| | | Enabled | Enabled | | | Enabled | Enabled |
-| GCPClusterHostedDNS| | | Enabled | Enabled | | | Enabled | Enabled |
+| ExternalOIDCExternalClaimsSourcing| | | Enabled | Enabled | | | Enabled | Enabled |
+| ExternalSnapshotMetadata| | | Enabled | Enabled | | | Enabled | Enabled |
| GCPCustomAPIEndpoints| | | Enabled | Enabled | | | Enabled | Enabled |
| GCPCustomAPIEndpointsInstall| | | Enabled | Enabled | | | Enabled | Enabled |
| GCPDualStackInstall| | | Enabled | Enabled | | | Enabled | Enabled |
-| GatewayAPIWithoutOLM| | | Enabled | Enabled | | | Enabled | Enabled |
+| GCPSovereignCloudInstall| | | Enabled | Enabled | | | Enabled | Enabled |
+| GatewayAPIManagementMode| | | Enabled | Enabled | | | Enabled | Enabled |
| HyperShiftOnlyDynamicResourceAllocation| Enabled | | Enabled | | Enabled | | Enabled | |
| ImageModeStatusReporting| | | Enabled | Enabled | | | Enabled | Enabled |
-| IngressControllerDynamicConfigurationManager| | | Enabled | Enabled | | | Enabled | Enabled |
-| IrreconcilableMachineConfig| | | Enabled | Enabled | | | Enabled | Enabled |
+| IngressComponentRouteLabels| | | Enabled | Enabled | | | Enabled | Enabled |
| KMSEncryption| | | Enabled | Enabled | | | Enabled | Enabled |
| MachineAPIMigration| | | Enabled | Enabled | | | Enabled | Enabled |
| MachineAPIMigrationAWS| | | Enabled | Enabled | | | Enabled | Enabled |
@@ -75,51 +73,56 @@
| MinimumKubeletVersion| | | Enabled | Enabled | | | Enabled | Enabled |
| MixedCPUsAllocation| | | Enabled | Enabled | | | Enabled | Enabled |
| MultiDiskSetup| | | Enabled | Enabled | | | Enabled | Enabled |
-| MutatingAdmissionPolicy| | | Enabled | Enabled | | | Enabled | Enabled |
+| NetworkObservabilityInstall| | | Enabled | Enabled | | | Enabled | Enabled |
| NewOLM| | Enabled | | Enabled | | Enabled | | Enabled |
-| NewOLMOwnSingleNamespace| | Enabled | | Enabled | | Enabled | | Enabled |
| NewOLMWebhookProviderOpenshiftServiceCA| | Enabled | | Enabled | | Enabled | | Enabled |
+| NoOverlayMode| | | Enabled | Enabled | | | Enabled | Enabled |
+| NoRegistryClusterInstall| | Enabled | | Enabled | | Enabled | | Enabled |
| NutanixMultiSubnets| | | Enabled | Enabled | | | Enabled | Enabled |
-| OSStreams| | | Enabled | Enabled | | | Enabled | Enabled |
+| OLMLifecycleAndCompatibility| | Enabled | | Enabled | | Enabled | | Enabled |
| OVNObservability| | | Enabled | Enabled | | | Enabled | Enabled |
| OnPremDNSRecords| | | Enabled | Enabled | | | Enabled | Enabled |
| SELinuxMount| | | Enabled | Enabled | | | Enabled | Enabled |
| SignatureStores| | | Enabled | Enabled | | | Enabled | Enabled |
+| TLSAdherence| | | Enabled | Enabled | | | Enabled | Enabled |
+| TLSGroupPreferences| | | Enabled | Enabled | | | Enabled | Enabled |
| VSphereConfigurableMaxAllowedBlockVolumesPerNode| | | Enabled | Enabled | | | Enabled | Enabled |
-| VSphereHostVMGroupZonal| | | Enabled | Enabled | | | Enabled | Enabled |
-| VSphereMixedNodeEnv| | | Enabled | Enabled | | | Enabled | Enabled |
-| VolumeGroupSnapshot| | | Enabled | Enabled | | | Enabled | Enabled |
+| VSphereMultiVCenterDay2| | | Enabled | Enabled | | | Enabled | Enabled |
+| OSStreams| | Enabled | Enabled | Enabled | | Enabled | Enabled | Enabled |
+| AWSClusterHostedDNSInstall| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
+| AWSDualStackInstall| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
+| AWSServiceLBNetworkSecurityGroup| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
+| AdditionalStorageConfig| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
| AzureWorkloadIdentity| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
+| BootImageSkewEnforcement| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
| BuildCSIVolumes| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
-| ConsolePluginContentSecurityPolicy| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
+| DualReplica| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
+| EVPN| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
+| EventTTL| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
| ExternalOIDC| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
| ExternalOIDCWithUIDAndExtraClaimMappings| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
-| GCPClusterHostedDNSInstall| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
-| GatewayAPI| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
-| GatewayAPIController| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
-| HighlyAvailableArbiter| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
+| ExternalOIDCWithUpstreamParity| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
+| GatewayAPIWithoutOLM| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
| ImageStreamImportMode| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
-| ImageVolume| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
+| IngressControllerDynamicConfigurationManager| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
+| IngressControllerMultipleHAProxyVersions| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
| InsightsConfig| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
| InsightsOnDemandDataGather| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
+| IrreconcilableMachineConfig| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
| KMSv1| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
-| MachineConfigNodes| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
-| ManagedBootImages| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
-| ManagedBootImagesAWS| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
-| ManagedBootImagesAzure| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
| ManagedBootImagesCPMS| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
-| ManagedBootImagesvSphere| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
| MetricsCollectionProfiles| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
| MutableCSINodeAllocatableCount| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
+| MutatingAdmissionPolicy| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
| OpenShiftPodSecurityAdmission| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
-| PinnedImages| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
-| RouteExternalCertificate| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
+| SELinuxMountGAReadiness| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
| ServiceAccountTokenNodeBinding| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
| SigstoreImageVerification| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
| SigstoreImageVerificationPKI| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
| StoragePerformantSecurityPolicy| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
| UpgradeStatus| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
-| UserNamespacesPodSecurityStandards| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
-| UserNamespacesSupport| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
+| VSphereHostVMGroupZonal| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
+| VSphereMixedNodeEnv| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
| VSphereMultiDisk| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
| VSphereMultiNetworks| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
+| VolumeGroupSnapshot| Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled | Enabled |
diff --git a/vendor/github.com/openshift/api/helm/v1beta1/doc.go b/vendor/github.com/openshift/api/helm/v1beta1/doc.go
index 8a45cd1c81..85ecec82b9 100644
--- a/vendor/github.com/openshift/api/helm/v1beta1/doc.go
+++ b/vendor/github.com/openshift/api/helm/v1beta1/doc.go
@@ -1,6 +1,7 @@
// +k8s:deepcopy-gen=package,register
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.helm.v1beta1
// +kubebuilder:validation:Optional
// +groupName=helm.openshift.io
diff --git a/vendor/github.com/openshift/api/helm/v1beta1/zz_generated.model_name.go b/vendor/github.com/openshift/api/helm/v1beta1/zz_generated.model_name.go
new file mode 100644
index 0000000000..4cf8aee346
--- /dev/null
+++ b/vendor/github.com/openshift/api/helm/v1beta1/zz_generated.model_name.go
@@ -0,0 +1,51 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1beta1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConnectionConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.helm.v1beta1.ConnectionConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConnectionConfigNamespaceScoped) OpenAPIModelName() string {
+ return "com.github.openshift.api.helm.v1beta1.ConnectionConfigNamespaceScoped"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in HelmChartRepository) OpenAPIModelName() string {
+ return "com.github.openshift.api.helm.v1beta1.HelmChartRepository"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in HelmChartRepositoryList) OpenAPIModelName() string {
+ return "com.github.openshift.api.helm.v1beta1.HelmChartRepositoryList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in HelmChartRepositorySpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.helm.v1beta1.HelmChartRepositorySpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in HelmChartRepositoryStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.helm.v1beta1.HelmChartRepositoryStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ProjectHelmChartRepository) OpenAPIModelName() string {
+ return "com.github.openshift.api.helm.v1beta1.ProjectHelmChartRepository"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ProjectHelmChartRepositoryList) OpenAPIModelName() string {
+ return "com.github.openshift.api.helm.v1beta1.ProjectHelmChartRepositoryList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ProjectHelmChartRepositorySpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.helm.v1beta1.ProjectHelmChartRepositorySpec"
+}
diff --git a/vendor/github.com/openshift/api/image/.codegen.yaml b/vendor/github.com/openshift/api/image/.codegen.yaml
index ffa2c8d9b2..a2d9bd2000 100644
--- a/vendor/github.com/openshift/api/image/.codegen.yaml
+++ b/vendor/github.com/openshift/api/image/.codegen.yaml
@@ -1,2 +1,7 @@
swaggerdocs:
commentPolicy: Warn
+protobuf:
+ disabled: false
+ disabledVersions:
+ - "1.0"
+ - pre012
diff --git a/vendor/github.com/openshift/api/image/v1/doc.go b/vendor/github.com/openshift/api/image/v1/doc.go
index e57d45bbf9..c55344ebcc 100644
--- a/vendor/github.com/openshift/api/image/v1/doc.go
+++ b/vendor/github.com/openshift/api/image/v1/doc.go
@@ -2,6 +2,7 @@
// +k8s:conversion-gen=github.com/openshift/origin/pkg/image/apis/image
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.image.v1
// +groupName=image.openshift.io
// Package v1 is the v1 version of the API.
diff --git a/vendor/github.com/openshift/api/image/v1/zz_generated.model_name.go b/vendor/github.com/openshift/api/image/v1/zz_generated.model_name.go
new file mode 100644
index 0000000000..e1c8b2bc90
--- /dev/null
+++ b/vendor/github.com/openshift/api/image/v1/zz_generated.model_name.go
@@ -0,0 +1,196 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DockerImageReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.DockerImageReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Image) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.Image"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageBlobReferences) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.ImageBlobReferences"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageImportSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.ImageImportSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageImportStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.ImageImportStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageLayer) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.ImageLayer"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageLayerData) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.ImageLayerData"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageList) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.ImageList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageLookupPolicy) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.ImageLookupPolicy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageManifest) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.ImageManifest"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageSignature) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.ImageSignature"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageStream) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.ImageStream"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageStreamImage) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.ImageStreamImage"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageStreamImport) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.ImageStreamImport"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageStreamImportSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.ImageStreamImportSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageStreamImportStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.ImageStreamImportStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageStreamLayers) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.ImageStreamLayers"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageStreamList) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.ImageStreamList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageStreamMapping) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.ImageStreamMapping"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageStreamSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.ImageStreamSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageStreamStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.ImageStreamStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageStreamTag) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.ImageStreamTag"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageStreamTagList) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.ImageStreamTagList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageTag) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.ImageTag"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageTagList) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.ImageTagList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NamedTagEventList) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.NamedTagEventList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RepositoryImportSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.RepositoryImportSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RepositoryImportStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.RepositoryImportStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SecretList) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.SecretList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SignatureCondition) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.SignatureCondition"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SignatureGenericEntity) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.SignatureGenericEntity"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SignatureIssuer) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.SignatureIssuer"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SignatureSubject) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.SignatureSubject"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TagEvent) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.TagEvent"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TagEventCondition) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.TagEventCondition"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TagImportPolicy) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.TagImportPolicy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TagReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.TagReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TagReferencePolicy) OpenAPIModelName() string {
+ return "com.github.openshift.api.image.v1.TagReferencePolicy"
+}
diff --git a/vendor/github.com/openshift/api/imageregistry/v1/doc.go b/vendor/github.com/openshift/api/imageregistry/v1/doc.go
index 32ad6f8141..46761bad0d 100644
--- a/vendor/github.com/openshift/api/imageregistry/v1/doc.go
+++ b/vendor/github.com/openshift/api/imageregistry/v1/doc.go
@@ -1,3 +1,4 @@
// +k8s:deepcopy-gen=package
// +groupName=imageregistry.operator.openshift.io
+// +k8s:openapi-model-package=com.github.openshift.api.imageregistry.v1
package v1
diff --git a/vendor/github.com/openshift/api/imageregistry/v1/zz_generated.model_name.go b/vendor/github.com/openshift/api/imageregistry/v1/zz_generated.model_name.go
new file mode 100644
index 0000000000..bb51d1e7ef
--- /dev/null
+++ b/vendor/github.com/openshift/api/imageregistry/v1/zz_generated.model_name.go
@@ -0,0 +1,141 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AzureNetworkAccess) OpenAPIModelName() string {
+ return "com.github.openshift.api.imageregistry.v1.AzureNetworkAccess"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AzureNetworkAccessInternal) OpenAPIModelName() string {
+ return "com.github.openshift.api.imageregistry.v1.AzureNetworkAccessInternal"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Config) OpenAPIModelName() string {
+ return "com.github.openshift.api.imageregistry.v1.Config"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConfigList) OpenAPIModelName() string {
+ return "com.github.openshift.api.imageregistry.v1.ConfigList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EncryptionAlibaba) OpenAPIModelName() string {
+ return "com.github.openshift.api.imageregistry.v1.EncryptionAlibaba"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImagePruner) OpenAPIModelName() string {
+ return "com.github.openshift.api.imageregistry.v1.ImagePruner"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImagePrunerList) OpenAPIModelName() string {
+ return "com.github.openshift.api.imageregistry.v1.ImagePrunerList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImagePrunerSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.imageregistry.v1.ImagePrunerSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImagePrunerStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.imageregistry.v1.ImagePrunerStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageRegistryConfigProxy) OpenAPIModelName() string {
+ return "com.github.openshift.api.imageregistry.v1.ImageRegistryConfigProxy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageRegistryConfigRequests) OpenAPIModelName() string {
+ return "com.github.openshift.api.imageregistry.v1.ImageRegistryConfigRequests"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageRegistryConfigRequestsLimits) OpenAPIModelName() string {
+ return "com.github.openshift.api.imageregistry.v1.ImageRegistryConfigRequestsLimits"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageRegistryConfigRoute) OpenAPIModelName() string {
+ return "com.github.openshift.api.imageregistry.v1.ImageRegistryConfigRoute"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageRegistryConfigStorage) OpenAPIModelName() string {
+ return "com.github.openshift.api.imageregistry.v1.ImageRegistryConfigStorage"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageRegistryConfigStorageAlibabaOSS) OpenAPIModelName() string {
+ return "com.github.openshift.api.imageregistry.v1.ImageRegistryConfigStorageAlibabaOSS"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageRegistryConfigStorageAzure) OpenAPIModelName() string {
+ return "com.github.openshift.api.imageregistry.v1.ImageRegistryConfigStorageAzure"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageRegistryConfigStorageEmptyDir) OpenAPIModelName() string {
+ return "com.github.openshift.api.imageregistry.v1.ImageRegistryConfigStorageEmptyDir"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageRegistryConfigStorageGCS) OpenAPIModelName() string {
+ return "com.github.openshift.api.imageregistry.v1.ImageRegistryConfigStorageGCS"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageRegistryConfigStorageIBMCOS) OpenAPIModelName() string {
+ return "com.github.openshift.api.imageregistry.v1.ImageRegistryConfigStorageIBMCOS"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageRegistryConfigStoragePVC) OpenAPIModelName() string {
+ return "com.github.openshift.api.imageregistry.v1.ImageRegistryConfigStoragePVC"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageRegistryConfigStorageS3) OpenAPIModelName() string {
+ return "com.github.openshift.api.imageregistry.v1.ImageRegistryConfigStorageS3"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageRegistryConfigStorageS3CloudFront) OpenAPIModelName() string {
+ return "com.github.openshift.api.imageregistry.v1.ImageRegistryConfigStorageS3CloudFront"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageRegistryConfigStorageSwift) OpenAPIModelName() string {
+ return "com.github.openshift.api.imageregistry.v1.ImageRegistryConfigStorageSwift"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageRegistrySpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.imageregistry.v1.ImageRegistrySpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageRegistryStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.imageregistry.v1.ImageRegistryStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KMSEncryptionAlibaba) OpenAPIModelName() string {
+ return "com.github.openshift.api.imageregistry.v1.KMSEncryptionAlibaba"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in S3TrustedCASource) OpenAPIModelName() string {
+ return "com.github.openshift.api.imageregistry.v1.S3TrustedCASource"
+}
diff --git a/vendor/github.com/openshift/api/install.go b/vendor/github.com/openshift/api/install.go
index e4574e7c4f..6efcc1c298 100644
--- a/vendor/github.com/openshift/api/install.go
+++ b/vendor/github.com/openshift/api/install.go
@@ -14,8 +14,6 @@ import (
kauthorizationv1beta1 "k8s.io/api/authorization/v1beta1"
kautoscalingv1 "k8s.io/api/autoscaling/v1"
kautoscalingv2 "k8s.io/api/autoscaling/v2"
- kautoscalingv2beta1 "k8s.io/api/autoscaling/v2beta1"
- kautoscalingv2beta2 "k8s.io/api/autoscaling/v2beta2"
kbatchv1 "k8s.io/api/batch/v1"
kbatchv1beta1 "k8s.io/api/batch/v1beta1"
kcertificatesv1 "k8s.io/api/certificates/v1"
@@ -40,7 +38,6 @@ import (
krbacv1alpha1 "k8s.io/api/rbac/v1alpha1"
krbacv1beta1 "k8s.io/api/rbac/v1beta1"
kschedulingv1 "k8s.io/api/scheduling/v1"
- kschedulingv1alpha1 "k8s.io/api/scheduling/v1alpha1"
kschedulingv1beta1 "k8s.io/api/scheduling/v1beta1"
kstoragev1 "k8s.io/api/storage/v1"
kstoragev1alpha1 "k8s.io/api/storage/v1alpha1"
@@ -134,8 +131,6 @@ var (
kauthorizationv1beta1.AddToScheme,
kautoscalingv1.AddToScheme,
kautoscalingv2.AddToScheme,
- kautoscalingv2beta1.AddToScheme,
- kautoscalingv2beta2.AddToScheme,
kbatchv1.AddToScheme,
kbatchv1beta1.AddToScheme,
kcertificatesv1.AddToScheme,
@@ -160,7 +155,6 @@ var (
krbacv1beta1.AddToScheme,
krbacv1alpha1.AddToScheme,
kschedulingv1.AddToScheme,
- kschedulingv1alpha1.AddToScheme,
kschedulingv1beta1.AddToScheme,
kstoragev1.AddToScheme,
kstoragev1beta1.AddToScheme,
diff --git a/vendor/github.com/openshift/api/kubecontrolplane/v1/doc.go b/vendor/github.com/openshift/api/kubecontrolplane/v1/doc.go
index d8872a6132..8f60e8e439 100644
--- a/vendor/github.com/openshift/api/kubecontrolplane/v1/doc.go
+++ b/vendor/github.com/openshift/api/kubecontrolplane/v1/doc.go
@@ -1,6 +1,7 @@
// +k8s:deepcopy-gen=package,register
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.kubecontrolplane.v1
// +groupName=kubecontrolplane.config.openshift.io
// Package v1 is the v1 version of the API.
diff --git a/vendor/github.com/openshift/api/kubecontrolplane/v1/zz_generated.model_name.go b/vendor/github.com/openshift/api/kubecontrolplane/v1/zz_generated.model_name.go
new file mode 100644
index 0000000000..4048213494
--- /dev/null
+++ b/vendor/github.com/openshift/api/kubecontrolplane/v1/zz_generated.model_name.go
@@ -0,0 +1,76 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AggregatorConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.kubecontrolplane.v1.AggregatorConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KubeAPIServerConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.kubecontrolplane.v1.KubeAPIServerConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KubeAPIServerImagePolicyConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.kubecontrolplane.v1.KubeAPIServerImagePolicyConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KubeAPIServerProjectConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.kubecontrolplane.v1.KubeAPIServerProjectConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KubeControllerManagerConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.kubecontrolplane.v1.KubeControllerManagerConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KubeControllerManagerProjectConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.kubecontrolplane.v1.KubeControllerManagerProjectConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KubeletConnectionInfo) OpenAPIModelName() string {
+ return "com.github.openshift.api.kubecontrolplane.v1.KubeletConnectionInfo"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MasterAuthConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.kubecontrolplane.v1.MasterAuthConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RequestHeaderAuthenticationOptions) OpenAPIModelName() string {
+ return "com.github.openshift.api.kubecontrolplane.v1.RequestHeaderAuthenticationOptions"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ServiceServingCert) OpenAPIModelName() string {
+ return "com.github.openshift.api.kubecontrolplane.v1.ServiceServingCert"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in UserAgentDenyRule) OpenAPIModelName() string {
+ return "com.github.openshift.api.kubecontrolplane.v1.UserAgentDenyRule"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in UserAgentMatchRule) OpenAPIModelName() string {
+ return "com.github.openshift.api.kubecontrolplane.v1.UserAgentMatchRule"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in UserAgentMatchingConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.kubecontrolplane.v1.UserAgentMatchingConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in WebhookTokenAuthenticator) OpenAPIModelName() string {
+ return "com.github.openshift.api.kubecontrolplane.v1.WebhookTokenAuthenticator"
+}
diff --git a/vendor/github.com/openshift/api/legacyconfig/v1/doc.go b/vendor/github.com/openshift/api/legacyconfig/v1/doc.go
index 93fc6dc50d..151f0501e9 100644
--- a/vendor/github.com/openshift/api/legacyconfig/v1/doc.go
+++ b/vendor/github.com/openshift/api/legacyconfig/v1/doc.go
@@ -1,6 +1,7 @@
// +k8s:deepcopy-gen=package,register
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.legacyconfig.v1
// +groupName=legacy.config.openshift.io
// Package v1 is deprecated and exists to ease a transition to current APIs
diff --git a/vendor/github.com/openshift/api/legacyconfig/v1/zz_generated.model_name.go b/vendor/github.com/openshift/api/legacyconfig/v1/zz_generated.model_name.go
new file mode 100644
index 0000000000..1010a860a0
--- /dev/null
+++ b/vendor/github.com/openshift/api/legacyconfig/v1/zz_generated.model_name.go
@@ -0,0 +1,406 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ActiveDirectoryConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.ActiveDirectoryConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AdmissionConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.AdmissionConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AdmissionPluginConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.AdmissionPluginConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AggregatorConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.AggregatorConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AllowAllPasswordIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.AllowAllPasswordIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AuditConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.AuditConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AugmentedActiveDirectoryConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.AugmentedActiveDirectoryConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BasicAuthPasswordIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.BasicAuthPasswordIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildDefaultsConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.BuildDefaultsConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildOverridesConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.BuildOverridesConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CertInfo) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.CertInfo"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClientConnectionOverrides) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.ClientConnectionOverrides"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterNetworkEntry) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.ClusterNetworkEntry"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ControllerConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.ControllerConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ControllerElectionConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.ControllerElectionConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DNSConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.DNSConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DefaultAdmissionConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.DefaultAdmissionConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DenyAllPasswordIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.DenyAllPasswordIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DockerConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.DockerConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EtcdConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.EtcdConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EtcdConnectionInfo) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.EtcdConnectionInfo"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EtcdStorageConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.EtcdStorageConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GitHubIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.GitHubIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GitLabIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.GitLabIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GoogleIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.GoogleIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GrantConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.GrantConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GroupResource) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.GroupResource"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in HTPasswdPasswordIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.HTPasswdPasswordIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in HTTPServingInfo) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.HTTPServingInfo"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.IdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.ImageConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImagePolicyConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.ImagePolicyConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in JenkinsPipelineConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.JenkinsPipelineConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KeystonePasswordIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.KeystonePasswordIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KubeletConnectionInfo) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.KubeletConnectionInfo"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KubernetesMasterConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.KubernetesMasterConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in LDAPAttributeMapping) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.LDAPAttributeMapping"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in LDAPPasswordIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.LDAPPasswordIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in LDAPQuery) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.LDAPQuery"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in LDAPSyncConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.LDAPSyncConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in LocalQuota) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.LocalQuota"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MasterAuthConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.MasterAuthConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MasterClients) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.MasterClients"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MasterConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.MasterConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MasterNetworkConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.MasterNetworkConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MasterVolumeConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.MasterVolumeConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NamedCertificate) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.NamedCertificate"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeAuthConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.NodeAuthConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.NodeConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeNetworkConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.NodeNetworkConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeVolumeConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.NodeVolumeConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OAuthConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.OAuthConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OAuthTemplates) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.OAuthTemplates"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OpenIDClaims) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.OpenIDClaims"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OpenIDIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.OpenIDIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OpenIDURLs) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.OpenIDURLs"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PodManifestConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.PodManifestConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PolicyConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.PolicyConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ProjectConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.ProjectConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RFC2307Config) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.RFC2307Config"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RegistryLocation) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.RegistryLocation"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RemoteConnectionInfo) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.RemoteConnectionInfo"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RequestHeaderAuthenticationOptions) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.RequestHeaderAuthenticationOptions"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RequestHeaderIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.RequestHeaderIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RoutingConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.RoutingConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SecurityAllocator) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.SecurityAllocator"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ServiceAccountConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.ServiceAccountConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ServiceServingCert) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.ServiceServingCert"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ServingInfo) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.ServingInfo"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SessionConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.SessionConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SessionSecret) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.SessionSecret"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SessionSecrets) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.SessionSecrets"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SourceStrategyDefaultsConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.SourceStrategyDefaultsConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in StringSource) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.StringSource"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in StringSourceSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.StringSourceSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TokenConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.TokenConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in UserAgentDenyRule) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.UserAgentDenyRule"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in UserAgentMatchRule) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.UserAgentMatchRule"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in UserAgentMatchingConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.UserAgentMatchingConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in WebhookTokenAuthenticator) OpenAPIModelName() string {
+ return "com.github.openshift.api.legacyconfig.v1.WebhookTokenAuthenticator"
+}
diff --git a/vendor/github.com/openshift/api/machine/v1/doc.go b/vendor/github.com/openshift/api/machine/v1/doc.go
index 7bd97c9507..ceddf5bd77 100644
--- a/vendor/github.com/openshift/api/machine/v1/doc.go
+++ b/vendor/github.com/openshift/api/machine/v1/doc.go
@@ -1,6 +1,7 @@
// +k8s:deepcopy-gen=package,register
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.machine.v1
// +kubebuilder:validation:Optional
// +groupName=machine.openshift.io
diff --git a/vendor/github.com/openshift/api/machine/v1/zz_generated.model_name.go b/vendor/github.com/openshift/api/machine/v1/zz_generated.model_name.go
new file mode 100644
index 0000000000..11bf44a909
--- /dev/null
+++ b/vendor/github.com/openshift/api/machine/v1/zz_generated.model_name.go
@@ -0,0 +1,211 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AWSFailureDomain) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.AWSFailureDomain"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AWSFailureDomainPlacement) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.AWSFailureDomainPlacement"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AWSResourceFilter) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.AWSResourceFilter"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AWSResourceReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.AWSResourceReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AlibabaCloudMachineProviderConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.AlibabaCloudMachineProviderConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AlibabaCloudMachineProviderConfigList) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.AlibabaCloudMachineProviderConfigList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AlibabaCloudMachineProviderStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.AlibabaCloudMachineProviderStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AlibabaResourceReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.AlibabaResourceReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AzureFailureDomain) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.AzureFailureDomain"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BandwidthProperties) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.BandwidthProperties"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ControlPlaneMachineSet) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.ControlPlaneMachineSet"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ControlPlaneMachineSetList) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.ControlPlaneMachineSetList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ControlPlaneMachineSetSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.ControlPlaneMachineSetSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ControlPlaneMachineSetStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.ControlPlaneMachineSetStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ControlPlaneMachineSetStrategy) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.ControlPlaneMachineSetStrategy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ControlPlaneMachineSetTemplate) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.ControlPlaneMachineSetTemplate"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ControlPlaneMachineSetTemplateObjectMeta) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.ControlPlaneMachineSetTemplateObjectMeta"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DataDiskProperties) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.DataDiskProperties"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in FailureDomains) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.FailureDomains"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GCPFailureDomain) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.GCPFailureDomain"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in LoadBalancerReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.LoadBalancerReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NutanixCategory) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.NutanixCategory"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NutanixFailureDomainReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.NutanixFailureDomainReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NutanixGPU) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.NutanixGPU"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NutanixMachineProviderConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.NutanixMachineProviderConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NutanixMachineProviderStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.NutanixMachineProviderStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NutanixResourceIdentifier) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.NutanixResourceIdentifier"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NutanixStorageResourceIdentifier) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.NutanixStorageResourceIdentifier"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NutanixVMDisk) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.NutanixVMDisk"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NutanixVMDiskDeviceProperties) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.NutanixVMDiskDeviceProperties"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NutanixVMStorageConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.NutanixVMStorageConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OpenShiftMachineV1Beta1MachineTemplate) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.OpenShiftMachineV1Beta1MachineTemplate"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OpenStackFailureDomain) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.OpenStackFailureDomain"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PowerVSMachineProviderConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.PowerVSMachineProviderConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PowerVSMachineProviderStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.PowerVSMachineProviderStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PowerVSResource) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.PowerVSResource"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PowerVSSecretReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.PowerVSSecretReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RootVolume) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.RootVolume"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SystemDiskProperties) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.SystemDiskProperties"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Tag) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.Tag"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in VSphereFailureDomain) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1.VSphereFailureDomain"
+}
diff --git a/vendor/github.com/openshift/api/machine/v1alpha1/doc.go b/vendor/github.com/openshift/api/machine/v1alpha1/doc.go
index 111cacb635..201889b656 100644
--- a/vendor/github.com/openshift/api/machine/v1alpha1/doc.go
+++ b/vendor/github.com/openshift/api/machine/v1alpha1/doc.go
@@ -1,6 +1,7 @@
// +k8s:deepcopy-gen=package,register
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.machine.v1alpha1
// +kubebuilder:validation:Optional
// +groupName=machine.openshift.io
diff --git a/vendor/github.com/openshift/api/machine/v1alpha1/zz_generated.model_name.go b/vendor/github.com/openshift/api/machine/v1alpha1/zz_generated.model_name.go
new file mode 100644
index 0000000000..8310e981e9
--- /dev/null
+++ b/vendor/github.com/openshift/api/machine/v1alpha1/zz_generated.model_name.go
@@ -0,0 +1,76 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1alpha1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AdditionalBlockDevice) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1alpha1.AdditionalBlockDevice"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AddressPair) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1alpha1.AddressPair"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BlockDeviceStorage) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1alpha1.BlockDeviceStorage"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BlockDeviceVolume) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1alpha1.BlockDeviceVolume"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Filter) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1alpha1.Filter"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in FixedIPs) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1alpha1.FixedIPs"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NetworkParam) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1alpha1.NetworkParam"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OpenstackProviderSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1alpha1.OpenstackProviderSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PortOpts) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1alpha1.PortOpts"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RootVolume) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1alpha1.RootVolume"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SecurityGroupFilter) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1alpha1.SecurityGroupFilter"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SecurityGroupParam) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1alpha1.SecurityGroupParam"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SubnetFilter) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1alpha1.SubnetFilter"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SubnetParam) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1alpha1.SubnetParam"
+}
diff --git a/vendor/github.com/openshift/api/machine/v1beta1/doc.go b/vendor/github.com/openshift/api/machine/v1beta1/doc.go
index e14fc64e32..5c992f6923 100644
--- a/vendor/github.com/openshift/api/machine/v1beta1/doc.go
+++ b/vendor/github.com/openshift/api/machine/v1beta1/doc.go
@@ -1,6 +1,7 @@
// +k8s:deepcopy-gen=package,register
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.machine.v1beta1
// +kubebuilder:validation:Optional
// +groupName=machine.openshift.io
diff --git a/vendor/github.com/openshift/api/machine/v1beta1/types_machineset.go b/vendor/github.com/openshift/api/machine/v1beta1/types_machineset.go
index be5476344b..cbbe0b337c 100644
--- a/vendor/github.com/openshift/api/machine/v1beta1/types_machineset.go
+++ b/vendor/github.com/openshift/api/machine/v1beta1/types_machineset.go
@@ -129,6 +129,14 @@ type MachineSetStatus struct {
// observedGeneration reflects the generation of the most recently observed MachineSet.
// +optional
ObservedGeneration int64 `json:"observedGeneration,omitempty"`
+ // labelSelector is a label selector, in string format, for Machines corresponding to the MachineSet.
+ // It is exposed via the scale subresource as status.selector.
+ // When omitted, the MachineSet controller has not yet reconciled spec.selector into status.labelSelector.
+ // When present, it must not be empty and must not exceed 4096 characters.
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=4096
+ // +optional
+ LabelSelector string `json:"labelSelector,omitempty"`
// In the event that there is a terminal problem reconciling the
// replicas, both ErrorReason and ErrorMessage will be set. ErrorReason
// will be populated with a succinct value suitable for machine
diff --git a/vendor/github.com/openshift/api/machine/v1beta1/zz_generated.model_name.go b/vendor/github.com/openshift/api/machine/v1beta1/zz_generated.model_name.go
new file mode 100644
index 0000000000..fe84d447fd
--- /dev/null
+++ b/vendor/github.com/openshift/api/machine/v1beta1/zz_generated.model_name.go
@@ -0,0 +1,376 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1beta1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AWSMachineProviderConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.AWSMachineProviderConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AWSMachineProviderConfigList) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.AWSMachineProviderConfigList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AWSMachineProviderStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.AWSMachineProviderStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AWSResourceReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.AWSResourceReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AddressesFromPool) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.AddressesFromPool"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AzureBootDiagnostics) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.AzureBootDiagnostics"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AzureCustomerManagedBootDiagnostics) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.AzureCustomerManagedBootDiagnostics"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AzureDiagnostics) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.AzureDiagnostics"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AzureMachineProviderSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.AzureMachineProviderSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AzureMachineProviderStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.AzureMachineProviderStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BlockDeviceMappingSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.BlockDeviceMappingSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CPUOptions) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.CPUOptions"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Condition) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.Condition"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConfidentialVM) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.ConfidentialVM"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DataDisk) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.DataDisk"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DataDiskManagedDiskParameters) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.DataDiskManagedDiskParameters"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DedicatedHost) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.DedicatedHost"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DedicatedHostStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.DedicatedHostStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DiskEncryptionSetParameters) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.DiskEncryptionSetParameters"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DiskSettings) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.DiskSettings"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DynamicHostAllocationSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.DynamicHostAllocationSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EBSBlockDeviceSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.EBSBlockDeviceSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Filter) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.Filter"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GCPDisk) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.GCPDisk"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GCPEncryptionKeyReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.GCPEncryptionKeyReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GCPGPUConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.GCPGPUConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GCPKMSKeyReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.GCPKMSKeyReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GCPMachineProviderSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.GCPMachineProviderSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GCPMachineProviderStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.GCPMachineProviderStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GCPMetadata) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.GCPMetadata"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GCPNetworkInterface) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.GCPNetworkInterface"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GCPServiceAccount) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.GCPServiceAccount"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GCPShieldedInstanceConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.GCPShieldedInstanceConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in HostPlacement) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.HostPlacement"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Image) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.Image"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in LastOperation) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.LastOperation"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in LifecycleHook) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.LifecycleHook"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in LifecycleHooks) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.LifecycleHooks"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in LoadBalancerReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.LoadBalancerReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Machine) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.Machine"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MachineHealthCheck) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.MachineHealthCheck"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MachineHealthCheckList) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.MachineHealthCheckList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MachineHealthCheckSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.MachineHealthCheckSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MachineHealthCheckStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.MachineHealthCheckStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MachineList) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.MachineList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MachineSet) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.MachineSet"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MachineSetList) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.MachineSetList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MachineSetSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.MachineSetSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MachineSetStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.MachineSetStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MachineSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.MachineSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MachineStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.MachineStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MachineTemplateSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.MachineTemplateSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MetadataServiceOptions) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.MetadataServiceOptions"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NetworkDeviceSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.NetworkDeviceSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NetworkSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.NetworkSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OSDisk) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.OSDisk"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OSDiskManagedDiskParameters) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.OSDiskManagedDiskParameters"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ObjectMeta) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.ObjectMeta"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Placement) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.Placement"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ProviderSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.ProviderSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ResourceManagerTag) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.ResourceManagerTag"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SecurityProfile) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.SecurityProfile"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SecuritySettings) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.SecuritySettings"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SpotMarketOptions) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.SpotMarketOptions"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SpotVMOptions) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.SpotVMOptions"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TagSpecification) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.TagSpecification"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TrustedLaunch) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.TrustedLaunch"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in UEFISettings) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.UEFISettings"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in UnhealthyCondition) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.UnhealthyCondition"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in VMDiskSecurityProfile) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.VMDiskSecurityProfile"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in VSphereDisk) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.VSphereDisk"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in VSphereMachineProviderSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.VSphereMachineProviderSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in VSphereMachineProviderStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.VSphereMachineProviderStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Workspace) OpenAPIModelName() string {
+ return "com.github.openshift.api.machine.v1beta1.Workspace"
+}
diff --git a/vendor/github.com/openshift/api/machine/v1beta1/zz_generated.swagger_doc_generated.go b/vendor/github.com/openshift/api/machine/v1beta1/zz_generated.swagger_doc_generated.go
index 2c4a9030cc..e686cad25a 100644
--- a/vendor/github.com/openshift/api/machine/v1beta1/zz_generated.swagger_doc_generated.go
+++ b/vendor/github.com/openshift/api/machine/v1beta1/zz_generated.swagger_doc_generated.go
@@ -748,6 +748,7 @@ var map_MachineSetStatus = map[string]string{
"readyReplicas": "The number of ready replicas for this MachineSet. A machine is considered ready when the node has been created and is \"Ready\".",
"availableReplicas": "The number of available replicas (ready for at least minReadySeconds) for this MachineSet.",
"observedGeneration": "observedGeneration reflects the generation of the most recently observed MachineSet.",
+ "labelSelector": "labelSelector is a label selector, in string format, for Machines corresponding to the MachineSet. It is exposed via the scale subresource as status.selector. When omitted, the MachineSet controller has not yet reconciled spec.selector into status.labelSelector. When present, it must not be empty and must not exceed 4096 characters.",
"errorReason": "In the event that there is a terminal problem reconciling the replicas, both ErrorReason and ErrorMessage will be set. ErrorReason will be populated with a succinct value suitable for machine interpretation, while ErrorMessage will contain a more verbose string suitable for logging and human consumption.\n\nThese fields should not be set for transitive errors that a controller faces that are expected to be fixed automatically over time (like service outages), but instead indicate that something is fundamentally wrong with the MachineTemplate's spec or the configuration of the machine controller, and that manual intervention is required. Examples of terminal errors would be invalid combinations of settings in the spec, values that are unsupported by the machine controller, or the responsible machine controller itself being critically misconfigured.\n\nAny transient errors that occur during the reconciliation of Machines can be added as events to the MachineSet object and/or logged in the controller's output.",
"conditions": "conditions defines the current state of the MachineSet",
"authoritativeAPI": "authoritativeAPI is the API that is authoritative for this resource. Valid values are MachineAPI, ClusterAPI and Migrating. This value is updated by the migration controller to reflect the authoritative API. Machine API and Cluster API controllers use this value to determine whether or not to reconcile the resource. When set to Migrating, the migration controller is currently performing the handover of authority from one API to the other.",
diff --git a/vendor/github.com/openshift/api/monitoring/v1/doc.go b/vendor/github.com/openshift/api/monitoring/v1/doc.go
index bf046d6ef9..54296a5b37 100644
--- a/vendor/github.com/openshift/api/monitoring/v1/doc.go
+++ b/vendor/github.com/openshift/api/monitoring/v1/doc.go
@@ -1,6 +1,7 @@
// +k8s:deepcopy-gen=package,register
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.monitoring.v1
// +groupName=monitoring.openshift.io
package v1
diff --git a/vendor/github.com/openshift/api/monitoring/v1/zz_generated.model_name.go b/vendor/github.com/openshift/api/monitoring/v1/zz_generated.model_name.go
new file mode 100644
index 0000000000..eb2793cefc
--- /dev/null
+++ b/vendor/github.com/openshift/api/monitoring/v1/zz_generated.model_name.go
@@ -0,0 +1,66 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AlertRelabelConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.monitoring.v1.AlertRelabelConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AlertRelabelConfigList) OpenAPIModelName() string {
+ return "com.github.openshift.api.monitoring.v1.AlertRelabelConfigList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AlertRelabelConfigSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.monitoring.v1.AlertRelabelConfigSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AlertRelabelConfigStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.monitoring.v1.AlertRelabelConfigStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AlertingRule) OpenAPIModelName() string {
+ return "com.github.openshift.api.monitoring.v1.AlertingRule"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AlertingRuleList) OpenAPIModelName() string {
+ return "com.github.openshift.api.monitoring.v1.AlertingRuleList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AlertingRuleSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.monitoring.v1.AlertingRuleSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AlertingRuleStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.monitoring.v1.AlertingRuleStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PrometheusRuleRef) OpenAPIModelName() string {
+ return "com.github.openshift.api.monitoring.v1.PrometheusRuleRef"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RelabelConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.monitoring.v1.RelabelConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Rule) OpenAPIModelName() string {
+ return "com.github.openshift.api.monitoring.v1.Rule"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RuleGroup) OpenAPIModelName() string {
+ return "com.github.openshift.api.monitoring.v1.RuleGroup"
+}
diff --git a/vendor/github.com/openshift/api/network/.codegen.yaml b/vendor/github.com/openshift/api/network/.codegen.yaml
index ab56605cdc..e9a0f18976 100644
--- a/vendor/github.com/openshift/api/network/.codegen.yaml
+++ b/vendor/github.com/openshift/api/network/.codegen.yaml
@@ -1 +1,4 @@
-schemapatch:
+protobuf:
+ disabled: false
+ disabledVersions:
+ - v1alpha1
diff --git a/vendor/github.com/openshift/api/network/v1/doc.go b/vendor/github.com/openshift/api/network/v1/doc.go
index 2816420d96..a3a0e74635 100644
--- a/vendor/github.com/openshift/api/network/v1/doc.go
+++ b/vendor/github.com/openshift/api/network/v1/doc.go
@@ -2,6 +2,7 @@
// +k8s:conversion-gen=github.com/openshift/origin/pkg/network/apis/network
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.network.v1
// +groupName=network.openshift.io
// Package v1 is the v1 version of the API.
diff --git a/vendor/github.com/openshift/api/network/v1/zz_generated.model_name.go b/vendor/github.com/openshift/api/network/v1/zz_generated.model_name.go
new file mode 100644
index 0000000000..20c5089052
--- /dev/null
+++ b/vendor/github.com/openshift/api/network/v1/zz_generated.model_name.go
@@ -0,0 +1,66 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterNetwork) OpenAPIModelName() string {
+ return "com.github.openshift.api.network.v1.ClusterNetwork"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterNetworkEntry) OpenAPIModelName() string {
+ return "com.github.openshift.api.network.v1.ClusterNetworkEntry"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterNetworkList) OpenAPIModelName() string {
+ return "com.github.openshift.api.network.v1.ClusterNetworkList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EgressNetworkPolicy) OpenAPIModelName() string {
+ return "com.github.openshift.api.network.v1.EgressNetworkPolicy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EgressNetworkPolicyList) OpenAPIModelName() string {
+ return "com.github.openshift.api.network.v1.EgressNetworkPolicyList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EgressNetworkPolicyPeer) OpenAPIModelName() string {
+ return "com.github.openshift.api.network.v1.EgressNetworkPolicyPeer"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EgressNetworkPolicyRule) OpenAPIModelName() string {
+ return "com.github.openshift.api.network.v1.EgressNetworkPolicyRule"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EgressNetworkPolicySpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.network.v1.EgressNetworkPolicySpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in HostSubnet) OpenAPIModelName() string {
+ return "com.github.openshift.api.network.v1.HostSubnet"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in HostSubnetList) OpenAPIModelName() string {
+ return "com.github.openshift.api.network.v1.HostSubnetList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NetNamespace) OpenAPIModelName() string {
+ return "com.github.openshift.api.network.v1.NetNamespace"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NetNamespaceList) OpenAPIModelName() string {
+ return "com.github.openshift.api.network.v1.NetNamespaceList"
+}
diff --git a/vendor/github.com/openshift/api/network/v1alpha1/doc.go b/vendor/github.com/openshift/api/network/v1alpha1/doc.go
index 35539c458c..c02bccc319 100644
--- a/vendor/github.com/openshift/api/network/v1alpha1/doc.go
+++ b/vendor/github.com/openshift/api/network/v1alpha1/doc.go
@@ -1,6 +1,7 @@
// +k8s:deepcopy-gen=package,register
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.network.v1alpha1
// +groupName=network.openshift.io
package v1alpha1
diff --git a/vendor/github.com/openshift/api/network/v1alpha1/zz_generated.model_name.go b/vendor/github.com/openshift/api/network/v1alpha1/zz_generated.model_name.go
new file mode 100644
index 0000000000..6a67483281
--- /dev/null
+++ b/vendor/github.com/openshift/api/network/v1alpha1/zz_generated.model_name.go
@@ -0,0 +1,36 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1alpha1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DNSNameResolver) OpenAPIModelName() string {
+ return "com.github.openshift.api.network.v1alpha1.DNSNameResolver"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DNSNameResolverList) OpenAPIModelName() string {
+ return "com.github.openshift.api.network.v1alpha1.DNSNameResolverList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DNSNameResolverResolvedAddress) OpenAPIModelName() string {
+ return "com.github.openshift.api.network.v1alpha1.DNSNameResolverResolvedAddress"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DNSNameResolverResolvedName) OpenAPIModelName() string {
+ return "com.github.openshift.api.network.v1alpha1.DNSNameResolverResolvedName"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DNSNameResolverSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.network.v1alpha1.DNSNameResolverSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DNSNameResolverStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.network.v1alpha1.DNSNameResolverStatus"
+}
diff --git a/vendor/github.com/openshift/api/networkoperator/.codegen.yaml b/vendor/github.com/openshift/api/networkoperator/.codegen.yaml
index ffa2c8d9b2..f10357951b 100644
--- a/vendor/github.com/openshift/api/networkoperator/.codegen.yaml
+++ b/vendor/github.com/openshift/api/networkoperator/.codegen.yaml
@@ -1,2 +1,4 @@
swaggerdocs:
commentPolicy: Warn
+protobuf:
+ disabled: false
diff --git a/vendor/github.com/openshift/api/networkoperator/v1/doc.go b/vendor/github.com/openshift/api/networkoperator/v1/doc.go
index 3c958bbc6e..e49a8969ce 100644
--- a/vendor/github.com/openshift/api/networkoperator/v1/doc.go
+++ b/vendor/github.com/openshift/api/networkoperator/v1/doc.go
@@ -1,5 +1,6 @@
// Package v1 contains API Schema definitions for the network v1 API group
// +k8s:deepcopy-gen=package,register
+// +k8s:openapi-model-package=com.github.openshift.api.networkoperator.v1
// +groupName=network.operator.openshift.io
// +kubebuilder:validation:Optional
package v1
diff --git a/vendor/github.com/openshift/api/networkoperator/v1/zz_generated.model_name.go b/vendor/github.com/openshift/api/networkoperator/v1/zz_generated.model_name.go
new file mode 100644
index 0000000000..c667f3b2a4
--- /dev/null
+++ b/vendor/github.com/openshift/api/networkoperator/v1/zz_generated.model_name.go
@@ -0,0 +1,56 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EgressRouter) OpenAPIModelName() string {
+ return "com.github.openshift.api.networkoperator.v1.EgressRouter"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EgressRouterAddress) OpenAPIModelName() string {
+ return "com.github.openshift.api.networkoperator.v1.EgressRouterAddress"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EgressRouterInterface) OpenAPIModelName() string {
+ return "com.github.openshift.api.networkoperator.v1.EgressRouterInterface"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EgressRouterList) OpenAPIModelName() string {
+ return "com.github.openshift.api.networkoperator.v1.EgressRouterList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EgressRouterSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.networkoperator.v1.EgressRouterSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EgressRouterStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.networkoperator.v1.EgressRouterStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EgressRouterStatusCondition) OpenAPIModelName() string {
+ return "com.github.openshift.api.networkoperator.v1.EgressRouterStatusCondition"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in L4RedirectRule) OpenAPIModelName() string {
+ return "com.github.openshift.api.networkoperator.v1.L4RedirectRule"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MacvlanConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.networkoperator.v1.MacvlanConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RedirectConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.networkoperator.v1.RedirectConfig"
+}
diff --git a/vendor/github.com/openshift/api/oauth/.codegen.yaml b/vendor/github.com/openshift/api/oauth/.codegen.yaml
index ffa2c8d9b2..f10357951b 100644
--- a/vendor/github.com/openshift/api/oauth/.codegen.yaml
+++ b/vendor/github.com/openshift/api/oauth/.codegen.yaml
@@ -1,2 +1,4 @@
swaggerdocs:
commentPolicy: Warn
+protobuf:
+ disabled: false
diff --git a/vendor/github.com/openshift/api/oauth/v1/doc.go b/vendor/github.com/openshift/api/oauth/v1/doc.go
index cae9e70d4a..d39b241130 100644
--- a/vendor/github.com/openshift/api/oauth/v1/doc.go
+++ b/vendor/github.com/openshift/api/oauth/v1/doc.go
@@ -2,6 +2,7 @@
// +k8s:conversion-gen=github.com/openshift/origin/pkg/oauth/apis/oauth
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.oauth.v1
// +groupName=oauth.openshift.io
// Package v1 is the v1 version of the API.
diff --git a/vendor/github.com/openshift/api/oauth/v1/zz_generated.model_name.go b/vendor/github.com/openshift/api/oauth/v1/zz_generated.model_name.go
new file mode 100644
index 0000000000..9a471d2c4a
--- /dev/null
+++ b/vendor/github.com/openshift/api/oauth/v1/zz_generated.model_name.go
@@ -0,0 +1,76 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterRoleScopeRestriction) OpenAPIModelName() string {
+ return "com.github.openshift.api.oauth.v1.ClusterRoleScopeRestriction"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OAuthAccessToken) OpenAPIModelName() string {
+ return "com.github.openshift.api.oauth.v1.OAuthAccessToken"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OAuthAccessTokenList) OpenAPIModelName() string {
+ return "com.github.openshift.api.oauth.v1.OAuthAccessTokenList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OAuthAuthorizeToken) OpenAPIModelName() string {
+ return "com.github.openshift.api.oauth.v1.OAuthAuthorizeToken"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OAuthAuthorizeTokenList) OpenAPIModelName() string {
+ return "com.github.openshift.api.oauth.v1.OAuthAuthorizeTokenList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OAuthClient) OpenAPIModelName() string {
+ return "com.github.openshift.api.oauth.v1.OAuthClient"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OAuthClientAuthorization) OpenAPIModelName() string {
+ return "com.github.openshift.api.oauth.v1.OAuthClientAuthorization"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OAuthClientAuthorizationList) OpenAPIModelName() string {
+ return "com.github.openshift.api.oauth.v1.OAuthClientAuthorizationList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OAuthClientList) OpenAPIModelName() string {
+ return "com.github.openshift.api.oauth.v1.OAuthClientList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OAuthRedirectReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.oauth.v1.OAuthRedirectReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RedirectReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.oauth.v1.RedirectReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ScopeRestriction) OpenAPIModelName() string {
+ return "com.github.openshift.api.oauth.v1.ScopeRestriction"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in UserOAuthAccessToken) OpenAPIModelName() string {
+ return "com.github.openshift.api.oauth.v1.UserOAuthAccessToken"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in UserOAuthAccessTokenList) OpenAPIModelName() string {
+ return "com.github.openshift.api.oauth.v1.UserOAuthAccessTokenList"
+}
diff --git a/vendor/github.com/openshift/api/openshiftcontrolplane/v1/doc.go b/vendor/github.com/openshift/api/openshiftcontrolplane/v1/doc.go
index 4528e3c4a6..706f46006e 100644
--- a/vendor/github.com/openshift/api/openshiftcontrolplane/v1/doc.go
+++ b/vendor/github.com/openshift/api/openshiftcontrolplane/v1/doc.go
@@ -1,6 +1,7 @@
// +k8s:deepcopy-gen=package,register
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.openshiftcontrolplane.v1
// +groupName=openshiftcontrolplane.config.openshift.io
// Package v1 is the v1 version of the API.
diff --git a/vendor/github.com/openshift/api/openshiftcontrolplane/v1/zz_generated.model_name.go b/vendor/github.com/openshift/api/openshiftcontrolplane/v1/zz_generated.model_name.go
new file mode 100644
index 0000000000..b843518b15
--- /dev/null
+++ b/vendor/github.com/openshift/api/openshiftcontrolplane/v1/zz_generated.model_name.go
@@ -0,0 +1,131 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in APIServers) OpenAPIModelName() string {
+ return "com.github.openshift.api.openshiftcontrolplane.v1.APIServers"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildControllerConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.openshiftcontrolplane.v1.BuildControllerConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildDefaultsConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.openshiftcontrolplane.v1.BuildDefaultsConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BuildOverridesConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.openshiftcontrolplane.v1.BuildOverridesConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterNetworkEntry) OpenAPIModelName() string {
+ return "com.github.openshift.api.openshiftcontrolplane.v1.ClusterNetworkEntry"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DeployerControllerConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.openshiftcontrolplane.v1.DeployerControllerConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DockerPullSecretControllerConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.openshiftcontrolplane.v1.DockerPullSecretControllerConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in FrontProxyConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.openshiftcontrolplane.v1.FrontProxyConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.openshiftcontrolplane.v1.ImageConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageImportControllerConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.openshiftcontrolplane.v1.ImageImportControllerConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImagePolicyConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.openshiftcontrolplane.v1.ImagePolicyConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IngressControllerConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.openshiftcontrolplane.v1.IngressControllerConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in JenkinsPipelineConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.openshiftcontrolplane.v1.JenkinsPipelineConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NetworkControllerConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.openshiftcontrolplane.v1.NetworkControllerConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OpenShiftAPIServerConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.openshiftcontrolplane.v1.OpenShiftAPIServerConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OpenShiftControllerManagerConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.openshiftcontrolplane.v1.OpenShiftControllerManagerConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PerGroupOptions) OpenAPIModelName() string {
+ return "com.github.openshift.api.openshiftcontrolplane.v1.PerGroupOptions"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ProjectConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.openshiftcontrolplane.v1.ProjectConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RegistryLocation) OpenAPIModelName() string {
+ return "com.github.openshift.api.openshiftcontrolplane.v1.RegistryLocation"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ResourceQuotaControllerConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.openshiftcontrolplane.v1.ResourceQuotaControllerConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RoutingConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.openshiftcontrolplane.v1.RoutingConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SecurityAllocator) OpenAPIModelName() string {
+ return "com.github.openshift.api.openshiftcontrolplane.v1.SecurityAllocator"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ServiceAccountControllerConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.openshiftcontrolplane.v1.ServiceAccountControllerConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ServiceServingCert) OpenAPIModelName() string {
+ return "com.github.openshift.api.openshiftcontrolplane.v1.ServiceServingCert"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SourceStrategyDefaultsConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.openshiftcontrolplane.v1.SourceStrategyDefaultsConfig"
+}
diff --git a/vendor/github.com/openshift/api/operator/v1/doc.go b/vendor/github.com/openshift/api/operator/v1/doc.go
index 3de961a7fc..1aa50336ad 100644
--- a/vendor/github.com/openshift/api/operator/v1/doc.go
+++ b/vendor/github.com/openshift/api/operator/v1/doc.go
@@ -1,6 +1,7 @@
// +k8s:deepcopy-gen=package,register
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.operator.v1
// +kubebuilder:validation:Optional
// +groupName=operator.openshift.io
diff --git a/vendor/github.com/openshift/api/operator/v1/types.go b/vendor/github.com/openshift/api/operator/v1/types.go
index 3a2141abb9..599ceb03e1 100644
--- a/vendor/github.com/openshift/api/operator/v1/types.go
+++ b/vendor/github.com/openshift/api/operator/v1/types.go
@@ -266,6 +266,18 @@ type NodeStatus struct {
// +required
NodeName string `json:"nodeName"`
+ // nodeUID is the UID of the node.
+ // This field is used to detect that a node has been deleted and recreated
+ // with the same name. When the UID changes, it indicates the node is a
+ // new instance and the controller should treat this status entry as stale.
+ // When omitted, UID-based node replacement detection is not available
+ // for this entry.
+ // +kubebuilder:validation:MinLength=36
+ // +kubebuilder:validation:MaxLength=36
+ // +kubebuilder:validation:Format=uuid
+ // +optional
+ NodeUID string `json:"nodeUID,omitempty"`
+
// currentRevision is the generation of the most recently successful deployment.
// Can not be set on creation of a nodeStatus. Updates must only increase the value.
// +kubebuilder:validation:XValidation:rule="self >= oldSelf",message="must only increase"
diff --git a/vendor/github.com/openshift/api/operator/v1/types_authentication.go b/vendor/github.com/openshift/api/operator/v1/types_authentication.go
index 7cc22d1e4e..55fc62a791 100644
--- a/vendor/github.com/openshift/api/operator/v1/types_authentication.go
+++ b/vendor/github.com/openshift/api/operator/v1/types_authentication.go
@@ -33,6 +33,94 @@ type Authentication struct {
type AuthenticationSpec struct {
OperatorSpec `json:",inline"`
+
+ // proxy configures proxy settings for outbound connections made
+ // by the authentication stack. When set, it replaces the
+ // cluster-wide proxy (proxy.config.openshift.io/cluster)
+ // entirely for authentication — individual fields are not
+ // inherited from the cluster-wide configuration. When omitted,
+ // the cluster-wide proxy is used if configured; otherwise no
+ // proxy is used.
+ // +openshift:enable:FeatureGate=AuthenticationComponentProxy
+ // +optional
+ Proxy AuthenticationProxyConfig `json:"proxy,omitzero"`
+}
+
+// AuthenticationProxyConfig holds proxy configuration scoped to
+// authentication components (the OAuth server and the cluster
+// authentication operator).
+// +kubebuilder:validation:MinProperties=1
+// +kubebuilder:validation:XValidation:rule="has(self.httpProxy) || has(self.httpsProxy)",message="at least one of httpProxy or httpsProxy must be specified"
+type AuthenticationProxyConfig struct {
+ // httpProxy is the URL of the proxy for HTTP requests.
+ // Must be a valid URL with http or https scheme, a non-empty
+ // hostname, and no path, query parameters, or fragment.
+ // Userinfo (e.g. user:password@host) is allowed for proxy
+ // authentication. Maximum length is 2048 characters.
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=2048
+ // +kubebuilder:validation:XValidation:rule="isURL(self)",message="httpProxy must be a valid URL"
+ // +kubebuilder:validation:XValidation:rule="!isURL(self) || url(self).getScheme() in ['http', 'https']",message="httpProxy must use http or https scheme"
+ // +kubebuilder:validation:XValidation:rule="!isURL(self) || size(url(self).getHostname()) > 0",message="httpProxy must contain a hostname"
+ // +kubebuilder:validation:XValidation:rule="!isURL(self) || url(self).getEscapedPath() == '' || url(self).getEscapedPath() == '/'",message="httpProxy must not contain a path"
+ // +kubebuilder:validation:XValidation:rule="!isURL(self) || url(self).getQuery().size() == 0",message="httpProxy must not contain query parameters"
+ // +kubebuilder:validation:XValidation:rule="!self.matches('.*#.*')",message="httpProxy must not contain a fragment"
+ // +optional
+ HTTPProxy string `json:"httpProxy,omitempty"`
+
+ // httpsProxy is the URL of the proxy for HTTPS requests.
+ // Must be a valid URL with http or https scheme, a non-empty
+ // hostname, and no path, query parameters, or fragment.
+ // Userinfo (e.g. user:password@host) is allowed for proxy
+ // authentication. Maximum length is 2048 characters.
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=2048
+ // +kubebuilder:validation:XValidation:rule="isURL(self)",message="httpsProxy must be a valid URL"
+ // +kubebuilder:validation:XValidation:rule="!isURL(self) || url(self).getScheme() in ['http', 'https']",message="httpsProxy must use http or https scheme"
+ // +kubebuilder:validation:XValidation:rule="!isURL(self) || size(url(self).getHostname()) > 0",message="httpsProxy must contain a hostname"
+ // +kubebuilder:validation:XValidation:rule="!isURL(self) || url(self).getEscapedPath() == '' || url(self).getEscapedPath() == '/'",message="httpsProxy must not contain a path"
+ // +kubebuilder:validation:XValidation:rule="!isURL(self) || url(self).getQuery().size() == 0",message="httpsProxy must not contain query parameters"
+ // +kubebuilder:validation:XValidation:rule="!self.matches('.*#.*')",message="httpsProxy must not contain a fragment"
+ // +optional
+ HTTPSProxy string `json:"httpsProxy,omitempty"`
+
+ // noProxy is a list of hostnames and/or CIDRs and/or IPs for which
+ // the proxy should not be used. Must contain at least one entry
+ // when set. Each entry must be between 1 and 253 characters long
+ // and at most 64 entries are allowed. Duplicate
+ // entries are not permitted. Entries that are not valid hostnames,
+ // CIDRs, or IPs are silently ignored. Cluster-internal defaults
+ // (.cluster.local, .svc, 127.0.0.1, localhost) are always appended
+ // automatically and do not need to be included.
+ // +listType=set
+ // +kubebuilder:validation:MinItems=1
+ // +kubebuilder:validation:MaxItems=64
+ // +kubebuilder:validation:items:MinLength=1
+ // +kubebuilder:validation:items:MaxLength=253
+ // +optional
+ NoProxy []string `json:"noProxy,omitempty"`
+
+ // trustedCA is a reference to a ConfigMap in the openshift-config
+ // namespace containing a CA certificate bundle under the key
+ // "ca-bundle.crt". This bundle is appended to the system trust store
+ // used by authentication components for proxy TLS connections.
+ // When omitted, only the system trust store is used.
+ // +optional
+ TrustedCA AuthenticationConfigMapReference `json:"trustedCA,omitzero"`
+}
+
+// AuthenticationConfigMapReference references a ConfigMap in the
+// openshift-config namespace.
+type AuthenticationConfigMapReference struct {
+ // name is the metadata.name of the referenced ConfigMap.
+ // Must be a valid DNS subdomain name (RFC 1123): at most 253
+ // characters, only lowercase alphanumeric characters, '-' or
+ // '.', starting and ending with an alphanumeric character.
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=253
+ // +kubebuilder:validation:XValidation:rule="!format.dns1123Subdomain().validate(self).hasValue()",message="name must be a valid DNS subdomain name: contain no more than 253 characters, contain only lowercase alphanumeric characters, '-' or '.', and start and end with an alphanumeric character"
+ // +required
+ Name string `json:"name,omitempty"`
}
type AuthenticationStatus struct {
@@ -49,6 +137,11 @@ type OAuthAPIServerStatus struct {
// +optional
// +kubebuilder:validation:Minimum=0
LatestAvailableRevision int32 `json:"latestAvailableRevision,omitempty"`
+
+ // encryptionStatus contains status reports for the KMS plugin health and its key rotation.
+ // +optional
+ // +openshift:enable:FeatureGate=KMSEncryption
+ EncryptionStatus KMSEncryptionStatus `json:"encryptionStatus,omitempty,omitzero"`
}
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
diff --git a/vendor/github.com/openshift/api/operator/v1/types_csi_cluster_driver.go b/vendor/github.com/openshift/api/operator/v1/types_csi_cluster_driver.go
index 53c71aabb6..fca2c808d3 100644
--- a/vendor/github.com/openshift/api/operator/v1/types_csi_cluster_driver.go
+++ b/vendor/github.com/openshift/api/operator/v1/types_csi_cluster_driver.go
@@ -21,6 +21,9 @@ import (
// +kubebuilder:subresource:status
// +openshift:api-approved.openshift.io=https://github.com/openshift/api/pull/701
// +openshift:file-pattern=cvoRunLevel=0000_50,operatorName=csi-driver,operatorOrdering=01
+// +kubebuilder:validation:XValidation:rule="self.spec.?driverConfig.driverType.orValue('') == 'SecretsStore' ? self.metadata.name == 'secrets-store.csi.k8s.io' : true",message="driverType 'SecretsStore' requires metadata.name 'secrets-store.csi.k8s.io'"
+// +kubebuilder:validation:XValidation:rule="self.metadata.name == 'secrets-store.csi.k8s.io' ? (!has(self.spec.driverConfig) || self.spec.driverConfig.driverType == 'SecretsStore') : true",message="metadata.name 'secrets-store.csi.k8s.io' requires driverType 'SecretsStore'"
+// +kubebuilder:validation:XValidation:rule="oldSelf.spec.?driverConfig.?secretsStore.?tokenRequests.?type.orValue('') != 'Managed' || self.spec.?driverConfig.?secretsStore.?tokenRequests.?type.orValue('') == 'Managed'",message="tokenRequests type cannot be changed from Managed"
// ClusterCSIDriver object allows management and configuration of a CSI driver operator
// installed by default in OpenShift. Name of the object must be name of the CSI driver
@@ -113,25 +116,27 @@ type ClusterCSIDriverSpec struct {
}
// CSIDriverType indicates type of CSI driver being configured.
-// +kubebuilder:validation:Enum="";AWS;Azure;GCP;IBMCloud;vSphere
+// +kubebuilder:validation:Enum="";AWS;Azure;GCP;IBMCloud;vSphere;SecretsStore
type CSIDriverType string
const (
- AWSDriverType CSIDriverType = "AWS"
- AzureDriverType CSIDriverType = "Azure"
- GCPDriverType CSIDriverType = "GCP"
- IBMCloudDriverType CSIDriverType = "IBMCloud"
- VSphereDriverType CSIDriverType = "vSphere"
+ AWSDriverType CSIDriverType = "AWS"
+ AzureDriverType CSIDriverType = "Azure"
+ GCPDriverType CSIDriverType = "GCP"
+ IBMCloudDriverType CSIDriverType = "IBMCloud"
+ VSphereDriverType CSIDriverType = "vSphere"
+ SecretsStoreDriverType CSIDriverType = "SecretsStore"
)
// CSIDriverConfigSpec defines configuration spec that can be
// used to optionally configure a specific CSI Driver.
// +kubebuilder:validation:XValidation:rule="has(self.driverType) && self.driverType == 'IBMCloud' ? has(self.ibmcloud) : !has(self.ibmcloud)",message="ibmcloud must be set if driverType is 'IBMCloud', but remain unset otherwise"
+// +kubebuilder:validation:XValidation:rule="has(self.driverType) && self.driverType == 'SecretsStore' ? has(self.secretsStore) : !has(self.secretsStore)",message="secretsStore must be set if driverType is 'SecretsStore', but remain unset otherwise"
// +union
type CSIDriverConfigSpec struct {
// driverType indicates type of CSI driver for which the
// driverConfig is being applied to.
- // Valid values are: AWS, Azure, GCP, IBMCloud, vSphere and omitted.
+ // Valid values are: AWS, Azure, GCP, IBMCloud, vSphere, SecretsStore and omitted.
// Consumers should treat unknown values as a NO-OP.
// +required
// +unionDiscriminator
@@ -156,6 +161,10 @@ type CSIDriverConfigSpec struct {
// vSphere is used to configure the vsphere CSI driver.
// +optional
VSphere *VSphereCSIDriverConfigSpec `json:"vSphere,omitempty"`
+
+ // secretsStore is used to configure the Secrets Store CSI driver.
+ // +optional
+ SecretsStore SecretsStoreCSIDriverConfigSpec `json:"secretsStore,omitzero"`
}
// AWSCSIDriverConfigSpec defines properties that can be configured for the AWS CSI driver.
@@ -163,7 +172,15 @@ type AWSCSIDriverConfigSpec struct {
// kmsKeyARN sets the cluster default storage class to encrypt volumes with a user-defined KMS key,
// rather than the default KMS key used by AWS.
// The value may be either the ARN or Alias ARN of a KMS key.
- // +kubebuilder:validation:Pattern:=`^arn:(aws|aws-cn|aws-us-gov|aws-iso|aws-iso-b|aws-iso-e|aws-iso-f):kms:[a-z0-9-]+:[0-9]{12}:(key|alias)\/.*$`
+ //
+ // The ARN must follow the format: arn::kms:::(key|alias)/, where:
+ // is the AWS partition (aws, aws-cn, aws-us-gov, aws-iso, aws-iso-b, aws-iso-e, aws-iso-f, or aws-eusc),
+ // is the AWS region,
+ // is a 12-digit numeric identifier for the AWS account,
+ // is the KMS key ID or alias name.
+ //
+ // +openshift:validation:FeatureGateAwareXValidation:featureGate="",rule=`matches(self, '^arn:(aws|aws-cn|aws-us-gov|aws-iso|aws-iso-b|aws-iso-e|aws-iso-f):kms:[a-z0-9-]+:[0-9]{12}:(key|alias)/.*$')`,message=`kmsKeyARN must be a valid AWS KMS key ARN in the format: arn::kms:::(key|alias)/`
+ // +openshift:validation:FeatureGateAwareXValidation:featureGate=AWSEuropeanSovereignCloudInstall,rule=`matches(self, '^arn:(aws|aws-cn|aws-us-gov|aws-iso|aws-iso-b|aws-iso-e|aws-iso-f|aws-eusc):kms:[a-z0-9-]+:[0-9]{12}:(key|alias)/.*$')`,message=`kmsKeyARN must be a valid AWS KMS key ARN in the format: arn::kms:::(key|alias)/`
// +optional
KMSKeyARN string `json:"kmsKeyARN,omitempty"`
@@ -381,6 +398,158 @@ type VSphereCSIDriverConfigSpec struct {
MaxAllowedBlockVolumesPerNode int32 `json:"maxAllowedBlockVolumesPerNode,omitempty"`
}
+// SecretsStoreCSIDriverConfigSpec defines properties that can be configured for the Secrets Store CSI driver.
+// +kubebuilder:validation:MinProperties=1
+type SecretsStoreCSIDriverConfigSpec struct {
+ // secretRotation controls automatic secret rotation behavior.
+ // When omitted, secret rotation is enabled with a default poll interval of 2 minutes.
+ // +optional
+ SecretRotation SecretsStoreSecretRotation `json:"secretRotation,omitzero"`
+
+ // tokenRequests controls service account token configuration for
+ // workload identity federation (WIF) with cloud providers.
+ // When omitted, the operator preserves any existing tokenRequests
+ // already configured on the CSIDriver object without modification.
+ // +optional
+ TokenRequests SecretsStoreTokenRequests `json:"tokenRequests,omitzero"`
+}
+
+// TokenRequestsType determines how the operator manages the tokenRequests
+// field on the storage.k8s.io CSIDriver object.
+// +kubebuilder:validation:Enum=Managed;Unmanaged
+type TokenRequestsType string
+
+const (
+ // TokenRequestsManaged means the operator uses the audiences list
+ // as the sole source of truth for the CSIDriver.spec.tokenRequests field.
+ TokenRequestsManaged TokenRequestsType = "Managed"
+
+ // TokenRequestsUnmanaged means the operator preserves any existing
+ // tokenRequests already configured on the CSIDriver object and does not
+ // overwrite them.
+ TokenRequestsUnmanaged TokenRequestsType = "Unmanaged"
+)
+
+// SecretsStoreTokenRequests configures how service account tokens are
+// provided to the Secrets Store CSI driver for workload identity federation.
+// +kubebuilder:validation:XValidation:rule="has(self.type) && self.type == 'Managed' ? has(self.managed) : !has(self.managed)",message="managed must be set when type is 'Managed', and must not be set otherwise"
+// +union
+type SecretsStoreTokenRequests struct {
+ // type determines how the operator manages tokenRequests on the CSIDriver object.
+ // When "Unmanaged", existing tokenRequests on the CSIDriver are preserved
+ // and the managed field is not used.
+ // When "Managed", the operator sets tokenRequests from the audiences
+ // specified in the managed field, replacing any previously configured values.
+ // Once set to "Managed", type cannot be reverted back to "Unmanaged".
+ // +unionDiscriminator
+ // +required
+ Type TokenRequestsType `json:"type,omitempty"`
+
+ // managed holds configuration for operator-managed tokenRequests.
+ // Only valid when type is "Managed".
+ // +optional
+ Managed ManagedTokenRequests `json:"managed,omitzero"`
+}
+
+// ManagedTokenRequests holds the configuration for operator-managed
+// service account token requests.
+// +kubebuilder:validation:MinProperties=1
+type ManagedTokenRequests struct {
+ // audiences specifies service account token audiences that kubelet will
+ // provide to the CSI driver during NodePublishVolume calls. These tokens
+ // enable workload identity federation (WIF) with cloud providers such as
+ // AWS, Azure, and GCP.
+ // When empty, the operator clears all tokenRequests from the CSIDriver object.
+ // +optional
+ // +listType=map
+ // +listMapKey=audience
+ // +kubebuilder:validation:MinItems=0
+ // +kubebuilder:validation:MaxItems=10
+ Audiences *[]SecretsStoreTokenRequest `json:"audiences,omitempty"`
+}
+
+// SecretRotationType determines the secret rotation behavior for the
+// Secrets Store CSI driver.
+// +kubebuilder:validation:Enum=None;Custom
+type SecretRotationType string
+
+const (
+ // SecretRotationNone disables automatic secret rotation. Secrets are only
+ // fetched at initial pod mount time.
+ SecretRotationNone SecretRotationType = "None"
+
+ // SecretRotationCustom enables automatic secret rotation with the
+ // configuration specified in the custom field.
+ SecretRotationCustom SecretRotationType = "Custom"
+)
+
+// SecretsStoreSecretRotation configures the automatic secret rotation behavior
+// for the Secrets Store CSI driver.
+// +kubebuilder:validation:XValidation:rule="has(self.type) && self.type == 'Custom' ? has(self.custom) : !has(self.custom)",message="custom must be set when type is 'Custom', and must not be set otherwise"
+// +union
+type SecretsStoreSecretRotation struct {
+ // type determines the secret rotation behavior.
+ // When "None", secret rotation is disabled and secrets are only fetched at
+ // initial pod mount time.
+ // When "Custom", secret rotation is enabled with the configuration specified
+ // in the custom field.
+ // +unionDiscriminator
+ // +required
+ Type SecretRotationType `json:"type,omitempty"`
+
+ // custom holds the custom rotation configuration.
+ // Only valid when type is "Custom".
+ // +optional
+ Custom CustomSecretRotation `json:"custom,omitzero"`
+}
+
+// CustomSecretRotation holds configuration for custom secret rotation behavior.
+// +kubebuilder:validation:MinProperties=1
+type CustomSecretRotation struct {
+ // minimumRefreshAge is the minimum time in seconds between secret
+ // rotation attempts. Each time kubelet calls NodePublishVolume, the driver
+ // checks whether this interval has elapsed since the last successful provider
+ // call. If it has, the driver contacts the secret provider to fetch the latest
+ // secret values and updates the mounted volume.
+ // Setting this value below the kubelet syncFrequency (default: 1 minute)
+ // has no additional effect on the actual rotation cadence.
+ // Must be at least 1 second and no more than 31560000 seconds (~1 year).
+ // When omitted, this means no opinion and the platform is left to choose a
+ // reasonable default, which is subject to change over time.
+ // +kubebuilder:validation:Minimum=1
+ // +kubebuilder:validation:Maximum=31560000
+ // +optional
+ MinimumRefreshAge int32 `json:"minimumRefreshAge,omitempty"`
+
+ // --- TOMBSTONE ---
+ // rotationPollIntervalSeconds was the previous name for minimumRefreshAge.
+ // The field has been renamed to better reflect its semantics.
+ // The JSON key is reserved to prevent reuse.
+ //
+ // +optional
+ // RotationPollIntervalSeconds int32 `json:"rotationPollIntervalSeconds,omitempty"`
+}
+
+// SecretsStoreTokenRequest specifies a service account token audience configuration
+// for workload identity federation (WIF) with the Secrets Store CSI driver.
+type SecretsStoreTokenRequest struct {
+ // audience is the intended audience of the service account token.
+ // An empty string means the issued token will use the kube-apiserver's default APIAudiences.
+ // +kubebuilder:validation:MinLength=0
+ // +kubebuilder:validation:MaxLength=253
+ // +required
+ Audience *string `json:"audience,omitempty"`
+
+ // expirationSeconds is the requested duration of validity of the service account token.
+ // The token issuer may return a token with a different validity duration.
+ // When omitted, the token expiration is determined by the kube-apiserver.
+ // Must be at least 600 seconds (10 minutes) and no more than 315360000 seconds (~10 years).
+ // +kubebuilder:validation:Minimum=600
+ // +kubebuilder:validation:Maximum=315360000
+ // +optional
+ ExpirationSeconds int32 `json:"expirationSeconds,omitempty"`
+}
+
// ClusterCSIDriverStatus is the observed status of CSI driver operator
type ClusterCSIDriverStatus struct {
OperatorStatus `json:",inline"`
diff --git a/vendor/github.com/openshift/api/operator/v1/types_etcd.go b/vendor/github.com/openshift/api/operator/v1/types_etcd.go
index 252f3b3990..f2f1131036 100644
--- a/vendor/github.com/openshift/api/operator/v1/types_etcd.go
+++ b/vendor/github.com/openshift/api/operator/v1/types_etcd.go
@@ -42,11 +42,11 @@ type EtcdSpec struct {
HardwareSpeed ControlPlaneHardwareSpeed `json:"controlPlaneHardwareSpeed"`
// backendQuotaGiB sets the etcd backend storage size limit in gibibytes.
- // The value should be an integer not less than 8 and not more than 32.
+ // The value should be an integer not less than 8 and not more than 16.
// When not specified, the default value is 8.
// +kubebuilder:default:=8
// +kubebuilder:validation:Minimum=8
- // +kubebuilder:validation:Maximum=32
+ // +kubebuilder:validation:Maximum=16
// +kubebuilder:validation:XValidation:rule="self>=oldSelf",message="etcd backendQuotaGiB may not be decreased"
// +openshift:enable:FeatureGate=EtcdBackendQuota
// +default=8
diff --git a/vendor/github.com/openshift/api/operator/v1/types_ingress.go b/vendor/github.com/openshift/api/operator/v1/types_ingress.go
deleted file mode 100644
index d54352f2ce..0000000000
--- a/vendor/github.com/openshift/api/operator/v1/types_ingress.go
+++ /dev/null
@@ -1,2244 +0,0 @@
-package v1
-
-import (
- metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
- "k8s.io/apimachinery/pkg/runtime"
-
- corev1 "k8s.io/api/core/v1"
-
- configv1 "github.com/openshift/api/config/v1"
-)
-
-// +genclient
-// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
-// +kubebuilder:object:root=true
-// +kubebuilder:subresource:status
-// +kubebuilder:subresource:scale:specpath=.spec.replicas,statuspath=.status.availableReplicas,selectorpath=.status.selector
-// +kubebuilder:resource:path=ingresscontrollers,scope=Namespaced
-// +openshift:api-approved.openshift.io=https://github.com/openshift/api/pull/616
-// +openshift:capability=Ingress
-// +openshift:file-pattern=cvoRunLevel=0000_50,operatorName=ingress,operatorOrdering=00
-
-// IngressController describes a managed ingress controller for the cluster. The
-// controller can service OpenShift Route and Kubernetes Ingress resources.
-//
-// When an IngressController is created, a new ingress controller deployment is
-// created to allow external traffic to reach the services that expose Ingress
-// or Route resources. Updating this resource may lead to disruption for public
-// facing network connections as a new ingress controller revision may be rolled
-// out.
-//
-// https://kubernetes.io/docs/concepts/services-networking/ingress-controllers
-//
-// Whenever possible, sensible defaults for the platform are used. See each
-// field for more details.
-//
-// Compatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer).
-// +openshift:compatibility-gen:level=1
-// +kubebuilder:validation:XValidation:rule="!has(self.spec.domain) || size('router-' + self.metadata.name + '.' + self.spec.domain) <= 253",message="The combined 'router-' + metadata.name + '.' + .spec.domain cannot exceed 253 characters"
-type IngressController struct {
- metav1.TypeMeta `json:",inline"`
-
- // metadata is the standard object's metadata.
- // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
- metav1.ObjectMeta `json:"metadata,omitempty"`
-
- // spec is the specification of the desired behavior of the IngressController.
- Spec IngressControllerSpec `json:"spec,omitempty"`
- // status is the most recently observed status of the IngressController.
- Status IngressControllerStatus `json:"status,omitempty"`
-}
-
-// IngressControllerSpec is the specification of the desired behavior of the
-// IngressController.
-type IngressControllerSpec struct {
- // domain is a DNS name serviced by the ingress controller and is used to
- // configure multiple features:
- //
- // * For the LoadBalancerService endpoint publishing strategy, domain is
- // used to configure DNS records. See endpointPublishingStrategy.
- //
- // * When using a generated default certificate, the certificate will be valid
- // for domain and its subdomains. See defaultCertificate.
- //
- // * The value is published to individual Route statuses so that end-users
- // know where to target external DNS records.
- //
- // domain must be unique among all IngressControllers, and cannot be
- // updated.
- //
- // If empty, defaults to ingress.config.openshift.io/cluster .spec.domain.
- //
- // The domain value must be a valid DNS name. It must consist of lowercase
- // alphanumeric characters, '-' or '.', and each label must start and end
- // with an alphanumeric character and not exceed 63 characters. Maximum
- // length of a valid DNS domain is 253 characters.
- //
- // The implementation may add a prefix such as "router-default." to the domain
- // when constructing the router canonical hostname. To ensure the resulting
- // hostname does not exceed the DNS maximum length of 253 characters,
- // the domain length is additionally validated at the IngressController object
- // level. For the maximum length of the domain value itself, the shortest
- // possible variant of the prefix and the ingress controller name was considered
- // for example "router-a."
- //
- // +kubebuilder:validation:MaxLength=244
- // +kubebuilder:validation:XValidation:rule="!format.dns1123Subdomain().validate(self).hasValue()",message="domain must consist of lower case alphanumeric characters, '-' or '.', and must start and end with an alphanumeric character"
- // +kubebuilder:validation:XValidation:rule="self.split('.').all(label, size(label) <= 63)",message="each DNS label must not exceed 63 characters"
- // +optional
- Domain string `json:"domain,omitempty"`
-
- // httpErrorCodePages specifies a configmap with custom error pages.
- // The administrator must create this configmap in the openshift-config namespace.
- // This configmap should have keys in the format "error-page-.http",
- // where is an HTTP error code.
- // For example, "error-page-503.http" defines an error page for HTTP 503 responses.
- // Currently only error pages for 503 and 404 responses can be customized.
- // Each value in the configmap should be the full response, including HTTP headers.
- // Eg- https://raw.githubusercontent.com/openshift/router/fadab45747a9b30cc3f0a4b41ad2871f95827a93/images/router/haproxy/conf/error-page-503.http
- // If this field is empty, the ingress controller uses the default error pages.
- HttpErrorCodePages configv1.ConfigMapNameReference `json:"httpErrorCodePages,omitempty"`
-
- // replicas is the desired number of ingress controller replicas. If unset,
- // the default depends on the value of the defaultPlacement field in the
- // cluster config.openshift.io/v1/ingresses status.
- //
- // The value of replicas is set based on the value of a chosen field in the
- // Infrastructure CR. If defaultPlacement is set to ControlPlane, the
- // chosen field will be controlPlaneTopology. If it is set to Workers the
- // chosen field will be infrastructureTopology. Replicas will then be set to 1
- // or 2 based whether the chosen field's value is SingleReplica or
- // HighlyAvailable, respectively.
- //
- // These defaults are subject to change.
- //
- // +optional
- Replicas *int32 `json:"replicas,omitempty"`
-
- // endpointPublishingStrategy is used to publish the ingress controller
- // endpoints to other networks, enable load balancer integrations, etc.
- //
- // If unset, the default is based on
- // infrastructure.config.openshift.io/cluster .status.platform:
- //
- // AWS: LoadBalancerService (with External scope)
- // Azure: LoadBalancerService (with External scope)
- // GCP: LoadBalancerService (with External scope)
- // IBMCloud: LoadBalancerService (with External scope)
- // AlibabaCloud: LoadBalancerService (with External scope)
- // Libvirt: HostNetwork
- //
- // Any other platform types (including None) default to HostNetwork.
- //
- // endpointPublishingStrategy cannot be updated.
- //
- // +optional
- EndpointPublishingStrategy *EndpointPublishingStrategy `json:"endpointPublishingStrategy,omitempty"`
-
- // defaultCertificate is a reference to a secret containing the default
- // certificate served by the ingress controller. When Routes don't specify
- // their own certificate, defaultCertificate is used.
- //
- // The secret must contain the following keys and data:
- //
- // tls.crt: certificate file contents
- // tls.key: key file contents
- //
- // If unset, a wildcard certificate is automatically generated and used. The
- // certificate is valid for the ingress controller domain (and subdomains) and
- // the generated certificate's CA will be automatically integrated with the
- // cluster's trust store.
- //
- // If a wildcard certificate is used and shared by multiple
- // HTTP/2 enabled routes (which implies ALPN) then clients
- // (i.e., notably browsers) are at liberty to reuse open
- // connections. This means a client can reuse a connection to
- // another route and that is likely to fail. This behaviour is
- // generally known as connection coalescing.
- //
- // The in-use certificate (whether generated or user-specified) will be
- // automatically integrated with OpenShift's built-in OAuth server.
- //
- // +optional
- DefaultCertificate *corev1.LocalObjectReference `json:"defaultCertificate,omitempty"`
-
- // namespaceSelector is used to filter the set of namespaces serviced by the
- // ingress controller. This is useful for implementing shards.
- //
- // If unset, the default is no filtering.
- //
- // +optional
- NamespaceSelector *metav1.LabelSelector `json:"namespaceSelector,omitempty"`
-
- // routeSelector is used to filter the set of Routes serviced by the ingress
- // controller. This is useful for implementing shards.
- //
- // If unset, the default is no filtering.
- //
- // +optional
- RouteSelector *metav1.LabelSelector `json:"routeSelector,omitempty"`
-
- // nodePlacement enables explicit control over the scheduling of the ingress
- // controller.
- //
- // If unset, defaults are used. See NodePlacement for more details.
- //
- // +optional
- NodePlacement *NodePlacement `json:"nodePlacement,omitempty"`
-
- // tlsSecurityProfile specifies settings for TLS connections for ingresscontrollers.
- //
- // If unset, the default is based on the apiservers.config.openshift.io/cluster resource.
- //
- // Note that when using the Old, Intermediate, and Modern profile types, the effective
- // profile configuration is subject to change between releases. For example, given
- // a specification to use the Intermediate profile deployed on release X.Y.Z, an upgrade
- // to release X.Y.Z+1 may cause a new profile configuration to be applied to the ingress
- // controller, resulting in a rollout.
- //
- // +optional
- TLSSecurityProfile *configv1.TLSSecurityProfile `json:"tlsSecurityProfile,omitempty"`
-
- // clientTLS specifies settings for requesting and verifying client
- // certificates, which can be used to enable mutual TLS for
- // edge-terminated and reencrypt routes.
- //
- // +optional
- ClientTLS ClientTLS `json:"clientTLS"`
-
- // routeAdmission defines a policy for handling new route claims (for example,
- // to allow or deny claims across namespaces).
- //
- // If empty, defaults will be applied. See specific routeAdmission fields
- // for details about their defaults.
- //
- // +optional
- RouteAdmission *RouteAdmissionPolicy `json:"routeAdmission,omitempty"`
-
- // logging defines parameters for what should be logged where. If this
- // field is empty, operational logs are enabled but access logs are
- // disabled.
- //
- // +optional
- Logging *IngressControllerLogging `json:"logging,omitempty"`
-
- // httpHeaders defines policy for HTTP headers.
- //
- // If this field is empty, the default values are used.
- //
- // +optional
- HTTPHeaders *IngressControllerHTTPHeaders `json:"httpHeaders,omitempty"`
-
- // httpEmptyRequestsPolicy describes how HTTP connections should be
- // handled if the connection times out before a request is received.
- // Allowed values for this field are "Respond" and "Ignore". If the
- // field is set to "Respond", the ingress controller sends an HTTP 400
- // or 408 response, logs the connection (if access logging is enabled),
- // and counts the connection in the appropriate metrics. If the field
- // is set to "Ignore", the ingress controller closes the connection
- // without sending a response, logging the connection, or incrementing
- // metrics. The default value is "Respond".
- //
- // Typically, these connections come from load balancers' health probes
- // or Web browsers' speculative connections ("preconnect") and can be
- // safely ignored. However, these requests may also be caused by
- // network errors, and so setting this field to "Ignore" may impede
- // detection and diagnosis of problems. In addition, these requests may
- // be caused by port scans, in which case logging empty requests may aid
- // in detecting intrusion attempts.
- //
- // +optional
- // +kubebuilder:default:="Respond"
- HTTPEmptyRequestsPolicy HTTPEmptyRequestsPolicy `json:"httpEmptyRequestsPolicy,omitempty"`
-
- // tuningOptions defines parameters for adjusting the performance of
- // ingress controller pods. All fields are optional and will use their
- // respective defaults if not set. See specific tuningOptions fields for
- // more details.
- //
- // Setting fields within tuningOptions is generally not recommended. The
- // default values are suitable for most configurations.
- //
- // +optional
- TuningOptions IngressControllerTuningOptions `json:"tuningOptions,omitempty"`
-
- // unsupportedConfigOverrides allows specifying unsupported
- // configuration options. Its use is unsupported.
- //
- // +optional
- // +nullable
- // +kubebuilder:pruning:PreserveUnknownFields
- UnsupportedConfigOverrides runtime.RawExtension `json:"unsupportedConfigOverrides"`
-
- // httpCompression defines a policy for HTTP traffic compression.
- // By default, there is no HTTP compression.
- //
- // +optional
- HTTPCompression HTTPCompressionPolicy `json:"httpCompression,omitempty"`
-
- // idleConnectionTerminationPolicy maps directly to HAProxy's
- // idle-close-on-response option and controls whether HAProxy
- // keeps idle frontend connections open during a soft stop
- // (router reload).
- //
- // Allowed values for this field are "Immediate" and
- // "Deferred". The default value is "Immediate".
- //
- // When set to "Immediate", idle connections are closed
- // immediately during router reloads. This ensures immediate
- // propagation of route changes but may impact clients
- // sensitive to connection resets.
- //
- // When set to "Deferred", HAProxy will maintain idle
- // connections during a soft reload instead of closing them
- // immediately. These connections remain open until any of the
- // following occurs:
- //
- // - A new request is received on the connection, in which
- // case HAProxy handles it in the old process and closes
- // the connection after sending the response.
- //
- // - HAProxy's `timeout http-keep-alive` duration expires.
- // By default this is 300 seconds, but it can be changed
- // using httpKeepAliveTimeout tuning option.
- //
- // - The client's keep-alive timeout expires, causing the
- // client to close the connection.
- //
- // Setting Deferred can help prevent errors in clients or load
- // balancers that do not properly handle connection resets.
- // Additionally, this option allows you to retain the pre-2.4
- // HAProxy behaviour: in HAProxy version 2.2 (OpenShift
- // versions < 4.14), maintaining idle connections during a
- // soft reload was the default behaviour, but starting with
- // HAProxy 2.4, the default changed to closing idle
- // connections immediately.
- //
- // Important Consideration:
- //
- // - Using Deferred will result in temporary inconsistencies
- // for the first request on each persistent connection
- // after a route update and router reload. This request
- // will be processed by the old HAProxy process using its
- // old configuration. Subsequent requests will use the
- // updated configuration.
- //
- // Operational Considerations:
- //
- // - Keeping idle connections open during reloads may lead
- // to an accumulation of old HAProxy processes if
- // connections remain idle for extended periods,
- // especially in environments where frequent reloads
- // occur.
- //
- // - Consider monitoring the number of HAProxy processes in
- // the router pods when Deferred is set.
- //
- // - You may need to enable or adjust the
- // `ingress.operator.openshift.io/hard-stop-after`
- // duration (configured via an annotation on the
- // IngressController resource) in environments with
- // frequent reloads to prevent resource exhaustion.
- //
- // +optional
- // +kubebuilder:default:="Immediate"
- // +default="Immediate"
- IdleConnectionTerminationPolicy IngressControllerConnectionTerminationPolicy `json:"idleConnectionTerminationPolicy,omitempty"`
-
- // closedClientConnectionPolicy controls how the IngressController
- // behaves when the client closes the TCP connection while the TLS
- // handshake or HTTP request is in progress. This option maps directly
- // to HAProxy’s "abortonclose" option.
- //
- // Valid values are: "Abort" and "Continue".
- // The default value is "Continue".
- //
- // When set to "Abort", the router will stop processing the TLS handshake
- // if it is in progress, and it will not send an HTTP request to the backend server
- // if the request has not yet been sent when the client closes the connection.
- //
- // When set to "Continue", the router will complete the TLS handshake
- // if it is in progress, or send an HTTP request to the backend server
- // and wait for the backend server's response, regardless of
- // whether the client has closed the connection.
- //
- // Setting "Abort" can help free CPU resources otherwise spent on TLS computation
- // for connections the client has already closed, and can reduce request queue
- // size, thereby reducing the load on saturated backend servers.
- //
- // Important Considerations:
- //
- // - The default policy ("Continue") is HTTP-compliant, and requests
- // for aborted client connections will still be served.
- // Use the "Continue" policy to allow a client to send a request
- // and then immediately close its side of the connection while
- // still receiving a response on the half-closed connection.
- //
- // - When clients use keep-alive connections, the most common case for premature
- // closure is when the user wants to cancel the transfer or when a timeout
- // occurs. In that case, the "Abort" policy may be used to reduce resource consumption.
- //
- // - Using RSA keys larger than 2048 bits can significantly slow down
- // TLS computations. Consider using the "Abort" policy to reduce CPU usage.
- //
- // +optional
- // +kubebuilder:default:="Continue"
- // +default="Continue"
- ClosedClientConnectionPolicy IngressControllerClosedClientConnectionPolicy `json:"closedClientConnectionPolicy,omitempty"`
-}
-
-// httpCompressionPolicy turns on compression for the specified MIME types.
-//
-// This field is optional, and its absence implies that compression should not be enabled
-// globally in HAProxy.
-//
-// If httpCompressionPolicy exists, compression should be enabled only for the specified
-// MIME types.
-type HTTPCompressionPolicy struct {
- // mimeTypes is a list of MIME types that should have compression applied.
- // This list can be empty, in which case the ingress controller does not apply compression.
- //
- // Note: Not all MIME types benefit from compression, but HAProxy will still use resources
- // to try to compress if instructed to. Generally speaking, text (html, css, js, etc.)
- // formats benefit from compression, but formats that are already compressed (image,
- // audio, video, etc.) benefit little in exchange for the time and cpu spent on compressing
- // again. See https://joehonton.medium.com/the-gzip-penalty-d31bd697f1a2
- //
- // +listType=set
- MimeTypes []CompressionMIMEType `json:"mimeTypes,omitempty"`
-}
-
-// CompressionMIMEType defines the format of a single MIME type.
-// E.g. "text/css; charset=utf-8", "text/html", "text/*", "image/svg+xml",
-// "application/octet-stream", "X-custom/customsub", etc.
-//
-// The format should follow the Content-Type definition in RFC 1341:
-// Content-Type := type "/" subtype *[";" parameter]
-// - The type in Content-Type can be one of:
-// application, audio, image, message, multipart, text, video, or a custom
-// type preceded by "X-" and followed by a token as defined below.
-// - The token is a string of at least one character, and not containing white
-// space, control characters, or any of the characters in the tspecials set.
-// - The tspecials set contains the characters ()<>@,;:\"/[]?.=
-// - The subtype in Content-Type is also a token.
-// - The optional parameter/s following the subtype are defined as:
-// token "=" (token / quoted-string)
-// - The quoted-string, as defined in RFC 822, is surrounded by double quotes
-// and can contain white space plus any character EXCEPT \, ", and CR.
-// It can also contain any single ASCII character as long as it is escaped by \.
-//
-// +kubebuilder:validation:Pattern=`^(?i)(x-[^][ ()\\<>@,;:"/?.=\x00-\x1F\x7F]+|application|audio|image|message|multipart|text|video)/[^][ ()\\<>@,;:"/?.=\x00-\x1F\x7F]+(; *[^][ ()\\<>@,;:"/?.=\x00-\x1F\x7F]+=([^][ ()\\<>@,;:"/?.=\x00-\x1F\x7F]+|"(\\[\x00-\x7F]|[^\x0D"\\])*"))*$`
-type CompressionMIMEType string
-
-// NodePlacement describes node scheduling configuration for an ingress
-// controller.
-type NodePlacement struct {
- // nodeSelector is the node selector applied to ingress controller
- // deployments.
- //
- // If set, the specified selector is used and replaces the default.
- //
- // If unset, the default depends on the value of the defaultPlacement
- // field in the cluster config.openshift.io/v1/ingresses status.
- //
- // When defaultPlacement is Workers, the default is:
- //
- // kubernetes.io/os: linux
- // node-role.kubernetes.io/worker: ''
- //
- // When defaultPlacement is ControlPlane, the default is:
- //
- // kubernetes.io/os: linux
- // node-role.kubernetes.io/master: ''
- //
- // These defaults are subject to change.
- //
- // Note that using nodeSelector.matchExpressions is not supported. Only
- // nodeSelector.matchLabels may be used. This is a limitation of the
- // Kubernetes API: the pod spec does not allow complex expressions for
- // node selectors.
- //
- // +optional
- NodeSelector *metav1.LabelSelector `json:"nodeSelector,omitempty"`
-
- // tolerations is a list of tolerations applied to ingress controller
- // deployments.
- //
- // The default is an empty list.
- //
- // See https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/
- //
- // +optional
- // +listType=atomic
- Tolerations []corev1.Toleration `json:"tolerations,omitempty"`
-}
-
-// EndpointPublishingStrategyType is a way to publish ingress controller endpoints.
-// +kubebuilder:validation:Enum=LoadBalancerService;HostNetwork;Private;NodePortService
-type EndpointPublishingStrategyType string
-
-const (
- // LoadBalancerService publishes the ingress controller using a Kubernetes
- // LoadBalancer Service.
- LoadBalancerServiceStrategyType EndpointPublishingStrategyType = "LoadBalancerService"
-
- // HostNetwork publishes the ingress controller on node ports where the
- // ingress controller is deployed.
- HostNetworkStrategyType EndpointPublishingStrategyType = "HostNetwork"
-
- // Private does not publish the ingress controller.
- PrivateStrategyType EndpointPublishingStrategyType = "Private"
-
- // NodePortService publishes the ingress controller using a Kubernetes NodePort Service.
- NodePortServiceStrategyType EndpointPublishingStrategyType = "NodePortService"
-)
-
-// LoadBalancerScope is the scope at which a load balancer is exposed.
-// +kubebuilder:validation:Enum=Internal;External
-type LoadBalancerScope string
-
-var (
- // InternalLoadBalancer is a load balancer that is exposed only on the
- // cluster's private network.
- InternalLoadBalancer LoadBalancerScope = "Internal"
-
- // ExternalLoadBalancer is a load balancer that is exposed on the
- // cluster's public network (which is typically on the Internet).
- ExternalLoadBalancer LoadBalancerScope = "External"
-)
-
-// CIDR is an IP address range in CIDR notation (for example, "10.0.0.0/8"
-// or "fd00::/8").
-// +kubebuilder:validation:Pattern=`(^(([0-9]|[0-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[0-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])/([0-9]|[12][0-9]|3[0-2])$)|(^s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]d|1dd|[1-9]?d)(.(25[0-5]|2[0-4]d|1dd|[1-9]?d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]d|1dd|[1-9]?d)(.(25[0-5]|2[0-4]d|1dd|[1-9]?d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]d|1dd|[1-9]?d)(.(25[0-5]|2[0-4]d|1dd|[1-9]?d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]d|1dd|[1-9]?d)(.(25[0-5]|2[0-4]d|1dd|[1-9]?d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]d|1dd|[1-9]?d)(.(25[0-5]|2[0-4]d|1dd|[1-9]?d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]d|1dd|[1-9]?d)(.(25[0-5]|2[0-4]d|1dd|[1-9]?d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]d|1dd|[1-9]?d)(.(25[0-5]|2[0-4]d|1dd|[1-9]?d)){3}))|:)))(%.+)?s*(\/(12[0-8]|1[0-1][0-9]|[1-9][0-9]|[0-9]))$)`
-// + ---
-// + The regex for the IPv4 CIDR range was taken from other CIDR fields in the OpenShift API
-// + and the one for the IPv6 CIDR range was taken from
-// + https://blog.markhatton.co.uk/2011/03/15/regular-expressions-for-ip-addresses-cidr-ranges-and-hostnames/
-// + The resulting regex is an OR of both regexes.
-type CIDR string
-
-// LoadBalancerStrategy holds parameters for a load balancer.
-// +kubebuilder:validation:XValidation:rule="!has(self.scope) || self.scope != 'Internal' || !has(self.providerParameters) || !has(self.providerParameters.aws) || !has(self.providerParameters.aws.networkLoadBalancer) || !has(self.providerParameters.aws.networkLoadBalancer.eipAllocations)",message="eipAllocations are forbidden when the scope is Internal."
-// +kubebuilder:validation:XValidation:rule=`!has(self.scope) || self.scope != 'Internal' || !has(self.providerParameters) || !has(self.providerParameters.openstack) || !has(self.providerParameters.openstack.floatingIP) || self.providerParameters.openstack.floatingIP == ""`,message="cannot specify a floating ip when scope is internal"
-type LoadBalancerStrategy struct {
- // scope indicates the scope at which the load balancer is exposed.
- // Possible values are "External" and "Internal".
- //
- // +required
- Scope LoadBalancerScope `json:"scope"`
-
- // allowedSourceRanges specifies an allowlist of IP address ranges to which
- // access to the load balancer should be restricted. Each range must be
- // specified using CIDR notation (e.g. "10.0.0.0/8" or "fd00::/8"). If no range is
- // specified, "0.0.0.0/0" for IPv4 and "::/0" for IPv6 are used by default,
- // which allows all source addresses.
- //
- // To facilitate migration from earlier versions of OpenShift that did
- // not have the allowedSourceRanges field, you may set the
- // service.beta.kubernetes.io/load-balancer-source-ranges annotation on
- // the "router-" service in the
- // "openshift-ingress" namespace, and this annotation will take
- // effect if allowedSourceRanges is empty on OpenShift 4.12.
- //
- // +nullable
- // +optional
- // +listType=atomic
- AllowedSourceRanges []CIDR `json:"allowedSourceRanges,omitempty"`
-
- // providerParameters holds desired load balancer information specific to
- // the underlying infrastructure provider.
- //
- // If empty, defaults will be applied. See specific providerParameters
- // fields for details about their defaults.
- //
- // +optional
- ProviderParameters *ProviderLoadBalancerParameters `json:"providerParameters,omitempty"`
-
- // dnsManagementPolicy indicates if the lifecycle of the wildcard DNS record
- // associated with the load balancer service will be managed by
- // the ingress operator. It defaults to Managed.
- // Valid values are: Managed and Unmanaged.
- //
- // +kubebuilder:default:="Managed"
- // +required
- // +default="Managed"
- DNSManagementPolicy LoadBalancerDNSManagementPolicy `json:"dnsManagementPolicy,omitempty"`
-}
-
-// LoadBalancerDNSManagementPolicy is a policy for configuring how
-// ingresscontrollers manage DNS.
-//
-// +kubebuilder:validation:Enum=Managed;Unmanaged
-type LoadBalancerDNSManagementPolicy string
-
-const (
- // ManagedLoadBalancerDNS specifies that the operator manages
- // a wildcard DNS record for the ingresscontroller.
- ManagedLoadBalancerDNS LoadBalancerDNSManagementPolicy = "Managed"
- // UnmanagedLoadBalancerDNS specifies that the operator does not manage
- // any wildcard DNS record for the ingresscontroller.
- UnmanagedLoadBalancerDNS LoadBalancerDNSManagementPolicy = "Unmanaged"
-)
-
-// ProviderLoadBalancerParameters holds desired load balancer information
-// specific to the underlying infrastructure provider.
-// +kubebuilder:validation:XValidation:rule="has(self.type) && self.type == 'OpenStack' ? true : !has(self.openstack)",message="openstack is not permitted when type is not OpenStack"
-// +union
-type ProviderLoadBalancerParameters struct {
- // type is the underlying infrastructure provider for the load balancer.
- // Allowed values are "AWS", "Azure", "BareMetal", "GCP", "IBM", "Nutanix",
- // "OpenStack", and "VSphere".
- //
- // +unionDiscriminator
- // +required
- Type LoadBalancerProviderType `json:"type"`
-
- // aws provides configuration settings that are specific to AWS
- // load balancers.
- //
- // If empty, defaults will be applied. See specific aws fields for
- // details about their defaults.
- //
- // +optional
- AWS *AWSLoadBalancerParameters `json:"aws,omitempty"`
-
- // gcp provides configuration settings that are specific to GCP
- // load balancers.
- //
- // If empty, defaults will be applied. See specific gcp fields for
- // details about their defaults.
- //
- // +optional
- GCP *GCPLoadBalancerParameters `json:"gcp,omitempty"`
-
- // ibm provides configuration settings that are specific to IBM Cloud
- // load balancers.
- //
- // If empty, defaults will be applied. See specific ibm fields for
- // details about their defaults.
- //
- // +optional
- IBM *IBMLoadBalancerParameters `json:"ibm,omitempty"`
-
- // openstack provides configuration settings that are specific to OpenStack
- // load balancers.
- //
- // If empty, defaults will be applied. See specific openstack fields for
- // details about their defaults.
- //
- // +optional
- OpenStack *OpenStackLoadBalancerParameters `json:"openstack,omitempty"`
-}
-
-// LoadBalancerProviderType is the underlying infrastructure provider for the
-// load balancer. Allowed values are "AWS", "Azure", "BareMetal", "GCP", "IBM", "Nutanix",
-// "OpenStack", and "VSphere".
-//
-// +kubebuilder:validation:Enum=AWS;Azure;BareMetal;GCP;Nutanix;OpenStack;VSphere;IBM
-type LoadBalancerProviderType string
-
-const (
- AWSLoadBalancerProvider LoadBalancerProviderType = "AWS"
- AzureLoadBalancerProvider LoadBalancerProviderType = "Azure"
- GCPLoadBalancerProvider LoadBalancerProviderType = "GCP"
- OpenStackLoadBalancerProvider LoadBalancerProviderType = "OpenStack"
- VSphereLoadBalancerProvider LoadBalancerProviderType = "VSphere"
- IBMLoadBalancerProvider LoadBalancerProviderType = "IBM"
- BareMetalLoadBalancerProvider LoadBalancerProviderType = "BareMetal"
- AlibabaCloudLoadBalancerProvider LoadBalancerProviderType = "AlibabaCloud"
- NutanixLoadBalancerProvider LoadBalancerProviderType = "Nutanix"
-)
-
-// AWSLoadBalancerParameters provides configuration settings that are
-// specific to AWS load balancers.
-// +union
-type AWSLoadBalancerParameters struct {
- // type is the type of AWS load balancer to instantiate for an ingresscontroller.
- //
- // Valid values are:
- //
- // * "Classic": A Classic Load Balancer that makes routing decisions at either
- // the transport layer (TCP/SSL) or the application layer (HTTP/HTTPS). See
- // the following for additional details:
- //
- // https://docs.aws.amazon.com/AmazonECS/latest/developerguide/load-balancer-types.html#clb
- //
- // * "NLB": A Network Load Balancer that makes routing decisions at the
- // transport layer (TCP/SSL). See the following for additional details:
- //
- // https://docs.aws.amazon.com/AmazonECS/latest/developerguide/load-balancer-types.html#nlb
- //
- // +unionDiscriminator
- // +required
- Type AWSLoadBalancerType `json:"type"`
-
- // classicLoadBalancerParameters holds configuration parameters for an AWS
- // classic load balancer. Present only if type is Classic.
- //
- // +optional
- ClassicLoadBalancerParameters *AWSClassicLoadBalancerParameters `json:"classicLoadBalancer,omitempty"`
-
- // networkLoadBalancerParameters holds configuration parameters for an AWS
- // network load balancer. Present only if type is NLB.
- //
- // +optional
- NetworkLoadBalancerParameters *AWSNetworkLoadBalancerParameters `json:"networkLoadBalancer,omitempty"`
-}
-
-// AWSLoadBalancerType is the type of AWS load balancer to instantiate.
-// +kubebuilder:validation:Enum=Classic;NLB
-type AWSLoadBalancerType string
-
-const (
- AWSClassicLoadBalancer AWSLoadBalancerType = "Classic"
- AWSNetworkLoadBalancer AWSLoadBalancerType = "NLB"
-)
-
-// AWSSubnets contains a list of references to AWS subnets by
-// ID or name.
-// +kubebuilder:validation:XValidation:rule=`has(self.ids) && has(self.names) ? size(self.ids + self.names) <= 10 : true`,message="the total number of subnets cannot exceed 10"
-// +kubebuilder:validation:XValidation:rule=`has(self.ids) && self.ids.size() > 0 || has(self.names) && self.names.size() > 0`,message="must specify at least 1 subnet name or id"
-type AWSSubnets struct {
- // ids specifies a list of AWS subnets by subnet ID.
- // Subnet IDs must start with "subnet-", consist only
- // of alphanumeric characters, must be exactly 24
- // characters long, must be unique, and the total
- // number of subnets specified by ids and names
- // must not exceed 10.
- //
- // +optional
- // +listType=atomic
- // +kubebuilder:validation:XValidation:rule=`self.all(x, self.exists_one(y, x == y))`,message="subnet ids cannot contain duplicates"
- // + Note: Though it may seem redundant, MaxItems is necessary to prevent exceeding of the cost budget for the validation rules.
- // +kubebuilder:validation:MaxItems=10
- IDs []AWSSubnetID `json:"ids,omitempty"`
-
- // names specifies a list of AWS subnets by subnet name.
- // Subnet names must not start with "subnet-", must not
- // include commas, must be under 256 characters in length,
- // must be unique, and the total number of subnets
- // specified by ids and names must not exceed 10.
- //
- // +optional
- // +listType=atomic
- // +kubebuilder:validation:XValidation:rule=`self.all(x, self.exists_one(y, x == y))`,message="subnet names cannot contain duplicates"
- // + Note: Though it may seem redundant, MaxItems is necessary to prevent exceeding of the cost budget for the validation rules.
- // +kubebuilder:validation:MaxItems=10
- Names []AWSSubnetName `json:"names,omitempty"`
-}
-
-// AWSSubnetID is a reference to an AWS subnet ID.
-// +kubebuilder:validation:MinLength=24
-// +kubebuilder:validation:MaxLength=24
-// +kubebuilder:validation:Pattern=`^subnet-[0-9A-Za-z]+$`
-type AWSSubnetID string
-
-// AWSSubnetName is a reference to an AWS subnet name.
-// +kubebuilder:validation:MinLength=1
-// +kubebuilder:validation:MaxLength=256
-// +kubebuilder:validation:XValidation:rule=`!self.contains(',')`,message="subnet name cannot contain a comma"
-// +kubebuilder:validation:XValidation:rule=`!self.startsWith('subnet-')`,message="subnet name cannot start with 'subnet-'"
-type AWSSubnetName string
-
-// GCPLoadBalancerParameters provides configuration settings that are
-// specific to GCP load balancers.
-type GCPLoadBalancerParameters struct {
- // clientAccess describes how client access is restricted for internal
- // load balancers.
- //
- // Valid values are:
- // * "Global": Specifying an internal load balancer with Global client access
- // allows clients from any region within the VPC to communicate with the load
- // balancer.
- //
- // https://cloud.google.com/kubernetes-engine/docs/how-to/internal-load-balancing#global_access
- //
- // * "Local": Specifying an internal load balancer with Local client access
- // means only clients within the same region (and VPC) as the GCP load balancer
- // can communicate with the load balancer. Note that this is the default behavior.
- //
- // https://cloud.google.com/load-balancing/docs/internal#client_access
- //
- // +optional
- ClientAccess GCPClientAccess `json:"clientAccess,omitempty"`
-}
-
-// GCPClientAccess describes how client access is restricted for internal
-// load balancers.
-// +kubebuilder:validation:Enum=Global;Local
-type GCPClientAccess string
-
-const (
- GCPGlobalAccess GCPClientAccess = "Global"
- GCPLocalAccess GCPClientAccess = "Local"
-)
-
-// IBMLoadBalancerParameters provides configuration settings that are
-// specific to IBM Cloud load balancers.
-type IBMLoadBalancerParameters struct {
- // protocol specifies whether the load balancer uses PROXY protocol to forward connections to
- // the IngressController. See "service.kubernetes.io/ibm-load-balancer-cloud-provider-enable-features:
- // "proxy-protocol"" at https://cloud.ibm.com/docs/containers?topic=containers-vpc-lbaas"
- //
- // PROXY protocol can be used with load balancers that support it to
- // communicate the source addresses of client connections when
- // forwarding those connections to the IngressController. Using PROXY
- // protocol enables the IngressController to report those source
- // addresses instead of reporting the load balancer's address in HTTP
- // headers and logs. Note that enabling PROXY protocol on the
- // IngressController will cause connections to fail if you are not using
- // a load balancer that uses PROXY protocol to forward connections to
- // the IngressController. See
- // http://www.haproxy.org/download/2.2/doc/proxy-protocol.txt for
- // information about PROXY protocol.
- //
- // Valid values for protocol are TCP, PROXY and omitted.
- // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
- // The current default is TCP, without the proxy protocol enabled.
- //
- // +optional
- Protocol IngressControllerProtocol `json:"protocol,omitempty"`
-}
-
-// OpenStackLoadBalancerParameters provides configuration settings that are
-// specific to OpenStack load balancers.
-type OpenStackLoadBalancerParameters struct {
- // loadBalancerIP is tombstoned since the field was replaced by floatingIP.
- // LoadBalancerIP string `json:"loadBalancerIP,omitempty"`
-
- // floatingIP specifies the IP address that the load balancer will use.
- // When not specified, an IP address will be assigned randomly by the OpenStack cloud provider.
- // When specified, the floating IP has to be pre-created. If the
- // specified value is not a floating IP or is already claimed, the
- // OpenStack cloud provider won't be able to provision the load
- // balancer.
- // This field may only be used if the IngressController has External scope.
- // This value must be a valid IPv4 or IPv6 address.
- // + ---
- // + Note: this field is meant to be set by the ingress controller
- // + to populate the `Service.Spec.LoadBalancerIP` field which has been
- // + deprecated in Kubernetes:
- // + https://github.com/kubernetes/kubernetes/pull/107235
- // + However, the field is still used by cloud-provider-openstack to reconcile
- // + the floating IP that we attach to the external load balancer.
- //
- // +kubebuilder:validation:XValidation:rule="isIP(self)",message="floatingIP must be a valid IPv4 or IPv6 address"
- // +optional
- FloatingIP string `json:"floatingIP,omitempty"`
-}
-
-// AWSClassicLoadBalancerParameters holds configuration parameters for an
-// AWS Classic load balancer.
-type AWSClassicLoadBalancerParameters struct {
- // connectionIdleTimeout specifies the maximum time period that a
- // connection may be idle before the load balancer closes the
- // connection. The value must be parseable as a time duration value;
- // see . A nil or zero value
- // means no opinion, in which case a default value is used. The default
- // value for this field is 60s. This default is subject to change.
- //
- // +kubebuilder:validation:Format=duration
- // +optional
- ConnectionIdleTimeout metav1.Duration `json:"connectionIdleTimeout,omitempty"`
-
- // subnets specifies the subnets to which the load balancer will
- // attach. The subnets may be specified by either their
- // ID or name. The total number of subnets is limited to 10.
- //
- // In order for the load balancer to be provisioned with subnets,
- // each subnet must exist, each subnet must be from a different
- // availability zone, and the load balancer service must be
- // recreated to pick up new values.
- //
- // When omitted from the spec, the subnets will be auto-discovered
- // for each availability zone. Auto-discovered subnets are not reported
- // in the status of the IngressController object.
- //
- // +optional
- Subnets *AWSSubnets `json:"subnets,omitempty"`
-}
-
-// AWSNetworkLoadBalancerParameters holds configuration parameters for an
-// AWS Network load balancer. For Example: Setting AWS EIPs https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/elastic-ip-addresses-eip.html
-// +kubebuilder:validation:XValidation:rule=`has(self.subnets) && has(self.subnets.ids) && has(self.subnets.names) && has(self.eipAllocations) ? size(self.subnets.ids + self.subnets.names) == size(self.eipAllocations) : true`,message="number of subnets must be equal to number of eipAllocations"
-// +kubebuilder:validation:XValidation:rule=`has(self.subnets) && has(self.subnets.ids) && !has(self.subnets.names) && has(self.eipAllocations) ? size(self.subnets.ids) == size(self.eipAllocations) : true`,message="number of subnets must be equal to number of eipAllocations"
-// +kubebuilder:validation:XValidation:rule=`has(self.subnets) && has(self.subnets.names) && !has(self.subnets.ids) && has(self.eipAllocations) ? size(self.subnets.names) == size(self.eipAllocations) : true`,message="number of subnets must be equal to number of eipAllocations"
-type AWSNetworkLoadBalancerParameters struct {
- // subnets specifies the subnets to which the load balancer will
- // attach. The subnets may be specified by either their
- // ID or name. The total number of subnets is limited to 10.
- //
- // In order for the load balancer to be provisioned with subnets,
- // each subnet must exist, each subnet must be from a different
- // availability zone, and the load balancer service must be
- // recreated to pick up new values.
- //
- // When omitted from the spec, the subnets will be auto-discovered
- // for each availability zone. Auto-discovered subnets are not reported
- // in the status of the IngressController object.
- //
- // +optional
- Subnets *AWSSubnets `json:"subnets,omitempty"`
-
- // eipAllocations is a list of IDs for Elastic IP (EIP) addresses that
- // are assigned to the Network Load Balancer.
- // The following restrictions apply:
- //
- // eipAllocations can only be used with external scope, not internal.
- // An EIP can be allocated to only a single IngressController.
- // The number of EIP allocations must match the number of subnets that are used for the load balancer.
- // Each EIP allocation must be unique.
- // A maximum of 10 EIP allocations are permitted.
- //
- // See https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/elastic-ip-addresses-eip.html for general
- // information about configuration, characteristics, and limitations of Elastic IP addresses.
- //
- // +optional
- // +listType=atomic
- // +kubebuilder:validation:XValidation:rule=`self.all(x, self.exists_one(y, x == y))`,message="eipAllocations cannot contain duplicates"
- // +kubebuilder:validation:MaxItems=10
- EIPAllocations []EIPAllocation `json:"eipAllocations"`
-}
-
-// EIPAllocation is an ID for an Elastic IP (EIP) address that can be allocated to an ELB in the AWS environment.
-// Values must begin with `eipalloc-` followed by exactly 17 hexadecimal (`[0-9a-fA-F]`) characters.
-// + Explanation of the regex `^eipalloc-[0-9a-fA-F]{17}$` for validating value of the EIPAllocation:
-// + ^eipalloc- ensures the string starts with "eipalloc-".
-// + [0-9a-fA-F]{17} matches exactly 17 hexadecimal characters (0-9, a-f, A-F).
-// + $ ensures the string ends after the 17 hexadecimal characters.
-// + Example of Valid and Invalid values:
-// + eipalloc-1234567890abcdef1 is valid.
-// + eipalloc-1234567890abcde is not valid (too short).
-// + eipalloc-1234567890abcdefg is not valid (contains a non-hex character 'g').
-// + Max length is calculated as follows:
-// + eipalloc- = 9 chars and 17 hexadecimal chars after `-`
-// + So, total is 17 + 9 = 26 chars required for value of an EIPAllocation.
-//
-// +kubebuilder:validation:MinLength=26
-// +kubebuilder:validation:MaxLength=26
-// +kubebuilder:validation:XValidation:rule=`self.startsWith('eipalloc-')`,message="eipAllocations should start with 'eipalloc-'"
-// +kubebuilder:validation:XValidation:rule=`self.split("-", 2)[1].matches('[0-9a-fA-F]{17}$')`,message="eipAllocations must be 'eipalloc-' followed by exactly 17 hexadecimal characters (0-9, a-f, A-F)"
-type EIPAllocation string
-
-// HostNetworkStrategy holds parameters for the HostNetwork endpoint publishing
-// strategy.
-type HostNetworkStrategy struct {
- // protocol specifies whether the IngressController expects incoming
- // connections to use plain TCP or whether the IngressController expects
- // PROXY protocol.
- //
- // PROXY protocol can be used with load balancers that support it to
- // communicate the source addresses of client connections when
- // forwarding those connections to the IngressController. Using PROXY
- // protocol enables the IngressController to report those source
- // addresses instead of reporting the load balancer's address in HTTP
- // headers and logs. Note that enabling PROXY protocol on the
- // IngressController will cause connections to fail if you are not using
- // a load balancer that uses PROXY protocol to forward connections to
- // the IngressController. See
- // http://www.haproxy.org/download/2.2/doc/proxy-protocol.txt for
- // information about PROXY protocol.
- //
- // The following values are valid for this field:
- //
- // * The empty string.
- // * "TCP".
- // * "PROXY".
- //
- // The empty string specifies the default, which is TCP without PROXY
- // protocol. Note that the default is subject to change.
- //
- // +optional
- Protocol IngressControllerProtocol `json:"protocol,omitempty"`
-
- // httpPort is the port on the host which should be used to listen for
- // HTTP requests. This field should be set when port 80 is already in use.
- // The value should not coincide with the NodePort range of the cluster.
- // When the value is 0 or is not specified it defaults to 80.
- // +kubebuilder:validation:Maximum=65535
- // +kubebuilder:validation:Minimum=0
- // +kubebuilder:default=80
- // +optional
- HTTPPort int32 `json:"httpPort,omitempty"`
-
- // httpsPort is the port on the host which should be used to listen for
- // HTTPS requests. This field should be set when port 443 is already in use.
- // The value should not coincide with the NodePort range of the cluster.
- // When the value is 0 or is not specified it defaults to 443.
- // +kubebuilder:validation:Maximum=65535
- // +kubebuilder:validation:Minimum=0
- // +kubebuilder:default=443
- // +optional
- HTTPSPort int32 `json:"httpsPort,omitempty"`
-
- // statsPort is the port on the host where the stats from the router are
- // published. The value should not coincide with the NodePort range of the
- // cluster. If an external load balancer is configured to forward connections
- // to this IngressController, the load balancer should use this port for
- // health checks. The load balancer can send HTTP probes on this port on a
- // given node, with the path /healthz/ready to determine if the ingress
- // controller is ready to receive traffic on the node. For proper operation
- // the load balancer must not forward traffic to a node until the health
- // check reports ready. The load balancer should also stop forwarding requests
- // within a maximum of 45 seconds after /healthz/ready starts reporting
- // not-ready. Probing every 5 to 10 seconds, with a 5-second timeout and with
- // a threshold of two successful or failed requests to become healthy or
- // unhealthy respectively, are well-tested values. When the value is 0 or
- // is not specified it defaults to 1936.
- // +kubebuilder:validation:Maximum=65535
- // +kubebuilder:validation:Minimum=0
- // +kubebuilder:default=1936
- // +optional
- StatsPort int32 `json:"statsPort,omitempty"`
-}
-
-// PrivateStrategy holds parameters for the Private endpoint publishing
-// strategy.
-type PrivateStrategy struct {
- // protocol specifies whether the IngressController expects incoming
- // connections to use plain TCP or whether the IngressController expects
- // PROXY protocol.
- //
- // PROXY protocol can be used with load balancers that support it to
- // communicate the source addresses of client connections when
- // forwarding those connections to the IngressController. Using PROXY
- // protocol enables the IngressController to report those source
- // addresses instead of reporting the load balancer's address in HTTP
- // headers and logs. Note that enabling PROXY protocol on the
- // IngressController will cause connections to fail if you are not using
- // a load balancer that uses PROXY protocol to forward connections to
- // the IngressController. See
- // http://www.haproxy.org/download/2.2/doc/proxy-protocol.txt for
- // information about PROXY protocol.
- //
- // The following values are valid for this field:
- //
- // * The empty string.
- // * "TCP".
- // * "PROXY".
- //
- // The empty string specifies the default, which is TCP without PROXY
- // protocol. Note that the default is subject to change.
- //
- // +optional
- Protocol IngressControllerProtocol `json:"protocol,omitempty"`
-}
-
-// NodePortStrategy holds parameters for the NodePortService endpoint publishing strategy.
-type NodePortStrategy struct {
- // protocol specifies whether the IngressController expects incoming
- // connections to use plain TCP or whether the IngressController expects
- // PROXY protocol.
- //
- // PROXY protocol can be used with load balancers that support it to
- // communicate the source addresses of client connections when
- // forwarding those connections to the IngressController. Using PROXY
- // protocol enables the IngressController to report those source
- // addresses instead of reporting the load balancer's address in HTTP
- // headers and logs. Note that enabling PROXY protocol on the
- // IngressController will cause connections to fail if you are not using
- // a load balancer that uses PROXY protocol to forward connections to
- // the IngressController. See
- // http://www.haproxy.org/download/2.2/doc/proxy-protocol.txt for
- // information about PROXY protocol.
- //
- // The following values are valid for this field:
- //
- // * The empty string.
- // * "TCP".
- // * "PROXY".
- //
- // The empty string specifies the default, which is TCP without PROXY
- // protocol. Note that the default is subject to change.
- //
- // +optional
- Protocol IngressControllerProtocol `json:"protocol,omitempty"`
-}
-
-// IngressControllerProtocol specifies whether PROXY protocol is enabled or not.
-// +kubebuilder:validation:Enum="";TCP;PROXY
-type IngressControllerProtocol string
-
-const (
- DefaultProtocol IngressControllerProtocol = ""
- TCPProtocol IngressControllerProtocol = "TCP"
- ProxyProtocol IngressControllerProtocol = "PROXY"
-)
-
-// EndpointPublishingStrategy is a way to publish the endpoints of an
-// IngressController, and represents the type and any additional configuration
-// for a specific type.
-// +union
-type EndpointPublishingStrategy struct {
- // type is the publishing strategy to use. Valid values are:
- //
- // * LoadBalancerService
- //
- // Publishes the ingress controller using a Kubernetes LoadBalancer Service.
- //
- // In this configuration, the ingress controller deployment uses container
- // networking. A LoadBalancer Service is created to publish the deployment.
- //
- // See: https://kubernetes.io/docs/concepts/services-networking/service/#loadbalancer
- //
- // If domain is set, a wildcard DNS record will be managed to point at the
- // LoadBalancer Service's external name. DNS records are managed only in DNS
- // zones defined by dns.config.openshift.io/cluster .spec.publicZone and
- // .spec.privateZone.
- //
- // Wildcard DNS management is currently supported only on the AWS, Azure,
- // and GCP platforms.
- //
- // * HostNetwork
- //
- // Publishes the ingress controller on node ports where the ingress controller
- // is deployed.
- //
- // In this configuration, the ingress controller deployment uses host
- // networking, bound to node ports 80 and 443. The user is responsible for
- // configuring an external load balancer to publish the ingress controller via
- // the node ports.
- //
- // * Private
- //
- // Does not publish the ingress controller.
- //
- // In this configuration, the ingress controller deployment uses container
- // networking, and is not explicitly published. The user must manually publish
- // the ingress controller.
- //
- // * NodePortService
- //
- // Publishes the ingress controller using a Kubernetes NodePort Service.
- //
- // In this configuration, the ingress controller deployment uses container
- // networking. A NodePort Service is created to publish the deployment. The
- // specific node ports are dynamically allocated by OpenShift; however, to
- // support static port allocations, user changes to the node port
- // field of the managed NodePort Service will preserved.
- //
- // +unionDiscriminator
- // +required
- Type EndpointPublishingStrategyType `json:"type"`
-
- // loadBalancer holds parameters for the load balancer. Present only if
- // type is LoadBalancerService.
- // +optional
- LoadBalancer *LoadBalancerStrategy `json:"loadBalancer,omitempty"`
-
- // hostNetwork holds parameters for the HostNetwork endpoint publishing
- // strategy. Present only if type is HostNetwork.
- // +optional
- HostNetwork *HostNetworkStrategy `json:"hostNetwork,omitempty"`
-
- // private holds parameters for the Private endpoint publishing
- // strategy. Present only if type is Private.
- // +optional
- Private *PrivateStrategy `json:"private,omitempty"`
-
- // nodePort holds parameters for the NodePortService endpoint publishing strategy.
- // Present only if type is NodePortService.
- // +optional
- NodePort *NodePortStrategy `json:"nodePort,omitempty"`
-}
-
-// ClientCertificatePolicy describes the policy for client certificates.
-// +kubebuilder:validation:Enum="";Required;Optional
-type ClientCertificatePolicy string
-
-const (
- // ClientCertificatePolicyRequired indicates that a client certificate
- // should be required.
- ClientCertificatePolicyRequired ClientCertificatePolicy = "Required"
-
- // ClientCertificatePolicyOptional indicates that a client certificate
- // should be requested but not required.
- ClientCertificatePolicyOptional ClientCertificatePolicy = "Optional"
-)
-
-// ClientTLS specifies TLS configuration to enable client-to-server
-// authentication, which can be used for mutual TLS.
-type ClientTLS struct {
- // clientCertificatePolicy specifies whether the ingress controller
- // requires clients to provide certificates. This field accepts the
- // values "Required" or "Optional".
- //
- // Note that the ingress controller only checks client certificates for
- // edge-terminated and reencrypt TLS routes; it cannot check
- // certificates for cleartext HTTP or passthrough TLS routes.
- //
- // +required
- ClientCertificatePolicy ClientCertificatePolicy `json:"clientCertificatePolicy"`
-
- // clientCA specifies a configmap containing the PEM-encoded CA
- // certificate bundle that should be used to verify a client's
- // certificate. The administrator must create this configmap in the
- // openshift-config namespace.
- //
- // +required
- ClientCA configv1.ConfigMapNameReference `json:"clientCA"`
-
- // allowedSubjectPatterns specifies a list of regular expressions that
- // should be matched against the distinguished name on a valid client
- // certificate to filter requests. The regular expressions must use
- // PCRE syntax. If this list is empty, no filtering is performed. If
- // the list is nonempty, then at least one pattern must match a client
- // certificate's distinguished name or else the ingress controller
- // rejects the certificate and denies the connection.
- //
- // +listType=atomic
- // +optional
- AllowedSubjectPatterns []string `json:"allowedSubjectPatterns,omitempty"`
-}
-
-// RouteAdmissionPolicy is an admission policy for allowing new route claims.
-type RouteAdmissionPolicy struct {
- // namespaceOwnership describes how host name claims across namespaces should
- // be handled.
- //
- // Value must be one of:
- //
- // - Strict: Do not allow routes in different namespaces to claim the same host.
- //
- // - InterNamespaceAllowed: Allow routes to claim different paths of the same
- // host name across namespaces.
- //
- // If empty, the default is Strict.
- // +optional
- NamespaceOwnership NamespaceOwnershipCheck `json:"namespaceOwnership,omitempty"`
- // wildcardPolicy describes how routes with wildcard policies should
- // be handled for the ingress controller. WildcardPolicy controls use
- // of routes [1] exposed by the ingress controller based on the route's
- // wildcard policy.
- //
- // [1] https://github.com/openshift/api/blob/master/route/v1/types.go
- //
- // Note: Updating WildcardPolicy from WildcardsAllowed to WildcardsDisallowed
- // will cause admitted routes with a wildcard policy of Subdomain to stop
- // working. These routes must be updated to a wildcard policy of None to be
- // readmitted by the ingress controller.
- //
- // WildcardPolicy supports WildcardsAllowed and WildcardsDisallowed values.
- //
- // If empty, defaults to "WildcardsDisallowed".
- //
- WildcardPolicy WildcardPolicy `json:"wildcardPolicy,omitempty"`
-}
-
-// WildcardPolicy is a route admission policy component that describes how
-// routes with a wildcard policy should be handled.
-// +kubebuilder:validation:Enum=WildcardsAllowed;WildcardsDisallowed
-type WildcardPolicy string
-
-const (
- // WildcardPolicyAllowed indicates routes with any wildcard policy are
- // admitted by the ingress controller.
- WildcardPolicyAllowed WildcardPolicy = "WildcardsAllowed"
-
- // WildcardPolicyDisallowed indicates only routes with a wildcard policy
- // of None are admitted by the ingress controller.
- WildcardPolicyDisallowed WildcardPolicy = "WildcardsDisallowed"
-)
-
-// NamespaceOwnershipCheck is a route admission policy component that describes
-// how host name claims across namespaces should be handled.
-// +kubebuilder:validation:Enum=InterNamespaceAllowed;Strict
-type NamespaceOwnershipCheck string
-
-const (
- // InterNamespaceAllowedOwnershipCheck allows routes to claim different paths of the same host name across namespaces.
- InterNamespaceAllowedOwnershipCheck NamespaceOwnershipCheck = "InterNamespaceAllowed"
-
- // StrictNamespaceOwnershipCheck does not allow routes to claim the same host name across namespaces.
- StrictNamespaceOwnershipCheck NamespaceOwnershipCheck = "Strict"
-)
-
-// LoggingDestinationType is a type of destination to which to send log
-// messages.
-//
-// +kubebuilder:validation:Enum=Container;Syslog
-type LoggingDestinationType string
-
-const (
- // Container sends log messages to a sidecar container.
- ContainerLoggingDestinationType LoggingDestinationType = "Container"
-
- // Syslog sends log messages to a syslog endpoint.
- SyslogLoggingDestinationType LoggingDestinationType = "Syslog"
-
- // ContainerLoggingSidecarContainerName is the name of the container
- // with the log output in an ingress controller pod when container
- // logging is used.
- ContainerLoggingSidecarContainerName = "logs"
-)
-
-// SyslogLoggingDestinationParameters describes parameters for the Syslog
-// logging destination type.
-type SyslogLoggingDestinationParameters struct {
- // address is the IP address of the syslog endpoint that receives log
- // messages.
- //
- // +required
- Address string `json:"address"`
-
- // port is the UDP port number of the syslog endpoint that receives log
- // messages.
- //
- // +kubebuilder:validation:Minimum=1
- // +kubebuilder:validation:Maximum=65535
- // +required
- Port uint32 `json:"port"`
-
- // facility specifies the syslog facility of log messages.
- //
- // If this field is empty, the facility is "local1".
- //
- // +kubebuilder:validation:Enum=kern;user;mail;daemon;auth;syslog;lpr;news;uucp;cron;auth2;ftp;ntp;audit;alert;cron2;local0;local1;local2;local3;local4;local5;local6;local7
- // +optional
- Facility string `json:"facility,omitempty"`
-
- // maxLength is the maximum length of the log message.
- //
- // Valid values are integers in the range 480 to 4096, inclusive.
- //
- // When omitted, the default value is 1024.
- //
- // +kubebuilder:validation:Maximum=4096
- // +kubebuilder:validation:Minimum=480
- // +kubebuilder:default=1024
- // +default:=1024
- // +optional
- MaxLength uint32 `json:"maxLength,omitempty"`
-}
-
-// ContainerLoggingDestinationParameters describes parameters for the Container
-// logging destination type.
-type ContainerLoggingDestinationParameters struct {
- // maxLength is the maximum length of the log message.
- //
- // Valid values are integers in the range 480 to 8192, inclusive.
- //
- // When omitted, the default value is 1024.
- //
- // +kubebuilder:validation:Maximum=8192
- // +kubebuilder:validation:Minimum=480
- // +kubebuilder:default=1024
- // +default:=1024
- // +optional
- MaxLength int32 `json:"maxLength,omitempty"`
-}
-
-// LoggingDestination describes a destination for log messages.
-// +union
-type LoggingDestination struct {
- // type is the type of destination for logs. It must be one of the
- // following:
- //
- // * Container
- //
- // The ingress operator configures the sidecar container named "logs" on
- // the ingress controller pod and configures the ingress controller to
- // write logs to the sidecar. The logs are then available as container
- // logs. The expectation is that the administrator configures a custom
- // logging solution that reads logs from this sidecar. Note that using
- // container logs means that logs may be dropped if the rate of logs
- // exceeds the container runtime's or the custom logging solution's
- // capacity.
- //
- // * Syslog
- //
- // Logs are sent to a syslog endpoint. The administrator must specify
- // an endpoint that can receive syslog messages. The expectation is
- // that the administrator has configured a custom syslog instance.
- //
- // +unionDiscriminator
- // +required
- Type LoggingDestinationType `json:"type"`
-
- // syslog holds parameters for a syslog endpoint. Present only if
- // type is Syslog.
- //
- // +optional
- Syslog *SyslogLoggingDestinationParameters `json:"syslog,omitempty"`
-
- // container holds parameters for the Container logging destination.
- // Present only if type is Container.
- //
- // +optional
- Container *ContainerLoggingDestinationParameters `json:"container,omitempty"`
-}
-
-// IngressControllerCaptureHTTPHeader describes an HTTP header that should be
-// captured.
-type IngressControllerCaptureHTTPHeader struct {
- // name specifies a header name. Its value must be a valid HTTP header
- // name as defined in RFC 2616 section 4.2.
- //
- // +kubebuilder:validation:Pattern="^[-!#$%&'*+.0-9A-Z^_`a-z|~]+$"
- // +required
- Name string `json:"name"`
-
- // maxLength specifies a maximum length for the header value. If a
- // header value exceeds this length, the value will be truncated in the
- // log message. Note that the ingress controller may impose a separate
- // bound on the total length of HTTP headers in a request.
- //
- // +kubebuilder:validation:Minimum=1
- // +required
- MaxLength int `json:"maxLength"`
-}
-
-// IngressControllerCaptureHTTPHeaders specifies which HTTP headers the
-// IngressController captures.
-type IngressControllerCaptureHTTPHeaders struct {
- // request specifies which HTTP request headers to capture.
- //
- // If this field is empty, no request headers are captured.
- //
- // +nullable
- // +optional
- // +listType=atomic
- Request []IngressControllerCaptureHTTPHeader `json:"request,omitempty"`
-
- // response specifies which HTTP response headers to capture.
- //
- // If this field is empty, no response headers are captured.
- //
- // +nullable
- // +optional
- // +listType=atomic
- Response []IngressControllerCaptureHTTPHeader `json:"response,omitempty"`
-}
-
-// CookieMatchType indicates the type of matching used against cookie names to
-// select a cookie for capture.
-// +kubebuilder:validation:Enum=Exact;Prefix
-type CookieMatchType string
-
-const (
- // CookieMatchTypeExact indicates that an exact string match should be
- // performed.
- CookieMatchTypeExact CookieMatchType = "Exact"
- // CookieMatchTypePrefix indicates that a string prefix match should be
- // performed.
- CookieMatchTypePrefix CookieMatchType = "Prefix"
-)
-
-// IngressControllerCaptureHTTPCookie describes an HTTP cookie that should be
-// captured.
-type IngressControllerCaptureHTTPCookie struct {
- IngressControllerCaptureHTTPCookieUnion `json:",inline"`
-
- // maxLength specifies a maximum length of the string that will be
- // logged, which includes the cookie name, cookie value, and
- // one-character delimiter. If the log entry exceeds this length, the
- // value will be truncated in the log message. Note that the ingress
- // controller may impose a separate bound on the total length of HTTP
- // headers in a request.
- //
- // +kubebuilder:validation:Minimum=1
- // +kubebuilder:validation:Maximum=1024
- // +required
- MaxLength int `json:"maxLength"`
-}
-
-// IngressControllerCaptureHTTPCookieUnion describes optional fields of an HTTP cookie that should be captured.
-// +union
-type IngressControllerCaptureHTTPCookieUnion struct {
- // matchType specifies the type of match to be performed on the cookie
- // name. Allowed values are "Exact" for an exact string match and
- // "Prefix" for a string prefix match. If "Exact" is specified, a name
- // must be specified in the name field. If "Prefix" is provided, a
- // prefix must be specified in the namePrefix field. For example,
- // specifying matchType "Prefix" and namePrefix "foo" will capture a
- // cookie named "foo" or "foobar" but not one named "bar". The first
- // matching cookie is captured.
- //
- // +unionDiscriminator
- // +required
- MatchType CookieMatchType `json:"matchType"`
-
- // name specifies a cookie name. Its value must be a valid HTTP cookie
- // name as defined in RFC 6265 section 4.1.
- //
- // +kubebuilder:validation:Pattern="^[-!#$%&'*+.0-9A-Z^_`a-z|~]*$"
- // +kubebuilder:validation:MinLength=0
- // +kubebuilder:validation:MaxLength=1024
- // +optional
- Name string `json:"name"`
-
- // namePrefix specifies a cookie name prefix. Its value must be a valid
- // HTTP cookie name as defined in RFC 6265 section 4.1.
- //
- // +kubebuilder:validation:Pattern="^[-!#$%&'*+.0-9A-Z^_`a-z|~]*$"
- // +kubebuilder:validation:MinLength=0
- // +kubebuilder:validation:MaxLength=1024
- // +optional
- NamePrefix string `json:"namePrefix"`
-}
-
-// LoggingPolicy indicates how an event should be logged.
-// +kubebuilder:validation:Enum=Log;Ignore
-type LoggingPolicy string
-
-const (
- // LoggingPolicyLog indicates that an event should be logged.
- LoggingPolicyLog LoggingPolicy = "Log"
- // LoggingPolicyIgnore indicates that an event should not be logged.
- LoggingPolicyIgnore LoggingPolicy = "Ignore"
-)
-
-// AccessLogging describes how client requests should be logged.
-type AccessLogging struct {
- // destination is where access logs go.
- //
- // +required
- Destination LoggingDestination `json:"destination"`
-
- // httpLogFormat specifies the format of the log message for an HTTP
- // request.
- //
- // If this field is empty, log messages use the implementation's default
- // HTTP log format. For HAProxy's default HTTP log format, see the
- // HAProxy documentation:
- // http://cbonte.github.io/haproxy-dconv/2.0/configuration.html#8.2.3
- //
- // Note that this format only applies to cleartext HTTP connections
- // and to secure HTTP connections for which the ingress controller
- // terminates encryption (that is, edge-terminated or reencrypt
- // connections). It does not affect the log format for TLS passthrough
- // connections.
- //
- // +optional
- HttpLogFormat string `json:"httpLogFormat,omitempty"`
-
- // httpCaptureHeaders defines HTTP headers that should be captured in
- // access logs. If this field is empty, no headers are captured.
- //
- // Note that this option only applies to cleartext HTTP connections
- // and to secure HTTP connections for which the ingress controller
- // terminates encryption (that is, edge-terminated or reencrypt
- // connections). Headers cannot be captured for TLS passthrough
- // connections.
- //
- // +optional
- HTTPCaptureHeaders IngressControllerCaptureHTTPHeaders `json:"httpCaptureHeaders,omitempty"`
-
- // httpCaptureCookies specifies HTTP cookies that should be captured in
- // access logs. If this field is empty, no cookies are captured.
- //
- // +nullable
- // +optional
- // +kubebuilder:validation:MaxItems=1
- // +listType=atomic
- HTTPCaptureCookies []IngressControllerCaptureHTTPCookie `json:"httpCaptureCookies,omitempty"`
-
- // logEmptyRequests specifies how connections on which no request is
- // received should be logged. Typically, these empty requests come from
- // load balancers' health probes or Web browsers' speculative
- // connections ("preconnect"), in which case logging these requests may
- // be undesirable. However, these requests may also be caused by
- // network errors, in which case logging empty requests may be useful
- // for diagnosing the errors. In addition, these requests may be caused
- // by port scans, in which case logging empty requests may aid in
- // detecting intrusion attempts. Allowed values for this field are
- // "Log" and "Ignore". The default value is "Log".
- //
- // +optional
- // +kubebuilder:default:="Log"
- LogEmptyRequests LoggingPolicy `json:"logEmptyRequests,omitempty"`
-}
-
-// IngressControllerLogging describes what should be logged where.
-type IngressControllerLogging struct {
- // access describes how the client requests should be logged.
- //
- // If this field is empty, access logging is disabled.
- //
- // +optional
- Access *AccessLogging `json:"access,omitempty"`
-}
-
-// IngressControllerHTTPHeaderPolicy is a policy for setting HTTP headers.
-//
-// +kubebuilder:validation:Enum=Append;Replace;IfNone;Never
-type IngressControllerHTTPHeaderPolicy string
-
-const (
- // AppendHTTPHeaderPolicy appends the header, preserving any existing header.
- AppendHTTPHeaderPolicy IngressControllerHTTPHeaderPolicy = "Append"
- // ReplaceHTTPHeaderPolicy sets the header, removing any existing header.
- ReplaceHTTPHeaderPolicy IngressControllerHTTPHeaderPolicy = "Replace"
- // IfNoneHTTPHeaderPolicy sets the header if it is not already set.
- IfNoneHTTPHeaderPolicy IngressControllerHTTPHeaderPolicy = "IfNone"
- // NeverHTTPHeaderPolicy never sets the header, preserving any existing
- // header.
- NeverHTTPHeaderPolicy IngressControllerHTTPHeaderPolicy = "Never"
-)
-
-// IngressControllerHTTPUniqueIdHeaderPolicy describes configuration for a
-// unique id header.
-type IngressControllerHTTPUniqueIdHeaderPolicy struct {
- // name specifies the name of the HTTP header (for example, "unique-id")
- // that the ingress controller should inject into HTTP requests. The
- // field's value must be a valid HTTP header name as defined in RFC 2616
- // section 4.2. If the field is empty, no header is injected.
- //
- // +optional
- // +kubebuilder:validation:Pattern="^$|^[-!#$%&'*+.0-9A-Z^_`a-z|~]+$"
- // +kubebuilder:validation:MinLength=0
- // +kubebuilder:validation:MaxLength=1024
- Name string `json:"name,omitempty"`
-
- // format specifies the format for the injected HTTP header's value.
- // This field has no effect unless name is specified. For the
- // HAProxy-based ingress controller implementation, this format uses the
- // same syntax as the HTTP log format. If the field is empty, the
- // default value is "%{+X}o\\ %ci:%cp_%fi:%fp_%Ts_%rt:%pid"; see the
- // corresponding HAProxy documentation:
- // http://cbonte.github.io/haproxy-dconv/2.0/configuration.html#8.2.3
- //
- // +optional
- // +kubebuilder:validation:Pattern="^(%(%|(\\{[-+]?[QXE](,[-+]?[QXE])*\\})?([A-Za-z]+|\\[[.0-9A-Z_a-z]+(\\([^)]+\\))?(,[.0-9A-Z_a-z]+(\\([^)]+\\))?)*\\]))|[^%[:cntrl:]])*$"
- // +kubebuilder:validation:MinLength=0
- // +kubebuilder:validation:MaxLength=1024
- Format string `json:"format,omitempty"`
-}
-
-// IngressControllerHTTPHeaderNameCaseAdjustment is the name of an HTTP header
-// (for example, "X-Forwarded-For") in the desired capitalization. The value
-// must be a valid HTTP header name as defined in RFC 2616 section 4.2.
-//
-// +kubebuilder:validation:Pattern="^$|^[-!#$%&'*+.0-9A-Z^_`a-z|~]+$"
-// +kubebuilder:validation:MinLength=0
-// +kubebuilder:validation:MaxLength=1024
-type IngressControllerHTTPHeaderNameCaseAdjustment string
-
-// IngressControllerHTTPHeaders specifies how the IngressController handles
-// certain HTTP headers.
-type IngressControllerHTTPHeaders struct {
- // forwardedHeaderPolicy specifies when and how the IngressController
- // sets the Forwarded, X-Forwarded-For, X-Forwarded-Host,
- // X-Forwarded-Port, X-Forwarded-Proto, and X-Forwarded-Proto-Version
- // HTTP headers. The value may be one of the following:
- //
- // * "Append", which specifies that the IngressController appends the
- // headers, preserving existing headers.
- //
- // * "Replace", which specifies that the IngressController sets the
- // headers, replacing any existing Forwarded or X-Forwarded-* headers.
- //
- // * "IfNone", which specifies that the IngressController sets the
- // headers if they are not already set.
- //
- // * "Never", which specifies that the IngressController never sets the
- // headers, preserving any existing headers.
- //
- // By default, the policy is "Append".
- //
- // +optional
- ForwardedHeaderPolicy IngressControllerHTTPHeaderPolicy `json:"forwardedHeaderPolicy,omitempty"`
-
- // uniqueId describes configuration for a custom HTTP header that the
- // ingress controller should inject into incoming HTTP requests.
- // Typically, this header is configured to have a value that is unique
- // to the HTTP request. The header can be used by applications or
- // included in access logs to facilitate tracing individual HTTP
- // requests.
- //
- // If this field is empty, no such header is injected into requests.
- //
- // +optional
- UniqueId IngressControllerHTTPUniqueIdHeaderPolicy `json:"uniqueId,omitempty"`
-
- // headerNameCaseAdjustments specifies case adjustments that can be
- // applied to HTTP header names. Each adjustment is specified as an
- // HTTP header name with the desired capitalization. For example,
- // specifying "X-Forwarded-For" indicates that the "x-forwarded-for"
- // HTTP header should be adjusted to have the specified capitalization.
- //
- // These adjustments are only applied to cleartext, edge-terminated, and
- // re-encrypt routes, and only when using HTTP/1.
- //
- // For request headers, these adjustments are applied only for routes
- // that have the haproxy.router.openshift.io/h1-adjust-case=true
- // annotation. For response headers, these adjustments are applied to
- // all HTTP responses.
- //
- // If this field is empty, no request headers are adjusted.
- //
- // +nullable
- // +optional
- // +listType=atomic
- HeaderNameCaseAdjustments []IngressControllerHTTPHeaderNameCaseAdjustment `json:"headerNameCaseAdjustments,omitempty"`
-
- // actions specifies options for modifying headers and their values.
- // Note that this option only applies to cleartext HTTP connections
- // and to secure HTTP connections for which the ingress controller
- // terminates encryption (that is, edge-terminated or reencrypt
- // connections). Headers cannot be modified for TLS passthrough
- // connections.
- // Setting the HSTS (`Strict-Transport-Security`) header is not supported via actions. `Strict-Transport-Security`
- // may only be configured using the "haproxy.router.openshift.io/hsts_header" route annotation, and only in
- // accordance with the policy specified in Ingress.Spec.RequiredHSTSPolicies.
- // Any actions defined here are applied after any actions related to the following other fields:
- // cache-control, spec.clientTLS,
- // spec.httpHeaders.forwardedHeaderPolicy, spec.httpHeaders.uniqueId,
- // and spec.httpHeaders.headerNameCaseAdjustments.
- // In case of HTTP request headers, the actions specified in spec.httpHeaders.actions on the Route will be executed after
- // the actions specified in the IngressController's spec.httpHeaders.actions field.
- // In case of HTTP response headers, the actions specified in spec.httpHeaders.actions on the IngressController will be
- // executed after the actions specified in the Route's spec.httpHeaders.actions field.
- // Headers set using this API cannot be captured for use in access logs.
- // The following header names are reserved and may not be modified via this API:
- // Strict-Transport-Security, Proxy, Host, Cookie, Set-Cookie.
- // Note that the total size of all net added headers *after* interpolating dynamic values
- // must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the
- // IngressController. Please refer to the documentation
- // for that API field for more details.
- // +optional
- Actions IngressControllerHTTPHeaderActions `json:"actions,omitempty"`
-}
-
-// IngressControllerHTTPHeaderActions defines configuration for actions on HTTP request and response headers.
-type IngressControllerHTTPHeaderActions struct {
- // response is a list of HTTP response headers to modify.
- // Actions defined here will modify the response headers of all requests passing through an ingress controller.
- // These actions are applied to all Routes i.e. for all connections handled by the ingress controller defined within a cluster.
- // IngressController actions for response headers will be executed after Route actions.
- // Currently, actions may define to either `Set` or `Delete` headers values.
- // Actions are applied in sequence as defined in this list.
- // A maximum of 20 response header actions may be configured.
- // Sample fetchers allowed are "res.hdr" and "ssl_c_der".
- // Converters allowed are "lower" and "base64".
- // Example header values: "%[res.hdr(X-target),lower]", "%{+Q}[ssl_c_der,base64]".
- // +listType=map
- // +listMapKey=name
- // +optional
- // +kubebuilder:validation:MaxItems=20
- // +kubebuilder:validation:XValidation:rule=`self.all(key, key.action.type == "Delete" || (has(key.action.set) && key.action.set.value.matches('^(?:%(?:%|(?:\\{[-+]?[QXE](?:,[-+]?[QXE])*\\})?\\[(?:res\\.hdr\\([0-9A-Za-z-]+\\)|ssl_c_der)(?:,(?:lower|base64))*\\])|[^%[:cntrl:]])+$')))`,message="Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are res.hdr, ssl_c_der. Converters allowed are lower, base64."
- Response []IngressControllerHTTPHeader `json:"response"`
- // request is a list of HTTP request headers to modify.
- // Actions defined here will modify the request headers of all requests passing through an ingress controller.
- // These actions are applied to all Routes i.e. for all connections handled by the ingress controller defined within a cluster.
- // IngressController actions for request headers will be executed before Route actions.
- // Currently, actions may define to either `Set` or `Delete` headers values.
- // Actions are applied in sequence as defined in this list.
- // A maximum of 20 request header actions may be configured.
- // Sample fetchers allowed are "req.hdr" and "ssl_c_der".
- // Converters allowed are "lower" and "base64".
- // Example header values: "%[req.hdr(X-target),lower]", "%{+Q}[ssl_c_der,base64]".
- // + ---
- // + Note: Any change to regex mentioned below must be reflected in the CRD validation of route in https://github.com/openshift/library-go/blob/master/pkg/route/validation/validation.go and vice-versa.
- // +listType=map
- // +listMapKey=name
- // +optional
- // +kubebuilder:validation:MaxItems=20
- // +kubebuilder:validation:XValidation:rule=`self.all(key, key.action.type == "Delete" || (has(key.action.set) && key.action.set.value.matches('^(?:%(?:%|(?:\\{[-+]?[QXE](?:,[-+]?[QXE])*\\})?\\[(?:req\\.hdr\\([0-9A-Za-z-]+\\)|ssl_c_der)(?:,(?:lower|base64))*\\])|[^%[:cntrl:]])+$')))`,message="Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are req.hdr, ssl_c_der. Converters allowed are lower, base64."
- Request []IngressControllerHTTPHeader `json:"request"`
-}
-
-// IngressControllerHTTPHeader specifies configuration for setting or deleting an HTTP header.
-type IngressControllerHTTPHeader struct {
- // name specifies the name of a header on which to perform an action. Its value must be a valid HTTP header
- // name as defined in RFC 2616 section 4.2.
- // The name must consist only of alphanumeric and the following special characters, "-!#$%&'*+.^_`".
- // The following header names are reserved and may not be modified via this API:
- // Strict-Transport-Security, Proxy, Host, Cookie, Set-Cookie.
- // It must be no more than 255 characters in length.
- // Header name must be unique.
- // +required
- // +kubebuilder:validation:MinLength=1
- // +kubebuilder:validation:MaxLength=255
- // +kubebuilder:validation:Pattern="^[-!#$%&'*+.0-9A-Z^_`a-z|~]+$"
- // +kubebuilder:validation:XValidation:rule="self.lowerAscii() != 'strict-transport-security'",message="strict-transport-security header may not be modified via header actions"
- // +kubebuilder:validation:XValidation:rule="self.lowerAscii() != 'proxy'",message="proxy header may not be modified via header actions"
- // +kubebuilder:validation:XValidation:rule="self.lowerAscii() != 'host'",message="host header may not be modified via header actions"
- // +kubebuilder:validation:XValidation:rule="self.lowerAscii() != 'cookie'",message="cookie header may not be modified via header actions"
- // +kubebuilder:validation:XValidation:rule="self.lowerAscii() != 'set-cookie'",message="set-cookie header may not be modified via header actions"
- Name string `json:"name"`
- // action specifies actions to perform on headers, such as setting or deleting headers.
- // +required
- Action IngressControllerHTTPHeaderActionUnion `json:"action"`
-}
-
-// IngressControllerHTTPHeaderActionUnion specifies an action to take on an HTTP header.
-// +kubebuilder:validation:XValidation:rule="has(self.type) && self.type == 'Set' ? has(self.set) : !has(self.set)",message="set is required when type is Set, and forbidden otherwise"
-// +union
-type IngressControllerHTTPHeaderActionUnion struct {
- // type defines the type of the action to be applied on the header.
- // Possible values are Set or Delete.
- // Set allows you to set HTTP request and response headers.
- // Delete allows you to delete HTTP request and response headers.
- // +unionDiscriminator
- // +kubebuilder:validation:Enum:=Set;Delete
- // +required
- Type IngressControllerHTTPHeaderActionType `json:"type"`
-
- // set specifies how the HTTP header should be set.
- // This field is required when type is Set and forbidden otherwise.
- // +optional
- // +unionMember
- Set *IngressControllerSetHTTPHeader `json:"set,omitempty"`
-}
-
-// IngressControllerHTTPHeaderActionType defines actions that can be performed on HTTP headers.
-type IngressControllerHTTPHeaderActionType string
-
-const (
- // Set specifies that an HTTP header should be set.
- Set IngressControllerHTTPHeaderActionType = "Set"
- // Delete specifies that an HTTP header should be deleted.
- Delete IngressControllerHTTPHeaderActionType = "Delete"
-)
-
-// IngressControllerSetHTTPHeader defines the value which needs to be set on an HTTP header.
-type IngressControllerSetHTTPHeader struct {
- // value specifies a header value.
- // Dynamic values can be added. The value will be interpreted as an HAProxy format string as defined in
- // http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and
- // otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2.
- // The value of this field must be no more than 16384 characters in length.
- // Note that the total size of all net added headers *after* interpolating dynamic values
- // must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the
- // IngressController.
- // + ---
- // + Note: This limit was selected as most common web servers have a limit of 16384 characters or some lower limit.
- // + See .
- // +required
- // +kubebuilder:validation:MinLength=1
- // +kubebuilder:validation:MaxLength=16384
- Value string `json:"value"`
-}
-
-// IngressControllerTuningOptions specifies options for tuning the performance
-// of ingress controller pods
-type IngressControllerTuningOptions struct {
- // headerBufferBytes describes how much memory should be reserved
- // (in bytes) for IngressController connection sessions.
- // Note that this value must be at least 16384 if HTTP/2 is
- // enabled for the IngressController (https://tools.ietf.org/html/rfc7540).
- // If this field is empty, the IngressController will use a default value
- // of 32768 bytes.
- //
- // Setting this field is generally not recommended as headerBufferBytes
- // values that are too small may break the IngressController and
- // headerBufferBytes values that are too large could cause the
- // IngressController to use significantly more memory than necessary.
- //
- // +kubebuilder:validation:Minimum=16384
- // +optional
- HeaderBufferBytes int32 `json:"headerBufferBytes,omitempty"`
-
- // headerBufferMaxRewriteBytes describes how much memory should be reserved
- // (in bytes) from headerBufferBytes for HTTP header rewriting
- // and appending for IngressController connection sessions.
- // Note that incoming HTTP requests will be limited to
- // (headerBufferBytes - headerBufferMaxRewriteBytes) bytes, meaning
- // headerBufferBytes must be greater than headerBufferMaxRewriteBytes.
- // If this field is empty, the IngressController will use a default value
- // of 8192 bytes.
- //
- // Setting this field is generally not recommended as
- // headerBufferMaxRewriteBytes values that are too small may break the
- // IngressController and headerBufferMaxRewriteBytes values that are too
- // large could cause the IngressController to use significantly more memory
- // than necessary.
- //
- // +kubebuilder:validation:Minimum=4096
- // +optional
- HeaderBufferMaxRewriteBytes int32 `json:"headerBufferMaxRewriteBytes,omitempty"`
-
- // threadCount defines the number of threads created per HAProxy process.
- // Creating more threads allows each ingress controller pod to handle more
- // connections, at the cost of more system resources being used. HAProxy
- // currently supports up to 64 threads. If this field is empty, the
- // IngressController will use the default value. The current default is 4
- // threads, but this may change in future releases.
- //
- // Setting this field is generally not recommended. Increasing the number
- // of HAProxy threads allows ingress controller pods to utilize more CPU
- // time under load, potentially starving other pods if set too high.
- // Reducing the number of threads may cause the ingress controller to
- // perform poorly.
- //
- // +kubebuilder:validation:Minimum=1
- // +kubebuilder:validation:Maximum=64
- // +optional
- ThreadCount int32 `json:"threadCount,omitempty"`
-
- // clientTimeout defines how long a connection will be held open while
- // waiting for a client response.
- //
- // If unset, the default timeout is 30s
- // +kubebuilder:validation:Format=duration
- // +optional
- ClientTimeout *metav1.Duration `json:"clientTimeout,omitempty"`
-
- // clientFinTimeout defines how long a connection will be held open while
- // waiting for the client response to the server/backend closing the
- // connection.
- //
- // If unset, the default timeout is 1s
- // +kubebuilder:validation:Format=duration
- // +optional
- ClientFinTimeout *metav1.Duration `json:"clientFinTimeout,omitempty"`
-
- // serverTimeout defines how long a connection will be held open while
- // waiting for a server/backend response.
- //
- // If unset, the default timeout is 30s
- // +kubebuilder:validation:Format=duration
- // +optional
- ServerTimeout *metav1.Duration `json:"serverTimeout,omitempty"`
-
- // serverFinTimeout defines how long a connection will be held open while
- // waiting for the server/backend response to the client closing the
- // connection.
- //
- // If unset, the default timeout is 1s
- // +kubebuilder:validation:Format=duration
- // +optional
- ServerFinTimeout *metav1.Duration `json:"serverFinTimeout,omitempty"`
-
- // tunnelTimeout defines how long a tunnel connection (including
- // websockets) will be held open while the tunnel is idle.
- //
- // If unset, the default timeout is 1h
- // +kubebuilder:validation:Format=duration
- // +optional
- TunnelTimeout *metav1.Duration `json:"tunnelTimeout,omitempty"`
-
- // connectTimeout defines the maximum time to wait for
- // a connection attempt to a server/backend to succeed.
- //
- // This field expects an unsigned duration string of decimal numbers, each with optional
- // fraction and a unit suffix, e.g. "300ms", "1.5h" or "2h45m".
- // Valid time units are "ns", "us" (or "µs" U+00B5 or "μs" U+03BC), "ms", "s", "m", "h".
- //
- // When omitted, this means the user has no opinion and the platform is left
- // to choose a reasonable default. This default is subject to change over time.
- // The current default is 5s.
- //
- // +kubebuilder:validation:Pattern=^(0|([0-9]+(\.[0-9]+)?(ns|us|µs|μs|ms|s|m|h))+)$
- // +kubebuilder:validation:Type:=string
- // +optional
- ConnectTimeout *metav1.Duration `json:"connectTimeout,omitempty"`
-
- // httpKeepAliveTimeout defines the maximum allowed time to wait for
- // a new HTTP request to appear on a connection from the client to the router.
- //
- // This field expects an unsigned duration string of a decimal number, with optional
- // fraction and a unit suffix, e.g. "300ms", "1.5s" or "2m45s".
- // Valid time units are "ms", "s", "m".
- // The allowed range is from 1 millisecond to 15 minutes.
- //
- // When omitted, this means the user has no opinion and the platform is left
- // to choose a reasonable default. This default is subject to change over time.
- // The current default is 300s.
- //
- // Low values (tens of milliseconds or less) can cause clients to close and reopen connections
- // for each request, leading to reduced connection sharing.
- // For HTTP/2, special care should be taken with low values.
- // A few seconds is a reasonable starting point to avoid holding idle connections open
- // while still allowing subsequent requests to reuse the connection.
- //
- // High values (minutes or more) favor connection reuse but may cause idle
- // connections to linger longer.
- //
- // +kubebuilder:validation:Type:=string
- // +kubebuilder:validation:XValidation:rule="self.matches('^([0-9]+(\\\\.[0-9]+)?(ms|s|m))+$')",message="httpKeepAliveTimeout must be a valid duration string composed of an unsigned integer value, optionally followed by a decimal fraction and a unit suffix (ms, s, m)"
- // +kubebuilder:validation:XValidation:rule="!self.matches('^([0-9]+(\\\\.[0-9]+)?(ms|s|m))+$') || duration(self) <= duration('15m')",message="httpKeepAliveTimeout must be less than or equal to 15 minutes"
- // +kubebuilder:validation:XValidation:rule="!self.matches('^([0-9]+(\\\\.[0-9]+)?(ms|s|m))+$') || duration(self) >= duration('1ms')",message="httpKeepAliveTimeout must be greater than or equal to 1 millisecond"
- // +kubebuilder:validation:MinLength=1
- // +kubebuilder:validation:MaxLength=16
- // +optional
- HTTPKeepAliveTimeout *metav1.Duration `json:"httpKeepAliveTimeout,omitempty"`
-
- // tlsInspectDelay defines how long the router can hold data to find a
- // matching route.
- //
- // Setting this too short can cause the router to fall back to the default
- // certificate for edge-terminated or reencrypt routes even when a better
- // matching certificate could be used.
- //
- // If unset, the default inspect delay is 5s
- // +kubebuilder:validation:Format=duration
- // +optional
- TLSInspectDelay *metav1.Duration `json:"tlsInspectDelay,omitempty"`
-
- // healthCheckInterval defines how long the router waits between two consecutive
- // health checks on its configured backends. This value is applied globally as
- // a default for all routes, but may be overridden per-route by the route annotation
- // "router.openshift.io/haproxy.health.check.interval".
- //
- // Expects an unsigned duration string of decimal numbers, each with optional
- // fraction and a unit suffix, eg "300ms", "1.5h" or "2h45m".
- // Valid time units are "ns", "us" (or "µs" U+00B5 or "μs" U+03BC), "ms", "s", "m", "h".
- //
- // Setting this to less than 5s can cause excess traffic due to too frequent
- // TCP health checks and accompanying SYN packet storms. Alternatively, setting
- // this too high can result in increased latency, due to backend servers that are no
- // longer available, but haven't yet been detected as such.
- //
- // An empty or zero healthCheckInterval means no opinion and IngressController chooses
- // a default, which is subject to change over time.
- // Currently the default healthCheckInterval value is 5s.
- //
- // Currently the minimum allowed value is 1s and the maximum allowed value is
- // 2147483647ms (24.85 days). Both are subject to change over time.
- //
- // +kubebuilder:validation:Pattern=^(0|([0-9]+(\.[0-9]+)?(ns|us|µs|μs|ms|s|m|h))+)$
- // +kubebuilder:validation:Type:=string
- // +optional
- HealthCheckInterval *metav1.Duration `json:"healthCheckInterval,omitempty"`
-
- // maxConnections defines the maximum number of simultaneous
- // connections that can be established per HAProxy process.
- // Increasing this value allows each ingress controller pod to
- // handle more connections but at the cost of additional
- // system resources being consumed.
- //
- // Permitted values are: empty, 0, -1, and the range
- // 2000-2000000.
- //
- // If this field is empty or 0, the IngressController will use
- // the default value of 50000, but the default is subject to
- // change in future releases.
- //
- // If the value is -1 then HAProxy will dynamically compute a
- // maximum value based on the available ulimits in the running
- // container. Selecting -1 (i.e., auto) will result in a large
- // value being computed (~520000 on OpenShift >=4.10 clusters)
- // and therefore each HAProxy process will incur significant
- // memory usage compared to the current default of 50000.
- //
- // Setting a value that is greater than the current operating
- // system limit will prevent the HAProxy process from
- // starting.
- //
- // If you choose a discrete value (e.g., 750000) and the
- // router pod is migrated to a new node, there's no guarantee
- // that that new node has identical ulimits configured. In
- // such a scenario the pod would fail to start. If you have
- // nodes with different ulimits configured (e.g., different
- // tuned profiles) and you choose a discrete value then the
- // guidance is to use -1 and let the value be computed
- // dynamically at runtime.
- //
- // You can monitor memory usage for router containers with the
- // following metric:
- // 'container_memory_working_set_bytes{container="router",namespace="openshift-ingress"}'.
- //
- // You can monitor memory usage of individual HAProxy
- // processes in router containers with the following metric:
- // 'container_memory_working_set_bytes{container="router",namespace="openshift-ingress"}/container_processes{container="router",namespace="openshift-ingress"}'.
- //
- // +optional
- MaxConnections int32 `json:"maxConnections,omitempty"`
-
- // reloadInterval defines the minimum interval at which the router is allowed to reload
- // to accept new changes. Increasing this value can prevent the accumulation of
- // HAProxy processes, depending on the scenario. Increasing this interval can
- // also lessen load imbalance on a backend's servers when using the roundrobin
- // balancing algorithm. Alternatively, decreasing this value may decrease latency
- // since updates to HAProxy's configuration can take effect more quickly.
- //
- // The value must be a time duration value; see .
- // Currently, the minimum value allowed is 1s, and the maximum allowed value is
- // 120s. Minimum and maximum allowed values may change in future versions of OpenShift.
- // Note that if a duration outside of these bounds is provided, the value of reloadInterval
- // will be capped/floored and not rejected (e.g. a duration of over 120s will be capped to
- // 120s; the IngressController will not reject and replace this disallowed value with
- // the default).
- //
- // A zero value for reloadInterval tells the IngressController to choose the default,
- // which is currently 5s and subject to change without notice.
- //
- // This field expects an unsigned duration string of decimal numbers, each with optional
- // fraction and a unit suffix, e.g. "300ms", "1.5h" or "2h45m".
- // Valid time units are "ns", "us" (or "µs" U+00B5 or "μs" U+03BC), "ms", "s", "m", "h".
- //
- // Note: Setting a value significantly larger than the default of 5s can cause latency
- // in observing updates to routes and their endpoints. HAProxy's configuration will
- // be reloaded less frequently, and newly created routes will not be served until the
- // subsequent reload.
- //
- // +kubebuilder:validation:Pattern=^(0|([0-9]+(\.[0-9]+)?(ns|us|µs|μs|ms|s|m|h))+)$
- // +kubebuilder:validation:Type:=string
- // +optional
- ReloadInterval metav1.Duration `json:"reloadInterval,omitempty"`
-}
-
-// HTTPEmptyRequestsPolicy indicates how HTTP connections for which no request
-// is received should be handled.
-// +kubebuilder:validation:Enum=Respond;Ignore
-type HTTPEmptyRequestsPolicy string
-
-const (
- // HTTPEmptyRequestsPolicyRespond indicates that the ingress controller
- // should respond to empty requests.
- HTTPEmptyRequestsPolicyRespond HTTPEmptyRequestsPolicy = "Respond"
- // HTTPEmptyRequestsPolicyIgnore indicates that the ingress controller
- // should ignore empty requests.
- HTTPEmptyRequestsPolicyIgnore HTTPEmptyRequestsPolicy = "Ignore"
-)
-
-var (
- // Available indicates the ingress controller deployment is available.
- IngressControllerAvailableConditionType = "Available"
- // LoadBalancerManaged indicates the management status of any load balancer
- // service associated with an ingress controller.
- LoadBalancerManagedIngressConditionType = "LoadBalancerManaged"
- // LoadBalancerReady indicates the ready state of any load balancer service
- // associated with an ingress controller.
- LoadBalancerReadyIngressConditionType = "LoadBalancerReady"
- // DNSManaged indicates the management status of any DNS records for the
- // ingress controller.
- DNSManagedIngressConditionType = "DNSManaged"
- // DNSReady indicates the ready state of any DNS records for the ingress
- // controller.
- DNSReadyIngressConditionType = "DNSReady"
-)
-
-// IngressControllerStatus defines the observed status of the IngressController.
-type IngressControllerStatus struct {
- // availableReplicas is number of observed available replicas according to the
- // ingress controller deployment.
- // +optional
- AvailableReplicas int32 `json:"availableReplicas"`
-
- // selector is a label selector, in string format, for ingress controller pods
- // corresponding to the IngressController. The number of matching pods should
- // equal the value of availableReplicas.
- // +optional
- Selector string `json:"selector"`
-
- // domain is the actual domain in use.
- // +optional
- Domain string `json:"domain"`
-
- // endpointPublishingStrategy is the actual strategy in use.
- // +optional
- EndpointPublishingStrategy *EndpointPublishingStrategy `json:"endpointPublishingStrategy,omitempty"`
-
- // conditions is a list of conditions and their status.
- //
- // Available means the ingress controller deployment is available and
- // servicing route and ingress resources (i.e, .status.availableReplicas
- // equals .spec.replicas)
- //
- // There are additional conditions which indicate the status of other
- // ingress controller features and capabilities.
- //
- // * LoadBalancerManaged
- // - True if the following conditions are met:
- // * The endpoint publishing strategy requires a service load balancer.
- // - False if any of those conditions are unsatisfied.
- //
- // * LoadBalancerReady
- // - True if the following conditions are met:
- // * A load balancer is managed.
- // * The load balancer is ready.
- // - False if any of those conditions are unsatisfied.
- //
- // * DNSManaged
- // - True if the following conditions are met:
- // * The endpoint publishing strategy and platform support DNS.
- // * The ingress controller domain is set.
- // * dns.config.openshift.io/cluster configures DNS zones.
- // - False if any of those conditions are unsatisfied.
- //
- // * DNSReady
- // - True if the following conditions are met:
- // * DNS is managed.
- // * DNS records have been successfully created.
- // - False if any of those conditions are unsatisfied.
- // +listType=map
- // +listMapKey=type
- // +optional
- Conditions []OperatorCondition `json:"conditions,omitempty"`
-
- // tlsProfile is the TLS connection configuration that is in effect.
- // +optional
- TLSProfile *configv1.TLSProfileSpec `json:"tlsProfile,omitempty"`
-
- // observedGeneration is the most recent generation observed.
- // +optional
- ObservedGeneration int64 `json:"observedGeneration,omitempty"`
-
- // namespaceSelector is the actual namespaceSelector in use.
- // +optional
- NamespaceSelector *metav1.LabelSelector `json:"namespaceSelector,omitempty"`
-
- // routeSelector is the actual routeSelector in use.
- // +optional
- RouteSelector *metav1.LabelSelector `json:"routeSelector,omitempty"`
-}
-
-// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
-
-// IngressControllerList contains a list of IngressControllers.
-//
-// Compatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer).
-// +openshift:compatibility-gen:level=1
-type IngressControllerList struct {
- metav1.TypeMeta `json:",inline"`
-
- // metadata is the standard list's metadata.
- // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
- metav1.ListMeta `json:"metadata,omitempty"`
-
- Items []IngressController `json:"items"`
-}
-
-// IngressControllerConnectionTerminationPolicy defines the behaviour
-// for handling idle connections during a soft reload of the router.
-//
-// +kubebuilder:validation:Enum=Immediate;Deferred
-type IngressControllerConnectionTerminationPolicy string
-
-const (
- // IngressControllerConnectionTerminationPolicyImmediate specifies
- // that idle connections should be closed immediately during a
- // router reload.
- IngressControllerConnectionTerminationPolicyImmediate IngressControllerConnectionTerminationPolicy = "Immediate"
-
- // IngressControllerConnectionTerminationPolicyDeferred
- // specifies that idle connections should remain open until a
- // terminating event, such as a new request, the expiration of
- // the proxy keep-alive timeout, or the client closing the
- // connection.
- IngressControllerConnectionTerminationPolicyDeferred IngressControllerConnectionTerminationPolicy = "Deferred"
-)
-
-// IngressControllerClosedClientConnectionPolicy controls how the IngressController
-// behaves when the client closes the TCP connection while the TLS
-// handshake or HTTP request is in progress.
-//
-// +kubebuilder:validation:Enum=Abort;Continue
-type IngressControllerClosedClientConnectionPolicy string
-
-const (
- // IngressControllerClosedClientConnectionPolicyAbort aborts processing early when the client
- // closes the connection.
- //
- // This affects two types of processing: TLS handshake computation on the router
- // and request handling.
- //
- // When the client closes the connection, the router will stop processing
- // the TLS handshake, preventing unnecessary CPU work.
- //
- // If the HTTP request has not yet been sent to the backend, it will be aborted.
- // If the request is already being processed by the backend, the router will
- // half-close the connection to signal this condition to the backend server,
- // which can then decide how to proceed.
- IngressControllerClosedClientConnectionPolicyAbort IngressControllerClosedClientConnectionPolicy = "Abort"
-
- // IngressControllerClosedClientConnectionPolicyContinue continues processing even if the client
- // closes the connection.
- //
- // The router will complete the TLS handshake and wait for the backend
- // server's response regardless of the client having closed the connection.
- IngressControllerClosedClientConnectionPolicyContinue IngressControllerClosedClientConnectionPolicy = "Continue"
-)
diff --git a/vendor/github.com/openshift/api/operator/v1/types_ingresscontroller.go b/vendor/github.com/openshift/api/operator/v1/types_ingresscontroller.go
new file mode 100644
index 0000000000..2d442d4b41
--- /dev/null
+++ b/vendor/github.com/openshift/api/operator/v1/types_ingresscontroller.go
@@ -0,0 +1,2386 @@
+package v1
+
+import (
+ metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
+ "k8s.io/apimachinery/pkg/runtime"
+
+ corev1 "k8s.io/api/core/v1"
+
+ configv1 "github.com/openshift/api/config/v1"
+)
+
+// +genclient
+// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
+// +kubebuilder:object:root=true
+// +kubebuilder:subresource:status
+// +kubebuilder:subresource:scale:specpath=.spec.replicas,statuspath=.status.availableReplicas,selectorpath=.status.selector
+// +kubebuilder:resource:path=ingresscontrollers,scope=Namespaced
+// +openshift:api-approved.openshift.io=https://github.com/openshift/api/pull/616
+// +openshift:capability=Ingress
+// +openshift:file-pattern=cvoRunLevel=0000_50,operatorName=ingress,operatorOrdering=00
+
+// IngressController describes a managed ingress controller for the cluster. The
+// controller can service OpenShift Route and Kubernetes Ingress resources.
+//
+// When an IngressController is created, a new ingress controller deployment is
+// created to allow external traffic to reach the services that expose Ingress
+// or Route resources. Updating this resource may lead to disruption for public
+// facing network connections as a new ingress controller revision may be rolled
+// out.
+//
+// https://kubernetes.io/docs/concepts/services-networking/ingress-controllers
+//
+// Whenever possible, sensible defaults for the platform are used. See each
+// field for more details.
+//
+// Compatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer).
+// +openshift:compatibility-gen:level=1
+// +kubebuilder:validation:XValidation:rule="!has(self.spec.domain) || size('router-' + self.metadata.name + '.' + self.spec.domain) <= 253",message="The combined 'router-' + metadata.name + '.' + .spec.domain cannot exceed 253 characters"
+type IngressController struct {
+ metav1.TypeMeta `json:",inline"`
+
+ // metadata is the standard object's metadata.
+ // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
+ metav1.ObjectMeta `json:"metadata,omitempty"`
+
+ // spec is the specification of the desired behavior of the IngressController.
+ Spec IngressControllerSpec `json:"spec,omitempty"`
+ // status is the most recently observed status of the IngressController.
+ Status IngressControllerStatus `json:"status,omitempty"`
+}
+
+// IngressControllerSpec is the specification of the desired behavior of the
+// IngressController.
+type IngressControllerSpec struct {
+ // domain is a DNS name serviced by the ingress controller and is used to
+ // configure multiple features:
+ //
+ // * For the LoadBalancerService endpoint publishing strategy, domain is
+ // used to configure DNS records. See endpointPublishingStrategy.
+ //
+ // * When using a generated default certificate, the certificate will be valid
+ // for domain and its subdomains. See defaultCertificate.
+ //
+ // * The value is published to individual Route statuses so that end-users
+ // know where to target external DNS records.
+ //
+ // domain must be unique among all IngressControllers, and cannot be
+ // updated.
+ //
+ // If empty, defaults to ingress.config.openshift.io/cluster .spec.domain.
+ //
+ // The domain value must be a valid DNS name. It must consist of lowercase
+ // alphanumeric characters, '-' or '.', and each label must start and end
+ // with an alphanumeric character and not exceed 63 characters. Maximum
+ // length of a valid DNS domain is 253 characters.
+ //
+ // The implementation may add a prefix such as "router-default." to the domain
+ // when constructing the router canonical hostname. To ensure the resulting
+ // hostname does not exceed the DNS maximum length of 253 characters,
+ // the domain length is additionally validated at the IngressController object
+ // level. For the maximum length of the domain value itself, the shortest
+ // possible variant of the prefix and the ingress controller name was considered
+ // for example "router-a."
+ //
+ // +kubebuilder:validation:MaxLength=244
+ // +kubebuilder:validation:XValidation:rule="!format.dns1123Subdomain().validate(self).hasValue()",message="domain must consist of lower case alphanumeric characters, '-' or '.', and must start and end with an alphanumeric character"
+ // +kubebuilder:validation:XValidation:rule="self.split('.').all(label, size(label) <= 63)",message="each DNS label must not exceed 63 characters"
+ // +optional
+ Domain string `json:"domain,omitempty"`
+
+ // httpErrorCodePages specifies a configmap with custom error pages.
+ // The administrator must create this configmap in the openshift-config namespace.
+ // This configmap should have keys in the format "error-page-.http",
+ // where is an HTTP error code.
+ // For example, "error-page-503.http" defines an error page for HTTP 503 responses.
+ // Currently only error pages for 503 and 404 responses can be customized.
+ // Each value in the configmap should be the full response, including HTTP headers.
+ // Eg- https://raw.githubusercontent.com/openshift/router/fadab45747a9b30cc3f0a4b41ad2871f95827a93/images/router/haproxy/conf/error-page-503.http
+ // If this field is empty, the ingress controller uses the default error pages.
+ HttpErrorCodePages configv1.ConfigMapNameReference `json:"httpErrorCodePages,omitempty"`
+
+ // replicas is the desired number of ingress controller replicas. If unset,
+ // the default depends on the value of the defaultPlacement field in the
+ // cluster config.openshift.io/v1/ingresses status.
+ //
+ // The value of replicas is set based on the value of a chosen field in the
+ // Infrastructure CR. If defaultPlacement is set to ControlPlane, the
+ // chosen field will be controlPlaneTopology. If it is set to Workers the
+ // chosen field will be infrastructureTopology. Replicas will then be set to 1
+ // or 2 based whether the chosen field's value is SingleReplica or
+ // HighlyAvailable, respectively.
+ //
+ // These defaults are subject to change.
+ //
+ // +optional
+ Replicas *int32 `json:"replicas,omitempty"`
+
+ // endpointPublishingStrategy is used to publish the ingress controller
+ // endpoints to other networks, enable load balancer integrations, etc.
+ //
+ // If unset, the default is based on
+ // infrastructure.config.openshift.io/cluster .status.platform:
+ //
+ // AWS: LoadBalancerService (with External scope)
+ // Azure: LoadBalancerService (with External scope)
+ // GCP: LoadBalancerService (with External scope)
+ // IBMCloud: LoadBalancerService (with External scope)
+ // AlibabaCloud: LoadBalancerService (with External scope)
+ // Libvirt: HostNetwork
+ //
+ // Any other platform types (including None) default to HostNetwork.
+ //
+ // endpointPublishingStrategy cannot be updated.
+ //
+ // +optional
+ EndpointPublishingStrategy *EndpointPublishingStrategy `json:"endpointPublishingStrategy,omitempty"`
+
+ // defaultCertificate is a reference to a secret containing the default
+ // certificate served by the ingress controller. When Routes don't specify
+ // their own certificate, defaultCertificate is used.
+ //
+ // The secret must contain the following keys and data:
+ //
+ // tls.crt: certificate file contents
+ // tls.key: key file contents
+ //
+ // If unset, a wildcard certificate is automatically generated and used. The
+ // certificate is valid for the ingress controller domain (and subdomains) and
+ // the generated certificate's CA will be automatically integrated with the
+ // cluster's trust store.
+ //
+ // If a wildcard certificate is used and shared by multiple
+ // HTTP/2 enabled routes (which implies ALPN) then clients
+ // (i.e., notably browsers) are at liberty to reuse open
+ // connections. This means a client can reuse a connection to
+ // another route and that is likely to fail. This behaviour is
+ // generally known as connection coalescing.
+ //
+ // The in-use certificate (whether generated or user-specified) will be
+ // automatically integrated with OpenShift's built-in OAuth server.
+ //
+ // +optional
+ DefaultCertificate *corev1.LocalObjectReference `json:"defaultCertificate,omitempty"`
+
+ // namespaceSelector is used to filter the set of namespaces serviced by the
+ // ingress controller. This is useful for implementing shards.
+ //
+ // If unset, the default is no filtering.
+ //
+ // +optional
+ NamespaceSelector *metav1.LabelSelector `json:"namespaceSelector,omitempty"`
+
+ // routeSelector is used to filter the set of Routes serviced by the ingress
+ // controller. This is useful for implementing shards.
+ //
+ // If unset, the default is no filtering.
+ //
+ // +optional
+ RouteSelector *metav1.LabelSelector `json:"routeSelector,omitempty"`
+
+ // nodePlacement enables explicit control over the scheduling of the ingress
+ // controller.
+ //
+ // If unset, defaults are used. See NodePlacement for more details.
+ //
+ // +optional
+ NodePlacement *NodePlacement `json:"nodePlacement,omitempty"`
+
+ // tlsSecurityProfile specifies settings for TLS connections for ingresscontrollers.
+ //
+ // If unset, the default is based on the apiservers.config.openshift.io/cluster resource.
+ //
+ // Note that when using the Old, Intermediate, and Modern profile types, the effective
+ // profile configuration is subject to change between releases. For example, given
+ // a specification to use the Intermediate profile deployed on release X.Y.Z, an upgrade
+ // to release X.Y.Z+1 may cause a new profile configuration to be applied to the ingress
+ // controller, resulting in a rollout.
+ //
+ // +optional
+ TLSSecurityProfile *configv1.TLSSecurityProfile `json:"tlsSecurityProfile,omitempty"`
+
+ // clientTLS specifies settings for requesting and verifying client
+ // certificates, which can be used to enable mutual TLS for
+ // edge-terminated and reencrypt routes.
+ //
+ // +optional
+ ClientTLS ClientTLS `json:"clientTLS"`
+
+ // routeAdmission defines a policy for handling new route claims (for example,
+ // to allow or deny claims across namespaces).
+ //
+ // If empty, defaults will be applied. See specific routeAdmission fields
+ // for details about their defaults.
+ //
+ // +optional
+ RouteAdmission *RouteAdmissionPolicy `json:"routeAdmission,omitempty"`
+
+ // logging defines parameters for what should be logged where. If this
+ // field is empty, operational logs are enabled but access logs are
+ // disabled.
+ //
+ // +optional
+ Logging *IngressControllerLogging `json:"logging,omitempty"`
+
+ // httpHeaders defines policy for HTTP headers.
+ //
+ // If this field is empty, the default values are used.
+ //
+ // +optional
+ HTTPHeaders *IngressControllerHTTPHeaders `json:"httpHeaders,omitempty"`
+
+ // httpEmptyRequestsPolicy describes how HTTP connections should be
+ // handled if the connection times out before a request is received.
+ // Allowed values for this field are "Respond" and "Ignore". If the
+ // field is set to "Respond", the ingress controller sends an HTTP 400
+ // or 408 response, logs the connection (if access logging is enabled),
+ // and counts the connection in the appropriate metrics. If the field
+ // is set to "Ignore", the ingress controller closes the connection
+ // without sending a response, logging the connection, or incrementing
+ // metrics. The default value is "Respond".
+ //
+ // Typically, these connections come from load balancers' health probes
+ // or Web browsers' speculative connections ("preconnect") and can be
+ // safely ignored. However, these requests may also be caused by
+ // network errors, and so setting this field to "Ignore" may impede
+ // detection and diagnosis of problems. In addition, these requests may
+ // be caused by port scans, in which case logging empty requests may aid
+ // in detecting intrusion attempts.
+ //
+ // +optional
+ // +kubebuilder:default:="Respond"
+ HTTPEmptyRequestsPolicy HTTPEmptyRequestsPolicy `json:"httpEmptyRequestsPolicy,omitempty"`
+
+ // tuningOptions defines parameters for adjusting the performance of
+ // ingress controller pods. All fields are optional and will use their
+ // respective defaults if not set. See specific tuningOptions fields for
+ // more details.
+ //
+ // Setting fields within tuningOptions is generally not recommended. The
+ // default values are suitable for most configurations.
+ //
+ // +optional
+ TuningOptions IngressControllerTuningOptions `json:"tuningOptions,omitempty"`
+
+ // unsupportedConfigOverrides allows specifying unsupported
+ // configuration options. Its use is unsupported.
+ //
+ // +optional
+ // +nullable
+ // +kubebuilder:pruning:PreserveUnknownFields
+ UnsupportedConfigOverrides runtime.RawExtension `json:"unsupportedConfigOverrides"`
+
+ // httpCompression defines a policy for HTTP traffic compression.
+ // By default, there is no HTTP compression.
+ //
+ // +optional
+ HTTPCompression HTTPCompressionPolicy `json:"httpCompression,omitempty"`
+
+ // idleConnectionTerminationPolicy maps directly to HAProxy's
+ // idle-close-on-response option and controls whether HAProxy
+ // keeps idle frontend connections open during a soft stop
+ // (router reload).
+ //
+ // Allowed values for this field are "Immediate" and
+ // "Deferred". The default value is "Immediate".
+ //
+ // When set to "Immediate", idle connections are closed
+ // immediately during router reloads. This ensures immediate
+ // propagation of route changes but may impact clients
+ // sensitive to connection resets.
+ //
+ // When set to "Deferred", HAProxy will maintain idle
+ // connections during a soft reload instead of closing them
+ // immediately. These connections remain open until any of the
+ // following occurs:
+ //
+ // - A new request is received on the connection, in which
+ // case HAProxy handles it in the old process and closes
+ // the connection after sending the response.
+ //
+ // - HAProxy's `timeout http-keep-alive` duration expires.
+ // By default this is 300 seconds, but it can be changed
+ // using httpKeepAliveTimeout tuning option.
+ //
+ // - The client's keep-alive timeout expires, causing the
+ // client to close the connection.
+ //
+ // Setting Deferred can help prevent errors in clients or load
+ // balancers that do not properly handle connection resets.
+ // Additionally, this option allows you to retain the pre-2.4
+ // HAProxy behaviour: in HAProxy version 2.2 (OpenShift
+ // versions < 4.14), maintaining idle connections during a
+ // soft reload was the default behaviour, but starting with
+ // HAProxy 2.4, the default changed to closing idle
+ // connections immediately.
+ //
+ // Important Consideration:
+ //
+ // - Using Deferred will result in temporary inconsistencies
+ // for the first request on each persistent connection
+ // after a route update and router reload. This request
+ // will be processed by the old HAProxy process using its
+ // old configuration. Subsequent requests will use the
+ // updated configuration.
+ //
+ // Operational Considerations:
+ //
+ // - Keeping idle connections open during reloads may lead
+ // to an accumulation of old HAProxy processes if
+ // connections remain idle for extended periods,
+ // especially in environments where frequent reloads
+ // occur.
+ //
+ // - Consider monitoring the number of HAProxy processes in
+ // the router pods when Deferred is set.
+ //
+ // - You may need to enable or adjust the
+ // `ingress.operator.openshift.io/hard-stop-after`
+ // duration (configured via an annotation on the
+ // IngressController resource) in environments with
+ // frequent reloads to prevent resource exhaustion.
+ //
+ // +optional
+ // +kubebuilder:default:="Immediate"
+ // +default="Immediate"
+ IdleConnectionTerminationPolicy IngressControllerConnectionTerminationPolicy `json:"idleConnectionTerminationPolicy,omitempty"`
+
+ // closedClientConnectionPolicy controls how the IngressController
+ // behaves when the client closes the TCP connection while the TLS
+ // handshake or HTTP request is in progress. This option maps directly
+ // to HAProxy’s "abortonclose" option.
+ //
+ // Valid values are: "Abort" and "Continue".
+ // The default value is "Continue".
+ //
+ // When set to "Abort", the router will stop processing the TLS handshake
+ // if it is in progress, and it will not send an HTTP request to the backend server
+ // if the request has not yet been sent when the client closes the connection.
+ //
+ // When set to "Continue", the router will complete the TLS handshake
+ // if it is in progress, or send an HTTP request to the backend server
+ // and wait for the backend server's response, regardless of
+ // whether the client has closed the connection.
+ //
+ // Setting "Abort" can help free CPU resources otherwise spent on TLS computation
+ // for connections the client has already closed, and can reduce request queue
+ // size, thereby reducing the load on saturated backend servers.
+ //
+ // Important Considerations:
+ //
+ // - The default policy ("Continue") is HTTP-compliant, and requests
+ // for aborted client connections will still be served.
+ // Use the "Continue" policy to allow a client to send a request
+ // and then immediately close its side of the connection while
+ // still receiving a response on the half-closed connection.
+ //
+ // - When clients use keep-alive connections, the most common case for premature
+ // closure is when the user wants to cancel the transfer or when a timeout
+ // occurs. In that case, the "Abort" policy may be used to reduce resource consumption.
+ //
+ // - Using RSA keys larger than 2048 bits can significantly slow down
+ // TLS computations. Consider using the "Abort" policy to reduce CPU usage.
+ //
+ // +optional
+ // +kubebuilder:default:="Continue"
+ // +default="Continue"
+ ClosedClientConnectionPolicy IngressControllerClosedClientConnectionPolicy `json:"closedClientConnectionPolicy,omitempty"`
+
+ // haproxyVersion specifies the HAProxy version to use for this
+ // IngressController.
+ //
+ // OpenShift 5.0 introduces HAProxy 3.2 as its default version and supports
+ // HAProxy 2.8 from OpenShift 4.22 for migration purposes. When an OpenShift
+ // release introduces a new default HAProxy version, that HAProxy version
+ // becomes available as a pinnable value in subsequent OpenShift releases,
+ // providing a smooth migration path for administrators who want to defer
+ // HAProxy upgrades.
+ //
+ // Valid values for OpenShift 5.0:
+ // - Unset (default): Uses HAProxy 3.2 (the default for OpenShift 5.0)
+ // - "3.2": Explicitly pins HAProxy 3.2 for preservation during cluster
+ // upgrades to future OpenShift releases
+ // - "2.8": Uses HAProxy 2.8 from OpenShift 4.22 (migration support, will
+ // be dropped in the next OpenShift release)
+ //
+ // If a specific HAProxy version is set and would become unsupported in a
+ // target cluster upgrade, a preflight check will block the cluster upgrade
+ // until this field is updated to unset or a supported version.
+ //
+ // +optional
+ // +openshift:enable:FeatureGate=IngressControllerMultipleHAProxyVersions
+ HAProxyVersion HAProxyVersion `json:"haproxyVersion,omitempty"`
+}
+
+// httpCompressionPolicy turns on compression for the specified MIME types.
+//
+// This field is optional, and its absence implies that compression should not be enabled
+// globally in HAProxy.
+//
+// If httpCompressionPolicy exists, compression should be enabled only for the specified
+// MIME types.
+type HTTPCompressionPolicy struct {
+ // mimeTypes is a list of MIME types that should have compression applied.
+ // This list can be empty, in which case the ingress controller does not apply compression.
+ //
+ // Note: Not all MIME types benefit from compression, but HAProxy will still use resources
+ // to try to compress if instructed to. Generally speaking, text (html, css, js, etc.)
+ // formats benefit from compression, but formats that are already compressed (image,
+ // audio, video, etc.) benefit little in exchange for the time and cpu spent on compressing
+ // again. See https://joehonton.medium.com/the-gzip-penalty-d31bd697f1a2
+ //
+ // +listType=set
+ MimeTypes []CompressionMIMEType `json:"mimeTypes,omitempty"`
+}
+
+// CompressionMIMEType defines the format of a single MIME type.
+// E.g. "text/css; charset=utf-8", "text/html", "text/*", "image/svg+xml",
+// "application/octet-stream", "X-custom/customsub", etc.
+//
+// The format should follow the Content-Type definition in RFC 1341:
+// Content-Type := type "/" subtype *[";" parameter]
+// - The type in Content-Type can be one of:
+// application, audio, image, message, multipart, text, video, or a custom
+// type preceded by "X-" and followed by a token as defined below.
+// - The token is a string of at least one character, and not containing white
+// space, control characters, or any of the characters in the tspecials set.
+// - The tspecials set contains the characters ()<>@,;:\"/[]?.=
+// - The subtype in Content-Type is also a token.
+// - The optional parameter/s following the subtype are defined as:
+// token "=" (token / quoted-string)
+// - The quoted-string, as defined in RFC 822, is surrounded by double quotes
+// and can contain white space plus any character EXCEPT \, ", and CR.
+// It can also contain any single ASCII character as long as it is escaped by \.
+//
+// +kubebuilder:validation:Pattern=`^(?i)(x-[^][ ()\\<>@,;:"/?.=\x00-\x1F\x7F]+|application|audio|image|message|multipart|text|video)/[^][ ()\\<>@,;:"/?.=\x00-\x1F\x7F]+(; *[^][ ()\\<>@,;:"/?.=\x00-\x1F\x7F]+=([^][ ()\\<>@,;:"/?.=\x00-\x1F\x7F]+|"(\\[\x00-\x7F]|[^\x0D"\\])*"))*$`
+type CompressionMIMEType string
+
+// NodePlacement describes node scheduling configuration for an ingress
+// controller.
+type NodePlacement struct {
+ // nodeSelector is the node selector applied to ingress controller
+ // deployments.
+ //
+ // If set, the specified selector is used and replaces the default.
+ //
+ // If unset, the default depends on the value of the defaultPlacement
+ // field in the cluster config.openshift.io/v1/ingresses status.
+ //
+ // When defaultPlacement is Workers, the default is:
+ //
+ // kubernetes.io/os: linux
+ // node-role.kubernetes.io/worker: ''
+ //
+ // When defaultPlacement is ControlPlane, the default is:
+ //
+ // kubernetes.io/os: linux
+ // node-role.kubernetes.io/master: ''
+ //
+ // These defaults are subject to change.
+ //
+ // Note that using nodeSelector.matchExpressions is not supported. Only
+ // nodeSelector.matchLabels may be used. This is a limitation of the
+ // Kubernetes API: the pod spec does not allow complex expressions for
+ // node selectors.
+ //
+ // +optional
+ NodeSelector *metav1.LabelSelector `json:"nodeSelector,omitempty"`
+
+ // tolerations is a list of tolerations applied to ingress controller
+ // deployments.
+ //
+ // The default is an empty list.
+ //
+ // See https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/
+ //
+ // +optional
+ // +listType=atomic
+ Tolerations []corev1.Toleration `json:"tolerations,omitempty"`
+}
+
+// EndpointPublishingStrategyType is a way to publish ingress controller endpoints.
+// +kubebuilder:validation:Enum=LoadBalancerService;HostNetwork;Private;NodePortService
+type EndpointPublishingStrategyType string
+
+const (
+ // LoadBalancerService publishes the ingress controller using a Kubernetes
+ // LoadBalancer Service.
+ LoadBalancerServiceStrategyType EndpointPublishingStrategyType = "LoadBalancerService"
+
+ // HostNetwork publishes the ingress controller on node ports where the
+ // ingress controller is deployed.
+ HostNetworkStrategyType EndpointPublishingStrategyType = "HostNetwork"
+
+ // Private does not publish the ingress controller.
+ PrivateStrategyType EndpointPublishingStrategyType = "Private"
+
+ // NodePortService publishes the ingress controller using a Kubernetes NodePort Service.
+ NodePortServiceStrategyType EndpointPublishingStrategyType = "NodePortService"
+)
+
+// LoadBalancerScope is the scope at which a load balancer is exposed.
+// +kubebuilder:validation:Enum=Internal;External
+type LoadBalancerScope string
+
+var (
+ // InternalLoadBalancer is a load balancer that is exposed only on the
+ // cluster's private network.
+ InternalLoadBalancer LoadBalancerScope = "Internal"
+
+ // ExternalLoadBalancer is a load balancer that is exposed on the
+ // cluster's public network (which is typically on the Internet).
+ ExternalLoadBalancer LoadBalancerScope = "External"
+)
+
+// CIDR is an IP address range in CIDR notation (for example, "10.0.0.0/8"
+// or "fd00::/8").
+// +kubebuilder:validation:Pattern=`(^(([0-9]|[0-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[0-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])/([0-9]|[12][0-9]|3[0-2])$)|(^s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]d|1dd|[1-9]?d)(.(25[0-5]|2[0-4]d|1dd|[1-9]?d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]d|1dd|[1-9]?d)(.(25[0-5]|2[0-4]d|1dd|[1-9]?d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]d|1dd|[1-9]?d)(.(25[0-5]|2[0-4]d|1dd|[1-9]?d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]d|1dd|[1-9]?d)(.(25[0-5]|2[0-4]d|1dd|[1-9]?d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]d|1dd|[1-9]?d)(.(25[0-5]|2[0-4]d|1dd|[1-9]?d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]d|1dd|[1-9]?d)(.(25[0-5]|2[0-4]d|1dd|[1-9]?d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]d|1dd|[1-9]?d)(.(25[0-5]|2[0-4]d|1dd|[1-9]?d)){3}))|:)))(%.+)?s*(\/(12[0-8]|1[0-1][0-9]|[1-9][0-9]|[0-9]))$)`
+// + ---
+// + The regex for the IPv4 CIDR range was taken from other CIDR fields in the OpenShift API
+// + and the one for the IPv6 CIDR range was taken from
+// + https://blog.markhatton.co.uk/2011/03/15/regular-expressions-for-ip-addresses-cidr-ranges-and-hostnames/
+// + The resulting regex is an OR of both regexes.
+type CIDR string
+
+// LoadBalancerStrategy holds parameters for a load balancer.
+// +kubebuilder:validation:XValidation:rule="!has(self.scope) || self.scope != 'Internal' || !has(self.providerParameters) || !has(self.providerParameters.aws) || !has(self.providerParameters.aws.networkLoadBalancer) || !has(self.providerParameters.aws.networkLoadBalancer.eipAllocations)",message="eipAllocations are forbidden when the scope is Internal."
+// +kubebuilder:validation:XValidation:rule=`!has(self.scope) || self.scope != 'Internal' || !has(self.providerParameters) || !has(self.providerParameters.openstack) || !has(self.providerParameters.openstack.floatingIP) || self.providerParameters.openstack.floatingIP == ""`,message="cannot specify a floating ip when scope is internal"
+type LoadBalancerStrategy struct {
+ // scope indicates the scope at which the load balancer is exposed.
+ // Possible values are "External" and "Internal".
+ //
+ // +required
+ Scope LoadBalancerScope `json:"scope"`
+
+ // allowedSourceRanges specifies an allowlist of IP address ranges to which
+ // access to the load balancer should be restricted. Each range must be
+ // specified using CIDR notation (e.g. "10.0.0.0/8" or "fd00::/8"). If no range is
+ // specified, "0.0.0.0/0" for IPv4 and "::/0" for IPv6 are used by default,
+ // which allows all source addresses.
+ //
+ // To facilitate migration from earlier versions of OpenShift that did
+ // not have the allowedSourceRanges field, you may set the
+ // service.beta.kubernetes.io/load-balancer-source-ranges annotation on
+ // the "router-" service in the
+ // "openshift-ingress" namespace, and this annotation will take
+ // effect if allowedSourceRanges is empty on OpenShift 4.12.
+ //
+ // +nullable
+ // +optional
+ // +listType=atomic
+ AllowedSourceRanges []CIDR `json:"allowedSourceRanges,omitempty"`
+
+ // providerParameters holds desired load balancer information specific to
+ // the underlying infrastructure provider.
+ //
+ // If empty, defaults will be applied. See specific providerParameters
+ // fields for details about their defaults.
+ //
+ // +optional
+ ProviderParameters *ProviderLoadBalancerParameters `json:"providerParameters,omitempty"`
+
+ // dnsManagementPolicy indicates if the lifecycle of the wildcard DNS record
+ // associated with the load balancer service will be managed by
+ // the ingress operator. It defaults to Managed.
+ // Valid values are: Managed and Unmanaged.
+ //
+ // +kubebuilder:default:="Managed"
+ // +required
+ // +default="Managed"
+ DNSManagementPolicy LoadBalancerDNSManagementPolicy `json:"dnsManagementPolicy,omitempty"`
+}
+
+// LoadBalancerDNSManagementPolicy is a policy for configuring how
+// ingresscontrollers manage DNS.
+//
+// +kubebuilder:validation:Enum=Managed;Unmanaged
+type LoadBalancerDNSManagementPolicy string
+
+const (
+ // ManagedLoadBalancerDNS specifies that the operator manages
+ // a wildcard DNS record for the ingresscontroller.
+ ManagedLoadBalancerDNS LoadBalancerDNSManagementPolicy = "Managed"
+ // UnmanagedLoadBalancerDNS specifies that the operator does not manage
+ // any wildcard DNS record for the ingresscontroller.
+ UnmanagedLoadBalancerDNS LoadBalancerDNSManagementPolicy = "Unmanaged"
+)
+
+// ProviderLoadBalancerParameters holds desired load balancer information
+// specific to the underlying infrastructure provider.
+// +kubebuilder:validation:XValidation:rule="has(self.type) && self.type == 'OpenStack' ? true : !has(self.openstack)",message="openstack is not permitted when type is not OpenStack"
+// +union
+type ProviderLoadBalancerParameters struct {
+ // type is the underlying infrastructure provider for the load balancer.
+ // Allowed values are "AWS", "Azure", "BareMetal", "GCP", "IBM", "Nutanix",
+ // "OpenStack", and "VSphere".
+ //
+ // +unionDiscriminator
+ // +required
+ Type LoadBalancerProviderType `json:"type"`
+
+ // aws provides configuration settings that are specific to AWS
+ // load balancers.
+ //
+ // If empty, defaults will be applied. See specific aws fields for
+ // details about their defaults.
+ //
+ // +optional
+ AWS *AWSLoadBalancerParameters `json:"aws,omitempty"`
+
+ // gcp provides configuration settings that are specific to GCP
+ // load balancers.
+ //
+ // If empty, defaults will be applied. See specific gcp fields for
+ // details about their defaults.
+ //
+ // +optional
+ GCP *GCPLoadBalancerParameters `json:"gcp,omitempty"`
+
+ // ibm provides configuration settings that are specific to IBM Cloud
+ // load balancers.
+ //
+ // If empty, defaults will be applied. See specific ibm fields for
+ // details about their defaults.
+ //
+ // +optional
+ IBM *IBMLoadBalancerParameters `json:"ibm,omitempty"`
+
+ // openstack provides configuration settings that are specific to OpenStack
+ // load balancers.
+ //
+ // If empty, defaults will be applied. See specific openstack fields for
+ // details about their defaults.
+ //
+ // +optional
+ OpenStack *OpenStackLoadBalancerParameters `json:"openstack,omitempty"`
+}
+
+// LoadBalancerProviderType is the underlying infrastructure provider for the
+// load balancer. Allowed values are "AWS", "Azure", "BareMetal", "GCP", "IBM", "Nutanix",
+// "OpenStack", and "VSphere".
+//
+// +kubebuilder:validation:Enum=AWS;Azure;BareMetal;GCP;Nutanix;OpenStack;VSphere;IBM
+type LoadBalancerProviderType string
+
+const (
+ AWSLoadBalancerProvider LoadBalancerProviderType = "AWS"
+ AzureLoadBalancerProvider LoadBalancerProviderType = "Azure"
+ GCPLoadBalancerProvider LoadBalancerProviderType = "GCP"
+ OpenStackLoadBalancerProvider LoadBalancerProviderType = "OpenStack"
+ VSphereLoadBalancerProvider LoadBalancerProviderType = "VSphere"
+ IBMLoadBalancerProvider LoadBalancerProviderType = "IBM"
+ BareMetalLoadBalancerProvider LoadBalancerProviderType = "BareMetal"
+ AlibabaCloudLoadBalancerProvider LoadBalancerProviderType = "AlibabaCloud"
+ NutanixLoadBalancerProvider LoadBalancerProviderType = "Nutanix"
+)
+
+// AWSLoadBalancerParameters provides configuration settings that are
+// specific to AWS load balancers.
+// +union
+type AWSLoadBalancerParameters struct {
+ // type is the type of AWS load balancer to instantiate for an ingresscontroller.
+ //
+ // Valid values are:
+ //
+ // * "Classic": A Classic Load Balancer that makes routing decisions at either
+ // the transport layer (TCP/SSL) or the application layer (HTTP/HTTPS). See
+ // the following for additional details:
+ //
+ // https://docs.aws.amazon.com/AmazonECS/latest/developerguide/load-balancer-types.html#clb
+ //
+ // * "NLB": A Network Load Balancer that makes routing decisions at the
+ // transport layer (TCP/SSL). See the following for additional details:
+ //
+ // https://docs.aws.amazon.com/AmazonECS/latest/developerguide/load-balancer-types.html#nlb
+ //
+ // +unionDiscriminator
+ // +required
+ Type AWSLoadBalancerType `json:"type"`
+
+ // classicLoadBalancerParameters holds configuration parameters for an AWS
+ // classic load balancer. Present only if type is Classic.
+ //
+ // +optional
+ ClassicLoadBalancerParameters *AWSClassicLoadBalancerParameters `json:"classicLoadBalancer,omitempty"`
+
+ // networkLoadBalancerParameters holds configuration parameters for an AWS
+ // network load balancer. Present only if type is NLB.
+ //
+ // +optional
+ NetworkLoadBalancerParameters *AWSNetworkLoadBalancerParameters `json:"networkLoadBalancer,omitempty"`
+}
+
+// AWSLoadBalancerType is the type of AWS load balancer to instantiate.
+// +kubebuilder:validation:Enum=Classic;NLB
+type AWSLoadBalancerType string
+
+const (
+ AWSClassicLoadBalancer AWSLoadBalancerType = "Classic"
+ AWSNetworkLoadBalancer AWSLoadBalancerType = "NLB"
+)
+
+// AWSSubnets contains a list of references to AWS subnets by
+// ID or name.
+// +kubebuilder:validation:XValidation:rule=`has(self.ids) && has(self.names) ? size(self.ids + self.names) <= 10 : true`,message="the total number of subnets cannot exceed 10"
+// +kubebuilder:validation:XValidation:rule=`has(self.ids) && self.ids.size() > 0 || has(self.names) && self.names.size() > 0`,message="must specify at least 1 subnet name or id"
+type AWSSubnets struct {
+ // ids specifies a list of AWS subnets by subnet ID.
+ // Subnet IDs must start with "subnet-", consist only
+ // of alphanumeric characters, must be exactly 24
+ // characters long, must be unique, and the total
+ // number of subnets specified by ids and names
+ // must not exceed 10.
+ //
+ // +optional
+ // +listType=atomic
+ // +kubebuilder:validation:XValidation:rule=`self.all(x, self.exists_one(y, x == y))`,message="subnet ids cannot contain duplicates"
+ // + Note: Though it may seem redundant, MaxItems is necessary to prevent exceeding of the cost budget for the validation rules.
+ // +kubebuilder:validation:MaxItems=10
+ IDs []AWSSubnetID `json:"ids,omitempty"`
+
+ // names specifies a list of AWS subnets by subnet name.
+ // Subnet names must not start with "subnet-", must not
+ // include commas, must be under 256 characters in length,
+ // must be unique, and the total number of subnets
+ // specified by ids and names must not exceed 10.
+ //
+ // +optional
+ // +listType=atomic
+ // +kubebuilder:validation:XValidation:rule=`self.all(x, self.exists_one(y, x == y))`,message="subnet names cannot contain duplicates"
+ // + Note: Though it may seem redundant, MaxItems is necessary to prevent exceeding of the cost budget for the validation rules.
+ // +kubebuilder:validation:MaxItems=10
+ Names []AWSSubnetName `json:"names,omitempty"`
+}
+
+// AWSSubnetID is a reference to an AWS subnet ID.
+// +kubebuilder:validation:MinLength=24
+// +kubebuilder:validation:MaxLength=24
+// +kubebuilder:validation:Pattern=`^subnet-[0-9A-Za-z]+$`
+type AWSSubnetID string
+
+// AWSSubnetName is a reference to an AWS subnet name.
+// +kubebuilder:validation:MinLength=1
+// +kubebuilder:validation:MaxLength=256
+// +kubebuilder:validation:XValidation:rule=`!self.contains(',')`,message="subnet name cannot contain a comma"
+// +kubebuilder:validation:XValidation:rule=`!self.startsWith('subnet-')`,message="subnet name cannot start with 'subnet-'"
+type AWSSubnetName string
+
+// GCPLoadBalancerParameters provides configuration settings that are
+// specific to GCP load balancers.
+type GCPLoadBalancerParameters struct {
+ // clientAccess describes how client access is restricted for internal
+ // load balancers.
+ //
+ // Valid values are:
+ // * "Global": Specifying an internal load balancer with Global client access
+ // allows clients from any region within the VPC to communicate with the load
+ // balancer.
+ //
+ // https://cloud.google.com/kubernetes-engine/docs/how-to/internal-load-balancing#global_access
+ //
+ // * "Local": Specifying an internal load balancer with Local client access
+ // means only clients within the same region (and VPC) as the GCP load balancer
+ // can communicate with the load balancer. Note that this is the default behavior.
+ //
+ // https://cloud.google.com/load-balancing/docs/internal#client_access
+ //
+ // +optional
+ ClientAccess GCPClientAccess `json:"clientAccess,omitempty"`
+}
+
+// GCPClientAccess describes how client access is restricted for internal
+// load balancers.
+// +kubebuilder:validation:Enum=Global;Local
+type GCPClientAccess string
+
+const (
+ GCPGlobalAccess GCPClientAccess = "Global"
+ GCPLocalAccess GCPClientAccess = "Local"
+)
+
+// IBMLoadBalancerParameters provides configuration settings that are
+// specific to IBM Cloud load balancers.
+type IBMLoadBalancerParameters struct {
+ // protocol specifies whether the load balancer uses PROXY protocol to forward connections to
+ // the IngressController. See "service.kubernetes.io/ibm-load-balancer-cloud-provider-enable-features:
+ // "proxy-protocol"" at https://cloud.ibm.com/docs/containers?topic=containers-vpc-lbaas"
+ //
+ // PROXY protocol can be used with load balancers that support it to
+ // communicate the source addresses of client connections when
+ // forwarding those connections to the IngressController. Using PROXY
+ // protocol enables the IngressController to report those source
+ // addresses instead of reporting the load balancer's address in HTTP
+ // headers and logs. Note that enabling PROXY protocol on the
+ // IngressController will cause connections to fail if you are not using
+ // a load balancer that uses PROXY protocol to forward connections to
+ // the IngressController. See
+ // http://www.haproxy.org/download/2.2/doc/proxy-protocol.txt for
+ // information about PROXY protocol.
+ //
+ // Valid values for protocol are TCP, PROXY and omitted.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The current default is TCP, without the proxy protocol enabled.
+ //
+ // +optional
+ Protocol IngressControllerProtocol `json:"protocol,omitempty"`
+}
+
+// OpenStackLoadBalancerParameters provides configuration settings that are
+// specific to OpenStack load balancers.
+type OpenStackLoadBalancerParameters struct {
+ // loadBalancerIP is tombstoned since the field was replaced by floatingIP.
+ // LoadBalancerIP string `json:"loadBalancerIP,omitempty"`
+
+ // floatingIP specifies the IP address that the load balancer will use.
+ // When not specified, an IP address will be assigned randomly by the OpenStack cloud provider.
+ // When specified, the floating IP has to be pre-created. If the
+ // specified value is not a floating IP or is already claimed, the
+ // OpenStack cloud provider won't be able to provision the load
+ // balancer.
+ // This field may only be used if the IngressController has External scope.
+ // This value must be a valid IPv4 or IPv6 address.
+ // + ---
+ // + Note: this field is meant to be set by the ingress controller
+ // + to populate the `Service.Spec.LoadBalancerIP` field which has been
+ // + deprecated in Kubernetes:
+ // + https://github.com/kubernetes/kubernetes/pull/107235
+ // + However, the field is still used by cloud-provider-openstack to reconcile
+ // + the floating IP that we attach to the external load balancer.
+ //
+ // +kubebuilder:validation:XValidation:rule="isIP(self)",message="floatingIP must be a valid IPv4 or IPv6 address"
+ // +optional
+ FloatingIP string `json:"floatingIP,omitempty"`
+}
+
+// AWSClassicLoadBalancerParameters holds configuration parameters for an
+// AWS Classic load balancer.
+type AWSClassicLoadBalancerParameters struct {
+ // connectionIdleTimeout specifies the maximum time period that a
+ // connection may be idle before the load balancer closes the
+ // connection. The value must be parseable as a time duration value;
+ // see . A nil or zero value
+ // means no opinion, in which case a default value is used. The default
+ // value for this field is 60s. This default is subject to change.
+ //
+ // +kubebuilder:validation:Format=duration
+ // +optional
+ ConnectionIdleTimeout metav1.Duration `json:"connectionIdleTimeout,omitempty"`
+
+ // subnets specifies the subnets to which the load balancer will
+ // attach. The subnets may be specified by either their
+ // ID or name. The total number of subnets is limited to 10.
+ //
+ // In order for the load balancer to be provisioned with subnets,
+ // each subnet must exist, each subnet must be from a different
+ // availability zone, and the load balancer service must be
+ // recreated to pick up new values.
+ //
+ // When omitted from the spec, the subnets will be auto-discovered
+ // for each availability zone. Auto-discovered subnets are not reported
+ // in the status of the IngressController object.
+ //
+ // +optional
+ Subnets *AWSSubnets `json:"subnets,omitempty"`
+}
+
+// AWSNetworkLoadBalancerParameters holds configuration parameters for an
+// AWS Network load balancer. For Example: Setting AWS EIPs https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/elastic-ip-addresses-eip.html
+// +kubebuilder:validation:XValidation:rule=`has(self.subnets) && has(self.subnets.ids) && has(self.subnets.names) && has(self.eipAllocations) ? size(self.subnets.ids + self.subnets.names) == size(self.eipAllocations) : true`,message="number of subnets must be equal to number of eipAllocations"
+// +kubebuilder:validation:XValidation:rule=`has(self.subnets) && has(self.subnets.ids) && !has(self.subnets.names) && has(self.eipAllocations) ? size(self.subnets.ids) == size(self.eipAllocations) : true`,message="number of subnets must be equal to number of eipAllocations"
+// +kubebuilder:validation:XValidation:rule=`has(self.subnets) && has(self.subnets.names) && !has(self.subnets.ids) && has(self.eipAllocations) ? size(self.subnets.names) == size(self.eipAllocations) : true`,message="number of subnets must be equal to number of eipAllocations"
+type AWSNetworkLoadBalancerParameters struct {
+ // subnets specifies the subnets to which the load balancer will
+ // attach. The subnets may be specified by either their
+ // ID or name. The total number of subnets is limited to 10.
+ //
+ // In order for the load balancer to be provisioned with subnets,
+ // each subnet must exist, each subnet must be from a different
+ // availability zone, and the load balancer service must be
+ // recreated to pick up new values.
+ //
+ // When omitted from the spec, the subnets will be auto-discovered
+ // for each availability zone. Auto-discovered subnets are not reported
+ // in the status of the IngressController object.
+ //
+ // +optional
+ Subnets *AWSSubnets `json:"subnets,omitempty"`
+
+ // eipAllocations is a list of IDs for Elastic IP (EIP) addresses that
+ // are assigned to the Network Load Balancer.
+ // The following restrictions apply:
+ //
+ // eipAllocations can only be used with external scope, not internal.
+ // An EIP can be allocated to only a single IngressController.
+ // The number of EIP allocations must match the number of subnets that are used for the load balancer.
+ // Each EIP allocation must be unique.
+ // A maximum of 10 EIP allocations are permitted.
+ //
+ // See https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/elastic-ip-addresses-eip.html for general
+ // information about configuration, characteristics, and limitations of Elastic IP addresses.
+ //
+ // +optional
+ // +listType=atomic
+ // +kubebuilder:validation:XValidation:rule=`self.all(x, self.exists_one(y, x == y))`,message="eipAllocations cannot contain duplicates"
+ // +kubebuilder:validation:MaxItems=10
+ EIPAllocations []EIPAllocation `json:"eipAllocations"`
+
+ // protocol specifies whether the Network Load Balancer uses PROXY
+ // protocol to forward connections to the IngressController.
+ //
+ // When set to "TCP", the NLB uses AWS's native client IP preservation.
+ // This may cause hairpin connection failures for internal load
+ // balancers when connections are made from pods to router pods on
+ // the same node.
+ //
+ // When set to "PROXY", the NLB disables native client IP preservation
+ // and uses PROXY protocol v2. The IngressController enables PROXY
+ // protocol on HAProxy so that it can parse PROXY protocol headers to
+ // obtain the original client IP. This avoids hairpin connection
+ // failures.
+ //
+ // The following values are valid for this field:
+ //
+ // * "TCP".
+ // * "PROXY".
+ //
+ // When omitted, this means the user has no opinion and the value is
+ // left to the platform to choose a reasonable default, which is subject to
+ // change over time. The current default is "PROXY".
+ //
+ // Note that changing this field may cause brief connection failures
+ // during the transition as the NLB attribute change and router rollout
+ // occur independently.
+ //
+ // +optional
+ Protocol NLBProtocol `json:"protocol,omitempty"`
+}
+
+// NLBProtocol specifies whether the AWS Network Load Balancer uses
+// PROXY protocol to forward connections to the IngressController.
+// +kubebuilder:validation:Enum=TCP;PROXY
+// +enum
+type NLBProtocol string
+
+const (
+ // NLBProtocolTCP instructs the NLB to forward connections using TCP
+ // without PROXY protocol.
+ NLBProtocolTCP NLBProtocol = "TCP"
+ // NLBProtocolProxy instructs the NLB to forward connections using
+ // PROXY protocol v2.
+ NLBProtocolProxy NLBProtocol = "PROXY"
+)
+
+// EIPAllocation is an ID for an Elastic IP (EIP) address that can be allocated to an ELB in the AWS environment.
+// Values must begin with `eipalloc-` followed by exactly 17 hexadecimal (`[0-9a-fA-F]`) characters.
+// + Explanation of the regex `^eipalloc-[0-9a-fA-F]{17}$` for validating value of the EIPAllocation:
+// + ^eipalloc- ensures the string starts with "eipalloc-".
+// + [0-9a-fA-F]{17} matches exactly 17 hexadecimal characters (0-9, a-f, A-F).
+// + $ ensures the string ends after the 17 hexadecimal characters.
+// + Example of Valid and Invalid values:
+// + eipalloc-1234567890abcdef1 is valid.
+// + eipalloc-1234567890abcde is not valid (too short).
+// + eipalloc-1234567890abcdefg is not valid (contains a non-hex character 'g').
+// + Max length is calculated as follows:
+// + eipalloc- = 9 chars and 17 hexadecimal chars after `-`
+// + So, total is 17 + 9 = 26 chars required for value of an EIPAllocation.
+//
+// +kubebuilder:validation:MinLength=26
+// +kubebuilder:validation:MaxLength=26
+// +kubebuilder:validation:XValidation:rule=`self.startsWith('eipalloc-')`,message="eipAllocations should start with 'eipalloc-'"
+// +kubebuilder:validation:XValidation:rule=`self.split("-", 2)[1].matches('[0-9a-fA-F]{17}$')`,message="eipAllocations must be 'eipalloc-' followed by exactly 17 hexadecimal characters (0-9, a-f, A-F)"
+type EIPAllocation string
+
+// HostNetworkStrategy holds parameters for the HostNetwork endpoint publishing
+// strategy.
+type HostNetworkStrategy struct {
+ // protocol specifies whether the IngressController expects incoming
+ // connections to use plain TCP or whether the IngressController expects
+ // PROXY protocol.
+ //
+ // PROXY protocol can be used with load balancers that support it to
+ // communicate the source addresses of client connections when
+ // forwarding those connections to the IngressController. Using PROXY
+ // protocol enables the IngressController to report those source
+ // addresses instead of reporting the load balancer's address in HTTP
+ // headers and logs. Note that enabling PROXY protocol on the
+ // IngressController will cause connections to fail if you are not using
+ // a load balancer that uses PROXY protocol to forward connections to
+ // the IngressController. See
+ // http://www.haproxy.org/download/2.2/doc/proxy-protocol.txt for
+ // information about PROXY protocol.
+ //
+ // The following values are valid for this field:
+ //
+ // * The empty string.
+ // * "TCP".
+ // * "PROXY".
+ //
+ // The empty string specifies the default, which is TCP without PROXY
+ // protocol. Note that the default is subject to change.
+ //
+ // +optional
+ Protocol IngressControllerProtocol `json:"protocol,omitempty"`
+
+ // httpPort is the port on the host which should be used to listen for
+ // HTTP requests. This field should be set when port 80 is already in use.
+ // The value should not coincide with the NodePort range of the cluster.
+ // When the value is 0 or is not specified it defaults to 80.
+ // +kubebuilder:validation:Maximum=65535
+ // +kubebuilder:validation:Minimum=0
+ // +kubebuilder:default=80
+ // +optional
+ HTTPPort int32 `json:"httpPort,omitempty"`
+
+ // httpsPort is the port on the host which should be used to listen for
+ // HTTPS requests. This field should be set when port 443 is already in use.
+ // The value should not coincide with the NodePort range of the cluster.
+ // When the value is 0 or is not specified it defaults to 443.
+ // +kubebuilder:validation:Maximum=65535
+ // +kubebuilder:validation:Minimum=0
+ // +kubebuilder:default=443
+ // +optional
+ HTTPSPort int32 `json:"httpsPort,omitempty"`
+
+ // statsPort is the port on the host where the stats from the router are
+ // published. The value should not coincide with the NodePort range of the
+ // cluster. If an external load balancer is configured to forward connections
+ // to this IngressController, the load balancer should use this port for
+ // health checks. The load balancer can send HTTP probes on this port on a
+ // given node, with the path /healthz/ready to determine if the ingress
+ // controller is ready to receive traffic on the node. For proper operation
+ // the load balancer must not forward traffic to a node until the health
+ // check reports ready. The load balancer should also stop forwarding requests
+ // within a maximum of 45 seconds after /healthz/ready starts reporting
+ // not-ready. Probing every 5 to 10 seconds, with a 5-second timeout and with
+ // a threshold of two successful or failed requests to become healthy or
+ // unhealthy respectively, are well-tested values. When the value is 0 or
+ // is not specified it defaults to 1936.
+ // +kubebuilder:validation:Maximum=65535
+ // +kubebuilder:validation:Minimum=0
+ // +kubebuilder:default=1936
+ // +optional
+ StatsPort int32 `json:"statsPort,omitempty"`
+}
+
+// PrivateStrategy holds parameters for the Private endpoint publishing
+// strategy.
+type PrivateStrategy struct {
+ // protocol specifies whether the IngressController expects incoming
+ // connections to use plain TCP or whether the IngressController expects
+ // PROXY protocol.
+ //
+ // PROXY protocol can be used with load balancers that support it to
+ // communicate the source addresses of client connections when
+ // forwarding those connections to the IngressController. Using PROXY
+ // protocol enables the IngressController to report those source
+ // addresses instead of reporting the load balancer's address in HTTP
+ // headers and logs. Note that enabling PROXY protocol on the
+ // IngressController will cause connections to fail if you are not using
+ // a load balancer that uses PROXY protocol to forward connections to
+ // the IngressController. See
+ // http://www.haproxy.org/download/2.2/doc/proxy-protocol.txt for
+ // information about PROXY protocol.
+ //
+ // The following values are valid for this field:
+ //
+ // * The empty string.
+ // * "TCP".
+ // * "PROXY".
+ //
+ // The empty string specifies the default, which is TCP without PROXY
+ // protocol. Note that the default is subject to change.
+ //
+ // +optional
+ Protocol IngressControllerProtocol `json:"protocol,omitempty"`
+}
+
+// NodePortStrategy holds parameters for the NodePortService endpoint publishing strategy.
+type NodePortStrategy struct {
+ // protocol specifies whether the IngressController expects incoming
+ // connections to use plain TCP or whether the IngressController expects
+ // PROXY protocol.
+ //
+ // PROXY protocol can be used with load balancers that support it to
+ // communicate the source addresses of client connections when
+ // forwarding those connections to the IngressController. Using PROXY
+ // protocol enables the IngressController to report those source
+ // addresses instead of reporting the load balancer's address in HTTP
+ // headers and logs. Note that enabling PROXY protocol on the
+ // IngressController will cause connections to fail if you are not using
+ // a load balancer that uses PROXY protocol to forward connections to
+ // the IngressController. See
+ // http://www.haproxy.org/download/2.2/doc/proxy-protocol.txt for
+ // information about PROXY protocol.
+ //
+ // The following values are valid for this field:
+ //
+ // * The empty string.
+ // * "TCP".
+ // * "PROXY".
+ //
+ // The empty string specifies the default, which is TCP without PROXY
+ // protocol. Note that the default is subject to change.
+ //
+ // +optional
+ Protocol IngressControllerProtocol `json:"protocol,omitempty"`
+}
+
+// IngressControllerProtocol specifies whether PROXY protocol is enabled or not.
+// +kubebuilder:validation:Enum="";TCP;PROXY
+type IngressControllerProtocol string
+
+const (
+ DefaultProtocol IngressControllerProtocol = ""
+ TCPProtocol IngressControllerProtocol = "TCP"
+ ProxyProtocol IngressControllerProtocol = "PROXY"
+)
+
+// EndpointPublishingStrategy is a way to publish the endpoints of an
+// IngressController, and represents the type and any additional configuration
+// for a specific type.
+// +union
+type EndpointPublishingStrategy struct {
+ // type is the publishing strategy to use. Valid values are:
+ //
+ // * LoadBalancerService
+ //
+ // Publishes the ingress controller using a Kubernetes LoadBalancer Service.
+ //
+ // In this configuration, the ingress controller deployment uses container
+ // networking. A LoadBalancer Service is created to publish the deployment.
+ //
+ // See: https://kubernetes.io/docs/concepts/services-networking/service/#loadbalancer
+ //
+ // If domain is set, a wildcard DNS record will be managed to point at the
+ // LoadBalancer Service's external name. DNS records are managed only in DNS
+ // zones defined by dns.config.openshift.io/cluster .spec.publicZone and
+ // .spec.privateZone.
+ //
+ // Wildcard DNS management is currently supported only on the AWS, Azure,
+ // and GCP platforms.
+ //
+ // * HostNetwork
+ //
+ // Publishes the ingress controller on node ports where the ingress controller
+ // is deployed.
+ //
+ // In this configuration, the ingress controller deployment uses host
+ // networking, bound to node ports 80 and 443. The user is responsible for
+ // configuring an external load balancer to publish the ingress controller via
+ // the node ports.
+ //
+ // * Private
+ //
+ // Does not publish the ingress controller.
+ //
+ // In this configuration, the ingress controller deployment uses container
+ // networking, and is not explicitly published. The user must manually publish
+ // the ingress controller.
+ //
+ // * NodePortService
+ //
+ // Publishes the ingress controller using a Kubernetes NodePort Service.
+ //
+ // In this configuration, the ingress controller deployment uses container
+ // networking. A NodePort Service is created to publish the deployment. The
+ // specific node ports are dynamically allocated by OpenShift; however, to
+ // support static port allocations, user changes to the node port
+ // field of the managed NodePort Service will preserved.
+ //
+ // +unionDiscriminator
+ // +required
+ Type EndpointPublishingStrategyType `json:"type"`
+
+ // loadBalancer holds parameters for the load balancer. Present only if
+ // type is LoadBalancerService.
+ // +optional
+ LoadBalancer *LoadBalancerStrategy `json:"loadBalancer,omitempty"`
+
+ // hostNetwork holds parameters for the HostNetwork endpoint publishing
+ // strategy. Present only if type is HostNetwork.
+ // +optional
+ HostNetwork *HostNetworkStrategy `json:"hostNetwork,omitempty"`
+
+ // private holds parameters for the Private endpoint publishing
+ // strategy. Present only if type is Private.
+ // +optional
+ Private *PrivateStrategy `json:"private,omitempty"`
+
+ // nodePort holds parameters for the NodePortService endpoint publishing strategy.
+ // Present only if type is NodePortService.
+ // +optional
+ NodePort *NodePortStrategy `json:"nodePort,omitempty"`
+}
+
+// ClientCertificatePolicy describes the policy for client certificates.
+// +kubebuilder:validation:Enum="";Required;Optional
+type ClientCertificatePolicy string
+
+const (
+ // ClientCertificatePolicyRequired indicates that a client certificate
+ // should be required.
+ ClientCertificatePolicyRequired ClientCertificatePolicy = "Required"
+
+ // ClientCertificatePolicyOptional indicates that a client certificate
+ // should be requested but not required.
+ ClientCertificatePolicyOptional ClientCertificatePolicy = "Optional"
+)
+
+// ClientTLS specifies TLS configuration to enable client-to-server
+// authentication, which can be used for mutual TLS.
+type ClientTLS struct {
+ // clientCertificatePolicy specifies whether the ingress controller
+ // requires clients to provide certificates. This field accepts the
+ // values "Required" or "Optional".
+ //
+ // Note that the ingress controller only checks client certificates for
+ // edge-terminated and reencrypt TLS routes; it cannot check
+ // certificates for cleartext HTTP or passthrough TLS routes.
+ //
+ // +required
+ ClientCertificatePolicy ClientCertificatePolicy `json:"clientCertificatePolicy"`
+
+ // clientCA specifies a configmap containing the PEM-encoded CA
+ // certificate bundle that should be used to verify a client's
+ // certificate. The administrator must create this configmap in the
+ // openshift-config namespace.
+ //
+ // +required
+ ClientCA configv1.ConfigMapNameReference `json:"clientCA"`
+
+ // allowedSubjectPatterns specifies a list of regular expressions that
+ // should be matched against the distinguished name on a valid client
+ // certificate to filter requests. The regular expressions must use
+ // PCRE syntax. If this list is empty, no filtering is performed. If
+ // the list is nonempty, then at least one pattern must match a client
+ // certificate's distinguished name or else the ingress controller
+ // rejects the certificate and denies the connection.
+ //
+ // +listType=atomic
+ // +optional
+ AllowedSubjectPatterns []string `json:"allowedSubjectPatterns,omitempty"`
+}
+
+// RouteAdmissionPolicy is an admission policy for allowing new route claims.
+type RouteAdmissionPolicy struct {
+ // namespaceOwnership describes how host name claims across namespaces should
+ // be handled.
+ //
+ // Value must be one of:
+ //
+ // - Strict: Do not allow routes in different namespaces to claim the same host.
+ //
+ // - InterNamespaceAllowed: Allow routes to claim different paths of the same
+ // host name across namespaces.
+ //
+ // If empty, the default is Strict.
+ // +optional
+ NamespaceOwnership NamespaceOwnershipCheck `json:"namespaceOwnership,omitempty"`
+ // wildcardPolicy describes how routes with wildcard policies should
+ // be handled for the ingress controller. WildcardPolicy controls use
+ // of routes [1] exposed by the ingress controller based on the route's
+ // wildcard policy.
+ //
+ // [1] https://github.com/openshift/api/blob/master/route/v1/types.go
+ //
+ // Note: Updating WildcardPolicy from WildcardsAllowed to WildcardsDisallowed
+ // will cause admitted routes with a wildcard policy of Subdomain to stop
+ // working. These routes must be updated to a wildcard policy of None to be
+ // readmitted by the ingress controller.
+ //
+ // WildcardPolicy supports WildcardsAllowed and WildcardsDisallowed values.
+ //
+ // If empty, defaults to "WildcardsDisallowed".
+ //
+ WildcardPolicy WildcardPolicy `json:"wildcardPolicy,omitempty"`
+}
+
+// WildcardPolicy is a route admission policy component that describes how
+// routes with a wildcard policy should be handled.
+// +kubebuilder:validation:Enum=WildcardsAllowed;WildcardsDisallowed
+type WildcardPolicy string
+
+const (
+ // WildcardPolicyAllowed indicates routes with any wildcard policy are
+ // admitted by the ingress controller.
+ WildcardPolicyAllowed WildcardPolicy = "WildcardsAllowed"
+
+ // WildcardPolicyDisallowed indicates only routes with a wildcard policy
+ // of None are admitted by the ingress controller.
+ WildcardPolicyDisallowed WildcardPolicy = "WildcardsDisallowed"
+)
+
+// NamespaceOwnershipCheck is a route admission policy component that describes
+// how host name claims across namespaces should be handled.
+// +kubebuilder:validation:Enum=InterNamespaceAllowed;Strict
+type NamespaceOwnershipCheck string
+
+const (
+ // InterNamespaceAllowedOwnershipCheck allows routes to claim different paths of the same host name across namespaces.
+ InterNamespaceAllowedOwnershipCheck NamespaceOwnershipCheck = "InterNamespaceAllowed"
+
+ // StrictNamespaceOwnershipCheck does not allow routes to claim the same host name across namespaces.
+ StrictNamespaceOwnershipCheck NamespaceOwnershipCheck = "Strict"
+)
+
+// LoggingDestinationType is a type of destination to which to send log
+// messages.
+//
+// +kubebuilder:validation:Enum=Container;Syslog
+type LoggingDestinationType string
+
+const (
+ // Container sends log messages to a sidecar container.
+ ContainerLoggingDestinationType LoggingDestinationType = "Container"
+
+ // Syslog sends log messages to a syslog endpoint.
+ SyslogLoggingDestinationType LoggingDestinationType = "Syslog"
+
+ // ContainerLoggingSidecarContainerName is the name of the container
+ // with the log output in an ingress controller pod when container
+ // logging is used.
+ ContainerLoggingSidecarContainerName = "logs"
+)
+
+// SyslogLoggingDestinationParameters describes parameters for the Syslog
+// logging destination type.
+type SyslogLoggingDestinationParameters struct {
+ // address is the IP address of the syslog endpoint that receives log
+ // messages.
+ //
+ // +required
+ Address string `json:"address"`
+
+ // port is the UDP port number of the syslog endpoint that receives log
+ // messages.
+ //
+ // +kubebuilder:validation:Minimum=1
+ // +kubebuilder:validation:Maximum=65535
+ // +required
+ Port uint32 `json:"port"`
+
+ // facility specifies the syslog facility of log messages.
+ //
+ // If this field is empty, the facility is "local1".
+ //
+ // +kubebuilder:validation:Enum=kern;user;mail;daemon;auth;syslog;lpr;news;uucp;cron;auth2;ftp;ntp;audit;alert;cron2;local0;local1;local2;local3;local4;local5;local6;local7
+ // +optional
+ Facility string `json:"facility,omitempty"`
+
+ // maxLength is the maximum length of the log message.
+ //
+ // Valid values are integers in the range 480 to 4096, inclusive.
+ //
+ // When omitted, the default value is 1024.
+ //
+ // +kubebuilder:validation:Maximum=4096
+ // +kubebuilder:validation:Minimum=480
+ // +kubebuilder:default=1024
+ // +default:=1024
+ // +optional
+ MaxLength uint32 `json:"maxLength,omitempty"`
+}
+
+// ContainerLoggingDestinationParameters describes parameters for the Container
+// logging destination type.
+type ContainerLoggingDestinationParameters struct {
+ // maxLength is the maximum length of the log message.
+ //
+ // Valid values are integers in the range 480 to 8192, inclusive.
+ //
+ // When omitted, the default value is 1024.
+ //
+ // +kubebuilder:validation:Maximum=8192
+ // +kubebuilder:validation:Minimum=480
+ // +kubebuilder:default=1024
+ // +default:=1024
+ // +optional
+ MaxLength int32 `json:"maxLength,omitempty"`
+}
+
+// LoggingDestination describes a destination for log messages.
+// +union
+type LoggingDestination struct {
+ // type is the type of destination for logs. It must be one of the
+ // following:
+ //
+ // * Container
+ //
+ // The ingress operator configures the sidecar container named "logs" on
+ // the ingress controller pod and configures the ingress controller to
+ // write logs to the sidecar. The logs are then available as container
+ // logs. The expectation is that the administrator configures a custom
+ // logging solution that reads logs from this sidecar. Note that using
+ // container logs means that logs may be dropped if the rate of logs
+ // exceeds the container runtime's or the custom logging solution's
+ // capacity.
+ //
+ // * Syslog
+ //
+ // Logs are sent to a syslog endpoint. The administrator must specify
+ // an endpoint that can receive syslog messages. The expectation is
+ // that the administrator has configured a custom syslog instance.
+ //
+ // +unionDiscriminator
+ // +required
+ Type LoggingDestinationType `json:"type"`
+
+ // syslog holds parameters for a syslog endpoint. Present only if
+ // type is Syslog.
+ //
+ // +optional
+ Syslog *SyslogLoggingDestinationParameters `json:"syslog,omitempty"`
+
+ // container holds parameters for the Container logging destination.
+ // Present only if type is Container.
+ //
+ // +optional
+ Container *ContainerLoggingDestinationParameters `json:"container,omitempty"`
+}
+
+// IngressControllerCaptureHTTPHeader describes an HTTP header that should be
+// captured.
+type IngressControllerCaptureHTTPHeader struct {
+ // name specifies a header name. Its value must be a valid HTTP header
+ // name as defined in RFC 2616 section 4.2.
+ //
+ // +kubebuilder:validation:Pattern="^[-!#$%&'*+.0-9A-Z^_`a-z|~]+$"
+ // +required
+ Name string `json:"name"`
+
+ // maxLength specifies a maximum length for the header value. If a
+ // header value exceeds this length, the value will be truncated in the
+ // log message. Note that the ingress controller may impose a separate
+ // bound on the total length of HTTP headers in a request.
+ //
+ // +kubebuilder:validation:Minimum=1
+ // +required
+ MaxLength int `json:"maxLength"`
+}
+
+// IngressControllerCaptureHTTPHeaders specifies which HTTP headers the
+// IngressController captures.
+type IngressControllerCaptureHTTPHeaders struct {
+ // request specifies which HTTP request headers to capture.
+ //
+ // If this field is empty, no request headers are captured.
+ //
+ // +nullable
+ // +optional
+ // +listType=atomic
+ Request []IngressControllerCaptureHTTPHeader `json:"request,omitempty"`
+
+ // response specifies which HTTP response headers to capture.
+ //
+ // If this field is empty, no response headers are captured.
+ //
+ // +nullable
+ // +optional
+ // +listType=atomic
+ Response []IngressControllerCaptureHTTPHeader `json:"response,omitempty"`
+}
+
+// CookieMatchType indicates the type of matching used against cookie names to
+// select a cookie for capture.
+// +kubebuilder:validation:Enum=Exact;Prefix
+type CookieMatchType string
+
+const (
+ // CookieMatchTypeExact indicates that an exact string match should be
+ // performed.
+ CookieMatchTypeExact CookieMatchType = "Exact"
+ // CookieMatchTypePrefix indicates that a string prefix match should be
+ // performed.
+ CookieMatchTypePrefix CookieMatchType = "Prefix"
+)
+
+// IngressControllerCaptureHTTPCookie describes an HTTP cookie that should be
+// captured.
+type IngressControllerCaptureHTTPCookie struct {
+ IngressControllerCaptureHTTPCookieUnion `json:",inline"`
+
+ // maxLength specifies a maximum length of the string that will be
+ // logged, which includes the cookie name, cookie value, and
+ // one-character delimiter. If the log entry exceeds this length, the
+ // value will be truncated in the log message. Note that the ingress
+ // controller may impose a separate bound on the total length of HTTP
+ // headers in a request.
+ //
+ // +kubebuilder:validation:Minimum=1
+ // +kubebuilder:validation:Maximum=1024
+ // +required
+ MaxLength int `json:"maxLength"`
+}
+
+// IngressControllerCaptureHTTPCookieUnion describes optional fields of an HTTP cookie that should be captured.
+// +union
+type IngressControllerCaptureHTTPCookieUnion struct {
+ // matchType specifies the type of match to be performed on the cookie
+ // name. Allowed values are "Exact" for an exact string match and
+ // "Prefix" for a string prefix match. If "Exact" is specified, a name
+ // must be specified in the name field. If "Prefix" is provided, a
+ // prefix must be specified in the namePrefix field. For example,
+ // specifying matchType "Prefix" and namePrefix "foo" will capture a
+ // cookie named "foo" or "foobar" but not one named "bar". The first
+ // matching cookie is captured.
+ //
+ // +unionDiscriminator
+ // +required
+ MatchType CookieMatchType `json:"matchType"`
+
+ // name specifies a cookie name. Its value must be a valid HTTP cookie
+ // name as defined in RFC 6265 section 4.1.
+ //
+ // +kubebuilder:validation:Pattern="^[-!#$%&'*+.0-9A-Z^_`a-z|~]*$"
+ // +kubebuilder:validation:MinLength=0
+ // +kubebuilder:validation:MaxLength=1024
+ // +optional
+ Name string `json:"name"`
+
+ // namePrefix specifies a cookie name prefix. Its value must be a valid
+ // HTTP cookie name as defined in RFC 6265 section 4.1.
+ //
+ // +kubebuilder:validation:Pattern="^[-!#$%&'*+.0-9A-Z^_`a-z|~]*$"
+ // +kubebuilder:validation:MinLength=0
+ // +kubebuilder:validation:MaxLength=1024
+ // +optional
+ NamePrefix string `json:"namePrefix"`
+}
+
+// LoggingPolicy indicates how an event should be logged.
+// +kubebuilder:validation:Enum=Log;Ignore
+type LoggingPolicy string
+
+const (
+ // LoggingPolicyLog indicates that an event should be logged.
+ LoggingPolicyLog LoggingPolicy = "Log"
+ // LoggingPolicyIgnore indicates that an event should not be logged.
+ LoggingPolicyIgnore LoggingPolicy = "Ignore"
+)
+
+// AccessLogging describes how client requests should be logged.
+type AccessLogging struct {
+ // destination is where access logs go.
+ //
+ // +required
+ Destination LoggingDestination `json:"destination"`
+
+ // httpLogFormat specifies the format of the log message for an HTTP
+ // request.
+ //
+ // If this field is empty, log messages use the implementation's default
+ // HTTP log format. For HAProxy's default HTTP log format, see the
+ // HAProxy documentation:
+ // http://cbonte.github.io/haproxy-dconv/2.0/configuration.html#8.2.3
+ //
+ // Note that this format only applies to cleartext HTTP connections
+ // and to secure HTTP connections for which the ingress controller
+ // terminates encryption (that is, edge-terminated or reencrypt
+ // connections). It does not affect the log format for TLS passthrough
+ // connections.
+ //
+ // +optional
+ HttpLogFormat string `json:"httpLogFormat,omitempty"`
+
+ // httpCaptureHeaders defines HTTP headers that should be captured in
+ // access logs. If this field is empty, no headers are captured.
+ //
+ // Note that this option only applies to cleartext HTTP connections
+ // and to secure HTTP connections for which the ingress controller
+ // terminates encryption (that is, edge-terminated or reencrypt
+ // connections). Headers cannot be captured for TLS passthrough
+ // connections.
+ //
+ // +optional
+ HTTPCaptureHeaders IngressControllerCaptureHTTPHeaders `json:"httpCaptureHeaders,omitempty"`
+
+ // httpCaptureCookies specifies HTTP cookies that should be captured in
+ // access logs. If this field is empty, no cookies are captured.
+ //
+ // +nullable
+ // +optional
+ // +kubebuilder:validation:MaxItems=1
+ // +listType=atomic
+ HTTPCaptureCookies []IngressControllerCaptureHTTPCookie `json:"httpCaptureCookies,omitempty"`
+
+ // logEmptyRequests specifies how connections on which no request is
+ // received should be logged. Typically, these empty requests come from
+ // load balancers' health probes or Web browsers' speculative
+ // connections ("preconnect"), in which case logging these requests may
+ // be undesirable. However, these requests may also be caused by
+ // network errors, in which case logging empty requests may be useful
+ // for diagnosing the errors. In addition, these requests may be caused
+ // by port scans, in which case logging empty requests may aid in
+ // detecting intrusion attempts. Allowed values for this field are
+ // "Log" and "Ignore". The default value is "Log".
+ //
+ // +optional
+ // +kubebuilder:default:="Log"
+ LogEmptyRequests LoggingPolicy `json:"logEmptyRequests,omitempty"`
+}
+
+// IngressControllerLogging describes what should be logged where.
+type IngressControllerLogging struct {
+ // access describes how the client requests should be logged.
+ //
+ // If this field is empty, access logging is disabled.
+ //
+ // +optional
+ Access *AccessLogging `json:"access,omitempty"`
+}
+
+// IngressControllerHTTPHeaderPolicy is a policy for setting HTTP headers.
+//
+// +kubebuilder:validation:Enum=Append;Replace;IfNone;Never
+type IngressControllerHTTPHeaderPolicy string
+
+const (
+ // AppendHTTPHeaderPolicy appends the header, preserving any existing header.
+ AppendHTTPHeaderPolicy IngressControllerHTTPHeaderPolicy = "Append"
+ // ReplaceHTTPHeaderPolicy sets the header, removing any existing header.
+ ReplaceHTTPHeaderPolicy IngressControllerHTTPHeaderPolicy = "Replace"
+ // IfNoneHTTPHeaderPolicy sets the header if it is not already set.
+ IfNoneHTTPHeaderPolicy IngressControllerHTTPHeaderPolicy = "IfNone"
+ // NeverHTTPHeaderPolicy never sets the header, preserving any existing
+ // header.
+ NeverHTTPHeaderPolicy IngressControllerHTTPHeaderPolicy = "Never"
+)
+
+// IngressControllerHTTPUniqueIdHeaderPolicy describes configuration for a
+// unique id header.
+type IngressControllerHTTPUniqueIdHeaderPolicy struct {
+ // name specifies the name of the HTTP header (for example, "unique-id")
+ // that the ingress controller should inject into HTTP requests. The
+ // field's value must be a valid HTTP header name as defined in RFC 2616
+ // section 4.2. If the field is empty, no header is injected.
+ //
+ // +optional
+ // +kubebuilder:validation:Pattern="^$|^[-!#$%&'*+.0-9A-Z^_`a-z|~]+$"
+ // +kubebuilder:validation:MinLength=0
+ // +kubebuilder:validation:MaxLength=1024
+ Name string `json:"name,omitempty"`
+
+ // format specifies the format for the injected HTTP header's value.
+ // This field has no effect unless name is specified. For the
+ // HAProxy-based ingress controller implementation, this format uses the
+ // same syntax as the HTTP log format. If the field is empty, the
+ // default value is "%{+X}o\\ %ci:%cp_%fi:%fp_%Ts_%rt:%pid"; see the
+ // corresponding HAProxy documentation:
+ // http://cbonte.github.io/haproxy-dconv/2.0/configuration.html#8.2.3
+ //
+ // +optional
+ // +kubebuilder:validation:Pattern="^(%(%|(\\{[-+]?[QXE](,[-+]?[QXE])*\\})?([A-Za-z]+|\\[[.0-9A-Z_a-z]+(\\([^)]+\\))?(,[.0-9A-Z_a-z]+(\\([^)]+\\))?)*\\]))|[^%[:cntrl:]])*$"
+ // +kubebuilder:validation:MinLength=0
+ // +kubebuilder:validation:MaxLength=1024
+ Format string `json:"format,omitempty"`
+}
+
+// IngressControllerHTTPHeaderNameCaseAdjustment is the name of an HTTP header
+// (for example, "X-Forwarded-For") in the desired capitalization. The value
+// must be a valid HTTP header name as defined in RFC 2616 section 4.2.
+//
+// +kubebuilder:validation:Pattern="^$|^[-!#$%&'*+.0-9A-Z^_`a-z|~]+$"
+// +kubebuilder:validation:MinLength=0
+// +kubebuilder:validation:MaxLength=1024
+type IngressControllerHTTPHeaderNameCaseAdjustment string
+
+// IngressControllerHTTPHeaders specifies how the IngressController handles
+// certain HTTP headers.
+type IngressControllerHTTPHeaders struct {
+ // forwardedHeaderPolicy specifies when and how the IngressController
+ // sets the Forwarded, X-Forwarded-For, X-Forwarded-Host,
+ // X-Forwarded-Port, X-Forwarded-Proto, and X-Forwarded-Proto-Version
+ // HTTP headers. The value may be one of the following:
+ //
+ // * "Append", which specifies that the IngressController appends the
+ // headers, preserving existing headers.
+ //
+ // * "Replace", which specifies that the IngressController sets the
+ // headers, replacing any existing Forwarded or X-Forwarded-* headers.
+ //
+ // * "IfNone", which specifies that the IngressController sets the
+ // headers if they are not already set.
+ //
+ // * "Never", which specifies that the IngressController never sets the
+ // headers, preserving any existing headers.
+ //
+ // By default, the policy is "Append".
+ //
+ // +optional
+ ForwardedHeaderPolicy IngressControllerHTTPHeaderPolicy `json:"forwardedHeaderPolicy,omitempty"`
+
+ // uniqueId describes configuration for a custom HTTP header that the
+ // ingress controller should inject into incoming HTTP requests.
+ // Typically, this header is configured to have a value that is unique
+ // to the HTTP request. The header can be used by applications or
+ // included in access logs to facilitate tracing individual HTTP
+ // requests.
+ //
+ // If this field is empty, no such header is injected into requests.
+ //
+ // +optional
+ UniqueId IngressControllerHTTPUniqueIdHeaderPolicy `json:"uniqueId,omitempty"`
+
+ // headerNameCaseAdjustments specifies case adjustments that can be
+ // applied to HTTP header names. Each adjustment is specified as an
+ // HTTP header name with the desired capitalization. For example,
+ // specifying "X-Forwarded-For" indicates that the "x-forwarded-for"
+ // HTTP header should be adjusted to have the specified capitalization.
+ //
+ // These adjustments are only applied to cleartext, edge-terminated, and
+ // re-encrypt routes, and only when using HTTP/1.
+ //
+ // For request headers, these adjustments are applied only for routes
+ // that have the haproxy.router.openshift.io/h1-adjust-case=true
+ // annotation. For response headers, these adjustments are applied to
+ // all HTTP responses.
+ //
+ // If this field is empty, no request headers are adjusted.
+ //
+ // +nullable
+ // +optional
+ // +listType=atomic
+ HeaderNameCaseAdjustments []IngressControllerHTTPHeaderNameCaseAdjustment `json:"headerNameCaseAdjustments,omitempty"`
+
+ // actions specifies options for modifying headers and their values.
+ // Note that this option only applies to cleartext HTTP connections
+ // and to secure HTTP connections for which the ingress controller
+ // terminates encryption (that is, edge-terminated or reencrypt
+ // connections). Headers cannot be modified for TLS passthrough
+ // connections.
+ // Setting the HSTS (`Strict-Transport-Security`) header is not supported via actions. `Strict-Transport-Security`
+ // may only be configured using the "haproxy.router.openshift.io/hsts_header" route annotation, and only in
+ // accordance with the policy specified in Ingress.Spec.RequiredHSTSPolicies.
+ // Any actions defined here are applied after any actions related to the following other fields:
+ // cache-control, spec.clientTLS,
+ // spec.httpHeaders.forwardedHeaderPolicy, spec.httpHeaders.uniqueId,
+ // and spec.httpHeaders.headerNameCaseAdjustments.
+ // In case of HTTP request headers, the actions specified in spec.httpHeaders.actions on the Route will be executed after
+ // the actions specified in the IngressController's spec.httpHeaders.actions field.
+ // In case of HTTP response headers, the actions specified in spec.httpHeaders.actions on the IngressController will be
+ // executed after the actions specified in the Route's spec.httpHeaders.actions field.
+ // Headers set using this API cannot be captured for use in access logs.
+ // The following header names are reserved and may not be modified via this API:
+ // Strict-Transport-Security, Proxy, Host, Cookie, Set-Cookie.
+ // Note that the total size of all net added headers *after* interpolating dynamic values
+ // must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the
+ // IngressController. Please refer to the documentation
+ // for that API field for more details.
+ // +optional
+ Actions IngressControllerHTTPHeaderActions `json:"actions,omitempty"`
+}
+
+// IngressControllerHTTPHeaderActions defines configuration for actions on HTTP request and response headers.
+type IngressControllerHTTPHeaderActions struct {
+ // response is a list of HTTP response headers to modify.
+ // Actions defined here will modify the response headers of all requests passing through an ingress controller.
+ // These actions are applied to all Routes i.e. for all connections handled by the ingress controller defined within a cluster.
+ // IngressController actions for response headers will be executed after Route actions.
+ // Currently, actions may define to either `Set` or `Delete` headers values.
+ // Actions are applied in sequence as defined in this list.
+ // A maximum of 20 response header actions may be configured.
+ // Sample fetchers allowed are "res.hdr" and "ssl_c_der".
+ // Converters allowed are "lower" and "base64".
+ // Example header values: "%[res.hdr(X-target),lower]", "%{+Q}[ssl_c_der,base64]".
+ // +listType=map
+ // +listMapKey=name
+ // +optional
+ // +kubebuilder:validation:MaxItems=20
+ // +kubebuilder:validation:XValidation:rule=`self.all(key, key.action.type == "Delete" || (has(key.action.set) && key.action.set.value.matches('^(?:%(?:%|(?:\\{[-+]?[QXE](?:,[-+]?[QXE])*\\})?\\[(?:res\\.hdr\\([0-9A-Za-z-]+\\)|ssl_c_der)(?:,(?:lower|base64))*\\])|[^%[:cntrl:]])+$')))`,message="Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are res.hdr, ssl_c_der. Converters allowed are lower, base64."
+ Response []IngressControllerHTTPHeader `json:"response"`
+ // request is a list of HTTP request headers to modify.
+ // Actions defined here will modify the request headers of all requests passing through an ingress controller.
+ // These actions are applied to all Routes i.e. for all connections handled by the ingress controller defined within a cluster.
+ // IngressController actions for request headers will be executed before Route actions.
+ // Currently, actions may define to either `Set` or `Delete` headers values.
+ // Actions are applied in sequence as defined in this list.
+ // A maximum of 20 request header actions may be configured.
+ // Sample fetchers allowed are "req.hdr" and "ssl_c_der".
+ // Converters allowed are "lower" and "base64".
+ // Example header values: "%[req.hdr(X-target),lower]", "%{+Q}[ssl_c_der,base64]".
+ // + ---
+ // + Note: Any change to regex mentioned below must be reflected in the CRD validation of route in https://github.com/openshift/library-go/blob/master/pkg/route/validation/validation.go and vice-versa.
+ // +listType=map
+ // +listMapKey=name
+ // +optional
+ // +kubebuilder:validation:MaxItems=20
+ // +kubebuilder:validation:XValidation:rule=`self.all(key, key.action.type == "Delete" || (has(key.action.set) && key.action.set.value.matches('^(?:%(?:%|(?:\\{[-+]?[QXE](?:,[-+]?[QXE])*\\})?\\[(?:req\\.hdr\\([0-9A-Za-z-]+\\)|ssl_c_der)(?:,(?:lower|base64))*\\])|[^%[:cntrl:]])+$')))`,message="Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are req.hdr, ssl_c_der. Converters allowed are lower, base64."
+ Request []IngressControllerHTTPHeader `json:"request"`
+}
+
+// IngressControllerHTTPHeader specifies configuration for setting or deleting an HTTP header.
+type IngressControllerHTTPHeader struct {
+ // name specifies the name of a header on which to perform an action. Its value must be a valid HTTP header
+ // name as defined in RFC 2616 section 4.2.
+ // The name must consist only of alphanumeric and the following special characters, "-!#$%&'*+.^_`".
+ // The following header names are reserved and may not be modified via this API:
+ // Strict-Transport-Security, Proxy, Host, Cookie, Set-Cookie.
+ // It must be no more than 255 characters in length.
+ // Header name must be unique.
+ // +required
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=255
+ // +kubebuilder:validation:Pattern="^[-!#$%&'*+.0-9A-Z^_`a-z|~]+$"
+ // +kubebuilder:validation:XValidation:rule="self.lowerAscii() != 'strict-transport-security'",message="strict-transport-security header may not be modified via header actions"
+ // +kubebuilder:validation:XValidation:rule="self.lowerAscii() != 'proxy'",message="proxy header may not be modified via header actions"
+ // +kubebuilder:validation:XValidation:rule="self.lowerAscii() != 'host'",message="host header may not be modified via header actions"
+ // +kubebuilder:validation:XValidation:rule="self.lowerAscii() != 'cookie'",message="cookie header may not be modified via header actions"
+ // +kubebuilder:validation:XValidation:rule="self.lowerAscii() != 'set-cookie'",message="set-cookie header may not be modified via header actions"
+ Name string `json:"name"`
+ // action specifies actions to perform on headers, such as setting or deleting headers.
+ // +required
+ Action IngressControllerHTTPHeaderActionUnion `json:"action"`
+}
+
+// IngressControllerHTTPHeaderActionUnion specifies an action to take on an HTTP header.
+// +kubebuilder:validation:XValidation:rule="has(self.type) && self.type == 'Set' ? has(self.set) : !has(self.set)",message="set is required when type is Set, and forbidden otherwise"
+// +union
+type IngressControllerHTTPHeaderActionUnion struct {
+ // type defines the type of the action to be applied on the header.
+ // Possible values are Set or Delete.
+ // Set allows you to set HTTP request and response headers.
+ // Delete allows you to delete HTTP request and response headers.
+ // +unionDiscriminator
+ // +kubebuilder:validation:Enum:=Set;Delete
+ // +required
+ Type IngressControllerHTTPHeaderActionType `json:"type"`
+
+ // set specifies how the HTTP header should be set.
+ // This field is required when type is Set and forbidden otherwise.
+ // +optional
+ // +unionMember
+ Set *IngressControllerSetHTTPHeader `json:"set,omitempty"`
+}
+
+// IngressControllerHTTPHeaderActionType defines actions that can be performed on HTTP headers.
+type IngressControllerHTTPHeaderActionType string
+
+const (
+ // Set specifies that an HTTP header should be set.
+ Set IngressControllerHTTPHeaderActionType = "Set"
+ // Delete specifies that an HTTP header should be deleted.
+ Delete IngressControllerHTTPHeaderActionType = "Delete"
+)
+
+// IngressControllerSetHTTPHeader defines the value which needs to be set on an HTTP header.
+type IngressControllerSetHTTPHeader struct {
+ // value specifies a header value.
+ // Dynamic values can be added. The value will be interpreted as an HAProxy format string as defined in
+ // http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and
+ // otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2.
+ // The value of this field must be no more than 16384 characters in length.
+ // Note that the total size of all net added headers *after* interpolating dynamic values
+ // must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the
+ // IngressController.
+ // + ---
+ // + Note: This limit was selected as most common web servers have a limit of 16384 characters or some lower limit.
+ // + See .
+ // +required
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=16384
+ Value string `json:"value"`
+}
+
+// IngressControllerTuningOptions specifies options for tuning the performance
+// of ingress controller pods
+type IngressControllerTuningOptions struct {
+ // headerBufferBytes describes how much memory should be reserved
+ // (in bytes) for IngressController connection sessions.
+ // Note that this value must be at least 16384 if HTTP/2 is
+ // enabled for the IngressController (https://tools.ietf.org/html/rfc7540).
+ // If this field is empty, the IngressController will use a default value
+ // of 32768 bytes.
+ //
+ // Setting this field is generally not recommended as headerBufferBytes
+ // values that are too small may break the IngressController and
+ // headerBufferBytes values that are too large could cause the
+ // IngressController to use significantly more memory than necessary.
+ //
+ // +kubebuilder:validation:Minimum=16384
+ // +optional
+ HeaderBufferBytes int32 `json:"headerBufferBytes,omitempty"`
+
+ // headerBufferMaxRewriteBytes describes how much memory should be reserved
+ // (in bytes) from headerBufferBytes for HTTP header rewriting
+ // and appending for IngressController connection sessions.
+ // Note that incoming HTTP requests will be limited to
+ // (headerBufferBytes - headerBufferMaxRewriteBytes) bytes, meaning
+ // headerBufferBytes must be greater than headerBufferMaxRewriteBytes.
+ // If this field is empty, the IngressController will use a default value
+ // of 8192 bytes.
+ //
+ // Setting this field is generally not recommended as
+ // headerBufferMaxRewriteBytes values that are too small may break the
+ // IngressController and headerBufferMaxRewriteBytes values that are too
+ // large could cause the IngressController to use significantly more memory
+ // than necessary.
+ //
+ // +kubebuilder:validation:Minimum=4096
+ // +optional
+ HeaderBufferMaxRewriteBytes int32 `json:"headerBufferMaxRewriteBytes,omitempty"`
+
+ // threadCount defines the number of threads created per HAProxy process.
+ // Creating more threads allows each ingress controller pod to handle more
+ // connections, at the cost of more system resources being used. HAProxy
+ // currently supports up to 64 threads. If this field is empty, the
+ // IngressController will use the default value. The current default is 4
+ // threads, but this may change in future releases.
+ //
+ // Setting this field is generally not recommended. Increasing the number
+ // of HAProxy threads allows ingress controller pods to utilize more CPU
+ // time under load, potentially starving other pods if set too high.
+ // Reducing the number of threads may cause the ingress controller to
+ // perform poorly.
+ //
+ // +kubebuilder:validation:Minimum=1
+ // +kubebuilder:validation:Maximum=64
+ // +optional
+ ThreadCount int32 `json:"threadCount,omitempty"`
+
+ // clientTimeout defines how long a connection will be held open while
+ // waiting for a client response.
+ //
+ // If unset, the default timeout is 30s
+ // +kubebuilder:validation:Format=duration
+ // +optional
+ ClientTimeout *metav1.Duration `json:"clientTimeout,omitempty"`
+
+ // clientFinTimeout defines how long a connection will be held open while
+ // waiting for the client response to the server/backend closing the
+ // connection.
+ //
+ // If unset, the default timeout is 1s
+ // +kubebuilder:validation:Format=duration
+ // +optional
+ ClientFinTimeout *metav1.Duration `json:"clientFinTimeout,omitempty"`
+
+ // serverTimeout defines how long a connection will be held open while
+ // waiting for a server/backend response.
+ //
+ // If unset, the default timeout is 30s
+ // +kubebuilder:validation:Format=duration
+ // +optional
+ ServerTimeout *metav1.Duration `json:"serverTimeout,omitempty"`
+
+ // serverFinTimeout defines how long a connection will be held open while
+ // waiting for the server/backend response to the client closing the
+ // connection.
+ //
+ // If unset, the default timeout is 1s
+ // +kubebuilder:validation:Format=duration
+ // +optional
+ ServerFinTimeout *metav1.Duration `json:"serverFinTimeout,omitempty"`
+
+ // tunnelTimeout defines how long a tunnel connection (including
+ // websockets) will be held open while the tunnel is idle.
+ //
+ // If unset, the default timeout is 1h
+ // +kubebuilder:validation:Format=duration
+ // +optional
+ TunnelTimeout *metav1.Duration `json:"tunnelTimeout,omitempty"`
+
+ // connectTimeout defines the maximum time to wait for
+ // a connection attempt to a server/backend to succeed.
+ //
+ // This field expects an unsigned duration string of decimal numbers, each with optional
+ // fraction and a unit suffix, e.g. "300ms", "1.5h" or "2h45m".
+ // Valid time units are "ns", "us" (or "µs" U+00B5 or "μs" U+03BC), "ms", "s", "m", "h".
+ //
+ // When omitted, this means the user has no opinion and the platform is left
+ // to choose a reasonable default. This default is subject to change over time.
+ // The current default is 5s.
+ //
+ // +kubebuilder:validation:Pattern=^(0|([0-9]+(\.[0-9]+)?(ns|us|µs|μs|ms|s|m|h))+)$
+ // +kubebuilder:validation:Type:=string
+ // +optional
+ ConnectTimeout *metav1.Duration `json:"connectTimeout,omitempty"`
+
+ // httpKeepAliveTimeout defines the maximum allowed time to wait for
+ // a new HTTP request to appear on a connection from the client to the router.
+ //
+ // This field expects an unsigned duration string of a decimal number, with optional
+ // fraction and a unit suffix, e.g. "300ms", "1.5s" or "2m45s".
+ // Valid time units are "ms", "s", "m".
+ // The allowed range is from 1 millisecond to 15 minutes.
+ //
+ // When omitted, this means the user has no opinion and the platform is left
+ // to choose a reasonable default. This default is subject to change over time.
+ // The current default is 300s.
+ //
+ // Low values (tens of milliseconds or less) can cause clients to close and reopen connections
+ // for each request, leading to reduced connection sharing.
+ // For HTTP/2, special care should be taken with low values.
+ // A few seconds is a reasonable starting point to avoid holding idle connections open
+ // while still allowing subsequent requests to reuse the connection.
+ //
+ // High values (minutes or more) favor connection reuse but may cause idle
+ // connections to linger longer.
+ //
+ // +kubebuilder:validation:Type:=string
+ // +kubebuilder:validation:XValidation:rule="self.matches('^([0-9]+(\\\\.[0-9]+)?(ms|s|m))+$')",message="httpKeepAliveTimeout must be a valid duration string composed of an unsigned integer value, optionally followed by a decimal fraction and a unit suffix (ms, s, m)"
+ // +kubebuilder:validation:XValidation:rule="!self.matches('^([0-9]+(\\\\.[0-9]+)?(ms|s|m))+$') || duration(self) <= duration('15m')",message="httpKeepAliveTimeout must be less than or equal to 15 minutes"
+ // +kubebuilder:validation:XValidation:rule="!self.matches('^([0-9]+(\\\\.[0-9]+)?(ms|s|m))+$') || duration(self) >= duration('1ms')",message="httpKeepAliveTimeout must be greater than or equal to 1 millisecond"
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=16
+ // +optional
+ HTTPKeepAliveTimeout *metav1.Duration `json:"httpKeepAliveTimeout,omitempty"`
+
+ // tlsInspectDelay defines how long the router can hold data to find a
+ // matching route.
+ //
+ // Setting this too short can cause the router to fall back to the default
+ // certificate for edge-terminated or reencrypt routes even when a better
+ // matching certificate could be used.
+ //
+ // If unset, the default inspect delay is 5s
+ // +kubebuilder:validation:Format=duration
+ // +optional
+ TLSInspectDelay *metav1.Duration `json:"tlsInspectDelay,omitempty"`
+
+ // healthCheckInterval defines how long the router waits between two consecutive
+ // health checks on its configured backends. This value is applied globally as
+ // a default for all routes, but may be overridden per-route by the route annotation
+ // "router.openshift.io/haproxy.health.check.interval".
+ //
+ // Expects an unsigned duration string of decimal numbers, each with optional
+ // fraction and a unit suffix, eg "300ms", "1.5h" or "2h45m".
+ // Valid time units are "ns", "us" (or "µs" U+00B5 or "μs" U+03BC), "ms", "s", "m", "h".
+ //
+ // Setting this to less than 5s can cause excess traffic due to too frequent
+ // TCP health checks and accompanying SYN packet storms. Alternatively, setting
+ // this too high can result in increased latency, due to backend servers that are no
+ // longer available, but haven't yet been detected as such.
+ //
+ // An empty or zero healthCheckInterval means no opinion and IngressController chooses
+ // a default, which is subject to change over time.
+ // Currently the default healthCheckInterval value is 5s.
+ //
+ // Currently the minimum allowed value is 1s and the maximum allowed value is
+ // 2147483647ms (24.85 days). Both are subject to change over time.
+ //
+ // +kubebuilder:validation:Pattern=^(0|([0-9]+(\.[0-9]+)?(ns|us|µs|μs|ms|s|m|h))+)$
+ // +kubebuilder:validation:Type:=string
+ // +optional
+ HealthCheckInterval *metav1.Duration `json:"healthCheckInterval,omitempty"`
+
+ // maxConnections defines the maximum number of simultaneous
+ // connections that can be established per HAProxy process.
+ // Increasing this value allows each ingress controller pod to
+ // handle more connections but at the cost of additional
+ // system resources being consumed.
+ //
+ // Permitted values are: empty, 0, -1, and the range
+ // 2000-2000000.
+ //
+ // If this field is empty or 0, the IngressController will use
+ // the default value of 50000, but the default is subject to
+ // change in future releases.
+ //
+ // If the value is -1 then HAProxy will dynamically compute a
+ // maximum value based on the available ulimits in the running
+ // container. Selecting -1 (i.e., auto) will result in a large
+ // value being computed (~520000 on OpenShift >=4.10 clusters)
+ // and therefore each HAProxy process will incur significant
+ // memory usage compared to the current default of 50000.
+ //
+ // Setting a value that is greater than the current operating
+ // system limit will prevent the HAProxy process from
+ // starting.
+ //
+ // If you choose a discrete value (e.g., 750000) and the
+ // router pod is migrated to a new node, there's no guarantee
+ // that that new node has identical ulimits configured. In
+ // such a scenario the pod would fail to start. If you have
+ // nodes with different ulimits configured (e.g., different
+ // tuned profiles) and you choose a discrete value then the
+ // guidance is to use -1 and let the value be computed
+ // dynamically at runtime.
+ //
+ // You can monitor memory usage for router containers with the
+ // following metric:
+ // 'container_memory_working_set_bytes{container="router",namespace="openshift-ingress"}'.
+ //
+ // You can monitor memory usage of individual HAProxy
+ // processes in router containers with the following metric:
+ // 'container_memory_working_set_bytes{container="router",namespace="openshift-ingress"}/container_processes{container="router",namespace="openshift-ingress"}'.
+ //
+ // +kubebuilder:validation:XValidation:rule="self == 0 || self == -1 || (self >= 2000 && self <= 2000000)",message="maxConnections must be 0, -1, or between 2000 and 2000000"
+ // +optional
+ MaxConnections int32 `json:"maxConnections,omitempty"`
+
+ // reloadInterval defines the minimum interval at which the router is allowed to reload
+ // to accept new changes. Increasing this value can prevent the accumulation of
+ // HAProxy processes, depending on the scenario. Increasing this interval can
+ // also lessen load imbalance on a backend's servers when using the roundrobin
+ // balancing algorithm. Alternatively, decreasing this value may decrease latency
+ // since updates to HAProxy's configuration can take effect more quickly.
+ //
+ // The value must be a time duration value; see .
+ // Currently, the minimum value allowed is 1s, and the maximum allowed value is
+ // 120s. Minimum and maximum allowed values may change in future versions of OpenShift.
+ // Note that if a duration outside of these bounds is provided, the value of reloadInterval
+ // will be capped/floored and not rejected (e.g. a duration of over 120s will be capped to
+ // 120s; the IngressController will not reject and replace this disallowed value with
+ // the default).
+ //
+ // A zero value for reloadInterval tells the IngressController to choose the default,
+ // which is currently 5s and subject to change without notice.
+ //
+ // This field expects an unsigned duration string of decimal numbers, each with optional
+ // fraction and a unit suffix, e.g. "300ms", "1.5h" or "2h45m".
+ // Valid time units are "ns", "us" (or "µs" U+00B5 or "μs" U+03BC), "ms", "s", "m", "h".
+ //
+ // Note: Setting a value significantly larger than the default of 5s can cause latency
+ // in observing updates to routes and their endpoints. HAProxy's configuration will
+ // be reloaded less frequently, and newly created routes will not be served until the
+ // subsequent reload.
+ //
+ // +kubebuilder:validation:Pattern=^(0|([0-9]+(\.[0-9]+)?(ns|us|µs|μs|ms|s|m|h))+)$
+ // +kubebuilder:validation:Type:=string
+ // +optional
+ ReloadInterval metav1.Duration `json:"reloadInterval,omitempty"`
+
+ // configurationManagement specifies how OpenShift router should update
+ // the HAProxy configuration. The following values are valid for this
+ // field:
+ //
+ // * "ForkAndReload".
+ // * "Dynamic".
+ //
+ // Omitting this field means that the user has no opinion and the
+ // platform may choose a reasonable default. This default is subject to
+ // change over time. The current default is "ForkAndReload".
+ //
+ // "ForkAndReload" means that OpenShift router should rewrite the
+ // HAProxy configuration file and instruct HAProxy to fork and reload.
+ // This is OpenShift router's traditional approach.
+ //
+ // "Dynamic" means that OpenShift router may use HAProxy's control
+ // socket for some configuration updates and fall back to fork and
+ // reload for other configuration updates. This is a newer approach,
+ // which may be less mature than ForkAndReload. This setting can
+ // improve load-balancing fairness and metrics accuracy and reduce CPU
+ // and memory usage if HAProxy has frequent configuration updates for
+ // route and endpoints updates.
+ //
+ // Note: The "Dynamic" option is currently experimental and should not
+ // be enabled on production clusters.
+ //
+ // +openshift:enable:FeatureGate=IngressControllerDynamicConfigurationManager
+ // +optional
+ ConfigurationManagement IngressControllerConfigurationManagement `json:"configurationManagement,omitempty"`
+}
+
+// IngressControllerConfigurationManagement specifies whether always to use
+// fork-and-reload to update the HAProxy configuration or whether to use
+// HAProxy's control socket for some configuration updates.
+//
+// +enum
+// +kubebuilder:validation:Enum=Dynamic;ForkAndReload
+type IngressControllerConfigurationManagement string
+
+const (
+ IngressControllerConfigurationManagementDynamic IngressControllerConfigurationManagement = "Dynamic"
+ IngressControllerConfigurationManagementForkAndReload IngressControllerConfigurationManagement = "ForkAndReload"
+)
+
+// HTTPEmptyRequestsPolicy indicates how HTTP connections for which no request
+// is received should be handled.
+// +kubebuilder:validation:Enum=Respond;Ignore
+type HTTPEmptyRequestsPolicy string
+
+const (
+ // HTTPEmptyRequestsPolicyRespond indicates that the ingress controller
+ // should respond to empty requests.
+ HTTPEmptyRequestsPolicyRespond HTTPEmptyRequestsPolicy = "Respond"
+ // HTTPEmptyRequestsPolicyIgnore indicates that the ingress controller
+ // should ignore empty requests.
+ HTTPEmptyRequestsPolicyIgnore HTTPEmptyRequestsPolicy = "Ignore"
+)
+
+var (
+ // Available indicates the ingress controller deployment is available.
+ IngressControllerAvailableConditionType = "Available"
+ // LoadBalancerManaged indicates the management status of any load balancer
+ // service associated with an ingress controller.
+ LoadBalancerManagedIngressConditionType = "LoadBalancerManaged"
+ // LoadBalancerReady indicates the ready state of any load balancer service
+ // associated with an ingress controller.
+ LoadBalancerReadyIngressConditionType = "LoadBalancerReady"
+ // DNSManaged indicates the management status of any DNS records for the
+ // ingress controller.
+ DNSManagedIngressConditionType = "DNSManaged"
+ // DNSReady indicates the ready state of any DNS records for the ingress
+ // controller.
+ DNSReadyIngressConditionType = "DNSReady"
+)
+
+// IngressControllerStatus defines the observed status of the IngressController.
+type IngressControllerStatus struct {
+ // availableReplicas is number of observed available replicas according to the
+ // ingress controller deployment.
+ // +optional
+ AvailableReplicas int32 `json:"availableReplicas"`
+
+ // selector is a label selector, in string format, for ingress controller pods
+ // corresponding to the IngressController. The number of matching pods should
+ // equal the value of availableReplicas.
+ // +optional
+ Selector string `json:"selector"`
+
+ // domain is the actual domain in use.
+ // +optional
+ Domain string `json:"domain"`
+
+ // endpointPublishingStrategy is the actual strategy in use.
+ // +optional
+ EndpointPublishingStrategy *EndpointPublishingStrategy `json:"endpointPublishingStrategy,omitempty"`
+
+ // conditions is a list of conditions and their status.
+ //
+ // Available means the ingress controller deployment is available and
+ // servicing route and ingress resources (i.e, .status.availableReplicas
+ // equals .spec.replicas)
+ //
+ // There are additional conditions which indicate the status of other
+ // ingress controller features and capabilities.
+ //
+ // * LoadBalancerManaged
+ // - True if the following conditions are met:
+ // * The endpoint publishing strategy requires a service load balancer.
+ // - False if any of those conditions are unsatisfied.
+ //
+ // * LoadBalancerReady
+ // - True if the following conditions are met:
+ // * A load balancer is managed.
+ // * The load balancer is ready.
+ // - False if any of those conditions are unsatisfied.
+ //
+ // * DNSManaged
+ // - True if the following conditions are met:
+ // * The endpoint publishing strategy and platform support DNS.
+ // * The ingress controller domain is set.
+ // * dns.config.openshift.io/cluster configures DNS zones.
+ // - False if any of those conditions are unsatisfied.
+ //
+ // * DNSReady
+ // - True if the following conditions are met:
+ // * DNS is managed.
+ // * DNS records have been successfully created.
+ // - False if any of those conditions are unsatisfied.
+ // +listType=map
+ // +listMapKey=type
+ // +optional
+ Conditions []OperatorCondition `json:"conditions,omitempty"`
+
+ // tlsProfile is the TLS connection configuration that is in effect.
+ // +optional
+ TLSProfile *configv1.TLSProfileSpec `json:"tlsProfile,omitempty"`
+
+ // observedGeneration is the most recent generation observed.
+ // +optional
+ ObservedGeneration int64 `json:"observedGeneration,omitempty"`
+
+ // namespaceSelector is the actual namespaceSelector in use.
+ // +optional
+ NamespaceSelector *metav1.LabelSelector `json:"namespaceSelector,omitempty"`
+
+ // routeSelector is the actual routeSelector in use.
+ // +optional
+ RouteSelector *metav1.LabelSelector `json:"routeSelector,omitempty"`
+
+ // effectiveHAProxyVersion reports the HAProxy version currently in use by
+ // this IngressController. This reflects the resolved value of the
+ // spec.haproxyVersion field. When omitted, the effective value has not yet
+ // been resolved by the operator or the feature is not enabled for this cluster.
+ //
+ // Examples for OpenShift 5.0:
+ // - "3.2": Using HAProxy 3.2
+ // - "2.8": Using HAProxy 2.8
+ //
+ // +optional
+ // +openshift:enable:FeatureGate=IngressControllerMultipleHAProxyVersions
+ EffectiveHAProxyVersion HAProxyVersion `json:"effectiveHAProxyVersion,omitempty"`
+}
+
+// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
+
+// IngressControllerList contains a list of IngressControllers.
+//
+// Compatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer).
+// +openshift:compatibility-gen:level=1
+type IngressControllerList struct {
+ metav1.TypeMeta `json:",inline"`
+
+ // metadata is the standard list's metadata.
+ // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
+ metav1.ListMeta `json:"metadata,omitempty"`
+
+ Items []IngressController `json:"items"`
+}
+
+// IngressControllerConnectionTerminationPolicy defines the behaviour
+// for handling idle connections during a soft reload of the router.
+//
+// +kubebuilder:validation:Enum=Immediate;Deferred
+type IngressControllerConnectionTerminationPolicy string
+
+const (
+ // IngressControllerConnectionTerminationPolicyImmediate specifies
+ // that idle connections should be closed immediately during a
+ // router reload.
+ IngressControllerConnectionTerminationPolicyImmediate IngressControllerConnectionTerminationPolicy = "Immediate"
+
+ // IngressControllerConnectionTerminationPolicyDeferred
+ // specifies that idle connections should remain open until a
+ // terminating event, such as a new request, the expiration of
+ // the proxy keep-alive timeout, or the client closing the
+ // connection.
+ IngressControllerConnectionTerminationPolicyDeferred IngressControllerConnectionTerminationPolicy = "Deferred"
+)
+
+// IngressControllerClosedClientConnectionPolicy controls how the IngressController
+// behaves when the client closes the TCP connection while the TLS
+// handshake or HTTP request is in progress.
+//
+// +kubebuilder:validation:Enum=Abort;Continue
+type IngressControllerClosedClientConnectionPolicy string
+
+const (
+ // IngressControllerClosedClientConnectionPolicyAbort aborts processing early when the client
+ // closes the connection.
+ //
+ // This affects two types of processing: TLS handshake computation on the router
+ // and request handling.
+ //
+ // When the client closes the connection, the router will stop processing
+ // the TLS handshake, preventing unnecessary CPU work.
+ //
+ // If the HTTP request has not yet been sent to the backend, it will be aborted.
+ // If the request is already being processed by the backend, the router will
+ // half-close the connection to signal this condition to the backend server,
+ // which can then decide how to proceed.
+ IngressControllerClosedClientConnectionPolicyAbort IngressControllerClosedClientConnectionPolicy = "Abort"
+
+ // IngressControllerClosedClientConnectionPolicyContinue continues processing even if the client
+ // closes the connection.
+ //
+ // The router will complete the TLS handshake and wait for the backend
+ // server's response regardless of the client having closed the connection.
+ IngressControllerClosedClientConnectionPolicyContinue IngressControllerClosedClientConnectionPolicy = "Continue"
+)
+
+// HAProxyVersion is a string representing a HAProxy minor version in "X.Y"
+// format. The allowed values are constrained by enum validation and vary by
+// OpenShift release.
+//
+// +kubebuilder:validation:Enum="2.8";"3.2"
+type HAProxyVersion string
+
+const (
+ // HAProxyVersion28 represents HAProxy 2.8, shipped with OpenShift 4.22.
+ HAProxyVersion28 HAProxyVersion = "2.8"
+
+ // HAProxyVersion32 represents HAProxy 3.2, introduced in OpenShift 5.0.
+ HAProxyVersion32 HAProxyVersion = "3.2"
+)
diff --git a/vendor/github.com/openshift/api/operator/v1/types_kmsencryption.go b/vendor/github.com/openshift/api/operator/v1/types_kmsencryption.go
new file mode 100644
index 0000000000..51a981b716
--- /dev/null
+++ b/vendor/github.com/openshift/api/operator/v1/types_kmsencryption.go
@@ -0,0 +1,171 @@
+package v1
+
+import (
+ metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
+)
+
+// +kubebuilder:validation:Enum=Healthy;Unhealthy;Error
+type KMSPluginHealthStatus string
+
+const (
+ KMSPluginHealthStatusHealthy KMSPluginHealthStatus = "Healthy"
+
+ KMSPluginHealthStatusUnhealthy KMSPluginHealthStatus = "Unhealthy"
+
+ KMSPluginHealthStatusError KMSPluginHealthStatus = "Error"
+)
+
+type KMSPluginHealthReport struct {
+
+ // nodeName is the name of the node this instance of the plugin runs on.
+ // The combination of nodeName and keyID makes this health report unique.
+ // The value must be a valid Kubernetes node name: a lowercase RFC 1123 subdomain
+ // consisting of lowercase alphanumeric characters, '-' or '.', starting and ending with
+ // an alphanumeric character, and be at most 253 characters in length.
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=253
+ // +kubebuilder:validation:XValidation:rule="!format.dns1123Subdomain().validate(self).hasValue()",message="nodeName must be a lowercase RFC 1123 subdomain consisting of lowercase alphanumeric characters, '-' or '.', and must start and end with an alphanumeric character"
+ // +required
+ NodeName string `json:"nodeName,omitempty"`
+
+ // keyID is the encryption-key-secret id (kms-{keyID}.sock), a unique identifier of the plugin on that node.
+ // This is not a cryptographic key used to encrypt/decrypt any resources.
+ // The value must be between 1 and 512 characters.
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=512
+ // +required
+ KeyID string `json:"keyID,omitempty"`
+
+ // --- TOMBSTONE ---
+ // keyId is the encryption-key-secret id (kms-{keyId}.sock), a unique identifier of the plugin on that node.
+ // This is not a cryptographic key used to encrypt/decrypt any resources.
+ // The value must be between 1 and 512 characters.
+ // It has been renamed to keyID.
+ // The field name is reserved to prevent reuse.
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=512
+ // +required
+ // KeyId string `json:"keyId,omitempty"`
+
+ // status contains a health indicator for the respective KMS plugin
+ // The field can have three states: healthy, unhealthy, error.
+ // With error and unhealthy containing additional information in Detail.
+ // +required
+ Status KMSPluginHealthStatus `json:"status,omitempty"`
+
+ // lastCheckedTime is a timestamp of when the probe was last checked.
+ // +required
+ LastCheckedTime metav1.Time `json:"lastCheckedTime,omitempty"`
+
+ // remoteKeyID refers to the remote key identifier from KMS v2 StatusResponse.key_id.
+ // This is not a cryptographic key, but a unique representation of the KEK.
+ // The value must be between 1 and 1024 characters.
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=1024
+ // +required
+ RemoteKeyID string `json:"remoteKeyID,omitempty"`
+
+ // --- TOMBSTONE ---
+ // kekId refers to the remote KEK id from KMS v2 StatusResponse.key_id.
+ // This is not a cryptographic key, but a unique representation of the KEK.
+ // The value must be between 1 and 1024 characters.
+ // It has been renamed to remoteKeyID.
+ // The field name is reserved to prevent reuse.
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=1024
+ // +required
+ // KEKId string `json:"kekId,omitempty"`
+
+ // detail contains additional error/health information for the respective KMS plugin.
+ // When omitted, no additional error or health information is provided.
+ // When set, the value must be between 1 and 1024 characters.
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=1024
+ // +optional
+ Detail string `json:"detail,omitempty"`
+}
+
+// +openshift:compatibility-gen:level=1
+// +kubebuilder:validation:MinProperties=1
+type KMSEncryptionStatus struct {
+ // healthReports contains all KMS plugin health reports.
+ // When omitted, no health reports are available.
+ // Each entry must have a unique combination of nodeName and keyID.
+ // +optional
+ // +kubebuilder:validation:MinItems=1
+ // +kubebuilder:validation:MaxItems=200
+ // +listType=map
+ // +listMapKey=nodeName
+ // +listMapKey=keyID
+ HealthReports []KMSPluginHealthReport `json:"healthReports,omitempty"`
+
+ // preflight contains the state of KMS preflight validation for this operator.
+ // The preflight validates the KMS provider configuration before it is used
+ // to create a new encryption key, catching configuration issues early such
+ // as incorrect login credentials or an unreachable Vault service.
+ // When omitted, no preflight validation is in progress.
+ // +optional
+ Preflight KMSPreflightCheck `json:"preflight,omitzero"`
+}
+
+// KMSPreflightCheck describes a preflight validation request and its result.
+//
+// +kubebuilder:validation:MinProperties=1
+type KMSPreflightCheck struct {
+ // observedConfigHash is a hash of the KMS provider configuration and
+ // its referenced resources that has been observed and requires preflight
+ // validation before a new encryption key can be created.
+ // The value must be exactly 8 characters.
+ // +kubebuilder:validation:MinLength=8
+ // +kubebuilder:validation:MaxLength=8
+ // +kubebuilder:validation:XValidation:rule="self.matches('^[A-Za-z0-9_-]*={0,2}$')",message="must be a valid base64url encoded value"
+ // +required
+ ObservedConfigHash string `json:"observedConfigHash,omitempty"`
+
+ // result contains the outcome of the most recent preflight check.
+ // Preflight is considered passed when result.status is Succeeded and
+ // result.configHash matches observedConfigHash.
+ // When omitted, no preflight check result has been reported yet.
+ // +optional
+ Result KMSPreflightResult `json:"result,omitzero"`
+}
+
+// +kubebuilder:validation:Enum=Succeeded;Failed
+type KMSPreflightResultStatus string
+
+const (
+ KMSPreflightResultSucceeded KMSPreflightResultStatus = "Succeeded"
+
+ KMSPreflightResultFailed KMSPreflightResultStatus = "Failed"
+)
+
+// KMSPreflightResult contains the outcome of a preflight validation.
+//
+// +openshift:compatibility-gen:level=1
+type KMSPreflightResult struct {
+ // status indicates the outcome of the preflight check.
+ // Succeeded means the KMS plugin responded to Status, Encrypt, and
+ // Decrypt calls successfully.
+ // Failed means the validation did not pass.
+ // +required
+ Status KMSPreflightResultStatus `json:"status,omitempty"`
+
+ // configHash is the hash of the configuration that was validated.
+ // This is compared against observedConfigHash to confirm the result
+ // corresponds to the current configuration.
+ // The value must be exactly 8 characters.
+ // +kubebuilder:validation:MinLength=8
+ // +kubebuilder:validation:MaxLength=8
+ // +kubebuilder:validation:XValidation:rule="self.matches('^[A-Za-z0-9_-]*={0,2}$')",message="must be a valid base64url encoded value"
+ // +required
+ ConfigHash string `json:"configHash,omitempty"`
+
+ // remoteKeyID is the remote key encryption key identifier from KMS v2
+ // StatusResponse.key_id. This is not a cryptographic key, but a unique
+ // representation of the remote key used to encrypt data.
+ // The value must be between 1 and 1024 characters.
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=1024
+ // +required
+ RemoteKeyID string `json:"remoteKeyID,omitempty"`
+}
diff --git a/vendor/github.com/openshift/api/operator/v1/types_kubeapiserver.go b/vendor/github.com/openshift/api/operator/v1/types_kubeapiserver.go
index 1461f11a12..31b0c201b4 100644
--- a/vendor/github.com/openshift/api/operator/v1/types_kubeapiserver.go
+++ b/vendor/github.com/openshift/api/operator/v1/types_kubeapiserver.go
@@ -63,6 +63,11 @@ type KubeAPIServerStatus struct {
// +optional
// +listType=atomic
ServiceAccountIssuers []ServiceAccountIssuerStatus `json:"serviceAccountIssuers,omitempty"`
+
+ // encryptionStatus contains status reports for the KMS plugin health and its key rotation.
+ // +optional
+ // +openshift:enable:FeatureGate=KMSEncryption
+ EncryptionStatus KMSEncryptionStatus `json:"encryptionStatus,omitempty,omitzero"`
}
type ServiceAccountIssuerStatus struct {
diff --git a/vendor/github.com/openshift/api/operator/v1/types_machineconfiguration.go b/vendor/github.com/openshift/api/operator/v1/types_machineconfiguration.go
index f5836af0f8..f0c1e01c78 100644
--- a/vendor/github.com/openshift/api/operator/v1/types_machineconfiguration.go
+++ b/vendor/github.com/openshift/api/operator/v1/types_machineconfiguration.go
@@ -47,7 +47,6 @@ type MachineConfigurationSpec struct {
// and the platform is left to choose a reasonable default, which is subject to change over time.
// The default for each machine manager mode is All for GCP and AWS platforms, and None for all
// other platforms.
- // +openshift:enable:FeatureGate=ManagedBootImages
// +optional
ManagedBootImages ManagedBootImages `json:"managedBootImages"`
@@ -288,7 +287,6 @@ type MachineConfigurationStatus struct {
// managedBootImagesStatus reflects what the latest cluster-validated boot image configuration is
// and will be used by Machine Config Controller while performing boot image updates.
- // +openshift:enable:FeatureGate=ManagedBootImages
// +optional
ManagedBootImagesStatus ManagedBootImages `json:"managedBootImagesStatus"`
@@ -367,7 +365,7 @@ type ManagedBootImages struct {
// MachineManager describes a target machine resource that is registered for boot image updates. It stores identifying information
// such as the resource type and the API Group of the resource. It also provides granular control via the selection field.
-// +openshift:validation:FeatureGateAwareXValidation:requiredFeatureGate=ManagedBootImages;ManagedBootImagesCPMS,rule="self.resource != 'controlplanemachinesets' || self.selection.mode == 'All' || self.selection.mode == 'None'", message="Only All or None selection mode is permitted for ControlPlaneMachineSets"
+// +openshift:validation:FeatureGateAwareXValidation:requiredFeatureGate=ManagedBootImagesCPMS,rule="self.resource != 'controlplanemachinesets' || self.selection.mode == 'All' || self.selection.mode == 'None'", message="Only All or None selection mode is permitted for ControlPlaneMachineSets"
type MachineManager struct {
// resource is the machine management resource's type.
// Valid values are machinesets and controlplanemachinesets.
@@ -431,8 +429,8 @@ const (
// MachineManagerManagedResourceType is a string enum used in the MachineManager type to describe the resource
// type to be registered.
-// +openshift:validation:FeatureGateAwareEnum:requiredFeatureGate=ManagedBootImages,enum=machinesets
-// +openshift:validation:FeatureGateAwareEnum:requiredFeatureGate=ManagedBootImages;ManagedBootImagesCPMS,enum=machinesets;controlplanemachinesets
+// +openshift:validation:FeatureGateAwareEnum:featureGate="",enum=machinesets
+// +openshift:validation:FeatureGateAwareEnum:featureGate=ManagedBootImagesCPMS,enum=machinesets;controlplanemachinesets
type MachineManagerMachineSetsResourceType string
const (
diff --git a/vendor/github.com/openshift/api/operator/v1/types_network.go b/vendor/github.com/openshift/api/operator/v1/types_network.go
index 1cf56f549b..cd2e2f9e38 100644
--- a/vendor/github.com/openshift/api/operator/v1/types_network.go
+++ b/vendor/github.com/openshift/api/operator/v1/types_network.go
@@ -398,6 +398,12 @@ type OpenShiftSDNConfig struct {
// ovnKubernetesConfig contains the configuration parameters for networks
// using the ovn-kubernetes network project
+// +openshift:validation:FeatureGateAwareXValidation:featureGate=NoOverlayMode,rule="self.?transport.orValue('') == 'NoOverlay' ? self.?routeAdvertisements.orValue('') == 'Enabled' : true",message="routeAdvertisements must be Enabled when transport is NoOverlay"
+// +openshift:validation:FeatureGateAwareXValidation:featureGate=NoOverlayMode,rule="self.?transport.orValue('') == 'NoOverlay' ? has(self.noOverlayConfig) : !has(self.noOverlayConfig)",message="noOverlayConfig must be set if transport is NoOverlay, and is forbidden otherwise"
+// +openshift:validation:FeatureGateAwareXValidation:featureGate=NoOverlayMode,rule="self.?noOverlayConfig.routing.orValue('') == 'Managed' ? has(self.bgpManagedConfig) : true",message="bgpManagedConfig is required when noOverlayConfig.routing is Managed"
+// +openshift:validation:FeatureGateAwareXValidation:featureGate=NoOverlayMode,rule="!has(self.transport) || self.transport == 'Geneve' || has(oldSelf.transport)",message="transport can only be set to Geneve after installation"
+// +openshift:validation:FeatureGateAwareXValidation:featureGate=NoOverlayMode,rule="!has(oldSelf.transport) || has(self.transport)",message="transport may not be removed once set"
+// +openshift:validation:FeatureGateAwareXValidation:featureGate=NoOverlayMode,rule="!has(oldSelf.noOverlayConfig) || has(self.noOverlayConfig)",message="noOverlayConfig may not be removed once set"
type OVNKubernetesConfig struct {
// mtu is the MTU to use for the tunnel interface. This must be 100
// bytes smaller than the uplink mtu.
@@ -466,6 +472,38 @@ type OVNKubernetesConfig struct {
// current default is "Disabled".
// +optional
RouteAdvertisements RouteAdvertisementsEnablement `json:"routeAdvertisements,omitempty"`
+
+ // transport sets the transport mode for pods on the default network.
+ // Allowed values are "NoOverlay" and "Geneve".
+ // "NoOverlay" avoids tunnel encapsulation, routing pod traffic directly between nodes.
+ // "Geneve" encapsulates pod traffic using Geneve tunnels between nodes.
+ // When omitted, this means the user has no opinion and the platform chooses
+ // a reasonable default which is subject to change over time.
+ // The current default is "Geneve".
+ // "NoOverlay" can only be set at installation time and cannot be changed afterwards.
+ // "Geneve" may be set explicitly at any time to lock in the current default.
+ // +openshift:enable:FeatureGate=NoOverlayMode
+ // +kubebuilder:validation:Enum=NoOverlay;Geneve
+ // +openshift:validation:FeatureGateAwareXValidation:featureGate=NoOverlayMode,rule="self == oldSelf",message="transport is immutable once set"
+ // +optional
+ Transport TransportOption `json:"transport,omitempty"`
+
+ // noOverlayConfig contains configuration for no-overlay mode.
+ // This configuration applies to the default network only.
+ // It is required when transport is "NoOverlay".
+ // When omitted, this means the user does not configure no-overlay mode options.
+ // +openshift:enable:FeatureGate=NoOverlayMode
+ // +optional
+ NoOverlayConfig NoOverlayConfig `json:"noOverlayConfig,omitzero,omitempty"`
+
+ // bgpManagedConfig configures the BGP properties for networks (default network or CUDNs)
+ // in no-overlay mode that specify routing="Managed" in their noOverlayConfig.
+ // It is required when noOverlayConfig.routing is set to "Managed".
+ // When omitted, this means the user does not configure BGP for managed routing.
+ // This field can be set at installation time or on day 2, and can be modified at any time.
+ // +openshift:enable:FeatureGate=NoOverlayMode
+ // +optional
+ BGPManagedConfig BGPManagedConfig `json:"bgpManagedConfig,omitzero,omitempty"`
}
type IPv4OVNKubernetesConfig struct {
@@ -896,3 +934,80 @@ type AdditionalRoutingCapabilities struct {
// +kubebuilder:validation:XValidation:rule="self.all(x, self.exists_one(y, x == y))"
Providers []RoutingCapabilitiesProvider `json:"providers"`
}
+
+// TransportOption is the type for network transport options
+type TransportOption string
+
+// SNATOption is the type for SNAT configuration options
+type SNATOption string
+
+// RoutingOption is the type for routing configuration options
+type RoutingOption string
+
+// BGPTopology is the type for BGP topology configuration
+type BGPTopology string
+
+const (
+ // TransportOptionNoOverlay indicates the network operates in no-overlay mode
+ TransportOptionNoOverlay TransportOption = "NoOverlay"
+ // TransportOptionGeneve indicates the network uses Geneve overlay
+ TransportOptionGeneve TransportOption = "Geneve"
+
+ // SNATEnabled indicates outbound SNAT is enabled
+ SNATEnabled SNATOption = "Enabled"
+ // SNATDisabled indicates outbound SNAT is disabled
+ SNATDisabled SNATOption = "Disabled"
+
+ // RoutingManaged indicates routing is managed by OVN-Kubernetes
+ RoutingManaged RoutingOption = "Managed"
+ // RoutingUnmanaged indicates routing is managed by users
+ RoutingUnmanaged RoutingOption = "Unmanaged"
+
+ // BGPTopologyFullMesh indicates a full mesh BGP topology where every node peers directly with every other node
+ BGPTopologyFullMesh BGPTopology = "FullMesh"
+)
+
+// NoOverlayConfig contains configuration options for networks operating in no-overlay mode.
+type NoOverlayConfig struct {
+ // outboundSNAT defines the SNAT behavior for outbound traffic from pods.
+ // Allowed values are "Enabled" and "Disabled".
+ // When set to "Enabled", SNAT is performed on outbound traffic from pods.
+ // When set to "Disabled", SNAT is not performed and pod IPs are preserved in outbound traffic.
+ // This field is required when the network operates in no-overlay mode.
+ // This field can be set to any value at installation time and can be changed afterwards.
+ // +kubebuilder:validation:Enum=Enabled;Disabled
+ // +required
+ OutboundSNAT SNATOption `json:"outboundSNAT,omitempty"`
+
+ // routing specifies whether the pod network routing is managed by OVN-Kubernetes or users.
+ // Allowed values are "Managed" and "Unmanaged".
+ // When set to "Managed", OVN-Kubernetes manages the pod network routing configuration through BGP.
+ // When set to "Unmanaged", users are responsible for configuring the pod network routing.
+ // This field is required when the network operates in no-overlay mode.
+ // This field is immutable once set.
+ // +kubebuilder:validation:Enum=Managed;Unmanaged
+ // +kubebuilder:validation:XValidation:rule="self == oldSelf",message="routing is immutable once set"
+ // +required
+ Routing RoutingOption `json:"routing,omitempty"`
+}
+
+// BGPManagedConfig contains configuration options for BGP when routing is "Managed".
+type BGPManagedConfig struct {
+ // asNumber is the 2-byte or 4-byte Autonomous System Number (ASN)
+ // to be used in the generated FRR configuration.
+ // Valid values are 1 to 4294967295.
+ // When omitted, this defaults to 64512.
+ // +kubebuilder:validation:Minimum=1
+ // +kubebuilder:validation:Maximum=4294967295
+ // +default=64512
+ // +optional
+ ASNumber int64 `json:"asNumber,omitempty"`
+
+ // bgpTopology defines the BGP topology to be used.
+ // Allowed values are "FullMesh".
+ // When set to "FullMesh", every node peers directly with every other node via BGP.
+ // This field is required when BGPManagedConfig is specified.
+ // +kubebuilder:validation:Enum=FullMesh
+ // +required
+ BGPTopology BGPTopology `json:"bgpTopology,omitempty"`
+}
diff --git a/vendor/github.com/openshift/api/operator/v1/types_openshiftapiserver.go b/vendor/github.com/openshift/api/operator/v1/types_openshiftapiserver.go
index a96e033cb7..c9d104ad2c 100644
--- a/vendor/github.com/openshift/api/operator/v1/types_openshiftapiserver.go
+++ b/vendor/github.com/openshift/api/operator/v1/types_openshiftapiserver.go
@@ -39,6 +39,11 @@ type OpenShiftAPIServerSpec struct {
type OpenShiftAPIServerStatus struct {
OperatorStatus `json:",inline"`
+
+ // encryptionStatus contains status reports for the KMS plugin health and its key rotation.
+ // +optional
+ // +openshift:enable:FeatureGate=KMSEncryption
+ EncryptionStatus KMSEncryptionStatus `json:"encryptionStatus,omitempty,omitzero"`
}
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
diff --git a/vendor/github.com/openshift/api/operator/v1/zz_generated.deepcopy.go b/vendor/github.com/openshift/api/operator/v1/zz_generated.deepcopy.go
index 3bc6b81de4..8f7441b6c7 100644
--- a/vendor/github.com/openshift/api/operator/v1/zz_generated.deepcopy.go
+++ b/vendor/github.com/openshift/api/operator/v1/zz_generated.deepcopy.go
@@ -285,6 +285,22 @@ func (in *Authentication) DeepCopyObject() runtime.Object {
return nil
}
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *AuthenticationConfigMapReference) DeepCopyInto(out *AuthenticationConfigMapReference) {
+ *out = *in
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AuthenticationConfigMapReference.
+func (in *AuthenticationConfigMapReference) DeepCopy() *AuthenticationConfigMapReference {
+ if in == nil {
+ return nil
+ }
+ out := new(AuthenticationConfigMapReference)
+ in.DeepCopyInto(out)
+ return out
+}
+
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *AuthenticationList) DeepCopyInto(out *AuthenticationList) {
*out = *in
@@ -318,10 +334,33 @@ func (in *AuthenticationList) DeepCopyObject() runtime.Object {
return nil
}
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *AuthenticationProxyConfig) DeepCopyInto(out *AuthenticationProxyConfig) {
+ *out = *in
+ if in.NoProxy != nil {
+ in, out := &in.NoProxy, &out.NoProxy
+ *out = make([]string, len(*in))
+ copy(*out, *in)
+ }
+ out.TrustedCA = in.TrustedCA
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AuthenticationProxyConfig.
+func (in *AuthenticationProxyConfig) DeepCopy() *AuthenticationProxyConfig {
+ if in == nil {
+ return nil
+ }
+ out := new(AuthenticationProxyConfig)
+ in.DeepCopyInto(out)
+ return out
+}
+
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *AuthenticationSpec) DeepCopyInto(out *AuthenticationSpec) {
*out = *in
in.OperatorSpec.DeepCopyInto(&out.OperatorSpec)
+ in.Proxy.DeepCopyInto(&out.Proxy)
return
}
@@ -338,7 +377,7 @@ func (in *AuthenticationSpec) DeepCopy() *AuthenticationSpec {
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *AuthenticationStatus) DeepCopyInto(out *AuthenticationStatus) {
*out = *in
- out.OAuthAPIServer = in.OAuthAPIServer
+ in.OAuthAPIServer.DeepCopyInto(&out.OAuthAPIServer)
in.OperatorStatus.DeepCopyInto(&out.OperatorStatus)
return
}
@@ -390,6 +429,22 @@ func (in *AzureDiskEncryptionSet) DeepCopy() *AzureDiskEncryptionSet {
return out
}
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *BGPManagedConfig) DeepCopyInto(out *BGPManagedConfig) {
+ *out = *in
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BGPManagedConfig.
+func (in *BGPManagedConfig) DeepCopy() *BGPManagedConfig {
+ if in == nil {
+ return nil
+ }
+ out := new(BGPManagedConfig)
+ in.DeepCopyInto(out)
+ return out
+}
+
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *BootImageSkewEnforcementConfig) DeepCopyInto(out *BootImageSkewEnforcementConfig) {
*out = *in
@@ -453,6 +508,7 @@ func (in *CSIDriverConfigSpec) DeepCopyInto(out *CSIDriverConfigSpec) {
*out = new(VSphereCSIDriverConfigSpec)
(*in).DeepCopyInto(*out)
}
+ in.SecretsStore.DeepCopyInto(&out.SecretsStore)
return
}
@@ -1164,6 +1220,22 @@ func (in *ContainerLoggingDestinationParameters) DeepCopy() *ContainerLoggingDes
return out
}
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *CustomSecretRotation) DeepCopyInto(out *CustomSecretRotation) {
+ *out = *in
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CustomSecretRotation.
+func (in *CustomSecretRotation) DeepCopy() *CustomSecretRotation {
+ if in == nil {
+ return nil
+ }
+ out := new(CustomSecretRotation)
+ in.DeepCopyInto(out)
+ return out
+}
+
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *DNS) DeepCopyInto(out *DNS) {
*out = *in
@@ -2733,6 +2805,80 @@ func (in *IrreconcilableValidationOverrides) DeepCopy() *IrreconcilableValidatio
return out
}
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *KMSEncryptionStatus) DeepCopyInto(out *KMSEncryptionStatus) {
+ *out = *in
+ if in.HealthReports != nil {
+ in, out := &in.HealthReports, &out.HealthReports
+ *out = make([]KMSPluginHealthReport, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ out.Preflight = in.Preflight
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KMSEncryptionStatus.
+func (in *KMSEncryptionStatus) DeepCopy() *KMSEncryptionStatus {
+ if in == nil {
+ return nil
+ }
+ out := new(KMSEncryptionStatus)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *KMSPluginHealthReport) DeepCopyInto(out *KMSPluginHealthReport) {
+ *out = *in
+ in.LastCheckedTime.DeepCopyInto(&out.LastCheckedTime)
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KMSPluginHealthReport.
+func (in *KMSPluginHealthReport) DeepCopy() *KMSPluginHealthReport {
+ if in == nil {
+ return nil
+ }
+ out := new(KMSPluginHealthReport)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *KMSPreflightCheck) DeepCopyInto(out *KMSPreflightCheck) {
+ *out = *in
+ out.Result = in.Result
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KMSPreflightCheck.
+func (in *KMSPreflightCheck) DeepCopy() *KMSPreflightCheck {
+ if in == nil {
+ return nil
+ }
+ out := new(KMSPreflightCheck)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *KMSPreflightResult) DeepCopyInto(out *KMSPreflightResult) {
+ *out = *in
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KMSPreflightResult.
+func (in *KMSPreflightResult) DeepCopy() *KMSPreflightResult {
+ if in == nil {
+ return nil
+ }
+ out := new(KMSPreflightResult)
+ in.DeepCopyInto(out)
+ return out
+}
+
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *KubeAPIServer) DeepCopyInto(out *KubeAPIServer) {
*out = *in
@@ -2822,6 +2968,7 @@ func (in *KubeAPIServerStatus) DeepCopyInto(out *KubeAPIServerStatus) {
(*in)[i].DeepCopyInto(&(*out)[i])
}
}
+ in.EncryptionStatus.DeepCopyInto(&out.EncryptionStatus)
return
}
@@ -3416,6 +3563,33 @@ func (in *ManagedBootImages) DeepCopy() *ManagedBootImages {
return out
}
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *ManagedTokenRequests) DeepCopyInto(out *ManagedTokenRequests) {
+ *out = *in
+ if in.Audiences != nil {
+ in, out := &in.Audiences, &out.Audiences
+ *out = new([]SecretsStoreTokenRequest)
+ if **in != nil {
+ in, out := *in, *out
+ *out = make([]SecretsStoreTokenRequest, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ }
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ManagedTokenRequests.
+func (in *ManagedTokenRequests) DeepCopy() *ManagedTokenRequests {
+ if in == nil {
+ return nil
+ }
+ out := new(ManagedTokenRequests)
+ in.DeepCopyInto(out)
+ return out
+}
+
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *MyOperatorResource) DeepCopyInto(out *MyOperatorResource) {
*out = *in
@@ -3665,6 +3839,22 @@ func (in *NetworkStatus) DeepCopy() *NetworkStatus {
return out
}
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *NoOverlayConfig) DeepCopyInto(out *NoOverlayConfig) {
+ *out = *in
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NoOverlayConfig.
+func (in *NoOverlayConfig) DeepCopy() *NoOverlayConfig {
+ if in == nil {
+ return nil
+ }
+ out := new(NoOverlayConfig)
+ in.DeepCopyInto(out)
+ return out
+}
+
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *NodeDisruptionPolicyClusterStatus) DeepCopyInto(out *NodeDisruptionPolicyClusterStatus) {
*out = *in
@@ -4006,6 +4196,7 @@ func (in *NodeStatus) DeepCopy() *NodeStatus {
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *OAuthAPIServerStatus) DeepCopyInto(out *OAuthAPIServerStatus) {
*out = *in
+ in.EncryptionStatus.DeepCopyInto(&out.EncryptionStatus)
return
}
@@ -4158,6 +4349,8 @@ func (in *OVNKubernetesConfig) DeepCopyInto(out *OVNKubernetesConfig) {
*out = new(IPv6OVNKubernetesConfig)
**out = **in
}
+ out.NoOverlayConfig = in.NoOverlayConfig
+ out.BGPManagedConfig = in.BGPManagedConfig
return
}
@@ -4253,6 +4446,7 @@ func (in *OpenShiftAPIServerSpec) DeepCopy() *OpenShiftAPIServerSpec {
func (in *OpenShiftAPIServerStatus) DeepCopyInto(out *OpenShiftAPIServerStatus) {
*out = *in
in.OperatorStatus.DeepCopyInto(&out.OperatorStatus)
+ in.EncryptionStatus.DeepCopyInto(&out.EncryptionStatus)
return
}
@@ -4835,6 +5029,79 @@ func (in *SFlowConfig) DeepCopy() *SFlowConfig {
return out
}
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *SecretsStoreCSIDriverConfigSpec) DeepCopyInto(out *SecretsStoreCSIDriverConfigSpec) {
+ *out = *in
+ out.SecretRotation = in.SecretRotation
+ in.TokenRequests.DeepCopyInto(&out.TokenRequests)
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SecretsStoreCSIDriverConfigSpec.
+func (in *SecretsStoreCSIDriverConfigSpec) DeepCopy() *SecretsStoreCSIDriverConfigSpec {
+ if in == nil {
+ return nil
+ }
+ out := new(SecretsStoreCSIDriverConfigSpec)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *SecretsStoreSecretRotation) DeepCopyInto(out *SecretsStoreSecretRotation) {
+ *out = *in
+ out.Custom = in.Custom
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SecretsStoreSecretRotation.
+func (in *SecretsStoreSecretRotation) DeepCopy() *SecretsStoreSecretRotation {
+ if in == nil {
+ return nil
+ }
+ out := new(SecretsStoreSecretRotation)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *SecretsStoreTokenRequest) DeepCopyInto(out *SecretsStoreTokenRequest) {
+ *out = *in
+ if in.Audience != nil {
+ in, out := &in.Audience, &out.Audience
+ *out = new(string)
+ **out = **in
+ }
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SecretsStoreTokenRequest.
+func (in *SecretsStoreTokenRequest) DeepCopy() *SecretsStoreTokenRequest {
+ if in == nil {
+ return nil
+ }
+ out := new(SecretsStoreTokenRequest)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *SecretsStoreTokenRequests) DeepCopyInto(out *SecretsStoreTokenRequests) {
+ *out = *in
+ in.Managed.DeepCopyInto(&out.Managed)
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SecretsStoreTokenRequests.
+func (in *SecretsStoreTokenRequests) DeepCopy() *SecretsStoreTokenRequests {
+ if in == nil {
+ return nil
+ }
+ out := new(SecretsStoreTokenRequests)
+ in.DeepCopyInto(out)
+ return out
+}
+
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *Server) DeepCopyInto(out *Server) {
*out = *in
diff --git a/vendor/github.com/openshift/api/operator/v1/zz_generated.featuregated-crd-manifests.yaml b/vendor/github.com/openshift/api/operator/v1/zz_generated.featuregated-crd-manifests.yaml
index 51a758804d..aab9e3564f 100644
--- a/vendor/github.com/openshift/api/operator/v1/zz_generated.featuregated-crd-manifests.yaml
+++ b/vendor/github.com/openshift/api/operator/v1/zz_generated.featuregated-crd-manifests.yaml
@@ -5,7 +5,9 @@ authentications.operator.openshift.io:
CRDName: authentications.operator.openshift.io
Capability: ""
Category: ""
- FeatureGates: []
+ FeatureGates:
+ - AuthenticationComponentProxy
+ - KMSEncryption
FilenameOperatorName: authentication
FilenameOperatorOrdering: "01"
FilenameRunLevel: "0000_50"
@@ -69,6 +71,7 @@ clustercsidrivers.operator.openshift.io:
Capability: ""
Category: ""
FeatureGates:
+ - AWSEuropeanSovereignCloudInstall
- VSphereConfigurableMaxAllowedBlockVolumesPerNode
FilenameOperatorName: csi-driver
FilenameOperatorOrdering: "01"
@@ -175,7 +178,10 @@ ingresscontrollers.operator.openshift.io:
CRDName: ingresscontrollers.operator.openshift.io
Capability: Ingress
Category: ""
- FeatureGates: []
+ FeatureGates:
+ - IngressControllerDynamicConfigurationManager
+ - IngressControllerMultipleHAProxyVersions
+ - TLSGroupPreferences
FilenameOperatorName: ingress
FilenameOperatorOrdering: "00"
FilenameRunLevel: "0000_50"
@@ -219,6 +225,7 @@ kubeapiservers.operator.openshift.io:
Category: coreoperators
FeatureGates:
- EventTTL
+ - KMSEncryption
FilenameOperatorName: kube-apiserver
FilenameOperatorOrdering: "01"
FilenameRunLevel: "0000_20"
@@ -305,8 +312,7 @@ machineconfigurations.operator.openshift.io:
FeatureGates:
- BootImageSkewEnforcement
- IrreconcilableMachineConfig
- - ManagedBootImages
- - ManagedBootImages+ManagedBootImagesCPMS
+ - ManagedBootImagesCPMS
FilenameOperatorName: machine-config
FilenameOperatorOrdering: "01"
FilenameRunLevel: "0000_80"
@@ -327,7 +333,8 @@ networks.operator.openshift.io:
CRDName: networks.operator.openshift.io
Capability: ""
Category: ""
- FeatureGates: []
+ FeatureGates:
+ - NoOverlayMode
FilenameOperatorName: network
FilenameOperatorOrdering: "01"
FilenameRunLevel: "0000_70"
@@ -373,7 +380,8 @@ openshiftapiservers.operator.openshift.io:
CRDName: openshiftapiservers.operator.openshift.io
Capability: ""
Category: coreoperators
- FeatureGates: []
+ FeatureGates:
+ - KMSEncryption
FilenameOperatorName: openshift-apiserver
FilenameOperatorOrdering: "01"
FilenameRunLevel: "0000_30"
diff --git a/vendor/github.com/openshift/api/operator/v1/zz_generated.model_name.go b/vendor/github.com/openshift/api/operator/v1/zz_generated.model_name.go
new file mode 100644
index 0000000000..13ab0c5f6f
--- /dev/null
+++ b/vendor/github.com/openshift/api/operator/v1/zz_generated.model_name.go
@@ -0,0 +1,1246 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AWSCSIDriverConfigSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.AWSCSIDriverConfigSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AWSClassicLoadBalancerParameters) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.AWSClassicLoadBalancerParameters"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AWSEFSVolumeMetrics) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.AWSEFSVolumeMetrics"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AWSEFSVolumeMetricsRecursiveWalkConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.AWSEFSVolumeMetricsRecursiveWalkConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AWSLoadBalancerParameters) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.AWSLoadBalancerParameters"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AWSNetworkLoadBalancerParameters) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.AWSNetworkLoadBalancerParameters"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AWSSubnets) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.AWSSubnets"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AccessLogging) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.AccessLogging"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AddPage) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.AddPage"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AdditionalNetworkDefinition) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.AdditionalNetworkDefinition"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AdditionalRoutingCapabilities) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.AdditionalRoutingCapabilities"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Authentication) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.Authentication"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AuthenticationConfigMapReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.AuthenticationConfigMapReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AuthenticationList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.AuthenticationList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AuthenticationProxyConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.AuthenticationProxyConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AuthenticationSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.AuthenticationSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AuthenticationStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.AuthenticationStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AzureCSIDriverConfigSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.AzureCSIDriverConfigSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AzureDiskEncryptionSet) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.AzureDiskEncryptionSet"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BGPManagedConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.BGPManagedConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BootImageSkewEnforcementConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.BootImageSkewEnforcementConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BootImageSkewEnforcementStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.BootImageSkewEnforcementStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CSIDriverConfigSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.CSIDriverConfigSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CSISnapshotController) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.CSISnapshotController"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CSISnapshotControllerList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.CSISnapshotControllerList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CSISnapshotControllerSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.CSISnapshotControllerSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CSISnapshotControllerStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.CSISnapshotControllerStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Capability) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.Capability"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CapabilityVisibility) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.CapabilityVisibility"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClientTLS) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ClientTLS"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CloudCredential) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.CloudCredential"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CloudCredentialList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.CloudCredentialList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CloudCredentialSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.CloudCredentialSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CloudCredentialStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.CloudCredentialStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterBootImageAutomatic) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ClusterBootImageAutomatic"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterBootImageManual) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ClusterBootImageManual"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterCSIDriver) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ClusterCSIDriver"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterCSIDriverList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ClusterCSIDriverList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterCSIDriverSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ClusterCSIDriverSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterCSIDriverStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ClusterCSIDriverStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterNetworkEntry) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ClusterNetworkEntry"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Config) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.Config"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConfigList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ConfigList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConfigMapFileReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ConfigMapFileReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConfigSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ConfigSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConfigStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ConfigStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Console) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.Console"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleConfigRoute) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ConsoleConfigRoute"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleCustomization) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ConsoleCustomization"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ConsoleList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleProviders) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ConsoleProviders"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ConsoleSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConsoleStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ConsoleStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ContainerLoggingDestinationParameters) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ContainerLoggingDestinationParameters"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in CustomSecretRotation) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.CustomSecretRotation"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DNS) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.DNS"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DNSCache) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.DNSCache"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DNSList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.DNSList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DNSNodePlacement) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.DNSNodePlacement"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DNSOverTLSConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.DNSOverTLSConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DNSSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.DNSSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DNSStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.DNSStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DNSTransportConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.DNSTransportConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DefaultNetworkDefinition) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.DefaultNetworkDefinition"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DeveloperConsoleCatalogCategory) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.DeveloperConsoleCatalogCategory"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DeveloperConsoleCatalogCategoryMeta) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.DeveloperConsoleCatalogCategoryMeta"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DeveloperConsoleCatalogCustomization) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.DeveloperConsoleCatalogCustomization"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DeveloperConsoleCatalogTypes) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.DeveloperConsoleCatalogTypes"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EgressIPConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.EgressIPConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EndpointPublishingStrategy) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.EndpointPublishingStrategy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Etcd) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.Etcd"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EtcdList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.EtcdList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EtcdSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.EtcdSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EtcdStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.EtcdStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ExportNetworkFlows) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ExportNetworkFlows"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in FeaturesMigration) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.FeaturesMigration"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in FileReferenceSource) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.FileReferenceSource"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ForwardPlugin) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ForwardPlugin"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GCPCSIDriverConfigSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.GCPCSIDriverConfigSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GCPKMSKeyReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.GCPKMSKeyReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GCPLoadBalancerParameters) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.GCPLoadBalancerParameters"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GatewayConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.GatewayConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GatherStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.GatherStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GathererStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.GathererStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GenerationStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.GenerationStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in HTTPCompressionPolicy) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.HTTPCompressionPolicy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in HealthCheck) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.HealthCheck"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in HostNetworkStrategy) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.HostNetworkStrategy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in HybridOverlayConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.HybridOverlayConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IBMCloudCSIDriverConfigSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.IBMCloudCSIDriverConfigSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IBMLoadBalancerParameters) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.IBMLoadBalancerParameters"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IPAMConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.IPAMConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IPFIXConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.IPFIXConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IPsecConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.IPsecConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IPsecFullModeConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.IPsecFullModeConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IPv4GatewayConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.IPv4GatewayConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IPv4OVNKubernetesConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.IPv4OVNKubernetesConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IPv6GatewayConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.IPv6GatewayConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IPv6OVNKubernetesConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.IPv6OVNKubernetesConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Ingress) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.Ingress"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IngressController) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.IngressController"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IngressControllerCaptureHTTPCookie) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.IngressControllerCaptureHTTPCookie"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IngressControllerCaptureHTTPCookieUnion) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.IngressControllerCaptureHTTPCookieUnion"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IngressControllerCaptureHTTPHeader) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.IngressControllerCaptureHTTPHeader"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IngressControllerCaptureHTTPHeaders) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.IngressControllerCaptureHTTPHeaders"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IngressControllerHTTPHeader) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.IngressControllerHTTPHeader"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IngressControllerHTTPHeaderActionUnion) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.IngressControllerHTTPHeaderActionUnion"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IngressControllerHTTPHeaderActions) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.IngressControllerHTTPHeaderActions"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IngressControllerHTTPHeaders) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.IngressControllerHTTPHeaders"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IngressControllerHTTPUniqueIdHeaderPolicy) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.IngressControllerHTTPUniqueIdHeaderPolicy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IngressControllerList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.IngressControllerList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IngressControllerLogging) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.IngressControllerLogging"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IngressControllerSetHTTPHeader) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.IngressControllerSetHTTPHeader"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IngressControllerSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.IngressControllerSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IngressControllerStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.IngressControllerStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IngressControllerTuningOptions) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.IngressControllerTuningOptions"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in InsightsOperator) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.InsightsOperator"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in InsightsOperatorList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.InsightsOperatorList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in InsightsOperatorSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.InsightsOperatorSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in InsightsOperatorStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.InsightsOperatorStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in InsightsReport) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.InsightsReport"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IrreconcilableValidationOverrides) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.IrreconcilableValidationOverrides"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KMSEncryptionStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.KMSEncryptionStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KMSPluginHealthReport) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.KMSPluginHealthReport"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KMSPreflightCheck) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.KMSPreflightCheck"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KMSPreflightResult) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.KMSPreflightResult"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KubeAPIServer) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.KubeAPIServer"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KubeAPIServerList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.KubeAPIServerList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KubeAPIServerSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.KubeAPIServerSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KubeAPIServerStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.KubeAPIServerStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KubeControllerManager) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.KubeControllerManager"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KubeControllerManagerList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.KubeControllerManagerList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KubeControllerManagerSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.KubeControllerManagerSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KubeControllerManagerStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.KubeControllerManagerStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KubeScheduler) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.KubeScheduler"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KubeSchedulerList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.KubeSchedulerList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KubeSchedulerSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.KubeSchedulerSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KubeSchedulerStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.KubeSchedulerStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KubeStorageVersionMigrator) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.KubeStorageVersionMigrator"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KubeStorageVersionMigratorList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.KubeStorageVersionMigratorList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KubeStorageVersionMigratorSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.KubeStorageVersionMigratorSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KubeStorageVersionMigratorStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.KubeStorageVersionMigratorStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in LoadBalancerStrategy) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.LoadBalancerStrategy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in LoggingDestination) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.LoggingDestination"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Logo) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.Logo"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MTUMigration) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.MTUMigration"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MTUMigrationValues) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.MTUMigrationValues"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MachineConfiguration) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.MachineConfiguration"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MachineConfigurationList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.MachineConfigurationList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MachineConfigurationSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.MachineConfigurationSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MachineConfigurationStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.MachineConfigurationStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MachineManager) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.MachineManager"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MachineManagerSelector) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.MachineManagerSelector"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ManagedBootImages) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ManagedBootImages"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ManagedTokenRequests) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ManagedTokenRequests"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MyOperatorResource) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.MyOperatorResource"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MyOperatorResourceSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.MyOperatorResourceSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in MyOperatorResourceStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.MyOperatorResourceStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NetFlowConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.NetFlowConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Network) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.Network"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NetworkList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.NetworkList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NetworkMigration) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.NetworkMigration"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NetworkSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.NetworkSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NetworkStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.NetworkStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NoOverlayConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.NoOverlayConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeDisruptionPolicyClusterStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.NodeDisruptionPolicyClusterStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeDisruptionPolicyConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.NodeDisruptionPolicyConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeDisruptionPolicySpecAction) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.NodeDisruptionPolicySpecAction"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeDisruptionPolicySpecFile) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.NodeDisruptionPolicySpecFile"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeDisruptionPolicySpecSSHKey) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.NodeDisruptionPolicySpecSSHKey"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeDisruptionPolicySpecUnit) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.NodeDisruptionPolicySpecUnit"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeDisruptionPolicyStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.NodeDisruptionPolicyStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeDisruptionPolicyStatusAction) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.NodeDisruptionPolicyStatusAction"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeDisruptionPolicyStatusFile) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.NodeDisruptionPolicyStatusFile"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeDisruptionPolicyStatusSSHKey) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.NodeDisruptionPolicyStatusSSHKey"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeDisruptionPolicyStatusUnit) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.NodeDisruptionPolicyStatusUnit"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodePlacement) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.NodePlacement"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodePortStrategy) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.NodePortStrategy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.NodeStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OAuthAPIServerStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.OAuthAPIServerStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OLM) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.OLM"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OLMList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.OLMList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OLMSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.OLMSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OLMStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.OLMStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OVNKubernetesConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.OVNKubernetesConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OpenShiftAPIServer) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.OpenShiftAPIServer"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OpenShiftAPIServerList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.OpenShiftAPIServerList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OpenShiftAPIServerSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.OpenShiftAPIServerSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OpenShiftAPIServerStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.OpenShiftAPIServerStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OpenShiftControllerManager) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.OpenShiftControllerManager"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OpenShiftControllerManagerList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.OpenShiftControllerManagerList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OpenShiftControllerManagerSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.OpenShiftControllerManagerSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OpenShiftControllerManagerStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.OpenShiftControllerManagerStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OpenShiftSDNConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.OpenShiftSDNConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OpenStackLoadBalancerParameters) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.OpenStackLoadBalancerParameters"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OperatorCondition) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.OperatorCondition"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OperatorSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.OperatorSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OperatorStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.OperatorStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PartialSelector) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.PartialSelector"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Perspective) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.Perspective"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PerspectiveVisibility) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.PerspectiveVisibility"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PinnedResourceReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.PinnedResourceReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PolicyAuditConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.PolicyAuditConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PrivateStrategy) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.PrivateStrategy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ProjectAccess) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ProjectAccess"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ProviderLoadBalancerParameters) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ProviderLoadBalancerParameters"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ProxyConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ProxyConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in QuickStarts) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.QuickStarts"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ReloadService) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ReloadService"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ResourceAttributesAccessReview) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ResourceAttributesAccessReview"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RestartService) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.RestartService"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RouteAdmissionPolicy) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.RouteAdmissionPolicy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SFlowConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.SFlowConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SecretsStoreCSIDriverConfigSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.SecretsStoreCSIDriverConfigSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SecretsStoreSecretRotation) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.SecretsStoreSecretRotation"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SecretsStoreTokenRequest) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.SecretsStoreTokenRequest"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SecretsStoreTokenRequests) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.SecretsStoreTokenRequests"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Server) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.Server"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ServiceAccountIssuerStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ServiceAccountIssuerStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ServiceCA) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ServiceCA"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ServiceCAList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ServiceCAList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ServiceCASpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ServiceCASpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ServiceCAStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ServiceCAStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ServiceCatalogAPIServer) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ServiceCatalogAPIServer"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ServiceCatalogAPIServerList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ServiceCatalogAPIServerList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ServiceCatalogAPIServerSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ServiceCatalogAPIServerSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ServiceCatalogAPIServerStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ServiceCatalogAPIServerStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ServiceCatalogControllerManager) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ServiceCatalogControllerManager"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ServiceCatalogControllerManagerList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ServiceCatalogControllerManagerList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ServiceCatalogControllerManagerSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ServiceCatalogControllerManagerSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ServiceCatalogControllerManagerStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.ServiceCatalogControllerManagerStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SimpleMacvlanConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.SimpleMacvlanConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in StaticIPAMAddresses) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.StaticIPAMAddresses"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in StaticIPAMConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.StaticIPAMConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in StaticIPAMDNS) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.StaticIPAMDNS"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in StaticIPAMRoutes) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.StaticIPAMRoutes"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in StaticPodOperatorSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.StaticPodOperatorSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in StaticPodOperatorStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.StaticPodOperatorStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in StatuspageProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.StatuspageProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Storage) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.Storage"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in StorageList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.StorageList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in StorageSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.StorageSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in StorageStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.StorageStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SyslogLoggingDestinationParameters) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.SyslogLoggingDestinationParameters"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Theme) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.Theme"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Upstream) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.Upstream"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in UpstreamResolvers) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.UpstreamResolvers"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in VSphereCSIDriverConfigSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1.VSphereCSIDriverConfigSpec"
+}
diff --git a/vendor/github.com/openshift/api/operator/v1/zz_generated.swagger_doc_generated.go b/vendor/github.com/openshift/api/operator/v1/zz_generated.swagger_doc_generated.go
index 64aac26eb3..27e0916168 100644
--- a/vendor/github.com/openshift/api/operator/v1/zz_generated.swagger_doc_generated.go
+++ b/vendor/github.com/openshift/api/operator/v1/zz_generated.swagger_doc_generated.go
@@ -37,6 +37,7 @@ func (MyOperatorResource) SwaggerDoc() map[string]string {
var map_NodeStatus = map[string]string{
"": "NodeStatus provides information about the current state of a particular node managed by this operator.",
"nodeName": "nodeName is the name of the node",
+ "nodeUID": "nodeUID is the UID of the node. This field is used to detect that a node has been deleted and recreated with the same name. When the UID changes, it indicates the node is a new instance and the controller should treat this status entry as stale. When omitted, UID-based node replacement detection is not available for this entry.",
"currentRevision": "currentRevision is the generation of the most recently successful deployment. Can not be set on creation of a nodeStatus. Updates must only increase the value.",
"targetRevision": "targetRevision is the generation of the deployment we're trying to apply. Can not be set on creation of a nodeStatus.",
"lastFailedRevision": "lastFailedRevision is the generation of the deployment we tried and failed to deploy.",
@@ -118,6 +119,15 @@ func (Authentication) SwaggerDoc() map[string]string {
return map_Authentication
}
+var map_AuthenticationConfigMapReference = map[string]string{
+ "": "AuthenticationConfigMapReference references a ConfigMap in the openshift-config namespace.",
+ "name": "name is the metadata.name of the referenced ConfigMap. Must be a valid DNS subdomain name (RFC 1123): at most 253 characters, only lowercase alphanumeric characters, '-' or '.', starting and ending with an alphanumeric character.",
+}
+
+func (AuthenticationConfigMapReference) SwaggerDoc() map[string]string {
+ return map_AuthenticationConfigMapReference
+}
+
var map_AuthenticationList = map[string]string{
"": "AuthenticationList is a collection of items\n\nCompatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer).",
"metadata": "metadata is the standard list's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata",
@@ -127,6 +137,26 @@ func (AuthenticationList) SwaggerDoc() map[string]string {
return map_AuthenticationList
}
+var map_AuthenticationProxyConfig = map[string]string{
+ "": "AuthenticationProxyConfig holds proxy configuration scoped to authentication components (the OAuth server and the cluster authentication operator).",
+ "httpProxy": "httpProxy is the URL of the proxy for HTTP requests. Must be a valid URL with http or https scheme, a non-empty hostname, and no path, query parameters, or fragment. Userinfo (e.g. user:password@host) is allowed for proxy authentication. Maximum length is 2048 characters.",
+ "httpsProxy": "httpsProxy is the URL of the proxy for HTTPS requests. Must be a valid URL with http or https scheme, a non-empty hostname, and no path, query parameters, or fragment. Userinfo (e.g. user:password@host) is allowed for proxy authentication. Maximum length is 2048 characters.",
+ "noProxy": "noProxy is a list of hostnames and/or CIDRs and/or IPs for which the proxy should not be used. Must contain at least one entry when set. Each entry must be between 1 and 253 characters long and at most 64 entries are allowed. Duplicate entries are not permitted. Entries that are not valid hostnames, CIDRs, or IPs are silently ignored. Cluster-internal defaults (.cluster.local, .svc, 127.0.0.1, localhost) are always appended automatically and do not need to be included.",
+ "trustedCA": "trustedCA is a reference to a ConfigMap in the openshift-config namespace containing a CA certificate bundle under the key \"ca-bundle.crt\". This bundle is appended to the system trust store used by authentication components for proxy TLS connections. When omitted, only the system trust store is used.",
+}
+
+func (AuthenticationProxyConfig) SwaggerDoc() map[string]string {
+ return map_AuthenticationProxyConfig
+}
+
+var map_AuthenticationSpec = map[string]string{
+ "proxy": "proxy configures proxy settings for outbound connections made by the authentication stack. When set, it replaces the cluster-wide proxy (proxy.config.openshift.io/cluster) entirely for authentication — individual fields are not inherited from the cluster-wide configuration. When omitted, the cluster-wide proxy is used if configured; otherwise no proxy is used.",
+}
+
+func (AuthenticationSpec) SwaggerDoc() map[string]string {
+ return map_AuthenticationSpec
+}
+
var map_AuthenticationStatus = map[string]string{
"oauthAPIServer": "oauthAPIServer holds status specific only to oauth-apiserver",
}
@@ -137,6 +167,7 @@ func (AuthenticationStatus) SwaggerDoc() map[string]string {
var map_OAuthAPIServerStatus = map[string]string{
"latestAvailableRevision": "latestAvailableRevision is the latest revision used as suffix of revisioned secrets like encryption-config. A new revision causes a new deployment of pods.",
+ "encryptionStatus": "encryptionStatus contains status reports for the KMS plugin health and its key rotation.",
}
func (OAuthAPIServerStatus) SwaggerDoc() map[string]string {
@@ -466,7 +497,7 @@ func (Theme) SwaggerDoc() map[string]string {
var map_AWSCSIDriverConfigSpec = map[string]string{
"": "AWSCSIDriverConfigSpec defines properties that can be configured for the AWS CSI driver.",
- "kmsKeyARN": "kmsKeyARN sets the cluster default storage class to encrypt volumes with a user-defined KMS key, rather than the default KMS key used by AWS. The value may be either the ARN or Alias ARN of a KMS key.",
+ "kmsKeyARN": "kmsKeyARN sets the cluster default storage class to encrypt volumes with a user-defined KMS key, rather than the default KMS key used by AWS. The value may be either the ARN or Alias ARN of a KMS key.\n\nThe ARN must follow the format: arn::kms:::(key|alias)/, where: is the AWS partition (aws, aws-cn, aws-us-gov, aws-iso, aws-iso-b, aws-iso-e, aws-iso-f, or aws-eusc), is the AWS region, is a 12-digit numeric identifier for the AWS account, is the KMS key ID or alias name.",
"efsVolumeMetrics": "efsVolumeMetrics sets the configuration for collecting metrics from EFS volumes used by the EFS CSI Driver.",
}
@@ -515,13 +546,14 @@ func (AzureDiskEncryptionSet) SwaggerDoc() map[string]string {
}
var map_CSIDriverConfigSpec = map[string]string{
- "": "CSIDriverConfigSpec defines configuration spec that can be used to optionally configure a specific CSI Driver.",
- "driverType": "driverType indicates type of CSI driver for which the driverConfig is being applied to. Valid values are: AWS, Azure, GCP, IBMCloud, vSphere and omitted. Consumers should treat unknown values as a NO-OP.",
- "aws": "aws is used to configure the AWS CSI driver.",
- "azure": "azure is used to configure the Azure CSI driver.",
- "gcp": "gcp is used to configure the GCP CSI driver.",
- "ibmcloud": "ibmcloud is used to configure the IBM Cloud CSI driver.",
- "vSphere": "vSphere is used to configure the vsphere CSI driver.",
+ "": "CSIDriverConfigSpec defines configuration spec that can be used to optionally configure a specific CSI Driver.",
+ "driverType": "driverType indicates type of CSI driver for which the driverConfig is being applied to. Valid values are: AWS, Azure, GCP, IBMCloud, vSphere, SecretsStore and omitted. Consumers should treat unknown values as a NO-OP.",
+ "aws": "aws is used to configure the AWS CSI driver.",
+ "azure": "azure is used to configure the Azure CSI driver.",
+ "gcp": "gcp is used to configure the GCP CSI driver.",
+ "ibmcloud": "ibmcloud is used to configure the IBM Cloud CSI driver.",
+ "vSphere": "vSphere is used to configure the vsphere CSI driver.",
+ "secretsStore": "secretsStore is used to configure the Secrets Store CSI driver.",
}
func (CSIDriverConfigSpec) SwaggerDoc() map[string]string {
@@ -566,6 +598,15 @@ func (ClusterCSIDriverStatus) SwaggerDoc() map[string]string {
return map_ClusterCSIDriverStatus
}
+var map_CustomSecretRotation = map[string]string{
+ "": "CustomSecretRotation holds configuration for custom secret rotation behavior.",
+ "minimumRefreshAge": "minimumRefreshAge is the minimum time in seconds between secret rotation attempts. Each time kubelet calls NodePublishVolume, the driver checks whether this interval has elapsed since the last successful provider call. If it has, the driver contacts the secret provider to fetch the latest secret values and updates the mounted volume. Setting this value below the kubelet syncFrequency (default: 1 minute) has no additional effect on the actual rotation cadence. Must be at least 1 second and no more than 31560000 seconds (~1 year). When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.",
+}
+
+func (CustomSecretRotation) SwaggerDoc() map[string]string {
+ return map_CustomSecretRotation
+}
+
var map_GCPCSIDriverConfigSpec = map[string]string{
"": "GCPCSIDriverConfigSpec defines properties that can be configured for the GCP CSI driver.",
"kmsKey": "kmsKey sets the cluster default storage class to encrypt volumes with customer-supplied encryption keys, rather than the default keys managed by GCP.",
@@ -596,6 +637,55 @@ func (IBMCloudCSIDriverConfigSpec) SwaggerDoc() map[string]string {
return map_IBMCloudCSIDriverConfigSpec
}
+var map_ManagedTokenRequests = map[string]string{
+ "": "ManagedTokenRequests holds the configuration for operator-managed service account token requests.",
+ "audiences": "audiences specifies service account token audiences that kubelet will provide to the CSI driver during NodePublishVolume calls. These tokens enable workload identity federation (WIF) with cloud providers such as AWS, Azure, and GCP. When empty, the operator clears all tokenRequests from the CSIDriver object.",
+}
+
+func (ManagedTokenRequests) SwaggerDoc() map[string]string {
+ return map_ManagedTokenRequests
+}
+
+var map_SecretsStoreCSIDriverConfigSpec = map[string]string{
+ "": "SecretsStoreCSIDriverConfigSpec defines properties that can be configured for the Secrets Store CSI driver.",
+ "secretRotation": "secretRotation controls automatic secret rotation behavior. When omitted, secret rotation is enabled with a default poll interval of 2 minutes.",
+ "tokenRequests": "tokenRequests controls service account token configuration for workload identity federation (WIF) with cloud providers. When omitted, the operator preserves any existing tokenRequests already configured on the CSIDriver object without modification.",
+}
+
+func (SecretsStoreCSIDriverConfigSpec) SwaggerDoc() map[string]string {
+ return map_SecretsStoreCSIDriverConfigSpec
+}
+
+var map_SecretsStoreSecretRotation = map[string]string{
+ "": "SecretsStoreSecretRotation configures the automatic secret rotation behavior for the Secrets Store CSI driver.",
+ "type": "type determines the secret rotation behavior. When \"None\", secret rotation is disabled and secrets are only fetched at initial pod mount time. When \"Custom\", secret rotation is enabled with the configuration specified in the custom field.",
+ "custom": "custom holds the custom rotation configuration. Only valid when type is \"Custom\".",
+}
+
+func (SecretsStoreSecretRotation) SwaggerDoc() map[string]string {
+ return map_SecretsStoreSecretRotation
+}
+
+var map_SecretsStoreTokenRequest = map[string]string{
+ "": "SecretsStoreTokenRequest specifies a service account token audience configuration for workload identity federation (WIF) with the Secrets Store CSI driver.",
+ "audience": "audience is the intended audience of the service account token. An empty string means the issued token will use the kube-apiserver's default APIAudiences.",
+ "expirationSeconds": "expirationSeconds is the requested duration of validity of the service account token. The token issuer may return a token with a different validity duration. When omitted, the token expiration is determined by the kube-apiserver. Must be at least 600 seconds (10 minutes) and no more than 315360000 seconds (~10 years).",
+}
+
+func (SecretsStoreTokenRequest) SwaggerDoc() map[string]string {
+ return map_SecretsStoreTokenRequest
+}
+
+var map_SecretsStoreTokenRequests = map[string]string{
+ "": "SecretsStoreTokenRequests configures how service account tokens are provided to the Secrets Store CSI driver for workload identity federation.",
+ "type": "type determines how the operator manages tokenRequests on the CSIDriver object. When \"Unmanaged\", existing tokenRequests on the CSIDriver are preserved and the managed field is not used. When \"Managed\", the operator sets tokenRequests from the audiences specified in the managed field, replacing any previously configured values. Once set to \"Managed\", type cannot be reverted back to \"Unmanaged\".",
+ "managed": "managed holds configuration for operator-managed tokenRequests. Only valid when type is \"Managed\".",
+}
+
+func (SecretsStoreTokenRequests) SwaggerDoc() map[string]string {
+ return map_SecretsStoreTokenRequests
+}
+
var map_VSphereCSIDriverConfigSpec = map[string]string{
"": "VSphereCSIDriverConfigSpec defines properties that can be configured for vsphere CSI driver.",
"topologyCategories": "topologyCategories indicates tag categories with which vcenter resources such as hostcluster or datacenter were tagged with. If cluster Infrastructure object has a topology, values specified in Infrastructure object will be used and modifications to topologyCategories will be rejected.",
@@ -798,7 +888,7 @@ func (EtcdList) SwaggerDoc() map[string]string {
var map_EtcdSpec = map[string]string{
"controlPlaneHardwareSpeed": "HardwareSpeed allows user to change the etcd tuning profile which configures the latency parameters for heartbeat interval and leader election timeouts allowing the cluster to tolerate longer round-trip-times between etcd members. Valid values are \"\", \"Standard\" and \"Slower\".\n\t\"\" means no opinion and the platform is left to choose a reasonable default\n\twhich is subject to change without notice.",
- "backendQuotaGiB": "backendQuotaGiB sets the etcd backend storage size limit in gibibytes. The value should be an integer not less than 8 and not more than 32. When not specified, the default value is 8.",
+ "backendQuotaGiB": "backendQuotaGiB sets the etcd backend storage size limit in gibibytes. The value should be an integer not less than 8 and not more than 16. When not specified, the default value is 8.",
}
func (EtcdSpec) SwaggerDoc() map[string]string {
@@ -830,6 +920,7 @@ var map_AWSNetworkLoadBalancerParameters = map[string]string{
"": "AWSNetworkLoadBalancerParameters holds configuration parameters for an AWS Network load balancer. For Example: Setting AWS EIPs https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/elastic-ip-addresses-eip.html",
"subnets": "subnets specifies the subnets to which the load balancer will attach. The subnets may be specified by either their ID or name. The total number of subnets is limited to 10.\n\nIn order for the load balancer to be provisioned with subnets, each subnet must exist, each subnet must be from a different availability zone, and the load balancer service must be recreated to pick up new values.\n\nWhen omitted from the spec, the subnets will be auto-discovered for each availability zone. Auto-discovered subnets are not reported in the status of the IngressController object.",
"eipAllocations": "eipAllocations is a list of IDs for Elastic IP (EIP) addresses that are assigned to the Network Load Balancer. The following restrictions apply:\n\neipAllocations can only be used with external scope, not internal. An EIP can be allocated to only a single IngressController. The number of EIP allocations must match the number of subnets that are used for the load balancer. Each EIP allocation must be unique. A maximum of 10 EIP allocations are permitted.\n\nSee https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/elastic-ip-addresses-eip.html for general information about configuration, characteristics, and limitations of Elastic IP addresses.",
+ "protocol": "protocol specifies whether the Network Load Balancer uses PROXY protocol to forward connections to the IngressController.\n\nWhen set to \"TCP\", the NLB uses AWS's native client IP preservation. This may cause hairpin connection failures for internal load balancers when connections are made from pods to router pods on the same node.\n\nWhen set to \"PROXY\", the NLB disables native client IP preservation and uses PROXY protocol v2. The IngressController enables PROXY protocol on HAProxy so that it can parse PROXY protocol headers to obtain the original client IP. This avoids hairpin connection failures.\n\nThe following values are valid for this field:\n\n* \"TCP\". * \"PROXY\".\n\nWhen omitted, this means the user has no opinion and the value is left to the platform to choose a reasonable default, which is subject to change over time. The current default is \"PROXY\".\n\nNote that changing this field may cause brief connection failures during the transition as the NLB attribute change and router rollout occur independently.",
}
func (AWSNetworkLoadBalancerParameters) SwaggerDoc() map[string]string {
@@ -1082,6 +1173,7 @@ var map_IngressControllerSpec = map[string]string{
"httpCompression": "httpCompression defines a policy for HTTP traffic compression. By default, there is no HTTP compression.",
"idleConnectionTerminationPolicy": "idleConnectionTerminationPolicy maps directly to HAProxy's idle-close-on-response option and controls whether HAProxy keeps idle frontend connections open during a soft stop (router reload).\n\nAllowed values for this field are \"Immediate\" and \"Deferred\". The default value is \"Immediate\".\n\nWhen set to \"Immediate\", idle connections are closed immediately during router reloads. This ensures immediate propagation of route changes but may impact clients sensitive to connection resets.\n\nWhen set to \"Deferred\", HAProxy will maintain idle connections during a soft reload instead of closing them immediately. These connections remain open until any of the following occurs:\n\n - A new request is received on the connection, in which\n case HAProxy handles it in the old process and closes\n the connection after sending the response.\n\n - HAProxy's `timeout http-keep-alive` duration expires.\n By default this is 300 seconds, but it can be changed\n using httpKeepAliveTimeout tuning option.\n\n - The client's keep-alive timeout expires, causing the\n client to close the connection.\n\nSetting Deferred can help prevent errors in clients or load balancers that do not properly handle connection resets. Additionally, this option allows you to retain the pre-2.4 HAProxy behaviour: in HAProxy version 2.2 (OpenShift versions < 4.14), maintaining idle connections during a soft reload was the default behaviour, but starting with HAProxy 2.4, the default changed to closing idle connections immediately.\n\nImportant Consideration:\n\n - Using Deferred will result in temporary inconsistencies\n for the first request on each persistent connection\n after a route update and router reload. This request\n will be processed by the old HAProxy process using its\n old configuration. Subsequent requests will use the\n updated configuration.\n\nOperational Considerations:\n\n - Keeping idle connections open during reloads may lead\n to an accumulation of old HAProxy processes if\n connections remain idle for extended periods,\n especially in environments where frequent reloads\n occur.\n\n - Consider monitoring the number of HAProxy processes in\n the router pods when Deferred is set.\n\n - You may need to enable or adjust the\n `ingress.operator.openshift.io/hard-stop-after`\n duration (configured via an annotation on the\n IngressController resource) in environments with\n frequent reloads to prevent resource exhaustion.",
"closedClientConnectionPolicy": "closedClientConnectionPolicy controls how the IngressController behaves when the client closes the TCP connection while the TLS handshake or HTTP request is in progress. This option maps directly to HAProxy’s \"abortonclose\" option.\n\nValid values are: \"Abort\" and \"Continue\". The default value is \"Continue\".\n\nWhen set to \"Abort\", the router will stop processing the TLS handshake if it is in progress, and it will not send an HTTP request to the backend server if the request has not yet been sent when the client closes the connection.\n\nWhen set to \"Continue\", the router will complete the TLS handshake if it is in progress, or send an HTTP request to the backend server and wait for the backend server's response, regardless of whether the client has closed the connection.\n\nSetting \"Abort\" can help free CPU resources otherwise spent on TLS computation for connections the client has already closed, and can reduce request queue size, thereby reducing the load on saturated backend servers.\n\nImportant Considerations:\n\n - The default policy (\"Continue\") is HTTP-compliant, and requests\n for aborted client connections will still be served.\n Use the \"Continue\" policy to allow a client to send a request\n and then immediately close its side of the connection while\n still receiving a response on the half-closed connection.\n\n - When clients use keep-alive connections, the most common case for premature\n closure is when the user wants to cancel the transfer or when a timeout\n occurs. In that case, the \"Abort\" policy may be used to reduce resource consumption.\n\n - Using RSA keys larger than 2048 bits can significantly slow down\n TLS computations. Consider using the \"Abort\" policy to reduce CPU usage.",
+ "haproxyVersion": "haproxyVersion specifies the HAProxy version to use for this IngressController.\n\nOpenShift 5.0 introduces HAProxy 3.2 as its default version and supports HAProxy 2.8 from OpenShift 4.22 for migration purposes. When an OpenShift release introduces a new default HAProxy version, that HAProxy version becomes available as a pinnable value in subsequent OpenShift releases, providing a smooth migration path for administrators who want to defer HAProxy upgrades.\n\nValid values for OpenShift 5.0: - Unset (default): Uses HAProxy 3.2 (the default for OpenShift 5.0) - \"3.2\": Explicitly pins HAProxy 3.2 for preservation during cluster\n upgrades to future OpenShift releases\n- \"2.8\": Uses HAProxy 2.8 from OpenShift 4.22 (migration support, will\n be dropped in the next OpenShift release)\n\nIf a specific HAProxy version is set and would become unsupported in a target cluster upgrade, a preflight check will block the cluster upgrade until this field is updated to unset or a supported version.",
}
func (IngressControllerSpec) SwaggerDoc() map[string]string {
@@ -1099,6 +1191,7 @@ var map_IngressControllerStatus = map[string]string{
"observedGeneration": "observedGeneration is the most recent generation observed.",
"namespaceSelector": "namespaceSelector is the actual namespaceSelector in use.",
"routeSelector": "routeSelector is the actual routeSelector in use.",
+ "effectiveHAProxyVersion": "effectiveHAProxyVersion reports the HAProxy version currently in use by this IngressController. This reflects the resolved value of the spec.haproxyVersion field. When omitted, the effective value has not yet been resolved by the operator or the feature is not enabled for this cluster.\n\nExamples for OpenShift 5.0: - \"3.2\": Using HAProxy 3.2 - \"2.8\": Using HAProxy 2.8",
}
func (IngressControllerStatus) SwaggerDoc() map[string]string {
@@ -1121,6 +1214,7 @@ var map_IngressControllerTuningOptions = map[string]string{
"healthCheckInterval": "healthCheckInterval defines how long the router waits between two consecutive health checks on its configured backends. This value is applied globally as a default for all routes, but may be overridden per-route by the route annotation \"router.openshift.io/haproxy.health.check.interval\".\n\nExpects an unsigned duration string of decimal numbers, each with optional fraction and a unit suffix, eg \"300ms\", \"1.5h\" or \"2h45m\". Valid time units are \"ns\", \"us\" (or \"µs\" U+00B5 or \"μs\" U+03BC), \"ms\", \"s\", \"m\", \"h\".\n\nSetting this to less than 5s can cause excess traffic due to too frequent TCP health checks and accompanying SYN packet storms. Alternatively, setting this too high can result in increased latency, due to backend servers that are no longer available, but haven't yet been detected as such.\n\nAn empty or zero healthCheckInterval means no opinion and IngressController chooses a default, which is subject to change over time. Currently the default healthCheckInterval value is 5s.\n\nCurrently the minimum allowed value is 1s and the maximum allowed value is 2147483647ms (24.85 days). Both are subject to change over time.",
"maxConnections": "maxConnections defines the maximum number of simultaneous connections that can be established per HAProxy process. Increasing this value allows each ingress controller pod to handle more connections but at the cost of additional system resources being consumed.\n\nPermitted values are: empty, 0, -1, and the range 2000-2000000.\n\nIf this field is empty or 0, the IngressController will use the default value of 50000, but the default is subject to change in future releases.\n\nIf the value is -1 then HAProxy will dynamically compute a maximum value based on the available ulimits in the running container. Selecting -1 (i.e., auto) will result in a large value being computed (~520000 on OpenShift >=4.10 clusters) and therefore each HAProxy process will incur significant memory usage compared to the current default of 50000.\n\nSetting a value that is greater than the current operating system limit will prevent the HAProxy process from starting.\n\nIf you choose a discrete value (e.g., 750000) and the router pod is migrated to a new node, there's no guarantee that that new node has identical ulimits configured. In such a scenario the pod would fail to start. If you have nodes with different ulimits configured (e.g., different tuned profiles) and you choose a discrete value then the guidance is to use -1 and let the value be computed dynamically at runtime.\n\nYou can monitor memory usage for router containers with the following metric: 'container_memory_working_set_bytes{container=\"router\",namespace=\"openshift-ingress\"}'.\n\nYou can monitor memory usage of individual HAProxy processes in router containers with the following metric: 'container_memory_working_set_bytes{container=\"router\",namespace=\"openshift-ingress\"}/container_processes{container=\"router\",namespace=\"openshift-ingress\"}'.",
"reloadInterval": "reloadInterval defines the minimum interval at which the router is allowed to reload to accept new changes. Increasing this value can prevent the accumulation of HAProxy processes, depending on the scenario. Increasing this interval can also lessen load imbalance on a backend's servers when using the roundrobin balancing algorithm. Alternatively, decreasing this value may decrease latency since updates to HAProxy's configuration can take effect more quickly.\n\nThe value must be a time duration value; see . Currently, the minimum value allowed is 1s, and the maximum allowed value is 120s. Minimum and maximum allowed values may change in future versions of OpenShift. Note that if a duration outside of these bounds is provided, the value of reloadInterval will be capped/floored and not rejected (e.g. a duration of over 120s will be capped to 120s; the IngressController will not reject and replace this disallowed value with the default).\n\nA zero value for reloadInterval tells the IngressController to choose the default, which is currently 5s and subject to change without notice.\n\nThis field expects an unsigned duration string of decimal numbers, each with optional fraction and a unit suffix, e.g. \"300ms\", \"1.5h\" or \"2h45m\". Valid time units are \"ns\", \"us\" (or \"µs\" U+00B5 or \"μs\" U+03BC), \"ms\", \"s\", \"m\", \"h\".\n\nNote: Setting a value significantly larger than the default of 5s can cause latency in observing updates to routes and their endpoints. HAProxy's configuration will be reloaded less frequently, and newly created routes will not be served until the subsequent reload.",
+ "configurationManagement": "configurationManagement specifies how OpenShift router should update the HAProxy configuration. The following values are valid for this field:\n\n* \"ForkAndReload\". * \"Dynamic\".\n\nOmitting this field means that the user has no opinion and the platform may choose a reasonable default. This default is subject to change over time. The current default is \"ForkAndReload\".\n\n\"ForkAndReload\" means that OpenShift router should rewrite the HAProxy configuration file and instruct HAProxy to fork and reload. This is OpenShift router's traditional approach.\n\n\"Dynamic\" means that OpenShift router may use HAProxy's control socket for some configuration updates and fall back to fork and reload for other configuration updates. This is a newer approach, which may be less mature than ForkAndReload. This setting can improve load-balancing fairness and metrics accuracy and reduce CPU and memory usage if HAProxy has frequent configuration updates for route and endpoints updates.\n\nNote: The \"Dynamic\" option is currently experimental and should not be enabled on production clusters.",
}
func (IngressControllerTuningOptions) SwaggerDoc() map[string]string {
@@ -1295,6 +1389,49 @@ func (InsightsReport) SwaggerDoc() map[string]string {
return map_InsightsReport
}
+var map_KMSEncryptionStatus = map[string]string{
+ "healthReports": "healthReports contains all KMS plugin health reports. When omitted, no health reports are available. Each entry must have a unique combination of nodeName and keyID.",
+ "preflight": "preflight contains the state of KMS preflight validation for this operator. The preflight validates the KMS provider configuration before it is used to create a new encryption key, catching configuration issues early such as incorrect login credentials or an unreachable Vault service. When omitted, no preflight validation is in progress.",
+}
+
+func (KMSEncryptionStatus) SwaggerDoc() map[string]string {
+ return map_KMSEncryptionStatus
+}
+
+var map_KMSPluginHealthReport = map[string]string{
+ "nodeName": "nodeName is the name of the node this instance of the plugin runs on. The combination of nodeName and keyID makes this health report unique. The value must be a valid Kubernetes node name: a lowercase RFC 1123 subdomain consisting of lowercase alphanumeric characters, '-' or '.', starting and ending with an alphanumeric character, and be at most 253 characters in length.",
+ "keyID": "keyID is the encryption-key-secret id (kms-{keyID}.sock), a unique identifier of the plugin on that node. This is not a cryptographic key used to encrypt/decrypt any resources. The value must be between 1 and 512 characters.",
+ "status": "status contains a health indicator for the respective KMS plugin The field can have three states: healthy, unhealthy, error. With error and unhealthy containing additional information in Detail.",
+ "lastCheckedTime": "lastCheckedTime is a timestamp of when the probe was last checked.",
+ "remoteKeyID": "remoteKeyID refers to the remote key identifier from KMS v2 StatusResponse.key_id. This is not a cryptographic key, but a unique representation of the KEK. The value must be between 1 and 1024 characters.",
+ "detail": "detail contains additional error/health information for the respective KMS plugin. When omitted, no additional error or health information is provided. When set, the value must be between 1 and 1024 characters.",
+}
+
+func (KMSPluginHealthReport) SwaggerDoc() map[string]string {
+ return map_KMSPluginHealthReport
+}
+
+var map_KMSPreflightCheck = map[string]string{
+ "": "KMSPreflightCheck describes a preflight validation request and its result.",
+ "observedConfigHash": "observedConfigHash is a hash of the KMS provider configuration and its referenced resources that has been observed and requires preflight validation before a new encryption key can be created. The value must be exactly 8 characters.",
+ "result": "result contains the outcome of the most recent preflight check. Preflight is considered passed when result.status is Succeeded and result.configHash matches observedConfigHash. When omitted, no preflight check result has been reported yet.",
+}
+
+func (KMSPreflightCheck) SwaggerDoc() map[string]string {
+ return map_KMSPreflightCheck
+}
+
+var map_KMSPreflightResult = map[string]string{
+ "": "KMSPreflightResult contains the outcome of a preflight validation.",
+ "status": "status indicates the outcome of the preflight check. Succeeded means the KMS plugin responded to Status, Encrypt, and Decrypt calls successfully. Failed means the validation did not pass.",
+ "configHash": "configHash is the hash of the configuration that was validated. This is compared against observedConfigHash to confirm the result corresponds to the current configuration. The value must be exactly 8 characters.",
+ "remoteKeyID": "remoteKeyID is the remote key encryption key identifier from KMS v2 StatusResponse.key_id. This is not a cryptographic key, but a unique representation of the remote key used to encrypt data. The value must be between 1 and 1024 characters.",
+}
+
+func (KMSPreflightResult) SwaggerDoc() map[string]string {
+ return map_KMSPreflightResult
+}
+
var map_KubeAPIServer = map[string]string{
"": "KubeAPIServer provides information to configure an operator to manage kube-apiserver.\n\nCompatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer).",
"metadata": "metadata is the standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata",
@@ -1326,6 +1463,7 @@ func (KubeAPIServerSpec) SwaggerDoc() map[string]string {
var map_KubeAPIServerStatus = map[string]string{
"serviceAccountIssuers": "serviceAccountIssuers tracks history of used service account issuers. The item without expiration time represents the currently used service account issuer. The other items represents service account issuers that were used previously and are still being trusted. The default expiration for the items is set by the platform and it defaults to 24h. see: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/#service-account-token-volume-projection",
+ "encryptionStatus": "encryptionStatus contains status reports for the KMS plugin health and its key rotation.",
}
func (KubeAPIServerStatus) SwaggerDoc() map[string]string {
@@ -1669,6 +1807,16 @@ func (AdditionalRoutingCapabilities) SwaggerDoc() map[string]string {
return map_AdditionalRoutingCapabilities
}
+var map_BGPManagedConfig = map[string]string{
+ "": "BGPManagedConfig contains configuration options for BGP when routing is \"Managed\".",
+ "asNumber": "asNumber is the 2-byte or 4-byte Autonomous System Number (ASN) to be used in the generated FRR configuration. Valid values are 1 to 4294967295. When omitted, this defaults to 64512.",
+ "bgpTopology": "bgpTopology defines the BGP topology to be used. Allowed values are \"FullMesh\". When set to \"FullMesh\", every node peers directly with every other node via BGP. This field is required when BGPManagedConfig is specified.",
+}
+
+func (BGPManagedConfig) SwaggerDoc() map[string]string {
+ return map_BGPManagedConfig
+}
+
var map_ClusterNetworkEntry = map[string]string{
"": "ClusterNetworkEntry is a subnet from which to allocate PodIPs. A network of size HostPrefix (in CIDR notation) will be allocated when nodes join the cluster. If the HostPrefix field is not used by the plugin, it can be left unset. Not all network providers support multiple ClusterNetworks",
}
@@ -1896,6 +2044,16 @@ func (NetworkStatus) SwaggerDoc() map[string]string {
return map_NetworkStatus
}
+var map_NoOverlayConfig = map[string]string{
+ "": "NoOverlayConfig contains configuration options for networks operating in no-overlay mode.",
+ "outboundSNAT": "outboundSNAT defines the SNAT behavior for outbound traffic from pods. Allowed values are \"Enabled\" and \"Disabled\". When set to \"Enabled\", SNAT is performed on outbound traffic from pods. When set to \"Disabled\", SNAT is not performed and pod IPs are preserved in outbound traffic. This field is required when the network operates in no-overlay mode. This field can be set to any value at installation time and can be changed afterwards.",
+ "routing": "routing specifies whether the pod network routing is managed by OVN-Kubernetes or users. Allowed values are \"Managed\" and \"Unmanaged\". When set to \"Managed\", OVN-Kubernetes manages the pod network routing configuration through BGP. When set to \"Unmanaged\", users are responsible for configuring the pod network routing. This field is required when the network operates in no-overlay mode. This field is immutable once set.",
+}
+
+func (NoOverlayConfig) SwaggerDoc() map[string]string {
+ return map_NoOverlayConfig
+}
+
var map_OVNKubernetesConfig = map[string]string{
"": "ovnKubernetesConfig contains the configuration parameters for networks using the ovn-kubernetes network project",
"mtu": "mtu is the MTU to use for the tunnel interface. This must be 100 bytes smaller than the uplink mtu. Default is 1400",
@@ -1910,6 +2068,9 @@ var map_OVNKubernetesConfig = map[string]string{
"ipv4": "ipv4 allows users to configure IP settings for IPv4 connections. When ommitted, this means no opinions and the default configuration is used. Check individual fields within ipv4 for details of default values.",
"ipv6": "ipv6 allows users to configure IP settings for IPv6 connections. When ommitted, this means no opinions and the default configuration is used. Check individual fields within ipv4 for details of default values.",
"routeAdvertisements": "routeAdvertisements determines if the functionality to advertise cluster network routes through a dynamic routing protocol, such as BGP, is enabled or not. This functionality is configured through the ovn-kubernetes RouteAdvertisements CRD. Requires the 'FRR' routing capability provider to be enabled as an additional routing capability. Allowed values are \"Enabled\", \"Disabled\" and ommited. When omitted, this means the user has no opinion and the platform is left to choose reasonable defaults. These defaults are subject to change over time. The current default is \"Disabled\".",
+ "transport": "transport sets the transport mode for pods on the default network. Allowed values are \"NoOverlay\" and \"Geneve\". \"NoOverlay\" avoids tunnel encapsulation, routing pod traffic directly between nodes. \"Geneve\" encapsulates pod traffic using Geneve tunnels between nodes. When omitted, this means the user has no opinion and the platform chooses a reasonable default which is subject to change over time. The current default is \"Geneve\". \"NoOverlay\" can only be set at installation time and cannot be changed afterwards. \"Geneve\" may be set explicitly at any time to lock in the current default.",
+ "noOverlayConfig": "noOverlayConfig contains configuration for no-overlay mode. This configuration applies to the default network only. It is required when transport is \"NoOverlay\". When omitted, this means the user does not configure no-overlay mode options.",
+ "bgpManagedConfig": "bgpManagedConfig configures the BGP properties for networks (default network or CUDNs) in no-overlay mode that specify routing=\"Managed\" in their noOverlayConfig. It is required when noOverlayConfig.routing is set to \"Managed\". When omitted, this means the user does not configure BGP for managed routing. This field can be set at installation time or on day 2, and can be modified at any time.",
}
func (OVNKubernetesConfig) SwaggerDoc() map[string]string {
@@ -2056,6 +2217,14 @@ func (OpenShiftAPIServerList) SwaggerDoc() map[string]string {
return map_OpenShiftAPIServerList
}
+var map_OpenShiftAPIServerStatus = map[string]string{
+ "encryptionStatus": "encryptionStatus contains status reports for the KMS plugin health and its key rotation.",
+}
+
+func (OpenShiftAPIServerStatus) SwaggerDoc() map[string]string {
+ return map_OpenShiftAPIServerStatus
+}
+
var map_OpenShiftControllerManager = map[string]string{
"": "OpenShiftControllerManager provides information to configure an operator to manage openshift-controller-manager.\n\nCompatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer).",
"metadata": "metadata is the standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata",
diff --git a/vendor/github.com/openshift/api/operator/v1alpha1/doc.go b/vendor/github.com/openshift/api/operator/v1alpha1/doc.go
index 9d18719532..6a48bca3d9 100644
--- a/vendor/github.com/openshift/api/operator/v1alpha1/doc.go
+++ b/vendor/github.com/openshift/api/operator/v1alpha1/doc.go
@@ -1,6 +1,7 @@
// +k8s:deepcopy-gen=package,register
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.operator.v1alpha1
// +groupName=operator.openshift.io
package v1alpha1
diff --git a/vendor/github.com/openshift/api/operator/v1alpha1/register.go b/vendor/github.com/openshift/api/operator/v1alpha1/register.go
index ec19cba3a9..099f1f7557 100644
--- a/vendor/github.com/openshift/api/operator/v1alpha1/register.go
+++ b/vendor/github.com/openshift/api/operator/v1alpha1/register.go
@@ -43,6 +43,8 @@ func addKnownTypes(scheme *runtime.Scheme) error {
&ClusterVersionOperatorList{},
&ClusterAPI{},
&ClusterAPIList{},
+ &Ingress{},
+ &IngressList{},
)
return nil
diff --git a/vendor/github.com/openshift/api/operator/v1alpha1/types_clusterapi.go b/vendor/github.com/openshift/api/operator/v1alpha1/types_clusterapi.go
index 5816f93628..291cedc145 100644
--- a/vendor/github.com/openshift/api/operator/v1alpha1/types_clusterapi.go
+++ b/vendor/github.com/openshift/api/operator/v1alpha1/types_clusterapi.go
@@ -20,6 +20,7 @@ import (
// Compatibility level 4: No compatibility is provided, the API can change at any point for any reason. These capabilities should not be used by applications needing long term support.
// +openshift:compatibility-gen:level=4
// +kubebuilder:validation:XValidation:rule="self.metadata.name == 'cluster'",message="clusterapi is a singleton, .metadata.name must be 'cluster'"
+// +kubebuilder:validation:XValidation:rule="!has(oldSelf.status) || has(self.status)",message="status may not be removed once set"
type ClusterAPI struct {
metav1.TypeMeta `json:",inline"`
@@ -78,6 +79,7 @@ type RevisionName string
// ClusterAPIStatus describes the current state of the capi-operator.
// +kubebuilder:validation:XValidation:rule="self.revisions.exists(r, r.name == self.desiredRevision && self.revisions.all(s, s.revision <= r.revision))",message="desiredRevision must be the name of the revision with the highest revision number"
// +kubebuilder:validation:XValidation:rule="!has(self.currentRevision) || self.revisions.exists(r, r.name == self.currentRevision)",message="currentRevision must correspond to an entry in the revisions list"
+// +kubebuilder:validation:XValidation:rule="!has(oldSelf.observedRevisionGeneration) || has(self.observedRevisionGeneration)",message="observedRevisionGeneration may not be unset once set"
type ClusterAPIStatus struct {
// currentRevision is the name of the most recently fully applied revision.
// It is written by the installer controller. If it is absent, it indicates
@@ -111,6 +113,15 @@ type ClusterAPIStatus struct {
// +kubebuilder:validation:XValidation:rule="self.all(new, oldSelf.exists(old, old.name == new.name) || oldSelf.all(old, new.revision > old.revision))",message="new revisions must have a revision number greater than all existing revisions"
// +kubebuilder:validation:XValidation:rule="oldSelf.all(old, !self.exists(new, new.name == old.name) || self.exists(new, new == old))",message="existing revisions are immutable, but may be removed"
Revisions []ClusterAPIInstallerRevision `json:"revisions,omitempty"`
+
+ // observedRevisionGeneration is the generation of the ClusterAPI object that was last observed by the revision controller.
+ // If specified it must be greater than or equal to 1, and less than 2^53. It may not decrease or be unset once set.
+ //
+ // +optional
+ // +kubebuilder:validation:Minimum=1
+ // +kubebuilder:validation:Maximum=9007199254740991
+ // +kubebuilder:validation:XValidation:rule="self >= oldSelf",message="observedRevisionGeneration may not decrease"
+ ObservedRevisionGeneration int64 `json:"observedRevisionGeneration,omitempty"`
}
// +structType=atomic
@@ -144,6 +155,17 @@ type ClusterAPIInstallerRevision struct {
// +optional
UnmanagedCustomResourceDefinitions []string `json:"unmanagedCustomResourceDefinitions,omitempty"`
+ // manifestSubstitutions is a list of envsubst style substitutions which
+ // will be applied to manifests in the revision during rendering. If
+ // defined it must not be empty, and may not contain more than 32 items.
+ // Each manifest substitution must have a unique key.
+ // +optional
+ // +listType=map
+ // +listMapKey=key
+ // +kubebuilder:validation:MinItems=1
+ // +kubebuilder:validation:MaxItems=32
+ ManifestSubstitutions []ClusterAPIInstallerRevisionManifestSubstitution `json:"manifestSubstitutions,omitempty"`
+
// components is a list of components which will be installed by this
// revision. Components will be installed in the order they are listed. If
// omitted no components will be installed.
@@ -157,6 +179,29 @@ type ClusterAPIInstallerRevision struct {
Components []ClusterAPIInstallerComponent `json:"components,omitempty"`
}
+// ClusterAPIInstallerRevisionManifestSubstitution defines an envsubst style
+// substitution which will be applied to manifests in a revision during
+// rendering.
+type ClusterAPIInstallerRevisionManifestSubstitution struct {
+ // key is the name of the envsubst variable to substitute. It must be a
+ // valid envsubst variable name, consisting of letters, digits, and
+ // underscores, and must start with a letter or underscore. The key must
+ // not be empty, and must not exceed 255 characters.
+ // +required
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=255
+ // +kubebuilder:validation:XValidation:rule="self.matches('^[A-Za-z_][A-Za-z0-9_]*$')",message="key must start with a letter or underscore, followed by letters, digits, or underscores"
+ Key string `json:"key,omitempty"`
+
+ // value is the value to substitute for the envsubst variable. It may be
+ // empty, in which case the variable will be substituted with an empty
+ // string. The value must not exceed 4096 characters.
+ // +required
+ // +kubebuilder:validation:MinLength=0
+ // +kubebuilder:validation:MaxLength=4096
+ Value *string `json:"value,omitempty"`
+}
+
// InstallerComponentType is the type of component to install.
// +kubebuilder:validation:Enum=Image
// +enum
@@ -168,9 +213,24 @@ const (
)
// ClusterAPIInstallerComponent defines a component which will be installed by this revision.
+type ClusterAPIInstallerComponent struct {
+ // name is the human-readable name of the component. The value has no
+ // effect, and will not be set if the component does not define a name in
+ // its manifests. If set it must consist of alphanumeric characters, or
+ // '-', and may not exceed 255 characters.
+ // +optional
+ // +kubebuilder:validation:MinLength=1
+ // +kubebuilder:validation:MaxLength=255
+ // +kubebuilder:validation:XValidation:rule="self.matches('^[A-Za-z0-9-]+$')",message="name must consist of alphanumeric characters or '-'"
+ Name string `json:"name,omitempty"`
+
+ ClusterAPIInstallerComponentSource `json:",inline"`
+}
+
+// ClusterAPIInstallerComponentSource defines the source of a component which will be installed by this revision.
// +union
// +kubebuilder:validation:XValidation:rule="self.type == 'Image' ? has(self.image) : !has(self.image)",message="image is required when type is Image, and forbidden otherwise"
-type ClusterAPIInstallerComponent struct {
+type ClusterAPIInstallerComponentSource struct {
// type is the source type of the component.
// The only valid value is Image.
// When set to Image, the image field must be set and will define an image source for the component.
@@ -184,13 +244,24 @@ type ClusterAPIInstallerComponent struct {
Image ClusterAPIInstallerComponentImage `json:"image,omitzero"`
}
-// ImageDigestFormat is a type that conforms to the format host[:port][/namespace]/name@sha256:.
+// The image name validation regex is derived from the OCI distribution reference:
+// https://github.com/distribution/reference/blob/main/regexp.go
+// It matches: domainAndPort "/" remoteName
+//
+// domainAndPort = (domainName | "[" ipv6 "]") [ ":" port ]
+// domainName = label ("." label)*
+// label = alphanumeric, may contain hyphens but must start/end with [a-zA-Z0-9]
+// remoteName = pathComponent ("/" pathComponent)*
+// pathComponent = [a-z0-9]+ separated by ".", "_", "__", or "-"+
+
+// ImageDigestFormat is a type that conforms to the format host[:port][/namespace[/namespace...]]/name@sha256:.
+// The host may be a dotted domain name (including IPv4 addresses like 192.168.1.1), or an IPv6 address in brackets (e.g. [fd00::1]).
// The digest must be 64 characters long, and consist only of lowercase hexadecimal characters, a-f and 0-9.
// The length of the field must be between 1 to 447 characters.
// +kubebuilder:validation:MinLength=1
// +kubebuilder:validation:MaxLength=447
// +kubebuilder:validation:XValidation:rule=`(self.split('@').size() == 2 && self.split('@')[1].matches('^sha256:[a-f0-9]{64}$'))`,message="the OCI Image reference must end with a valid '@sha256:' suffix, where '' is 64 characters long"
-// +kubebuilder:validation:XValidation:rule=`(self.split('@')[0].matches('^([a-zA-Z0-9-]+\\.)+[a-zA-Z0-9-]+(:[0-9]{2,5})?/([a-zA-Z0-9-_]{0,61}/)?[a-zA-Z0-9-_.]*?$'))`,message="the OCI Image name should follow the host[:port][/namespace]/name format, resembling a valid URL without the scheme"
+// +kubebuilder:validation:XValidation:rule=`(self.split('@')[0].matches('^(?:(?:[a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])(?:\\.(?:[a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9]))*|\\[(?:[a-fA-F0-9:]+)\\])(?::[0-9]+)?/[a-z0-9]+(?:(?:[._]|__|[-]+)[a-z0-9]+)*(?:/[a-z0-9]+(?:(?:[._]|__|[-]+)[a-z0-9]+)*)*$'))`,message="the OCI Image name should follow the host[:port][/namespace[/namespace...]]/name format, where host is a domain name, IPv4, or IPv6 address in brackets"
type ImageDigestFormat string
// ClusterAPIInstallerComponentImage defines an image source for a component.
diff --git a/vendor/github.com/openshift/api/operator/v1alpha1/types_ingress.go b/vendor/github.com/openshift/api/operator/v1alpha1/types_ingress.go
new file mode 100644
index 0000000000..0dbf9ead8b
--- /dev/null
+++ b/vendor/github.com/openshift/api/operator/v1alpha1/types_ingress.go
@@ -0,0 +1,146 @@
+package v1alpha1
+
+import (
+ metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
+)
+
+// +genclient
+// +genclient:nonNamespaced
+// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
+
+// Ingress contains configuration options specific to the Ingress Operator itself,
+// including how it manages Gateway API integration.
+//
+// Compatibility level 4: No compatibility is provided, the API can change at any point for any reason. These capabilities should not be used by applications needing long term support.
+// +openshift:compatibility-gen:level=4
+// +openshift:file-pattern=cvoRunLevel=0000_50,operatorName=ingress,operatorOrdering=02
+// +kubebuilder:object:root=true
+// +kubebuilder:resource:path=ingresses,scope=Cluster
+// +kubebuilder:subresource:status
+// +openshift:api-approved.openshift.io=https://github.com/openshift/api/pull/2890
+// +openshift:capability=Ingress
+// +openshift:enable:FeatureGate=GatewayAPIManagementMode
+// +kubebuilder:validation:XValidation:rule="self.metadata.name == 'cluster'",message="Ingress is a singleton; the .metadata.name field must be 'cluster'"
+type Ingress struct {
+ metav1.TypeMeta `json:",inline"`
+
+ // metadata is the standard object's metadata.
+ // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
+ // +required
+ metav1.ObjectMeta `json:"metadata"`
+
+ // spec holds user settable values for configuration.
+ // +required
+ Spec IngressSpec `json:"spec,omitzero"`
+
+ // status holds observed values from the cluster.
+ // +optional
+ Status IngressStatus `json:"status,omitzero"`
+}
+
+// IngressSpec is the specification of the desired behavior of the Ingress Operator.
+// +kubebuilder:validation:MinProperties=1
+type IngressSpec struct {
+ // gatewayAPI holds configuration for Gateway API integration, including how the
+ // ingress operator manages Gateway API CRDs, the OpenShift Gateway API
+ // implementation, and its Gateway API controllers.
+ //
+ // +optional
+ GatewayAPI GatewayAPIIngressConfig `json:"gatewayAPI,omitzero"`
+}
+
+// IngressStatus defines the observed status of the Ingress Operator.
+// +kubebuilder:validation:MinProperties=1
+// +kubebuilder:validation:XValidation:rule="!has(oldSelf.observedGeneration) || (has(self.observedGeneration) && self.observedGeneration >= oldSelf.observedGeneration)",message="observedGeneration must remain set and only increase once set"
+type IngressStatus struct {
+ // conditions is a list of conditions and their status.
+ //
+ // Gateway API CRD management conditions are reported here with the "GatewayAPI" prefix:
+ //
+ // * "GatewayAPICRDsManaged" indicates whether the ingress operator is actively
+ // managing Gateway API CRDs.
+ // * "GatewayAPICRDsPresent" indicates whether Gateway API CRDs exist on the
+ // cluster.
+ // * "GatewayAPICRDsCompliant" indicates whether the installed CRDs match the
+ // version expected by this ingress operator release.
+ //
+ // +listType=map
+ // +listMapKey=type
+ // +kubebuilder:validation:MinItems=1
+ // +kubebuilder:validation:MaxItems=32
+ // +optional
+ Conditions []metav1.Condition `json:"conditions,omitempty"`
+
+ // observedGeneration represents the most recent generation observed by the operator and specifies the version of
+ // the spec field currently being synced.
+ //
+ // When omitted, the operator has not yet observed the resource.
+ // +optional
+ // +kubebuilder:validation:Minimum=1
+ ObservedGeneration int64 `json:"observedGeneration,omitempty"`
+}
+
+// GatewayAPIIngressConfig holds configuration for Gateway API integration in the
+// Cluster Ingress Operator.
+// +kubebuilder:validation:MinProperties=1
+type GatewayAPIIngressConfig struct {
+ // managementMode specifies how the Cluster Ingress Operator manages Gateway API
+ // Custom Resource Definitions (CRDs), the OpenShift Gateway API implementation,
+ // and its Gateway API controllers.
+ //
+ // Allowed values are "Managed" and "Unmanaged".
+ //
+ // When omitted or set to "Managed", the ingress operator installs, owns, and
+ // upgrades the Gateway API CRDs, protects them with a Validating Admission
+ // Policy, and deploys the OpenShift Gateway API implementation and its Gateway
+ // API controllers.
+ //
+ // When set to "Unmanaged", the ingress operator does not install or manage
+ // Gateway API CRDs and does not deploy the OpenShift Gateway API implementation
+ // or its Gateway API controllers. The cluster administrator or a third-party
+ // product is responsible for providing their own CRDs and Gateway controller.
+ // The ingress operator reports observational status only.
+ //
+ // +optional
+ ManagementMode GatewayAPIManagementMode `json:"managementMode,omitempty"`
+}
+
+// GatewayAPIManagementMode describes how the Cluster Ingress Operator manages
+// Gateway API Custom Resource Definitions.
+// +kubebuilder:validation:Enum=Managed;Unmanaged
+type GatewayAPIManagementMode string
+
+const (
+ // GatewayAPIManagementModeManaged means the ingress operator installs, owns,
+ // protects (via a Validating Admission Policy), and upgrades the Gateway API
+ // CRDs, deploys the OpenShift Gateway API implementation, and runs its Gateway
+ // API controllers. This is the default mode and the only fully supported
+ // configuration.
+ GatewayAPIManagementModeManaged GatewayAPIManagementMode = "Managed"
+
+ // GatewayAPIManagementModeUnmanaged means the ingress operator does not
+ // install or manage Gateway API CRDs, does not deploy the OpenShift Gateway
+ // API implementation, and does not run its Gateway API controllers. The
+ // cluster administrator or a third-party product is responsible for bringing
+ // their own CRDs and Gateway controller. The ingress operator reports
+ // observational status only.
+ GatewayAPIManagementModeUnmanaged GatewayAPIManagementMode = "Unmanaged"
+)
+
+// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
+
+// IngressList is a collection of Ingresses.
+//
+// Compatibility level 4: No compatibility is provided, the API can change at any point for any reason. These capabilities should not be used by applications needing long term support.
+// +openshift:compatibility-gen:level=4
+type IngressList struct {
+ metav1.TypeMeta `json:",inline"`
+
+ // metadata is the standard list's metadata.
+ // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
+ metav1.ListMeta `json:"metadata"`
+
+ // items is a list of Ingresses.
+ // +optional
+ Items []Ingress `json:"items,omitempty"`
+}
diff --git a/vendor/github.com/openshift/api/operator/v1alpha1/zz_generated.deepcopy.go b/vendor/github.com/openshift/api/operator/v1alpha1/zz_generated.deepcopy.go
index 1f3fd281e1..4d864f167e 100644
--- a/vendor/github.com/openshift/api/operator/v1alpha1/zz_generated.deepcopy.go
+++ b/vendor/github.com/openshift/api/operator/v1alpha1/zz_generated.deepcopy.go
@@ -61,7 +61,7 @@ func (in *ClusterAPI) DeepCopyObject() runtime.Object {
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *ClusterAPIInstallerComponent) DeepCopyInto(out *ClusterAPIInstallerComponent) {
*out = *in
- out.Image = in.Image
+ out.ClusterAPIInstallerComponentSource = in.ClusterAPIInstallerComponentSource
return
}
@@ -91,6 +91,23 @@ func (in *ClusterAPIInstallerComponentImage) DeepCopy() *ClusterAPIInstallerComp
return out
}
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *ClusterAPIInstallerComponentSource) DeepCopyInto(out *ClusterAPIInstallerComponentSource) {
+ *out = *in
+ out.Image = in.Image
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterAPIInstallerComponentSource.
+func (in *ClusterAPIInstallerComponentSource) DeepCopy() *ClusterAPIInstallerComponentSource {
+ if in == nil {
+ return nil
+ }
+ out := new(ClusterAPIInstallerComponentSource)
+ in.DeepCopyInto(out)
+ return out
+}
+
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *ClusterAPIInstallerRevision) DeepCopyInto(out *ClusterAPIInstallerRevision) {
*out = *in
@@ -99,6 +116,13 @@ func (in *ClusterAPIInstallerRevision) DeepCopyInto(out *ClusterAPIInstallerRevi
*out = make([]string, len(*in))
copy(*out, *in)
}
+ if in.ManifestSubstitutions != nil {
+ in, out := &in.ManifestSubstitutions, &out.ManifestSubstitutions
+ *out = make([]ClusterAPIInstallerRevisionManifestSubstitution, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
if in.Components != nil {
in, out := &in.Components, &out.Components
*out = make([]ClusterAPIInstallerComponent, len(*in))
@@ -117,6 +141,27 @@ func (in *ClusterAPIInstallerRevision) DeepCopy() *ClusterAPIInstallerRevision {
return out
}
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *ClusterAPIInstallerRevisionManifestSubstitution) DeepCopyInto(out *ClusterAPIInstallerRevisionManifestSubstitution) {
+ *out = *in
+ if in.Value != nil {
+ in, out := &in.Value, &out.Value
+ *out = new(string)
+ **out = **in
+ }
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterAPIInstallerRevisionManifestSubstitution.
+func (in *ClusterAPIInstallerRevisionManifestSubstitution) DeepCopy() *ClusterAPIInstallerRevisionManifestSubstitution {
+ if in == nil {
+ return nil
+ }
+ out := new(ClusterAPIInstallerRevisionManifestSubstitution)
+ in.DeepCopyInto(out)
+ return out
+}
+
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *ClusterAPIList) DeepCopyInto(out *ClusterAPIList) {
*out = *in
@@ -424,6 +469,22 @@ func (in *EtcdBackupStatus) DeepCopy() *EtcdBackupStatus {
return out
}
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *GatewayAPIIngressConfig) DeepCopyInto(out *GatewayAPIIngressConfig) {
+ *out = *in
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GatewayAPIIngressConfig.
+func (in *GatewayAPIIngressConfig) DeepCopy() *GatewayAPIIngressConfig {
+ if in == nil {
+ return nil
+ }
+ out := new(GatewayAPIIngressConfig)
+ in.DeepCopyInto(out)
+ return out
+}
+
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *GenerationHistory) DeepCopyInto(out *GenerationHistory) {
*out = *in
@@ -552,6 +613,107 @@ func (in *ImageContentSourcePolicySpec) DeepCopy() *ImageContentSourcePolicySpec
return out
}
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *Ingress) DeepCopyInto(out *Ingress) {
+ *out = *in
+ out.TypeMeta = in.TypeMeta
+ in.ObjectMeta.DeepCopyInto(&out.ObjectMeta)
+ out.Spec = in.Spec
+ in.Status.DeepCopyInto(&out.Status)
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Ingress.
+func (in *Ingress) DeepCopy() *Ingress {
+ if in == nil {
+ return nil
+ }
+ out := new(Ingress)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
+func (in *Ingress) DeepCopyObject() runtime.Object {
+ if c := in.DeepCopy(); c != nil {
+ return c
+ }
+ return nil
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *IngressList) DeepCopyInto(out *IngressList) {
+ *out = *in
+ out.TypeMeta = in.TypeMeta
+ in.ListMeta.DeepCopyInto(&out.ListMeta)
+ if in.Items != nil {
+ in, out := &in.Items, &out.Items
+ *out = make([]Ingress, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new IngressList.
+func (in *IngressList) DeepCopy() *IngressList {
+ if in == nil {
+ return nil
+ }
+ out := new(IngressList)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
+func (in *IngressList) DeepCopyObject() runtime.Object {
+ if c := in.DeepCopy(); c != nil {
+ return c
+ }
+ return nil
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *IngressSpec) DeepCopyInto(out *IngressSpec) {
+ *out = *in
+ out.GatewayAPI = in.GatewayAPI
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new IngressSpec.
+func (in *IngressSpec) DeepCopy() *IngressSpec {
+ if in == nil {
+ return nil
+ }
+ out := new(IngressSpec)
+ in.DeepCopyInto(out)
+ return out
+}
+
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *IngressStatus) DeepCopyInto(out *IngressStatus) {
+ *out = *in
+ if in.Conditions != nil {
+ in, out := &in.Conditions, &out.Conditions
+ *out = make([]v1.Condition, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
+ }
+ return
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new IngressStatus.
+func (in *IngressStatus) DeepCopy() *IngressStatus {
+ if in == nil {
+ return nil
+ }
+ out := new(IngressStatus)
+ in.DeepCopyInto(out)
+ return out
+}
+
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *LoggingConfig) DeepCopyInto(out *LoggingConfig) {
*out = *in
diff --git a/vendor/github.com/openshift/api/operator/v1alpha1/zz_generated.featuregated-crd-manifests.yaml b/vendor/github.com/openshift/api/operator/v1alpha1/zz_generated.featuregated-crd-manifests.yaml
index 3ad442d9d8..bb0d1025d4 100644
--- a/vendor/github.com/openshift/api/operator/v1alpha1/zz_generated.featuregated-crd-manifests.yaml
+++ b/vendor/github.com/openshift/api/operator/v1alpha1/zz_generated.featuregated-crd-manifests.yaml
@@ -90,6 +90,29 @@ imagecontentsourcepolicies.operator.openshift.io:
TopLevelFeatureGates: []
Version: v1alpha1
+ingresses.operator.openshift.io:
+ Annotations: {}
+ ApprovedPRNumber: https://github.com/openshift/api/pull/2890
+ CRDName: ingresses.operator.openshift.io
+ Capability: Ingress
+ Category: ""
+ FeatureGates:
+ - GatewayAPIManagementMode
+ FilenameOperatorName: ingress
+ FilenameOperatorOrdering: "02"
+ FilenameRunLevel: "0000_50"
+ GroupName: operator.openshift.io
+ HasStatus: true
+ KindName: Ingress
+ Labels: {}
+ PluralName: ingresses
+ PrinterColumns: []
+ Scope: Cluster
+ ShortNames: null
+ TopLevelFeatureGates:
+ - GatewayAPIManagementMode
+ Version: v1alpha1
+
olms.operator.openshift.io:
Annotations:
include.release.openshift.io/ibm-cloud-managed: "false"
diff --git a/vendor/github.com/openshift/api/operator/v1alpha1/zz_generated.model_name.go b/vendor/github.com/openshift/api/operator/v1alpha1/zz_generated.model_name.go
new file mode 100644
index 0000000000..cd4dbe030a
--- /dev/null
+++ b/vendor/github.com/openshift/api/operator/v1alpha1/zz_generated.model_name.go
@@ -0,0 +1,216 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1alpha1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BackupJobReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.BackupJobReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterAPI) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.ClusterAPI"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterAPIInstallerComponent) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.ClusterAPIInstallerComponent"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterAPIInstallerComponentImage) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.ClusterAPIInstallerComponentImage"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterAPIInstallerComponentSource) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.ClusterAPIInstallerComponentSource"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterAPIInstallerRevision) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.ClusterAPIInstallerRevision"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterAPIInstallerRevisionManifestSubstitution) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.ClusterAPIInstallerRevisionManifestSubstitution"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterAPIList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.ClusterAPIList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterAPISpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.ClusterAPISpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterAPIStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.ClusterAPIStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterVersionOperator) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.ClusterVersionOperator"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterVersionOperatorList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.ClusterVersionOperatorList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterVersionOperatorSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.ClusterVersionOperatorSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterVersionOperatorStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.ClusterVersionOperatorStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DelegatedAuthentication) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.DelegatedAuthentication"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DelegatedAuthorization) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.DelegatedAuthorization"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EtcdBackup) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.EtcdBackup"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EtcdBackupList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.EtcdBackupList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EtcdBackupSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.EtcdBackupSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in EtcdBackupStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.EtcdBackupStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GatewayAPIIngressConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.GatewayAPIIngressConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GenerationHistory) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.GenerationHistory"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GenericOperatorConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.GenericOperatorConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageContentSourcePolicy) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.ImageContentSourcePolicy"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageContentSourcePolicyList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.ImageContentSourcePolicyList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ImageContentSourcePolicySpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.ImageContentSourcePolicySpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Ingress) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.Ingress"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IngressList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.IngressList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IngressSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.IngressSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IngressStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.IngressStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in LoggingConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.LoggingConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in NodeStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.NodeStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OLM) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.OLM"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OLMList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.OLMList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OLMSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.OLMSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OLMStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.OLMStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OperatorCondition) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.OperatorCondition"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OperatorSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.OperatorSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OperatorStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.OperatorStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RepositoryDigestMirrors) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.RepositoryDigestMirrors"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in StaticPodOperatorStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.StaticPodOperatorStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in VersionAvailability) OpenAPIModelName() string {
+ return "com.github.openshift.api.operator.v1alpha1.VersionAvailability"
+}
diff --git a/vendor/github.com/openshift/api/operator/v1alpha1/zz_generated.swagger_doc_generated.go b/vendor/github.com/openshift/api/operator/v1alpha1/zz_generated.swagger_doc_generated.go
index 92cef1421a..57a7d19669 100644
--- a/vendor/github.com/openshift/api/operator/v1alpha1/zz_generated.swagger_doc_generated.go
+++ b/vendor/github.com/openshift/api/operator/v1alpha1/zz_generated.swagger_doc_generated.go
@@ -147,9 +147,8 @@ func (ClusterAPI) SwaggerDoc() map[string]string {
}
var map_ClusterAPIInstallerComponent = map[string]string{
- "": "ClusterAPIInstallerComponent defines a component which will be installed by this revision.",
- "type": "type is the source type of the component. The only valid value is Image. When set to Image, the image field must be set and will define an image source for the component.",
- "image": "image defines an image source for a component. The image must contain a /capi-operator-installer directory containing the component manifests.",
+ "": "ClusterAPIInstallerComponent defines a component which will be installed by this revision.",
+ "name": "name is the human-readable name of the component. The value has no effect, and will not be set if the component does not define a name in its manifests. If set it must consist of alphanumeric characters, or '-', and may not exceed 255 characters.",
}
func (ClusterAPIInstallerComponent) SwaggerDoc() map[string]string {
@@ -166,11 +165,22 @@ func (ClusterAPIInstallerComponentImage) SwaggerDoc() map[string]string {
return map_ClusterAPIInstallerComponentImage
}
+var map_ClusterAPIInstallerComponentSource = map[string]string{
+ "": "ClusterAPIInstallerComponentSource defines the source of a component which will be installed by this revision.",
+ "type": "type is the source type of the component. The only valid value is Image. When set to Image, the image field must be set and will define an image source for the component.",
+ "image": "image defines an image source for a component. The image must contain a /capi-operator-installer directory containing the component manifests.",
+}
+
+func (ClusterAPIInstallerComponentSource) SwaggerDoc() map[string]string {
+ return map_ClusterAPIInstallerComponentSource
+}
+
var map_ClusterAPIInstallerRevision = map[string]string{
"name": "name is the name of a revision.",
"revision": "revision is a monotonically increasing number that is assigned to a revision.",
"contentID": "contentID uniquely identifies the content of this revision. The contentID must be between 1 and 255 characters long.",
"unmanagedCustomResourceDefinitions": "unmanagedCustomResourceDefinitions is a list of the names of ClusterResourceDefinition (CRD) objects which are included in this revision, but which should not be installed or updated. If not set, all CRDs in the revision will be managed by the CAPI operator.",
+ "manifestSubstitutions": "manifestSubstitutions is a list of envsubst style substitutions which will be applied to manifests in the revision during rendering. If defined it must not be empty, and may not contain more than 32 items. Each manifest substitution must have a unique key.",
"components": "components is a list of components which will be installed by this revision. Components will be installed in the order they are listed. If omitted no components will be installed.\n\nThe maximum number of components is 32.",
}
@@ -178,6 +188,16 @@ func (ClusterAPIInstallerRevision) SwaggerDoc() map[string]string {
return map_ClusterAPIInstallerRevision
}
+var map_ClusterAPIInstallerRevisionManifestSubstitution = map[string]string{
+ "": "ClusterAPIInstallerRevisionManifestSubstitution defines an envsubst style substitution which will be applied to manifests in a revision during rendering.",
+ "key": "key is the name of the envsubst variable to substitute. It must be a valid envsubst variable name, consisting of letters, digits, and underscores, and must start with a letter or underscore. The key must not be empty, and must not exceed 255 characters.",
+ "value": "value is the value to substitute for the envsubst variable. It may be empty, in which case the variable will be substituted with an empty string. The value must not exceed 4096 characters.",
+}
+
+func (ClusterAPIInstallerRevisionManifestSubstitution) SwaggerDoc() map[string]string {
+ return map_ClusterAPIInstallerRevisionManifestSubstitution
+}
+
var map_ClusterAPIList = map[string]string{
"": "ClusterAPIList contains a list of ClusterAPI configurations\n\nCompatibility level 4: No compatibility is provided, the API can change at any point for any reason. These capabilities should not be used by applications needing long term support.",
"metadata": "metadata is the standard list's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata",
@@ -198,10 +218,11 @@ func (ClusterAPISpec) SwaggerDoc() map[string]string {
}
var map_ClusterAPIStatus = map[string]string{
- "": "ClusterAPIStatus describes the current state of the capi-operator.",
- "currentRevision": "currentRevision is the name of the most recently fully applied revision. It is written by the installer controller. If it is absent, it indicates that no revision has been fully applied yet. If set, currentRevision must correspond to an entry in the revisions list.",
- "desiredRevision": "desiredRevision is the name of the desired revision. It is written by the revision controller. It must be set to the name of the entry in the revisions list with the highest revision number.",
- "revisions": "revisions is a list of all currently active revisions. A revision is active until the installer controller updates currentRevision to a later revision. It is written by the revision controller.\n\nThe maximum number of revisions is 16. All revisions must have a unique name. All revisions must have a unique revision number. When adding a revision, the revision number must be greater than the highest revision number in the list. Revisions are immutable, although they can be deleted.",
+ "": "ClusterAPIStatus describes the current state of the capi-operator.",
+ "currentRevision": "currentRevision is the name of the most recently fully applied revision. It is written by the installer controller. If it is absent, it indicates that no revision has been fully applied yet. If set, currentRevision must correspond to an entry in the revisions list.",
+ "desiredRevision": "desiredRevision is the name of the desired revision. It is written by the revision controller. It must be set to the name of the entry in the revisions list with the highest revision number.",
+ "revisions": "revisions is a list of all currently active revisions. A revision is active until the installer controller updates currentRevision to a later revision. It is written by the revision controller.\n\nThe maximum number of revisions is 16. All revisions must have a unique name. All revisions must have a unique revision number. When adding a revision, the revision number must be greater than the highest revision number in the list. Revisions are immutable, although they can be deleted.",
+ "observedRevisionGeneration": "observedRevisionGeneration is the generation of the ClusterAPI object that was last observed by the revision controller. If specified it must be greater than or equal to 1, and less than 2^53. It may not decrease or be unset once set.",
}
func (ClusterAPIStatus) SwaggerDoc() map[string]string {
@@ -330,6 +351,55 @@ func (RepositoryDigestMirrors) SwaggerDoc() map[string]string {
return map_RepositoryDigestMirrors
}
+var map_GatewayAPIIngressConfig = map[string]string{
+ "": "GatewayAPIIngressConfig holds configuration for Gateway API integration in the Cluster Ingress Operator.",
+ "managementMode": "managementMode specifies how the Cluster Ingress Operator manages Gateway API Custom Resource Definitions (CRDs), the OpenShift Gateway API implementation, and its Gateway API controllers.\n\nAllowed values are \"Managed\" and \"Unmanaged\".\n\nWhen omitted or set to \"Managed\", the ingress operator installs, owns, and upgrades the Gateway API CRDs, protects them with a Validating Admission Policy, and deploys the OpenShift Gateway API implementation and its Gateway API controllers.\n\nWhen set to \"Unmanaged\", the ingress operator does not install or manage Gateway API CRDs and does not deploy the OpenShift Gateway API implementation or its Gateway API controllers. The cluster administrator or a third-party product is responsible for providing their own CRDs and Gateway controller. The ingress operator reports observational status only.",
+}
+
+func (GatewayAPIIngressConfig) SwaggerDoc() map[string]string {
+ return map_GatewayAPIIngressConfig
+}
+
+var map_Ingress = map[string]string{
+ "": "Ingress contains configuration options specific to the Ingress Operator itself, including how it manages Gateway API integration.\n\nCompatibility level 4: No compatibility is provided, the API can change at any point for any reason. These capabilities should not be used by applications needing long term support.",
+ "metadata": "metadata is the standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata",
+ "spec": "spec holds user settable values for configuration.",
+ "status": "status holds observed values from the cluster.",
+}
+
+func (Ingress) SwaggerDoc() map[string]string {
+ return map_Ingress
+}
+
+var map_IngressList = map[string]string{
+ "": "IngressList is a collection of Ingresses.\n\nCompatibility level 4: No compatibility is provided, the API can change at any point for any reason. These capabilities should not be used by applications needing long term support.",
+ "metadata": "metadata is the standard list's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata",
+ "items": "items is a list of Ingresses.",
+}
+
+func (IngressList) SwaggerDoc() map[string]string {
+ return map_IngressList
+}
+
+var map_IngressSpec = map[string]string{
+ "": "IngressSpec is the specification of the desired behavior of the Ingress Operator.",
+ "gatewayAPI": "gatewayAPI holds configuration for Gateway API integration, including how the ingress operator manages Gateway API CRDs, the OpenShift Gateway API implementation, and its Gateway API controllers.",
+}
+
+func (IngressSpec) SwaggerDoc() map[string]string {
+ return map_IngressSpec
+}
+
+var map_IngressStatus = map[string]string{
+ "": "IngressStatus defines the observed status of the Ingress Operator.",
+ "conditions": "conditions is a list of conditions and their status.\n\nGateway API CRD management conditions are reported here with the \"GatewayAPI\" prefix:\n\n* \"GatewayAPICRDsManaged\" indicates whether the ingress operator is actively\n managing Gateway API CRDs.\n* \"GatewayAPICRDsPresent\" indicates whether Gateway API CRDs exist on the\n cluster.\n* \"GatewayAPICRDsCompliant\" indicates whether the installed CRDs match the\n version expected by this ingress operator release.",
+ "observedGeneration": "observedGeneration represents the most recent generation observed by the operator and specifies the version of the spec field currently being synced.\n\nWhen omitted, the operator has not yet observed the resource.",
+}
+
+func (IngressStatus) SwaggerDoc() map[string]string {
+ return map_IngressStatus
+}
+
var map_OLM = map[string]string{
"": "OLM provides information to configure an operator to manage the OLM controllers\n\nCompatibility level 4: No compatibility is provided, the API can change at any point for any reason. These capabilities should not be used by applications needing long term support.",
"metadata": "metadata is the standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata",
diff --git a/vendor/github.com/openshift/api/operatorcontrolplane/v1alpha1/doc.go b/vendor/github.com/openshift/api/operatorcontrolplane/v1alpha1/doc.go
index 73f55856a8..302abb3541 100644
--- a/vendor/github.com/openshift/api/operatorcontrolplane/v1alpha1/doc.go
+++ b/vendor/github.com/openshift/api/operatorcontrolplane/v1alpha1/doc.go
@@ -1,6 +1,7 @@
// +k8s:deepcopy-gen=package,register
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.operatorcontrolplane.v1alpha1
// +kubebuilder:validation:Optional
// +groupName=controlplane.operator.openshift.io
diff --git a/vendor/github.com/openshift/api/operatorcontrolplane/v1alpha1/zz_generated.model_name.go b/vendor/github.com/openshift/api/operatorcontrolplane/v1alpha1/zz_generated.model_name.go
new file mode 100644
index 0000000000..87f0d3b3ce
--- /dev/null
+++ b/vendor/github.com/openshift/api/operatorcontrolplane/v1alpha1/zz_generated.model_name.go
@@ -0,0 +1,41 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1alpha1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in LogEntry) OpenAPIModelName() string {
+ return "com.github.openshift.api.operatorcontrolplane.v1alpha1.LogEntry"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OutageEntry) OpenAPIModelName() string {
+ return "com.github.openshift.api.operatorcontrolplane.v1alpha1.OutageEntry"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PodNetworkConnectivityCheck) OpenAPIModelName() string {
+ return "com.github.openshift.api.operatorcontrolplane.v1alpha1.PodNetworkConnectivityCheck"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PodNetworkConnectivityCheckCondition) OpenAPIModelName() string {
+ return "com.github.openshift.api.operatorcontrolplane.v1alpha1.PodNetworkConnectivityCheckCondition"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PodNetworkConnectivityCheckList) OpenAPIModelName() string {
+ return "com.github.openshift.api.operatorcontrolplane.v1alpha1.PodNetworkConnectivityCheckList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PodNetworkConnectivityCheckSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.operatorcontrolplane.v1alpha1.PodNetworkConnectivityCheckSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PodNetworkConnectivityCheckStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.operatorcontrolplane.v1alpha1.PodNetworkConnectivityCheckStatus"
+}
diff --git a/vendor/github.com/openshift/api/osin/v1/doc.go b/vendor/github.com/openshift/api/osin/v1/doc.go
index b74dfc48ad..970c856a3b 100644
--- a/vendor/github.com/openshift/api/osin/v1/doc.go
+++ b/vendor/github.com/openshift/api/osin/v1/doc.go
@@ -1,6 +1,7 @@
// +k8s:deepcopy-gen=package,register
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.osin.v1
// +groupName=osin.config.openshift.io
// Package v1 is the v1 version of the API.
diff --git a/vendor/github.com/openshift/api/osin/v1/types.go b/vendor/github.com/openshift/api/osin/v1/types.go
index 35eb3ee8b0..3f3af3cfa5 100644
--- a/vendor/github.com/openshift/api/osin/v1/types.go
+++ b/vendor/github.com/openshift/api/osin/v1/types.go
@@ -80,6 +80,11 @@ type OAuthConfig struct {
// templates allow you to customize pages like the login page.
Templates *OAuthTemplates `json:"templates"`
+
+ // proxyTrustedCA is an optional path to a PEM-encoded CA bundle used to
+ // verify connections to an HTTPS proxy during outbound IdP requests.
+ // When omitted, proxy connections use the system trust roots only.
+ ProxyTrustedCA string `json:"proxyTrustedCA,omitempty"`
}
// OAuthTemplates allow for customization of pages like the login page
diff --git a/vendor/github.com/openshift/api/osin/v1/zz_generated.model_name.go b/vendor/github.com/openshift/api/osin/v1/zz_generated.model_name.go
new file mode 100644
index 0000000000..1ac7911e26
--- /dev/null
+++ b/vendor/github.com/openshift/api/osin/v1/zz_generated.model_name.go
@@ -0,0 +1,121 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AllowAllPasswordIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.osin.v1.AllowAllPasswordIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BasicAuthPasswordIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.osin.v1.BasicAuthPasswordIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in DenyAllPasswordIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.osin.v1.DenyAllPasswordIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GitHubIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.osin.v1.GitHubIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GitLabIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.osin.v1.GitLabIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GoogleIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.osin.v1.GoogleIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GrantConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.osin.v1.GrantConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in HTPasswdPasswordIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.osin.v1.HTPasswdPasswordIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.osin.v1.IdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in KeystonePasswordIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.osin.v1.KeystonePasswordIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in LDAPAttributeMapping) OpenAPIModelName() string {
+ return "com.github.openshift.api.osin.v1.LDAPAttributeMapping"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in LDAPPasswordIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.osin.v1.LDAPPasswordIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OAuthConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.osin.v1.OAuthConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OAuthTemplates) OpenAPIModelName() string {
+ return "com.github.openshift.api.osin.v1.OAuthTemplates"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OpenIDClaims) OpenAPIModelName() string {
+ return "com.github.openshift.api.osin.v1.OpenIDClaims"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OpenIDIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.osin.v1.OpenIDIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OpenIDURLs) OpenAPIModelName() string {
+ return "com.github.openshift.api.osin.v1.OpenIDURLs"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in OsinServerConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.osin.v1.OsinServerConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RequestHeaderIdentityProvider) OpenAPIModelName() string {
+ return "com.github.openshift.api.osin.v1.RequestHeaderIdentityProvider"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SessionConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.osin.v1.SessionConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SessionSecret) OpenAPIModelName() string {
+ return "com.github.openshift.api.osin.v1.SessionSecret"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SessionSecrets) OpenAPIModelName() string {
+ return "com.github.openshift.api.osin.v1.SessionSecrets"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TokenConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.osin.v1.TokenConfig"
+}
diff --git a/vendor/github.com/openshift/api/osin/v1/zz_generated.swagger_doc_generated.go b/vendor/github.com/openshift/api/osin/v1/zz_generated.swagger_doc_generated.go
index 890928a7a4..6594af9451 100644
--- a/vendor/github.com/openshift/api/osin/v1/zz_generated.swagger_doc_generated.go
+++ b/vendor/github.com/openshift/api/osin/v1/zz_generated.swagger_doc_generated.go
@@ -154,6 +154,7 @@ var map_OAuthConfig = map[string]string{
"sessionConfig": "sessionConfig hold information about configuring sessions.",
"tokenConfig": "tokenConfig contains options for authorization and access tokens",
"templates": "templates allow you to customize pages like the login page.",
+ "proxyTrustedCA": "proxyTrustedCA is an optional path to a PEM-encoded CA bundle used to verify connections to an HTTPS proxy during outbound IdP requests. When omitted, proxy connections use the system trust roots only.",
}
func (OAuthConfig) SwaggerDoc() map[string]string {
diff --git a/vendor/github.com/openshift/api/project/.codegen.yaml b/vendor/github.com/openshift/api/project/.codegen.yaml
new file mode 100644
index 0000000000..f7a37129a0
--- /dev/null
+++ b/vendor/github.com/openshift/api/project/.codegen.yaml
@@ -0,0 +1,2 @@
+protobuf:
+ disabled: false
diff --git a/vendor/github.com/openshift/api/project/v1/doc.go b/vendor/github.com/openshift/api/project/v1/doc.go
index 5bbd9d5ea7..28e4a99850 100644
--- a/vendor/github.com/openshift/api/project/v1/doc.go
+++ b/vendor/github.com/openshift/api/project/v1/doc.go
@@ -2,6 +2,7 @@
// +k8s:conversion-gen=github.com/openshift/origin/pkg/project/apis/project
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.project.v1
// +groupName=project.openshift.io
// Package v1 is the v1 version of the API.
diff --git a/vendor/github.com/openshift/api/project/v1/zz_generated.model_name.go b/vendor/github.com/openshift/api/project/v1/zz_generated.model_name.go
new file mode 100644
index 0000000000..0500036aea
--- /dev/null
+++ b/vendor/github.com/openshift/api/project/v1/zz_generated.model_name.go
@@ -0,0 +1,31 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Project) OpenAPIModelName() string {
+ return "com.github.openshift.api.project.v1.Project"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ProjectList) OpenAPIModelName() string {
+ return "com.github.openshift.api.project.v1.ProjectList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ProjectRequest) OpenAPIModelName() string {
+ return "com.github.openshift.api.project.v1.ProjectRequest"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ProjectSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.project.v1.ProjectSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ProjectStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.project.v1.ProjectStatus"
+}
diff --git a/vendor/github.com/openshift/api/quota/.codegen.yaml b/vendor/github.com/openshift/api/quota/.codegen.yaml
new file mode 100644
index 0000000000..f7a37129a0
--- /dev/null
+++ b/vendor/github.com/openshift/api/quota/.codegen.yaml
@@ -0,0 +1,2 @@
+protobuf:
+ disabled: false
diff --git a/vendor/github.com/openshift/api/quota/v1/doc.go b/vendor/github.com/openshift/api/quota/v1/doc.go
index ae5c9c2c76..6808c1a243 100644
--- a/vendor/github.com/openshift/api/quota/v1/doc.go
+++ b/vendor/github.com/openshift/api/quota/v1/doc.go
@@ -2,6 +2,7 @@
// +k8s:conversion-gen=github.com/openshift/origin/pkg/quota/apis/quota
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.quota.v1
// +groupName=quota.openshift.io
// Package v1 is the v1 version of the API.
diff --git a/vendor/github.com/openshift/api/quota/v1/generated.proto b/vendor/github.com/openshift/api/quota/v1/generated.proto
index fb7fed242a..998c594732 100644
--- a/vendor/github.com/openshift/api/quota/v1/generated.proto
+++ b/vendor/github.com/openshift/api/quota/v1/generated.proto
@@ -51,7 +51,7 @@ message AppliedClusterResourceQuotaList {
// +kubebuilder:resource:path=clusterresourcequotas,scope=Cluster
// +kubebuilder:subresource:status
// +openshift:api-approved.openshift.io=https://github.com/openshift/api/pull/470
-// +openshift:file-pattern=cvoRunLevel=0000_03,operatorName=config-operator,operatorOrdering=01
+// +openshift:file-pattern=cvoRunLevel=0000_00,operatorName=apiserver,operatorOrdering=01
// +openshift:compatibility-gen:level=1
// +kubebuilder:metadata:annotations=release.openshift.io/bootstrap-required=true
message ClusterResourceQuota {
diff --git a/vendor/github.com/openshift/api/quota/v1/types.go b/vendor/github.com/openshift/api/quota/v1/types.go
index 0cfb85f87e..9f60962146 100644
--- a/vendor/github.com/openshift/api/quota/v1/types.go
+++ b/vendor/github.com/openshift/api/quota/v1/types.go
@@ -17,7 +17,7 @@ import (
// +kubebuilder:resource:path=clusterresourcequotas,scope=Cluster
// +kubebuilder:subresource:status
// +openshift:api-approved.openshift.io=https://github.com/openshift/api/pull/470
-// +openshift:file-pattern=cvoRunLevel=0000_03,operatorName=config-operator,operatorOrdering=01
+// +openshift:file-pattern=cvoRunLevel=0000_00,operatorName=apiserver,operatorOrdering=01
// +openshift:compatibility-gen:level=1
// +kubebuilder:metadata:annotations=release.openshift.io/bootstrap-required=true
type ClusterResourceQuota struct {
diff --git a/vendor/github.com/openshift/api/quota/v1/zz_generated.featuregated-crd-manifests.yaml b/vendor/github.com/openshift/api/quota/v1/zz_generated.featuregated-crd-manifests.yaml
index b0fae46f7d..1a56a512d7 100644
--- a/vendor/github.com/openshift/api/quota/v1/zz_generated.featuregated-crd-manifests.yaml
+++ b/vendor/github.com/openshift/api/quota/v1/zz_generated.featuregated-crd-manifests.yaml
@@ -6,9 +6,9 @@ clusterresourcequotas.quota.openshift.io:
Capability: ""
Category: ""
FeatureGates: []
- FilenameOperatorName: config-operator
+ FilenameOperatorName: apiserver
FilenameOperatorOrdering: "01"
- FilenameRunLevel: "0000_03"
+ FilenameRunLevel: "0000_00"
GroupName: quota.openshift.io
HasStatus: true
KindName: ClusterResourceQuota
diff --git a/vendor/github.com/openshift/api/quota/v1/zz_generated.model_name.go b/vendor/github.com/openshift/api/quota/v1/zz_generated.model_name.go
new file mode 100644
index 0000000000..537360b604
--- /dev/null
+++ b/vendor/github.com/openshift/api/quota/v1/zz_generated.model_name.go
@@ -0,0 +1,46 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AppliedClusterResourceQuota) OpenAPIModelName() string {
+ return "com.github.openshift.api.quota.v1.AppliedClusterResourceQuota"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AppliedClusterResourceQuotaList) OpenAPIModelName() string {
+ return "com.github.openshift.api.quota.v1.AppliedClusterResourceQuotaList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterResourceQuota) OpenAPIModelName() string {
+ return "com.github.openshift.api.quota.v1.ClusterResourceQuota"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterResourceQuotaList) OpenAPIModelName() string {
+ return "com.github.openshift.api.quota.v1.ClusterResourceQuotaList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterResourceQuotaSelector) OpenAPIModelName() string {
+ return "com.github.openshift.api.quota.v1.ClusterResourceQuotaSelector"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterResourceQuotaSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.quota.v1.ClusterResourceQuotaSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ClusterResourceQuotaStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.quota.v1.ClusterResourceQuotaStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ResourceQuotaStatusByNamespace) OpenAPIModelName() string {
+ return "com.github.openshift.api.quota.v1.ResourceQuotaStatusByNamespace"
+}
diff --git a/vendor/github.com/openshift/api/route/.codegen.yaml b/vendor/github.com/openshift/api/route/.codegen.yaml
index 65cf5d814b..b003a5d6c9 100644
--- a/vendor/github.com/openshift/api/route/.codegen.yaml
+++ b/vendor/github.com/openshift/api/route/.codegen.yaml
@@ -1,3 +1,5 @@
schemapatch:
swaggerdocs:
commentPolicy: Warn
+protobuf:
+ disabled: false
diff --git a/vendor/github.com/openshift/api/route/v1/doc.go b/vendor/github.com/openshift/api/route/v1/doc.go
index e56fbbd8d1..1fb4d95d42 100644
--- a/vendor/github.com/openshift/api/route/v1/doc.go
+++ b/vendor/github.com/openshift/api/route/v1/doc.go
@@ -2,6 +2,7 @@
// +k8s:conversion-gen=github.com/openshift/origin/pkg/route/apis/route
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.route.v1
// +groupName=route.openshift.io
// Package v1 is the v1 version of the API.
diff --git a/vendor/github.com/openshift/api/route/v1/generated.proto b/vendor/github.com/openshift/api/route/v1/generated.proto
index 85018b16b7..28f8c311ee 100644
--- a/vendor/github.com/openshift/api/route/v1/generated.proto
+++ b/vendor/github.com/openshift/api/route/v1/generated.proto
@@ -411,7 +411,7 @@ message RouterShard {
// TLSConfig defines config used to secure a route and provide termination
//
// +kubebuilder:validation:XValidation:rule="has(self.termination) && has(self.insecureEdgeTerminationPolicy) ? !((self.termination=='passthrough') && (self.insecureEdgeTerminationPolicy=='Allow')) : true", message="cannot have both spec.tls.termination: passthrough and spec.tls.insecureEdgeTerminationPolicy: Allow"
-// +openshift:validation:FeatureGateAwareXValidation:featureGate=RouteExternalCertificate,rule="!(has(self.certificate) && has(self.externalCertificate))", message="cannot have both spec.tls.certificate and spec.tls.externalCertificate"
+// +kubebuilder:validation:XValidation:rule="!(has(self.certificate) && has(self.externalCertificate))", message="cannot have both spec.tls.certificate and spec.tls.externalCertificate"
message TLSConfig {
// termination indicates the TLS termination type.
//
@@ -464,7 +464,6 @@ message TLSConfig {
// The router service account needs to be granted with read-only access to this secret,
// please refer to openshift docs for additional details.
//
- // +openshift:enable:FeatureGate=RouteExternalCertificate
// +optional
optional LocalObjectReference externalCertificate = 7;
}
diff --git a/vendor/github.com/openshift/api/route/v1/types.go b/vendor/github.com/openshift/api/route/v1/types.go
index 35c4064825..41f362fdf4 100644
--- a/vendor/github.com/openshift/api/route/v1/types.go
+++ b/vendor/github.com/openshift/api/route/v1/types.go
@@ -422,7 +422,7 @@ type RouterShard struct {
// TLSConfig defines config used to secure a route and provide termination
//
// +kubebuilder:validation:XValidation:rule="has(self.termination) && has(self.insecureEdgeTerminationPolicy) ? !((self.termination=='passthrough') && (self.insecureEdgeTerminationPolicy=='Allow')) : true", message="cannot have both spec.tls.termination: passthrough and spec.tls.insecureEdgeTerminationPolicy: Allow"
-// +openshift:validation:FeatureGateAwareXValidation:featureGate=RouteExternalCertificate,rule="!(has(self.certificate) && has(self.externalCertificate))", message="cannot have both spec.tls.certificate and spec.tls.externalCertificate"
+// +kubebuilder:validation:XValidation:rule="!(has(self.certificate) && has(self.externalCertificate))", message="cannot have both spec.tls.certificate and spec.tls.externalCertificate"
type TLSConfig struct {
// termination indicates the TLS termination type.
//
@@ -475,7 +475,6 @@ type TLSConfig struct {
// The router service account needs to be granted with read-only access to this secret,
// please refer to openshift docs for additional details.
//
- // +openshift:enable:FeatureGate=RouteExternalCertificate
// +optional
ExternalCertificate *LocalObjectReference `json:"externalCertificate,omitempty" protobuf:"bytes,7,opt,name=externalCertificate"`
}
diff --git a/vendor/github.com/openshift/api/route/v1/zz_generated.featuregated-crd-manifests.yaml b/vendor/github.com/openshift/api/route/v1/zz_generated.featuregated-crd-manifests.yaml
index 0277ba2f32..33666eba4b 100644
--- a/vendor/github.com/openshift/api/route/v1/zz_generated.featuregated-crd-manifests.yaml
+++ b/vendor/github.com/openshift/api/route/v1/zz_generated.featuregated-crd-manifests.yaml
@@ -4,8 +4,7 @@ routes.route.openshift.io:
CRDName: routes.route.openshift.io
Capability: ""
Category: ""
- FeatureGates:
- - RouteExternalCertificate
+ FeatureGates: []
FilenameOperatorName: ""
FilenameOperatorOrdering: ""
FilenameRunLevel: ""
diff --git a/vendor/github.com/openshift/api/route/v1/zz_generated.model_name.go b/vendor/github.com/openshift/api/route/v1/zz_generated.model_name.go
new file mode 100644
index 0000000000..cbdd33762f
--- /dev/null
+++ b/vendor/github.com/openshift/api/route/v1/zz_generated.model_name.go
@@ -0,0 +1,86 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in LocalObjectReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.route.v1.LocalObjectReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Route) OpenAPIModelName() string {
+ return "com.github.openshift.api.route.v1.Route"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RouteHTTPHeader) OpenAPIModelName() string {
+ return "com.github.openshift.api.route.v1.RouteHTTPHeader"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RouteHTTPHeaderActionUnion) OpenAPIModelName() string {
+ return "com.github.openshift.api.route.v1.RouteHTTPHeaderActionUnion"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RouteHTTPHeaderActions) OpenAPIModelName() string {
+ return "com.github.openshift.api.route.v1.RouteHTTPHeaderActions"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RouteHTTPHeaders) OpenAPIModelName() string {
+ return "com.github.openshift.api.route.v1.RouteHTTPHeaders"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RouteIngress) OpenAPIModelName() string {
+ return "com.github.openshift.api.route.v1.RouteIngress"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RouteIngressCondition) OpenAPIModelName() string {
+ return "com.github.openshift.api.route.v1.RouteIngressCondition"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RouteList) OpenAPIModelName() string {
+ return "com.github.openshift.api.route.v1.RouteList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RoutePort) OpenAPIModelName() string {
+ return "com.github.openshift.api.route.v1.RoutePort"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RouteSetHTTPHeader) OpenAPIModelName() string {
+ return "com.github.openshift.api.route.v1.RouteSetHTTPHeader"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RouteSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.route.v1.RouteSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RouteStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.route.v1.RouteStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RouteTargetReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.route.v1.RouteTargetReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RouterShard) OpenAPIModelName() string {
+ return "com.github.openshift.api.route.v1.RouterShard"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TLSConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.route.v1.TLSConfig"
+}
diff --git a/vendor/github.com/openshift/api/samples/.codegen.yaml b/vendor/github.com/openshift/api/samples/.codegen.yaml
index ffa2c8d9b2..f10357951b 100644
--- a/vendor/github.com/openshift/api/samples/.codegen.yaml
+++ b/vendor/github.com/openshift/api/samples/.codegen.yaml
@@ -1,2 +1,4 @@
swaggerdocs:
commentPolicy: Warn
+protobuf:
+ disabled: false
diff --git a/vendor/github.com/openshift/api/samples/v1/doc.go b/vendor/github.com/openshift/api/samples/v1/doc.go
index d63c96b778..3e392e7f65 100644
--- a/vendor/github.com/openshift/api/samples/v1/doc.go
+++ b/vendor/github.com/openshift/api/samples/v1/doc.go
@@ -1,6 +1,7 @@
// +k8s:deepcopy-gen=package,register
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.samples.v1
// +groupName=samples.operator.openshift.io
// Package v1 ist he v1 version of the API.
diff --git a/vendor/github.com/openshift/api/samples/v1/zz_generated.model_name.go b/vendor/github.com/openshift/api/samples/v1/zz_generated.model_name.go
new file mode 100644
index 0000000000..bf37632ab9
--- /dev/null
+++ b/vendor/github.com/openshift/api/samples/v1/zz_generated.model_name.go
@@ -0,0 +1,31 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Config) OpenAPIModelName() string {
+ return "com.github.openshift.api.samples.v1.Config"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConfigCondition) OpenAPIModelName() string {
+ return "com.github.openshift.api.samples.v1.ConfigCondition"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConfigList) OpenAPIModelName() string {
+ return "com.github.openshift.api.samples.v1.ConfigList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConfigSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.samples.v1.ConfigSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ConfigStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.samples.v1.ConfigStatus"
+}
diff --git a/vendor/github.com/openshift/api/security/.codegen.yaml b/vendor/github.com/openshift/api/security/.codegen.yaml
new file mode 100644
index 0000000000..f7a37129a0
--- /dev/null
+++ b/vendor/github.com/openshift/api/security/.codegen.yaml
@@ -0,0 +1,2 @@
+protobuf:
+ disabled: false
diff --git a/vendor/github.com/openshift/api/security/v1/doc.go b/vendor/github.com/openshift/api/security/v1/doc.go
index 44fe37eb2d..4379db030e 100644
--- a/vendor/github.com/openshift/api/security/v1/doc.go
+++ b/vendor/github.com/openshift/api/security/v1/doc.go
@@ -2,6 +2,7 @@
// +k8s:conversion-gen=github.com/openshift/origin/pkg/security/apis/security
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.security.v1
// +groupName=security.openshift.io
// Package v1 is the v1 version of the API.
diff --git a/vendor/github.com/openshift/api/security/v1/generated.proto b/vendor/github.com/openshift/api/security/v1/generated.proto
index 933de5450e..bb8a37fc0f 100644
--- a/vendor/github.com/openshift/api/security/v1/generated.proto
+++ b/vendor/github.com/openshift/api/security/v1/generated.proto
@@ -246,7 +246,7 @@ message SecurityContextConstraints {
optional bool allowPrivilegedContainer = 3;
// defaultAddCapabilities is the default set of capabilities that will be added to the container
- // unless the pod spec specifically drops the capability. You may not list a capabiility in both
+ // unless the pod spec specifically drops the capability. You may not list a capability in both
// DefaultAddCapabilities and RequiredDropCapabilities.
// +nullable
// +listType=atomic
@@ -302,7 +302,6 @@ message SecurityContextConstraints {
// When "AllowHostLevel" is set, a pod author may set `hostUsers` to either `true` or `false`.
// When "RequirePodLevel" is set, a pod author must set `hostUsers` to `false`.
// When omitted, the default value is "AllowHostLevel".
- // +openshift:enable:FeatureGate=UserNamespacesPodSecurityStandards
// +kubebuilder:validation:Enum="AllowHostLevel";"RequirePodLevel"
// +kubebuilder:default:="AllowHostLevel"
// +default="AllowHostLevel"
@@ -358,7 +357,7 @@ message SecurityContextConstraints {
// seccompProfiles lists the allowed profiles that may be set for the pod or
// container's seccomp annotations. An unset (nil) or empty value means that no profiles may
- // be specifid by the pod or container. The wildcard '*' may be used to allow all profiles. When
+ // be specified by the pod or container. The wildcard '*' may be used to allow all profiles. When
// used to generate a value for a pod the first non-wildcard profile will be used as
// the default.
// +nullable
diff --git a/vendor/github.com/openshift/api/security/v1/types.go b/vendor/github.com/openshift/api/security/v1/types.go
index fb491480d7..8972b0dd68 100644
--- a/vendor/github.com/openshift/api/security/v1/types.go
+++ b/vendor/github.com/openshift/api/security/v1/types.go
@@ -57,7 +57,7 @@ type SecurityContextConstraints struct {
// allowPrivilegedContainer determines if a container can request to be run as privileged.
AllowPrivilegedContainer bool `json:"allowPrivilegedContainer" protobuf:"varint,3,opt,name=allowPrivilegedContainer"`
// defaultAddCapabilities is the default set of capabilities that will be added to the container
- // unless the pod spec specifically drops the capability. You may not list a capabiility in both
+ // unless the pod spec specifically drops the capability. You may not list a capability in both
// DefaultAddCapabilities and RequiredDropCapabilities.
// +nullable
// +listType=atomic
@@ -103,7 +103,6 @@ type SecurityContextConstraints struct {
// When "AllowHostLevel" is set, a pod author may set `hostUsers` to either `true` or `false`.
// When "RequirePodLevel" is set, a pod author must set `hostUsers` to `false`.
// When omitted, the default value is "AllowHostLevel".
- // +openshift:enable:FeatureGate=UserNamespacesPodSecurityStandards
// +kubebuilder:validation:Enum="AllowHostLevel";"RequirePodLevel"
// +kubebuilder:default:="AllowHostLevel"
// +default="AllowHostLevel"
@@ -151,7 +150,7 @@ type SecurityContextConstraints struct {
// seccompProfiles lists the allowed profiles that may be set for the pod or
// container's seccomp annotations. An unset (nil) or empty value means that no profiles may
- // be specifid by the pod or container. The wildcard '*' may be used to allow all profiles. When
+ // be specified by the pod or container. The wildcard '*' may be used to allow all profiles. When
// used to generate a value for a pod the first non-wildcard profile will be used as
// the default.
// +nullable
@@ -217,6 +216,7 @@ var (
FSTypeCSI FSType = "csi"
FSTypeEphemeral FSType = "ephemeral"
FSTypeImage FSType = "image"
+ FSTypeServiceAccountToken FSType = "serviceAccountToken"
FSTypeAll FSType = "*"
FSTypeNone FSType = "none"
)
diff --git a/vendor/github.com/openshift/api/security/v1/zz_generated.featuregated-crd-manifests.yaml b/vendor/github.com/openshift/api/security/v1/zz_generated.featuregated-crd-manifests.yaml
index 178c970780..86f78058a2 100644
--- a/vendor/github.com/openshift/api/security/v1/zz_generated.featuregated-crd-manifests.yaml
+++ b/vendor/github.com/openshift/api/security/v1/zz_generated.featuregated-crd-manifests.yaml
@@ -5,8 +5,7 @@ securitycontextconstraints.security.openshift.io:
CRDName: securitycontextconstraints.security.openshift.io
Capability: ""
Category: ""
- FeatureGates:
- - UserNamespacesPodSecurityStandards
+ FeatureGates: []
FilenameOperatorName: config-operator
FilenameOperatorOrdering: "01"
FilenameRunLevel: "0000_03"
diff --git a/vendor/github.com/openshift/api/security/v1/zz_generated.model_name.go b/vendor/github.com/openshift/api/security/v1/zz_generated.model_name.go
new file mode 100644
index 0000000000..74df1ce104
--- /dev/null
+++ b/vendor/github.com/openshift/api/security/v1/zz_generated.model_name.go
@@ -0,0 +1,101 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in AllowedFlexVolume) OpenAPIModelName() string {
+ return "com.github.openshift.api.security.v1.AllowedFlexVolume"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in FSGroupStrategyOptions) OpenAPIModelName() string {
+ return "com.github.openshift.api.security.v1.FSGroupStrategyOptions"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IDRange) OpenAPIModelName() string {
+ return "com.github.openshift.api.security.v1.IDRange"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PodSecurityPolicyReview) OpenAPIModelName() string {
+ return "com.github.openshift.api.security.v1.PodSecurityPolicyReview"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PodSecurityPolicyReviewSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.security.v1.PodSecurityPolicyReviewSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PodSecurityPolicyReviewStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.security.v1.PodSecurityPolicyReviewStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PodSecurityPolicySelfSubjectReview) OpenAPIModelName() string {
+ return "com.github.openshift.api.security.v1.PodSecurityPolicySelfSubjectReview"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PodSecurityPolicySelfSubjectReviewSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.security.v1.PodSecurityPolicySelfSubjectReviewSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PodSecurityPolicySubjectReview) OpenAPIModelName() string {
+ return "com.github.openshift.api.security.v1.PodSecurityPolicySubjectReview"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PodSecurityPolicySubjectReviewSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.security.v1.PodSecurityPolicySubjectReviewSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in PodSecurityPolicySubjectReviewStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.security.v1.PodSecurityPolicySubjectReviewStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RangeAllocation) OpenAPIModelName() string {
+ return "com.github.openshift.api.security.v1.RangeAllocation"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RangeAllocationList) OpenAPIModelName() string {
+ return "com.github.openshift.api.security.v1.RangeAllocationList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in RunAsUserStrategyOptions) OpenAPIModelName() string {
+ return "com.github.openshift.api.security.v1.RunAsUserStrategyOptions"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SELinuxContextStrategyOptions) OpenAPIModelName() string {
+ return "com.github.openshift.api.security.v1.SELinuxContextStrategyOptions"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SecurityContextConstraints) OpenAPIModelName() string {
+ return "com.github.openshift.api.security.v1.SecurityContextConstraints"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SecurityContextConstraintsList) OpenAPIModelName() string {
+ return "com.github.openshift.api.security.v1.SecurityContextConstraintsList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ServiceAccountPodSecurityPolicyReviewStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.security.v1.ServiceAccountPodSecurityPolicyReviewStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SupplementalGroupsStrategyOptions) OpenAPIModelName() string {
+ return "com.github.openshift.api.security.v1.SupplementalGroupsStrategyOptions"
+}
diff --git a/vendor/github.com/openshift/api/security/v1/zz_generated.swagger_doc_generated.go b/vendor/github.com/openshift/api/security/v1/zz_generated.swagger_doc_generated.go
index 29cddf7e64..67882a66e9 100644
--- a/vendor/github.com/openshift/api/security/v1/zz_generated.swagger_doc_generated.go
+++ b/vendor/github.com/openshift/api/security/v1/zz_generated.swagger_doc_generated.go
@@ -171,7 +171,7 @@ var map_SecurityContextConstraints = map[string]string{
"metadata": "metadata is the standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata",
"priority": "priority influences the sort order of SCCs when evaluating which SCCs to try first for a given pod request based on access in the Users and Groups fields. The higher the int, the higher priority. An unset value is considered a 0 priority. If scores for multiple SCCs are equal they will be sorted from most restrictive to least restrictive. If both priorities and restrictions are equal the SCCs will be sorted by name.",
"allowPrivilegedContainer": "allowPrivilegedContainer determines if a container can request to be run as privileged.",
- "defaultAddCapabilities": "defaultAddCapabilities is the default set of capabilities that will be added to the container unless the pod spec specifically drops the capability. You may not list a capabiility in both DefaultAddCapabilities and RequiredDropCapabilities.",
+ "defaultAddCapabilities": "defaultAddCapabilities is the default set of capabilities that will be added to the container unless the pod spec specifically drops the capability. You may not list a capability in both DefaultAddCapabilities and RequiredDropCapabilities.",
"requiredDropCapabilities": "requiredDropCapabilities are the capabilities that will be dropped from the container. These are required to be dropped and cannot be added.",
"allowedCapabilities": "allowedCapabilities is a list of capabilities that can be requested to add to the container. Capabilities in this field maybe added at the pod author's discretion. You must not list a capability in both AllowedCapabilities and RequiredDropCapabilities. To allow all capabilities you may use '*'.",
"allowHostDirVolumePlugin": "allowHostDirVolumePlugin determines if the policy allow containers to use the HostDir volume plugin",
@@ -191,7 +191,7 @@ var map_SecurityContextConstraints = map[string]string{
"readOnlyRootFilesystem": "readOnlyRootFilesystem when set to true will force containers to run with a read only root file system. If the container specifically requests to run with a non-read only root file system the SCC should deny the pod. If set to false the container may run with a read only root file system if it wishes but it will not be forced to.",
"users": "The users who have permissions to use this security context constraints",
"groups": "The groups that have permission to use this security context constraints",
- "seccompProfiles": "seccompProfiles lists the allowed profiles that may be set for the pod or container's seccomp annotations. An unset (nil) or empty value means that no profiles may be specifid by the pod or container.\tThe wildcard '*' may be used to allow all profiles. When used to generate a value for a pod the first non-wildcard profile will be used as the default.",
+ "seccompProfiles": "seccompProfiles lists the allowed profiles that may be set for the pod or container's seccomp annotations. An unset (nil) or empty value means that no profiles may be specified by the pod or container.\tThe wildcard '*' may be used to allow all profiles. When used to generate a value for a pod the first non-wildcard profile will be used as the default.",
"allowedUnsafeSysctls": "allowedUnsafeSysctls is a list of explicitly allowed unsafe sysctls, defaults to none. Each entry is either a plain sysctl name or ends in \"*\" in which case it is considered as a prefix of allowed sysctls. Single * means all unsafe sysctls are allowed. Kubelet has to whitelist all allowed unsafe sysctls explicitly to avoid rejection.\n\nExamples: e.g. \"foo/*\" allows \"foo/bar\", \"foo/baz\", etc. e.g. \"foo.*\" allows \"foo.bar\", \"foo.baz\", etc.",
"forbiddenSysctls": "forbiddenSysctls is a list of explicitly forbidden sysctls, defaults to none. Each entry is either a plain sysctl name or ends in \"*\" in which case it is considered as a prefix of forbidden sysctls. Single * means all sysctls are forbidden.\n\nExamples: e.g. \"foo/*\" forbids \"foo/bar\", \"foo/baz\", etc. e.g. \"foo.*\" forbids \"foo.bar\", \"foo.baz\", etc.",
}
diff --git a/vendor/github.com/openshift/api/servicecertsigner/v1alpha1/doc.go b/vendor/github.com/openshift/api/servicecertsigner/v1alpha1/doc.go
index 6ce02bdb3e..1f9da25524 100644
--- a/vendor/github.com/openshift/api/servicecertsigner/v1alpha1/doc.go
+++ b/vendor/github.com/openshift/api/servicecertsigner/v1alpha1/doc.go
@@ -1,6 +1,7 @@
// +k8s:deepcopy-gen=package,register
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.servicecertsigner.v1alpha1
// +groupName=servicecertsigner.config.openshift.io
package v1alpha1
diff --git a/vendor/github.com/openshift/api/servicecertsigner/v1alpha1/zz_generated.model_name.go b/vendor/github.com/openshift/api/servicecertsigner/v1alpha1/zz_generated.model_name.go
new file mode 100644
index 0000000000..446c48afeb
--- /dev/null
+++ b/vendor/github.com/openshift/api/servicecertsigner/v1alpha1/zz_generated.model_name.go
@@ -0,0 +1,26 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1alpha1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ServiceCertSignerOperatorConfig) OpenAPIModelName() string {
+ return "com.github.openshift.api.servicecertsigner.v1alpha1.ServiceCertSignerOperatorConfig"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ServiceCertSignerOperatorConfigList) OpenAPIModelName() string {
+ return "com.github.openshift.api.servicecertsigner.v1alpha1.ServiceCertSignerOperatorConfigList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ServiceCertSignerOperatorConfigSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.servicecertsigner.v1alpha1.ServiceCertSignerOperatorConfigSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in ServiceCertSignerOperatorConfigStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.servicecertsigner.v1alpha1.ServiceCertSignerOperatorConfigStatus"
+}
diff --git a/vendor/github.com/openshift/api/sharedresource/v1alpha1/doc.go b/vendor/github.com/openshift/api/sharedresource/v1alpha1/doc.go
index 833dd7f12c..3fa2207b8b 100644
--- a/vendor/github.com/openshift/api/sharedresource/v1alpha1/doc.go
+++ b/vendor/github.com/openshift/api/sharedresource/v1alpha1/doc.go
@@ -1,6 +1,7 @@
// +k8s:deepcopy-gen=package,register
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.sharedresource.v1alpha1
// +groupName=sharedresource.openshift.io
// Package v1alplha1 is the v1alpha1 version of the API.
diff --git a/vendor/github.com/openshift/api/sharedresource/v1alpha1/zz_generated.model_name.go b/vendor/github.com/openshift/api/sharedresource/v1alpha1/zz_generated.model_name.go
new file mode 100644
index 0000000000..d8c45a7aee
--- /dev/null
+++ b/vendor/github.com/openshift/api/sharedresource/v1alpha1/zz_generated.model_name.go
@@ -0,0 +1,56 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1alpha1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SharedConfigMap) OpenAPIModelName() string {
+ return "com.github.openshift.api.sharedresource.v1alpha1.SharedConfigMap"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SharedConfigMapList) OpenAPIModelName() string {
+ return "com.github.openshift.api.sharedresource.v1alpha1.SharedConfigMapList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SharedConfigMapReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.sharedresource.v1alpha1.SharedConfigMapReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SharedConfigMapSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.sharedresource.v1alpha1.SharedConfigMapSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SharedConfigMapStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.sharedresource.v1alpha1.SharedConfigMapStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SharedSecret) OpenAPIModelName() string {
+ return "com.github.openshift.api.sharedresource.v1alpha1.SharedSecret"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SharedSecretList) OpenAPIModelName() string {
+ return "com.github.openshift.api.sharedresource.v1alpha1.SharedSecretList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SharedSecretReference) OpenAPIModelName() string {
+ return "com.github.openshift.api.sharedresource.v1alpha1.SharedSecretReference"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SharedSecretSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.sharedresource.v1alpha1.SharedSecretSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in SharedSecretStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.sharedresource.v1alpha1.SharedSecretStatus"
+}
diff --git a/vendor/github.com/openshift/api/template/.codegen.yaml b/vendor/github.com/openshift/api/template/.codegen.yaml
new file mode 100644
index 0000000000..f7a37129a0
--- /dev/null
+++ b/vendor/github.com/openshift/api/template/.codegen.yaml
@@ -0,0 +1,2 @@
+protobuf:
+ disabled: false
diff --git a/vendor/github.com/openshift/api/template/v1/doc.go b/vendor/github.com/openshift/api/template/v1/doc.go
index 34f9f8d455..0cbca9f7e0 100644
--- a/vendor/github.com/openshift/api/template/v1/doc.go
+++ b/vendor/github.com/openshift/api/template/v1/doc.go
@@ -2,6 +2,7 @@
// +k8s:conversion-gen=github.com/openshift/origin/pkg/template/apis/template
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.template.v1
// +groupName=template.openshift.io
// Package v1 is the v1 version of the API.
diff --git a/vendor/github.com/openshift/api/template/v1/zz_generated.model_name.go b/vendor/github.com/openshift/api/template/v1/zz_generated.model_name.go
new file mode 100644
index 0000000000..eb14ace8de
--- /dev/null
+++ b/vendor/github.com/openshift/api/template/v1/zz_generated.model_name.go
@@ -0,0 +1,71 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BrokerTemplateInstance) OpenAPIModelName() string {
+ return "com.github.openshift.api.template.v1.BrokerTemplateInstance"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BrokerTemplateInstanceList) OpenAPIModelName() string {
+ return "com.github.openshift.api.template.v1.BrokerTemplateInstanceList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in BrokerTemplateInstanceSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.template.v1.BrokerTemplateInstanceSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Parameter) OpenAPIModelName() string {
+ return "com.github.openshift.api.template.v1.Parameter"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Template) OpenAPIModelName() string {
+ return "com.github.openshift.api.template.v1.Template"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TemplateInstance) OpenAPIModelName() string {
+ return "com.github.openshift.api.template.v1.TemplateInstance"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TemplateInstanceCondition) OpenAPIModelName() string {
+ return "com.github.openshift.api.template.v1.TemplateInstanceCondition"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TemplateInstanceList) OpenAPIModelName() string {
+ return "com.github.openshift.api.template.v1.TemplateInstanceList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TemplateInstanceObject) OpenAPIModelName() string {
+ return "com.github.openshift.api.template.v1.TemplateInstanceObject"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TemplateInstanceRequester) OpenAPIModelName() string {
+ return "com.github.openshift.api.template.v1.TemplateInstanceRequester"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TemplateInstanceSpec) OpenAPIModelName() string {
+ return "com.github.openshift.api.template.v1.TemplateInstanceSpec"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TemplateInstanceStatus) OpenAPIModelName() string {
+ return "com.github.openshift.api.template.v1.TemplateInstanceStatus"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in TemplateList) OpenAPIModelName() string {
+ return "com.github.openshift.api.template.v1.TemplateList"
+}
diff --git a/vendor/github.com/openshift/api/user/.codegen.yaml b/vendor/github.com/openshift/api/user/.codegen.yaml
new file mode 100644
index 0000000000..f7a37129a0
--- /dev/null
+++ b/vendor/github.com/openshift/api/user/.codegen.yaml
@@ -0,0 +1,2 @@
+protobuf:
+ disabled: false
diff --git a/vendor/github.com/openshift/api/user/v1/doc.go b/vendor/github.com/openshift/api/user/v1/doc.go
index 42287095e2..a8c24927d6 100644
--- a/vendor/github.com/openshift/api/user/v1/doc.go
+++ b/vendor/github.com/openshift/api/user/v1/doc.go
@@ -2,6 +2,7 @@
// +k8s:conversion-gen=github.com/openshift/origin/pkg/user/apis/user
// +k8s:defaulter-gen=TypeMeta
// +k8s:openapi-gen=true
+// +k8s:openapi-model-package=com.github.openshift.api.user.v1
// +groupName=user.openshift.io
// Package v1 is the v1 version of the API.
diff --git a/vendor/github.com/openshift/api/user/v1/zz_generated.model_name.go b/vendor/github.com/openshift/api/user/v1/zz_generated.model_name.go
new file mode 100644
index 0000000000..1d59e2115d
--- /dev/null
+++ b/vendor/github.com/openshift/api/user/v1/zz_generated.model_name.go
@@ -0,0 +1,41 @@
+//go:build !ignore_autogenerated
+// +build !ignore_autogenerated
+
+// Code generated by codegen. DO NOT EDIT.
+
+package v1
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Group) OpenAPIModelName() string {
+ return "com.github.openshift.api.user.v1.Group"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in GroupList) OpenAPIModelName() string {
+ return "com.github.openshift.api.user.v1.GroupList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in Identity) OpenAPIModelName() string {
+ return "com.github.openshift.api.user.v1.Identity"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in IdentityList) OpenAPIModelName() string {
+ return "com.github.openshift.api.user.v1.IdentityList"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in User) OpenAPIModelName() string {
+ return "com.github.openshift.api.user.v1.User"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in UserIdentityMapping) OpenAPIModelName() string {
+ return "com.github.openshift.api.user.v1.UserIdentityMapping"
+}
+
+// OpenAPIModelName returns the OpenAPI model name for this type.
+func (in UserList) OpenAPIModelName() string {
+ return "com.github.openshift.api.user.v1.UserList"
+}
diff --git a/vendor/github.com/openshift/build-machinery-go/.gitignore b/vendor/github.com/openshift/build-machinery-go/.gitignore
index 19607d9e60..0ff90ea9b3 100644
--- a/vendor/github.com/openshift/build-machinery-go/.gitignore
+++ b/vendor/github.com/openshift/build-machinery-go/.gitignore
@@ -1 +1,2 @@
*.log.raw
+make/examples/golang-versions-check/_output/
diff --git a/vendor/github.com/openshift/build-machinery-go/OWNERS b/vendor/github.com/openshift/build-machinery-go/OWNERS
index 1bbac46c7f..c54ee52b60 100644
--- a/vendor/github.com/openshift/build-machinery-go/OWNERS
+++ b/vendor/github.com/openshift/build-machinery-go/OWNERS
@@ -1,9 +1,9 @@
reviewers:
+ - control-plane-approvers
- 2uasimojo
- - benluddy
- jsafrane
- sanchezl
approvers:
- - benluddy
+ - control-plane-approvers
- jsafrane
- sanchezl
diff --git a/vendor/github.com/openshift/build-machinery-go/OWNERS_ALIASES b/vendor/github.com/openshift/build-machinery-go/OWNERS_ALIASES
new file mode 100644
index 0000000000..66464a003e
--- /dev/null
+++ b/vendor/github.com/openshift/build-machinery-go/OWNERS_ALIASES
@@ -0,0 +1,16 @@
+aliases:
+ control-plane-approvers:
+ - ardaguclu
+ - atiratree
+ - benluddy
+ - bertinatto
+ - everettraven
+ - flavianmissi
+ - gangwgr
+ - ingvagabund
+ - kaleemsiddiqu
+ - p0lyn0mial
+ - rh-roman
+ - ricardomaraschini
+ - tjungblu
+ - xueqzhan
diff --git a/vendor/github.com/openshift/build-machinery-go/make/lib/golang.mk b/vendor/github.com/openshift/build-machinery-go/make/lib/golang.mk
index d08f74a42d..6674f7eb65 100644
--- a/vendor/github.com/openshift/build-machinery-go/make/lib/golang.mk
+++ b/vendor/github.com/openshift/build-machinery-go/make/lib/golang.mk
@@ -60,10 +60,17 @@ ifndef OS_GIT_VERSION
OS_GIT_VERSION = $(SOURCE_GIT_TAG)
endif
+# OS_MAJOR_VERSION is populated by ART
+# If building out of the ART pipeline, fallback to '0' and let implementations decide how they handle it
+ifndef OS_MAJOR_VERSION
+ OS_MAJOR_VERSION = "0"
+endif
+
define version-ldflags
-X $(1).versionFromGit="$(OS_GIT_VERSION)" \
-X $(1).commitFromGit="$(SOURCE_GIT_COMMIT)" \
-X $(1).gitTreeState="$(SOURCE_GIT_TREE_STATE)" \
--X $(1).buildDate="$(shell date -u +'%Y-%m-%dT%H:%M:%SZ')"
+-X $(1).buildDate="$(shell date -u +'%Y-%m-%dT%H:%M:%SZ')" \
+-X $(1).majorFromGit="$(OS_MAJOR_VERSION)"
endef
GO_LD_FLAGS ?=-ldflags "$(call version-ldflags,$(GO_PACKAGE)/pkg/version) $(GO_LD_EXTRAFLAGS)"
diff --git a/vendor/github.com/openshift/build-machinery-go/make/targets/golang/version.mk b/vendor/github.com/openshift/build-machinery-go/make/targets/golang/version.mk
index bdd7f479da..9692c1d829 100644
--- a/vendor/github.com/openshift/build-machinery-go/make/targets/golang/version.mk
+++ b/vendor/github.com/openshift/build-machinery-go/make/targets/golang/version.mk
@@ -1,3 +1,23 @@
+# verify-golang-versions — ensure Go versions are consistent across build sources.
+#
+# OpenShift repos declare a Go version in up to three places: go.mod,
+# Dockerfile (builder image tag), and .ci-operator.yaml (CI build root).
+# When these drift apart, builds can silently use the wrong Go version or
+# fail in hard-to-diagnose ways. In particular, if go.mod declares a version
+# higher than the CI builder, the build fails because GOTOOLCHAIN=local
+# prevents Go from downloading a newer toolchain. This target catches
+# that drift at verify time by extracting the Go MAJOR.MINOR from each source
+# and comparing them.
+#
+# Rules:
+# 1. All CI sources (Dockerfile, .ci-operator.yaml) must declare the same Go version.
+# 2. go.mod may declare a version <= the CI version (Go is backward-compatible).
+# 3. go.mod must NOT declare a version higher than the CI builder.
+# 4. Every extracted version must be a valid MAJOR.MINOR number.
+#
+# Usage:
+# $(call verify-golang-versions,Dockerfile.rhel7)
+
include $(addprefix $(dir $(lastword $(MAKEFILE_LIST))), \
../../lib/golang.mk \
../../lib/tmp.mk \
@@ -9,11 +29,28 @@ include $(addprefix $(dir $(lastword $(MAKEFILE_LIST))), \
verify-golang-versions:
@if [ -f "$(PERMANENT_TMP)/golang-versions" ]; then \
- LINES=$$(cat "$(PERMANENT_TMP)/golang-versions" | sort | uniq | wc -l); \
- if [ $${LINES} -gt 1 ]; then \
+ GOMOD_VER=""; \
+ CI_VER=""; \
+ if [ -f "$(PERMANENT_TMP)/named-golang-versions" ]; then \
+ GOMOD_VER=$$(grep '^go\.mod:' "$(PERMANENT_TMP)/named-golang-versions" | sed 's/go\.mod: *//'); \
+ CI_VER=$$(grep -v '^go\.mod:' "$(PERMANENT_TMP)/named-golang-versions" | sed 's/^[^:]*: *//' | sort | uniq); \
+ fi; \
+ CI_COUNT=$$(echo "$${CI_VER}" | grep -c . 2>/dev/null || :); \
+ if [ "$${CI_COUNT}" -gt 1 ]; then \
echo "Golang version mismatch:"; \
cat "$(PERMANENT_TMP)/named-golang-versions" | sort | sed 's/^/- /'; \
false; \
+ elif [ -n "$${GOMOD_VER}" ] && [ -n "$${CI_VER}" ]; then \
+ GOMOD_MAJOR=$$(echo "$${GOMOD_VER}" | cut -d. -f1); \
+ GOMOD_MINOR=$$(echo "$${GOMOD_VER}" | cut -d. -f2); \
+ CI_MAJOR=$$(echo "$${CI_VER}" | cut -d. -f1); \
+ CI_MINOR=$$(echo "$${CI_VER}" | cut -d. -f2); \
+ if [ "$${GOMOD_MAJOR}" -gt "$${CI_MAJOR}" ] 2>/dev/null || \
+ { [ "$${GOMOD_MAJOR}" -eq "$${CI_MAJOR}" ] 2>/dev/null && [ "$${GOMOD_MINOR}" -gt "$${CI_MINOR}" ] 2>/dev/null; }; then \
+ echo "Golang version mismatch:"; \
+ cat "$(PERMANENT_TMP)/named-golang-versions" | sort | sed 's/^/- /'; \
+ false; \
+ fi; \
fi; \
fi
.PHONY: verify-golang-versions
@@ -24,6 +61,10 @@ define verify-golang-version-reference-internal
verify-golang-versions-$(1): .empty-golang-versions-files
verify-golang-versions-$(1):
@mkdir -p "$(PERMANENT_TMP)"
+ @if ! echo "$(2)" | grep -qxE '[0-9]+\.[0-9]+'; then \
+ echo "Error: could not extract a valid golang version from $(1) (got '$(2)')"; \
+ false; \
+ fi
@echo "$(1): $(2)" >> "$(PERMANENT_TMP)/named-golang-versions"
@echo "$(2)" >> "$(PERMANENT_TMP)/golang-versions"
.PHONY: verify-golang-versions-$(1)
diff --git a/vendor/github.com/openshift/client-go/apps/applyconfigurations/internal/internal.go b/vendor/github.com/openshift/client-go/apps/applyconfigurations/internal/internal.go
index d360fcba5e..d34284e991 100644
--- a/vendor/github.com/openshift/client-go/apps/applyconfigurations/internal/internal.go
+++ b/vendor/github.com/openshift/client-go/apps/applyconfigurations/internal/internal.go
@@ -1510,6 +1510,11 @@ var schemaYAML = typed.YAMLObject(`types:
- name: signerName
type:
scalar: string
+ - name: userAnnotations
+ type:
+ map:
+ elementType:
+ scalar: string
- name: io.k8s.api.core.v1.PodDNSConfig
map:
fields:
@@ -1574,6 +1579,16 @@ var schemaYAML = typed.YAMLObject(`types:
type:
scalar: string
default: ""
+- name: io.k8s.api.core.v1.PodSchedulingGroup
+ map:
+ fields:
+ - name: podGroupName
+ type:
+ scalar: string
+ unions:
+ - fields:
+ - fieldName: podGroupName
+ discriminatorValue: PodGroupName
- name: io.k8s.api.core.v1.PodSecurityContext
map:
fields:
@@ -1761,6 +1776,9 @@ var schemaYAML = typed.YAMLObject(`types:
elementRelationship: associative
keys:
- name
+ - name: schedulingGroup
+ type:
+ namedType: io.k8s.api.core.v1.PodSchedulingGroup
- name: securityContext
type:
namedType: io.k8s.api.core.v1.PodSecurityContext
diff --git a/vendor/github.com/openshift/client-go/apps/clientset/versioned/fake/clientset_generated.go b/vendor/github.com/openshift/client-go/apps/clientset/versioned/fake/clientset_generated.go
index 847a7ed2a3..cd640ccd68 100644
--- a/vendor/github.com/openshift/client-go/apps/clientset/versioned/fake/clientset_generated.go
+++ b/vendor/github.com/openshift/client-go/apps/clientset/versioned/fake/clientset_generated.go
@@ -19,10 +19,6 @@ import (
// It's backed by a very simple object tracker that processes creates, updates and deletions as-is,
// without applying any field management, validations and/or defaults. It shouldn't be considered a replacement
// for a real clientset and is mostly useful in simple unit tests.
-//
-// Deprecated: NewClientset replaces this with support for field management, which significantly improves
-// server side apply testing. NewClientset is only available when apply configurations are generated (e.g.
-// via --with-applyconfig).
func NewSimpleClientset(objects ...runtime.Object) *Clientset {
o := testing.NewObjectTracker(scheme, codecs.UniversalDecoder())
for _, obj := range objects {
@@ -68,7 +64,7 @@ func (c *Clientset) Tracker() testing.ObjectTracker {
return c.tracker
}
-// IsWatchListSemanticsSupported informs the reflector that this client
+// IsWatchListSemanticsUnSupported informs the reflector that this client
// doesn't support WatchList semantics.
//
// This is a synthetic method whose sole purpose is to satisfy the optional
@@ -83,6 +79,10 @@ func (c *Clientset) IsWatchListSemanticsUnSupported() bool {
// It's backed by a very simple object tracker that processes creates, updates and deletions as-is,
// without applying any validations and/or defaults. It shouldn't be considered a replacement
// for a real clientset and is mostly useful in simple unit tests.
+//
+// Compared to NewSimpleClientset, the Clientset returned here supports field tracking and thus
+// server-side apply. Beware though that support in that for CRDs is missing
+// (https://github.com/kubernetes/kubernetes/issues/126850).
func NewClientset(objects ...runtime.Object) *Clientset {
o := testing.NewFieldManagedObjectTracker(
scheme,
diff --git a/vendor/github.com/openshift/client-go/apps/informers/externalversions/apps/v1/deploymentconfig.go b/vendor/github.com/openshift/client-go/apps/informers/externalversions/apps/v1/deploymentconfig.go
index e2beccfd80..296eeb417f 100644
--- a/vendor/github.com/openshift/client-go/apps/informers/externalversions/apps/v1/deploymentconfig.go
+++ b/vendor/github.com/openshift/client-go/apps/informers/externalversions/apps/v1/deploymentconfig.go
@@ -12,6 +12,7 @@ import (
appsv1 "github.com/openshift/client-go/apps/listers/apps/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -33,48 +34,61 @@ type deploymentConfigInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewDeploymentConfigInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredDeploymentConfigInformer(client, namespace, resyncPeriod, indexers, nil)
+ return NewDeploymentConfigInformerWithOptions(client, namespace, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredDeploymentConfigInformer constructs a new informer for DeploymentConfig type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredDeploymentConfigInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewDeploymentConfigInformerWithOptions(client, namespace, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewDeploymentConfigInformerWithOptions constructs a new informer for DeploymentConfig type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewDeploymentConfigInformerWithOptions(client versioned.Interface, namespace string, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "apps.openshift.io", Version: "v1", Resource: "deploymentconfigs"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.AppsV1().DeploymentConfigs(namespace).List(context.Background(), options)
+ return client.AppsV1().DeploymentConfigs(namespace).List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.AppsV1().DeploymentConfigs(namespace).Watch(context.Background(), options)
+ return client.AppsV1().DeploymentConfigs(namespace).Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.AppsV1().DeploymentConfigs(namespace).List(ctx, options)
+ return client.AppsV1().DeploymentConfigs(namespace).List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.AppsV1().DeploymentConfigs(namespace).Watch(ctx, options)
+ return client.AppsV1().DeploymentConfigs(namespace).Watch(ctx, opts)
},
}, client),
&apiappsv1.DeploymentConfig{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *deploymentConfigInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredDeploymentConfigInformer(client, f.namespace, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewDeploymentConfigInformerWithOptions(client, f.namespace, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *deploymentConfigInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/apps/informers/externalversions/factory.go b/vendor/github.com/openshift/client-go/apps/informers/externalversions/factory.go
index 825dd4566b..53a559e436 100644
--- a/vendor/github.com/openshift/client-go/apps/informers/externalversions/factory.go
+++ b/vendor/github.com/openshift/client-go/apps/informers/externalversions/factory.go
@@ -3,6 +3,7 @@
package externalversions
import (
+ context "context"
reflect "reflect"
sync "sync"
time "time"
@@ -13,6 +14,7 @@ import (
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
schema "k8s.io/apimachinery/pkg/runtime/schema"
+ wait "k8s.io/apimachinery/pkg/util/wait"
cache "k8s.io/client-go/tools/cache"
)
@@ -27,6 +29,7 @@ type sharedInformerFactory struct {
defaultResync time.Duration
customResync map[reflect.Type]time.Duration
transform cache.TransformFunc
+ informerName *cache.InformerName
informers map[reflect.Type]cache.SharedIndexInformer
// startedInformers is used for tracking which informers have been started.
@@ -73,6 +76,21 @@ func WithTransform(transform cache.TransformFunc) SharedInformerOption {
}
}
+// WithInformerName sets the InformerName for informer identity used in metrics.
+// The InformerName must be created via cache.NewInformerName() at startup,
+// which validates global uniqueness. Each informer type will register its
+// GVR under this name.
+func WithInformerName(informerName *cache.InformerName) SharedInformerOption {
+ return func(factory *sharedInformerFactory) *sharedInformerFactory {
+ factory.informerName = informerName
+ return factory
+ }
+}
+
+func (f *sharedInformerFactory) InformerName() *cache.InformerName {
+ return f.informerName
+}
+
// NewSharedInformerFactory constructs a new instance of sharedInformerFactory for all namespaces.
func NewSharedInformerFactory(client versioned.Interface, defaultResync time.Duration) SharedInformerFactory {
return NewSharedInformerFactoryWithOptions(client, defaultResync)
@@ -107,6 +125,10 @@ func NewSharedInformerFactoryWithOptions(client versioned.Interface, defaultResy
}
func (f *sharedInformerFactory) Start(stopCh <-chan struct{}) {
+ f.StartWithContext(wait.ContextForChannel(stopCh))
+}
+
+func (f *sharedInformerFactory) StartWithContext(ctx context.Context) {
f.lock.Lock()
defer f.lock.Unlock()
@@ -116,15 +138,9 @@ func (f *sharedInformerFactory) Start(stopCh <-chan struct{}) {
for informerType, informer := range f.informers {
if !f.startedInformers[informerType] {
- f.wg.Add(1)
- // We need a new variable in each loop iteration,
- // otherwise the goroutine would use the loop variable
- // and that keeps changing.
- informer := informer
- go func() {
- defer f.wg.Done()
- informer.Run(stopCh)
- }()
+ f.wg.Go(func() {
+ informer.RunWithContext(ctx)
+ })
f.startedInformers[informerType] = true
}
}
@@ -137,9 +153,15 @@ func (f *sharedInformerFactory) Shutdown() {
// Will return immediately if there is nothing to wait for.
f.wg.Wait()
+ f.informerName.Release()
}
func (f *sharedInformerFactory) WaitForCacheSync(stopCh <-chan struct{}) map[reflect.Type]bool {
+ result := f.WaitForCacheSyncWithContext(wait.ContextForChannel(stopCh))
+ return result.Synced
+}
+
+func (f *sharedInformerFactory) WaitForCacheSyncWithContext(ctx context.Context) cache.SyncResult {
informers := func() map[reflect.Type]cache.SharedIndexInformer {
f.lock.Lock()
defer f.lock.Unlock()
@@ -153,10 +175,31 @@ func (f *sharedInformerFactory) WaitForCacheSync(stopCh <-chan struct{}) map[ref
return informers
}()
- res := map[reflect.Type]bool{}
+ // Wait for informers to sync, without polling.
+ cacheSyncs := make([]cache.DoneChecker, 0, len(informers))
+ for _, informer := range informers {
+ cacheSyncs = append(cacheSyncs, informer.HasSyncedChecker())
+ }
+ cache.WaitFor(ctx, "" /* no logging */, cacheSyncs...)
+
+ res := cache.SyncResult{
+ Synced: make(map[reflect.Type]bool, len(informers)),
+ }
+ failed := false
for informType, informer := range informers {
- res[informType] = cache.WaitForCacheSync(stopCh, informer.HasSynced)
+ hasSynced := informer.HasSynced()
+ if !hasSynced {
+ failed = true
+ }
+ res.Synced[informType] = hasSynced
}
+ if failed {
+ // context.Cause is more informative than ctx.Err().
+ // This must be non-nil, otherwise WaitFor wouldn't have stopped
+ // prematurely.
+ res.Err = context.Cause(ctx)
+ }
+
return res
}
@@ -178,7 +221,9 @@ func (f *sharedInformerFactory) InformerFor(obj runtime.Object, newFunc internal
}
informer = newFunc(f.client, resyncPeriod)
- informer.SetTransform(f.transform)
+ if f.transform != nil {
+ informer.SetTransform(f.transform)
+ }
f.informers[informerType] = informer
return informer
@@ -195,27 +240,46 @@ func (f *sharedInformerFactory) InformerFor(obj runtime.Object, newFunc internal
// defer factory.WaitForStop() // Returns immediately if nothing was started.
// genericInformer := factory.ForResource(resource)
// typedInformer := factory.SomeAPIGroup().V1().SomeType()
-// factory.Start(ctx.Done()) // Start processing these informers.
-// synced := factory.WaitForCacheSync(ctx.Done())
-// for v, ok := range synced {
-// if !ok {
-// fmt.Fprintf(os.Stderr, "caches failed to sync: %v", v)
-// return
-// }
+// handle, err := typeInformer.Informer().AddEventHandler(...)
+// if err != nil {
+// return fmt.Errorf("register event handler: %v", err)
+// }
+// defer typeInformer.Informer().RemoveEventHandler(handle) // Avoids leaking goroutines.
+// factory.StartWithContext(ctx) // Start processing these informers.
+// synced := factory.WaitForCacheSyncWithContext(ctx)
+// if err := synced.AsError(); err != nil {
+// return err
+// }
+// for v := range synced {
+// // Only if desired log some information similar to this.
+// fmt.Fprintf(os.Stdout, "cache synced: %s", v)
+// }
+//
+// // Also make sure that all of the initial cache events have been delivered.
+// if !WaitFor(ctx, "event handler sync", handle.HasSyncedChecker()) {
+// // Must have failed because of context.
+// return fmt.Errorf("sync event handler: %w", context.Cause(ctx))
// }
//
// // Creating informers can also be created after Start, but then
// // Start must be called again:
// anotherGenericInformer := factory.ForResource(resource)
-// factory.Start(ctx.Done())
+// factory.StartWithContext(ctx)
type SharedInformerFactory interface {
internalinterfaces.SharedInformerFactory
// Start initializes all requested informers. They are handled in goroutines
// which run until the stop channel gets closed.
// Warning: Start does not block. When run in a go-routine, it will race with a later WaitForCacheSync.
+ //
+ // Contextual logging: StartWithContext should be used instead of Start in code which supports contextual logging.
Start(stopCh <-chan struct{})
+ // StartWithContext initializes all requested informers. They are handled in goroutines
+ // which run until the context gets canceled.
+ // Warning: StartWithContext does not block. When run in a go-routine, it will race with a later WaitForCacheSync.
+ StartWithContext(ctx context.Context)
+
// Shutdown marks a factory as shutting down. At that point no new
// informers can be started anymore and Start will return without
// doing anything.
@@ -230,8 +294,14 @@ type SharedInformerFactory interface {
// WaitForCacheSync blocks until all started informers' caches were synced
// or the stop channel gets closed.
+ //
+ // Contextual logging: WaitForCacheSync should be used instead of WaitForCacheSync in code which supports contextual logging. It also returns a more useful result.
WaitForCacheSync(stopCh <-chan struct{}) map[reflect.Type]bool
+ // WaitForCacheSyncWithContext blocks until all started informers' caches were synced
+ // or the context gets canceled.
+ WaitForCacheSyncWithContext(ctx context.Context) cache.SyncResult
+
// ForResource gives generic access to a shared informer of the matching type.
ForResource(resource schema.GroupVersionResource) (GenericInformer, error)
diff --git a/vendor/github.com/openshift/client-go/apps/informers/externalversions/internalinterfaces/factory_interfaces.go b/vendor/github.com/openshift/client-go/apps/informers/externalversions/internalinterfaces/factory_interfaces.go
index 308cc551b4..338efb809b 100644
--- a/vendor/github.com/openshift/client-go/apps/informers/externalversions/internalinterfaces/factory_interfaces.go
+++ b/vendor/github.com/openshift/client-go/apps/informers/externalversions/internalinterfaces/factory_interfaces.go
@@ -18,7 +18,26 @@ type NewInformerFunc func(versioned.Interface, time.Duration) cache.SharedIndexI
type SharedInformerFactory interface {
Start(stopCh <-chan struct{})
InformerFor(obj runtime.Object, newFunc NewInformerFunc) cache.SharedIndexInformer
+ InformerName() *cache.InformerName
}
// TweakListOptionsFunc is a function that transforms a v1.ListOptions.
type TweakListOptionsFunc func(*v1.ListOptions)
+
+// InformerOptions holds the options for creating an informer.
+type InformerOptions struct {
+ // ResyncPeriod is the resync period for this informer.
+ // If not set, defaults to 0 (no resync).
+ ResyncPeriod time.Duration
+
+ // Indexers are the indexers for this informer.
+ Indexers cache.Indexers
+
+ // InformerName is used to uniquely identify this informer for metrics.
+ // If not set, metrics will not be published for this informer.
+ // Use cache.NewInformerName() to create an InformerName at startup.
+ InformerName *cache.InformerName
+
+ // TweakListOptions is an optional function to modify the list options.
+ TweakListOptions TweakListOptionsFunc
+}
diff --git a/vendor/github.com/openshift/client-go/build/clientset/versioned/fake/clientset_generated.go b/vendor/github.com/openshift/client-go/build/clientset/versioned/fake/clientset_generated.go
index 0aff9c6884..673e66bf93 100644
--- a/vendor/github.com/openshift/client-go/build/clientset/versioned/fake/clientset_generated.go
+++ b/vendor/github.com/openshift/client-go/build/clientset/versioned/fake/clientset_generated.go
@@ -19,10 +19,6 @@ import (
// It's backed by a very simple object tracker that processes creates, updates and deletions as-is,
// without applying any field management, validations and/or defaults. It shouldn't be considered a replacement
// for a real clientset and is mostly useful in simple unit tests.
-//
-// Deprecated: NewClientset replaces this with support for field management, which significantly improves
-// server side apply testing. NewClientset is only available when apply configurations are generated (e.g.
-// via --with-applyconfig).
func NewSimpleClientset(objects ...runtime.Object) *Clientset {
o := testing.NewObjectTracker(scheme, codecs.UniversalDecoder())
for _, obj := range objects {
@@ -68,7 +64,7 @@ func (c *Clientset) Tracker() testing.ObjectTracker {
return c.tracker
}
-// IsWatchListSemanticsSupported informs the reflector that this client
+// IsWatchListSemanticsUnSupported informs the reflector that this client
// doesn't support WatchList semantics.
//
// This is a synthetic method whose sole purpose is to satisfy the optional
@@ -83,6 +79,10 @@ func (c *Clientset) IsWatchListSemanticsUnSupported() bool {
// It's backed by a very simple object tracker that processes creates, updates and deletions as-is,
// without applying any validations and/or defaults. It shouldn't be considered a replacement
// for a real clientset and is mostly useful in simple unit tests.
+//
+// Compared to NewSimpleClientset, the Clientset returned here supports field tracking and thus
+// server-side apply. Beware though that support in that for CRDs is missing
+// (https://github.com/kubernetes/kubernetes/issues/126850).
func NewClientset(objects ...runtime.Object) *Clientset {
o := testing.NewFieldManagedObjectTracker(
scheme,
diff --git a/vendor/github.com/openshift/client-go/build/informers/externalversions/build/v1/build.go b/vendor/github.com/openshift/client-go/build/informers/externalversions/build/v1/build.go
index 4e99781005..3f5e90c250 100644
--- a/vendor/github.com/openshift/client-go/build/informers/externalversions/build/v1/build.go
+++ b/vendor/github.com/openshift/client-go/build/informers/externalversions/build/v1/build.go
@@ -12,6 +12,7 @@ import (
buildv1 "github.com/openshift/client-go/build/listers/build/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -33,48 +34,61 @@ type buildInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewBuildInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredBuildInformer(client, namespace, resyncPeriod, indexers, nil)
+ return NewBuildInformerWithOptions(client, namespace, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredBuildInformer constructs a new informer for Build type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredBuildInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewBuildInformerWithOptions(client, namespace, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewBuildInformerWithOptions constructs a new informer for Build type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewBuildInformerWithOptions(client versioned.Interface, namespace string, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "build.openshift.io", Version: "v1", Resource: "builds"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.BuildV1().Builds(namespace).List(context.Background(), options)
+ return client.BuildV1().Builds(namespace).List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.BuildV1().Builds(namespace).Watch(context.Background(), options)
+ return client.BuildV1().Builds(namespace).Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.BuildV1().Builds(namespace).List(ctx, options)
+ return client.BuildV1().Builds(namespace).List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.BuildV1().Builds(namespace).Watch(ctx, options)
+ return client.BuildV1().Builds(namespace).Watch(ctx, opts)
},
}, client),
&apibuildv1.Build{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *buildInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredBuildInformer(client, f.namespace, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewBuildInformerWithOptions(client, f.namespace, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *buildInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/build/informers/externalversions/build/v1/buildconfig.go b/vendor/github.com/openshift/client-go/build/informers/externalversions/build/v1/buildconfig.go
index a523b4abc6..2c019d3385 100644
--- a/vendor/github.com/openshift/client-go/build/informers/externalversions/build/v1/buildconfig.go
+++ b/vendor/github.com/openshift/client-go/build/informers/externalversions/build/v1/buildconfig.go
@@ -12,6 +12,7 @@ import (
buildv1 "github.com/openshift/client-go/build/listers/build/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -33,48 +34,61 @@ type buildConfigInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewBuildConfigInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredBuildConfigInformer(client, namespace, resyncPeriod, indexers, nil)
+ return NewBuildConfigInformerWithOptions(client, namespace, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredBuildConfigInformer constructs a new informer for BuildConfig type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredBuildConfigInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewBuildConfigInformerWithOptions(client, namespace, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewBuildConfigInformerWithOptions constructs a new informer for BuildConfig type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewBuildConfigInformerWithOptions(client versioned.Interface, namespace string, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "build.openshift.io", Version: "v1", Resource: "buildconfigs"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.BuildV1().BuildConfigs(namespace).List(context.Background(), options)
+ return client.BuildV1().BuildConfigs(namespace).List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.BuildV1().BuildConfigs(namespace).Watch(context.Background(), options)
+ return client.BuildV1().BuildConfigs(namespace).Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.BuildV1().BuildConfigs(namespace).List(ctx, options)
+ return client.BuildV1().BuildConfigs(namespace).List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.BuildV1().BuildConfigs(namespace).Watch(ctx, options)
+ return client.BuildV1().BuildConfigs(namespace).Watch(ctx, opts)
},
}, client),
&apibuildv1.BuildConfig{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *buildConfigInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredBuildConfigInformer(client, f.namespace, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewBuildConfigInformerWithOptions(client, f.namespace, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *buildConfigInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/build/informers/externalversions/factory.go b/vendor/github.com/openshift/client-go/build/informers/externalversions/factory.go
index 4ccf074e8d..bbdd416b22 100644
--- a/vendor/github.com/openshift/client-go/build/informers/externalversions/factory.go
+++ b/vendor/github.com/openshift/client-go/build/informers/externalversions/factory.go
@@ -3,6 +3,7 @@
package externalversions
import (
+ context "context"
reflect "reflect"
sync "sync"
time "time"
@@ -13,6 +14,7 @@ import (
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
schema "k8s.io/apimachinery/pkg/runtime/schema"
+ wait "k8s.io/apimachinery/pkg/util/wait"
cache "k8s.io/client-go/tools/cache"
)
@@ -27,6 +29,7 @@ type sharedInformerFactory struct {
defaultResync time.Duration
customResync map[reflect.Type]time.Duration
transform cache.TransformFunc
+ informerName *cache.InformerName
informers map[reflect.Type]cache.SharedIndexInformer
// startedInformers is used for tracking which informers have been started.
@@ -73,6 +76,21 @@ func WithTransform(transform cache.TransformFunc) SharedInformerOption {
}
}
+// WithInformerName sets the InformerName for informer identity used in metrics.
+// The InformerName must be created via cache.NewInformerName() at startup,
+// which validates global uniqueness. Each informer type will register its
+// GVR under this name.
+func WithInformerName(informerName *cache.InformerName) SharedInformerOption {
+ return func(factory *sharedInformerFactory) *sharedInformerFactory {
+ factory.informerName = informerName
+ return factory
+ }
+}
+
+func (f *sharedInformerFactory) InformerName() *cache.InformerName {
+ return f.informerName
+}
+
// NewSharedInformerFactory constructs a new instance of sharedInformerFactory for all namespaces.
func NewSharedInformerFactory(client versioned.Interface, defaultResync time.Duration) SharedInformerFactory {
return NewSharedInformerFactoryWithOptions(client, defaultResync)
@@ -107,6 +125,10 @@ func NewSharedInformerFactoryWithOptions(client versioned.Interface, defaultResy
}
func (f *sharedInformerFactory) Start(stopCh <-chan struct{}) {
+ f.StartWithContext(wait.ContextForChannel(stopCh))
+}
+
+func (f *sharedInformerFactory) StartWithContext(ctx context.Context) {
f.lock.Lock()
defer f.lock.Unlock()
@@ -116,15 +138,9 @@ func (f *sharedInformerFactory) Start(stopCh <-chan struct{}) {
for informerType, informer := range f.informers {
if !f.startedInformers[informerType] {
- f.wg.Add(1)
- // We need a new variable in each loop iteration,
- // otherwise the goroutine would use the loop variable
- // and that keeps changing.
- informer := informer
- go func() {
- defer f.wg.Done()
- informer.Run(stopCh)
- }()
+ f.wg.Go(func() {
+ informer.RunWithContext(ctx)
+ })
f.startedInformers[informerType] = true
}
}
@@ -137,9 +153,15 @@ func (f *sharedInformerFactory) Shutdown() {
// Will return immediately if there is nothing to wait for.
f.wg.Wait()
+ f.informerName.Release()
}
func (f *sharedInformerFactory) WaitForCacheSync(stopCh <-chan struct{}) map[reflect.Type]bool {
+ result := f.WaitForCacheSyncWithContext(wait.ContextForChannel(stopCh))
+ return result.Synced
+}
+
+func (f *sharedInformerFactory) WaitForCacheSyncWithContext(ctx context.Context) cache.SyncResult {
informers := func() map[reflect.Type]cache.SharedIndexInformer {
f.lock.Lock()
defer f.lock.Unlock()
@@ -153,10 +175,31 @@ func (f *sharedInformerFactory) WaitForCacheSync(stopCh <-chan struct{}) map[ref
return informers
}()
- res := map[reflect.Type]bool{}
+ // Wait for informers to sync, without polling.
+ cacheSyncs := make([]cache.DoneChecker, 0, len(informers))
+ for _, informer := range informers {
+ cacheSyncs = append(cacheSyncs, informer.HasSyncedChecker())
+ }
+ cache.WaitFor(ctx, "" /* no logging */, cacheSyncs...)
+
+ res := cache.SyncResult{
+ Synced: make(map[reflect.Type]bool, len(informers)),
+ }
+ failed := false
for informType, informer := range informers {
- res[informType] = cache.WaitForCacheSync(stopCh, informer.HasSynced)
+ hasSynced := informer.HasSynced()
+ if !hasSynced {
+ failed = true
+ }
+ res.Synced[informType] = hasSynced
}
+ if failed {
+ // context.Cause is more informative than ctx.Err().
+ // This must be non-nil, otherwise WaitFor wouldn't have stopped
+ // prematurely.
+ res.Err = context.Cause(ctx)
+ }
+
return res
}
@@ -178,7 +221,9 @@ func (f *sharedInformerFactory) InformerFor(obj runtime.Object, newFunc internal
}
informer = newFunc(f.client, resyncPeriod)
- informer.SetTransform(f.transform)
+ if f.transform != nil {
+ informer.SetTransform(f.transform)
+ }
f.informers[informerType] = informer
return informer
@@ -195,27 +240,46 @@ func (f *sharedInformerFactory) InformerFor(obj runtime.Object, newFunc internal
// defer factory.WaitForStop() // Returns immediately if nothing was started.
// genericInformer := factory.ForResource(resource)
// typedInformer := factory.SomeAPIGroup().V1().SomeType()
-// factory.Start(ctx.Done()) // Start processing these informers.
-// synced := factory.WaitForCacheSync(ctx.Done())
-// for v, ok := range synced {
-// if !ok {
-// fmt.Fprintf(os.Stderr, "caches failed to sync: %v", v)
-// return
-// }
+// handle, err := typeInformer.Informer().AddEventHandler(...)
+// if err != nil {
+// return fmt.Errorf("register event handler: %v", err)
+// }
+// defer typeInformer.Informer().RemoveEventHandler(handle) // Avoids leaking goroutines.
+// factory.StartWithContext(ctx) // Start processing these informers.
+// synced := factory.WaitForCacheSyncWithContext(ctx)
+// if err := synced.AsError(); err != nil {
+// return err
+// }
+// for v := range synced {
+// // Only if desired log some information similar to this.
+// fmt.Fprintf(os.Stdout, "cache synced: %s", v)
+// }
+//
+// // Also make sure that all of the initial cache events have been delivered.
+// if !WaitFor(ctx, "event handler sync", handle.HasSyncedChecker()) {
+// // Must have failed because of context.
+// return fmt.Errorf("sync event handler: %w", context.Cause(ctx))
// }
//
// // Creating informers can also be created after Start, but then
// // Start must be called again:
// anotherGenericInformer := factory.ForResource(resource)
-// factory.Start(ctx.Done())
+// factory.StartWithContext(ctx)
type SharedInformerFactory interface {
internalinterfaces.SharedInformerFactory
// Start initializes all requested informers. They are handled in goroutines
// which run until the stop channel gets closed.
// Warning: Start does not block. When run in a go-routine, it will race with a later WaitForCacheSync.
+ //
+ // Contextual logging: StartWithContext should be used instead of Start in code which supports contextual logging.
Start(stopCh <-chan struct{})
+ // StartWithContext initializes all requested informers. They are handled in goroutines
+ // which run until the context gets canceled.
+ // Warning: StartWithContext does not block. When run in a go-routine, it will race with a later WaitForCacheSync.
+ StartWithContext(ctx context.Context)
+
// Shutdown marks a factory as shutting down. At that point no new
// informers can be started anymore and Start will return without
// doing anything.
@@ -230,8 +294,14 @@ type SharedInformerFactory interface {
// WaitForCacheSync blocks until all started informers' caches were synced
// or the stop channel gets closed.
+ //
+ // Contextual logging: WaitForCacheSync should be used instead of WaitForCacheSync in code which supports contextual logging. It also returns a more useful result.
WaitForCacheSync(stopCh <-chan struct{}) map[reflect.Type]bool
+ // WaitForCacheSyncWithContext blocks until all started informers' caches were synced
+ // or the context gets canceled.
+ WaitForCacheSyncWithContext(ctx context.Context) cache.SyncResult
+
// ForResource gives generic access to a shared informer of the matching type.
ForResource(resource schema.GroupVersionResource) (GenericInformer, error)
diff --git a/vendor/github.com/openshift/client-go/build/informers/externalversions/internalinterfaces/factory_interfaces.go b/vendor/github.com/openshift/client-go/build/informers/externalversions/internalinterfaces/factory_interfaces.go
index 1bcbd5975a..c205ab8b00 100644
--- a/vendor/github.com/openshift/client-go/build/informers/externalversions/internalinterfaces/factory_interfaces.go
+++ b/vendor/github.com/openshift/client-go/build/informers/externalversions/internalinterfaces/factory_interfaces.go
@@ -18,7 +18,26 @@ type NewInformerFunc func(versioned.Interface, time.Duration) cache.SharedIndexI
type SharedInformerFactory interface {
Start(stopCh <-chan struct{})
InformerFor(obj runtime.Object, newFunc NewInformerFunc) cache.SharedIndexInformer
+ InformerName() *cache.InformerName
}
// TweakListOptionsFunc is a function that transforms a v1.ListOptions.
type TweakListOptionsFunc func(*v1.ListOptions)
+
+// InformerOptions holds the options for creating an informer.
+type InformerOptions struct {
+ // ResyncPeriod is the resync period for this informer.
+ // If not set, defaults to 0 (no resync).
+ ResyncPeriod time.Duration
+
+ // Indexers are the indexers for this informer.
+ Indexers cache.Indexers
+
+ // InformerName is used to uniquely identify this informer for metrics.
+ // If not set, metrics will not be published for this informer.
+ // Use cache.NewInformerName() to create an InformerName at startup.
+ InformerName *cache.InformerName
+
+ // TweakListOptions is an optional function to modify the list options.
+ TweakListOptions TweakListOptionsFunc
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/apiserverencryption.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/apiserverencryption.go
index f4214f6a9d..5a9af0cb27 100644
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/apiserverencryption.go
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/apiserverencryption.go
@@ -32,7 +32,7 @@ type APIServerEncryptionApplyConfiguration struct {
// The Key Management Service (KMS) instance provides symmetric encryption and is responsible for
// managing the lifecyle of the encryption keys outside of the control plane.
// This allows integration with an external provider to manage the data encryption keys securely.
- KMS *KMSConfigApplyConfiguration `json:"kms,omitempty"`
+ KMS *KMSPluginConfigApplyConfiguration `json:"kms,omitempty"`
}
// APIServerEncryptionApplyConfiguration constructs a declarative configuration of the APIServerEncryption type for use with
@@ -52,7 +52,7 @@ func (b *APIServerEncryptionApplyConfiguration) WithType(value configv1.Encrypti
// WithKMS sets the KMS field in the declarative configuration to the given value
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
// If called multiple times, the KMS field is set to the value of the last call.
-func (b *APIServerEncryptionApplyConfiguration) WithKMS(value *KMSConfigApplyConfiguration) *APIServerEncryptionApplyConfiguration {
+func (b *APIServerEncryptionApplyConfiguration) WithKMS(value *KMSPluginConfigApplyConfiguration) *APIServerEncryptionApplyConfiguration {
b.KMS = value
return b
}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/apiserverspec.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/apiserverspec.go
index 5b674ae05d..42392a353e 100644
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/apiserverspec.go
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/apiserverspec.go
@@ -2,6 +2,10 @@
package v1
+import (
+ configv1 "github.com/openshift/api/config/v1"
+)
+
// APIServerSpecApplyConfiguration represents a declarative configuration of the APIServerSpec type for use
// with apply.
type APIServerSpecApplyConfiguration struct {
@@ -26,6 +30,37 @@ type APIServerSpecApplyConfiguration struct {
// When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
// The current default is the Intermediate profile.
TLSSecurityProfile *TLSSecurityProfileApplyConfiguration `json:"tlsSecurityProfile,omitempty"`
+ // tlsAdherence controls if components in the cluster adhere to the TLS security profile
+ // configured on this APIServer resource.
+ //
+ // Valid values are "LegacyAdheringComponentsOnly" and "StrictAllComponents".
+ //
+ // When set to "LegacyAdheringComponentsOnly", components that already honor the
+ // cluster-wide TLS profile continue to do so. Components that do not already honor
+ // it continue to use their individual TLS configurations.
+ //
+ // When set to "StrictAllComponents", all components must honor the configured TLS
+ // profile unless they have a component-specific TLS configuration that overrides
+ // it. This mode is recommended for security-conscious deployments and is required
+ // for certain compliance frameworks.
+ //
+ // Note: Some components such as Kubelet and IngressController have their own
+ // dedicated TLS configuration mechanisms via KubeletConfig and IngressController
+ // CRs respectively. When these component-specific TLS configurations are set,
+ // they take precedence over the cluster-wide tlsSecurityProfile. When not set,
+ // these components fall back to the cluster-wide default.
+ //
+ // Components that encounter an unknown value for tlsAdherence should treat it
+ // as "StrictAllComponents" and log a warning to ensure forward compatibility
+ // while defaulting to the more secure behavior.
+ //
+ // This field is optional.
+ // When omitted, this means the user has no opinion and the platform is left
+ // to choose reasonable defaults. These defaults are subject to change over time.
+ // The current default is LegacyAdheringComponentsOnly.
+ //
+ // Once set, this field may be changed to a different value, but may not be removed.
+ TLSAdherence *configv1.TLSAdherencePolicy `json:"tlsAdherence,omitempty"`
// audit specifies the settings for audit configuration to be applied to all OpenShift-provided
// API servers in the cluster.
Audit *AuditApplyConfiguration `json:"audit,omitempty"`
@@ -79,6 +114,14 @@ func (b *APIServerSpecApplyConfiguration) WithTLSSecurityProfile(value *TLSSecur
return b
}
+// WithTLSAdherence sets the TLSAdherence field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the TLSAdherence field is set to the value of the last call.
+func (b *APIServerSpecApplyConfiguration) WithTLSAdherence(value configv1.TLSAdherencePolicy) *APIServerSpecApplyConfiguration {
+ b.TLSAdherence = &value
+ return b
+}
+
// WithAudit sets the Audit field in the declarative configuration to the given value
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
// If called multiple times, the Audit field is set to the value of the last call.
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/awsdnsspec.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/awsdnsspec.go
index ec57615082..457cb43aca 100644
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/awsdnsspec.go
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/awsdnsspec.go
@@ -10,6 +10,11 @@ type AWSDNSSpecApplyConfiguration struct {
// privateZoneIAMRole contains the ARN of an IAM role that should be assumed when performing
// operations on the cluster's private hosted zone specified in the cluster DNS config.
// When left empty, no role should be assumed.
+ //
+ // The ARN must follow the format: arn::iam:::role/, where:
+ // is the AWS partition (aws, aws-cn, aws-us-gov, or aws-eusc),
+ // is a 12-digit numeric identifier for the AWS account,
+ // is the IAM role name.
PrivateZoneIAMRole *string `json:"privateZoneIAMRole,omitempty"`
}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/awskmsconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/awskmsconfig.go
deleted file mode 100644
index 483e570da2..0000000000
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/awskmsconfig.go
+++ /dev/null
@@ -1,42 +0,0 @@
-// Code generated by applyconfiguration-gen. DO NOT EDIT.
-
-package v1
-
-// AWSKMSConfigApplyConfiguration represents a declarative configuration of the AWSKMSConfig type for use
-// with apply.
-//
-// AWSKMSConfig defines the KMS config specific to AWS KMS provider
-type AWSKMSConfigApplyConfiguration struct {
- // keyARN specifies the Amazon Resource Name (ARN) of the AWS KMS key used for encryption.
- // The value must adhere to the format `arn:aws:kms:::key/`, where:
- // - `` is the AWS region consisting of lowercase letters and hyphens followed by a number.
- // - `` is a 12-digit numeric identifier for the AWS account.
- // - `` is a unique identifier for the KMS key, consisting of lowercase hexadecimal characters and hyphens.
- KeyARN *string `json:"keyARN,omitempty"`
- // region specifies the AWS region where the KMS instance exists, and follows the format
- // `--`, e.g.: `us-east-1`.
- // Only lowercase letters and hyphens followed by numbers are allowed.
- Region *string `json:"region,omitempty"`
-}
-
-// AWSKMSConfigApplyConfiguration constructs a declarative configuration of the AWSKMSConfig type for use with
-// apply.
-func AWSKMSConfig() *AWSKMSConfigApplyConfiguration {
- return &AWSKMSConfigApplyConfiguration{}
-}
-
-// WithKeyARN sets the KeyARN field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the KeyARN field is set to the value of the last call.
-func (b *AWSKMSConfigApplyConfiguration) WithKeyARN(value string) *AWSKMSConfigApplyConfiguration {
- b.KeyARN = &value
- return b
-}
-
-// WithRegion sets the Region field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the Region field is set to the value of the last call.
-func (b *AWSKMSConfigApplyConfiguration) WithRegion(value string) *AWSKMSConfigApplyConfiguration {
- b.Region = &value
- return b
-}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/awsplatformstatus.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/awsplatformstatus.go
index 33007c2103..457caa686a 100644
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/awsplatformstatus.go
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/awsplatformstatus.go
@@ -33,6 +33,15 @@ type AWSPlatformStatusApplyConfiguration struct {
// network resources. This controls whether AWS resources are created with
// IPv4-only, or dual-stack networking with IPv4 or IPv6 as the primary
// protocol family.
+ //
+ // Valid values are:
+ // * "IPv4" (default): Cloud platform resources use IPv4 addressing only.
+ // * "DualStackIPv6Primary": Cloud platform resources use dual-stack networking with IPv6 as the primary protocol family.
+ // * "DualStackIPv4Primary": Cloud platform resources use dual-stack networking with IPv4 as the primary protocol family.
+ //
+ // When omitted, this field defaults to "IPv4".
+ //
+ // This field is immutable and cannot be changed once set.
IPFamily *configv1.IPFamilyType `json:"ipFamily,omitempty"`
}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/baremetalplatformstatus.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/baremetalplatformstatus.go
index 1f6dd6df6b..f90232bff9 100644
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/baremetalplatformstatus.go
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/baremetalplatformstatus.go
@@ -45,6 +45,17 @@ type BareMetalPlatformStatusApplyConfiguration struct {
NodeDNSIP *string `json:"nodeDNSIP,omitempty"`
// loadBalancer defines how the load balancer used by the cluster is configured.
LoadBalancer *BareMetalPlatformLoadBalancerApplyConfiguration `json:"loadBalancer,omitempty"`
+ // vipManagement indicates which VIP management mechanism is active
+ // on this cluster.
+ // Allowed values are `Keepalived`, `BGP`, and omitted.
+ // Once set to a non-empty value, this field is immutable.
+ // When set to `BGP`, kube-vip (Routing Table Mode) and frr-k8s are
+ // deployed as static pods to advertise VIPs via BGP, replacing the
+ // default keepalived/VRRP mechanism.
+ // When set to `Keepalived`, the default keepalived-based VIP
+ // management is used.
+ // When omitted, the default keepalived-based VIP management is used.
+ VIPManagement *configv1.VIPManagementType `json:"vipManagement,omitempty"`
// dnsRecordsType determines whether records for api, api-int, and ingress
// are provided by the internal DNS service or externally.
// Allowed values are `Internal`, `External`, and omitted.
@@ -120,6 +131,14 @@ func (b *BareMetalPlatformStatusApplyConfiguration) WithLoadBalancer(value *Bare
return b
}
+// WithVIPManagement sets the VIPManagement field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the VIPManagement field is set to the value of the last call.
+func (b *BareMetalPlatformStatusApplyConfiguration) WithVIPManagement(value configv1.VIPManagementType) *BareMetalPlatformStatusApplyConfiguration {
+ b.VIPManagement = &value
+ return b
+}
+
// WithDNSRecordsType sets the DNSRecordsType field in the declarative configuration to the given value
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
// If called multiple times, the DNSRecordsType field is set to the value of the last call.
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/clientcredentialconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/clientcredentialconfig.go
new file mode 100644
index 0000000000..c23f4d5307
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/clientcredentialconfig.go
@@ -0,0 +1,98 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+import (
+ configv1 "github.com/openshift/api/config/v1"
+)
+
+// ClientCredentialConfigApplyConfiguration represents a declarative configuration of the ClientCredentialConfig type for use
+// with apply.
+//
+// ClientCredentialConfig configures the client credentials and token endpoint
+// to use to get an access token via the OAuth2 client credentials grant flow.
+type ClientCredentialConfigApplyConfiguration struct {
+ // clientID is a required client identifier to use during the OAuth2 client credentials flow.
+ // clientID must be at least 1 character in length, must not exceed 256 characters in length,
+ // and must only contain printable ASCII characters.
+ ClientID *string `json:"clientID,omitempty"`
+ // clientSecret is a required reference to a Secret in the openshift-config namespace to be used
+ // as the client secret during the OAuth2 client credentials flow.
+ //
+ // The key 'client-secret' is used to locate the client secret data in the Secret.
+ ClientSecret *ClientSecretSecretReferenceApplyConfiguration `json:"clientSecret,omitempty"`
+ // tokenEndpoint is a required URL to query for an access token using
+ // the client credential OAuth2 flow.
+ // tokenEndpoint must be at least 1 character in length and must not exceed 2048 characters in length.
+ // tokenEndpoint must be a valid HTTPS URL.
+ // tokenEndpoint must have a host and a path.
+ // tokenEndpoint must not contain query parameters, fragments,
+ // or user information (e.g., "user:password@host").
+ TokenEndpoint *string `json:"tokenEndpoint,omitempty"`
+ // scopes is an optional list of OAuth2 scopes to request when obtaining
+ // an access token.
+ //
+ // If not specified, the token endpoint's default scopes
+ // will be used.
+ //
+ // When specified, there must be at least 1 entry and must not exceed 16 entries.
+ // Each entry must be at least 1 character in length and must not exceed 256 characters in length.
+ // Each entry must only contain printable ASCII characters, excluding spaces, double quotes and backslashes.
+ // Entries must be unique.
+ Scopes []configv1.OAuth2Scope `json:"scopes,omitempty"`
+ // tls is an optional field that allows configuring the TLS
+ // settings used to interact with the identity provider
+ // as an OAuth2 client.
+ //
+ // When omitted, system default TLS settings will be used
+ // for the OAuth2 client.
+ TLS *ExternalSourceTLSApplyConfiguration `json:"tls,omitempty"`
+}
+
+// ClientCredentialConfigApplyConfiguration constructs a declarative configuration of the ClientCredentialConfig type for use with
+// apply.
+func ClientCredentialConfig() *ClientCredentialConfigApplyConfiguration {
+ return &ClientCredentialConfigApplyConfiguration{}
+}
+
+// WithClientID sets the ClientID field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the ClientID field is set to the value of the last call.
+func (b *ClientCredentialConfigApplyConfiguration) WithClientID(value string) *ClientCredentialConfigApplyConfiguration {
+ b.ClientID = &value
+ return b
+}
+
+// WithClientSecret sets the ClientSecret field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the ClientSecret field is set to the value of the last call.
+func (b *ClientCredentialConfigApplyConfiguration) WithClientSecret(value *ClientSecretSecretReferenceApplyConfiguration) *ClientCredentialConfigApplyConfiguration {
+ b.ClientSecret = value
+ return b
+}
+
+// WithTokenEndpoint sets the TokenEndpoint field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the TokenEndpoint field is set to the value of the last call.
+func (b *ClientCredentialConfigApplyConfiguration) WithTokenEndpoint(value string) *ClientCredentialConfigApplyConfiguration {
+ b.TokenEndpoint = &value
+ return b
+}
+
+// WithScopes adds the given value to the Scopes field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the Scopes field.
+func (b *ClientCredentialConfigApplyConfiguration) WithScopes(values ...configv1.OAuth2Scope) *ClientCredentialConfigApplyConfiguration {
+ for i := range values {
+ b.Scopes = append(b.Scopes, values[i])
+ }
+ return b
+}
+
+// WithTLS sets the TLS field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the TLS field is set to the value of the last call.
+func (b *ClientCredentialConfigApplyConfiguration) WithTLS(value *ExternalSourceTLSApplyConfiguration) *ClientCredentialConfigApplyConfiguration {
+ b.TLS = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/clientsecretsecretreference.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/clientsecretsecretreference.go
new file mode 100644
index 0000000000..5b2a8fe03f
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/clientsecretsecretreference.go
@@ -0,0 +1,32 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+// ClientSecretSecretReferenceApplyConfiguration represents a declarative configuration of the ClientSecretSecretReference type for use
+// with apply.
+//
+// ClientSecretSecretReference is a reference to a Secret in the openshift-config
+// namespace that should be used for configuring the client secret to be
+// used when sourcing claims from external sources with the client credential authentication flow.
+type ClientSecretSecretReferenceApplyConfiguration struct {
+ // name is the required name of the Secret that exists in the openshift-config namespace.
+ //
+ // It must be at least 1 character in length, must not exceed 253 characters in length,
+ // must start and end with a lowercase alphanumeric character, and must only contain
+ // lowercase alphanumeric characters, '-' or '.'.
+ Name *string `json:"name,omitempty"`
+}
+
+// ClientSecretSecretReferenceApplyConfiguration constructs a declarative configuration of the ClientSecretSecretReference type for use with
+// apply.
+func ClientSecretSecretReference() *ClientSecretSecretReferenceApplyConfiguration {
+ return &ClientSecretSecretReferenceApplyConfiguration{}
+}
+
+// WithName sets the Name field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Name field is set to the value of the last call.
+func (b *ClientSecretSecretReferenceApplyConfiguration) WithName(value string) *ClientSecretSecretReferenceApplyConfiguration {
+ b.Name = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/componentroutespec.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/componentroutespec.go
index f4e3838447..990a7230a1 100644
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/componentroutespec.go
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/componentroutespec.go
@@ -28,6 +28,24 @@ type ComponentRouteSpecApplyConfiguration struct {
// If the custom hostname uses the default routing suffix of the cluster,
// the Secret specification for a serving certificate will not be needed.
ServingCertKeyPairSecret *SecretNameReferenceApplyConfiguration `json:"servingCertKeyPairSecret,omitempty"`
+ // labels defines additional labels to be applied to the route created
+ // for the component. These labels are used by the IngressController to
+ // determine which routes it should manage. Changing labels may cause the
+ // route to be reassigned to a different IngressController.
+ // When omitted, no additional labels are applied to the component route.
+ // When specified, labels must contain at least one entry, up to a maximum of 8.
+ // Label keys must be valid qualified names, consisting of a name segment and
+ // an optional prefix separated by a slash (/). The name segment must be at most
+ // 63 characters in length and must consist only of alphanumeric characters,
+ // dashes (-), underscores (_), and dots (.), and must start and end with
+ // alphanumeric characters. The prefix, if specified, must be a DNS subdomain:
+ // at most 253 characters in length, consisting of dot-separated segments where
+ // each segment starts and ends with an alphanumeric character.
+ // Label values must be either empty or 1-63 characters, consisting of
+ // alphanumeric characters, dashes (-), underscores (_), or dots (.),
+ // starting and ending with an alphanumeric character.
+ // Keys with the "kubernetes.io/", "k8s.io/", and "openshift.io/" prefixes are reserved and may not be used.
+ Labels map[string]configv1.LabelValue `json:"labels,omitempty"`
}
// ComponentRouteSpecApplyConfiguration constructs a declarative configuration of the ComponentRouteSpec type for use with
@@ -67,3 +85,17 @@ func (b *ComponentRouteSpecApplyConfiguration) WithServingCertKeyPairSecret(valu
b.ServingCertKeyPairSecret = value
return b
}
+
+// WithLabels puts the entries into the Labels field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, the entries provided by each call will be put on the Labels field,
+// overwriting an existing map entries in Labels field with the same key.
+func (b *ComponentRouteSpecApplyConfiguration) WithLabels(entries map[string]configv1.LabelValue) *ComponentRouteSpecApplyConfiguration {
+ if b.Labels == nil && len(entries) > 0 {
+ b.Labels = make(map[string]configv1.LabelValue, len(entries))
+ }
+ for k, v := range entries {
+ b.Labels[k] = v
+ }
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/criocredentialproviderconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/criocredentialproviderconfig.go
new file mode 100644
index 0000000000..94be7a1cda
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/criocredentialproviderconfig.go
@@ -0,0 +1,285 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+import (
+ configv1 "github.com/openshift/api/config/v1"
+ internal "github.com/openshift/client-go/config/applyconfigurations/internal"
+ apismetav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
+ types "k8s.io/apimachinery/pkg/types"
+ managedfields "k8s.io/apimachinery/pkg/util/managedfields"
+ metav1 "k8s.io/client-go/applyconfigurations/meta/v1"
+)
+
+// CRIOCredentialProviderConfigApplyConfiguration represents a declarative configuration of the CRIOCredentialProviderConfig type for use
+// with apply.
+//
+// CRIOCredentialProviderConfig holds cluster-wide singleton resource configurations for CRI-O credential provider, the name of this instance is "cluster". CRI-O credential provider is a binary shipped with CRI-O that provides a way to obtain container image pull credentials from external sources.
+// For example, it can be used to fetch mirror registry credentials from secrets resources in the cluster within the same namespace the pod will be running in.
+// CRIOCredentialProviderConfig configuration specifies the pod image sources registries that should trigger the CRI-O credential provider execution, which will resolve the CRI-O mirror configurations and obtain the necessary credentials for pod creation.
+// Note: Configuration changes will only take effect after the kubelet restarts, which is automatically managed by the cluster during rollout.
+//
+// The resource is a singleton named "cluster".
+//
+// Compatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer).
+type CRIOCredentialProviderConfigApplyConfiguration struct {
+ metav1.TypeMetaApplyConfiguration `json:",inline"`
+ // metadata is the standard object's metadata.
+ // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
+ *metav1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"`
+ // spec defines the desired configuration of the CRI-O Credential Provider.
+ // This field is required and must be provided when creating the resource.
+ Spec *CRIOCredentialProviderConfigSpecApplyConfiguration `json:"spec,omitempty"`
+ // status represents the current state of the CRIOCredentialProviderConfig.
+ // When omitted or nil, it indicates that the status has not yet been set by the controller.
+ // The controller will populate this field with validation conditions and operational state.
+ Status *CRIOCredentialProviderConfigStatusApplyConfiguration `json:"status,omitempty"`
+}
+
+// CRIOCredentialProviderConfig constructs a declarative configuration of the CRIOCredentialProviderConfig type for use with
+// apply.
+func CRIOCredentialProviderConfig(name string) *CRIOCredentialProviderConfigApplyConfiguration {
+ b := &CRIOCredentialProviderConfigApplyConfiguration{}
+ b.WithName(name)
+ b.WithKind("CRIOCredentialProviderConfig")
+ b.WithAPIVersion("config.openshift.io/v1")
+ return b
+}
+
+// ExtractCRIOCredentialProviderConfigFrom extracts the applied configuration owned by fieldManager from
+// cRIOCredentialProviderConfig for the specified subresource. Pass an empty string for subresource to extract
+// the main resource. Common subresources include "status", "scale", etc.
+// cRIOCredentialProviderConfig must be a unmodified CRIOCredentialProviderConfig API object that was retrieved from the Kubernetes API.
+// ExtractCRIOCredentialProviderConfigFrom provides a way to perform a extract/modify-in-place/apply workflow.
+// Note that an extracted apply configuration will contain fewer fields than what the fieldManager previously
+// applied if another fieldManager has updated or force applied any of the previously applied fields.
+func ExtractCRIOCredentialProviderConfigFrom(cRIOCredentialProviderConfig *configv1.CRIOCredentialProviderConfig, fieldManager string, subresource string) (*CRIOCredentialProviderConfigApplyConfiguration, error) {
+ b := &CRIOCredentialProviderConfigApplyConfiguration{}
+ err := managedfields.ExtractInto(cRIOCredentialProviderConfig, internal.Parser().Type("com.github.openshift.api.config.v1.CRIOCredentialProviderConfig"), fieldManager, b, subresource)
+ if err != nil {
+ return nil, err
+ }
+ b.WithName(cRIOCredentialProviderConfig.Name)
+
+ b.WithKind("CRIOCredentialProviderConfig")
+ b.WithAPIVersion("config.openshift.io/v1")
+ return b, nil
+}
+
+// ExtractCRIOCredentialProviderConfig extracts the applied configuration owned by fieldManager from
+// cRIOCredentialProviderConfig. If no managedFields are found in cRIOCredentialProviderConfig for fieldManager, a
+// CRIOCredentialProviderConfigApplyConfiguration is returned with only the Name, Namespace (if applicable),
+// APIVersion and Kind populated. It is possible that no managed fields were found for because other
+// field managers have taken ownership of all the fields previously owned by fieldManager, or because
+// the fieldManager never owned fields any fields.
+// cRIOCredentialProviderConfig must be a unmodified CRIOCredentialProviderConfig API object that was retrieved from the Kubernetes API.
+// ExtractCRIOCredentialProviderConfig provides a way to perform a extract/modify-in-place/apply workflow.
+// Note that an extracted apply configuration will contain fewer fields than what the fieldManager previously
+// applied if another fieldManager has updated or force applied any of the previously applied fields.
+func ExtractCRIOCredentialProviderConfig(cRIOCredentialProviderConfig *configv1.CRIOCredentialProviderConfig, fieldManager string) (*CRIOCredentialProviderConfigApplyConfiguration, error) {
+ return ExtractCRIOCredentialProviderConfigFrom(cRIOCredentialProviderConfig, fieldManager, "")
+}
+
+// ExtractCRIOCredentialProviderConfigStatus extracts the applied configuration owned by fieldManager from
+// cRIOCredentialProviderConfig for the status subresource.
+func ExtractCRIOCredentialProviderConfigStatus(cRIOCredentialProviderConfig *configv1.CRIOCredentialProviderConfig, fieldManager string) (*CRIOCredentialProviderConfigApplyConfiguration, error) {
+ return ExtractCRIOCredentialProviderConfigFrom(cRIOCredentialProviderConfig, fieldManager, "status")
+}
+
+func (b CRIOCredentialProviderConfigApplyConfiguration) IsApplyConfiguration() {}
+
+// WithKind sets the Kind field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Kind field is set to the value of the last call.
+func (b *CRIOCredentialProviderConfigApplyConfiguration) WithKind(value string) *CRIOCredentialProviderConfigApplyConfiguration {
+ b.TypeMetaApplyConfiguration.Kind = &value
+ return b
+}
+
+// WithAPIVersion sets the APIVersion field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the APIVersion field is set to the value of the last call.
+func (b *CRIOCredentialProviderConfigApplyConfiguration) WithAPIVersion(value string) *CRIOCredentialProviderConfigApplyConfiguration {
+ b.TypeMetaApplyConfiguration.APIVersion = &value
+ return b
+}
+
+// WithName sets the Name field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Name field is set to the value of the last call.
+func (b *CRIOCredentialProviderConfigApplyConfiguration) WithName(value string) *CRIOCredentialProviderConfigApplyConfiguration {
+ b.ensureObjectMetaApplyConfigurationExists()
+ b.ObjectMetaApplyConfiguration.Name = &value
+ return b
+}
+
+// WithGenerateName sets the GenerateName field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the GenerateName field is set to the value of the last call.
+func (b *CRIOCredentialProviderConfigApplyConfiguration) WithGenerateName(value string) *CRIOCredentialProviderConfigApplyConfiguration {
+ b.ensureObjectMetaApplyConfigurationExists()
+ b.ObjectMetaApplyConfiguration.GenerateName = &value
+ return b
+}
+
+// WithNamespace sets the Namespace field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Namespace field is set to the value of the last call.
+func (b *CRIOCredentialProviderConfigApplyConfiguration) WithNamespace(value string) *CRIOCredentialProviderConfigApplyConfiguration {
+ b.ensureObjectMetaApplyConfigurationExists()
+ b.ObjectMetaApplyConfiguration.Namespace = &value
+ return b
+}
+
+// WithUID sets the UID field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the UID field is set to the value of the last call.
+func (b *CRIOCredentialProviderConfigApplyConfiguration) WithUID(value types.UID) *CRIOCredentialProviderConfigApplyConfiguration {
+ b.ensureObjectMetaApplyConfigurationExists()
+ b.ObjectMetaApplyConfiguration.UID = &value
+ return b
+}
+
+// WithResourceVersion sets the ResourceVersion field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the ResourceVersion field is set to the value of the last call.
+func (b *CRIOCredentialProviderConfigApplyConfiguration) WithResourceVersion(value string) *CRIOCredentialProviderConfigApplyConfiguration {
+ b.ensureObjectMetaApplyConfigurationExists()
+ b.ObjectMetaApplyConfiguration.ResourceVersion = &value
+ return b
+}
+
+// WithGeneration sets the Generation field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Generation field is set to the value of the last call.
+func (b *CRIOCredentialProviderConfigApplyConfiguration) WithGeneration(value int64) *CRIOCredentialProviderConfigApplyConfiguration {
+ b.ensureObjectMetaApplyConfigurationExists()
+ b.ObjectMetaApplyConfiguration.Generation = &value
+ return b
+}
+
+// WithCreationTimestamp sets the CreationTimestamp field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the CreationTimestamp field is set to the value of the last call.
+func (b *CRIOCredentialProviderConfigApplyConfiguration) WithCreationTimestamp(value apismetav1.Time) *CRIOCredentialProviderConfigApplyConfiguration {
+ b.ensureObjectMetaApplyConfigurationExists()
+ b.ObjectMetaApplyConfiguration.CreationTimestamp = &value
+ return b
+}
+
+// WithDeletionTimestamp sets the DeletionTimestamp field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the DeletionTimestamp field is set to the value of the last call.
+func (b *CRIOCredentialProviderConfigApplyConfiguration) WithDeletionTimestamp(value apismetav1.Time) *CRIOCredentialProviderConfigApplyConfiguration {
+ b.ensureObjectMetaApplyConfigurationExists()
+ b.ObjectMetaApplyConfiguration.DeletionTimestamp = &value
+ return b
+}
+
+// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the DeletionGracePeriodSeconds field is set to the value of the last call.
+func (b *CRIOCredentialProviderConfigApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *CRIOCredentialProviderConfigApplyConfiguration {
+ b.ensureObjectMetaApplyConfigurationExists()
+ b.ObjectMetaApplyConfiguration.DeletionGracePeriodSeconds = &value
+ return b
+}
+
+// WithLabels puts the entries into the Labels field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, the entries provided by each call will be put on the Labels field,
+// overwriting an existing map entries in Labels field with the same key.
+func (b *CRIOCredentialProviderConfigApplyConfiguration) WithLabels(entries map[string]string) *CRIOCredentialProviderConfigApplyConfiguration {
+ b.ensureObjectMetaApplyConfigurationExists()
+ if b.ObjectMetaApplyConfiguration.Labels == nil && len(entries) > 0 {
+ b.ObjectMetaApplyConfiguration.Labels = make(map[string]string, len(entries))
+ }
+ for k, v := range entries {
+ b.ObjectMetaApplyConfiguration.Labels[k] = v
+ }
+ return b
+}
+
+// WithAnnotations puts the entries into the Annotations field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, the entries provided by each call will be put on the Annotations field,
+// overwriting an existing map entries in Annotations field with the same key.
+func (b *CRIOCredentialProviderConfigApplyConfiguration) WithAnnotations(entries map[string]string) *CRIOCredentialProviderConfigApplyConfiguration {
+ b.ensureObjectMetaApplyConfigurationExists()
+ if b.ObjectMetaApplyConfiguration.Annotations == nil && len(entries) > 0 {
+ b.ObjectMetaApplyConfiguration.Annotations = make(map[string]string, len(entries))
+ }
+ for k, v := range entries {
+ b.ObjectMetaApplyConfiguration.Annotations[k] = v
+ }
+ return b
+}
+
+// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the OwnerReferences field.
+func (b *CRIOCredentialProviderConfigApplyConfiguration) WithOwnerReferences(values ...*metav1.OwnerReferenceApplyConfiguration) *CRIOCredentialProviderConfigApplyConfiguration {
+ b.ensureObjectMetaApplyConfigurationExists()
+ for i := range values {
+ if values[i] == nil {
+ panic("nil value passed to WithOwnerReferences")
+ }
+ b.ObjectMetaApplyConfiguration.OwnerReferences = append(b.ObjectMetaApplyConfiguration.OwnerReferences, *values[i])
+ }
+ return b
+}
+
+// WithFinalizers adds the given value to the Finalizers field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the Finalizers field.
+func (b *CRIOCredentialProviderConfigApplyConfiguration) WithFinalizers(values ...string) *CRIOCredentialProviderConfigApplyConfiguration {
+ b.ensureObjectMetaApplyConfigurationExists()
+ for i := range values {
+ b.ObjectMetaApplyConfiguration.Finalizers = append(b.ObjectMetaApplyConfiguration.Finalizers, values[i])
+ }
+ return b
+}
+
+func (b *CRIOCredentialProviderConfigApplyConfiguration) ensureObjectMetaApplyConfigurationExists() {
+ if b.ObjectMetaApplyConfiguration == nil {
+ b.ObjectMetaApplyConfiguration = &metav1.ObjectMetaApplyConfiguration{}
+ }
+}
+
+// WithSpec sets the Spec field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Spec field is set to the value of the last call.
+func (b *CRIOCredentialProviderConfigApplyConfiguration) WithSpec(value *CRIOCredentialProviderConfigSpecApplyConfiguration) *CRIOCredentialProviderConfigApplyConfiguration {
+ b.Spec = value
+ return b
+}
+
+// WithStatus sets the Status field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Status field is set to the value of the last call.
+func (b *CRIOCredentialProviderConfigApplyConfiguration) WithStatus(value *CRIOCredentialProviderConfigStatusApplyConfiguration) *CRIOCredentialProviderConfigApplyConfiguration {
+ b.Status = value
+ return b
+}
+
+// GetKind retrieves the value of the Kind field in the declarative configuration.
+func (b *CRIOCredentialProviderConfigApplyConfiguration) GetKind() *string {
+ return b.TypeMetaApplyConfiguration.Kind
+}
+
+// GetAPIVersion retrieves the value of the APIVersion field in the declarative configuration.
+func (b *CRIOCredentialProviderConfigApplyConfiguration) GetAPIVersion() *string {
+ return b.TypeMetaApplyConfiguration.APIVersion
+}
+
+// GetName retrieves the value of the Name field in the declarative configuration.
+func (b *CRIOCredentialProviderConfigApplyConfiguration) GetName() *string {
+ b.ensureObjectMetaApplyConfigurationExists()
+ return b.ObjectMetaApplyConfiguration.Name
+}
+
+// GetNamespace retrieves the value of the Namespace field in the declarative configuration.
+func (b *CRIOCredentialProviderConfigApplyConfiguration) GetNamespace() *string {
+ b.ensureObjectMetaApplyConfigurationExists()
+ return b.ObjectMetaApplyConfiguration.Namespace
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/criocredentialproviderconfigspec.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/criocredentialproviderconfigspec.go
new file mode 100644
index 0000000000..4820041d74
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/criocredentialproviderconfigspec.go
@@ -0,0 +1,72 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+import (
+ configv1 "github.com/openshift/api/config/v1"
+)
+
+// CRIOCredentialProviderConfigSpecApplyConfiguration represents a declarative configuration of the CRIOCredentialProviderConfigSpec type for use
+// with apply.
+//
+// CRIOCredentialProviderConfigSpec defines the desired configuration of the CRI-O Credential Provider.
+type CRIOCredentialProviderConfigSpecApplyConfiguration struct {
+ // matchImages is a list of string patterns used to determine whether
+ // the CRI-O credential provider should be invoked for a given image. This list is
+ // passed to the kubelet CredentialProviderConfig, and if any pattern matches
+ // the requested image, CRI-O credential provider will be invoked to obtain credentials for pulling
+ // that image or its mirrors.
+ // Depending on the platform, the CRI-O credential provider may be installed alongside an existing platform specific provider.
+ // Conflicts between the existing platform specific provider image match configuration and this list will be handled by
+ // the following precedence rule: credentials from built-in kubelet providers (e.g., ECR, GCR, ACR) take precedence over those
+ // from the CRIOCredentialProviderConfig when both match the same image.
+ // To avoid uncertainty, it is recommended to avoid configuring your private image patterns to overlap with
+ // existing platform specific provider config(e.g., the entries from https://github.com/openshift/machine-config-operator/blob/main/templates/common/aws/files/etc-kubernetes-credential-providers-ecr-credential-provider.yaml).
+ // You can check the resource's Status conditions
+ // to see if any entries were ignored due to exact matches with known built-in provider patterns.
+ //
+ // This field is optional, the items of the list must contain between 1 and 50 entries.
+ // The list is treated as a set, so duplicate entries are not allowed.
+ //
+ // For more details, see:
+ // https://kubernetes.io/docs/tasks/administer-cluster/kubelet-credential-provider/
+ // https://github.com/cri-o/crio-credential-provider#architecture
+ //
+ // Each entry in matchImages is a pattern which can optionally contain a port and a path. Each entry must be no longer than 512 characters.
+ // Wildcards ('*') are supported for full subdomain labels, such as '*.k8s.io' or 'k8s.*.io',
+ // and for top-level domains, such as 'k8s.*' (which matches 'k8s.io' or 'k8s.net').
+ // A global wildcard '*' (matching any domain) is not allowed.
+ // Wildcards may replace an entire hostname label (e.g., *.example.com), but they cannot appear within a label (e.g., f*oo.example.com) and are not allowed in the port or path.
+ // For example, 'example.*.com' is valid, but 'exa*mple.*.com' is not.
+ // Each wildcard matches only a single domain label,
+ // so '*.io' does **not** match '*.k8s.io'.
+ //
+ // A match exists between an image and a matchImage when all of the below are true:
+ // Both contain the same number of domain parts and each part matches.
+ // The URL path of an matchImages must be a prefix of the target image URL path.
+ // If the matchImages contains a port, then the port must match in the image as well.
+ //
+ // Example values of matchImages:
+ // - 123456789.dkr.ecr.us-east-1.amazonaws.com
+ // - *.azurecr.io
+ // - gcr.io
+ // - *.*.registry.io
+ // - registry.io:8080/path
+ MatchImages []configv1.MatchImage `json:"matchImages,omitempty"`
+}
+
+// CRIOCredentialProviderConfigSpecApplyConfiguration constructs a declarative configuration of the CRIOCredentialProviderConfigSpec type for use with
+// apply.
+func CRIOCredentialProviderConfigSpec() *CRIOCredentialProviderConfigSpecApplyConfiguration {
+ return &CRIOCredentialProviderConfigSpecApplyConfiguration{}
+}
+
+// WithMatchImages adds the given value to the MatchImages field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the MatchImages field.
+func (b *CRIOCredentialProviderConfigSpecApplyConfiguration) WithMatchImages(values ...configv1.MatchImage) *CRIOCredentialProviderConfigSpecApplyConfiguration {
+ for i := range values {
+ b.MatchImages = append(b.MatchImages, values[i])
+ }
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/criocredentialproviderconfigstatus.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/criocredentialproviderconfigstatus.go
new file mode 100644
index 0000000000..903292fe8d
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/criocredentialproviderconfigstatus.go
@@ -0,0 +1,41 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+import (
+ metav1 "k8s.io/client-go/applyconfigurations/meta/v1"
+)
+
+// CRIOCredentialProviderConfigStatusApplyConfiguration represents a declarative configuration of the CRIOCredentialProviderConfigStatus type for use
+// with apply.
+//
+// CRIOCredentialProviderConfigStatus defines the observed state of CRIOCredentialProviderConfig
+type CRIOCredentialProviderConfigStatusApplyConfiguration struct {
+ // conditions represent the latest available observations of the configuration state.
+ // When omitted, it indicates that no conditions have been reported yet.
+ // The maximum number of conditions is 16.
+ // Conditions are stored as a map keyed by condition type, ensuring uniqueness.
+ //
+ // Expected condition types include:
+ // "Validated": indicates whether the matchImages configuration is valid
+ Conditions []metav1.ConditionApplyConfiguration `json:"conditions,omitempty"`
+}
+
+// CRIOCredentialProviderConfigStatusApplyConfiguration constructs a declarative configuration of the CRIOCredentialProviderConfigStatus type for use with
+// apply.
+func CRIOCredentialProviderConfigStatus() *CRIOCredentialProviderConfigStatusApplyConfiguration {
+ return &CRIOCredentialProviderConfigStatusApplyConfiguration{}
+}
+
+// WithConditions adds the given value to the Conditions field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the Conditions field.
+func (b *CRIOCredentialProviderConfigStatusApplyConfiguration) WithConditions(values ...*metav1.ConditionApplyConfiguration) *CRIOCredentialProviderConfigStatusApplyConfiguration {
+ for i := range values {
+ if values[i] == nil {
+ panic("nil value passed to WithConditions")
+ }
+ b.Conditions = append(b.Conditions, *values[i])
+ }
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/customtlsprofile.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/customtlsprofile.go
index 7df6a4be9e..7b682ef205 100644
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/customtlsprofile.go
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/customtlsprofile.go
@@ -31,6 +31,16 @@ func (b *CustomTLSProfileApplyConfiguration) WithCiphers(values ...string) *Cust
return b
}
+// WithGroups adds the given value to the Groups field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the Groups field.
+func (b *CustomTLSProfileApplyConfiguration) WithGroups(values ...configv1.TLSGroup) *CustomTLSProfileApplyConfiguration {
+ for i := range values {
+ b.TLSProfileSpecApplyConfiguration.Groups = append(b.TLSProfileSpecApplyConfiguration.Groups, values[i])
+ }
+ return b
+}
+
// WithMinTLSVersion sets the MinTLSVersion field in the declarative configuration to the given value
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
// If called multiple times, the MinTLSVersion field is set to the value of the last call.
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/externalclaimssource.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/externalclaimssource.go
new file mode 100644
index 0000000000..143544e7cd
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/externalclaimssource.go
@@ -0,0 +1,97 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+// ExternalClaimsSourceApplyConfiguration represents a declarative configuration of the ExternalClaimsSource type for use
+// with apply.
+//
+// ExternalClaimsSource provides the configuration for a single external claim source.
+type ExternalClaimsSourceApplyConfiguration struct {
+ // authentication is an optional field that configures how the apiserver authenticates with an external claims source.
+ // When not specified, anonymous authentication is used which means no 'Authorization' header
+ // is sent in the HTTP request to fetch the external claims.
+ Authentication *ExternalSourceAuthenticationApplyConfiguration `json:"authentication,omitempty"`
+ // tls is an optional field that configures the http client TLS
+ // settings when fetching external claims from this source.
+ //
+ // When omitted, system default TLS settings will be used
+ // for fetching claims from the external source.
+ TLS *ExternalSourceTLSApplyConfiguration `json:"tls,omitempty"`
+ // url is a required configuration of the URL
+ // for which the external claims are located.
+ URL *SourceURLApplyConfiguration `json:"url,omitempty"`
+ // mappings is a required list of the claim
+ // and response handling expression pairs
+ // that produces the claims from the external source.
+ // mappings must have at least 1 entry and must not exceed 16 entries.
+ // Entries must have a unique name across all external claim sources.
+ Mappings []SourcedClaimMappingApplyConfiguration `json:"mappings,omitempty"`
+ // predicates is an optional list of constraints in
+ // which claims should attempt to be fetched from this
+ // external source.
+ //
+ // When omitted, claims are always fetched
+ // from this external source.
+ //
+ // When specified, all predicates must evaluate to 'true'
+ // before claims are attempted to be fetched from this external source.
+ // predicates must have at least 1 entry and must not exceed 16 entries.
+ // Entries must have unique expressions.
+ Predicates []ExternalSourcePredicateApplyConfiguration `json:"predicates,omitempty"`
+}
+
+// ExternalClaimsSourceApplyConfiguration constructs a declarative configuration of the ExternalClaimsSource type for use with
+// apply.
+func ExternalClaimsSource() *ExternalClaimsSourceApplyConfiguration {
+ return &ExternalClaimsSourceApplyConfiguration{}
+}
+
+// WithAuthentication sets the Authentication field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Authentication field is set to the value of the last call.
+func (b *ExternalClaimsSourceApplyConfiguration) WithAuthentication(value *ExternalSourceAuthenticationApplyConfiguration) *ExternalClaimsSourceApplyConfiguration {
+ b.Authentication = value
+ return b
+}
+
+// WithTLS sets the TLS field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the TLS field is set to the value of the last call.
+func (b *ExternalClaimsSourceApplyConfiguration) WithTLS(value *ExternalSourceTLSApplyConfiguration) *ExternalClaimsSourceApplyConfiguration {
+ b.TLS = value
+ return b
+}
+
+// WithURL sets the URL field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the URL field is set to the value of the last call.
+func (b *ExternalClaimsSourceApplyConfiguration) WithURL(value *SourceURLApplyConfiguration) *ExternalClaimsSourceApplyConfiguration {
+ b.URL = value
+ return b
+}
+
+// WithMappings adds the given value to the Mappings field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the Mappings field.
+func (b *ExternalClaimsSourceApplyConfiguration) WithMappings(values ...*SourcedClaimMappingApplyConfiguration) *ExternalClaimsSourceApplyConfiguration {
+ for i := range values {
+ if values[i] == nil {
+ panic("nil value passed to WithMappings")
+ }
+ b.Mappings = append(b.Mappings, *values[i])
+ }
+ return b
+}
+
+// WithPredicates adds the given value to the Predicates field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the Predicates field.
+func (b *ExternalClaimsSourceApplyConfiguration) WithPredicates(values ...*ExternalSourcePredicateApplyConfiguration) *ExternalClaimsSourceApplyConfiguration {
+ for i := range values {
+ if values[i] == nil {
+ panic("nil value passed to WithPredicates")
+ }
+ b.Predicates = append(b.Predicates, *values[i])
+ }
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/externalsourceauthentication.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/externalsourceauthentication.go
new file mode 100644
index 0000000000..a2deb822e3
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/externalsourceauthentication.go
@@ -0,0 +1,57 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+import (
+ configv1 "github.com/openshift/api/config/v1"
+)
+
+// ExternalSourceAuthenticationApplyConfiguration represents a declarative configuration of the ExternalSourceAuthentication type for use
+// with apply.
+//
+// ExternalSourceAuthentication configures how the apiserver should attempt
+// to authenticate with an external claims source.
+type ExternalSourceAuthenticationApplyConfiguration struct {
+ // type is a required field that sets the type of
+ // authentication method used by the authenticator
+ // when fetching external claims.
+ //
+ // Allowed values are 'RequestProvidedToken' and 'ClientCredential'.
+ //
+ // When set to 'RequestProvidedToken', the authenticator will
+ // use the token provided to the kube-apiserver as part of the
+ // request to authenticate with the external claims source.
+ //
+ // When set to 'ClientCredential', the authenticator will
+ // use the configured client-id, client-secret, and token endpoint
+ // to fetch an access token using the OAuth2 client credentials grant
+ // flow. The fetched access token will then be used to authenticate
+ // with the external claims source.
+ Type *configv1.ExternalSourceAuthenticationType `json:"type,omitempty"`
+ // clientCredential configures the client credentials
+ // and token endpoint to use to get an access token.
+ // clientCredential is required when type is 'ClientCredential', and forbidden otherwise.
+ ClientCredential *ClientCredentialConfigApplyConfiguration `json:"clientCredential,omitempty"`
+}
+
+// ExternalSourceAuthenticationApplyConfiguration constructs a declarative configuration of the ExternalSourceAuthentication type for use with
+// apply.
+func ExternalSourceAuthentication() *ExternalSourceAuthenticationApplyConfiguration {
+ return &ExternalSourceAuthenticationApplyConfiguration{}
+}
+
+// WithType sets the Type field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Type field is set to the value of the last call.
+func (b *ExternalSourceAuthenticationApplyConfiguration) WithType(value configv1.ExternalSourceAuthenticationType) *ExternalSourceAuthenticationApplyConfiguration {
+ b.Type = &value
+ return b
+}
+
+// WithClientCredential sets the ClientCredential field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the ClientCredential field is set to the value of the last call.
+func (b *ExternalSourceAuthenticationApplyConfiguration) WithClientCredential(value *ClientCredentialConfigApplyConfiguration) *ExternalSourceAuthenticationApplyConfiguration {
+ b.ClientCredential = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/externalsourcecertificateauthorityconfigmapreference.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/externalsourcecertificateauthorityconfigmapreference.go
new file mode 100644
index 0000000000..f1fb64e745
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/externalsourcecertificateauthorityconfigmapreference.go
@@ -0,0 +1,34 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+// ExternalSourceCertificateAuthorityConfigMapReferenceApplyConfiguration represents a declarative configuration of the ExternalSourceCertificateAuthorityConfigMapReference type for use
+// with apply.
+//
+// ExternalSourceCertificateAuthorityConfigMapReference is a reference to a ConfigMap in the openshift-config
+// namespace that should be used for configuring the certificate authority to be
+// used when sourcing claims from external sources.
+type ExternalSourceCertificateAuthorityConfigMapReferenceApplyConfiguration struct {
+ // name is the required name of the ConfigMap that exists in the openshift-config namespace.
+ // The key "ca-bundle.crt" must be present and must contain the CA certificate to be used
+ // to verify the external source's TLS certificate.
+ //
+ // It must be at least 1 character in length, must not exceed 253 characters in length,
+ // must start and end with a lowercase alphanumeric character, and must only contain
+ // lowercase alphanumeric characters, '-' or '.'.
+ Name *string `json:"name,omitempty"`
+}
+
+// ExternalSourceCertificateAuthorityConfigMapReferenceApplyConfiguration constructs a declarative configuration of the ExternalSourceCertificateAuthorityConfigMapReference type for use with
+// apply.
+func ExternalSourceCertificateAuthorityConfigMapReference() *ExternalSourceCertificateAuthorityConfigMapReferenceApplyConfiguration {
+ return &ExternalSourceCertificateAuthorityConfigMapReferenceApplyConfiguration{}
+}
+
+// WithName sets the Name field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Name field is set to the value of the last call.
+func (b *ExternalSourceCertificateAuthorityConfigMapReferenceApplyConfiguration) WithName(value string) *ExternalSourceCertificateAuthorityConfigMapReferenceApplyConfiguration {
+ b.Name = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/externalsourcepredicate.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/externalsourcepredicate.go
new file mode 100644
index 0000000000..ade172deeb
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/externalsourcepredicate.go
@@ -0,0 +1,43 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+// ExternalSourcePredicateApplyConfiguration represents a declarative configuration of the ExternalSourcePredicate type for use
+// with apply.
+//
+// ExternalSourcePredicate configures a singular condition
+// that must return true before the external source is queried
+// to retrieve external claims.
+type ExternalSourcePredicateApplyConfiguration struct {
+ // expression is a required CEL expression that
+ // is used to determine whether or not an external
+ // source should be used to fetch external claims.
+ //
+ // The expression must return a boolean value,
+ // where true means that the source should be consulted
+ // and false means that it should not.
+ //
+ // Claims from the token used for the request to the kube-apiserver
+ // are made available via the `claims` variable.
+ //
+ // The contents of the `claims` variable varies based on the claims that are
+ // present in the token being validated. It is the responsibility of those configuring this
+ // field to understand what claims the identity provider includes when issuing tokens.
+ //
+ // expression must be at least 1 character and must not exceed 1024 characters in length.
+ Expression *string `json:"expression,omitempty"`
+}
+
+// ExternalSourcePredicateApplyConfiguration constructs a declarative configuration of the ExternalSourcePredicate type for use with
+// apply.
+func ExternalSourcePredicate() *ExternalSourcePredicateApplyConfiguration {
+ return &ExternalSourcePredicateApplyConfiguration{}
+}
+
+// WithExpression sets the Expression field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Expression field is set to the value of the last call.
+func (b *ExternalSourcePredicateApplyConfiguration) WithExpression(value string) *ExternalSourcePredicateApplyConfiguration {
+ b.Expression = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/externalsourcetls.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/externalsourcetls.go
new file mode 100644
index 0000000000..a0b84ad6d5
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/externalsourcetls.go
@@ -0,0 +1,30 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+// ExternalSourceTLSApplyConfiguration represents a declarative configuration of the ExternalSourceTLS type for use
+// with apply.
+//
+// ExternalSourceTLS configures the TLS options that the apiserver uses as a client
+// when making a request to the external claim source.
+type ExternalSourceTLSApplyConfiguration struct {
+ // certificateAuthority is a required reference to a ConfigMap in the openshift-config
+ // namespace that contains the CA certificate to use to validate TLS connections with the external claims source.
+ // The key "ca-bundle.crt" must be present in the referenced ConfigMap and must contain the CA certificate to be used
+ // to verify the external source's TLS certificate.
+ CertificateAuthority *ExternalSourceCertificateAuthorityConfigMapReferenceApplyConfiguration `json:"certificateAuthority,omitempty"`
+}
+
+// ExternalSourceTLSApplyConfiguration constructs a declarative configuration of the ExternalSourceTLS type for use with
+// apply.
+func ExternalSourceTLS() *ExternalSourceTLSApplyConfiguration {
+ return &ExternalSourceTLSApplyConfiguration{}
+}
+
+// WithCertificateAuthority sets the CertificateAuthority field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the CertificateAuthority field is set to the value of the last call.
+func (b *ExternalSourceTLSApplyConfiguration) WithCertificateAuthority(value *ExternalSourceCertificateAuthorityConfigMapReferenceApplyConfiguration) *ExternalSourceTLSApplyConfiguration {
+ b.CertificateAuthority = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/gcpplatformstatus.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/gcpplatformstatus.go
index bf4c761d1a..158041b9ab 100644
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/gcpplatformstatus.go
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/gcpplatformstatus.go
@@ -27,6 +27,18 @@ type GCPPlatformStatusApplyConfiguration struct {
// must be provided for the API and internal API load balancers as well as the
// ingress load balancer.
CloudLoadBalancerConfig *CloudLoadBalancerConfigApplyConfiguration `json:"cloudLoadBalancerConfig,omitempty"`
+ // universeDomain is the GCP universe domain for the cluster, detected from
+ // the installer credentials. Components with their own GCP credentials should
+ // read the universe domain from those credentials, as they are the authoritative
+ // source. This field is provided for components that do not have GCP credentials
+ // and for general observability.
+ //
+ // When omitted, standard public GCP (googleapis.com) is assumed.
+ //
+ // universeDomain is an optional field that, when specified, must be non-empty and at most
+ // 253 characters. It must be a valid DNS subdomain: containing only lowercase alphanumeric
+ // characters, '-' or '.', and starting and ending with an alphanumeric character.
+ UniverseDomain *string `json:"universeDomain,omitempty"`
}
// GCPPlatformStatusApplyConfiguration constructs a declarative configuration of the GCPPlatformStatus type for use with
@@ -84,3 +96,11 @@ func (b *GCPPlatformStatusApplyConfiguration) WithCloudLoadBalancerConfig(value
b.CloudLoadBalancerConfig = value
return b
}
+
+// WithUniverseDomain sets the UniverseDomain field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the UniverseDomain field is set to the value of the last call.
+func (b *GCPPlatformStatusApplyConfiguration) WithUniverseDomain(value string) *GCPPlatformStatusApplyConfiguration {
+ b.UniverseDomain = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/infrastructurespec.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/infrastructurespec.go
index e48e1368b3..135e8568dd 100644
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/infrastructurespec.go
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/infrastructurespec.go
@@ -2,6 +2,10 @@
package v1
+import (
+ configv1 "github.com/openshift/api/config/v1"
+)
+
// InfrastructureSpecApplyConfiguration represents a declarative configuration of the InfrastructureSpec type for use
// with apply.
//
@@ -23,6 +27,16 @@ type InfrastructureSpecApplyConfiguration struct {
// platformSpec holds desired information specific to the underlying
// infrastructure provider.
PlatformSpec *PlatformSpecApplyConfiguration `json:"platformSpec,omitempty"`
+ // controlPlaneTopology expresses the desired topology configuration for control nodes.
+ //
+ // When status.controlPlaneTopology is 'SingleReplica' and spec.controlPlaneTopology is set to 'HighlyAvailable',
+ // a transition will be triggered to reconfigure the cluster from SingleReplica to HighlyAvailable.
+ //
+ // When left blank or status.controlPlaneTopology and spec.controlPlaneTopology are the same value,
+ // no changes are required and no transitions will be triggered.
+ //
+ // This value may be set to match status.controlPlaneTopology regardless of the current value.
+ ControlPlaneTopology *configv1.TopologyMode `json:"controlPlaneTopology,omitempty"`
}
// InfrastructureSpecApplyConfiguration constructs a declarative configuration of the InfrastructureSpec type for use with
@@ -46,3 +60,11 @@ func (b *InfrastructureSpecApplyConfiguration) WithPlatformSpec(value *PlatformS
b.PlatformSpec = value
return b
}
+
+// WithControlPlaneTopology sets the ControlPlaneTopology field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the ControlPlaneTopology field is set to the value of the last call.
+func (b *InfrastructureSpecApplyConfiguration) WithControlPlaneTopology(value configv1.TopologyMode) *InfrastructureSpecApplyConfiguration {
+ b.ControlPlaneTopology = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/infrastructurestatus.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/infrastructurestatus.go
index f5c63c6ae9..c01827c113 100644
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/infrastructurestatus.go
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/infrastructurestatus.go
@@ -42,6 +42,8 @@ type InfrastructureStatusApplyConfiguration struct {
// and the operators should not configure the operand for highly-available operation
// The 'External' mode indicates that the control plane is hosted externally to the cluster and that
// its components are not visible within the cluster.
+ // The 'HighlyAvailableArbiter' mode indicates that the control plane will consist of 2 control-plane nodes
+ // that run conventional services and 1 smaller sized arbiter node that runs a bare minimum of services to maintain quorum.
ControlPlaneTopology *configv1.TopologyMode `json:"controlPlaneTopology,omitempty"`
// infrastructureTopology expresses the expectations for infrastructure services that do not run on control
// plane nodes, usually indicated by a node selector for a `role` value
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/ingressspec.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/ingressspec.go
index ed804bd000..50d8252389 100644
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/ingressspec.go
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/ingressspec.go
@@ -30,6 +30,7 @@ type IngressSpecApplyConfiguration struct {
// To determine the set of configurable Routes, look at namespace and name of entries in the
// .status.componentRoutes list, where participating operators write the status of
// configurable routes.
+ // A maximum of 250 component routes may be configured.
ComponentRoutes []ComponentRouteSpecApplyConfiguration `json:"componentRoutes,omitempty"`
// requiredHSTSPolicies specifies HSTS policies that are required to be set on newly created or updated routes
// matching the domainPattern/s and namespaceSelector/s that are specified in the policy.
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/kmsconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/kmsconfig.go
deleted file mode 100644
index 3590aae241..0000000000
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/kmsconfig.go
+++ /dev/null
@@ -1,44 +0,0 @@
-// Code generated by applyconfiguration-gen. DO NOT EDIT.
-
-package v1
-
-import (
- configv1 "github.com/openshift/api/config/v1"
-)
-
-// KMSConfigApplyConfiguration represents a declarative configuration of the KMSConfig type for use
-// with apply.
-//
-// KMSConfig defines the configuration for the KMS instance
-// that will be used with KMSEncryptionProvider encryption
-type KMSConfigApplyConfiguration struct {
- // type defines the kind of platform for the KMS provider.
- // Available provider types are AWS only.
- Type *configv1.KMSProviderType `json:"type,omitempty"`
- // aws defines the key config for using an AWS KMS instance
- // for the encryption. The AWS KMS instance is managed
- // by the user outside the purview of the control plane.
- AWS *AWSKMSConfigApplyConfiguration `json:"aws,omitempty"`
-}
-
-// KMSConfigApplyConfiguration constructs a declarative configuration of the KMSConfig type for use with
-// apply.
-func KMSConfig() *KMSConfigApplyConfiguration {
- return &KMSConfigApplyConfiguration{}
-}
-
-// WithType sets the Type field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the Type field is set to the value of the last call.
-func (b *KMSConfigApplyConfiguration) WithType(value configv1.KMSProviderType) *KMSConfigApplyConfiguration {
- b.Type = &value
- return b
-}
-
-// WithAWS sets the AWS field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the AWS field is set to the value of the last call.
-func (b *KMSConfigApplyConfiguration) WithAWS(value *AWSKMSConfigApplyConfiguration) *KMSConfigApplyConfiguration {
- b.AWS = value
- return b
-}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/kmspluginconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/kmspluginconfig.go
new file mode 100644
index 0000000000..fc266edc48
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/kmspluginconfig.go
@@ -0,0 +1,46 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+import (
+ configv1 "github.com/openshift/api/config/v1"
+)
+
+// KMSPluginConfigApplyConfiguration represents a declarative configuration of the KMSPluginConfig type for use
+// with apply.
+//
+// KMSPluginConfig defines the configuration for the KMS instance
+// that will be used with KMS encryption
+type KMSPluginConfigApplyConfiguration struct {
+ // type defines the kind of platform for the KMS provider.
+ // Allowed values are Vault.
+ // When set to Vault, the plugin connects to a HashiCorp Vault server for key management.
+ Type *configv1.KMSProviderType `json:"type,omitempty"`
+ // vault defines the configuration for the Vault KMS plugin.
+ // The plugin connects to a Vault Enterprise server that is managed
+ // by the user outside the purview of the control plane.
+ // This field must be set when type is Vault, and must be unset otherwise.
+ Vault *VaultKMSPluginConfigApplyConfiguration `json:"vault,omitempty"`
+}
+
+// KMSPluginConfigApplyConfiguration constructs a declarative configuration of the KMSPluginConfig type for use with
+// apply.
+func KMSPluginConfig() *KMSPluginConfigApplyConfiguration {
+ return &KMSPluginConfigApplyConfiguration{}
+}
+
+// WithType sets the Type field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Type field is set to the value of the last call.
+func (b *KMSPluginConfigApplyConfiguration) WithType(value configv1.KMSProviderType) *KMSPluginConfigApplyConfiguration {
+ b.Type = &value
+ return b
+}
+
+// WithVault sets the Vault field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Vault field is set to the value of the last call.
+func (b *KMSPluginConfigApplyConfiguration) WithVault(value *VaultKMSPluginConfigApplyConfiguration) *KMSPluginConfigApplyConfiguration {
+ b.Vault = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/networkobservabilityspec.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/networkobservabilityspec.go
new file mode 100644
index 0000000000..5e58d8e9c1
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/networkobservabilityspec.go
@@ -0,0 +1,36 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+import (
+ configv1 "github.com/openshift/api/config/v1"
+)
+
+// NetworkObservabilitySpecApplyConfiguration represents a declarative configuration of the NetworkObservabilitySpec type for use
+// with apply.
+//
+// NetworkObservabilitySpec defines the configuration for network observability installation
+type NetworkObservabilitySpecApplyConfiguration struct {
+ // installationPolicy controls whether network observability is installed during cluster deployment.
+ // Valid values are "InstallAndEnable" and "NoAction".
+ // When set to "InstallAndEnable", ensure that network observability will be installed and enabled on the cluster. If already installed, no action taken, but if it gets uninstalled, it will install it again.
+ // When set to "NoAction", nothing will be done regarding Network observability.
+ // During the installation of NetworkObservability, the platform checks for any existing manual installations.
+ // If a successful installation using the OLMv0 or OLMv1 API is detected, it will be used.
+ // If the platform cannot determine how the current version was installed, or if the existing installation is incomplete, the installation process will stop.
+ InstallationPolicy *configv1.NetworkObservabilityInstallationPolicy `json:"installationPolicy,omitempty"`
+}
+
+// NetworkObservabilitySpecApplyConfiguration constructs a declarative configuration of the NetworkObservabilitySpec type for use with
+// apply.
+func NetworkObservabilitySpec() *NetworkObservabilitySpecApplyConfiguration {
+ return &NetworkObservabilitySpecApplyConfiguration{}
+}
+
+// WithInstallationPolicy sets the InstallationPolicy field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the InstallationPolicy field is set to the value of the last call.
+func (b *NetworkObservabilitySpecApplyConfiguration) WithInstallationPolicy(value configv1.NetworkObservabilityInstallationPolicy) *NetworkObservabilitySpecApplyConfiguration {
+ b.InstallationPolicy = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/networkspec.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/networkspec.go
index 4a3f9b7b89..27e7480ecf 100644
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/networkspec.go
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/networkspec.go
@@ -42,6 +42,10 @@ type NetworkSpecApplyConfiguration struct {
// and the spec.disableNetworkDiagnostics flag in network.operator.openshift.io is set to true,
// the network diagnostics feature will be disabled.
NetworkDiagnostics *NetworkDiagnosticsApplyConfiguration `json:"networkDiagnostics,omitempty"`
+ // networkObservability is an optional field that configures network observability installation
+ // during cluster deployment (day-0).
+ // When omitted, unless this is a SNO cluster, network observability will be installed if not already present, after that, no action taken.
+ NetworkObservability *NetworkObservabilitySpecApplyConfiguration `json:"networkObservability,omitempty"`
}
// NetworkSpecApplyConfiguration constructs a declarative configuration of the NetworkSpec type for use with
@@ -104,3 +108,11 @@ func (b *NetworkSpecApplyConfiguration) WithNetworkDiagnostics(value *NetworkDia
b.NetworkDiagnostics = value
return b
}
+
+// WithNetworkObservability sets the NetworkObservability field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the NetworkObservability field is set to the value of the last call.
+func (b *NetworkSpecApplyConfiguration) WithNetworkObservability(value *NetworkObservabilitySpecApplyConfiguration) *NetworkSpecApplyConfiguration {
+ b.NetworkObservability = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/oidcprovider.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/oidcprovider.go
index 6f5a249a70..4fb1c97ebc 100644
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/oidcprovider.go
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/oidcprovider.go
@@ -26,6 +26,27 @@ type OIDCProviderApplyConfiguration struct {
// If any rule in the chain of rules evaluates to 'false', authentication will fail.
// When specified, at least one rule must be specified and no more than 64 rules may be specified.
UserValidationRules []TokenUserValidationRuleApplyConfiguration `json:"userValidationRules,omitempty"`
+ // externalClaimsSources is an optional field that can be used to configure
+ // sources, external to the token provided in a request, in which claims
+ // should be fetched from and made available to the claim mapping process
+ // that is used to build the identity of a token holder.
+ //
+ // For example, fetching additional user metadata from an OIDC provider's UserInfo endpoint.
+ //
+ // When not specified, only claims present in the token itself will be available
+ // in the claim mapping process.
+ //
+ // When specified, at least one external claim source must be specified and no more than 5
+ // sources may be specified.
+ // All external claim sources must have unique claim mappings.
+ // When an external source responds and resolves additional claims successfully, they will
+ // be made available as claims during the claim mapping process.
+ // Externally sourced claims with the same name as a claim existing within the token will
+ // overwrite the claim data from the token with the externally sourced information.
+ // If an external source does not respond, responds with an error, or the additional
+ // claim data cannot be resolved from the response successfully it will not be
+ // included in the claim data passed to the claim mapping process.
+ ExternalClaimsSources []ExternalClaimsSourceApplyConfiguration `json:"externalClaimsSources,omitempty"`
}
// OIDCProviderApplyConfiguration constructs a declarative configuration of the OIDCProvider type for use with
@@ -96,3 +117,16 @@ func (b *OIDCProviderApplyConfiguration) WithUserValidationRules(values ...*Toke
}
return b
}
+
+// WithExternalClaimsSources adds the given value to the ExternalClaimsSources field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the ExternalClaimsSources field.
+func (b *OIDCProviderApplyConfiguration) WithExternalClaimsSources(values ...*ExternalClaimsSourceApplyConfiguration) *OIDCProviderApplyConfiguration {
+ for i := range values {
+ if values[i] == nil {
+ panic("nil value passed to WithExternalClaimsSources")
+ }
+ b.ExternalClaimsSources = append(b.ExternalClaimsSources, *values[i])
+ }
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/prefixedclaimmapping.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/prefixedclaimmapping.go
index d9b0e87914..08ebf26a86 100644
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/prefixedclaimmapping.go
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/prefixedclaimmapping.go
@@ -11,7 +11,8 @@ type PrefixedClaimMappingApplyConfiguration struct {
TokenClaimMappingApplyConfiguration `json:",inline"`
// prefix is an optional field that configures the prefix that will be applied to the cluster identity attribute during the process of mapping JWT claims to cluster identity attributes.
//
- // When omitted (""), no prefix is applied to the cluster identity attribute.
+ // When omitted or set to an empty string (""), no prefix is applied to the cluster identity attribute.
+ // Must not be set to a non-empty value when expression is set.
//
// Example: if `prefix` is set to "myoidc:" and the `claim` in JWT contains an array of strings "a", "b" and "c", the mapping will result in an array of string "myoidc:a", "myoidc:b" and "myoidc:c".
Prefix *string `json:"prefix,omitempty"`
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/registrysources.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/registrysources.go
index 61fc436e6f..9fd5335dad 100644
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/registrysources.go
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/registrysources.go
@@ -8,12 +8,30 @@ package v1
// RegistrySources holds cluster-wide information about how to handle the registries config.
type RegistrySourcesApplyConfiguration struct {
// insecureRegistries are registries which do not have a valid TLS certificates or only support HTTP connections.
+ // Each entry must be a valid registry scope in the format hostname[:port][/path],
+ // optionally prefixed with "*." for wildcard subdomains (e.g., "*.example.com").
+ // The hostname must consist of valid DNS labels separated by dots, where each label
+ // contains only alphanumeric characters and hyphens and does not start or end with a hyphen.
+ // Entries must not be empty, must not include tags (e.g., ":latest") or digests (e.g., "@sha256:..."),
+ // and must be at most 256 characters in length. The list may contain at most 1024 entries.
InsecureRegistries []string `json:"insecureRegistries,omitempty"`
// blockedRegistries cannot be used for image pull and push actions. All other registries are permitted.
+ // Each entry must be a valid registry scope in the format hostname[:port][/path],
+ // optionally prefixed with "*." for wildcard subdomains (e.g., "*.example.com").
+ // The hostname must consist of valid DNS labels separated by dots, where each label
+ // contains only alphanumeric characters and hyphens and does not start or end with a hyphen.
+ // Entries must not be empty, must not include tags (e.g., ":latest") or digests (e.g., "@sha256:..."),
+ // and must be at most 256 characters in length. The list may contain at most 1024 entries.
//
// Only one of BlockedRegistries or AllowedRegistries may be set.
BlockedRegistries []string `json:"blockedRegistries,omitempty"`
// allowedRegistries are the only registries permitted for image pull and push actions. All other registries are denied.
+ // Each entry must be a valid registry scope in the format hostname[:port][/path],
+ // optionally prefixed with "*." for wildcard subdomains (e.g., "*.example.com").
+ // The hostname must consist of valid DNS labels separated by dots, where each label
+ // contains only alphanumeric characters and hyphens and does not start or end with a hyphen.
+ // Entries must not be empty, must not include tags (e.g., ":latest") or digests (e.g., "@sha256:..."),
+ // and must be at most 256 characters in length. The list may contain at most 1024 entries.
//
// Only one of BlockedRegistries or AllowedRegistries may be set.
AllowedRegistries []string `json:"allowedRegistries,omitempty"`
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/sourcedclaimmapping.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/sourcedclaimmapping.go
new file mode 100644
index 0000000000..92c4dc24f7
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/sourcedclaimmapping.go
@@ -0,0 +1,51 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+// SourcedClaimMappingApplyConfiguration represents a declarative configuration of the SourcedClaimMapping type for use
+// with apply.
+//
+// SourcedClaimMapping configures the mapping behavior for a single external claim
+// from the response the apiserver received from the external claim source.
+type SourcedClaimMappingApplyConfiguration struct {
+ // name is a required name of the claim that
+ // will be produced and made available during
+ // the claim-to-identity mapping process.
+ // name must consist of only lowercase alpha characters and underscores ('_').
+ // name must be at least 1 character and must not exceed 256 characters in length.
+ Name *string `json:"name,omitempty"`
+ // expression is a required CEL expression that
+ // will produce a value to be assigned to the claim.
+ // The full response body from the request to the
+ // external claim source is provided via the
+ // `response.body` variable.
+ //
+ // The contents of the `response.body` variable varies based on the response received
+ // from the external source. It is the responsibility of those configuring
+ // this expression to understand what is returned from the external source.
+ //
+ // expression must be at least 1 character and must not exceed 1024 characters in length.
+ Expression *string `json:"expression,omitempty"`
+}
+
+// SourcedClaimMappingApplyConfiguration constructs a declarative configuration of the SourcedClaimMapping type for use with
+// apply.
+func SourcedClaimMapping() *SourcedClaimMappingApplyConfiguration {
+ return &SourcedClaimMappingApplyConfiguration{}
+}
+
+// WithName sets the Name field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Name field is set to the value of the last call.
+func (b *SourcedClaimMappingApplyConfiguration) WithName(value string) *SourcedClaimMappingApplyConfiguration {
+ b.Name = &value
+ return b
+}
+
+// WithExpression sets the Expression field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Expression field is set to the value of the last call.
+func (b *SourcedClaimMappingApplyConfiguration) WithExpression(value string) *SourcedClaimMappingApplyConfiguration {
+ b.Expression = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/sourceurl.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/sourceurl.go
new file mode 100644
index 0000000000..b94a89f39c
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/sourceurl.go
@@ -0,0 +1,67 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+// SourceURLApplyConfiguration represents a declarative configuration of the SourceURL type for use
+// with apply.
+//
+// SourceURL configures the options used to build the URL that is queried for external claims.
+type SourceURLApplyConfiguration struct {
+ // hostname is a required hostname for which the external claims are located.
+ //
+ // It must be a valid DNS subdomain name as per RFC1123.
+ //
+ // This means that it must start and end with a lowercase alphanumeric character,
+ // must only consist of lowercase alphanumeric characters, '-', and '.'.
+ // hostname may optionally specify a port in the format ':{port}'.
+ // If a port is specified it must not exceed 65535.
+ //
+ // hostname must be at least 1 character in length.
+ // When specifying a port, hostname must not exceed 259 characters in length.
+ // When not specifying a port, hostname must not exceed 253 characters in length.
+ Hostname *string `json:"hostname,omitempty"`
+ // pathExpression is a required CEL expression that returns a list
+ // of string values used to construct the URL path.
+ // Claims from the token used for the request to the kube-apiserver
+ // are made available via the `claims` variable.
+ // expression must be at least 1 character in length and must not exceed 1024 characters in length.
+ //
+ // Values in the returned list will be joined with the hostname using a forward slash
+ // (`/`) as a separator. Values in the returned list do not need to include the forward slash.
+ // If a forward slash is included in a returned value, it will be encoded as `%2F`.
+ //
+ // Example of a static path configuration:
+ //
+ // pathExpression: ['realms', 'k8s', 'protocol', 'openid-connect', 'userinfo']
+ //
+ // The above example would resolve to the path: '/realms/k8s/protocol/openid-connect/userinfo'
+ //
+ // Example of a dynamic path configuration:
+ //
+ // pathExpression: "['admin', 'realms', 'k8s', 'users'] + [claims.sub] + ['groups']"
+ //
+ // Assuming 'claims.sub' is set to '12345', the above example would resolve to the path: '/admin/realms/k8s/users/12345/groups'
+ PathExpression *string `json:"pathExpression,omitempty"`
+}
+
+// SourceURLApplyConfiguration constructs a declarative configuration of the SourceURL type for use with
+// apply.
+func SourceURL() *SourceURLApplyConfiguration {
+ return &SourceURLApplyConfiguration{}
+}
+
+// WithHostname sets the Hostname field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Hostname field is set to the value of the last call.
+func (b *SourceURLApplyConfiguration) WithHostname(value string) *SourceURLApplyConfiguration {
+ b.Hostname = &value
+ return b
+}
+
+// WithPathExpression sets the PathExpression field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the PathExpression field is set to the value of the last call.
+func (b *SourceURLApplyConfiguration) WithPathExpression(value string) *SourceURLApplyConfiguration {
+ b.PathExpression = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/tlsprofilespec.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/tlsprofilespec.go
index 5e34ffd5db..cbefaf5169 100644
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/tlsprofilespec.go
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/tlsprofilespec.go
@@ -21,6 +21,24 @@ type TLSProfileSpecApplyConfiguration struct {
// TLS 1.3 cipher suites (e.g. TLS_AES_128_GCM_SHA256) are not configurable
// and are always enabled when TLS 1.3 is negotiated.
Ciphers []string `json:"ciphers,omitempty"`
+ // groups is an optional, ordered field used to specify the supported groups (formerly known as
+ // elliptic curves) that are used during the TLS handshake. The order of the groups represents
+ // a suggested preference, with the most preferred group first. Note that not all platform
+ // components honor the ordering: Go-based components use Go's internal preference order and
+ // treat this list as a filter of allowed groups rather than an ordered preference.
+ // Operators may remove entries their operands do not support.
+ //
+ // When omitted, this means no opinion and the platform is left to choose reasonable defaults which are
+ // subject to change over time and may be different per platform component depending on the underlying TLS
+ // libraries they use. If specified, the list must contain at least one and at most 7 groups,
+ // and each group must be unique.
+ //
+ // For example, to use X25519 and secp256r1 (yaml):
+ //
+ // groups:
+ // - X25519
+ // - secp256r1
+ Groups []configv1.TLSGroup `json:"groups,omitempty"`
// minTLSVersion is used to specify the minimal version of the TLS protocol
// that is negotiated during the TLS handshake. For example, to use TLS
// versions 1.1, 1.2 and 1.3 (yaml):
@@ -45,6 +63,16 @@ func (b *TLSProfileSpecApplyConfiguration) WithCiphers(values ...string) *TLSPro
return b
}
+// WithGroups adds the given value to the Groups field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the Groups field.
+func (b *TLSProfileSpecApplyConfiguration) WithGroups(values ...configv1.TLSGroup) *TLSProfileSpecApplyConfiguration {
+ for i := range values {
+ b.Groups = append(b.Groups, values[i])
+ }
+ return b
+}
+
// WithMinTLSVersion sets the MinTLSVersion field in the declarative configuration to the given value
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
// If called multiple times, the MinTLSVersion field is set to the value of the last call.
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/tlssecurityprofile.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/tlssecurityprofile.go
index dd57aad086..eab7cd4525 100644
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/tlssecurityprofile.go
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/tlssecurityprofile.go
@@ -15,10 +15,16 @@ type TLSSecurityProfileApplyConfiguration struct {
// type is one of Old, Intermediate, Modern or Custom. Custom provides the
// ability to specify individual TLS security profile parameters.
//
- // The profiles are based on version 5.7 of the Mozilla Server Side TLS
- // configuration guidelines. The cipher lists consist of the configuration's
- // "ciphersuites" followed by the Go-specific "ciphers" from the guidelines.
- // See: https://ssl-config.mozilla.org/guidelines/5.7.json
+ // The cipher and groups lists in these profiles are based on version 5.8 of the
+ // Mozilla Server Side TLS configuration guidelines.
+ // See: https://ssl-config.mozilla.org/guidelines/5.8.json
+ //
+ // The groups are listed in suggested preference order, with the most preferred group first.
+ // Note that not all platform components honor the ordering: Go-based components use Go's
+ // internal preference order and treat this list as a filter of allowed groups rather than
+ // an ordered preference.
+ // Note that X25519MLKEM768 is a post-quantum hybrid group that is not
+ // FIPS-approved and should be ignored by components running in FIPS mode.
//
// The profiles are intent based, so they may change over time as new ciphers are
// developed and existing ciphers are found to be insecure. Depending on
@@ -27,6 +33,10 @@ type TLSSecurityProfileApplyConfiguration struct {
// old is a TLS profile for use when services need to be accessed by very old
// clients or libraries and should be used only as a last resort.
//
+ // The supported groups list includes by default the following groups
+ // in suggested preference order (ordering may not be honored by all implementations):
+ // X25519MLKEM768, X25519, secp256r1, secp384r1.
+ //
// This profile is equivalent to a Custom profile specified as:
// minTLSVersion: VersionTLS10
// ciphers:
@@ -43,11 +53,14 @@ type TLSSecurityProfileApplyConfiguration struct {
// - ECDHE-RSA-AES128-SHA256
// - ECDHE-ECDSA-AES128-SHA
// - ECDHE-RSA-AES128-SHA
+ // - ECDHE-ECDSA-AES256-SHA384
+ // - ECDHE-RSA-AES256-SHA384
// - ECDHE-ECDSA-AES256-SHA
// - ECDHE-RSA-AES256-SHA
// - AES128-GCM-SHA256
// - AES256-GCM-SHA384
// - AES128-SHA256
+ // - AES256-SHA256
// - AES128-SHA
// - AES256-SHA
// - DES-CBC3-SHA
@@ -56,6 +69,10 @@ type TLSSecurityProfileApplyConfiguration struct {
// legacy clients and want to remain highly secure while being compatible with
// most clients currently in use.
//
+ // The supported groups list includes by default the following groups
+ // in suggested preference order (ordering may not be honored by all implementations):
+ // X25519MLKEM768, X25519, secp256r1, secp384r1.
+ //
// This profile is equivalent to a Custom profile specified as:
// minTLSVersion: VersionTLS12
// ciphers:
@@ -71,7 +88,9 @@ type TLSSecurityProfileApplyConfiguration struct {
Intermediate *configv1.IntermediateTLSProfile `json:"intermediate,omitempty"`
// modern is a TLS security profile for use with clients that support TLS 1.3 and
// do not need backward compatibility for older clients.
- //
+ // The supported groups list includes by default the following groups
+ // in suggested preference order (ordering may not be honored by all implementations):
+ // X25519MLKEM768, X25519, secp256r1, secp384r1.
// This profile is equivalent to a Custom profile specified as:
// minTLSVersion: VersionTLS13
// ciphers:
@@ -80,8 +99,11 @@ type TLSSecurityProfileApplyConfiguration struct {
// - TLS_CHACHA20_POLY1305_SHA256
Modern *configv1.ModernTLSProfile `json:"modern,omitempty"`
// custom is a user-defined TLS security profile. Be extremely careful using a custom
- // profile as invalid configurations can be catastrophic. An example custom profile
- // looks like this:
+ // profile as invalid configurations can be catastrophic.
+ //
+ // The supported groups list for this profile is empty by default.
+ //
+ // An example custom profile looks like this:
//
// minTLSVersion: VersionTLS11
// ciphers:
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/update.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/update.go
index 6151b6b13a..db1128deb5 100644
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/update.go
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/update.go
@@ -47,6 +47,19 @@ type UpdateApplyConfiguration struct {
// acceptRisks must not contain more than 1000 entries.
// Entries in this list must be unique.
AcceptRisks []AcceptRiskApplyConfiguration `json:"acceptRisks,omitempty"`
+ // mode determines how an update should be processed.
+ // The only valid value is "Preflight".
+ // When omitted, the cluster performs a normal update by applying the specified version or image to the cluster.
+ // This is the standard update behavior.
+ // When set to "Preflight", the cluster runs compatibility checks against the target release without
+ // performing an actual update. Compatibility results, including any detected risks, are reported
+ // in status.conditionalUpdates and status.conditionalUpdateRisks alongside risks from the update
+ // recommendation service.
+ // This allows administrators to assess update readiness and address issues before committing to the update.
+ // Preflight mode is particularly useful for skip-level updates where upgrade compatibility needs to be
+ // verified across multiple minor versions.
+ // When mode is set to "Preflight", the same rules for version, image, and architecture apply as for normal updates.
+ Mode *configv1.UpdateMode `json:"mode,omitempty"`
}
// UpdateApplyConfiguration constructs a declarative configuration of the Update type for use with
@@ -99,3 +112,11 @@ func (b *UpdateApplyConfiguration) WithAcceptRisks(values ...*AcceptRiskApplyCon
}
return b
}
+
+// WithMode sets the Mode field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Mode field is set to the value of the last call.
+func (b *UpdateApplyConfiguration) WithMode(value configv1.UpdateMode) *UpdateApplyConfiguration {
+ b.Mode = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/usernameclaimmapping.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/usernameclaimmapping.go
index d33d6d71d8..8676ae891f 100644
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/usernameclaimmapping.go
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/usernameclaimmapping.go
@@ -29,11 +29,9 @@ type UsernameClaimMappingApplyConfiguration struct {
// Allowed values are 'Prefix', 'NoPrefix', and omitted (not provided or an empty string).
//
// When set to 'Prefix', the value specified in the prefix field will be prepended to the value of the JWT claim.
- //
// The prefix field must be set when prefixPolicy is 'Prefix'.
- //
+ // Must not be set to 'Prefix' when expression is set.
// When set to 'NoPrefix', no prefix will be prepended to the value of the JWT claim.
- //
// When omitted, this means no opinion and the platform is left to choose any prefixes that are applied which is subject to change over time.
// Currently, the platform prepends `{issuerURL}#` to the value of the JWT claim when the claim is not 'email'.
//
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/vaultapproleauthentication.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/vaultapproleauthentication.go
new file mode 100644
index 0000000000..9119cbe199
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/vaultapproleauthentication.go
@@ -0,0 +1,28 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+// VaultAppRoleAuthenticationApplyConfiguration represents a declarative configuration of the VaultAppRoleAuthentication type for use
+// with apply.
+//
+// VaultAppRoleAuthentication defines the configuration for AppRole authentication with Vault.
+type VaultAppRoleAuthenticationApplyConfiguration struct {
+ // secret references a secret in the openshift-config namespace containing
+ // the AppRole credentials used to authenticate with Vault.
+ // The referenced Secret must contain two keys: "role-id" for the AppRole Role ID and "secret-id" for the AppRole Secret ID.
+ Secret *VaultSecretReferenceApplyConfiguration `json:"secret,omitempty"`
+}
+
+// VaultAppRoleAuthenticationApplyConfiguration constructs a declarative configuration of the VaultAppRoleAuthentication type for use with
+// apply.
+func VaultAppRoleAuthentication() *VaultAppRoleAuthenticationApplyConfiguration {
+ return &VaultAppRoleAuthenticationApplyConfiguration{}
+}
+
+// WithSecret sets the Secret field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Secret field is set to the value of the last call.
+func (b *VaultAppRoleAuthenticationApplyConfiguration) WithSecret(value *VaultSecretReferenceApplyConfiguration) *VaultAppRoleAuthenticationApplyConfiguration {
+ b.Secret = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/vaultauthentication.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/vaultauthentication.go
new file mode 100644
index 0000000000..466bbc7970
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/vaultauthentication.go
@@ -0,0 +1,43 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+import (
+ configv1 "github.com/openshift/api/config/v1"
+)
+
+// VaultAuthenticationApplyConfiguration represents a declarative configuration of the VaultAuthentication type for use
+// with apply.
+//
+// VaultAuthentication defines the authentication method used to authenticate with Vault.
+type VaultAuthenticationApplyConfiguration struct {
+ // type defines the authentication method used to authenticate with Vault.
+ // Allowed values are AppRole.
+ // When set to AppRole, the plugin uses AppRole credentials to authenticate with Vault.
+ Type *configv1.VaultAuthenticationType `json:"type,omitempty"`
+ // appRole defines the configuration for AppRole authentication.
+ // This field must be set when type is AppRole, and must be unset otherwise.
+ AppRole *VaultAppRoleAuthenticationApplyConfiguration `json:"appRole,omitempty"`
+}
+
+// VaultAuthenticationApplyConfiguration constructs a declarative configuration of the VaultAuthentication type for use with
+// apply.
+func VaultAuthentication() *VaultAuthenticationApplyConfiguration {
+ return &VaultAuthenticationApplyConfiguration{}
+}
+
+// WithType sets the Type field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Type field is set to the value of the last call.
+func (b *VaultAuthenticationApplyConfiguration) WithType(value configv1.VaultAuthenticationType) *VaultAuthenticationApplyConfiguration {
+ b.Type = &value
+ return b
+}
+
+// WithAppRole sets the AppRole field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the AppRole field is set to the value of the last call.
+func (b *VaultAuthenticationApplyConfiguration) WithAppRole(value *VaultAppRoleAuthenticationApplyConfiguration) *VaultAuthenticationApplyConfiguration {
+ b.AppRole = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/vaultconfigmapreference.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/vaultconfigmapreference.go
new file mode 100644
index 0000000000..cb0e46af85
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/vaultconfigmapreference.go
@@ -0,0 +1,28 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+// VaultConfigMapReferenceApplyConfiguration represents a declarative configuration of the VaultConfigMapReference type for use
+// with apply.
+//
+// VaultConfigMapReference references a ConfigMap in the openshift-config namespace.
+type VaultConfigMapReferenceApplyConfiguration struct {
+ // name is the metadata.name of the referenced ConfigMap in the openshift-config namespace.
+ // The name must be a valid DNS subdomain name: it must contain no more than 253 characters,
+ // contain only lowercase alphanumeric characters, '-' or '.', and start and end with an alphanumeric character.
+ Name *string `json:"name,omitempty"`
+}
+
+// VaultConfigMapReferenceApplyConfiguration constructs a declarative configuration of the VaultConfigMapReference type for use with
+// apply.
+func VaultConfigMapReference() *VaultConfigMapReferenceApplyConfiguration {
+ return &VaultConfigMapReferenceApplyConfiguration{}
+}
+
+// WithName sets the Name field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Name field is set to the value of the last call.
+func (b *VaultConfigMapReferenceApplyConfiguration) WithName(value string) *VaultConfigMapReferenceApplyConfiguration {
+ b.Name = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/vaultkmspluginconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/vaultkmspluginconfig.go
new file mode 100644
index 0000000000..235cecb939
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/vaultkmspluginconfig.go
@@ -0,0 +1,130 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+// VaultKMSPluginConfigApplyConfiguration represents a declarative configuration of the VaultKMSPluginConfig type for use
+// with apply.
+//
+// VaultKMSPluginConfig defines the KMS plugin configuration specific to Vault KMS
+type VaultKMSPluginConfigApplyConfiguration struct {
+ // kmsPluginImage specifies the container image for the HashiCorp Vault KMS plugin.
+ //
+ // The image must be a fully qualified OCI image pull spec with a SHA256 digest.
+ // The format is: host[:port][/namespace]/name@sha256:
+ // where the digest must be 64 characters long and consist only of lowercase hexadecimal characters, a-f and 0-9.
+ // The total length must be between 75 and 447 characters.
+ //
+ // Short names (e.g., "vault-plugin" or "hashicorp/vault-plugin") are not allowed.
+ // The registry hostname must be included and must contain at least one dot.
+ // Image tags (e.g., ":latest", ":v1.0.0") are not allowed.
+ //
+ // Consult the OpenShift documentation for compatible plugin versions with your cluster version,
+ // then obtain the image digest for that version from HashiCorp's container registry.
+ //
+ // For disconnected environments, mirror the plugin image to an accessible registry
+ // and reference the mirrored location with its digest.
+ KMSPluginImage *string `json:"kmsPluginImage,omitempty"`
+ // vaultAddress specifies the address of the HashiCorp Vault instance.
+ // The value must be a valid HTTPS URL containing only scheme, host, and optional port.
+ // Paths, user info, query parameters, and fragments are not allowed.
+ //
+ // Format: https://hostname[:port]
+ // Example: https://vault.example.com:8200
+ //
+ // The value must be between 1 and 512 characters.
+ VaultAddress *string `json:"vaultAddress,omitempty"`
+ // vaultNamespace specifies the Vault namespace where the Transit secrets engine is mounted.
+ // This is only applicable for Vault Enterprise installations.
+ // When this field is not set, no namespace is used.
+ //
+ // The value must be between 1 and 4096 characters.
+ // The namespace cannot end with a forward slash, cannot contain spaces, and cannot be one of the reserved strings: root, sys, audit, auth, cubbyhole, or identity.
+ VaultNamespace *string `json:"vaultNamespace,omitempty"`
+ // vaultAuthNamespace specifies the Vault namespace to use for authentication.
+ // This is only applicable for Vault Enterprise installations where authentication
+ // and Transit operations may be in different namespaces.
+ // When this field is not set, the value of vaultNamespace is used for both
+ // authentication and Transit key operations.
+ //
+ // The value must be between 1 and 4096 characters.
+ // The namespace cannot end with a forward slash, cannot contain spaces, and cannot be one of the reserved strings: root, sys, audit, auth, cubbyhole, or identity.
+ VaultAuthNamespace *string `json:"vaultAuthNamespace,omitempty"`
+ // tls contains the TLS configuration for connecting to the Vault server.
+ // When this field is not set, system default TLS settings are used.
+ TLS *VaultTLSConfigApplyConfiguration `json:"tls,omitempty"`
+ // authentication defines the authentication method used to authenticate with Vault.
+ Authentication *VaultAuthenticationApplyConfiguration `json:"authentication,omitempty"`
+ // vaultKeyPath specifies the full path to the encryption key in Vault's Transit secrets engine,
+ // combining the Transit engine mount path and the key name separated by "/keys/".
+ // Format: /keys/ (e.g., transit/keys/my-key, myteam/transit/keys/production-key).
+ //
+ // The total path length must be between 8 and 1542 characters.
+ // The path cannot start or end with a forward slash, cannot contain consecutive forward slashes,
+ // must only contain RFC 3986 unreserved characters (alphanumeric, hyphen, period, underscore, tilde)
+ // and forward slashes as path separators, and must not contain "." or ".." path segments.
+ // The key name must start and end with an alphanumeric character or underscore, and may contain
+ // alphanumeric characters, underscores, hyphens, and periods in the middle.
+ VaultKeyPath *string `json:"vaultKeyPath,omitempty"`
+}
+
+// VaultKMSPluginConfigApplyConfiguration constructs a declarative configuration of the VaultKMSPluginConfig type for use with
+// apply.
+func VaultKMSPluginConfig() *VaultKMSPluginConfigApplyConfiguration {
+ return &VaultKMSPluginConfigApplyConfiguration{}
+}
+
+// WithKMSPluginImage sets the KMSPluginImage field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the KMSPluginImage field is set to the value of the last call.
+func (b *VaultKMSPluginConfigApplyConfiguration) WithKMSPluginImage(value string) *VaultKMSPluginConfigApplyConfiguration {
+ b.KMSPluginImage = &value
+ return b
+}
+
+// WithVaultAddress sets the VaultAddress field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the VaultAddress field is set to the value of the last call.
+func (b *VaultKMSPluginConfigApplyConfiguration) WithVaultAddress(value string) *VaultKMSPluginConfigApplyConfiguration {
+ b.VaultAddress = &value
+ return b
+}
+
+// WithVaultNamespace sets the VaultNamespace field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the VaultNamespace field is set to the value of the last call.
+func (b *VaultKMSPluginConfigApplyConfiguration) WithVaultNamespace(value string) *VaultKMSPluginConfigApplyConfiguration {
+ b.VaultNamespace = &value
+ return b
+}
+
+// WithVaultAuthNamespace sets the VaultAuthNamespace field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the VaultAuthNamespace field is set to the value of the last call.
+func (b *VaultKMSPluginConfigApplyConfiguration) WithVaultAuthNamespace(value string) *VaultKMSPluginConfigApplyConfiguration {
+ b.VaultAuthNamespace = &value
+ return b
+}
+
+// WithTLS sets the TLS field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the TLS field is set to the value of the last call.
+func (b *VaultKMSPluginConfigApplyConfiguration) WithTLS(value *VaultTLSConfigApplyConfiguration) *VaultKMSPluginConfigApplyConfiguration {
+ b.TLS = value
+ return b
+}
+
+// WithAuthentication sets the Authentication field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Authentication field is set to the value of the last call.
+func (b *VaultKMSPluginConfigApplyConfiguration) WithAuthentication(value *VaultAuthenticationApplyConfiguration) *VaultKMSPluginConfigApplyConfiguration {
+ b.Authentication = value
+ return b
+}
+
+// WithVaultKeyPath sets the VaultKeyPath field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the VaultKeyPath field is set to the value of the last call.
+func (b *VaultKMSPluginConfigApplyConfiguration) WithVaultKeyPath(value string) *VaultKMSPluginConfigApplyConfiguration {
+ b.VaultKeyPath = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/vaultsecretreference.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/vaultsecretreference.go
new file mode 100644
index 0000000000..5918611ed7
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/vaultsecretreference.go
@@ -0,0 +1,28 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+// VaultSecretReferenceApplyConfiguration represents a declarative configuration of the VaultSecretReference type for use
+// with apply.
+//
+// VaultSecretReference references a secret in the openshift-config namespace.
+type VaultSecretReferenceApplyConfiguration struct {
+ // name is the metadata.name of the referenced secret in the openshift-config namespace.
+ // The name must be a valid DNS subdomain name: it must contain no more than 253 characters,
+ // contain only lowercase alphanumeric characters, '-' or '.', and start and end with an alphanumeric character.
+ Name *string `json:"name,omitempty"`
+}
+
+// VaultSecretReferenceApplyConfiguration constructs a declarative configuration of the VaultSecretReference type for use with
+// apply.
+func VaultSecretReference() *VaultSecretReferenceApplyConfiguration {
+ return &VaultSecretReferenceApplyConfiguration{}
+}
+
+// WithName sets the Name field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Name field is set to the value of the last call.
+func (b *VaultSecretReferenceApplyConfiguration) WithName(value string) *VaultSecretReferenceApplyConfiguration {
+ b.Name = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/vaulttlsconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/vaulttlsconfig.go
new file mode 100644
index 0000000000..04bf8c3bf1
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/vaulttlsconfig.go
@@ -0,0 +1,58 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+// VaultTLSConfigApplyConfiguration represents a declarative configuration of the VaultTLSConfig type for use
+// with apply.
+//
+// VaultTLSConfig contains TLS configuration for connecting to Vault.
+type VaultTLSConfigApplyConfiguration struct {
+ // caBundle references a ConfigMap in the openshift-config namespace containing
+ // the CA certificate bundle used to verify the TLS connection to the Vault server.
+ // The referenced ConfigMap must contain the CA bundle in the key "ca-bundle.crt".
+ // When this field is not set, the system's trusted CA certificates are used.
+ //
+ // The namespace for the ConfigMap is openshift-config.
+ //
+ // Example ConfigMap:
+ // apiVersion: v1
+ // kind: ConfigMap
+ // metadata:
+ // name: vault-ca-bundle
+ // namespace: openshift-config
+ // data:
+ // ca-bundle.crt: |
+ // -----BEGIN CERTIFICATE-----
+ // ...
+ // -----END CERTIFICATE-----
+ CABundle *VaultConfigMapReferenceApplyConfiguration `json:"caBundle,omitempty"`
+ // serverName specifies the Server Name Indication (SNI) to use when connecting to Vault via TLS.
+ // This is useful when the Vault server's hostname doesn't match its TLS certificate.
+ // When this field is not set, the hostname from vaultAddress is used for SNI.
+ //
+ // The value must be a valid DNS hostname: it must contain no more than 253 characters,
+ // contain only lowercase alphanumeric characters, '-' or '.', and start and end with an alphanumeric character.
+ ServerName *string `json:"serverName,omitempty"`
+}
+
+// VaultTLSConfigApplyConfiguration constructs a declarative configuration of the VaultTLSConfig type for use with
+// apply.
+func VaultTLSConfig() *VaultTLSConfigApplyConfiguration {
+ return &VaultTLSConfigApplyConfiguration{}
+}
+
+// WithCABundle sets the CABundle field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the CABundle field is set to the value of the last call.
+func (b *VaultTLSConfigApplyConfiguration) WithCABundle(value *VaultConfigMapReferenceApplyConfiguration) *VaultTLSConfigApplyConfiguration {
+ b.CABundle = value
+ return b
+}
+
+// WithServerName sets the ServerName field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the ServerName field is set to the value of the last call.
+func (b *VaultTLSConfigApplyConfiguration) WithServerName(value string) *VaultTLSConfigApplyConfiguration {
+ b.ServerName = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/vsphereplatformfailuredomainspec.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/vsphereplatformfailuredomainspec.go
index 4f3d37e0f1..feb5a68fbc 100644
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/vsphereplatformfailuredomainspec.go
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/vsphereplatformfailuredomainspec.go
@@ -28,6 +28,9 @@ type VSpherePlatformFailureDomainSpecApplyConfiguration struct {
// contains the vmHostRule which is an affinity vm-host rule in vCenter.
ZoneAffinity *VSphereFailureDomainZoneAffinityApplyConfiguration `json:"zoneAffinity,omitempty"`
// server is the fully-qualified domain name or the IP address of the vCenter server.
+ // This must match the server field of an entry in the vcenters list.
+ // The match is case-sensitive; the value must be specified exactly as it appears in the vcenters entry.
+ // The value must be between 1 and 255 characters long.
// ---
Server *string `json:"server,omitempty"`
// topology describes a given failure domain using vSphere constructs
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/vsphereplatformspec.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/vsphereplatformspec.go
index f8037b67a1..971183e94d 100644
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/vsphereplatformspec.go
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/vsphereplatformspec.go
@@ -14,16 +14,18 @@ import (
// use these fields for configuration.
type VSpherePlatformSpecApplyConfiguration struct {
// vcenters holds the connection details for services to communicate with vCenter.
- // Currently, only a single vCenter is supported, but in tech preview 3 vCenters are supported.
+ // Up to 3 vCenters are supported.
// Once the cluster has been installed, you are unable to change the current number of defined
- // vCenters except in the case where the cluster has been upgraded from a version of OpenShift
- // where the vsphere platform spec was not present. You may make modifications to the existing
+ // vCenters except when 1.) the cluster has been upgraded from a version of OpenShift
+ // where the vsphere platform spec was not present or 2.) in TechPreview you are able to add and
+ // remove vCenters but may not remove all vCenters. You may make modifications to the existing
// vCenters that are defined in the vcenters list in order to match with any added or modified
// failure domains.
// ---
VCenters []VSpherePlatformVCenterSpecApplyConfiguration `json:"vcenters,omitempty"`
// failureDomains contains the definition of region, zone and the vCenter topology.
// If this is omitted failure domains (regions and zones) will not be used.
+ // Each failure domain's server must match the server field of an entry in the vcenters list.
FailureDomains []VSpherePlatformFailureDomainSpecApplyConfiguration `json:"failureDomains,omitempty"`
// nodeNetworking contains the definition of internal and external network constraints for
// assigning the node's networking.
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/additionalalertmanagerconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/additionalalertmanagerconfig.go
new file mode 100644
index 0000000000..6a699cd82a
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/additionalalertmanagerconfig.go
@@ -0,0 +1,119 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ configv1alpha1 "github.com/openshift/api/config/v1alpha1"
+)
+
+// AdditionalAlertmanagerConfigApplyConfiguration represents a declarative configuration of the AdditionalAlertmanagerConfig type for use
+// with apply.
+//
+// AdditionalAlertmanagerConfig represents configuration for additional Alertmanager instances.
+// The `AdditionalAlertmanagerConfig` resource defines settings for how a
+// component communicates with additional Alertmanager instances.
+type AdditionalAlertmanagerConfigApplyConfiguration struct {
+ // name is a unique identifier for this Alertmanager configuration entry.
+ // The name must be a valid DNS subdomain (RFC 1123): lowercase alphanumeric characters,
+ // hyphens, or periods, and must start and end with an alphanumeric character.
+ // Minimum length is 1 character (empty string is invalid).
+ // Maximum length is 253 characters.
+ Name *string `json:"name,omitempty"`
+ // authorization configures the authentication method for Alertmanager connections.
+ // Supports bearer token authentication. When omitted, no authentication is used.
+ Authorization *AuthorizationConfigApplyConfiguration `json:"authorization,omitempty"`
+ // pathPrefix defines an optional URL path prefix to prepend to the Alertmanager API endpoints.
+ // For example, if your Alertmanager is behind a reverse proxy at "/alertmanager/",
+ // set this to "/alertmanager" so requests go to "/alertmanager/api/v1/alerts" instead of "/api/v1/alerts".
+ // This is commonly needed when Alertmanager is deployed behind ingress controllers or load balancers.
+ // When no prefix is needed, omit this field; do not set it to "/" as that would produce paths with double slashes (e.g. "//api/v1/alerts").
+ // Must start with "/", must not end with "/", and must not be exactly "/".
+ // Must not contain query strings ("?") or fragments ("#").
+ PathPrefix *string `json:"pathPrefix,omitempty"`
+ // scheme defines the URL scheme to use when communicating with Alertmanager
+ // instances.
+ // Possible values are `HTTP` or `HTTPS`.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The current default value is `HTTP`.
+ Scheme *configv1alpha1.AlertmanagerScheme `json:"scheme,omitempty"`
+ // staticConfigs is a list of statically configured Alertmanager endpoints in the form
+ // of `:`. Each entry must be a valid hostname, IPv4 address, or IPv6 address
+ // (in brackets) followed by a colon and a valid port number (1-65535).
+ // Examples: "alertmanager.example.com:9093", "192.168.1.100:9093", "[::1]:9093"
+ // At least one endpoint must be specified (minimum 1, maximum 10 endpoints).
+ // Each entry must be unique and non-empty (empty string is invalid).
+ StaticConfigs []string `json:"staticConfigs,omitempty"`
+ // timeoutSeconds defines the timeout in seconds for requests to Alertmanager.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // Currently the default is 10 seconds.
+ // Minimum value is 1 second.
+ // Maximum value is 600 seconds (10 minutes).
+ TimeoutSeconds *int32 `json:"timeoutSeconds,omitempty"`
+ // tlsConfig defines the TLS settings to use for Alertmanager connections.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ TLSConfig *TLSConfigApplyConfiguration `json:"tlsConfig,omitempty"`
+}
+
+// AdditionalAlertmanagerConfigApplyConfiguration constructs a declarative configuration of the AdditionalAlertmanagerConfig type for use with
+// apply.
+func AdditionalAlertmanagerConfig() *AdditionalAlertmanagerConfigApplyConfiguration {
+ return &AdditionalAlertmanagerConfigApplyConfiguration{}
+}
+
+// WithName sets the Name field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Name field is set to the value of the last call.
+func (b *AdditionalAlertmanagerConfigApplyConfiguration) WithName(value string) *AdditionalAlertmanagerConfigApplyConfiguration {
+ b.Name = &value
+ return b
+}
+
+// WithAuthorization sets the Authorization field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Authorization field is set to the value of the last call.
+func (b *AdditionalAlertmanagerConfigApplyConfiguration) WithAuthorization(value *AuthorizationConfigApplyConfiguration) *AdditionalAlertmanagerConfigApplyConfiguration {
+ b.Authorization = value
+ return b
+}
+
+// WithPathPrefix sets the PathPrefix field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the PathPrefix field is set to the value of the last call.
+func (b *AdditionalAlertmanagerConfigApplyConfiguration) WithPathPrefix(value string) *AdditionalAlertmanagerConfigApplyConfiguration {
+ b.PathPrefix = &value
+ return b
+}
+
+// WithScheme sets the Scheme field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Scheme field is set to the value of the last call.
+func (b *AdditionalAlertmanagerConfigApplyConfiguration) WithScheme(value configv1alpha1.AlertmanagerScheme) *AdditionalAlertmanagerConfigApplyConfiguration {
+ b.Scheme = &value
+ return b
+}
+
+// WithStaticConfigs adds the given value to the StaticConfigs field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the StaticConfigs field.
+func (b *AdditionalAlertmanagerConfigApplyConfiguration) WithStaticConfigs(values ...string) *AdditionalAlertmanagerConfigApplyConfiguration {
+ for i := range values {
+ b.StaticConfigs = append(b.StaticConfigs, values[i])
+ }
+ return b
+}
+
+// WithTimeoutSeconds sets the TimeoutSeconds field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the TimeoutSeconds field is set to the value of the last call.
+func (b *AdditionalAlertmanagerConfigApplyConfiguration) WithTimeoutSeconds(value int32) *AdditionalAlertmanagerConfigApplyConfiguration {
+ b.TimeoutSeconds = &value
+ return b
+}
+
+// WithTLSConfig sets the TLSConfig field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the TLSConfig field is set to the value of the last call.
+func (b *AdditionalAlertmanagerConfigApplyConfiguration) WithTLSConfig(value *TLSConfigApplyConfiguration) *AdditionalAlertmanagerConfigApplyConfiguration {
+ b.TLSConfig = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/alertmanagercustomconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/alertmanagercustomconfig.go
index ebc4e4a6be..37c93f7e15 100644
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/alertmanagercustomconfig.go
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/alertmanagercustomconfig.go
@@ -13,8 +13,23 @@ import (
// AlertmanagerCustomConfig represents the configuration for a custom Alertmanager deployment.
// alertmanagerCustomConfig provides configuration options for the default Alertmanager instance
// that runs in the `openshift-monitoring` namespace. Use this configuration to control
-// whether the default Alertmanager is deployed, how it logs, and how its pods are scheduled.
+// whether user-defined namespaces are selected for AlertmanagerConfig lookups, how it logs,
+// and how its pods are scheduled.
type AlertmanagerCustomConfigApplyConfiguration struct {
+ // userAlertmanagerConfigSelection is an optional field that controls whether user-defined
+ // namespaces can be selected for AlertmanagerConfig lookups on the platform Alertmanager
+ // instance in the `openshift-monitoring` namespace.
+ // Valid values are Selectable and None.
+ // When set to Selectable, the platform Alertmanager discovers AlertmanagerConfig resources
+ // in user-defined namespaces. This is equivalent to `enableUserAlertmanagerConfig: true` in
+ // the cluster-monitoring-config ConfigMap.
+ // When set to None, user-defined namespaces are not selected for AlertmanagerConfig lookups
+ // on the platform Alertmanager. This is equivalent to `enableUserAlertmanagerConfig: false`
+ // in the cluster-monitoring-config ConfigMap.
+ // This setting only applies when the user-workload monitoring Alertmanager is not enabled.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The current default value is `None`.
+ UserAlertmanagerConfigSelection *configv1alpha1.UserAlertmanagerConfigSelection `json:"userAlertmanagerConfigSelection,omitempty"`
// logLevel defines the verbosity of logs emitted by Alertmanager.
// This field allows users to control the amount and severity of logs generated, which can be useful
// for debugging issues or reducing noise in production environments.
@@ -47,7 +62,7 @@ type AlertmanagerCustomConfigApplyConfiguration struct {
// - name: memory
// request: 40Mi
// limit: null
- // Maximum length for this list is 10.
+ // Maximum length for this list is 5.
// Minimum length for this list is 1.
// Each resource name must be unique within this list.
Resources []ContainerResourceApplyConfiguration `json:"resources,omitempty"`
@@ -90,12 +105,10 @@ type AlertmanagerCustomConfigApplyConfiguration struct {
// Minimum length for this list is 1.
// Entries must have unique topologyKey and whenUnsatisfiable pairs.
TopologySpreadConstraints []v1.TopologySpreadConstraint `json:"topologySpreadConstraints,omitempty"`
- // volumeClaimTemplate Defines persistent storage for Alertmanager. Use this setting to
- // configure the persistent volume claim, including storage class, volume
- // size, and name.
+ // volumeClaimTemplate defines persistent storage for Alertmanager. Use this setting to
+ // configure the persistent volume claim, including storage class and volume size.
// If omitted, the Pod uses ephemeral storage and alert data will not persist
// across restarts.
- // This field is optional.
VolumeClaimTemplate *v1.PersistentVolumeClaim `json:"volumeClaimTemplate,omitempty"`
}
@@ -105,6 +118,14 @@ func AlertmanagerCustomConfig() *AlertmanagerCustomConfigApplyConfiguration {
return &AlertmanagerCustomConfigApplyConfiguration{}
}
+// WithUserAlertmanagerConfigSelection sets the UserAlertmanagerConfigSelection field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the UserAlertmanagerConfigSelection field is set to the value of the last call.
+func (b *AlertmanagerCustomConfigApplyConfiguration) WithUserAlertmanagerConfigSelection(value configv1alpha1.UserAlertmanagerConfigSelection) *AlertmanagerCustomConfigApplyConfiguration {
+ b.UserAlertmanagerConfigSelection = &value
+ return b
+}
+
// WithLogLevel sets the LogLevel field in the declarative configuration to the given value
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
// If called multiple times, the LogLevel field is set to the value of the last call.
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/authorizationconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/authorizationconfig.go
new file mode 100644
index 0000000000..87d7c7eefe
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/authorizationconfig.go
@@ -0,0 +1,44 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ configv1alpha1 "github.com/openshift/api/config/v1alpha1"
+)
+
+// AuthorizationConfigApplyConfiguration represents a declarative configuration of the AuthorizationConfig type for use
+// with apply.
+//
+// AuthorizationConfig defines the authentication method for Alertmanager connections.
+type AuthorizationConfigApplyConfiguration struct {
+ // type specifies the authentication type to use.
+ // Valid value is "BearerToken" (bearer token authentication).
+ // When set to BearerToken, the bearerToken field must be specified.
+ Type *configv1alpha1.AuthorizationType `json:"type,omitempty"`
+ // bearerToken defines the secret reference containing the bearer token.
+ // Required when type is "BearerToken", and forbidden otherwise.
+ // The secret must exist in the openshift-monitoring namespace.
+ BearerToken *SecretKeySelectorApplyConfiguration `json:"bearerToken,omitempty"`
+}
+
+// AuthorizationConfigApplyConfiguration constructs a declarative configuration of the AuthorizationConfig type for use with
+// apply.
+func AuthorizationConfig() *AuthorizationConfigApplyConfiguration {
+ return &AuthorizationConfigApplyConfiguration{}
+}
+
+// WithType sets the Type field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Type field is set to the value of the last call.
+func (b *AuthorizationConfigApplyConfiguration) WithType(value configv1alpha1.AuthorizationType) *AuthorizationConfigApplyConfiguration {
+ b.Type = &value
+ return b
+}
+
+// WithBearerToken sets the BearerToken field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the BearerToken field is set to the value of the last call.
+func (b *AuthorizationConfigApplyConfiguration) WithBearerToken(value *SecretKeySelectorApplyConfiguration) *AuthorizationConfigApplyConfiguration {
+ b.BearerToken = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/basicauth.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/basicauth.go
new file mode 100644
index 0000000000..efad66668a
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/basicauth.go
@@ -0,0 +1,38 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+// BasicAuthApplyConfiguration represents a declarative configuration of the BasicAuth type for use
+// with apply.
+//
+// BasicAuth defines basic authentication settings for the remote write endpoint URL.
+type BasicAuthApplyConfiguration struct {
+ // username defines the secret reference containing the username for basic authentication.
+ // The secret must exist in the openshift-monitoring namespace.
+ Username *SecretKeySelectorApplyConfiguration `json:"username,omitempty"`
+ // password defines the secret reference containing the password for basic authentication.
+ // The secret must exist in the openshift-monitoring namespace.
+ Password *SecretKeySelectorApplyConfiguration `json:"password,omitempty"`
+}
+
+// BasicAuthApplyConfiguration constructs a declarative configuration of the BasicAuth type for use with
+// apply.
+func BasicAuth() *BasicAuthApplyConfiguration {
+ return &BasicAuthApplyConfiguration{}
+}
+
+// WithUsername sets the Username field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Username field is set to the value of the last call.
+func (b *BasicAuthApplyConfiguration) WithUsername(value *SecretKeySelectorApplyConfiguration) *BasicAuthApplyConfiguration {
+ b.Username = value
+ return b
+}
+
+// WithPassword sets the Password field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Password field is set to the value of the last call.
+func (b *BasicAuthApplyConfiguration) WithPassword(value *SecretKeySelectorApplyConfiguration) *BasicAuthApplyConfiguration {
+ b.Password = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/clusterimagepolicy.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/clusterimagepolicy.go
deleted file mode 100644
index 19a6917f99..0000000000
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/clusterimagepolicy.go
+++ /dev/null
@@ -1,277 +0,0 @@
-// Code generated by applyconfiguration-gen. DO NOT EDIT.
-
-package v1alpha1
-
-import (
- configv1alpha1 "github.com/openshift/api/config/v1alpha1"
- internal "github.com/openshift/client-go/config/applyconfigurations/internal"
- metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
- types "k8s.io/apimachinery/pkg/types"
- managedfields "k8s.io/apimachinery/pkg/util/managedfields"
- v1 "k8s.io/client-go/applyconfigurations/meta/v1"
-)
-
-// ClusterImagePolicyApplyConfiguration represents a declarative configuration of the ClusterImagePolicy type for use
-// with apply.
-//
-// # ClusterImagePolicy holds cluster-wide configuration for image signature verification
-//
-// Compatibility level 4: No compatibility is provided, the API can change at any point for any reason. These capabilities should not be used by applications needing long term support.
-type ClusterImagePolicyApplyConfiguration struct {
- v1.TypeMetaApplyConfiguration `json:",inline"`
- // metadata is the standard object's metadata.
- // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
- *v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"`
- // spec contains the configuration for the cluster image policy.
- Spec *ClusterImagePolicySpecApplyConfiguration `json:"spec,omitempty"`
- // status contains the observed state of the resource.
- Status *ClusterImagePolicyStatusApplyConfiguration `json:"status,omitempty"`
-}
-
-// ClusterImagePolicy constructs a declarative configuration of the ClusterImagePolicy type for use with
-// apply.
-func ClusterImagePolicy(name string) *ClusterImagePolicyApplyConfiguration {
- b := &ClusterImagePolicyApplyConfiguration{}
- b.WithName(name)
- b.WithKind("ClusterImagePolicy")
- b.WithAPIVersion("config.openshift.io/v1alpha1")
- return b
-}
-
-// ExtractClusterImagePolicyFrom extracts the applied configuration owned by fieldManager from
-// clusterImagePolicy for the specified subresource. Pass an empty string for subresource to extract
-// the main resource. Common subresources include "status", "scale", etc.
-// clusterImagePolicy must be a unmodified ClusterImagePolicy API object that was retrieved from the Kubernetes API.
-// ExtractClusterImagePolicyFrom provides a way to perform a extract/modify-in-place/apply workflow.
-// Note that an extracted apply configuration will contain fewer fields than what the fieldManager previously
-// applied if another fieldManager has updated or force applied any of the previously applied fields.
-func ExtractClusterImagePolicyFrom(clusterImagePolicy *configv1alpha1.ClusterImagePolicy, fieldManager string, subresource string) (*ClusterImagePolicyApplyConfiguration, error) {
- b := &ClusterImagePolicyApplyConfiguration{}
- err := managedfields.ExtractInto(clusterImagePolicy, internal.Parser().Type("com.github.openshift.api.config.v1alpha1.ClusterImagePolicy"), fieldManager, b, subresource)
- if err != nil {
- return nil, err
- }
- b.WithName(clusterImagePolicy.Name)
-
- b.WithKind("ClusterImagePolicy")
- b.WithAPIVersion("config.openshift.io/v1alpha1")
- return b, nil
-}
-
-// ExtractClusterImagePolicy extracts the applied configuration owned by fieldManager from
-// clusterImagePolicy. If no managedFields are found in clusterImagePolicy for fieldManager, a
-// ClusterImagePolicyApplyConfiguration is returned with only the Name, Namespace (if applicable),
-// APIVersion and Kind populated. It is possible that no managed fields were found for because other
-// field managers have taken ownership of all the fields previously owned by fieldManager, or because
-// the fieldManager never owned fields any fields.
-// clusterImagePolicy must be a unmodified ClusterImagePolicy API object that was retrieved from the Kubernetes API.
-// ExtractClusterImagePolicy provides a way to perform a extract/modify-in-place/apply workflow.
-// Note that an extracted apply configuration will contain fewer fields than what the fieldManager previously
-// applied if another fieldManager has updated or force applied any of the previously applied fields.
-func ExtractClusterImagePolicy(clusterImagePolicy *configv1alpha1.ClusterImagePolicy, fieldManager string) (*ClusterImagePolicyApplyConfiguration, error) {
- return ExtractClusterImagePolicyFrom(clusterImagePolicy, fieldManager, "")
-}
-
-// ExtractClusterImagePolicyStatus extracts the applied configuration owned by fieldManager from
-// clusterImagePolicy for the status subresource.
-func ExtractClusterImagePolicyStatus(clusterImagePolicy *configv1alpha1.ClusterImagePolicy, fieldManager string) (*ClusterImagePolicyApplyConfiguration, error) {
- return ExtractClusterImagePolicyFrom(clusterImagePolicy, fieldManager, "status")
-}
-
-func (b ClusterImagePolicyApplyConfiguration) IsApplyConfiguration() {}
-
-// WithKind sets the Kind field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the Kind field is set to the value of the last call.
-func (b *ClusterImagePolicyApplyConfiguration) WithKind(value string) *ClusterImagePolicyApplyConfiguration {
- b.TypeMetaApplyConfiguration.Kind = &value
- return b
-}
-
-// WithAPIVersion sets the APIVersion field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the APIVersion field is set to the value of the last call.
-func (b *ClusterImagePolicyApplyConfiguration) WithAPIVersion(value string) *ClusterImagePolicyApplyConfiguration {
- b.TypeMetaApplyConfiguration.APIVersion = &value
- return b
-}
-
-// WithName sets the Name field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the Name field is set to the value of the last call.
-func (b *ClusterImagePolicyApplyConfiguration) WithName(value string) *ClusterImagePolicyApplyConfiguration {
- b.ensureObjectMetaApplyConfigurationExists()
- b.ObjectMetaApplyConfiguration.Name = &value
- return b
-}
-
-// WithGenerateName sets the GenerateName field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the GenerateName field is set to the value of the last call.
-func (b *ClusterImagePolicyApplyConfiguration) WithGenerateName(value string) *ClusterImagePolicyApplyConfiguration {
- b.ensureObjectMetaApplyConfigurationExists()
- b.ObjectMetaApplyConfiguration.GenerateName = &value
- return b
-}
-
-// WithNamespace sets the Namespace field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the Namespace field is set to the value of the last call.
-func (b *ClusterImagePolicyApplyConfiguration) WithNamespace(value string) *ClusterImagePolicyApplyConfiguration {
- b.ensureObjectMetaApplyConfigurationExists()
- b.ObjectMetaApplyConfiguration.Namespace = &value
- return b
-}
-
-// WithUID sets the UID field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the UID field is set to the value of the last call.
-func (b *ClusterImagePolicyApplyConfiguration) WithUID(value types.UID) *ClusterImagePolicyApplyConfiguration {
- b.ensureObjectMetaApplyConfigurationExists()
- b.ObjectMetaApplyConfiguration.UID = &value
- return b
-}
-
-// WithResourceVersion sets the ResourceVersion field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the ResourceVersion field is set to the value of the last call.
-func (b *ClusterImagePolicyApplyConfiguration) WithResourceVersion(value string) *ClusterImagePolicyApplyConfiguration {
- b.ensureObjectMetaApplyConfigurationExists()
- b.ObjectMetaApplyConfiguration.ResourceVersion = &value
- return b
-}
-
-// WithGeneration sets the Generation field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the Generation field is set to the value of the last call.
-func (b *ClusterImagePolicyApplyConfiguration) WithGeneration(value int64) *ClusterImagePolicyApplyConfiguration {
- b.ensureObjectMetaApplyConfigurationExists()
- b.ObjectMetaApplyConfiguration.Generation = &value
- return b
-}
-
-// WithCreationTimestamp sets the CreationTimestamp field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the CreationTimestamp field is set to the value of the last call.
-func (b *ClusterImagePolicyApplyConfiguration) WithCreationTimestamp(value metav1.Time) *ClusterImagePolicyApplyConfiguration {
- b.ensureObjectMetaApplyConfigurationExists()
- b.ObjectMetaApplyConfiguration.CreationTimestamp = &value
- return b
-}
-
-// WithDeletionTimestamp sets the DeletionTimestamp field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the DeletionTimestamp field is set to the value of the last call.
-func (b *ClusterImagePolicyApplyConfiguration) WithDeletionTimestamp(value metav1.Time) *ClusterImagePolicyApplyConfiguration {
- b.ensureObjectMetaApplyConfigurationExists()
- b.ObjectMetaApplyConfiguration.DeletionTimestamp = &value
- return b
-}
-
-// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the DeletionGracePeriodSeconds field is set to the value of the last call.
-func (b *ClusterImagePolicyApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *ClusterImagePolicyApplyConfiguration {
- b.ensureObjectMetaApplyConfigurationExists()
- b.ObjectMetaApplyConfiguration.DeletionGracePeriodSeconds = &value
- return b
-}
-
-// WithLabels puts the entries into the Labels field in the declarative configuration
-// and returns the receiver, so that objects can be build by chaining "With" function invocations.
-// If called multiple times, the entries provided by each call will be put on the Labels field,
-// overwriting an existing map entries in Labels field with the same key.
-func (b *ClusterImagePolicyApplyConfiguration) WithLabels(entries map[string]string) *ClusterImagePolicyApplyConfiguration {
- b.ensureObjectMetaApplyConfigurationExists()
- if b.ObjectMetaApplyConfiguration.Labels == nil && len(entries) > 0 {
- b.ObjectMetaApplyConfiguration.Labels = make(map[string]string, len(entries))
- }
- for k, v := range entries {
- b.ObjectMetaApplyConfiguration.Labels[k] = v
- }
- return b
-}
-
-// WithAnnotations puts the entries into the Annotations field in the declarative configuration
-// and returns the receiver, so that objects can be build by chaining "With" function invocations.
-// If called multiple times, the entries provided by each call will be put on the Annotations field,
-// overwriting an existing map entries in Annotations field with the same key.
-func (b *ClusterImagePolicyApplyConfiguration) WithAnnotations(entries map[string]string) *ClusterImagePolicyApplyConfiguration {
- b.ensureObjectMetaApplyConfigurationExists()
- if b.ObjectMetaApplyConfiguration.Annotations == nil && len(entries) > 0 {
- b.ObjectMetaApplyConfiguration.Annotations = make(map[string]string, len(entries))
- }
- for k, v := range entries {
- b.ObjectMetaApplyConfiguration.Annotations[k] = v
- }
- return b
-}
-
-// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration
-// and returns the receiver, so that objects can be build by chaining "With" function invocations.
-// If called multiple times, values provided by each call will be appended to the OwnerReferences field.
-func (b *ClusterImagePolicyApplyConfiguration) WithOwnerReferences(values ...*v1.OwnerReferenceApplyConfiguration) *ClusterImagePolicyApplyConfiguration {
- b.ensureObjectMetaApplyConfigurationExists()
- for i := range values {
- if values[i] == nil {
- panic("nil value passed to WithOwnerReferences")
- }
- b.ObjectMetaApplyConfiguration.OwnerReferences = append(b.ObjectMetaApplyConfiguration.OwnerReferences, *values[i])
- }
- return b
-}
-
-// WithFinalizers adds the given value to the Finalizers field in the declarative configuration
-// and returns the receiver, so that objects can be build by chaining "With" function invocations.
-// If called multiple times, values provided by each call will be appended to the Finalizers field.
-func (b *ClusterImagePolicyApplyConfiguration) WithFinalizers(values ...string) *ClusterImagePolicyApplyConfiguration {
- b.ensureObjectMetaApplyConfigurationExists()
- for i := range values {
- b.ObjectMetaApplyConfiguration.Finalizers = append(b.ObjectMetaApplyConfiguration.Finalizers, values[i])
- }
- return b
-}
-
-func (b *ClusterImagePolicyApplyConfiguration) ensureObjectMetaApplyConfigurationExists() {
- if b.ObjectMetaApplyConfiguration == nil {
- b.ObjectMetaApplyConfiguration = &v1.ObjectMetaApplyConfiguration{}
- }
-}
-
-// WithSpec sets the Spec field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the Spec field is set to the value of the last call.
-func (b *ClusterImagePolicyApplyConfiguration) WithSpec(value *ClusterImagePolicySpecApplyConfiguration) *ClusterImagePolicyApplyConfiguration {
- b.Spec = value
- return b
-}
-
-// WithStatus sets the Status field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the Status field is set to the value of the last call.
-func (b *ClusterImagePolicyApplyConfiguration) WithStatus(value *ClusterImagePolicyStatusApplyConfiguration) *ClusterImagePolicyApplyConfiguration {
- b.Status = value
- return b
-}
-
-// GetKind retrieves the value of the Kind field in the declarative configuration.
-func (b *ClusterImagePolicyApplyConfiguration) GetKind() *string {
- return b.TypeMetaApplyConfiguration.Kind
-}
-
-// GetAPIVersion retrieves the value of the APIVersion field in the declarative configuration.
-func (b *ClusterImagePolicyApplyConfiguration) GetAPIVersion() *string {
- return b.TypeMetaApplyConfiguration.APIVersion
-}
-
-// GetName retrieves the value of the Name field in the declarative configuration.
-func (b *ClusterImagePolicyApplyConfiguration) GetName() *string {
- b.ensureObjectMetaApplyConfigurationExists()
- return b.ObjectMetaApplyConfiguration.Name
-}
-
-// GetNamespace retrieves the value of the Namespace field in the declarative configuration.
-func (b *ClusterImagePolicyApplyConfiguration) GetNamespace() *string {
- b.ensureObjectMetaApplyConfigurationExists()
- return b.ObjectMetaApplyConfiguration.Namespace
-}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/clusterimagepolicyspec.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/clusterimagepolicyspec.go
deleted file mode 100644
index 135aa592aa..0000000000
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/clusterimagepolicyspec.go
+++ /dev/null
@@ -1,53 +0,0 @@
-// Code generated by applyconfiguration-gen. DO NOT EDIT.
-
-package v1alpha1
-
-import (
- configv1alpha1 "github.com/openshift/api/config/v1alpha1"
-)
-
-// ClusterImagePolicySpecApplyConfiguration represents a declarative configuration of the ClusterImagePolicySpec type for use
-// with apply.
-//
-// CLusterImagePolicySpec is the specification of the ClusterImagePolicy custom resource.
-type ClusterImagePolicySpecApplyConfiguration struct {
- // scopes defines the list of image identities assigned to a policy. Each item refers to a scope in a registry implementing the "Docker Registry HTTP API V2".
- // Scopes matching individual images are named Docker references in the fully expanded form, either using a tag or digest. For example, docker.io/library/busybox:latest (not busybox:latest).
- // More general scopes are prefixes of individual-image scopes, and specify a repository (by omitting the tag or digest), a repository
- // namespace, or a registry host (by only specifying the host name and possibly a port number) or a wildcard expression starting with `*.`, for matching all subdomains (not including a port number).
- // Wildcards are only supported for subdomain matching, and may not be used in the middle of the host, i.e. *.example.com is a valid case, but example*.*.com is not.
- // If multiple scopes match a given image, only the policy requirements for the most specific scope apply. The policy requirements for more general scopes are ignored.
- // In addition to setting a policy appropriate for your own deployed applications, make sure that a policy on the OpenShift image repositories
- // quay.io/openshift-release-dev/ocp-release, quay.io/openshift-release-dev/ocp-v4.0-art-dev (or on a more general scope) allows deployment of the OpenShift images required for cluster operation.
- // If a scope is configured in both the ClusterImagePolicy and the ImagePolicy, or if the scope in ImagePolicy is nested under one of the scopes from the ClusterImagePolicy, only the policy from the ClusterImagePolicy will be applied.
- // For additional details about the format, please refer to the document explaining the docker transport field,
- // which can be found at: https://github.com/containers/image/blob/main/docs/containers-policy.json.5.md#docker
- Scopes []configv1alpha1.ImageScope `json:"scopes,omitempty"`
- // policy contains configuration to allow scopes to be verified, and defines how
- // images not matching the verification policy will be treated.
- Policy *ImageSigstoreVerificationPolicyApplyConfiguration `json:"policy,omitempty"`
-}
-
-// ClusterImagePolicySpecApplyConfiguration constructs a declarative configuration of the ClusterImagePolicySpec type for use with
-// apply.
-func ClusterImagePolicySpec() *ClusterImagePolicySpecApplyConfiguration {
- return &ClusterImagePolicySpecApplyConfiguration{}
-}
-
-// WithScopes adds the given value to the Scopes field in the declarative configuration
-// and returns the receiver, so that objects can be build by chaining "With" function invocations.
-// If called multiple times, values provided by each call will be appended to the Scopes field.
-func (b *ClusterImagePolicySpecApplyConfiguration) WithScopes(values ...configv1alpha1.ImageScope) *ClusterImagePolicySpecApplyConfiguration {
- for i := range values {
- b.Scopes = append(b.Scopes, values[i])
- }
- return b
-}
-
-// WithPolicy sets the Policy field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the Policy field is set to the value of the last call.
-func (b *ClusterImagePolicySpecApplyConfiguration) WithPolicy(value *ImageSigstoreVerificationPolicyApplyConfiguration) *ClusterImagePolicySpecApplyConfiguration {
- b.Policy = value
- return b
-}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/clusterimagepolicystatus.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/clusterimagepolicystatus.go
deleted file mode 100644
index e01b2cac34..0000000000
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/clusterimagepolicystatus.go
+++ /dev/null
@@ -1,33 +0,0 @@
-// Code generated by applyconfiguration-gen. DO NOT EDIT.
-
-package v1alpha1
-
-import (
- v1 "k8s.io/client-go/applyconfigurations/meta/v1"
-)
-
-// ClusterImagePolicyStatusApplyConfiguration represents a declarative configuration of the ClusterImagePolicyStatus type for use
-// with apply.
-type ClusterImagePolicyStatusApplyConfiguration struct {
- // conditions provide details on the status of this API Resource.
- Conditions []v1.ConditionApplyConfiguration `json:"conditions,omitempty"`
-}
-
-// ClusterImagePolicyStatusApplyConfiguration constructs a declarative configuration of the ClusterImagePolicyStatus type for use with
-// apply.
-func ClusterImagePolicyStatus() *ClusterImagePolicyStatusApplyConfiguration {
- return &ClusterImagePolicyStatusApplyConfiguration{}
-}
-
-// WithConditions adds the given value to the Conditions field in the declarative configuration
-// and returns the receiver, so that objects can be build by chaining "With" function invocations.
-// If called multiple times, values provided by each call will be appended to the Conditions field.
-func (b *ClusterImagePolicyStatusApplyConfiguration) WithConditions(values ...*v1.ConditionApplyConfiguration) *ClusterImagePolicyStatusApplyConfiguration {
- for i := range values {
- if values[i] == nil {
- panic("nil value passed to WithConditions")
- }
- b.Conditions = append(b.Conditions, *values[i])
- }
- return b
-}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/clustermonitoringspec.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/clustermonitoringspec.go
index 53f29c3fdc..288edad61f 100644
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/clustermonitoringspec.go
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/clustermonitoringspec.go
@@ -18,6 +18,18 @@ type ClusterMonitoringSpecApplyConfiguration struct {
// When omitted, this means no opinion and the platform is left to choose a reasonable default, that is subject to change over time.
// The current default value is `DefaultConfig`.
AlertmanagerConfig *AlertmanagerConfigApplyConfiguration `json:"alertmanagerConfig,omitempty"`
+ // prometheusConfig provides configuration options for the default platform Prometheus instance
+ // that runs in the `openshift-monitoring` namespace. This configuration applies only to the
+ // platform Prometheus instance; user-workload Prometheus instances are configured separately.
+ //
+ // This field allows you to customize how the platform Prometheus is deployed and operated, including:
+ // - Pod scheduling (node selectors, tolerations, topology spread constraints)
+ // - Resource allocation (CPU, memory requests/limits)
+ // - Retention policies (how long metrics are stored)
+ // - External integrations (remote write, additional alertmanagers)
+ //
+ // This field is optional. When omitted, the platform chooses reasonable defaults, which may change over time.
+ PrometheusConfig *PrometheusConfigApplyConfiguration `json:"prometheusConfig,omitempty"`
// metricsServerConfig is an optional field that can be used to configure the Kubernetes Metrics Server that runs in the openshift-monitoring namespace.
// Specifically, it can configure how the Metrics Server instance is deployed, pod scheduling, its audit policy and log verbosity.
// When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
@@ -33,6 +45,44 @@ type ClusterMonitoringSpecApplyConfiguration struct {
// between API versions.
// When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
PrometheusOperatorAdmissionWebhookConfig *PrometheusOperatorAdmissionWebhookConfigApplyConfiguration `json:"prometheusOperatorAdmissionWebhookConfig,omitempty"`
+ // openShiftStateMetricsConfig is an optional field that can be used to configure the openshift-state-metrics
+ // agent that runs in the openshift-monitoring namespace. The openshift-state-metrics agent generates metrics
+ // about the state of OpenShift-specific Kubernetes objects, such as routes, builds, and deployments.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ OpenShiftStateMetricsConfig *OpenShiftStateMetricsConfigApplyConfiguration `json:"openShiftStateMetricsConfig,omitempty"`
+ // telemeterClientConfig is an optional field that can be used to configure the Telemeter Client
+ // component that runs in the openshift-monitoring namespace. The Telemeter Client collects
+ // selected monitoring metrics and forwards them to Red Hat for telemetry purposes.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // When set, at least one field must be specified within telemeterClientConfig.
+ TelemeterClientConfig *TelemeterClientConfigApplyConfiguration `json:"telemeterClientConfig,omitempty"`
+ // thanosQuerierConfig is an optional field that can be used to configure the Thanos Querier
+ // component that runs in the openshift-monitoring namespace. The Thanos Querier provides
+ // a global query view by aggregating and deduplicating metrics from multiple Prometheus instances.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The current default deploys the Thanos Querier on linux nodes with 5m CPU and 12Mi memory
+ // requests, and no custom tolerations or topology spread constraints.
+ // When set, at least one field must be specified within thanosQuerierConfig.
+ ThanosQuerierConfig *ThanosQuerierConfigApplyConfiguration `json:"thanosQuerierConfig,omitempty"`
+ // nodeExporterConfig is an optional field that can be used to configure the node-exporter agent
+ // that runs as a DaemonSet in the openshift-monitoring namespace. The node-exporter agent collects
+ // hardware and OS-level metrics from every node in the cluster.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ NodeExporterConfig *NodeExporterConfigApplyConfiguration `json:"nodeExporterConfig,omitempty"`
+ // monitoringPluginConfig is an optional field that can be used to configure the monitoring plugin
+ // that runs as a dynamic plugin of the OpenShift web console. The monitoring plugin provides
+ // the monitoring UI in the OpenShift web console for visualizing metrics, alerts, and dashboards.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The current default deploys the monitoring-plugin as a single-replica Deployment
+ // on linux nodes with 10m CPU and 50Mi memory requests, and no custom tolerations
+ // or topology spread constraints.
+ // When set, at least one field must be specified within monitoringPluginConfig.
+ MonitoringPluginConfig *MonitoringPluginConfigApplyConfiguration `json:"monitoringPluginConfig,omitempty"`
+ // kubeStateMetricsConfig is an optional field that can be used to configure the kube-state-metrics
+ // agent that runs in the openshift-monitoring namespace. kube-state-metrics generates metrics about
+ // the state of Kubernetes objects such as Deployments, Nodes, and Pods.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ KubeStateMetricsConfig *KubeStateMetricsConfigApplyConfiguration `json:"kubeStateMetricsConfig,omitempty"`
}
// ClusterMonitoringSpecApplyConfiguration constructs a declarative configuration of the ClusterMonitoringSpec type for use with
@@ -57,6 +107,14 @@ func (b *ClusterMonitoringSpecApplyConfiguration) WithAlertmanagerConfig(value *
return b
}
+// WithPrometheusConfig sets the PrometheusConfig field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the PrometheusConfig field is set to the value of the last call.
+func (b *ClusterMonitoringSpecApplyConfiguration) WithPrometheusConfig(value *PrometheusConfigApplyConfiguration) *ClusterMonitoringSpecApplyConfiguration {
+ b.PrometheusConfig = value
+ return b
+}
+
// WithMetricsServerConfig sets the MetricsServerConfig field in the declarative configuration to the given value
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
// If called multiple times, the MetricsServerConfig field is set to the value of the last call.
@@ -80,3 +138,51 @@ func (b *ClusterMonitoringSpecApplyConfiguration) WithPrometheusOperatorAdmissio
b.PrometheusOperatorAdmissionWebhookConfig = value
return b
}
+
+// WithOpenShiftStateMetricsConfig sets the OpenShiftStateMetricsConfig field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the OpenShiftStateMetricsConfig field is set to the value of the last call.
+func (b *ClusterMonitoringSpecApplyConfiguration) WithOpenShiftStateMetricsConfig(value *OpenShiftStateMetricsConfigApplyConfiguration) *ClusterMonitoringSpecApplyConfiguration {
+ b.OpenShiftStateMetricsConfig = value
+ return b
+}
+
+// WithTelemeterClientConfig sets the TelemeterClientConfig field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the TelemeterClientConfig field is set to the value of the last call.
+func (b *ClusterMonitoringSpecApplyConfiguration) WithTelemeterClientConfig(value *TelemeterClientConfigApplyConfiguration) *ClusterMonitoringSpecApplyConfiguration {
+ b.TelemeterClientConfig = value
+ return b
+}
+
+// WithThanosQuerierConfig sets the ThanosQuerierConfig field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the ThanosQuerierConfig field is set to the value of the last call.
+func (b *ClusterMonitoringSpecApplyConfiguration) WithThanosQuerierConfig(value *ThanosQuerierConfigApplyConfiguration) *ClusterMonitoringSpecApplyConfiguration {
+ b.ThanosQuerierConfig = value
+ return b
+}
+
+// WithNodeExporterConfig sets the NodeExporterConfig field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the NodeExporterConfig field is set to the value of the last call.
+func (b *ClusterMonitoringSpecApplyConfiguration) WithNodeExporterConfig(value *NodeExporterConfigApplyConfiguration) *ClusterMonitoringSpecApplyConfiguration {
+ b.NodeExporterConfig = value
+ return b
+}
+
+// WithMonitoringPluginConfig sets the MonitoringPluginConfig field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the MonitoringPluginConfig field is set to the value of the last call.
+func (b *ClusterMonitoringSpecApplyConfiguration) WithMonitoringPluginConfig(value *MonitoringPluginConfigApplyConfiguration) *ClusterMonitoringSpecApplyConfiguration {
+ b.MonitoringPluginConfig = value
+ return b
+}
+
+// WithKubeStateMetricsConfig sets the KubeStateMetricsConfig field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the KubeStateMetricsConfig field is set to the value of the last call.
+func (b *ClusterMonitoringSpecApplyConfiguration) WithKubeStateMetricsConfig(value *KubeStateMetricsConfigApplyConfiguration) *ClusterMonitoringSpecApplyConfiguration {
+ b.KubeStateMetricsConfig = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/containerresource.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/containerresource.go
index d600828b01..2240e1b154 100644
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/containerresource.go
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/containerresource.go
@@ -9,6 +9,12 @@ import (
// ContainerResourceApplyConfiguration represents a declarative configuration of the ContainerResource type for use
// with apply.
//
+// MaxItems on []ContainerResource fields is kept at 5 to stay within the
+// Kubernetes CRD CEL validation cost budget (StaticEstimatedCRDCostLimit).
+// The quantity() CEL function has a high fixed estimated cost per invocation,
+// and the limit-vs-request comparison rule is costed per maxItems per location.
+// With multiple structs in ClusterMonitoringSpec embedding []ContainerResource,
+// maxItems > 5 causes the total estimated rule cost to exceed the budget.
// ContainerResource defines a single resource requirement for a container.
type ContainerResourceApplyConfiguration struct {
// name of the resource (e.g. "cpu", "memory", "hugepages-2Mi").
@@ -18,6 +24,7 @@ type ContainerResourceApplyConfiguration struct {
// request is the minimum amount of the resource required (e.g. "2Mi", "1Gi").
// This field is optional.
// When limit is specified, request cannot be greater than limit.
+ // The value must be greater than 0 when specified.
Request *resource.Quantity `json:"request,omitempty"`
// limit is the maximum amount of the resource allowed (e.g. "2Mi", "1Gi").
// This field is optional.
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/dropequalactionconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/dropequalactionconfig.go
new file mode 100644
index 0000000000..1e0a8e0014
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/dropequalactionconfig.go
@@ -0,0 +1,29 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+// DropEqualActionConfigApplyConfiguration represents a declarative configuration of the DropEqualActionConfig type for use
+// with apply.
+//
+// DropEqualActionConfig configures the DropEqual action.
+// Drops targets for which the concatenated source_labels do match the value of target_label.
+// Requires Prometheus >= v2.41.0.
+type DropEqualActionConfigApplyConfiguration struct {
+ // targetLabel is the label name whose value is compared to the concatenated source_labels; targets that match are dropped.
+ // Must be between 1 and 128 characters in length.
+ TargetLabel *string `json:"targetLabel,omitempty"`
+}
+
+// DropEqualActionConfigApplyConfiguration constructs a declarative configuration of the DropEqualActionConfig type for use with
+// apply.
+func DropEqualActionConfig() *DropEqualActionConfigApplyConfiguration {
+ return &DropEqualActionConfigApplyConfiguration{}
+}
+
+// WithTargetLabel sets the TargetLabel field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the TargetLabel field is set to the value of the last call.
+func (b *DropEqualActionConfigApplyConfiguration) WithTargetLabel(value string) *DropEqualActionConfigApplyConfiguration {
+ b.TargetLabel = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/hashmodactionconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/hashmodactionconfig.go
new file mode 100644
index 0000000000..453795b42b
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/hashmodactionconfig.go
@@ -0,0 +1,40 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+// HashModActionConfigApplyConfiguration represents a declarative configuration of the HashModActionConfig type for use
+// with apply.
+//
+// HashModActionConfig configures the HashMod action.
+// target_label is set to the modulus of a hash of the concatenated source_labels (target = hash % modulus).
+type HashModActionConfigApplyConfiguration struct {
+ // targetLabel is the label name where the hash modulus result is written.
+ // Must be between 1 and 128 characters in length.
+ TargetLabel *string `json:"targetLabel,omitempty"`
+ // modulus is the divisor applied to the hash of the concatenated source label values (target = hash % modulus).
+ // Required when using the HashMod action so the intended behavior is explicit.
+ // Must be between 1 and 1000000.
+ Modulus *int64 `json:"modulus,omitempty"`
+}
+
+// HashModActionConfigApplyConfiguration constructs a declarative configuration of the HashModActionConfig type for use with
+// apply.
+func HashModActionConfig() *HashModActionConfigApplyConfiguration {
+ return &HashModActionConfigApplyConfiguration{}
+}
+
+// WithTargetLabel sets the TargetLabel field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the TargetLabel field is set to the value of the last call.
+func (b *HashModActionConfigApplyConfiguration) WithTargetLabel(value string) *HashModActionConfigApplyConfiguration {
+ b.TargetLabel = &value
+ return b
+}
+
+// WithModulus sets the Modulus field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Modulus field is set to the value of the last call.
+func (b *HashModActionConfigApplyConfiguration) WithModulus(value int64) *HashModActionConfigApplyConfiguration {
+ b.Modulus = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/imagepolicy.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/imagepolicy.go
deleted file mode 100644
index 68a813c1af..0000000000
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/imagepolicy.go
+++ /dev/null
@@ -1,279 +0,0 @@
-// Code generated by applyconfiguration-gen. DO NOT EDIT.
-
-package v1alpha1
-
-import (
- configv1alpha1 "github.com/openshift/api/config/v1alpha1"
- internal "github.com/openshift/client-go/config/applyconfigurations/internal"
- metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
- types "k8s.io/apimachinery/pkg/types"
- managedfields "k8s.io/apimachinery/pkg/util/managedfields"
- v1 "k8s.io/client-go/applyconfigurations/meta/v1"
-)
-
-// ImagePolicyApplyConfiguration represents a declarative configuration of the ImagePolicy type for use
-// with apply.
-//
-// # ImagePolicy holds namespace-wide configuration for image signature verification
-//
-// Compatibility level 4: No compatibility is provided, the API can change at any point for any reason. These capabilities should not be used by applications needing long term support.
-type ImagePolicyApplyConfiguration struct {
- v1.TypeMetaApplyConfiguration `json:",inline"`
- // metadata is the standard object's metadata.
- // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
- *v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"`
- // spec holds user settable values for configuration
- Spec *ImagePolicySpecApplyConfiguration `json:"spec,omitempty"`
- // status contains the observed state of the resource.
- Status *ImagePolicyStatusApplyConfiguration `json:"status,omitempty"`
-}
-
-// ImagePolicy constructs a declarative configuration of the ImagePolicy type for use with
-// apply.
-func ImagePolicy(name, namespace string) *ImagePolicyApplyConfiguration {
- b := &ImagePolicyApplyConfiguration{}
- b.WithName(name)
- b.WithNamespace(namespace)
- b.WithKind("ImagePolicy")
- b.WithAPIVersion("config.openshift.io/v1alpha1")
- return b
-}
-
-// ExtractImagePolicyFrom extracts the applied configuration owned by fieldManager from
-// imagePolicy for the specified subresource. Pass an empty string for subresource to extract
-// the main resource. Common subresources include "status", "scale", etc.
-// imagePolicy must be a unmodified ImagePolicy API object that was retrieved from the Kubernetes API.
-// ExtractImagePolicyFrom provides a way to perform a extract/modify-in-place/apply workflow.
-// Note that an extracted apply configuration will contain fewer fields than what the fieldManager previously
-// applied if another fieldManager has updated or force applied any of the previously applied fields.
-func ExtractImagePolicyFrom(imagePolicy *configv1alpha1.ImagePolicy, fieldManager string, subresource string) (*ImagePolicyApplyConfiguration, error) {
- b := &ImagePolicyApplyConfiguration{}
- err := managedfields.ExtractInto(imagePolicy, internal.Parser().Type("com.github.openshift.api.config.v1alpha1.ImagePolicy"), fieldManager, b, subresource)
- if err != nil {
- return nil, err
- }
- b.WithName(imagePolicy.Name)
- b.WithNamespace(imagePolicy.Namespace)
-
- b.WithKind("ImagePolicy")
- b.WithAPIVersion("config.openshift.io/v1alpha1")
- return b, nil
-}
-
-// ExtractImagePolicy extracts the applied configuration owned by fieldManager from
-// imagePolicy. If no managedFields are found in imagePolicy for fieldManager, a
-// ImagePolicyApplyConfiguration is returned with only the Name, Namespace (if applicable),
-// APIVersion and Kind populated. It is possible that no managed fields were found for because other
-// field managers have taken ownership of all the fields previously owned by fieldManager, or because
-// the fieldManager never owned fields any fields.
-// imagePolicy must be a unmodified ImagePolicy API object that was retrieved from the Kubernetes API.
-// ExtractImagePolicy provides a way to perform a extract/modify-in-place/apply workflow.
-// Note that an extracted apply configuration will contain fewer fields than what the fieldManager previously
-// applied if another fieldManager has updated or force applied any of the previously applied fields.
-func ExtractImagePolicy(imagePolicy *configv1alpha1.ImagePolicy, fieldManager string) (*ImagePolicyApplyConfiguration, error) {
- return ExtractImagePolicyFrom(imagePolicy, fieldManager, "")
-}
-
-// ExtractImagePolicyStatus extracts the applied configuration owned by fieldManager from
-// imagePolicy for the status subresource.
-func ExtractImagePolicyStatus(imagePolicy *configv1alpha1.ImagePolicy, fieldManager string) (*ImagePolicyApplyConfiguration, error) {
- return ExtractImagePolicyFrom(imagePolicy, fieldManager, "status")
-}
-
-func (b ImagePolicyApplyConfiguration) IsApplyConfiguration() {}
-
-// WithKind sets the Kind field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the Kind field is set to the value of the last call.
-func (b *ImagePolicyApplyConfiguration) WithKind(value string) *ImagePolicyApplyConfiguration {
- b.TypeMetaApplyConfiguration.Kind = &value
- return b
-}
-
-// WithAPIVersion sets the APIVersion field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the APIVersion field is set to the value of the last call.
-func (b *ImagePolicyApplyConfiguration) WithAPIVersion(value string) *ImagePolicyApplyConfiguration {
- b.TypeMetaApplyConfiguration.APIVersion = &value
- return b
-}
-
-// WithName sets the Name field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the Name field is set to the value of the last call.
-func (b *ImagePolicyApplyConfiguration) WithName(value string) *ImagePolicyApplyConfiguration {
- b.ensureObjectMetaApplyConfigurationExists()
- b.ObjectMetaApplyConfiguration.Name = &value
- return b
-}
-
-// WithGenerateName sets the GenerateName field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the GenerateName field is set to the value of the last call.
-func (b *ImagePolicyApplyConfiguration) WithGenerateName(value string) *ImagePolicyApplyConfiguration {
- b.ensureObjectMetaApplyConfigurationExists()
- b.ObjectMetaApplyConfiguration.GenerateName = &value
- return b
-}
-
-// WithNamespace sets the Namespace field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the Namespace field is set to the value of the last call.
-func (b *ImagePolicyApplyConfiguration) WithNamespace(value string) *ImagePolicyApplyConfiguration {
- b.ensureObjectMetaApplyConfigurationExists()
- b.ObjectMetaApplyConfiguration.Namespace = &value
- return b
-}
-
-// WithUID sets the UID field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the UID field is set to the value of the last call.
-func (b *ImagePolicyApplyConfiguration) WithUID(value types.UID) *ImagePolicyApplyConfiguration {
- b.ensureObjectMetaApplyConfigurationExists()
- b.ObjectMetaApplyConfiguration.UID = &value
- return b
-}
-
-// WithResourceVersion sets the ResourceVersion field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the ResourceVersion field is set to the value of the last call.
-func (b *ImagePolicyApplyConfiguration) WithResourceVersion(value string) *ImagePolicyApplyConfiguration {
- b.ensureObjectMetaApplyConfigurationExists()
- b.ObjectMetaApplyConfiguration.ResourceVersion = &value
- return b
-}
-
-// WithGeneration sets the Generation field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the Generation field is set to the value of the last call.
-func (b *ImagePolicyApplyConfiguration) WithGeneration(value int64) *ImagePolicyApplyConfiguration {
- b.ensureObjectMetaApplyConfigurationExists()
- b.ObjectMetaApplyConfiguration.Generation = &value
- return b
-}
-
-// WithCreationTimestamp sets the CreationTimestamp field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the CreationTimestamp field is set to the value of the last call.
-func (b *ImagePolicyApplyConfiguration) WithCreationTimestamp(value metav1.Time) *ImagePolicyApplyConfiguration {
- b.ensureObjectMetaApplyConfigurationExists()
- b.ObjectMetaApplyConfiguration.CreationTimestamp = &value
- return b
-}
-
-// WithDeletionTimestamp sets the DeletionTimestamp field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the DeletionTimestamp field is set to the value of the last call.
-func (b *ImagePolicyApplyConfiguration) WithDeletionTimestamp(value metav1.Time) *ImagePolicyApplyConfiguration {
- b.ensureObjectMetaApplyConfigurationExists()
- b.ObjectMetaApplyConfiguration.DeletionTimestamp = &value
- return b
-}
-
-// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the DeletionGracePeriodSeconds field is set to the value of the last call.
-func (b *ImagePolicyApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *ImagePolicyApplyConfiguration {
- b.ensureObjectMetaApplyConfigurationExists()
- b.ObjectMetaApplyConfiguration.DeletionGracePeriodSeconds = &value
- return b
-}
-
-// WithLabels puts the entries into the Labels field in the declarative configuration
-// and returns the receiver, so that objects can be build by chaining "With" function invocations.
-// If called multiple times, the entries provided by each call will be put on the Labels field,
-// overwriting an existing map entries in Labels field with the same key.
-func (b *ImagePolicyApplyConfiguration) WithLabels(entries map[string]string) *ImagePolicyApplyConfiguration {
- b.ensureObjectMetaApplyConfigurationExists()
- if b.ObjectMetaApplyConfiguration.Labels == nil && len(entries) > 0 {
- b.ObjectMetaApplyConfiguration.Labels = make(map[string]string, len(entries))
- }
- for k, v := range entries {
- b.ObjectMetaApplyConfiguration.Labels[k] = v
- }
- return b
-}
-
-// WithAnnotations puts the entries into the Annotations field in the declarative configuration
-// and returns the receiver, so that objects can be build by chaining "With" function invocations.
-// If called multiple times, the entries provided by each call will be put on the Annotations field,
-// overwriting an existing map entries in Annotations field with the same key.
-func (b *ImagePolicyApplyConfiguration) WithAnnotations(entries map[string]string) *ImagePolicyApplyConfiguration {
- b.ensureObjectMetaApplyConfigurationExists()
- if b.ObjectMetaApplyConfiguration.Annotations == nil && len(entries) > 0 {
- b.ObjectMetaApplyConfiguration.Annotations = make(map[string]string, len(entries))
- }
- for k, v := range entries {
- b.ObjectMetaApplyConfiguration.Annotations[k] = v
- }
- return b
-}
-
-// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration
-// and returns the receiver, so that objects can be build by chaining "With" function invocations.
-// If called multiple times, values provided by each call will be appended to the OwnerReferences field.
-func (b *ImagePolicyApplyConfiguration) WithOwnerReferences(values ...*v1.OwnerReferenceApplyConfiguration) *ImagePolicyApplyConfiguration {
- b.ensureObjectMetaApplyConfigurationExists()
- for i := range values {
- if values[i] == nil {
- panic("nil value passed to WithOwnerReferences")
- }
- b.ObjectMetaApplyConfiguration.OwnerReferences = append(b.ObjectMetaApplyConfiguration.OwnerReferences, *values[i])
- }
- return b
-}
-
-// WithFinalizers adds the given value to the Finalizers field in the declarative configuration
-// and returns the receiver, so that objects can be build by chaining "With" function invocations.
-// If called multiple times, values provided by each call will be appended to the Finalizers field.
-func (b *ImagePolicyApplyConfiguration) WithFinalizers(values ...string) *ImagePolicyApplyConfiguration {
- b.ensureObjectMetaApplyConfigurationExists()
- for i := range values {
- b.ObjectMetaApplyConfiguration.Finalizers = append(b.ObjectMetaApplyConfiguration.Finalizers, values[i])
- }
- return b
-}
-
-func (b *ImagePolicyApplyConfiguration) ensureObjectMetaApplyConfigurationExists() {
- if b.ObjectMetaApplyConfiguration == nil {
- b.ObjectMetaApplyConfiguration = &v1.ObjectMetaApplyConfiguration{}
- }
-}
-
-// WithSpec sets the Spec field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the Spec field is set to the value of the last call.
-func (b *ImagePolicyApplyConfiguration) WithSpec(value *ImagePolicySpecApplyConfiguration) *ImagePolicyApplyConfiguration {
- b.Spec = value
- return b
-}
-
-// WithStatus sets the Status field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the Status field is set to the value of the last call.
-func (b *ImagePolicyApplyConfiguration) WithStatus(value *ImagePolicyStatusApplyConfiguration) *ImagePolicyApplyConfiguration {
- b.Status = value
- return b
-}
-
-// GetKind retrieves the value of the Kind field in the declarative configuration.
-func (b *ImagePolicyApplyConfiguration) GetKind() *string {
- return b.TypeMetaApplyConfiguration.Kind
-}
-
-// GetAPIVersion retrieves the value of the APIVersion field in the declarative configuration.
-func (b *ImagePolicyApplyConfiguration) GetAPIVersion() *string {
- return b.TypeMetaApplyConfiguration.APIVersion
-}
-
-// GetName retrieves the value of the Name field in the declarative configuration.
-func (b *ImagePolicyApplyConfiguration) GetName() *string {
- b.ensureObjectMetaApplyConfigurationExists()
- return b.ObjectMetaApplyConfiguration.Name
-}
-
-// GetNamespace retrieves the value of the Namespace field in the declarative configuration.
-func (b *ImagePolicyApplyConfiguration) GetNamespace() *string {
- b.ensureObjectMetaApplyConfigurationExists()
- return b.ObjectMetaApplyConfiguration.Namespace
-}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/imagepolicyfulciocawithrekorrootoftrust.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/imagepolicyfulciocawithrekorrootoftrust.go
deleted file mode 100644
index c9299e5000..0000000000
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/imagepolicyfulciocawithrekorrootoftrust.go
+++ /dev/null
@@ -1,52 +0,0 @@
-// Code generated by applyconfiguration-gen. DO NOT EDIT.
-
-package v1alpha1
-
-// ImagePolicyFulcioCAWithRekorRootOfTrustApplyConfiguration represents a declarative configuration of the ImagePolicyFulcioCAWithRekorRootOfTrust type for use
-// with apply.
-//
-// ImagePolicyFulcioCAWithRekorRootOfTrust defines the root of trust based on the Fulcio certificate and the Rekor public key.
-type ImagePolicyFulcioCAWithRekorRootOfTrustApplyConfiguration struct {
- // fulcioCAData contains inline base64-encoded data for the PEM format fulcio CA.
- // fulcioCAData must be at most 8192 characters.
- FulcioCAData []byte `json:"fulcioCAData,omitempty"`
- // rekorKeyData contains inline base64-encoded data for the PEM format from the Rekor public key.
- // rekorKeyData must be at most 8192 characters.
- RekorKeyData []byte `json:"rekorKeyData,omitempty"`
- // fulcioSubject specifies OIDC issuer and the email of the Fulcio authentication configuration.
- FulcioSubject *PolicyFulcioSubjectApplyConfiguration `json:"fulcioSubject,omitempty"`
-}
-
-// ImagePolicyFulcioCAWithRekorRootOfTrustApplyConfiguration constructs a declarative configuration of the ImagePolicyFulcioCAWithRekorRootOfTrust type for use with
-// apply.
-func ImagePolicyFulcioCAWithRekorRootOfTrust() *ImagePolicyFulcioCAWithRekorRootOfTrustApplyConfiguration {
- return &ImagePolicyFulcioCAWithRekorRootOfTrustApplyConfiguration{}
-}
-
-// WithFulcioCAData adds the given value to the FulcioCAData field in the declarative configuration
-// and returns the receiver, so that objects can be build by chaining "With" function invocations.
-// If called multiple times, values provided by each call will be appended to the FulcioCAData field.
-func (b *ImagePolicyFulcioCAWithRekorRootOfTrustApplyConfiguration) WithFulcioCAData(values ...byte) *ImagePolicyFulcioCAWithRekorRootOfTrustApplyConfiguration {
- for i := range values {
- b.FulcioCAData = append(b.FulcioCAData, values[i])
- }
- return b
-}
-
-// WithRekorKeyData adds the given value to the RekorKeyData field in the declarative configuration
-// and returns the receiver, so that objects can be build by chaining "With" function invocations.
-// If called multiple times, values provided by each call will be appended to the RekorKeyData field.
-func (b *ImagePolicyFulcioCAWithRekorRootOfTrustApplyConfiguration) WithRekorKeyData(values ...byte) *ImagePolicyFulcioCAWithRekorRootOfTrustApplyConfiguration {
- for i := range values {
- b.RekorKeyData = append(b.RekorKeyData, values[i])
- }
- return b
-}
-
-// WithFulcioSubject sets the FulcioSubject field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the FulcioSubject field is set to the value of the last call.
-func (b *ImagePolicyFulcioCAWithRekorRootOfTrustApplyConfiguration) WithFulcioSubject(value *PolicyFulcioSubjectApplyConfiguration) *ImagePolicyFulcioCAWithRekorRootOfTrustApplyConfiguration {
- b.FulcioSubject = value
- return b
-}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/imagepolicypkirootoftrust.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/imagepolicypkirootoftrust.go
deleted file mode 100644
index 42c3c0aa7c..0000000000
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/imagepolicypkirootoftrust.go
+++ /dev/null
@@ -1,51 +0,0 @@
-// Code generated by applyconfiguration-gen. DO NOT EDIT.
-
-package v1alpha1
-
-// ImagePolicyPKIRootOfTrustApplyConfiguration represents a declarative configuration of the ImagePolicyPKIRootOfTrust type for use
-// with apply.
-//
-// ImagePolicyPKIRootOfTrust defines the root of trust based on Root CA(s) and corresponding intermediate certificates.
-type ImagePolicyPKIRootOfTrustApplyConfiguration struct {
- // caRootsData contains base64-encoded data of a certificate bundle PEM file, which contains one or more CA roots in the PEM format. The total length of the data must not exceed 8192 characters.
- CertificateAuthorityRootsData []byte `json:"caRootsData,omitempty"`
- // caIntermediatesData contains base64-encoded data of a certificate bundle PEM file, which contains one or more intermediate certificates in the PEM format. The total length of the data must not exceed 8192 characters.
- // caIntermediatesData requires caRootsData to be set.
- CertificateAuthorityIntermediatesData []byte `json:"caIntermediatesData,omitempty"`
- // pkiCertificateSubject defines the requirements imposed on the subject to which the certificate was issued.
- PKICertificateSubject *PKICertificateSubjectApplyConfiguration `json:"pkiCertificateSubject,omitempty"`
-}
-
-// ImagePolicyPKIRootOfTrustApplyConfiguration constructs a declarative configuration of the ImagePolicyPKIRootOfTrust type for use with
-// apply.
-func ImagePolicyPKIRootOfTrust() *ImagePolicyPKIRootOfTrustApplyConfiguration {
- return &ImagePolicyPKIRootOfTrustApplyConfiguration{}
-}
-
-// WithCertificateAuthorityRootsData adds the given value to the CertificateAuthorityRootsData field in the declarative configuration
-// and returns the receiver, so that objects can be build by chaining "With" function invocations.
-// If called multiple times, values provided by each call will be appended to the CertificateAuthorityRootsData field.
-func (b *ImagePolicyPKIRootOfTrustApplyConfiguration) WithCertificateAuthorityRootsData(values ...byte) *ImagePolicyPKIRootOfTrustApplyConfiguration {
- for i := range values {
- b.CertificateAuthorityRootsData = append(b.CertificateAuthorityRootsData, values[i])
- }
- return b
-}
-
-// WithCertificateAuthorityIntermediatesData adds the given value to the CertificateAuthorityIntermediatesData field in the declarative configuration
-// and returns the receiver, so that objects can be build by chaining "With" function invocations.
-// If called multiple times, values provided by each call will be appended to the CertificateAuthorityIntermediatesData field.
-func (b *ImagePolicyPKIRootOfTrustApplyConfiguration) WithCertificateAuthorityIntermediatesData(values ...byte) *ImagePolicyPKIRootOfTrustApplyConfiguration {
- for i := range values {
- b.CertificateAuthorityIntermediatesData = append(b.CertificateAuthorityIntermediatesData, values[i])
- }
- return b
-}
-
-// WithPKICertificateSubject sets the PKICertificateSubject field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the PKICertificateSubject field is set to the value of the last call.
-func (b *ImagePolicyPKIRootOfTrustApplyConfiguration) WithPKICertificateSubject(value *PKICertificateSubjectApplyConfiguration) *ImagePolicyPKIRootOfTrustApplyConfiguration {
- b.PKICertificateSubject = value
- return b
-}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/imagepolicypublickeyrootoftrust.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/imagepolicypublickeyrootoftrust.go
deleted file mode 100644
index 317b1be6ad..0000000000
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/imagepolicypublickeyrootoftrust.go
+++ /dev/null
@@ -1,42 +0,0 @@
-// Code generated by applyconfiguration-gen. DO NOT EDIT.
-
-package v1alpha1
-
-// ImagePolicyPublicKeyRootOfTrustApplyConfiguration represents a declarative configuration of the ImagePolicyPublicKeyRootOfTrust type for use
-// with apply.
-//
-// ImagePolicyPublicKeyRootOfTrust defines the root of trust based on a sigstore public key.
-type ImagePolicyPublicKeyRootOfTrustApplyConfiguration struct {
- // keyData contains inline base64-encoded data for the PEM format public key.
- // KeyData must be at most 8192 characters.
- KeyData []byte `json:"keyData,omitempty"`
- // rekorKeyData contains inline base64-encoded data for the PEM format from the Rekor public key.
- // rekorKeyData must be at most 8192 characters.
- RekorKeyData []byte `json:"rekorKeyData,omitempty"`
-}
-
-// ImagePolicyPublicKeyRootOfTrustApplyConfiguration constructs a declarative configuration of the ImagePolicyPublicKeyRootOfTrust type for use with
-// apply.
-func ImagePolicyPublicKeyRootOfTrust() *ImagePolicyPublicKeyRootOfTrustApplyConfiguration {
- return &ImagePolicyPublicKeyRootOfTrustApplyConfiguration{}
-}
-
-// WithKeyData adds the given value to the KeyData field in the declarative configuration
-// and returns the receiver, so that objects can be build by chaining "With" function invocations.
-// If called multiple times, values provided by each call will be appended to the KeyData field.
-func (b *ImagePolicyPublicKeyRootOfTrustApplyConfiguration) WithKeyData(values ...byte) *ImagePolicyPublicKeyRootOfTrustApplyConfiguration {
- for i := range values {
- b.KeyData = append(b.KeyData, values[i])
- }
- return b
-}
-
-// WithRekorKeyData adds the given value to the RekorKeyData field in the declarative configuration
-// and returns the receiver, so that objects can be build by chaining "With" function invocations.
-// If called multiple times, values provided by each call will be appended to the RekorKeyData field.
-func (b *ImagePolicyPublicKeyRootOfTrustApplyConfiguration) WithRekorKeyData(values ...byte) *ImagePolicyPublicKeyRootOfTrustApplyConfiguration {
- for i := range values {
- b.RekorKeyData = append(b.RekorKeyData, values[i])
- }
- return b
-}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/imagepolicyspec.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/imagepolicyspec.go
deleted file mode 100644
index 0d8cbf64b7..0000000000
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/imagepolicyspec.go
+++ /dev/null
@@ -1,53 +0,0 @@
-// Code generated by applyconfiguration-gen. DO NOT EDIT.
-
-package v1alpha1
-
-import (
- configv1alpha1 "github.com/openshift/api/config/v1alpha1"
-)
-
-// ImagePolicySpecApplyConfiguration represents a declarative configuration of the ImagePolicySpec type for use
-// with apply.
-//
-// ImagePolicySpec is the specification of the ImagePolicy CRD.
-type ImagePolicySpecApplyConfiguration struct {
- // scopes defines the list of image identities assigned to a policy. Each item refers to a scope in a registry implementing the "Docker Registry HTTP API V2".
- // Scopes matching individual images are named Docker references in the fully expanded form, either using a tag or digest. For example, docker.io/library/busybox:latest (not busybox:latest).
- // More general scopes are prefixes of individual-image scopes, and specify a repository (by omitting the tag or digest), a repository
- // namespace, or a registry host (by only specifying the host name and possibly a port number) or a wildcard expression starting with `*.`, for matching all subdomains (not including a port number).
- // Wildcards are only supported for subdomain matching, and may not be used in the middle of the host, i.e. *.example.com is a valid case, but example*.*.com is not.
- // If multiple scopes match a given image, only the policy requirements for the most specific scope apply. The policy requirements for more general scopes are ignored.
- // In addition to setting a policy appropriate for your own deployed applications, make sure that a policy on the OpenShift image repositories
- // quay.io/openshift-release-dev/ocp-release, quay.io/openshift-release-dev/ocp-v4.0-art-dev (or on a more general scope) allows deployment of the OpenShift images required for cluster operation.
- // If a scope is configured in both the ClusterImagePolicy and the ImagePolicy, or if the scope in ImagePolicy is nested under one of the scopes from the ClusterImagePolicy, only the policy from the ClusterImagePolicy will be applied.
- // For additional details about the format, please refer to the document explaining the docker transport field,
- // which can be found at: https://github.com/containers/image/blob/main/docs/containers-policy.json.5.md#docker
- Scopes []configv1alpha1.ImageScope `json:"scopes,omitempty"`
- // policy contains configuration to allow scopes to be verified, and defines how
- // images not matching the verification policy will be treated.
- Policy *ImageSigstoreVerificationPolicyApplyConfiguration `json:"policy,omitempty"`
-}
-
-// ImagePolicySpecApplyConfiguration constructs a declarative configuration of the ImagePolicySpec type for use with
-// apply.
-func ImagePolicySpec() *ImagePolicySpecApplyConfiguration {
- return &ImagePolicySpecApplyConfiguration{}
-}
-
-// WithScopes adds the given value to the Scopes field in the declarative configuration
-// and returns the receiver, so that objects can be build by chaining "With" function invocations.
-// If called multiple times, values provided by each call will be appended to the Scopes field.
-func (b *ImagePolicySpecApplyConfiguration) WithScopes(values ...configv1alpha1.ImageScope) *ImagePolicySpecApplyConfiguration {
- for i := range values {
- b.Scopes = append(b.Scopes, values[i])
- }
- return b
-}
-
-// WithPolicy sets the Policy field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the Policy field is set to the value of the last call.
-func (b *ImagePolicySpecApplyConfiguration) WithPolicy(value *ImageSigstoreVerificationPolicyApplyConfiguration) *ImagePolicySpecApplyConfiguration {
- b.Policy = value
- return b
-}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/imagepolicystatus.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/imagepolicystatus.go
deleted file mode 100644
index 59fc118561..0000000000
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/imagepolicystatus.go
+++ /dev/null
@@ -1,33 +0,0 @@
-// Code generated by applyconfiguration-gen. DO NOT EDIT.
-
-package v1alpha1
-
-import (
- v1 "k8s.io/client-go/applyconfigurations/meta/v1"
-)
-
-// ImagePolicyStatusApplyConfiguration represents a declarative configuration of the ImagePolicyStatus type for use
-// with apply.
-type ImagePolicyStatusApplyConfiguration struct {
- // conditions provide details on the status of this API Resource.
- Conditions []v1.ConditionApplyConfiguration `json:"conditions,omitempty"`
-}
-
-// ImagePolicyStatusApplyConfiguration constructs a declarative configuration of the ImagePolicyStatus type for use with
-// apply.
-func ImagePolicyStatus() *ImagePolicyStatusApplyConfiguration {
- return &ImagePolicyStatusApplyConfiguration{}
-}
-
-// WithConditions adds the given value to the Conditions field in the declarative configuration
-// and returns the receiver, so that objects can be build by chaining "With" function invocations.
-// If called multiple times, values provided by each call will be appended to the Conditions field.
-func (b *ImagePolicyStatusApplyConfiguration) WithConditions(values ...*v1.ConditionApplyConfiguration) *ImagePolicyStatusApplyConfiguration {
- for i := range values {
- if values[i] == nil {
- panic("nil value passed to WithConditions")
- }
- b.Conditions = append(b.Conditions, *values[i])
- }
- return b
-}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/imagesigstoreverificationpolicy.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/imagesigstoreverificationpolicy.go
deleted file mode 100644
index 3fa4e27478..0000000000
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/imagesigstoreverificationpolicy.go
+++ /dev/null
@@ -1,36 +0,0 @@
-// Code generated by applyconfiguration-gen. DO NOT EDIT.
-
-package v1alpha1
-
-// ImageSigstoreVerificationPolicyApplyConfiguration represents a declarative configuration of the ImageSigstoreVerificationPolicy type for use
-// with apply.
-//
-// ImageSigstoreVerificationPolicy defines the verification policy for the items in the scopes list.
-type ImageSigstoreVerificationPolicyApplyConfiguration struct {
- // rootOfTrust specifies the root of trust for the policy.
- RootOfTrust *PolicyRootOfTrustApplyConfiguration `json:"rootOfTrust,omitempty"`
- // signedIdentity specifies what image identity the signature claims about the image. The required matchPolicy field specifies the approach used in the verification process to verify the identity in the signature and the actual image identity, the default matchPolicy is "MatchRepoDigestOrExact".
- SignedIdentity *PolicyIdentityApplyConfiguration `json:"signedIdentity,omitempty"`
-}
-
-// ImageSigstoreVerificationPolicyApplyConfiguration constructs a declarative configuration of the ImageSigstoreVerificationPolicy type for use with
-// apply.
-func ImageSigstoreVerificationPolicy() *ImageSigstoreVerificationPolicyApplyConfiguration {
- return &ImageSigstoreVerificationPolicyApplyConfiguration{}
-}
-
-// WithRootOfTrust sets the RootOfTrust field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the RootOfTrust field is set to the value of the last call.
-func (b *ImageSigstoreVerificationPolicyApplyConfiguration) WithRootOfTrust(value *PolicyRootOfTrustApplyConfiguration) *ImageSigstoreVerificationPolicyApplyConfiguration {
- b.RootOfTrust = value
- return b
-}
-
-// WithSignedIdentity sets the SignedIdentity field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the SignedIdentity field is set to the value of the last call.
-func (b *ImageSigstoreVerificationPolicyApplyConfiguration) WithSignedIdentity(value *PolicyIdentityApplyConfiguration) *ImageSigstoreVerificationPolicyApplyConfiguration {
- b.SignedIdentity = value
- return b
-}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/keepequalactionconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/keepequalactionconfig.go
new file mode 100644
index 0000000000..a560a662a8
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/keepequalactionconfig.go
@@ -0,0 +1,29 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+// KeepEqualActionConfigApplyConfiguration represents a declarative configuration of the KeepEqualActionConfig type for use
+// with apply.
+//
+// KeepEqualActionConfig configures the KeepEqual action.
+// Drops targets for which the concatenated source_labels do not match the value of target_label.
+// Requires Prometheus >= v2.41.0.
+type KeepEqualActionConfigApplyConfiguration struct {
+ // targetLabel is the label name whose value is compared to the concatenated source_labels; targets that do not match are dropped.
+ // Must be between 1 and 128 characters in length.
+ TargetLabel *string `json:"targetLabel,omitempty"`
+}
+
+// KeepEqualActionConfigApplyConfiguration constructs a declarative configuration of the KeepEqualActionConfig type for use with
+// apply.
+func KeepEqualActionConfig() *KeepEqualActionConfigApplyConfiguration {
+ return &KeepEqualActionConfigApplyConfiguration{}
+}
+
+// WithTargetLabel sets the TargetLabel field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the TargetLabel field is set to the value of the last call.
+func (b *KeepEqualActionConfigApplyConfiguration) WithTargetLabel(value string) *KeepEqualActionConfigApplyConfiguration {
+ b.TargetLabel = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/kubestatemetricsconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/kubestatemetricsconfig.go
new file mode 100644
index 0000000000..ed850ef346
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/kubestatemetricsconfig.go
@@ -0,0 +1,145 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ v1 "k8s.io/api/core/v1"
+)
+
+// KubeStateMetricsConfigApplyConfiguration represents a declarative configuration of the KubeStateMetricsConfig type for use
+// with apply.
+//
+// KubeStateMetricsConfig provides configuration options for the kube-state-metrics agent
+// that runs in the `openshift-monitoring` namespace. kube-state-metrics generates metrics
+// about the state of Kubernetes objects such as Deployments, Nodes, and Pods.
+type KubeStateMetricsConfigApplyConfiguration struct {
+ // nodeSelector defines the nodes on which the Pods are scheduled.
+ // nodeSelector is optional.
+ //
+ // When omitted, this means the user has no opinion and the platform is left
+ // to choose reasonable defaults. These defaults are subject to change over time.
+ // The current default value is `kubernetes.io/os: linux`.
+ // When specified, nodeSelector must contain at least 1 entry and must not contain more than 10 entries.
+ NodeSelector map[string]string `json:"nodeSelector,omitempty"`
+ // resources defines the compute resource requests and limits for the kube-state-metrics container.
+ // This includes CPU, memory and HugePages constraints to help control scheduling and resource usage.
+ // When not specified, defaults are used by the platform. Requests cannot exceed limits.
+ // This field is optional.
+ // More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/
+ // This is a simplified API that maps to Kubernetes ResourceRequirements.
+ // The current default values are:
+ // resources:
+ // - name: cpu
+ // request: 4m
+ // limit: null
+ // - name: memory
+ // request: 40Mi
+ // limit: null
+ // Maximum length for this list is 5.
+ // Minimum length for this list is 1.
+ // Each resource name must be unique within this list.
+ Resources []ContainerResourceApplyConfiguration `json:"resources,omitempty"`
+ // tolerations defines tolerations for the pods.
+ // tolerations is optional.
+ //
+ // When omitted, no tolerations are applied. This default is subject to change over time.
+ // When specified, tolerations must contain at least 1 entry and must not contain more than 10 entries.
+ // Each toleration's operator, when specified, must be either "Exists" or "Equal".
+ // Each toleration's effect, when specified, must be one of "NoSchedule", "PreferNoSchedule", or "NoExecute".
+ // An empty or unset effect means match all effects.
+ Tolerations []v1.Toleration `json:"tolerations,omitempty"`
+ // topologySpreadConstraints defines rules for how kube-state-metrics Pods should be distributed
+ // across topology domains such as zones, nodes, or other user-defined labels.
+ // topologySpreadConstraints is optional.
+ // This helps improve high availability and resource efficiency by avoiding placing
+ // too many replicas in the same failure domain.
+ //
+ // This field maps directly to the `topologySpreadConstraints` field in the Pod spec.
+ // When omitted, no topology spread constraints are applied. This default is subject to change over time.
+ // When specified, topologySpreadConstraints must contain at least 1 entry and must not contain more than 10 entries.
+ // Entries must have unique topologyKey and whenUnsatisfiable pairs.
+ // Each entry's whenUnsatisfiable must be either "DoNotSchedule" or "ScheduleAnyway".
+ // Each entry's maxSkew must be at least 1.
+ // When minDomains is specified, it must be at least 1 and whenUnsatisfiable must be "DoNotSchedule".
+ TopologySpreadConstraints []v1.TopologySpreadConstraint `json:"topologySpreadConstraints,omitempty"`
+ // additionalResourceLabels defines additional Kubernetes resource labels to expose as metrics
+ // in kube-state-metrics.
+ // Currently, only "Job" and "CronJob" resources are supported due to cardinality concerns.
+ // Each entry specifies a resource name and a list of Kubernetes label names to expose.
+ // Use "*" in the labels list to expose all labels for a given resource.
+ // additionalResourceLabels is optional.
+ // When omitted, no additional Kubernetes object labels are exposed as metrics
+ // by kube-state-metrics beyond its built-in metric labels (e.g. namespace, job_name).
+ // Use this field to opt in to exposing specific Kubernetes labels as metric labels
+ // for the supported resource types.
+ // Minimum length for this list is 1.
+ // Maximum length for this list is 2.
+ // Each resource name must be unique within this list.
+ AdditionalResourceLabels []KubeStateMetricsResourceLabelsApplyConfiguration `json:"additionalResourceLabels,omitempty"`
+}
+
+// KubeStateMetricsConfigApplyConfiguration constructs a declarative configuration of the KubeStateMetricsConfig type for use with
+// apply.
+func KubeStateMetricsConfig() *KubeStateMetricsConfigApplyConfiguration {
+ return &KubeStateMetricsConfigApplyConfiguration{}
+}
+
+// WithNodeSelector puts the entries into the NodeSelector field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, the entries provided by each call will be put on the NodeSelector field,
+// overwriting an existing map entries in NodeSelector field with the same key.
+func (b *KubeStateMetricsConfigApplyConfiguration) WithNodeSelector(entries map[string]string) *KubeStateMetricsConfigApplyConfiguration {
+ if b.NodeSelector == nil && len(entries) > 0 {
+ b.NodeSelector = make(map[string]string, len(entries))
+ }
+ for k, v := range entries {
+ b.NodeSelector[k] = v
+ }
+ return b
+}
+
+// WithResources adds the given value to the Resources field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the Resources field.
+func (b *KubeStateMetricsConfigApplyConfiguration) WithResources(values ...*ContainerResourceApplyConfiguration) *KubeStateMetricsConfigApplyConfiguration {
+ for i := range values {
+ if values[i] == nil {
+ panic("nil value passed to WithResources")
+ }
+ b.Resources = append(b.Resources, *values[i])
+ }
+ return b
+}
+
+// WithTolerations adds the given value to the Tolerations field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the Tolerations field.
+func (b *KubeStateMetricsConfigApplyConfiguration) WithTolerations(values ...v1.Toleration) *KubeStateMetricsConfigApplyConfiguration {
+ for i := range values {
+ b.Tolerations = append(b.Tolerations, values[i])
+ }
+ return b
+}
+
+// WithTopologySpreadConstraints adds the given value to the TopologySpreadConstraints field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the TopologySpreadConstraints field.
+func (b *KubeStateMetricsConfigApplyConfiguration) WithTopologySpreadConstraints(values ...v1.TopologySpreadConstraint) *KubeStateMetricsConfigApplyConfiguration {
+ for i := range values {
+ b.TopologySpreadConstraints = append(b.TopologySpreadConstraints, values[i])
+ }
+ return b
+}
+
+// WithAdditionalResourceLabels adds the given value to the AdditionalResourceLabels field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the AdditionalResourceLabels field.
+func (b *KubeStateMetricsConfigApplyConfiguration) WithAdditionalResourceLabels(values ...*KubeStateMetricsResourceLabelsApplyConfiguration) *KubeStateMetricsConfigApplyConfiguration {
+ for i := range values {
+ if values[i] == nil {
+ panic("nil value passed to WithAdditionalResourceLabels")
+ }
+ b.AdditionalResourceLabels = append(b.AdditionalResourceLabels, *values[i])
+ }
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/kubestatemetricsresourcelabels.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/kubestatemetricsresourcelabels.go
new file mode 100644
index 0000000000..8b4de02a9a
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/kubestatemetricsresourcelabels.go
@@ -0,0 +1,53 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ configv1alpha1 "github.com/openshift/api/config/v1alpha1"
+)
+
+// KubeStateMetricsResourceLabelsApplyConfiguration represents a declarative configuration of the KubeStateMetricsResourceLabels type for use
+// with apply.
+//
+// KubeStateMetricsResourceLabels defines which Kubernetes labels to expose as metrics
+// for a given resource type in kube-state-metrics.
+type KubeStateMetricsResourceLabelsApplyConfiguration struct {
+ // resource is the Kubernetes resource name whose labels should be exposed as metrics.
+ // Currently, only "Job" and "CronJob" are supported due to cardinality concerns.
+ // Valid values are "Job" and "CronJob".
+ // This field is required.
+ Resource *configv1alpha1.KubeStateMetricsResourceName `json:"resource,omitempty"`
+ // labels is the list of Kubernetes label names to expose as metrics for this resource.
+ // Use "*" to expose all labels for the specified resource.
+ // When "*" is specified, it must be the only entry in the list; mixing "*" with
+ // specific label names is not allowed.
+ // This field is required.
+ // Each label name must be unique within this list.
+ // Minimum length for this list is 1.
+ // Maximum length for this list is 50.
+ Labels []configv1alpha1.KubeStateMetricsLabelName `json:"labels,omitempty"`
+}
+
+// KubeStateMetricsResourceLabelsApplyConfiguration constructs a declarative configuration of the KubeStateMetricsResourceLabels type for use with
+// apply.
+func KubeStateMetricsResourceLabels() *KubeStateMetricsResourceLabelsApplyConfiguration {
+ return &KubeStateMetricsResourceLabelsApplyConfiguration{}
+}
+
+// WithResource sets the Resource field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Resource field is set to the value of the last call.
+func (b *KubeStateMetricsResourceLabelsApplyConfiguration) WithResource(value configv1alpha1.KubeStateMetricsResourceName) *KubeStateMetricsResourceLabelsApplyConfiguration {
+ b.Resource = &value
+ return b
+}
+
+// WithLabels adds the given value to the Labels field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the Labels field.
+func (b *KubeStateMetricsResourceLabelsApplyConfiguration) WithLabels(values ...configv1alpha1.KubeStateMetricsLabelName) *KubeStateMetricsResourceLabelsApplyConfiguration {
+ for i := range values {
+ b.Labels = append(b.Labels, values[i])
+ }
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/label.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/label.go
new file mode 100644
index 0000000000..d1710cc9ab
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/label.go
@@ -0,0 +1,39 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+// LabelApplyConfiguration represents a declarative configuration of the Label type for use
+// with apply.
+//
+// Label represents a key/value pair for external labels.
+type LabelApplyConfiguration struct {
+ // key is the name of the label.
+ // Prometheus supports UTF-8 label names, so any valid UTF-8 string is allowed.
+ // Must be between 1 and 128 characters in length.
+ Key *string `json:"key,omitempty"`
+ // value is the value of the label.
+ // Must be between 1 and 128 characters in length.
+ Value *string `json:"value,omitempty"`
+}
+
+// LabelApplyConfiguration constructs a declarative configuration of the Label type for use with
+// apply.
+func Label() *LabelApplyConfiguration {
+ return &LabelApplyConfiguration{}
+}
+
+// WithKey sets the Key field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Key field is set to the value of the last call.
+func (b *LabelApplyConfiguration) WithKey(value string) *LabelApplyConfiguration {
+ b.Key = &value
+ return b
+}
+
+// WithValue sets the Value field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Value field is set to the value of the last call.
+func (b *LabelApplyConfiguration) WithValue(value string) *LabelApplyConfiguration {
+ b.Value = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/labelmapactionconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/labelmapactionconfig.go
new file mode 100644
index 0000000000..a16bd78779
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/labelmapactionconfig.go
@@ -0,0 +1,30 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+// LabelMapActionConfigApplyConfiguration represents a declarative configuration of the LabelMapActionConfig type for use
+// with apply.
+//
+// LabelMapActionConfig configures the LabelMap action.
+// Regex is matched against all source label names (not just source_labels). Matching label values are copied to new label names given by replacement, with match group references (${1}, ${2}, ...) substituted.
+type LabelMapActionConfigApplyConfiguration struct {
+ // replacement is the template for new label names; match group references (${1}, ${2}, ...) are substituted from the matched label name.
+ // Required when using the LabelMap action so the intended behavior is explicit and the platform does not need to apply defaults.
+ // Use "$1" for the first capture group, "$2" for the second, etc.
+ // Must be between 1 and 255 characters in length. Empty string is invalid as it would produce invalid label names.
+ Replacement *string `json:"replacement,omitempty"`
+}
+
+// LabelMapActionConfigApplyConfiguration constructs a declarative configuration of the LabelMapActionConfig type for use with
+// apply.
+func LabelMapActionConfig() *LabelMapActionConfigApplyConfiguration {
+ return &LabelMapActionConfigApplyConfiguration{}
+}
+
+// WithReplacement sets the Replacement field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Replacement field is set to the value of the last call.
+func (b *LabelMapActionConfigApplyConfiguration) WithReplacement(value string) *LabelMapActionConfigApplyConfiguration {
+ b.Replacement = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/lowercaseactionconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/lowercaseactionconfig.go
new file mode 100644
index 0000000000..17fa48139a
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/lowercaseactionconfig.go
@@ -0,0 +1,29 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+// LowercaseActionConfigApplyConfiguration represents a declarative configuration of the LowercaseActionConfig type for use
+// with apply.
+//
+// LowercaseActionConfig configures the Lowercase action.
+// Maps the concatenated source_labels to their lower case and writes to target_label.
+// Requires Prometheus >= v2.36.0.
+type LowercaseActionConfigApplyConfiguration struct {
+ // targetLabel is the label name where the lower-cased value is written.
+ // Must be between 1 and 128 characters in length.
+ TargetLabel *string `json:"targetLabel,omitempty"`
+}
+
+// LowercaseActionConfigApplyConfiguration constructs a declarative configuration of the LowercaseActionConfig type for use with
+// apply.
+func LowercaseActionConfig() *LowercaseActionConfigApplyConfiguration {
+ return &LowercaseActionConfigApplyConfiguration{}
+}
+
+// WithTargetLabel sets the TargetLabel field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the TargetLabel field is set to the value of the last call.
+func (b *LowercaseActionConfigApplyConfiguration) WithTargetLabel(value string) *LowercaseActionConfigApplyConfiguration {
+ b.TargetLabel = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/metadataconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/metadataconfig.go
new file mode 100644
index 0000000000..f8e1627816
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/metadataconfig.go
@@ -0,0 +1,42 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ configv1alpha1 "github.com/openshift/api/config/v1alpha1"
+)
+
+// MetadataConfigApplyConfiguration represents a declarative configuration of the MetadataConfig type for use
+// with apply.
+//
+// MetadataConfig defines whether and how to send series metadata to remote write storage.
+type MetadataConfigApplyConfiguration struct {
+ // sendPolicy specifies whether to send metadata and how it is configured.
+ // Default: send metadata using platform-chosen defaults (e.g. send interval 30 seconds).
+ // Custom: send metadata using the settings in the custom field.
+ SendPolicy *configv1alpha1.MetadataConfigSendPolicy `json:"sendPolicy,omitempty"`
+ // custom defines custom metadata send settings. Required when sendPolicy is Custom (must have at least one property), and forbidden when sendPolicy is Default.
+ Custom *MetadataConfigCustomApplyConfiguration `json:"custom,omitempty"`
+}
+
+// MetadataConfigApplyConfiguration constructs a declarative configuration of the MetadataConfig type for use with
+// apply.
+func MetadataConfig() *MetadataConfigApplyConfiguration {
+ return &MetadataConfigApplyConfiguration{}
+}
+
+// WithSendPolicy sets the SendPolicy field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the SendPolicy field is set to the value of the last call.
+func (b *MetadataConfigApplyConfiguration) WithSendPolicy(value configv1alpha1.MetadataConfigSendPolicy) *MetadataConfigApplyConfiguration {
+ b.SendPolicy = &value
+ return b
+}
+
+// WithCustom sets the Custom field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Custom field is set to the value of the last call.
+func (b *MetadataConfigApplyConfiguration) WithCustom(value *MetadataConfigCustomApplyConfiguration) *MetadataConfigApplyConfiguration {
+ b.Custom = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/metadataconfigcustom.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/metadataconfigcustom.go
new file mode 100644
index 0000000000..3f5e050697
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/metadataconfigcustom.go
@@ -0,0 +1,29 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+// MetadataConfigCustomApplyConfiguration represents a declarative configuration of the MetadataConfigCustom type for use
+// with apply.
+//
+// MetadataConfigCustom defines custom settings for sending series metadata when sendPolicy is Custom.
+// At least one property must be set when sendPolicy is Custom (e.g. sendIntervalSeconds).
+type MetadataConfigCustomApplyConfiguration struct {
+ // sendIntervalSeconds is the interval in seconds at which metadata is sent.
+ // When omitted, the platform chooses a reasonable default (e.g. 30 seconds).
+ // Minimum value is 1 second. Maximum value is 86400 seconds (24 hours).
+ SendIntervalSeconds *int32 `json:"sendIntervalSeconds,omitempty"`
+}
+
+// MetadataConfigCustomApplyConfiguration constructs a declarative configuration of the MetadataConfigCustom type for use with
+// apply.
+func MetadataConfigCustom() *MetadataConfigCustomApplyConfiguration {
+ return &MetadataConfigCustomApplyConfiguration{}
+}
+
+// WithSendIntervalSeconds sets the SendIntervalSeconds field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the SendIntervalSeconds field is set to the value of the last call.
+func (b *MetadataConfigCustomApplyConfiguration) WithSendIntervalSeconds(value int32) *MetadataConfigCustomApplyConfiguration {
+ b.SendIntervalSeconds = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/metricsserverconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/metricsserverconfig.go
index ea4d945563..bc77df9d2f 100644
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/metricsserverconfig.go
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/metricsserverconfig.go
@@ -58,7 +58,7 @@ type MetricsServerConfigApplyConfiguration struct {
// - name: memory
// request: 40Mi
// limit: null
- // Maximum length for this list is 10.
+ // Maximum length for this list is 5.
// Minimum length for this list is 1.
// Each resource name must be unique within this list.
Resources []ContainerResourceApplyConfiguration `json:"resources,omitempty"`
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/monitoringpluginconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/monitoringpluginconfig.go
new file mode 100644
index 0000000000..6f10b30e5d
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/monitoringpluginconfig.go
@@ -0,0 +1,112 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ v1 "k8s.io/api/core/v1"
+)
+
+// MonitoringPluginConfigApplyConfiguration represents a declarative configuration of the MonitoringPluginConfig type for use
+// with apply.
+//
+// MonitoringPluginConfig provides configuration options for the monitoring plugin
+// that runs as a dynamic plugin of the OpenShift web console.
+// The monitoring plugin provides the monitoring UI in the OpenShift web console
+// for visualizing metrics, alerts, and dashboards.
+// At least one field must be specified; an empty monitoringPluginConfig object is not allowed.
+type MonitoringPluginConfigApplyConfiguration struct {
+ // nodeSelector defines the nodes on which the Pods are scheduled.
+ // nodeSelector is optional.
+ //
+ // When omitted, this means the user has no opinion and the platform is left
+ // to choose reasonable defaults. These defaults are subject to change over time.
+ // The current default value is `kubernetes.io/os: linux`.
+ // When specified, nodeSelector must contain at least 1 entry and must not contain more than 10 entries.
+ NodeSelector map[string]string `json:"nodeSelector,omitempty"`
+ // resources defines the compute resource requests and limits for the monitoring-plugin container.
+ // This includes CPU, memory and HugePages constraints to help control scheduling and resource usage.
+ // When not specified, defaults are used by the platform. Requests cannot exceed limits.
+ // This field is optional.
+ // More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/
+ // This is a simplified API that maps to Kubernetes ResourceRequirements.
+ // The current default values are:
+ // resources:
+ // - name: cpu
+ // request: 10m
+ // - name: memory
+ // request: 50Mi
+ //
+ // When specified, resources must contain at least 1 entry and must not exceed 5 entries.
+ Resources []ContainerResourceApplyConfiguration `json:"resources,omitempty"`
+ // tolerations defines the tolerations required for the monitoring-plugin Pods.
+ // This field is optional.
+ //
+ // When omitted, the monitoring-plugin Pods will not have any tolerations, which
+ // means they will only be scheduled on nodes with no taints.
+ // When specified, tolerations must contain at least 1 entry and must not contain more than 10 entries.
+ Tolerations []v1.Toleration `json:"tolerations,omitempty"`
+ // topologySpreadConstraints defines rules for how monitoring-plugin Pods should be distributed
+ // across topology domains such as zones, nodes, or other user-defined labels.
+ // topologySpreadConstraints is optional.
+ // This helps improve high availability and resource efficiency by avoiding placing
+ // too many replicas in the same failure domain.
+ //
+ // When omitted, this means no opinion and the platform is left to choose a default, which is subject to change over time.
+ // This field maps directly to the `topologySpreadConstraints` field in the Pod spec.
+ // Default is empty list.
+ // When specified, this list must contain at least 1 entry and must not exceed 10 entries.
+ TopologySpreadConstraints []v1.TopologySpreadConstraint `json:"topologySpreadConstraints,omitempty"`
+}
+
+// MonitoringPluginConfigApplyConfiguration constructs a declarative configuration of the MonitoringPluginConfig type for use with
+// apply.
+func MonitoringPluginConfig() *MonitoringPluginConfigApplyConfiguration {
+ return &MonitoringPluginConfigApplyConfiguration{}
+}
+
+// WithNodeSelector puts the entries into the NodeSelector field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, the entries provided by each call will be put on the NodeSelector field,
+// overwriting an existing map entries in NodeSelector field with the same key.
+func (b *MonitoringPluginConfigApplyConfiguration) WithNodeSelector(entries map[string]string) *MonitoringPluginConfigApplyConfiguration {
+ if b.NodeSelector == nil && len(entries) > 0 {
+ b.NodeSelector = make(map[string]string, len(entries))
+ }
+ for k, v := range entries {
+ b.NodeSelector[k] = v
+ }
+ return b
+}
+
+// WithResources adds the given value to the Resources field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the Resources field.
+func (b *MonitoringPluginConfigApplyConfiguration) WithResources(values ...*ContainerResourceApplyConfiguration) *MonitoringPluginConfigApplyConfiguration {
+ for i := range values {
+ if values[i] == nil {
+ panic("nil value passed to WithResources")
+ }
+ b.Resources = append(b.Resources, *values[i])
+ }
+ return b
+}
+
+// WithTolerations adds the given value to the Tolerations field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the Tolerations field.
+func (b *MonitoringPluginConfigApplyConfiguration) WithTolerations(values ...v1.Toleration) *MonitoringPluginConfigApplyConfiguration {
+ for i := range values {
+ b.Tolerations = append(b.Tolerations, values[i])
+ }
+ return b
+}
+
+// WithTopologySpreadConstraints adds the given value to the TopologySpreadConstraints field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the TopologySpreadConstraints field.
+func (b *MonitoringPluginConfigApplyConfiguration) WithTopologySpreadConstraints(values ...v1.TopologySpreadConstraint) *MonitoringPluginConfigApplyConfiguration {
+ for i := range values {
+ b.TopologySpreadConstraints = append(b.TopologySpreadConstraints, values[i])
+ }
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorbuddyinfoconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorbuddyinfoconfig.go
new file mode 100644
index 0000000000..ba6cedbf2a
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorbuddyinfoconfig.go
@@ -0,0 +1,37 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ configv1alpha1 "github.com/openshift/api/config/v1alpha1"
+)
+
+// NodeExporterCollectorBuddyInfoConfigApplyConfiguration represents a declarative configuration of the NodeExporterCollectorBuddyInfoConfig type for use
+// with apply.
+//
+// NodeExporterCollectorBuddyInfoConfig provides configuration for the buddyinfo collector
+// of the node-exporter agent. The buddyinfo collector collects statistics about memory fragmentation
+// from the node_buddyinfo_blocks metric using data from /proc/buddyinfo.
+// It is disabled by default.
+type NodeExporterCollectorBuddyInfoConfigApplyConfiguration struct {
+ // collectionPolicy declares whether the buddyinfo collector collects metrics.
+ // This field is required.
+ // Valid values are "Collect" and "DoNotCollect".
+ // When set to "Collect", the buddyinfo collector is active and memory fragmentation statistics are collected.
+ // When set to "DoNotCollect", the buddyinfo collector is inactive.
+ CollectionPolicy *configv1alpha1.NodeExporterCollectorCollectionPolicy `json:"collectionPolicy,omitempty"`
+}
+
+// NodeExporterCollectorBuddyInfoConfigApplyConfiguration constructs a declarative configuration of the NodeExporterCollectorBuddyInfoConfig type for use with
+// apply.
+func NodeExporterCollectorBuddyInfoConfig() *NodeExporterCollectorBuddyInfoConfigApplyConfiguration {
+ return &NodeExporterCollectorBuddyInfoConfigApplyConfiguration{}
+}
+
+// WithCollectionPolicy sets the CollectionPolicy field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the CollectionPolicy field is set to the value of the last call.
+func (b *NodeExporterCollectorBuddyInfoConfigApplyConfiguration) WithCollectionPolicy(value configv1alpha1.NodeExporterCollectorCollectionPolicy) *NodeExporterCollectorBuddyInfoConfigApplyConfiguration {
+ b.CollectionPolicy = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorconfig.go
new file mode 100644
index 0000000000..7f74fe4e81
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorconfig.go
@@ -0,0 +1,227 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+// NodeExporterCollectorConfigApplyConfiguration represents a declarative configuration of the NodeExporterCollectorConfig type for use
+// with apply.
+//
+// NodeExporterCollectorConfig defines settings for individual collectors
+// of the node-exporter agent. Each collector can be individually set to collect or not collect metrics.
+// At least one collector must be specified.
+type NodeExporterCollectorConfigApplyConfiguration struct {
+ // cpuFreq configures the cpufreq collector, which collects CPU frequency statistics.
+ // cpuFreq is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is disabled.
+ // Consider enabling when you need to observe CPU frequency scaling; expect higher CPU usage on
+ // many-core nodes when collectionPolicy is Collect.
+ CpuFreq *NodeExporterCollectorCpufreqConfigApplyConfiguration `json:"cpuFreq,omitempty"`
+ // tcpStat configures the tcpstat collector, which collects TCP connection statistics.
+ // tcpStat is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is disabled.
+ // Enable when debugging TCP connection behavior or capacity at the node level.
+ TcpStat *NodeExporterCollectorTcpStatConfigApplyConfiguration `json:"tcpStat,omitempty"`
+ // ethtool configures the ethtool collector, which collects ethernet device statistics.
+ // ethtool is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is disabled.
+ // Enable when you need NIC driver-level ethtool metrics beyond generic netdev counters.
+ Ethtool *NodeExporterCollectorEthtoolConfigApplyConfiguration `json:"ethtool,omitempty"`
+ // netDev configures the netdev collector, which collects network device statistics.
+ // netDev is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is enabled.
+ // Turn off if you must reduce per-interface metric cardinality on hosts with many virtual interfaces.
+ NetDev *NodeExporterCollectorNetDevConfigApplyConfiguration `json:"netDev,omitempty"`
+ // netClass configures the netclass collector, which collects information about network devices.
+ // netClass is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is enabled with netlink mode active.
+ // Use statsGatherer when sysfs vs netlink implementation matters or when matching node_exporter tuning.
+ NetClass *NodeExporterCollectorNetClassConfigApplyConfiguration `json:"netClass,omitempty"`
+ // buddyInfo configures the buddyinfo collector, which collects statistics about memory
+ // fragmentation from the node_buddyinfo_blocks metric. This metric collects data from /proc/buddyinfo.
+ // buddyInfo is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is disabled.
+ // Enable when investigating kernel memory fragmentation; typically for advanced troubleshooting only.
+ BuddyInfo *NodeExporterCollectorBuddyInfoConfigApplyConfiguration `json:"buddyInfo,omitempty"`
+ // mountStats configures the mountstats collector, which collects statistics about NFS volume
+ // I/O activities.
+ // mountStats is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is disabled.
+ // Enabling this collector may produce metrics with high cardinality. If you enable this
+ // collector, closely monitor the prometheus-k8s deployment for excessive memory usage.
+ // Enable when you care about per-mount NFS client statistics.
+ MountStats *NodeExporterCollectorMountStatsConfigApplyConfiguration `json:"mountStats,omitempty"`
+ // ksmd configures the ksmd collector, which collects statistics from the kernel same-page
+ // merger daemon.
+ // ksmd is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is disabled.
+ // Enable on nodes where KSM is in use and you want visibility into merging activity.
+ Ksmd *NodeExporterCollectorKSMDConfigApplyConfiguration `json:"ksmd,omitempty"`
+ // processes configures the processes collector, which collects statistics from processes and
+ // threads running in the system.
+ // processes is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is disabled.
+ // Enable for process/thread-level insight; can be expensive on busy nodes.
+ Processes *NodeExporterCollectorProcessesConfigApplyConfiguration `json:"processes,omitempty"`
+ // systemd configures the systemd collector, which collects statistics on the systemd daemon
+ // and its managed services.
+ // systemd is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is disabled.
+ // Enabling this collector with a long list of selected units may produce metrics with high
+ // cardinality. If you enable this collector, closely monitor the prometheus-k8s deployment
+ // for excessive memory usage.
+ // Enable when you need metrics for specific units; scope units carefully.
+ Systemd *NodeExporterCollectorSystemdConfigApplyConfiguration `json:"systemd,omitempty"`
+ // softirqs configures the softirqs collector, which exposes detailed softirq statistics
+ // from /proc/softirqs.
+ // softirqs is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is disabled.
+ // Enable when you need visibility into kernel softirq processing across CPUs.
+ Softirqs *NodeExporterCollectorSoftirqsConfigApplyConfiguration `json:"softirqs,omitempty"`
+ // deviceMapperMultipath configures the dmmultipath collector, which collects statistics
+ // about DM-Multipath devices.
+ // deviceMapperMultipath is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is enabled.
+ DeviceMapperMultipath *NodeExporterCollectorDeviceMapperMultipathConfigApplyConfiguration `json:"deviceMapperMultipath,omitempty"`
+ // zoneinfo configures the zoneinfo collector, which exposes per-zone memory page counts,
+ // watermarks, and protection thresholds from /proc/zoneinfo.
+ // zoneinfo is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is to not collect zoneinfo metrics.
+ // Enable when you need visibility into kernel memory zone allocation and pressure.
+ Zoneinfo *NodeExporterCollectorZoneinfoConfigApplyConfiguration `json:"zoneinfo,omitempty"`
+ // nvmExpressSubsystem configures the nvmesubsystem collector, which
+ // collects statistics about NVM Express (NVMe) subsystem devices.
+ // nvmExpressSubsystem is optional.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is enabled.
+ NVMExpressSubsystem *NodeExporterCollectorNVMExpressSubsystemConfigApplyConfiguration `json:"nvmExpressSubsystem,omitempty"`
+}
+
+// NodeExporterCollectorConfigApplyConfiguration constructs a declarative configuration of the NodeExporterCollectorConfig type for use with
+// apply.
+func NodeExporterCollectorConfig() *NodeExporterCollectorConfigApplyConfiguration {
+ return &NodeExporterCollectorConfigApplyConfiguration{}
+}
+
+// WithCpuFreq sets the CpuFreq field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the CpuFreq field is set to the value of the last call.
+func (b *NodeExporterCollectorConfigApplyConfiguration) WithCpuFreq(value *NodeExporterCollectorCpufreqConfigApplyConfiguration) *NodeExporterCollectorConfigApplyConfiguration {
+ b.CpuFreq = value
+ return b
+}
+
+// WithTcpStat sets the TcpStat field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the TcpStat field is set to the value of the last call.
+func (b *NodeExporterCollectorConfigApplyConfiguration) WithTcpStat(value *NodeExporterCollectorTcpStatConfigApplyConfiguration) *NodeExporterCollectorConfigApplyConfiguration {
+ b.TcpStat = value
+ return b
+}
+
+// WithEthtool sets the Ethtool field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Ethtool field is set to the value of the last call.
+func (b *NodeExporterCollectorConfigApplyConfiguration) WithEthtool(value *NodeExporterCollectorEthtoolConfigApplyConfiguration) *NodeExporterCollectorConfigApplyConfiguration {
+ b.Ethtool = value
+ return b
+}
+
+// WithNetDev sets the NetDev field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the NetDev field is set to the value of the last call.
+func (b *NodeExporterCollectorConfigApplyConfiguration) WithNetDev(value *NodeExporterCollectorNetDevConfigApplyConfiguration) *NodeExporterCollectorConfigApplyConfiguration {
+ b.NetDev = value
+ return b
+}
+
+// WithNetClass sets the NetClass field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the NetClass field is set to the value of the last call.
+func (b *NodeExporterCollectorConfigApplyConfiguration) WithNetClass(value *NodeExporterCollectorNetClassConfigApplyConfiguration) *NodeExporterCollectorConfigApplyConfiguration {
+ b.NetClass = value
+ return b
+}
+
+// WithBuddyInfo sets the BuddyInfo field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the BuddyInfo field is set to the value of the last call.
+func (b *NodeExporterCollectorConfigApplyConfiguration) WithBuddyInfo(value *NodeExporterCollectorBuddyInfoConfigApplyConfiguration) *NodeExporterCollectorConfigApplyConfiguration {
+ b.BuddyInfo = value
+ return b
+}
+
+// WithMountStats sets the MountStats field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the MountStats field is set to the value of the last call.
+func (b *NodeExporterCollectorConfigApplyConfiguration) WithMountStats(value *NodeExporterCollectorMountStatsConfigApplyConfiguration) *NodeExporterCollectorConfigApplyConfiguration {
+ b.MountStats = value
+ return b
+}
+
+// WithKsmd sets the Ksmd field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Ksmd field is set to the value of the last call.
+func (b *NodeExporterCollectorConfigApplyConfiguration) WithKsmd(value *NodeExporterCollectorKSMDConfigApplyConfiguration) *NodeExporterCollectorConfigApplyConfiguration {
+ b.Ksmd = value
+ return b
+}
+
+// WithProcesses sets the Processes field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Processes field is set to the value of the last call.
+func (b *NodeExporterCollectorConfigApplyConfiguration) WithProcesses(value *NodeExporterCollectorProcessesConfigApplyConfiguration) *NodeExporterCollectorConfigApplyConfiguration {
+ b.Processes = value
+ return b
+}
+
+// WithSystemd sets the Systemd field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Systemd field is set to the value of the last call.
+func (b *NodeExporterCollectorConfigApplyConfiguration) WithSystemd(value *NodeExporterCollectorSystemdConfigApplyConfiguration) *NodeExporterCollectorConfigApplyConfiguration {
+ b.Systemd = value
+ return b
+}
+
+// WithSoftirqs sets the Softirqs field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Softirqs field is set to the value of the last call.
+func (b *NodeExporterCollectorConfigApplyConfiguration) WithSoftirqs(value *NodeExporterCollectorSoftirqsConfigApplyConfiguration) *NodeExporterCollectorConfigApplyConfiguration {
+ b.Softirqs = value
+ return b
+}
+
+// WithDeviceMapperMultipath sets the DeviceMapperMultipath field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the DeviceMapperMultipath field is set to the value of the last call.
+func (b *NodeExporterCollectorConfigApplyConfiguration) WithDeviceMapperMultipath(value *NodeExporterCollectorDeviceMapperMultipathConfigApplyConfiguration) *NodeExporterCollectorConfigApplyConfiguration {
+ b.DeviceMapperMultipath = value
+ return b
+}
+
+// WithZoneinfo sets the Zoneinfo field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Zoneinfo field is set to the value of the last call.
+func (b *NodeExporterCollectorConfigApplyConfiguration) WithZoneinfo(value *NodeExporterCollectorZoneinfoConfigApplyConfiguration) *NodeExporterCollectorConfigApplyConfiguration {
+ b.Zoneinfo = value
+ return b
+}
+
+// WithNVMExpressSubsystem sets the NVMExpressSubsystem field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the NVMExpressSubsystem field is set to the value of the last call.
+func (b *NodeExporterCollectorConfigApplyConfiguration) WithNVMExpressSubsystem(value *NodeExporterCollectorNVMExpressSubsystemConfigApplyConfiguration) *NodeExporterCollectorConfigApplyConfiguration {
+ b.NVMExpressSubsystem = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorcpufreqconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorcpufreqconfig.go
new file mode 100644
index 0000000000..65fe3f11fe
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorcpufreqconfig.go
@@ -0,0 +1,36 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ configv1alpha1 "github.com/openshift/api/config/v1alpha1"
+)
+
+// NodeExporterCollectorCpufreqConfigApplyConfiguration represents a declarative configuration of the NodeExporterCollectorCpufreqConfig type for use
+// with apply.
+//
+// NodeExporterCollectorCpufreqConfig provides configuration for the cpufreq collector
+// of the node-exporter agent. The cpufreq collector collects CPU frequency statistics.
+// It is disabled by default.
+type NodeExporterCollectorCpufreqConfigApplyConfiguration struct {
+ // collectionPolicy declares whether the cpufreq collector collects metrics.
+ // This field is required.
+ // Valid values are "Collect" and "DoNotCollect".
+ // When set to "Collect", the cpufreq collector is active and CPU frequency statistics are collected.
+ // When set to "DoNotCollect", the cpufreq collector is inactive.
+ CollectionPolicy *configv1alpha1.NodeExporterCollectorCollectionPolicy `json:"collectionPolicy,omitempty"`
+}
+
+// NodeExporterCollectorCpufreqConfigApplyConfiguration constructs a declarative configuration of the NodeExporterCollectorCpufreqConfig type for use with
+// apply.
+func NodeExporterCollectorCpufreqConfig() *NodeExporterCollectorCpufreqConfigApplyConfiguration {
+ return &NodeExporterCollectorCpufreqConfigApplyConfiguration{}
+}
+
+// WithCollectionPolicy sets the CollectionPolicy field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the CollectionPolicy field is set to the value of the last call.
+func (b *NodeExporterCollectorCpufreqConfigApplyConfiguration) WithCollectionPolicy(value configv1alpha1.NodeExporterCollectorCollectionPolicy) *NodeExporterCollectorCpufreqConfigApplyConfiguration {
+ b.CollectionPolicy = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectordevicemappermultipathconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectordevicemappermultipathconfig.go
new file mode 100644
index 0000000000..2ea3f2c527
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectordevicemappermultipathconfig.go
@@ -0,0 +1,37 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ configv1alpha1 "github.com/openshift/api/config/v1alpha1"
+)
+
+// NodeExporterCollectorDeviceMapperMultipathConfigApplyConfiguration represents a declarative configuration of the NodeExporterCollectorDeviceMapperMultipathConfig type for use
+// with apply.
+//
+// NodeExporterCollectorDeviceMapperMultipathConfig provides configuration for the dmmultipath collector
+// of the node-exporter agent. The dmmultipath collector collects statistics about
+// DM-Multipath devices.
+// It is enabled by default.
+type NodeExporterCollectorDeviceMapperMultipathConfigApplyConfiguration struct {
+ // collectionPolicy declares whether the dmmultipath collector collects metrics.
+ // This field is required.
+ // Valid values are "Collect" and "DoNotCollect".
+ // When set to "Collect", the dmmultipath collector is active and DM-Multipath device statistics are collected.
+ // When set to "DoNotCollect", the dmmultipath collector is inactive and the corresponding metrics become unavailable.
+ CollectionPolicy *configv1alpha1.NodeExporterCollectorCollectionPolicy `json:"collectionPolicy,omitempty"`
+}
+
+// NodeExporterCollectorDeviceMapperMultipathConfigApplyConfiguration constructs a declarative configuration of the NodeExporterCollectorDeviceMapperMultipathConfig type for use with
+// apply.
+func NodeExporterCollectorDeviceMapperMultipathConfig() *NodeExporterCollectorDeviceMapperMultipathConfigApplyConfiguration {
+ return &NodeExporterCollectorDeviceMapperMultipathConfigApplyConfiguration{}
+}
+
+// WithCollectionPolicy sets the CollectionPolicy field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the CollectionPolicy field is set to the value of the last call.
+func (b *NodeExporterCollectorDeviceMapperMultipathConfigApplyConfiguration) WithCollectionPolicy(value configv1alpha1.NodeExporterCollectorCollectionPolicy) *NodeExporterCollectorDeviceMapperMultipathConfigApplyConfiguration {
+ b.CollectionPolicy = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorethtoolconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorethtoolconfig.go
new file mode 100644
index 0000000000..396477c1f0
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorethtoolconfig.go
@@ -0,0 +1,36 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ configv1alpha1 "github.com/openshift/api/config/v1alpha1"
+)
+
+// NodeExporterCollectorEthtoolConfigApplyConfiguration represents a declarative configuration of the NodeExporterCollectorEthtoolConfig type for use
+// with apply.
+//
+// NodeExporterCollectorEthtoolConfig provides configuration for the ethtool collector
+// of the node-exporter agent. The ethtool collector collects ethernet device statistics.
+// It is disabled by default.
+type NodeExporterCollectorEthtoolConfigApplyConfiguration struct {
+ // collectionPolicy declares whether the ethtool collector collects metrics.
+ // This field is required.
+ // Valid values are "Collect" and "DoNotCollect".
+ // When set to "Collect", the ethtool collector is active and ethernet device statistics are collected.
+ // When set to "DoNotCollect", the ethtool collector is inactive.
+ CollectionPolicy *configv1alpha1.NodeExporterCollectorCollectionPolicy `json:"collectionPolicy,omitempty"`
+}
+
+// NodeExporterCollectorEthtoolConfigApplyConfiguration constructs a declarative configuration of the NodeExporterCollectorEthtoolConfig type for use with
+// apply.
+func NodeExporterCollectorEthtoolConfig() *NodeExporterCollectorEthtoolConfigApplyConfiguration {
+ return &NodeExporterCollectorEthtoolConfigApplyConfiguration{}
+}
+
+// WithCollectionPolicy sets the CollectionPolicy field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the CollectionPolicy field is set to the value of the last call.
+func (b *NodeExporterCollectorEthtoolConfigApplyConfiguration) WithCollectionPolicy(value configv1alpha1.NodeExporterCollectorCollectionPolicy) *NodeExporterCollectorEthtoolConfigApplyConfiguration {
+ b.CollectionPolicy = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorksmdconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorksmdconfig.go
new file mode 100644
index 0000000000..fc0ac015a1
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorksmdconfig.go
@@ -0,0 +1,37 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ configv1alpha1 "github.com/openshift/api/config/v1alpha1"
+)
+
+// NodeExporterCollectorKSMDConfigApplyConfiguration represents a declarative configuration of the NodeExporterCollectorKSMDConfig type for use
+// with apply.
+//
+// NodeExporterCollectorKSMDConfig provides configuration for the ksmd collector
+// of the node-exporter agent. The ksmd collector collects statistics from the kernel
+// same-page merger daemon.
+// It is disabled by default.
+type NodeExporterCollectorKSMDConfigApplyConfiguration struct {
+ // collectionPolicy declares whether the ksmd collector collects metrics.
+ // This field is required.
+ // Valid values are "Collect" and "DoNotCollect".
+ // When set to "Collect", the ksmd collector is active and kernel same-page merger statistics are collected.
+ // When set to "DoNotCollect", the ksmd collector is inactive.
+ CollectionPolicy *configv1alpha1.NodeExporterCollectorCollectionPolicy `json:"collectionPolicy,omitempty"`
+}
+
+// NodeExporterCollectorKSMDConfigApplyConfiguration constructs a declarative configuration of the NodeExporterCollectorKSMDConfig type for use with
+// apply.
+func NodeExporterCollectorKSMDConfig() *NodeExporterCollectorKSMDConfigApplyConfiguration {
+ return &NodeExporterCollectorKSMDConfigApplyConfiguration{}
+}
+
+// WithCollectionPolicy sets the CollectionPolicy field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the CollectionPolicy field is set to the value of the last call.
+func (b *NodeExporterCollectorKSMDConfigApplyConfiguration) WithCollectionPolicy(value configv1alpha1.NodeExporterCollectorCollectionPolicy) *NodeExporterCollectorKSMDConfigApplyConfiguration {
+ b.CollectionPolicy = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectormountstatsconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectormountstatsconfig.go
new file mode 100644
index 0000000000..306bb851aa
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectormountstatsconfig.go
@@ -0,0 +1,38 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ configv1alpha1 "github.com/openshift/api/config/v1alpha1"
+)
+
+// NodeExporterCollectorMountStatsConfigApplyConfiguration represents a declarative configuration of the NodeExporterCollectorMountStatsConfig type for use
+// with apply.
+//
+// NodeExporterCollectorMountStatsConfig provides configuration for the mountstats collector
+// of the node-exporter agent. The mountstats collector collects statistics about NFS volume I/O activities.
+// It is disabled by default.
+// Enabling this collector may produce metrics with high cardinality. If you enable this
+// collector, closely monitor the prometheus-k8s deployment for excessive memory usage.
+type NodeExporterCollectorMountStatsConfigApplyConfiguration struct {
+ // collectionPolicy declares whether the mountstats collector collects metrics.
+ // This field is required.
+ // Valid values are "Collect" and "DoNotCollect".
+ // When set to "Collect", the mountstats collector is active and NFS volume I/O statistics are collected.
+ // When set to "DoNotCollect", the mountstats collector is inactive.
+ CollectionPolicy *configv1alpha1.NodeExporterCollectorCollectionPolicy `json:"collectionPolicy,omitempty"`
+}
+
+// NodeExporterCollectorMountStatsConfigApplyConfiguration constructs a declarative configuration of the NodeExporterCollectorMountStatsConfig type for use with
+// apply.
+func NodeExporterCollectorMountStatsConfig() *NodeExporterCollectorMountStatsConfigApplyConfiguration {
+ return &NodeExporterCollectorMountStatsConfigApplyConfiguration{}
+}
+
+// WithCollectionPolicy sets the CollectionPolicy field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the CollectionPolicy field is set to the value of the last call.
+func (b *NodeExporterCollectorMountStatsConfigApplyConfiguration) WithCollectionPolicy(value configv1alpha1.NodeExporterCollectorCollectionPolicy) *NodeExporterCollectorMountStatsConfigApplyConfiguration {
+ b.CollectionPolicy = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectornetclasscollectconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectornetclasscollectconfig.go
new file mode 100644
index 0000000000..321c7c6679
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectornetclasscollectconfig.go
@@ -0,0 +1,36 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ configv1alpha1 "github.com/openshift/api/config/v1alpha1"
+)
+
+// NodeExporterCollectorNetClassCollectConfigApplyConfiguration represents a declarative configuration of the NodeExporterCollectorNetClassCollectConfig type for use
+// with apply.
+//
+// NodeExporterCollectorNetClassCollectConfig holds configuration options for the netclass collector
+// when it is actively collecting metrics. At least one field must be specified.
+type NodeExporterCollectorNetClassCollectConfigApplyConfiguration struct {
+ // statsGatherer selects which implementation the netclass collector uses to gather statistics (sysfs or netlink).
+ // statsGatherer is optional.
+ // Valid values are "Sysfs" and "Netlink".
+ // When set to "Netlink", the netlink implementation is used; when set to "Sysfs", the sysfs implementation is used.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is Netlink.
+ StatsGatherer *configv1alpha1.NodeExporterNetclassStatsGatherer `json:"statsGatherer,omitempty"`
+}
+
+// NodeExporterCollectorNetClassCollectConfigApplyConfiguration constructs a declarative configuration of the NodeExporterCollectorNetClassCollectConfig type for use with
+// apply.
+func NodeExporterCollectorNetClassCollectConfig() *NodeExporterCollectorNetClassCollectConfigApplyConfiguration {
+ return &NodeExporterCollectorNetClassCollectConfigApplyConfiguration{}
+}
+
+// WithStatsGatherer sets the StatsGatherer field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the StatsGatherer field is set to the value of the last call.
+func (b *NodeExporterCollectorNetClassCollectConfigApplyConfiguration) WithStatsGatherer(value configv1alpha1.NodeExporterNetclassStatsGatherer) *NodeExporterCollectorNetClassCollectConfigApplyConfiguration {
+ b.StatsGatherer = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectornetclassconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectornetclassconfig.go
new file mode 100644
index 0000000000..2fe2a6a5ba
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectornetclassconfig.go
@@ -0,0 +1,53 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ configv1alpha1 "github.com/openshift/api/config/v1alpha1"
+)
+
+// NodeExporterCollectorNetClassConfigApplyConfiguration represents a declarative configuration of the NodeExporterCollectorNetClassConfig type for use
+// with apply.
+//
+// NodeExporterCollectorNetClassConfig provides configuration for the netclass collector
+// of the node-exporter agent. The netclass collector collects information about network devices
+// such as network speed, MTU, and carrier status.
+// It is enabled by default.
+// When collectionPolicy is DoNotCollect, the collect field must not be set.
+type NodeExporterCollectorNetClassConfigApplyConfiguration struct {
+ // collectionPolicy declares whether the netclass collector collects metrics.
+ // This field is required.
+ // Valid values are "Collect" and "DoNotCollect".
+ // When set to "Collect", the netclass collector is active and network class information is collected.
+ // When set to "DoNotCollect", the netclass collector is inactive and the corresponding metrics become unavailable.
+ // When set to "DoNotCollect", the collect field must not be set.
+ CollectionPolicy *configv1alpha1.NodeExporterCollectorCollectionPolicy `json:"collectionPolicy,omitempty"`
+ // collect contains configuration options that apply only when the netclass collector is actively collecting metrics
+ // (i.e. when collectionPolicy is Collect).
+ // collect is optional and may be omitted even when collectionPolicy is Collect.
+ // collect may only be set when collectionPolicy is Collect.
+ // When set, at least one field must be specified within collect.
+ Collect *NodeExporterCollectorNetClassCollectConfigApplyConfiguration `json:"collect,omitempty"`
+}
+
+// NodeExporterCollectorNetClassConfigApplyConfiguration constructs a declarative configuration of the NodeExporterCollectorNetClassConfig type for use with
+// apply.
+func NodeExporterCollectorNetClassConfig() *NodeExporterCollectorNetClassConfigApplyConfiguration {
+ return &NodeExporterCollectorNetClassConfigApplyConfiguration{}
+}
+
+// WithCollectionPolicy sets the CollectionPolicy field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the CollectionPolicy field is set to the value of the last call.
+func (b *NodeExporterCollectorNetClassConfigApplyConfiguration) WithCollectionPolicy(value configv1alpha1.NodeExporterCollectorCollectionPolicy) *NodeExporterCollectorNetClassConfigApplyConfiguration {
+ b.CollectionPolicy = &value
+ return b
+}
+
+// WithCollect sets the Collect field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Collect field is set to the value of the last call.
+func (b *NodeExporterCollectorNetClassConfigApplyConfiguration) WithCollect(value *NodeExporterCollectorNetClassCollectConfigApplyConfiguration) *NodeExporterCollectorNetClassConfigApplyConfiguration {
+ b.Collect = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectornetdevconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectornetdevconfig.go
new file mode 100644
index 0000000000..b5bbe4c86e
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectornetdevconfig.go
@@ -0,0 +1,37 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ configv1alpha1 "github.com/openshift/api/config/v1alpha1"
+)
+
+// NodeExporterCollectorNetDevConfigApplyConfiguration represents a declarative configuration of the NodeExporterCollectorNetDevConfig type for use
+// with apply.
+//
+// NodeExporterCollectorNetDevConfig provides configuration for the netdev collector
+// of the node-exporter agent. The netdev collector collects network device statistics
+// such as bytes, packets, errors, and drops per device.
+// It is enabled by default.
+type NodeExporterCollectorNetDevConfigApplyConfiguration struct {
+ // collectionPolicy declares whether the netdev collector collects metrics.
+ // This field is required.
+ // Valid values are "Collect" and "DoNotCollect".
+ // When set to "Collect", the netdev collector is active and network device statistics are collected.
+ // When set to "DoNotCollect", the netdev collector is inactive and the corresponding metrics become unavailable.
+ CollectionPolicy *configv1alpha1.NodeExporterCollectorCollectionPolicy `json:"collectionPolicy,omitempty"`
+}
+
+// NodeExporterCollectorNetDevConfigApplyConfiguration constructs a declarative configuration of the NodeExporterCollectorNetDevConfig type for use with
+// apply.
+func NodeExporterCollectorNetDevConfig() *NodeExporterCollectorNetDevConfigApplyConfiguration {
+ return &NodeExporterCollectorNetDevConfigApplyConfiguration{}
+}
+
+// WithCollectionPolicy sets the CollectionPolicy field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the CollectionPolicy field is set to the value of the last call.
+func (b *NodeExporterCollectorNetDevConfigApplyConfiguration) WithCollectionPolicy(value configv1alpha1.NodeExporterCollectorCollectionPolicy) *NodeExporterCollectorNetDevConfigApplyConfiguration {
+ b.CollectionPolicy = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectornvmexpresssubsystemconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectornvmexpresssubsystemconfig.go
new file mode 100644
index 0000000000..e072e4b091
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectornvmexpresssubsystemconfig.go
@@ -0,0 +1,37 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ configv1alpha1 "github.com/openshift/api/config/v1alpha1"
+)
+
+// NodeExporterCollectorNVMExpressSubsystemConfigApplyConfiguration represents a declarative configuration of the NodeExporterCollectorNVMExpressSubsystemConfig type for use
+// with apply.
+//
+// NodeExporterCollectorNVMExpressSubsystemConfig provides configuration for
+// the nvmesubsystem collector of the node-exporter agent. The nvmesubsystem
+// collector collects statistics about NVM Express (NVMe) subsystem devices.
+// It is enabled by default.
+type NodeExporterCollectorNVMExpressSubsystemConfigApplyConfiguration struct {
+ // collectionPolicy declares whether the nvmesubsystem collector collects metrics.
+ // This field is required.
+ // Valid values are "Collect" and "DoNotCollect".
+ // When set to "Collect", the nvmesubsystem collector is active and NVMe subsystem statistics are collected.
+ // When set to "DoNotCollect", the nvmesubsystem collector is inactive and the corresponding metrics become unavailable.
+ CollectionPolicy *configv1alpha1.NodeExporterCollectorCollectionPolicy `json:"collectionPolicy,omitempty"`
+}
+
+// NodeExporterCollectorNVMExpressSubsystemConfigApplyConfiguration constructs a declarative configuration of the NodeExporterCollectorNVMExpressSubsystemConfig type for use with
+// apply.
+func NodeExporterCollectorNVMExpressSubsystemConfig() *NodeExporterCollectorNVMExpressSubsystemConfigApplyConfiguration {
+ return &NodeExporterCollectorNVMExpressSubsystemConfigApplyConfiguration{}
+}
+
+// WithCollectionPolicy sets the CollectionPolicy field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the CollectionPolicy field is set to the value of the last call.
+func (b *NodeExporterCollectorNVMExpressSubsystemConfigApplyConfiguration) WithCollectionPolicy(value configv1alpha1.NodeExporterCollectorCollectionPolicy) *NodeExporterCollectorNVMExpressSubsystemConfigApplyConfiguration {
+ b.CollectionPolicy = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorprocessesconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorprocessesconfig.go
new file mode 100644
index 0000000000..71cf2fb59c
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorprocessesconfig.go
@@ -0,0 +1,37 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ configv1alpha1 "github.com/openshift/api/config/v1alpha1"
+)
+
+// NodeExporterCollectorProcessesConfigApplyConfiguration represents a declarative configuration of the NodeExporterCollectorProcessesConfig type for use
+// with apply.
+//
+// NodeExporterCollectorProcessesConfig provides configuration for the processes collector
+// of the node-exporter agent. The processes collector collects statistics from processes and threads
+// running in the system.
+// It is disabled by default.
+type NodeExporterCollectorProcessesConfigApplyConfiguration struct {
+ // collectionPolicy declares whether the processes collector collects metrics.
+ // This field is required.
+ // Valid values are "Collect" and "DoNotCollect".
+ // When set to "Collect", the processes collector is active and process/thread statistics are collected.
+ // When set to "DoNotCollect", the processes collector is inactive.
+ CollectionPolicy *configv1alpha1.NodeExporterCollectorCollectionPolicy `json:"collectionPolicy,omitempty"`
+}
+
+// NodeExporterCollectorProcessesConfigApplyConfiguration constructs a declarative configuration of the NodeExporterCollectorProcessesConfig type for use with
+// apply.
+func NodeExporterCollectorProcessesConfig() *NodeExporterCollectorProcessesConfigApplyConfiguration {
+ return &NodeExporterCollectorProcessesConfigApplyConfiguration{}
+}
+
+// WithCollectionPolicy sets the CollectionPolicy field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the CollectionPolicy field is set to the value of the last call.
+func (b *NodeExporterCollectorProcessesConfigApplyConfiguration) WithCollectionPolicy(value configv1alpha1.NodeExporterCollectorCollectionPolicy) *NodeExporterCollectorProcessesConfigApplyConfiguration {
+ b.CollectionPolicy = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorsoftirqsconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorsoftirqsconfig.go
new file mode 100644
index 0000000000..4f9936bc1c
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorsoftirqsconfig.go
@@ -0,0 +1,37 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ configv1alpha1 "github.com/openshift/api/config/v1alpha1"
+)
+
+// NodeExporterCollectorSoftirqsConfigApplyConfiguration represents a declarative configuration of the NodeExporterCollectorSoftirqsConfig type for use
+// with apply.
+//
+// NodeExporterCollectorSoftirqsConfig provides configuration for the softirqs collector
+// of the node-exporter agent. The softirqs collector exposes detailed softirq statistics
+// from /proc/softirqs.
+// It is disabled by default.
+type NodeExporterCollectorSoftirqsConfigApplyConfiguration struct {
+ // collectionPolicy declares whether the softirqs collector collects metrics.
+ // This field is required.
+ // Valid values are "Collect" and "DoNotCollect".
+ // When set to "Collect", the softirqs collector is active and softirq statistics are collected.
+ // When set to "DoNotCollect", the softirqs collector is inactive.
+ CollectionPolicy *configv1alpha1.NodeExporterCollectorCollectionPolicy `json:"collectionPolicy,omitempty"`
+}
+
+// NodeExporterCollectorSoftirqsConfigApplyConfiguration constructs a declarative configuration of the NodeExporterCollectorSoftirqsConfig type for use with
+// apply.
+func NodeExporterCollectorSoftirqsConfig() *NodeExporterCollectorSoftirqsConfigApplyConfiguration {
+ return &NodeExporterCollectorSoftirqsConfigApplyConfiguration{}
+}
+
+// WithCollectionPolicy sets the CollectionPolicy field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the CollectionPolicy field is set to the value of the last call.
+func (b *NodeExporterCollectorSoftirqsConfigApplyConfiguration) WithCollectionPolicy(value configv1alpha1.NodeExporterCollectorCollectionPolicy) *NodeExporterCollectorSoftirqsConfigApplyConfiguration {
+ b.CollectionPolicy = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorsystemdcollectconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorsystemdcollectconfig.go
new file mode 100644
index 0000000000..647f7efc0a
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorsystemdcollectconfig.go
@@ -0,0 +1,40 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ configv1alpha1 "github.com/openshift/api/config/v1alpha1"
+)
+
+// NodeExporterCollectorSystemdCollectConfigApplyConfiguration represents a declarative configuration of the NodeExporterCollectorSystemdCollectConfig type for use
+// with apply.
+//
+// NodeExporterCollectorSystemdCollectConfig holds configuration options for the systemd collector
+// when it is actively collecting metrics. At least one field must be specified.
+type NodeExporterCollectorSystemdCollectConfigApplyConfiguration struct {
+ // units is a list of regular expression patterns that match systemd units to be included
+ // by the systemd collector.
+ // units is optional.
+ // By default, the list is empty, so the collector exposes no metrics for systemd units.
+ // Each entry is a regular expression pattern and must be at least 1 character and at most 1024 characters.
+ // Maximum length for this list is 50.
+ // Minimum length for this list is 1.
+ // Entries in this list must be unique.
+ Units []configv1alpha1.NodeExporterSystemdUnit `json:"units,omitempty"`
+}
+
+// NodeExporterCollectorSystemdCollectConfigApplyConfiguration constructs a declarative configuration of the NodeExporterCollectorSystemdCollectConfig type for use with
+// apply.
+func NodeExporterCollectorSystemdCollectConfig() *NodeExporterCollectorSystemdCollectConfigApplyConfiguration {
+ return &NodeExporterCollectorSystemdCollectConfigApplyConfiguration{}
+}
+
+// WithUnits adds the given value to the Units field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the Units field.
+func (b *NodeExporterCollectorSystemdCollectConfigApplyConfiguration) WithUnits(values ...configv1alpha1.NodeExporterSystemdUnit) *NodeExporterCollectorSystemdCollectConfigApplyConfiguration {
+ for i := range values {
+ b.Units = append(b.Units, values[i])
+ }
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorsystemdconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorsystemdconfig.go
new file mode 100644
index 0000000000..a1422798de
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorsystemdconfig.go
@@ -0,0 +1,55 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ configv1alpha1 "github.com/openshift/api/config/v1alpha1"
+)
+
+// NodeExporterCollectorSystemdConfigApplyConfiguration represents a declarative configuration of the NodeExporterCollectorSystemdConfig type for use
+// with apply.
+//
+// NodeExporterCollectorSystemdConfig provides configuration for the systemd collector
+// of the node-exporter agent. The systemd collector collects statistics on the systemd daemon
+// and its managed services.
+// It is disabled by default.
+// Enabling this collector with a long list of selected units may produce metrics with high
+// cardinality. If you enable this collector, closely monitor the prometheus-k8s deployment
+// for excessive memory usage.
+// When collectionPolicy is DoNotCollect, the collect field must not be set.
+type NodeExporterCollectorSystemdConfigApplyConfiguration struct {
+ // collectionPolicy declares whether the systemd collector collects metrics.
+ // This field is required.
+ // Valid values are "Collect" and "DoNotCollect".
+ // When set to "Collect", the systemd collector is active and systemd unit statistics are collected.
+ // When set to "DoNotCollect", the systemd collector is inactive and the collect field must not be set.
+ CollectionPolicy *configv1alpha1.NodeExporterCollectorCollectionPolicy `json:"collectionPolicy,omitempty"`
+ // collect contains configuration options that apply only when the systemd collector is actively collecting metrics
+ // (i.e. when collectionPolicy is Collect).
+ // collect is optional and may be omitted even when collectionPolicy is Collect.
+ // collect may only be set when collectionPolicy is Collect.
+ // When set, at least one field must be specified within collect.
+ Collect *NodeExporterCollectorSystemdCollectConfigApplyConfiguration `json:"collect,omitempty"`
+}
+
+// NodeExporterCollectorSystemdConfigApplyConfiguration constructs a declarative configuration of the NodeExporterCollectorSystemdConfig type for use with
+// apply.
+func NodeExporterCollectorSystemdConfig() *NodeExporterCollectorSystemdConfigApplyConfiguration {
+ return &NodeExporterCollectorSystemdConfigApplyConfiguration{}
+}
+
+// WithCollectionPolicy sets the CollectionPolicy field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the CollectionPolicy field is set to the value of the last call.
+func (b *NodeExporterCollectorSystemdConfigApplyConfiguration) WithCollectionPolicy(value configv1alpha1.NodeExporterCollectorCollectionPolicy) *NodeExporterCollectorSystemdConfigApplyConfiguration {
+ b.CollectionPolicy = &value
+ return b
+}
+
+// WithCollect sets the Collect field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Collect field is set to the value of the last call.
+func (b *NodeExporterCollectorSystemdConfigApplyConfiguration) WithCollect(value *NodeExporterCollectorSystemdCollectConfigApplyConfiguration) *NodeExporterCollectorSystemdConfigApplyConfiguration {
+ b.Collect = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectortcpstatconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectortcpstatconfig.go
new file mode 100644
index 0000000000..20f77e8808
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectortcpstatconfig.go
@@ -0,0 +1,36 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ configv1alpha1 "github.com/openshift/api/config/v1alpha1"
+)
+
+// NodeExporterCollectorTcpStatConfigApplyConfiguration represents a declarative configuration of the NodeExporterCollectorTcpStatConfig type for use
+// with apply.
+//
+// NodeExporterCollectorTcpStatConfig provides configuration for the tcpstat collector
+// of the node-exporter agent. The tcpstat collector collects TCP connection statistics.
+// It is disabled by default.
+type NodeExporterCollectorTcpStatConfigApplyConfiguration struct {
+ // collectionPolicy declares whether the tcpstat collector collects metrics.
+ // This field is required.
+ // Valid values are "Collect" and "DoNotCollect".
+ // When set to "Collect", the tcpstat collector is active and TCP connection statistics are collected.
+ // When set to "DoNotCollect", the tcpstat collector is inactive.
+ CollectionPolicy *configv1alpha1.NodeExporterCollectorCollectionPolicy `json:"collectionPolicy,omitempty"`
+}
+
+// NodeExporterCollectorTcpStatConfigApplyConfiguration constructs a declarative configuration of the NodeExporterCollectorTcpStatConfig type for use with
+// apply.
+func NodeExporterCollectorTcpStatConfig() *NodeExporterCollectorTcpStatConfigApplyConfiguration {
+ return &NodeExporterCollectorTcpStatConfigApplyConfiguration{}
+}
+
+// WithCollectionPolicy sets the CollectionPolicy field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the CollectionPolicy field is set to the value of the last call.
+func (b *NodeExporterCollectorTcpStatConfigApplyConfiguration) WithCollectionPolicy(value configv1alpha1.NodeExporterCollectorCollectionPolicy) *NodeExporterCollectorTcpStatConfigApplyConfiguration {
+ b.CollectionPolicy = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorzoneinfoconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorzoneinfoconfig.go
new file mode 100644
index 0000000000..cdd1a5748f
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorzoneinfoconfig.go
@@ -0,0 +1,37 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ configv1alpha1 "github.com/openshift/api/config/v1alpha1"
+)
+
+// NodeExporterCollectorZoneinfoConfigApplyConfiguration represents a declarative configuration of the NodeExporterCollectorZoneinfoConfig type for use
+// with apply.
+//
+// NodeExporterCollectorZoneinfoConfig provides configuration for the zoneinfo collector
+// of the node-exporter agent. The zoneinfo collector exposes per-zone memory page counts,
+// watermarks, and protection thresholds from /proc/zoneinfo.
+// By default, the zoneinfo collector does not collect metrics.
+type NodeExporterCollectorZoneinfoConfigApplyConfiguration struct {
+ // collectionPolicy declares whether the zoneinfo collector collects metrics.
+ // This field is required.
+ // Valid values are "Collect" and "DoNotCollect".
+ // When set to "Collect", the zoneinfo collector is active and zone memory statistics are collected.
+ // When set to "DoNotCollect", the zoneinfo collector is inactive.
+ CollectionPolicy *configv1alpha1.NodeExporterCollectorCollectionPolicy `json:"collectionPolicy,omitempty"`
+}
+
+// NodeExporterCollectorZoneinfoConfigApplyConfiguration constructs a declarative configuration of the NodeExporterCollectorZoneinfoConfig type for use with
+// apply.
+func NodeExporterCollectorZoneinfoConfig() *NodeExporterCollectorZoneinfoConfigApplyConfiguration {
+ return &NodeExporterCollectorZoneinfoConfigApplyConfiguration{}
+}
+
+// WithCollectionPolicy sets the CollectionPolicy field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the CollectionPolicy field is set to the value of the last call.
+func (b *NodeExporterCollectorZoneinfoConfigApplyConfiguration) WithCollectionPolicy(value configv1alpha1.NodeExporterCollectorCollectionPolicy) *NodeExporterCollectorZoneinfoConfigApplyConfiguration {
+ b.CollectionPolicy = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexporterconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexporterconfig.go
new file mode 100644
index 0000000000..a4a250fc24
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexporterconfig.go
@@ -0,0 +1,115 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ configv1alpha1 "github.com/openshift/api/config/v1alpha1"
+)
+
+// NodeExporterConfigApplyConfiguration represents a declarative configuration of the NodeExporterConfig type for use
+// with apply.
+//
+// NodeExporterConfig provides configuration options for the node-exporter agent
+// that runs as a DaemonSet in the `openshift-monitoring` namespace. The node-exporter agent collects
+// hardware and OS-level metrics from every node in the cluster, including CPU, memory, disk, and
+// network statistics.
+// At least one field must be specified.
+type NodeExporterConfigApplyConfiguration struct {
+ // resources defines the compute resource requests and limits for the node-exporter container.
+ // This includes CPU, memory and HugePages constraints to help control scheduling and resource usage.
+ // When not specified, defaults are used by the platform. Requests cannot exceed limits.
+ // This field is optional.
+ // More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/
+ // This is a simplified API that maps to Kubernetes ResourceRequirements.
+ // The current default values are:
+ // resources:
+ // - name: cpu
+ // request: 8m
+ // limit: null
+ // - name: memory
+ // request: 32Mi
+ // limit: null
+ // ---
+ // maxItems is set to 5 to stay within the Kubernetes CRD CEL validation cost budget.
+ // See the MaxItems comment near the ContainerResource type definition for details.
+ // Minimum length for this list is 1.
+ // Each resource name must be unique within this list.
+ Resources []ContainerResourceApplyConfiguration `json:"resources,omitempty"`
+ // collectors configures which node-exporter metric collectors are enabled.
+ // collectors is optional.
+ // Each collector can be individually enabled or disabled. Some collectors may have
+ // additional configuration options.
+ //
+ // When omitted, this means no opinion and the platform is left to choose a reasonable
+ // default, which is subject to change over time.
+ Collectors *NodeExporterCollectorConfigApplyConfiguration `json:"collectors,omitempty"`
+ // maxProcs sets the target number of CPUs on which the node-exporter process will run.
+ // maxProcs is optional.
+ // Use this setting to override the default value, which is set either to 4 or to the number
+ // of CPUs on the host, whichever is smaller.
+ // The default value is computed at runtime and set via the GOMAXPROCS environment variable before
+ // node-exporter is launched.
+ // If a kernel deadlock occurs or if performance degrades when reading from sysfs concurrently,
+ // you can change this value to 1, which limits node-exporter to running on one CPU.
+ // For nodes with a high CPU count, setting the limit to a low number saves resources by preventing
+ // Go routines from being scheduled to run on all CPUs. However, I/O performance degrades if the
+ // maxProcs value is set too low and there are many metrics to collect.
+ // The minimum value is 1 and the maximum value is 1024.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default,
+ // which is subject to change over time. The current default is min(4, number of host CPUs).
+ MaxProcs *int32 `json:"maxProcs,omitempty"`
+ // ignoredNetworkDevices is a list of regular expression patterns that match network devices
+ // to be excluded from the relevant collector configuration such as netdev, netclass, and ethtool.
+ // ignoredNetworkDevices is optional.
+ //
+ // When omitted, the Cluster Monitoring Operator uses a predefined list of devices to be excluded
+ // to minimize the impact on memory usage.
+ // When set as an empty list, no devices are excluded.
+ // If you modify this setting, monitor the prometheus-k8s deployment closely for excessive memory usage.
+ // Maximum length for this list is 50.
+ // Each entry must be at least 1 character and at most 1024 characters long.
+ IgnoredNetworkDevices *[]configv1alpha1.NodeExporterIgnoredNetworkDevice `json:"ignoredNetworkDevices,omitempty"`
+}
+
+// NodeExporterConfigApplyConfiguration constructs a declarative configuration of the NodeExporterConfig type for use with
+// apply.
+func NodeExporterConfig() *NodeExporterConfigApplyConfiguration {
+ return &NodeExporterConfigApplyConfiguration{}
+}
+
+// WithResources adds the given value to the Resources field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the Resources field.
+func (b *NodeExporterConfigApplyConfiguration) WithResources(values ...*ContainerResourceApplyConfiguration) *NodeExporterConfigApplyConfiguration {
+ for i := range values {
+ if values[i] == nil {
+ panic("nil value passed to WithResources")
+ }
+ b.Resources = append(b.Resources, *values[i])
+ }
+ return b
+}
+
+// WithCollectors sets the Collectors field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Collectors field is set to the value of the last call.
+func (b *NodeExporterConfigApplyConfiguration) WithCollectors(value *NodeExporterCollectorConfigApplyConfiguration) *NodeExporterConfigApplyConfiguration {
+ b.Collectors = value
+ return b
+}
+
+// WithMaxProcs sets the MaxProcs field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the MaxProcs field is set to the value of the last call.
+func (b *NodeExporterConfigApplyConfiguration) WithMaxProcs(value int32) *NodeExporterConfigApplyConfiguration {
+ b.MaxProcs = &value
+ return b
+}
+
+// WithIgnoredNetworkDevices sets the IgnoredNetworkDevices field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the IgnoredNetworkDevices field is set to the value of the last call.
+func (b *NodeExporterConfigApplyConfiguration) WithIgnoredNetworkDevices(value []configv1alpha1.NodeExporterIgnoredNetworkDevice) *NodeExporterConfigApplyConfiguration {
+ b.IgnoredNetworkDevices = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/oauth2.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/oauth2.go
new file mode 100644
index 0000000000..d58cc3e513
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/oauth2.go
@@ -0,0 +1,82 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+// OAuth2ApplyConfiguration represents a declarative configuration of the OAuth2 type for use
+// with apply.
+//
+// OAuth2 defines OAuth2 authentication settings for the remote write endpoint.
+type OAuth2ApplyConfiguration struct {
+ // clientId defines the secret reference containing the OAuth2 client ID.
+ // The secret must exist in the openshift-monitoring namespace.
+ ClientID *SecretKeySelectorApplyConfiguration `json:"clientId,omitempty"`
+ // clientSecret defines the secret reference containing the OAuth2 client secret.
+ // The secret must exist in the openshift-monitoring namespace.
+ ClientSecret *SecretKeySelectorApplyConfiguration `json:"clientSecret,omitempty"`
+ // tokenUrl is the URL to fetch the token from.
+ // Must be a valid URL with http or https scheme.
+ // Must be between 1 and 2048 characters in length.
+ TokenURL *string `json:"tokenUrl,omitempty"`
+ // scopes is a list of OAuth2 scopes to request.
+ // When omitted, no scopes are requested.
+ // Maximum of 20 scopes can be specified.
+ // Each scope must be between 1 and 256 characters.
+ Scopes []string `json:"scopes,omitempty"`
+ // endpointParams defines additional parameters to append to the token URL.
+ // When omitted, no additional parameters are sent.
+ // Maximum of 20 parameters can be specified. Entries must have unique names (name is the list key).
+ EndpointParams []OAuth2EndpointParamApplyConfiguration `json:"endpointParams,omitempty"`
+}
+
+// OAuth2ApplyConfiguration constructs a declarative configuration of the OAuth2 type for use with
+// apply.
+func OAuth2() *OAuth2ApplyConfiguration {
+ return &OAuth2ApplyConfiguration{}
+}
+
+// WithClientID sets the ClientID field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the ClientID field is set to the value of the last call.
+func (b *OAuth2ApplyConfiguration) WithClientID(value *SecretKeySelectorApplyConfiguration) *OAuth2ApplyConfiguration {
+ b.ClientID = value
+ return b
+}
+
+// WithClientSecret sets the ClientSecret field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the ClientSecret field is set to the value of the last call.
+func (b *OAuth2ApplyConfiguration) WithClientSecret(value *SecretKeySelectorApplyConfiguration) *OAuth2ApplyConfiguration {
+ b.ClientSecret = value
+ return b
+}
+
+// WithTokenURL sets the TokenURL field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the TokenURL field is set to the value of the last call.
+func (b *OAuth2ApplyConfiguration) WithTokenURL(value string) *OAuth2ApplyConfiguration {
+ b.TokenURL = &value
+ return b
+}
+
+// WithScopes adds the given value to the Scopes field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the Scopes field.
+func (b *OAuth2ApplyConfiguration) WithScopes(values ...string) *OAuth2ApplyConfiguration {
+ for i := range values {
+ b.Scopes = append(b.Scopes, values[i])
+ }
+ return b
+}
+
+// WithEndpointParams adds the given value to the EndpointParams field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the EndpointParams field.
+func (b *OAuth2ApplyConfiguration) WithEndpointParams(values ...*OAuth2EndpointParamApplyConfiguration) *OAuth2ApplyConfiguration {
+ for i := range values {
+ if values[i] == nil {
+ panic("nil value passed to WithEndpointParams")
+ }
+ b.EndpointParams = append(b.EndpointParams, *values[i])
+ }
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/oauth2endpointparam.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/oauth2endpointparam.go
new file mode 100644
index 0000000000..8372d30f8c
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/oauth2endpointparam.go
@@ -0,0 +1,39 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+// OAuth2EndpointParamApplyConfiguration represents a declarative configuration of the OAuth2EndpointParam type for use
+// with apply.
+//
+// OAuth2EndpointParam defines a name/value parameter for the OAuth2 token URL.
+type OAuth2EndpointParamApplyConfiguration struct {
+ // name is the parameter name. Must be between 1 and 256 characters.
+ Name *string `json:"name,omitempty"`
+ // value is the optional parameter value. When omitted, the query parameter is applied as ?name (no value).
+ // When set (including to the empty string), it is applied as ?name=value. Empty string may be used when the
+ // external system expects a parameter with an empty value (e.g. ?parameter="").
+ // Must be between 0 and 2048 characters when present (aligned with common URL length recommendations).
+ Value *string `json:"value,omitempty"`
+}
+
+// OAuth2EndpointParamApplyConfiguration constructs a declarative configuration of the OAuth2EndpointParam type for use with
+// apply.
+func OAuth2EndpointParam() *OAuth2EndpointParamApplyConfiguration {
+ return &OAuth2EndpointParamApplyConfiguration{}
+}
+
+// WithName sets the Name field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Name field is set to the value of the last call.
+func (b *OAuth2EndpointParamApplyConfiguration) WithName(value string) *OAuth2EndpointParamApplyConfiguration {
+ b.Name = &value
+ return b
+}
+
+// WithValue sets the Value field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Value field is set to the value of the last call.
+func (b *OAuth2EndpointParamApplyConfiguration) WithValue(value string) *OAuth2EndpointParamApplyConfiguration {
+ b.Value = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/openshiftstatemetricsconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/openshiftstatemetricsconfig.go
new file mode 100644
index 0000000000..daef85c244
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/openshiftstatemetricsconfig.go
@@ -0,0 +1,117 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ v1 "k8s.io/api/core/v1"
+)
+
+// OpenShiftStateMetricsConfigApplyConfiguration represents a declarative configuration of the OpenShiftStateMetricsConfig type for use
+// with apply.
+//
+// OpenShiftStateMetricsConfig provides configuration options for the openshift-state-metrics agent
+// that runs in the `openshift-monitoring` namespace. The openshift-state-metrics agent generates
+// metrics about the state of OpenShift-specific Kubernetes objects, such as routes, builds, and deployments.
+type OpenShiftStateMetricsConfigApplyConfiguration struct {
+ // nodeSelector defines the nodes on which the Pods are scheduled.
+ // nodeSelector is optional.
+ //
+ // When omitted, this means the user has no opinion and the platform is left
+ // to choose reasonable defaults. These defaults are subject to change over time.
+ // The current default value is `kubernetes.io/os: linux`.
+ // When specified, nodeSelector must contain at least 1 entry and must not contain more than 10 entries.
+ NodeSelector map[string]string `json:"nodeSelector,omitempty"`
+ // resources defines the compute resource requests and limits for the openshift-state-metrics container.
+ // This includes CPU, memory and HugePages constraints to help control scheduling and resource usage.
+ // When not specified, defaults are used by the platform. Requests cannot exceed limits.
+ // This field is optional.
+ // More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/
+ // This is a simplified API that maps to Kubernetes ResourceRequirements.
+ // The current default values are:
+ // resources:
+ // - name: cpu
+ // request: 1m
+ // limit: null
+ // - name: memory
+ // request: 32Mi
+ // limit: null
+ // Maximum length for this list is 5.
+ // Minimum length for this list is 1.
+ // Each resource name must be unique within this list.
+ Resources []ContainerResourceApplyConfiguration `json:"resources,omitempty"`
+ // tolerations defines tolerations for the pods.
+ // tolerations is optional.
+ //
+ // When omitted, this means the user has no opinion and the platform is left
+ // to choose reasonable defaults. These defaults are subject to change over time.
+ // Defaults are empty/unset.
+ // Maximum length for this list is 10.
+ // Minimum length for this list is 1.
+ Tolerations []v1.Toleration `json:"tolerations,omitempty"`
+ // topologySpreadConstraints defines rules for how openshift-state-metrics Pods should be distributed
+ // across topology domains such as zones, nodes, or other user-defined labels.
+ // topologySpreadConstraints is optional.
+ // This helps improve high availability and resource efficiency by avoiding placing
+ // too many replicas in the same failure domain.
+ //
+ // When omitted, this means no opinion and the platform is left to choose a default, which is subject to change over time.
+ // This field maps directly to the `topologySpreadConstraints` field in the Pod spec.
+ // Default is empty list.
+ // Maximum length for this list is 10.
+ // Minimum length for this list is 1.
+ // Entries must have unique topologyKey and whenUnsatisfiable pairs.
+ TopologySpreadConstraints []v1.TopologySpreadConstraint `json:"topologySpreadConstraints,omitempty"`
+}
+
+// OpenShiftStateMetricsConfigApplyConfiguration constructs a declarative configuration of the OpenShiftStateMetricsConfig type for use with
+// apply.
+func OpenShiftStateMetricsConfig() *OpenShiftStateMetricsConfigApplyConfiguration {
+ return &OpenShiftStateMetricsConfigApplyConfiguration{}
+}
+
+// WithNodeSelector puts the entries into the NodeSelector field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, the entries provided by each call will be put on the NodeSelector field,
+// overwriting an existing map entries in NodeSelector field with the same key.
+func (b *OpenShiftStateMetricsConfigApplyConfiguration) WithNodeSelector(entries map[string]string) *OpenShiftStateMetricsConfigApplyConfiguration {
+ if b.NodeSelector == nil && len(entries) > 0 {
+ b.NodeSelector = make(map[string]string, len(entries))
+ }
+ for k, v := range entries {
+ b.NodeSelector[k] = v
+ }
+ return b
+}
+
+// WithResources adds the given value to the Resources field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the Resources field.
+func (b *OpenShiftStateMetricsConfigApplyConfiguration) WithResources(values ...*ContainerResourceApplyConfiguration) *OpenShiftStateMetricsConfigApplyConfiguration {
+ for i := range values {
+ if values[i] == nil {
+ panic("nil value passed to WithResources")
+ }
+ b.Resources = append(b.Resources, *values[i])
+ }
+ return b
+}
+
+// WithTolerations adds the given value to the Tolerations field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the Tolerations field.
+func (b *OpenShiftStateMetricsConfigApplyConfiguration) WithTolerations(values ...v1.Toleration) *OpenShiftStateMetricsConfigApplyConfiguration {
+ for i := range values {
+ b.Tolerations = append(b.Tolerations, values[i])
+ }
+ return b
+}
+
+// WithTopologySpreadConstraints adds the given value to the TopologySpreadConstraints field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the TopologySpreadConstraints field.
+func (b *OpenShiftStateMetricsConfigApplyConfiguration) WithTopologySpreadConstraints(values ...v1.TopologySpreadConstraint) *OpenShiftStateMetricsConfigApplyConfiguration {
+ for i := range values {
+ b.TopologySpreadConstraints = append(b.TopologySpreadConstraints, values[i])
+ }
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/pkicertificatesubject.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/pkicertificatesubject.go
deleted file mode 100644
index c9c93a2806..0000000000
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/pkicertificatesubject.go
+++ /dev/null
@@ -1,39 +0,0 @@
-// Code generated by applyconfiguration-gen. DO NOT EDIT.
-
-package v1alpha1
-
-// PKICertificateSubjectApplyConfiguration represents a declarative configuration of the PKICertificateSubject type for use
-// with apply.
-//
-// PKICertificateSubject defines the requirements imposed on the subject to which the certificate was issued.
-type PKICertificateSubjectApplyConfiguration struct {
- // email specifies the expected email address imposed on the subject to which the certificate was issued, and must match the email address listed in the Subject Alternative Name (SAN) field of the certificate.
- // The email should be a valid email address and at most 320 characters in length.
- Email *string `json:"email,omitempty"`
- // hostname specifies the expected hostname imposed on the subject to which the certificate was issued, and it must match the hostname listed in the Subject Alternative Name (SAN) DNS field of the certificate.
- // The hostname should be a valid dns 1123 subdomain name, optionally prefixed by '*.', and at most 253 characters in length.
- // It should consist only of lowercase alphanumeric characters, hyphens, periods and the optional preceding asterisk.
- Hostname *string `json:"hostname,omitempty"`
-}
-
-// PKICertificateSubjectApplyConfiguration constructs a declarative configuration of the PKICertificateSubject type for use with
-// apply.
-func PKICertificateSubject() *PKICertificateSubjectApplyConfiguration {
- return &PKICertificateSubjectApplyConfiguration{}
-}
-
-// WithEmail sets the Email field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the Email field is set to the value of the last call.
-func (b *PKICertificateSubjectApplyConfiguration) WithEmail(value string) *PKICertificateSubjectApplyConfiguration {
- b.Email = &value
- return b
-}
-
-// WithHostname sets the Hostname field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the Hostname field is set to the value of the last call.
-func (b *PKICertificateSubjectApplyConfiguration) WithHostname(value string) *PKICertificateSubjectApplyConfiguration {
- b.Hostname = &value
- return b
-}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/policyfulciosubject.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/policyfulciosubject.go
deleted file mode 100644
index 5c7bd5ed9e..0000000000
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/policyfulciosubject.go
+++ /dev/null
@@ -1,38 +0,0 @@
-// Code generated by applyconfiguration-gen. DO NOT EDIT.
-
-package v1alpha1
-
-// PolicyFulcioSubjectApplyConfiguration represents a declarative configuration of the PolicyFulcioSubject type for use
-// with apply.
-//
-// PolicyFulcioSubject defines the OIDC issuer and the email of the Fulcio authentication configuration.
-type PolicyFulcioSubjectApplyConfiguration struct {
- // oidcIssuer contains the expected OIDC issuer. It will be verified that the Fulcio-issued certificate contains a (Fulcio-defined) certificate extension pointing at this OIDC issuer URL. When Fulcio issues certificates, it includes a value based on an URL inside the client-provided ID token.
- // Example: "https://expected.OIDC.issuer/"
- OIDCIssuer *string `json:"oidcIssuer,omitempty"`
- // signedEmail holds the email address the the Fulcio certificate is issued for.
- // Example: "expected-signing-user@example.com"
- SignedEmail *string `json:"signedEmail,omitempty"`
-}
-
-// PolicyFulcioSubjectApplyConfiguration constructs a declarative configuration of the PolicyFulcioSubject type for use with
-// apply.
-func PolicyFulcioSubject() *PolicyFulcioSubjectApplyConfiguration {
- return &PolicyFulcioSubjectApplyConfiguration{}
-}
-
-// WithOIDCIssuer sets the OIDCIssuer field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the OIDCIssuer field is set to the value of the last call.
-func (b *PolicyFulcioSubjectApplyConfiguration) WithOIDCIssuer(value string) *PolicyFulcioSubjectApplyConfiguration {
- b.OIDCIssuer = &value
- return b
-}
-
-// WithSignedEmail sets the SignedEmail field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the SignedEmail field is set to the value of the last call.
-func (b *PolicyFulcioSubjectApplyConfiguration) WithSignedEmail(value string) *PolicyFulcioSubjectApplyConfiguration {
- b.SignedEmail = &value
- return b
-}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/policyidentity.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/policyidentity.go
deleted file mode 100644
index 822e756774..0000000000
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/policyidentity.go
+++ /dev/null
@@ -1,57 +0,0 @@
-// Code generated by applyconfiguration-gen. DO NOT EDIT.
-
-package v1alpha1
-
-import (
- configv1alpha1 "github.com/openshift/api/config/v1alpha1"
-)
-
-// PolicyIdentityApplyConfiguration represents a declarative configuration of the PolicyIdentity type for use
-// with apply.
-//
-// PolicyIdentity defines image identity the signature claims about the image. When omitted, the default matchPolicy is "MatchRepoDigestOrExact".
-type PolicyIdentityApplyConfiguration struct {
- // matchPolicy sets the type of matching to be used.
- // Valid values are "MatchRepoDigestOrExact", "MatchRepository", "ExactRepository", "RemapIdentity". When omitted, the default value is "MatchRepoDigestOrExact".
- // If set matchPolicy to ExactRepository, then the exactRepository must be specified.
- // If set matchPolicy to RemapIdentity, then the remapIdentity must be specified.
- // "MatchRepoDigestOrExact" means that the identity in the signature must be in the same repository as the image identity if the image identity is referenced by a digest. Otherwise, the identity in the signature must be the same as the image identity.
- // "MatchRepository" means that the identity in the signature must be in the same repository as the image identity.
- // "ExactRepository" means that the identity in the signature must be in the same repository as a specific identity specified by "repository".
- // "RemapIdentity" means that the signature must be in the same as the remapped image identity. Remapped image identity is obtained by replacing the "prefix" with the specified “signedPrefix” if the the image identity matches the specified remapPrefix.
- MatchPolicy *configv1alpha1.IdentityMatchPolicy `json:"matchPolicy,omitempty"`
- // exactRepository is required if matchPolicy is set to "ExactRepository".
- PolicyMatchExactRepository *PolicyMatchExactRepositoryApplyConfiguration `json:"exactRepository,omitempty"`
- // remapIdentity is required if matchPolicy is set to "RemapIdentity".
- PolicyMatchRemapIdentity *PolicyMatchRemapIdentityApplyConfiguration `json:"remapIdentity,omitempty"`
-}
-
-// PolicyIdentityApplyConfiguration constructs a declarative configuration of the PolicyIdentity type for use with
-// apply.
-func PolicyIdentity() *PolicyIdentityApplyConfiguration {
- return &PolicyIdentityApplyConfiguration{}
-}
-
-// WithMatchPolicy sets the MatchPolicy field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the MatchPolicy field is set to the value of the last call.
-func (b *PolicyIdentityApplyConfiguration) WithMatchPolicy(value configv1alpha1.IdentityMatchPolicy) *PolicyIdentityApplyConfiguration {
- b.MatchPolicy = &value
- return b
-}
-
-// WithPolicyMatchExactRepository sets the PolicyMatchExactRepository field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the PolicyMatchExactRepository field is set to the value of the last call.
-func (b *PolicyIdentityApplyConfiguration) WithPolicyMatchExactRepository(value *PolicyMatchExactRepositoryApplyConfiguration) *PolicyIdentityApplyConfiguration {
- b.PolicyMatchExactRepository = value
- return b
-}
-
-// WithPolicyMatchRemapIdentity sets the PolicyMatchRemapIdentity field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the PolicyMatchRemapIdentity field is set to the value of the last call.
-func (b *PolicyIdentityApplyConfiguration) WithPolicyMatchRemapIdentity(value *PolicyMatchRemapIdentityApplyConfiguration) *PolicyIdentityApplyConfiguration {
- b.PolicyMatchRemapIdentity = value
- return b
-}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/policymatchexactrepository.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/policymatchexactrepository.go
deleted file mode 100644
index 6420b8ed9e..0000000000
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/policymatchexactrepository.go
+++ /dev/null
@@ -1,29 +0,0 @@
-// Code generated by applyconfiguration-gen. DO NOT EDIT.
-
-package v1alpha1
-
-import (
- configv1alpha1 "github.com/openshift/api/config/v1alpha1"
-)
-
-// PolicyMatchExactRepositoryApplyConfiguration represents a declarative configuration of the PolicyMatchExactRepository type for use
-// with apply.
-type PolicyMatchExactRepositoryApplyConfiguration struct {
- // repository is the reference of the image identity to be matched.
- // The value should be a repository name (by omitting the tag or digest) in a registry implementing the "Docker Registry HTTP API V2". For example, docker.io/library/busybox
- Repository *configv1alpha1.IdentityRepositoryPrefix `json:"repository,omitempty"`
-}
-
-// PolicyMatchExactRepositoryApplyConfiguration constructs a declarative configuration of the PolicyMatchExactRepository type for use with
-// apply.
-func PolicyMatchExactRepository() *PolicyMatchExactRepositoryApplyConfiguration {
- return &PolicyMatchExactRepositoryApplyConfiguration{}
-}
-
-// WithRepository sets the Repository field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the Repository field is set to the value of the last call.
-func (b *PolicyMatchExactRepositoryApplyConfiguration) WithRepository(value configv1alpha1.IdentityRepositoryPrefix) *PolicyMatchExactRepositoryApplyConfiguration {
- b.Repository = &value
- return b
-}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/policymatchremapidentity.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/policymatchremapidentity.go
deleted file mode 100644
index 0b1a5098fa..0000000000
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/policymatchremapidentity.go
+++ /dev/null
@@ -1,45 +0,0 @@
-// Code generated by applyconfiguration-gen. DO NOT EDIT.
-
-package v1alpha1
-
-import (
- configv1alpha1 "github.com/openshift/api/config/v1alpha1"
-)
-
-// PolicyMatchRemapIdentityApplyConfiguration represents a declarative configuration of the PolicyMatchRemapIdentity type for use
-// with apply.
-type PolicyMatchRemapIdentityApplyConfiguration struct {
- // prefix is the prefix of the image identity to be matched.
- // If the image identity matches the specified prefix, that prefix is replaced by the specified “signedPrefix” (otherwise it is used as unchanged and no remapping takes place).
- // This useful when verifying signatures for a mirror of some other repository namespace that preserves the vendor’s repository structure.
- // The prefix and signedPrefix values can be either host[:port] values (matching exactly the same host[:port], string), repository namespaces,
- // or repositories (i.e. they must not contain tags/digests), and match as prefixes of the fully expanded form.
- // For example, docker.io/library/busybox (not busybox) to specify that single repository, or docker.io/library (not an empty string) to specify the parent namespace of docker.io/library/busybox.
- Prefix *configv1alpha1.IdentityRepositoryPrefix `json:"prefix,omitempty"`
- // signedPrefix is the prefix of the image identity to be matched in the signature. The format is the same as "prefix". The values can be either host[:port] values (matching exactly the same host[:port], string), repository namespaces,
- // or repositories (i.e. they must not contain tags/digests), and match as prefixes of the fully expanded form.
- // For example, docker.io/library/busybox (not busybox) to specify that single repository, or docker.io/library (not an empty string) to specify the parent namespace of docker.io/library/busybox.
- SignedPrefix *configv1alpha1.IdentityRepositoryPrefix `json:"signedPrefix,omitempty"`
-}
-
-// PolicyMatchRemapIdentityApplyConfiguration constructs a declarative configuration of the PolicyMatchRemapIdentity type for use with
-// apply.
-func PolicyMatchRemapIdentity() *PolicyMatchRemapIdentityApplyConfiguration {
- return &PolicyMatchRemapIdentityApplyConfiguration{}
-}
-
-// WithPrefix sets the Prefix field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the Prefix field is set to the value of the last call.
-func (b *PolicyMatchRemapIdentityApplyConfiguration) WithPrefix(value configv1alpha1.IdentityRepositoryPrefix) *PolicyMatchRemapIdentityApplyConfiguration {
- b.Prefix = &value
- return b
-}
-
-// WithSignedPrefix sets the SignedPrefix field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the SignedPrefix field is set to the value of the last call.
-func (b *PolicyMatchRemapIdentityApplyConfiguration) WithSignedPrefix(value configv1alpha1.IdentityRepositoryPrefix) *PolicyMatchRemapIdentityApplyConfiguration {
- b.SignedPrefix = &value
- return b
-}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/policyrootoftrust.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/policyrootoftrust.go
deleted file mode 100644
index b7a1877fc4..0000000000
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/policyrootoftrust.go
+++ /dev/null
@@ -1,65 +0,0 @@
-// Code generated by applyconfiguration-gen. DO NOT EDIT.
-
-package v1alpha1
-
-import (
- configv1alpha1 "github.com/openshift/api/config/v1alpha1"
-)
-
-// PolicyRootOfTrustApplyConfiguration represents a declarative configuration of the PolicyRootOfTrust type for use
-// with apply.
-//
-// PolicyRootOfTrust defines the root of trust based on the selected policyType.
-type PolicyRootOfTrustApplyConfiguration struct {
- // policyType serves as the union's discriminator. Users are required to assign a value to this field, choosing one of the policy types that define the root of trust.
- // "PublicKey" indicates that the policy relies on a sigstore publicKey and may optionally use a Rekor verification.
- // "FulcioCAWithRekor" indicates that the policy is based on the Fulcio certification and incorporates a Rekor verification.
- // "PKI" indicates that the policy is based on the certificates from Bring Your Own Public Key Infrastructure (BYOPKI). This value is enabled by turning on the SigstoreImageVerificationPKI feature gate.
- PolicyType *configv1alpha1.PolicyType `json:"policyType,omitempty"`
- // publicKey defines the root of trust based on a sigstore public key.
- PublicKey *ImagePolicyPublicKeyRootOfTrustApplyConfiguration `json:"publicKey,omitempty"`
- // fulcioCAWithRekor defines the root of trust based on the Fulcio certificate and the Rekor public key.
- // For more information about Fulcio and Rekor, please refer to the document at:
- // https://github.com/sigstore/fulcio and https://github.com/sigstore/rekor
- FulcioCAWithRekor *ImagePolicyFulcioCAWithRekorRootOfTrustApplyConfiguration `json:"fulcioCAWithRekor,omitempty"`
- // pki defines the root of trust based on Bring Your Own Public Key Infrastructure (BYOPKI) Root CA(s) and corresponding intermediate certificates.
- PKI *ImagePolicyPKIRootOfTrustApplyConfiguration `json:"pki,omitempty"`
-}
-
-// PolicyRootOfTrustApplyConfiguration constructs a declarative configuration of the PolicyRootOfTrust type for use with
-// apply.
-func PolicyRootOfTrust() *PolicyRootOfTrustApplyConfiguration {
- return &PolicyRootOfTrustApplyConfiguration{}
-}
-
-// WithPolicyType sets the PolicyType field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the PolicyType field is set to the value of the last call.
-func (b *PolicyRootOfTrustApplyConfiguration) WithPolicyType(value configv1alpha1.PolicyType) *PolicyRootOfTrustApplyConfiguration {
- b.PolicyType = &value
- return b
-}
-
-// WithPublicKey sets the PublicKey field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the PublicKey field is set to the value of the last call.
-func (b *PolicyRootOfTrustApplyConfiguration) WithPublicKey(value *ImagePolicyPublicKeyRootOfTrustApplyConfiguration) *PolicyRootOfTrustApplyConfiguration {
- b.PublicKey = value
- return b
-}
-
-// WithFulcioCAWithRekor sets the FulcioCAWithRekor field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the FulcioCAWithRekor field is set to the value of the last call.
-func (b *PolicyRootOfTrustApplyConfiguration) WithFulcioCAWithRekor(value *ImagePolicyFulcioCAWithRekorRootOfTrustApplyConfiguration) *PolicyRootOfTrustApplyConfiguration {
- b.FulcioCAWithRekor = value
- return b
-}
-
-// WithPKI sets the PKI field in the declarative configuration to the given value
-// and returns the receiver, so that objects can be built by chaining "With" function invocations.
-// If called multiple times, the PKI field is set to the value of the last call.
-func (b *PolicyRootOfTrustApplyConfiguration) WithPKI(value *ImagePolicyPKIRootOfTrustApplyConfiguration) *PolicyRootOfTrustApplyConfiguration {
- b.PKI = value
- return b
-}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/prometheusconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/prometheusconfig.go
new file mode 100644
index 0000000000..2565d5e49c
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/prometheusconfig.go
@@ -0,0 +1,282 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ configv1alpha1 "github.com/openshift/api/config/v1alpha1"
+ v1 "k8s.io/api/core/v1"
+)
+
+// PrometheusConfigApplyConfiguration represents a declarative configuration of the PrometheusConfig type for use
+// with apply.
+//
+// PrometheusConfig provides configuration options for the Prometheus instance.
+// Use this configuration to control
+// Prometheus deployment, pod scheduling, resource allocation, retention policies, and external integrations.
+type PrometheusConfigApplyConfiguration struct {
+ // additionalAlertmanagerConfigs configures additional Alertmanager instances that receive alerts from
+ // the Prometheus component. This is useful for organizations that need to:
+ // - Send alerts to external monitoring systems (like PagerDuty, Slack, or custom webhooks)
+ // - Route different types of alerts to different teams or systems
+ // - Integrate with existing enterprise alerting infrastructure
+ // - Maintain separate alert routing for compliance or organizational requirements
+ // When omitted, no additional Alertmanager instances are configured (default behavior).
+ // When provided, at least one configuration must be specified (minimum 1, maximum 10 items).
+ // Entries must have unique names (name is the list key).
+ AdditionalAlertmanagerConfigs []AdditionalAlertmanagerConfigApplyConfiguration `json:"additionalAlertmanagerConfigs,omitempty"`
+ // enforcedBodySizeLimitBytes enforces a body size limit (in bytes) for Prometheus scraped metrics.
+ // If a scraped target's body response is larger than the limit, the scrape will fail.
+ // This helps protect Prometheus from targets that return excessively large responses.
+ // The value is specified in bytes (e.g., 4194304 for 4MB, 1073741824 for 1GB).
+ // When omitted, the Cluster Monitoring Operator automatically calculates an appropriate
+ // limit based on cluster capacity. Set an explicit value to override the automatic calculation.
+ // Minimum value is 10240 (10kB).
+ // Maximum value is 1073741824 (1GB).
+ EnforcedBodySizeLimitBytes *int64 `json:"enforcedBodySizeLimitBytes,omitempty"`
+ // externalLabels defines labels to be attached to time series and alerts
+ // when communicating with external systems such as federation, remote storage,
+ // and Alertmanager. These labels are not stored with metrics on disk; they are
+ // only added when data leaves Prometheus (e.g., during federation queries,
+ // remote write, or alert notifications).
+ // At least 1 label must be specified when set, with a maximum of 50 labels allowed.
+ // Each label key must be unique within this list.
+ // When omitted, no external labels are applied.
+ ExternalLabels []LabelApplyConfiguration `json:"externalLabels,omitempty"`
+ // logLevel defines the verbosity of logs emitted by Prometheus.
+ // This field allows users to control the amount and severity of logs generated, which can be useful
+ // for debugging issues or reducing noise in production environments.
+ // Allowed values are Error, Warn, Info, and Debug.
+ // When set to Error, only errors will be logged.
+ // When set to Warn, both warnings and errors will be logged.
+ // When set to Info, general information, warnings, and errors will all be logged.
+ // When set to Debug, detailed debugging information will be logged.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, that is subject to change over time.
+ // The current default value is `Info`.
+ LogLevel *configv1alpha1.LogLevel `json:"logLevel,omitempty"`
+ // nodeSelector defines the nodes on which the Pods are scheduled.
+ // nodeSelector is optional.
+ //
+ // When omitted, this means the user has no opinion and the platform is left
+ // to choose reasonable defaults. These defaults are subject to change over time.
+ // The current default value is `kubernetes.io/os: linux`.
+ // When specified, nodeSelector must contain at least one key-value pair (minimum of 1)
+ // and must not contain more than 10 entries.
+ NodeSelector map[string]string `json:"nodeSelector,omitempty"`
+ // queryLogFile specifies the file to which PromQL queries are logged.
+ // This setting can be either a filename, in which
+ // case the queries are saved to an `emptyDir` volume
+ // at `/var/log/prometheus`, or a full path to a location where
+ // an `emptyDir` volume will be mounted and the queries saved.
+ // Writing to `/dev/stderr`, `/dev/stdout` or `/dev/null` is supported, but
+ // writing to any other `/dev/` path is not supported. Relative paths are
+ // also not supported.
+ // By default, PromQL queries are not logged.
+ // Must be an absolute path starting with `/` or a simple filename without path separators.
+ // Must not contain consecutive slashes, end with a slash, or include '..' path traversal.
+ // Must contain only alphanumeric characters, '.', '_', '-', or '/'.
+ // Must be between 1 and 255 characters in length.
+ QueryLogFile *string `json:"queryLogFile,omitempty"`
+ // remoteWrite defines the remote write configuration, including URL, authentication, and relabeling settings.
+ // Remote write allows Prometheus to send metrics it collects to external long-term storage systems.
+ // When omitted, no remote write endpoints are configured.
+ // When provided, at least one configuration must be specified (minimum 1, maximum 10 items).
+ // Entries must have unique names (name is the list key).
+ RemoteWrite []RemoteWriteSpecApplyConfiguration `json:"remoteWrite,omitempty"`
+ // resources defines the compute resource requests and limits for the Prometheus container.
+ // This includes CPU, memory and HugePages constraints to help control scheduling and resource usage.
+ // When not specified, defaults are used by the platform. Requests cannot exceed limits.
+ // This field is optional.
+ // More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/
+ // This is a simplified API that maps to Kubernetes ResourceRequirements.
+ // The current default values are:
+ // resources:
+ // - name: cpu
+ // request: 4m
+ // limit: null
+ // - name: memory
+ // request: 40Mi
+ // limit: null
+ // Maximum length for this list is 5.
+ // Minimum length for this list is 1.
+ // Each resource name must be unique within this list.
+ Resources []ContainerResourceApplyConfiguration `json:"resources,omitempty"`
+ // retention configures how long Prometheus retains metrics data and how much storage it can use.
+ // When omitted, the platform chooses reasonable defaults (currently 15d retention, no size limit).
+ Retention *RetentionApplyConfiguration `json:"retention,omitempty"`
+ // tolerations defines tolerations for the pods.
+ // tolerations is optional.
+ //
+ // When omitted, this means the user has no opinion and the platform is left
+ // to choose reasonable defaults. These defaults are subject to change over time.
+ // Defaults are empty/unset.
+ // Maximum length for this list is 10
+ // Minimum length for this list is 1
+ Tolerations []v1.Toleration `json:"tolerations,omitempty"`
+ // topologySpreadConstraints defines rules for how Prometheus Pods should be distributed
+ // across topology domains such as zones, nodes, or other user-defined labels.
+ // topologySpreadConstraints is optional.
+ // This helps improve high availability and resource efficiency by avoiding placing
+ // too many replicas in the same failure domain.
+ //
+ // When omitted, this means no opinion and the platform is left to choose a default, which is subject to change over time.
+ // This field maps directly to the `topologySpreadConstraints` field in the Pod spec.
+ // Default is empty list.
+ // Maximum length for this list is 10.
+ // Minimum length for this list is 1
+ // Entries must have unique topologyKey and whenUnsatisfiable pairs.
+ TopologySpreadConstraints []v1.TopologySpreadConstraint `json:"topologySpreadConstraints,omitempty"`
+ // collectionProfile defines the metrics collection profile that Prometheus uses to collect
+ // metrics from the platform components. Supported values are `Full` or
+ // `Minimal`. In the `Full` profile (default), Prometheus collects all
+ // metrics that are exposed by the platform components. In the `Minimal`
+ // profile, Prometheus only collects metrics necessary for the default
+ // platform alerts, recording rules, telemetry and console dashboards.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The default value is `Full`.
+ CollectionProfile *configv1alpha1.CollectionProfile `json:"collectionProfile,omitempty"`
+ // volumeClaimTemplate defines persistent storage for Prometheus. Use this setting to
+ // configure the persistent volume claim, including storage class and volume size.
+ // If omitted, the Pod uses ephemeral storage and Prometheus data will not persist
+ // across restarts.
+ VolumeClaimTemplate *v1.PersistentVolumeClaim `json:"volumeClaimTemplate,omitempty"`
+}
+
+// PrometheusConfigApplyConfiguration constructs a declarative configuration of the PrometheusConfig type for use with
+// apply.
+func PrometheusConfig() *PrometheusConfigApplyConfiguration {
+ return &PrometheusConfigApplyConfiguration{}
+}
+
+// WithAdditionalAlertmanagerConfigs adds the given value to the AdditionalAlertmanagerConfigs field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the AdditionalAlertmanagerConfigs field.
+func (b *PrometheusConfigApplyConfiguration) WithAdditionalAlertmanagerConfigs(values ...*AdditionalAlertmanagerConfigApplyConfiguration) *PrometheusConfigApplyConfiguration {
+ for i := range values {
+ if values[i] == nil {
+ panic("nil value passed to WithAdditionalAlertmanagerConfigs")
+ }
+ b.AdditionalAlertmanagerConfigs = append(b.AdditionalAlertmanagerConfigs, *values[i])
+ }
+ return b
+}
+
+// WithEnforcedBodySizeLimitBytes sets the EnforcedBodySizeLimitBytes field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the EnforcedBodySizeLimitBytes field is set to the value of the last call.
+func (b *PrometheusConfigApplyConfiguration) WithEnforcedBodySizeLimitBytes(value int64) *PrometheusConfigApplyConfiguration {
+ b.EnforcedBodySizeLimitBytes = &value
+ return b
+}
+
+// WithExternalLabels adds the given value to the ExternalLabels field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the ExternalLabels field.
+func (b *PrometheusConfigApplyConfiguration) WithExternalLabels(values ...*LabelApplyConfiguration) *PrometheusConfigApplyConfiguration {
+ for i := range values {
+ if values[i] == nil {
+ panic("nil value passed to WithExternalLabels")
+ }
+ b.ExternalLabels = append(b.ExternalLabels, *values[i])
+ }
+ return b
+}
+
+// WithLogLevel sets the LogLevel field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the LogLevel field is set to the value of the last call.
+func (b *PrometheusConfigApplyConfiguration) WithLogLevel(value configv1alpha1.LogLevel) *PrometheusConfigApplyConfiguration {
+ b.LogLevel = &value
+ return b
+}
+
+// WithNodeSelector puts the entries into the NodeSelector field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, the entries provided by each call will be put on the NodeSelector field,
+// overwriting an existing map entries in NodeSelector field with the same key.
+func (b *PrometheusConfigApplyConfiguration) WithNodeSelector(entries map[string]string) *PrometheusConfigApplyConfiguration {
+ if b.NodeSelector == nil && len(entries) > 0 {
+ b.NodeSelector = make(map[string]string, len(entries))
+ }
+ for k, v := range entries {
+ b.NodeSelector[k] = v
+ }
+ return b
+}
+
+// WithQueryLogFile sets the QueryLogFile field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the QueryLogFile field is set to the value of the last call.
+func (b *PrometheusConfigApplyConfiguration) WithQueryLogFile(value string) *PrometheusConfigApplyConfiguration {
+ b.QueryLogFile = &value
+ return b
+}
+
+// WithRemoteWrite adds the given value to the RemoteWrite field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the RemoteWrite field.
+func (b *PrometheusConfigApplyConfiguration) WithRemoteWrite(values ...*RemoteWriteSpecApplyConfiguration) *PrometheusConfigApplyConfiguration {
+ for i := range values {
+ if values[i] == nil {
+ panic("nil value passed to WithRemoteWrite")
+ }
+ b.RemoteWrite = append(b.RemoteWrite, *values[i])
+ }
+ return b
+}
+
+// WithResources adds the given value to the Resources field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the Resources field.
+func (b *PrometheusConfigApplyConfiguration) WithResources(values ...*ContainerResourceApplyConfiguration) *PrometheusConfigApplyConfiguration {
+ for i := range values {
+ if values[i] == nil {
+ panic("nil value passed to WithResources")
+ }
+ b.Resources = append(b.Resources, *values[i])
+ }
+ return b
+}
+
+// WithRetention sets the Retention field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Retention field is set to the value of the last call.
+func (b *PrometheusConfigApplyConfiguration) WithRetention(value *RetentionApplyConfiguration) *PrometheusConfigApplyConfiguration {
+ b.Retention = value
+ return b
+}
+
+// WithTolerations adds the given value to the Tolerations field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the Tolerations field.
+func (b *PrometheusConfigApplyConfiguration) WithTolerations(values ...v1.Toleration) *PrometheusConfigApplyConfiguration {
+ for i := range values {
+ b.Tolerations = append(b.Tolerations, values[i])
+ }
+ return b
+}
+
+// WithTopologySpreadConstraints adds the given value to the TopologySpreadConstraints field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the TopologySpreadConstraints field.
+func (b *PrometheusConfigApplyConfiguration) WithTopologySpreadConstraints(values ...v1.TopologySpreadConstraint) *PrometheusConfigApplyConfiguration {
+ for i := range values {
+ b.TopologySpreadConstraints = append(b.TopologySpreadConstraints, values[i])
+ }
+ return b
+}
+
+// WithCollectionProfile sets the CollectionProfile field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the CollectionProfile field is set to the value of the last call.
+func (b *PrometheusConfigApplyConfiguration) WithCollectionProfile(value configv1alpha1.CollectionProfile) *PrometheusConfigApplyConfiguration {
+ b.CollectionProfile = &value
+ return b
+}
+
+// WithVolumeClaimTemplate sets the VolumeClaimTemplate field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the VolumeClaimTemplate field is set to the value of the last call.
+func (b *PrometheusConfigApplyConfiguration) WithVolumeClaimTemplate(value v1.PersistentVolumeClaim) *PrometheusConfigApplyConfiguration {
+ b.VolumeClaimTemplate = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/prometheusoperatoradmissionwebhookconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/prometheusoperatoradmissionwebhookconfig.go
index b35fb15fef..9eadb023ec 100644
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/prometheusoperatoradmissionwebhookconfig.go
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/prometheusoperatoradmissionwebhookconfig.go
@@ -29,7 +29,7 @@ type PrometheusOperatorAdmissionWebhookConfigApplyConfiguration struct {
// - name: memory
// request: 30Mi
// limit: null
- // Maximum length for this list is 10.
+ // Maximum length for this list is 5.
// Minimum length for this list is 1.
// Each resource name must be unique within this list.
Resources []ContainerResourceApplyConfiguration `json:"resources,omitempty"`
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/prometheusoperatorconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/prometheusoperatorconfig.go
index 2612926255..a0bac703d0 100644
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/prometheusoperatorconfig.go
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/prometheusoperatorconfig.go
@@ -46,7 +46,7 @@ type PrometheusOperatorConfigApplyConfiguration struct {
// - name: memory
// request: 40Mi
// limit: null
- // Maximum length for this list is 10.
+ // Maximum length for this list is 5.
// Minimum length for this list is 1.
// Each resource name must be unique within this list.
Resources []ContainerResourceApplyConfiguration `json:"resources,omitempty"`
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/prometheusremotewriteheader.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/prometheusremotewriteheader.go
new file mode 100644
index 0000000000..53e21d1f9d
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/prometheusremotewriteheader.go
@@ -0,0 +1,40 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+// PrometheusRemoteWriteHeaderApplyConfiguration represents a declarative configuration of the PrometheusRemoteWriteHeader type for use
+// with apply.
+//
+// PrometheusRemoteWriteHeader defines a custom HTTP header for remote write requests.
+// The header name must not be one of the reserved headers set by Prometheus (Host, Authorization, Content-Encoding, Content-Type, X-Prometheus-Remote-Write-Version, User-Agent, Connection, Keep-Alive, Proxy-Authenticate, Proxy-Authorization, WWW-Authenticate).
+// Header names must contain only case-insensitive alphanumeric characters, hyphens (-), and underscores (_); other characters (e.g. emoji) are rejected by validation.
+// Validation is enforced on the Headers field in RemoteWriteSpec.
+type PrometheusRemoteWriteHeaderApplyConfiguration struct {
+ // name is the HTTP header name. Must not be a reserved header (see type documentation).
+ // Must contain only alphanumeric characters, hyphens, and underscores; invalid characters are rejected. Must be between 1 and 256 characters.
+ Name *string `json:"name,omitempty"`
+ // value is the HTTP header value. Must be at most 4096 characters.
+ Value *string `json:"value,omitempty"`
+}
+
+// PrometheusRemoteWriteHeaderApplyConfiguration constructs a declarative configuration of the PrometheusRemoteWriteHeader type for use with
+// apply.
+func PrometheusRemoteWriteHeader() *PrometheusRemoteWriteHeaderApplyConfiguration {
+ return &PrometheusRemoteWriteHeaderApplyConfiguration{}
+}
+
+// WithName sets the Name field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Name field is set to the value of the last call.
+func (b *PrometheusRemoteWriteHeaderApplyConfiguration) WithName(value string) *PrometheusRemoteWriteHeaderApplyConfiguration {
+ b.Name = &value
+ return b
+}
+
+// WithValue sets the Value field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Value field is set to the value of the last call.
+func (b *PrometheusRemoteWriteHeaderApplyConfiguration) WithValue(value string) *PrometheusRemoteWriteHeaderApplyConfiguration {
+ b.Value = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/queueconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/queueconfig.go
new file mode 100644
index 0000000000..a24ff44ace
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/queueconfig.go
@@ -0,0 +1,129 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ configv1alpha1 "github.com/openshift/api/config/v1alpha1"
+)
+
+// QueueConfigApplyConfiguration represents a declarative configuration of the QueueConfig type for use
+// with apply.
+//
+// QueueConfig allows tuning configuration for remote write queue parameters.
+// Configure this when you need to control throughput, backpressure, or retry behavior—for example to avoid overloading the remote endpoint, to reduce memory usage, or to tune for high-cardinality workloads. Consider capacity, maxShards, and batchSendDeadlineSeconds for throughput; minBackoffMilliseconds and maxBackoffMilliseconds for retries; and rateLimitedAction when the remote returns HTTP 429.
+type QueueConfigApplyConfiguration struct {
+ // capacity is the number of samples to buffer per shard before we start dropping them.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The default value is 10000.
+ // Minimum value is 1.
+ // Maximum value is 1000000.
+ Capacity *int32 `json:"capacity,omitempty"`
+ // maxShards is the maximum number of shards, i.e. amount of concurrency.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The default value is 200.
+ // Minimum value is 1.
+ // Maximum value is 10000.
+ MaxShards *int32 `json:"maxShards,omitempty"`
+ // minShards is the minimum number of shards, i.e. amount of concurrency.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The default value is 1.
+ // Minimum value is 1.
+ // Maximum value is 10000.
+ MinShards *int32 `json:"minShards,omitempty"`
+ // maxSamplesPerSend is the maximum number of samples per send.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The default value is 1000.
+ // Minimum value is 1.
+ // Maximum value is 100000.
+ MaxSamplesPerSend *int32 `json:"maxSamplesPerSend,omitempty"`
+ // batchSendDeadlineSeconds is the maximum time in seconds a sample will wait in buffer before being sent.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // Minimum value is 1 second.
+ // Maximum value is 3600 seconds (1 hour).
+ BatchSendDeadlineSeconds *int32 `json:"batchSendDeadlineSeconds,omitempty"`
+ // minBackoffMilliseconds is the minimum retry delay in milliseconds.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // Minimum value is 1 millisecond.
+ // Maximum value is 3600000 milliseconds (1 hour).
+ MinBackoffMilliseconds *int32 `json:"minBackoffMilliseconds,omitempty"`
+ // maxBackoffMilliseconds is the maximum retry delay in milliseconds.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // Minimum value is 1 millisecond.
+ // Maximum value is 3600000 milliseconds (1 hour).
+ MaxBackoffMilliseconds *int32 `json:"maxBackoffMilliseconds,omitempty"`
+ // rateLimitedAction controls what to do when the remote write endpoint returns HTTP 429 (Too Many Requests).
+ // When omitted, no retries are performed on rate limit responses.
+ // When set to "Retry", Prometheus will retry such requests using the backoff settings above.
+ // Valid value when set is "Retry".
+ RateLimitedAction *configv1alpha1.RateLimitedAction `json:"rateLimitedAction,omitempty"`
+}
+
+// QueueConfigApplyConfiguration constructs a declarative configuration of the QueueConfig type for use with
+// apply.
+func QueueConfig() *QueueConfigApplyConfiguration {
+ return &QueueConfigApplyConfiguration{}
+}
+
+// WithCapacity sets the Capacity field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Capacity field is set to the value of the last call.
+func (b *QueueConfigApplyConfiguration) WithCapacity(value int32) *QueueConfigApplyConfiguration {
+ b.Capacity = &value
+ return b
+}
+
+// WithMaxShards sets the MaxShards field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the MaxShards field is set to the value of the last call.
+func (b *QueueConfigApplyConfiguration) WithMaxShards(value int32) *QueueConfigApplyConfiguration {
+ b.MaxShards = &value
+ return b
+}
+
+// WithMinShards sets the MinShards field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the MinShards field is set to the value of the last call.
+func (b *QueueConfigApplyConfiguration) WithMinShards(value int32) *QueueConfigApplyConfiguration {
+ b.MinShards = &value
+ return b
+}
+
+// WithMaxSamplesPerSend sets the MaxSamplesPerSend field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the MaxSamplesPerSend field is set to the value of the last call.
+func (b *QueueConfigApplyConfiguration) WithMaxSamplesPerSend(value int32) *QueueConfigApplyConfiguration {
+ b.MaxSamplesPerSend = &value
+ return b
+}
+
+// WithBatchSendDeadlineSeconds sets the BatchSendDeadlineSeconds field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the BatchSendDeadlineSeconds field is set to the value of the last call.
+func (b *QueueConfigApplyConfiguration) WithBatchSendDeadlineSeconds(value int32) *QueueConfigApplyConfiguration {
+ b.BatchSendDeadlineSeconds = &value
+ return b
+}
+
+// WithMinBackoffMilliseconds sets the MinBackoffMilliseconds field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the MinBackoffMilliseconds field is set to the value of the last call.
+func (b *QueueConfigApplyConfiguration) WithMinBackoffMilliseconds(value int32) *QueueConfigApplyConfiguration {
+ b.MinBackoffMilliseconds = &value
+ return b
+}
+
+// WithMaxBackoffMilliseconds sets the MaxBackoffMilliseconds field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the MaxBackoffMilliseconds field is set to the value of the last call.
+func (b *QueueConfigApplyConfiguration) WithMaxBackoffMilliseconds(value int32) *QueueConfigApplyConfiguration {
+ b.MaxBackoffMilliseconds = &value
+ return b
+}
+
+// WithRateLimitedAction sets the RateLimitedAction field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the RateLimitedAction field is set to the value of the last call.
+func (b *QueueConfigApplyConfiguration) WithRateLimitedAction(value configv1alpha1.RateLimitedAction) *QueueConfigApplyConfiguration {
+ b.RateLimitedAction = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/relabelactionconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/relabelactionconfig.go
new file mode 100644
index 0000000000..cfcfc7b5cc
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/relabelactionconfig.go
@@ -0,0 +1,135 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ configv1alpha1 "github.com/openshift/api/config/v1alpha1"
+)
+
+// RelabelActionConfigApplyConfiguration represents a declarative configuration of the RelabelActionConfig type for use
+// with apply.
+//
+// RelabelActionConfig represents the action to perform and its configuration.
+// Exactly one action-specific configuration must be specified based on the action type.
+type RelabelActionConfigApplyConfiguration struct {
+ // type specifies the action to perform on the matched labels.
+ // Allowed values are Replace, Lowercase, Uppercase, Keep, Drop, KeepEqual, DropEqual, HashMod, LabelMap, LabelDrop, LabelKeep.
+ //
+ // When set to Replace, regex is matched against the concatenated source_labels; target_label is set to replacement with match group references (${1}, ${2}, ...) substituted. If regex does not match, no replacement takes place.
+ //
+ // When set to Lowercase, the concatenated source_labels are mapped to their lower case. Requires Prometheus >= v2.36.0.
+ //
+ // When set to Uppercase, the concatenated source_labels are mapped to their upper case. Requires Prometheus >= v2.36.0.
+ //
+ // When set to Keep, targets for which regex does not match the concatenated source_labels are dropped.
+ //
+ // When set to Drop, targets for which regex matches the concatenated source_labels are dropped.
+ //
+ // When set to KeepEqual, targets for which the concatenated source_labels do not match target_label are dropped. Requires Prometheus >= v2.41.0.
+ //
+ // When set to DropEqual, targets for which the concatenated source_labels do match target_label are dropped. Requires Prometheus >= v2.41.0.
+ //
+ // When set to HashMod, target_label is set to the modulus of a hash of the concatenated source_labels.
+ //
+ // When set to LabelMap, regex is matched against all source label names (not just source_labels); matching label values are copied to new names given by replacement with ${1}, ${2}, ... substituted.
+ //
+ // When set to LabelDrop, regex is matched against all label names; any label that matches is removed.
+ //
+ // When set to LabelKeep, regex is matched against all label names; any label that does not match is removed.
+ Type *configv1alpha1.RelabelAction `json:"type,omitempty"`
+ // replace configures the Replace action.
+ // Required when type is Replace, and forbidden otherwise.
+ Replace *ReplaceActionConfigApplyConfiguration `json:"replace,omitempty"`
+ // hashMod configures the HashMod action.
+ // Required when type is HashMod, and forbidden otherwise.
+ HashMod *HashModActionConfigApplyConfiguration `json:"hashMod,omitempty"`
+ // labelMap configures the LabelMap action.
+ // Required when type is LabelMap, and forbidden otherwise.
+ LabelMap *LabelMapActionConfigApplyConfiguration `json:"labelMap,omitempty"`
+ // lowercase configures the Lowercase action.
+ // Required when type is Lowercase, and forbidden otherwise.
+ // Requires Prometheus >= v2.36.0.
+ Lowercase *LowercaseActionConfigApplyConfiguration `json:"lowercase,omitempty"`
+ // uppercase configures the Uppercase action.
+ // Required when type is Uppercase, and forbidden otherwise.
+ // Requires Prometheus >= v2.36.0.
+ Uppercase *UppercaseActionConfigApplyConfiguration `json:"uppercase,omitempty"`
+ // keepEqual configures the KeepEqual action.
+ // Required when type is KeepEqual, and forbidden otherwise.
+ // Requires Prometheus >= v2.41.0.
+ KeepEqual *KeepEqualActionConfigApplyConfiguration `json:"keepEqual,omitempty"`
+ // dropEqual configures the DropEqual action.
+ // Required when type is DropEqual, and forbidden otherwise.
+ // Requires Prometheus >= v2.41.0.
+ DropEqual *DropEqualActionConfigApplyConfiguration `json:"dropEqual,omitempty"`
+}
+
+// RelabelActionConfigApplyConfiguration constructs a declarative configuration of the RelabelActionConfig type for use with
+// apply.
+func RelabelActionConfig() *RelabelActionConfigApplyConfiguration {
+ return &RelabelActionConfigApplyConfiguration{}
+}
+
+// WithType sets the Type field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Type field is set to the value of the last call.
+func (b *RelabelActionConfigApplyConfiguration) WithType(value configv1alpha1.RelabelAction) *RelabelActionConfigApplyConfiguration {
+ b.Type = &value
+ return b
+}
+
+// WithReplace sets the Replace field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Replace field is set to the value of the last call.
+func (b *RelabelActionConfigApplyConfiguration) WithReplace(value *ReplaceActionConfigApplyConfiguration) *RelabelActionConfigApplyConfiguration {
+ b.Replace = value
+ return b
+}
+
+// WithHashMod sets the HashMod field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the HashMod field is set to the value of the last call.
+func (b *RelabelActionConfigApplyConfiguration) WithHashMod(value *HashModActionConfigApplyConfiguration) *RelabelActionConfigApplyConfiguration {
+ b.HashMod = value
+ return b
+}
+
+// WithLabelMap sets the LabelMap field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the LabelMap field is set to the value of the last call.
+func (b *RelabelActionConfigApplyConfiguration) WithLabelMap(value *LabelMapActionConfigApplyConfiguration) *RelabelActionConfigApplyConfiguration {
+ b.LabelMap = value
+ return b
+}
+
+// WithLowercase sets the Lowercase field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Lowercase field is set to the value of the last call.
+func (b *RelabelActionConfigApplyConfiguration) WithLowercase(value *LowercaseActionConfigApplyConfiguration) *RelabelActionConfigApplyConfiguration {
+ b.Lowercase = value
+ return b
+}
+
+// WithUppercase sets the Uppercase field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Uppercase field is set to the value of the last call.
+func (b *RelabelActionConfigApplyConfiguration) WithUppercase(value *UppercaseActionConfigApplyConfiguration) *RelabelActionConfigApplyConfiguration {
+ b.Uppercase = value
+ return b
+}
+
+// WithKeepEqual sets the KeepEqual field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the KeepEqual field is set to the value of the last call.
+func (b *RelabelActionConfigApplyConfiguration) WithKeepEqual(value *KeepEqualActionConfigApplyConfiguration) *RelabelActionConfigApplyConfiguration {
+ b.KeepEqual = value
+ return b
+}
+
+// WithDropEqual sets the DropEqual field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the DropEqual field is set to the value of the last call.
+func (b *RelabelActionConfigApplyConfiguration) WithDropEqual(value *DropEqualActionConfigApplyConfiguration) *RelabelActionConfigApplyConfiguration {
+ b.DropEqual = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/relabelconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/relabelconfig.go
new file mode 100644
index 0000000000..efe191727e
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/relabelconfig.go
@@ -0,0 +1,89 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+// RelabelConfigApplyConfiguration represents a declarative configuration of the RelabelConfig type for use
+// with apply.
+//
+// RelabelConfig represents a relabeling rule.
+type RelabelConfigApplyConfiguration struct {
+ // name is a unique identifier for this relabel configuration.
+ // Must contain only alphanumeric characters, hyphens, and underscores.
+ // Must be between 1 and 63 characters in length.
+ Name *string `json:"name,omitempty"`
+ // sourceLabels specifies which label names to extract from each series for this relabeling rule.
+ // The values of these labels are joined together using the configured separator,
+ // and the resulting string is then matched against the regular expression.
+ // If a referenced label does not exist on a series, Prometheus substitutes an empty string.
+ // When omitted, the rule operates without extracting source labels (useful for actions like labelmap).
+ // Minimum of 1 and maximum of 10 source labels can be specified, each between 1 and 128 characters.
+ // Each entry must be unique.
+ // Label names beginning with "__" (two underscores) are reserved for internal Prometheus use and are not allowed.
+ // Label names SHOULD start with a letter (a-z, A-Z) or underscore (_), followed by zero or more letters, digits (0-9), or underscores for best compatibility.
+ // While Prometheus supports UTF-8 characters in label names (since v3.0.0), using the recommended character set
+ // ensures better compatibility with the wider ecosystem (tooling, third-party instrumentation, etc.).
+ SourceLabels []string `json:"sourceLabels,omitempty"`
+ // separator is the character sequence used to join source label values.
+ // Common examples: ";", ",", "::", "|||".
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The default value is ";".
+ // Must be between 1 and 5 characters in length when specified.
+ Separator *string `json:"separator,omitempty"`
+ // regex is the regular expression to match against the concatenated source label values.
+ // Must be a valid RE2 regular expression (https://github.com/google/re2/wiki/Syntax).
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The default value is "(.*)" to match everything.
+ // Must be between 1 and 1000 characters in length when specified.
+ Regex *string `json:"regex,omitempty"`
+ // action defines the action to perform on the matched labels and its configuration.
+ // Exactly one action-specific configuration must be specified based on the action type.
+ Action *RelabelActionConfigApplyConfiguration `json:"action,omitempty"`
+}
+
+// RelabelConfigApplyConfiguration constructs a declarative configuration of the RelabelConfig type for use with
+// apply.
+func RelabelConfig() *RelabelConfigApplyConfiguration {
+ return &RelabelConfigApplyConfiguration{}
+}
+
+// WithName sets the Name field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Name field is set to the value of the last call.
+func (b *RelabelConfigApplyConfiguration) WithName(value string) *RelabelConfigApplyConfiguration {
+ b.Name = &value
+ return b
+}
+
+// WithSourceLabels adds the given value to the SourceLabels field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the SourceLabels field.
+func (b *RelabelConfigApplyConfiguration) WithSourceLabels(values ...string) *RelabelConfigApplyConfiguration {
+ for i := range values {
+ b.SourceLabels = append(b.SourceLabels, values[i])
+ }
+ return b
+}
+
+// WithSeparator sets the Separator field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Separator field is set to the value of the last call.
+func (b *RelabelConfigApplyConfiguration) WithSeparator(value string) *RelabelConfigApplyConfiguration {
+ b.Separator = &value
+ return b
+}
+
+// WithRegex sets the Regex field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Regex field is set to the value of the last call.
+func (b *RelabelConfigApplyConfiguration) WithRegex(value string) *RelabelConfigApplyConfiguration {
+ b.Regex = &value
+ return b
+}
+
+// WithAction sets the Action field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Action field is set to the value of the last call.
+func (b *RelabelConfigApplyConfiguration) WithAction(value *RelabelActionConfigApplyConfiguration) *RelabelConfigApplyConfiguration {
+ b.Action = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/remotewriteauthorization.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/remotewriteauthorization.go
new file mode 100644
index 0000000000..e9b07674d1
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/remotewriteauthorization.go
@@ -0,0 +1,88 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ configv1alpha1 "github.com/openshift/api/config/v1alpha1"
+)
+
+// RemoteWriteAuthorizationApplyConfiguration represents a declarative configuration of the RemoteWriteAuthorization type for use
+// with apply.
+//
+// RemoteWriteAuthorization defines the authorization method for a remote write endpoint.
+// Nested config requirements depend on the type discriminator: Authorization requires authorization,
+// BasicAuth requires basicAuth, OAuth2 requires oauth2, SigV4 requires sigv4, and ServiceAccount forbids all nested configs.
+type RemoteWriteAuthorizationApplyConfiguration struct {
+ // type specifies the authorization method to use.
+ // Allowed values are Authorization, BasicAuth, OAuth2, SigV4, and ServiceAccount.
+ //
+ // When set to Authorization, credentials are read from a single Secret key. The secret key typically contains a Bearer token. Use the authorization field.
+ //
+ // When set to BasicAuth, HTTP basic authentication is used; the basicAuth field (username and password from Secrets) must be set.
+ //
+ // When set to OAuth2, OAuth2 client credentials flow is used; the oauth2 field (clientId, clientSecret, tokenUrl) must be set.
+ //
+ // When set to SigV4, AWS Signature Version 4 is used for authentication; the sigv4 field must be set.
+ //
+ // When set to ServiceAccount, the pod's service account token is used for machine identity. No additional field is required; the operator configures the token path.
+ Type *configv1alpha1.RemoteWriteAuthorizationType `json:"type,omitempty"`
+ // authorization defines the secret reference containing the authorization credentials (e.g. Bearer token).
+ // Required when type is "Authorization", and forbidden otherwise.
+ // The secret must exist in the openshift-monitoring namespace.
+ Authorization *SecretKeySelectorApplyConfiguration `json:"authorization,omitempty"`
+ // basicAuth defines HTTP basic authentication credentials.
+ // Required when type is "BasicAuth", and forbidden otherwise.
+ BasicAuth *BasicAuthApplyConfiguration `json:"basicAuth,omitempty"`
+ // oauth2 defines OAuth2 client credentials authentication.
+ // Required when type is "OAuth2", and forbidden otherwise.
+ OAuth2 *OAuth2ApplyConfiguration `json:"oauth2,omitempty"`
+ // sigv4 defines AWS Signature Version 4 authentication.
+ // Required when type is "SigV4", and forbidden otherwise.
+ Sigv4 *Sigv4ApplyConfiguration `json:"sigv4,omitempty"`
+}
+
+// RemoteWriteAuthorizationApplyConfiguration constructs a declarative configuration of the RemoteWriteAuthorization type for use with
+// apply.
+func RemoteWriteAuthorization() *RemoteWriteAuthorizationApplyConfiguration {
+ return &RemoteWriteAuthorizationApplyConfiguration{}
+}
+
+// WithType sets the Type field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Type field is set to the value of the last call.
+func (b *RemoteWriteAuthorizationApplyConfiguration) WithType(value configv1alpha1.RemoteWriteAuthorizationType) *RemoteWriteAuthorizationApplyConfiguration {
+ b.Type = &value
+ return b
+}
+
+// WithAuthorization sets the Authorization field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Authorization field is set to the value of the last call.
+func (b *RemoteWriteAuthorizationApplyConfiguration) WithAuthorization(value *SecretKeySelectorApplyConfiguration) *RemoteWriteAuthorizationApplyConfiguration {
+ b.Authorization = value
+ return b
+}
+
+// WithBasicAuth sets the BasicAuth field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the BasicAuth field is set to the value of the last call.
+func (b *RemoteWriteAuthorizationApplyConfiguration) WithBasicAuth(value *BasicAuthApplyConfiguration) *RemoteWriteAuthorizationApplyConfiguration {
+ b.BasicAuth = value
+ return b
+}
+
+// WithOAuth2 sets the OAuth2 field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the OAuth2 field is set to the value of the last call.
+func (b *RemoteWriteAuthorizationApplyConfiguration) WithOAuth2(value *OAuth2ApplyConfiguration) *RemoteWriteAuthorizationApplyConfiguration {
+ b.OAuth2 = value
+ return b
+}
+
+// WithSigv4 sets the Sigv4 field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Sigv4 field is set to the value of the last call.
+func (b *RemoteWriteAuthorizationApplyConfiguration) WithSigv4(value *Sigv4ApplyConfiguration) *RemoteWriteAuthorizationApplyConfiguration {
+ b.Sigv4 = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/remotewritespec.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/remotewritespec.go
new file mode 100644
index 0000000000..727c23a453
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/remotewritespec.go
@@ -0,0 +1,189 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ configv1alpha1 "github.com/openshift/api/config/v1alpha1"
+)
+
+// RemoteWriteSpecApplyConfiguration represents a declarative configuration of the RemoteWriteSpec type for use
+// with apply.
+//
+// RemoteWriteSpec represents configuration for remote write endpoints.
+type RemoteWriteSpecApplyConfiguration struct {
+ // url is the URL of the remote write endpoint.
+ // Must be a valid URL with http or https scheme and a non-empty hostname.
+ // Query parameters, fragments, and user information (e.g. user:password@host) are not allowed.
+ // Empty string is invalid. Must be between 1 and 2048 characters in length.
+ URL *string `json:"url,omitempty"`
+ // name is a required identifier for this remote write configuration (name is the list key for the remoteWrite list).
+ // This name is used in metrics and logging to differentiate remote write queues.
+ // Must contain only alphanumeric characters, hyphens, and underscores.
+ // Must be between 1 and 63 characters in length.
+ Name *string `json:"name,omitempty"`
+ // messageVersion defines the Remote Write message's version to use when writing to the endpoint.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The default value is "V1.0".
+ // When set to "V1.0", Prometheus uses the `prometheus.WriteRequest` protobuf message introduced in Remote Write 1.0.
+ // When set to "V2.0", Prometheus uses the `io.prometheus.write.v2.Request` protobuf message introduced in Remote Write 2.0.
+ MessageVersion *configv1alpha1.RemoteWriteMessageVersion `json:"messageVersion,omitempty"`
+ // authorization defines the authorization method for the remote write endpoint.
+ // When omitted, no authorization is performed.
+ // When set, type must be one of Authorization, BasicAuth, OAuth2, SigV4, or ServiceAccount; the corresponding nested config must be set (ServiceAccount has no config).
+ AuthorizationConfig *RemoteWriteAuthorizationApplyConfiguration `json:"authorization,omitempty"`
+ // headers specifies the custom HTTP headers to be sent along with each remote write request.
+ // Sending custom headers makes the configuration of a proxy in between optional and helps the
+ // receiver recognize the given source better.
+ // Clients MAY allow users to send custom HTTP headers; they MUST NOT allow users to configure
+ // them in such a way as to send reserved headers. Headers set by Prometheus cannot be overwritten.
+ // When omitted, no custom headers are sent.
+ // Maximum of 50 headers can be specified. Each header name must be unique.
+ // Each header name must contain only alphanumeric characters, hyphens, and underscores, and must not be a reserved Prometheus header (Host, Authorization, Content-Encoding, Content-Type, X-Prometheus-Remote-Write-Version, User-Agent, Connection, Keep-Alive, Proxy-Authenticate, Proxy-Authorization, WWW-Authenticate).
+ Headers []PrometheusRemoteWriteHeaderApplyConfiguration `json:"headers,omitempty"`
+ // metadataConfig configures the sending of series metadata to remote storage.
+ // When omitted, no metadata is sent.
+ // When set to sendPolicy: Default, metadata is sent using platform-chosen defaults (e.g. send interval 30 seconds).
+ // When set to sendPolicy: Custom, metadata is sent using the settings in the custom field (e.g. custom.sendIntervalSeconds).
+ MetadataConfig *MetadataConfigApplyConfiguration `json:"metadataConfig,omitempty"`
+ // proxyUrl defines an optional proxy URL.
+ // If the cluster-wide proxy is enabled, it replaces the proxyUrl setting.
+ // The cluster-wide proxy supports both HTTP and HTTPS proxies, with HTTPS taking precedence.
+ // When omitted, no proxy is used.
+ // Must be a valid URL with http or https scheme.
+ // Must be between 1 and 2048 characters in length.
+ ProxyURL *string `json:"proxyUrl,omitempty"`
+ // queueConfig allows tuning configuration for remote write queue parameters.
+ // When omitted, default queue configuration is used.
+ QueueConfig *QueueConfigApplyConfiguration `json:"queueConfig,omitempty"`
+ // remoteTimeoutSeconds defines the timeout in seconds for requests to the remote write endpoint.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // Minimum value is 1 second.
+ // Maximum value is 600 seconds (10 minutes).
+ RemoteTimeoutSeconds *int32 `json:"remoteTimeoutSeconds,omitempty"`
+ // exemplarsMode controls whether exemplars are sent via remote write.
+ // Valid values are "Send", "DoNotSend" and omitted.
+ // When set to "Send", Prometheus is configured to store a maximum of 100,000 exemplars in memory and send them with remote write.
+ // Note that this setting only applies to user-defined monitoring. It is not applicable to default in-cluster monitoring.
+ // When omitted or set to "DoNotSend", exemplars are not sent.
+ ExemplarsMode *configv1alpha1.ExemplarsMode `json:"exemplarsMode,omitempty"`
+ // tlsConfig defines TLS authentication settings for the remote write endpoint.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ TLSConfig *TLSConfigApplyConfiguration `json:"tlsConfig,omitempty"`
+ // writeRelabelConfigs is a list of relabeling rules to apply before sending data to the remote endpoint.
+ // When omitted, no relabeling is performed and all metrics are sent as-is.
+ // Minimum of 1 and maximum of 10 relabeling rules can be specified.
+ // Each rule must have a unique name.
+ WriteRelabelConfigs []RelabelConfigApplyConfiguration `json:"writeRelabelConfigs,omitempty"`
+}
+
+// RemoteWriteSpecApplyConfiguration constructs a declarative configuration of the RemoteWriteSpec type for use with
+// apply.
+func RemoteWriteSpec() *RemoteWriteSpecApplyConfiguration {
+ return &RemoteWriteSpecApplyConfiguration{}
+}
+
+// WithURL sets the URL field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the URL field is set to the value of the last call.
+func (b *RemoteWriteSpecApplyConfiguration) WithURL(value string) *RemoteWriteSpecApplyConfiguration {
+ b.URL = &value
+ return b
+}
+
+// WithName sets the Name field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Name field is set to the value of the last call.
+func (b *RemoteWriteSpecApplyConfiguration) WithName(value string) *RemoteWriteSpecApplyConfiguration {
+ b.Name = &value
+ return b
+}
+
+// WithMessageVersion sets the MessageVersion field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the MessageVersion field is set to the value of the last call.
+func (b *RemoteWriteSpecApplyConfiguration) WithMessageVersion(value configv1alpha1.RemoteWriteMessageVersion) *RemoteWriteSpecApplyConfiguration {
+ b.MessageVersion = &value
+ return b
+}
+
+// WithAuthorizationConfig sets the AuthorizationConfig field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the AuthorizationConfig field is set to the value of the last call.
+func (b *RemoteWriteSpecApplyConfiguration) WithAuthorizationConfig(value *RemoteWriteAuthorizationApplyConfiguration) *RemoteWriteSpecApplyConfiguration {
+ b.AuthorizationConfig = value
+ return b
+}
+
+// WithHeaders adds the given value to the Headers field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the Headers field.
+func (b *RemoteWriteSpecApplyConfiguration) WithHeaders(values ...*PrometheusRemoteWriteHeaderApplyConfiguration) *RemoteWriteSpecApplyConfiguration {
+ for i := range values {
+ if values[i] == nil {
+ panic("nil value passed to WithHeaders")
+ }
+ b.Headers = append(b.Headers, *values[i])
+ }
+ return b
+}
+
+// WithMetadataConfig sets the MetadataConfig field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the MetadataConfig field is set to the value of the last call.
+func (b *RemoteWriteSpecApplyConfiguration) WithMetadataConfig(value *MetadataConfigApplyConfiguration) *RemoteWriteSpecApplyConfiguration {
+ b.MetadataConfig = value
+ return b
+}
+
+// WithProxyURL sets the ProxyURL field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the ProxyURL field is set to the value of the last call.
+func (b *RemoteWriteSpecApplyConfiguration) WithProxyURL(value string) *RemoteWriteSpecApplyConfiguration {
+ b.ProxyURL = &value
+ return b
+}
+
+// WithQueueConfig sets the QueueConfig field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the QueueConfig field is set to the value of the last call.
+func (b *RemoteWriteSpecApplyConfiguration) WithQueueConfig(value *QueueConfigApplyConfiguration) *RemoteWriteSpecApplyConfiguration {
+ b.QueueConfig = value
+ return b
+}
+
+// WithRemoteTimeoutSeconds sets the RemoteTimeoutSeconds field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the RemoteTimeoutSeconds field is set to the value of the last call.
+func (b *RemoteWriteSpecApplyConfiguration) WithRemoteTimeoutSeconds(value int32) *RemoteWriteSpecApplyConfiguration {
+ b.RemoteTimeoutSeconds = &value
+ return b
+}
+
+// WithExemplarsMode sets the ExemplarsMode field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the ExemplarsMode field is set to the value of the last call.
+func (b *RemoteWriteSpecApplyConfiguration) WithExemplarsMode(value configv1alpha1.ExemplarsMode) *RemoteWriteSpecApplyConfiguration {
+ b.ExemplarsMode = &value
+ return b
+}
+
+// WithTLSConfig sets the TLSConfig field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the TLSConfig field is set to the value of the last call.
+func (b *RemoteWriteSpecApplyConfiguration) WithTLSConfig(value *TLSConfigApplyConfiguration) *RemoteWriteSpecApplyConfiguration {
+ b.TLSConfig = value
+ return b
+}
+
+// WithWriteRelabelConfigs adds the given value to the WriteRelabelConfigs field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the WriteRelabelConfigs field.
+func (b *RemoteWriteSpecApplyConfiguration) WithWriteRelabelConfigs(values ...*RelabelConfigApplyConfiguration) *RemoteWriteSpecApplyConfiguration {
+ for i := range values {
+ if values[i] == nil {
+ panic("nil value passed to WithWriteRelabelConfigs")
+ }
+ b.WriteRelabelConfigs = append(b.WriteRelabelConfigs, *values[i])
+ }
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/replaceactionconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/replaceactionconfig.go
new file mode 100644
index 0000000000..7b9766c11b
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/replaceactionconfig.go
@@ -0,0 +1,41 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+// ReplaceActionConfigApplyConfiguration represents a declarative configuration of the ReplaceActionConfig type for use
+// with apply.
+//
+// ReplaceActionConfig configures the Replace action.
+// Regex is matched against the concatenated source_labels; target_label is set to replacement with match group references (${1}, ${2}, ...) substituted. No replacement if regex does not match.
+type ReplaceActionConfigApplyConfiguration struct {
+ // targetLabel is the label name where the replacement result is written.
+ // Must be between 1 and 128 characters in length.
+ TargetLabel *string `json:"targetLabel,omitempty"`
+ // replacement is the value written to target_label when regex matches; match group references (${1}, ${2}, ...) are substituted.
+ // Required when using the Replace action so the intended behavior is explicit and the platform does not need to apply defaults.
+ // Use "$1" for the first capture group, "$2" for the second, etc. Use an empty string ("") to explicitly clear the target label value.
+ // Must be between 0 and 255 characters in length.
+ Replacement *string `json:"replacement,omitempty"`
+}
+
+// ReplaceActionConfigApplyConfiguration constructs a declarative configuration of the ReplaceActionConfig type for use with
+// apply.
+func ReplaceActionConfig() *ReplaceActionConfigApplyConfiguration {
+ return &ReplaceActionConfigApplyConfiguration{}
+}
+
+// WithTargetLabel sets the TargetLabel field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the TargetLabel field is set to the value of the last call.
+func (b *ReplaceActionConfigApplyConfiguration) WithTargetLabel(value string) *ReplaceActionConfigApplyConfiguration {
+ b.TargetLabel = &value
+ return b
+}
+
+// WithReplacement sets the Replacement field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Replacement field is set to the value of the last call.
+func (b *ReplaceActionConfigApplyConfiguration) WithReplacement(value string) *ReplaceActionConfigApplyConfiguration {
+ b.Replacement = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/retention.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/retention.go
new file mode 100644
index 0000000000..2c999b21da
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/retention.go
@@ -0,0 +1,54 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+// RetentionApplyConfiguration represents a declarative configuration of the Retention type for use
+// with apply.
+//
+// Retention configures how long Prometheus retains metrics data and how much storage it can use.
+type RetentionApplyConfiguration struct {
+ // duration is an optional field that specifies how long Prometheus retains metrics data.
+ // Valid values are Prometheus-style duration strings with unit suffixes y, w, d, h, m, s, or ms
+ // (for example, "15d", "24h", or "5d1h30m"). Each unit value must be a positive integer.
+ // Composite durations must follow the fixed unit order y, w, d, h, m, s, ms.
+ // Must be at least 1 character and at most 64 characters.
+ // When set to "0", time-based retention is disabled. This is the only supported form for disabling
+ // time-based retention; other zero-duration representations such as "0d", "0h", or "0y" are rejected.
+ // Prometheus automatically deletes data older than this duration.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The current default value is `15d`.
+ Duration *string `json:"duration,omitempty"`
+ // size is an optional field that specifies the maximum storage size that Prometheus
+ // can use for data blocks and the write-ahead log (WAL).
+ // Valid values are byte-size strings with an optional decimal prefix and a unit suffix B, KB, MB, GB,
+ // TB, EB, PB, or their binary equivalents KiB, MiB, GiB, TiB, EiB, PiB (for example, "500MiB", "10GiB").
+ // The numeric value must be greater than zero.
+ // Must be at least 1 character and at most 32 characters.
+ // When set to "0", no size limit is enforced. This is the only supported form for disabling size-based
+ // retention; other zero-size representations such as "0B" or "0MiB" are rejected.
+ // When the limit is reached, Prometheus deletes oldest data first.
+ // When omitted, no size limit is enforced and Prometheus uses available PersistentVolume capacity.
+ Size *string `json:"size,omitempty"`
+}
+
+// RetentionApplyConfiguration constructs a declarative configuration of the Retention type for use with
+// apply.
+func Retention() *RetentionApplyConfiguration {
+ return &RetentionApplyConfiguration{}
+}
+
+// WithDuration sets the Duration field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Duration field is set to the value of the last call.
+func (b *RetentionApplyConfiguration) WithDuration(value string) *RetentionApplyConfiguration {
+ b.Duration = &value
+ return b
+}
+
+// WithSize sets the Size field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Size field is set to the value of the last call.
+func (b *RetentionApplyConfiguration) WithSize(value string) *RetentionApplyConfiguration {
+ b.Size = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/secretkeyselector.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/secretkeyselector.go
new file mode 100644
index 0000000000..a824180eda
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/secretkeyselector.go
@@ -0,0 +1,40 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+// SecretKeySelectorApplyConfiguration represents a declarative configuration of the SecretKeySelector type for use
+// with apply.
+//
+// SecretKeySelector selects a key of a Secret in the `openshift-monitoring` namespace.
+type SecretKeySelectorApplyConfiguration struct {
+ // name is the name of the secret in the `openshift-monitoring` namespace to select from.
+ // Must be a valid Kubernetes secret name (lowercase alphanumeric, '-' or '.', start/end with alphanumeric).
+ // Must be between 1 and 253 characters in length.
+ Name *string `json:"name,omitempty"`
+ // key is the key of the secret to select from.
+ // Must consist of alphanumeric characters, '-', '_', or '.'.
+ // Must be between 1 and 253 characters in length.
+ Key *string `json:"key,omitempty"`
+}
+
+// SecretKeySelectorApplyConfiguration constructs a declarative configuration of the SecretKeySelector type for use with
+// apply.
+func SecretKeySelector() *SecretKeySelectorApplyConfiguration {
+ return &SecretKeySelectorApplyConfiguration{}
+}
+
+// WithName sets the Name field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Name field is set to the value of the last call.
+func (b *SecretKeySelectorApplyConfiguration) WithName(value string) *SecretKeySelectorApplyConfiguration {
+ b.Name = &value
+ return b
+}
+
+// WithKey sets the Key field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Key field is set to the value of the last call.
+func (b *SecretKeySelectorApplyConfiguration) WithKey(value string) *SecretKeySelectorApplyConfiguration {
+ b.Key = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/sigv4.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/sigv4.go
new file mode 100644
index 0000000000..e0e37c4fdb
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/sigv4.go
@@ -0,0 +1,78 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+// Sigv4ApplyConfiguration represents a declarative configuration of the Sigv4 type for use
+// with apply.
+//
+// Sigv4 defines AWS Signature Version 4 authentication settings.
+// At least one of region, accessKey/secretKey, profile, or roleArn must be set so the platform can perform authentication.
+type Sigv4ApplyConfiguration struct {
+ // region is the AWS region.
+ // When omitted, the region is derived from the environment or instance metadata.
+ // Must be between 1 and 128 characters.
+ Region *string `json:"region,omitempty"`
+ // accessKey defines the secret reference containing the AWS access key ID.
+ // The secret must exist in the openshift-monitoring namespace.
+ // When omitted, the access key is derived from the environment or instance metadata.
+ AccessKey *SecretKeySelectorApplyConfiguration `json:"accessKey,omitempty"`
+ // secretKey defines the secret reference containing the AWS secret access key.
+ // The secret must exist in the openshift-monitoring namespace.
+ // When omitted, the secret key is derived from the environment or instance metadata.
+ SecretKey *SecretKeySelectorApplyConfiguration `json:"secretKey,omitempty"`
+ // profile is the named AWS profile used to authenticate.
+ // When omitted, the default profile is used.
+ // Must be between 1 and 128 characters.
+ Profile *string `json:"profile,omitempty"`
+ // roleArn is the AWS Role ARN, an alternative to using AWS API keys.
+ // When omitted, API keys are used for authentication.
+ // Must be a valid AWS ARN format (e.g., "arn:aws:iam::123456789012:role/MyRole").
+ // Must be between 1 and 512 characters.
+ RoleArn *string `json:"roleArn,omitempty"`
+}
+
+// Sigv4ApplyConfiguration constructs a declarative configuration of the Sigv4 type for use with
+// apply.
+func Sigv4() *Sigv4ApplyConfiguration {
+ return &Sigv4ApplyConfiguration{}
+}
+
+// WithRegion sets the Region field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Region field is set to the value of the last call.
+func (b *Sigv4ApplyConfiguration) WithRegion(value string) *Sigv4ApplyConfiguration {
+ b.Region = &value
+ return b
+}
+
+// WithAccessKey sets the AccessKey field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the AccessKey field is set to the value of the last call.
+func (b *Sigv4ApplyConfiguration) WithAccessKey(value *SecretKeySelectorApplyConfiguration) *Sigv4ApplyConfiguration {
+ b.AccessKey = value
+ return b
+}
+
+// WithSecretKey sets the SecretKey field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the SecretKey field is set to the value of the last call.
+func (b *Sigv4ApplyConfiguration) WithSecretKey(value *SecretKeySelectorApplyConfiguration) *Sigv4ApplyConfiguration {
+ b.SecretKey = value
+ return b
+}
+
+// WithProfile sets the Profile field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Profile field is set to the value of the last call.
+func (b *Sigv4ApplyConfiguration) WithProfile(value string) *Sigv4ApplyConfiguration {
+ b.Profile = &value
+ return b
+}
+
+// WithRoleArn sets the RoleArn field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the RoleArn field is set to the value of the last call.
+func (b *Sigv4ApplyConfiguration) WithRoleArn(value string) *Sigv4ApplyConfiguration {
+ b.RoleArn = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/telemeterclientconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/telemeterclientconfig.go
new file mode 100644
index 0000000000..9d4c5cc331
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/telemeterclientconfig.go
@@ -0,0 +1,118 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ v1 "k8s.io/api/core/v1"
+)
+
+// TelemeterClientConfigApplyConfiguration represents a declarative configuration of the TelemeterClientConfig type for use
+// with apply.
+//
+// TelemeterClientConfig provides configuration options for the Telemeter Client component
+// that runs in the `openshift-monitoring` namespace. The Telemeter Client collects selected
+// monitoring metrics and forwards them to Red Hat for telemetry purposes.
+// At least one field must be specified.
+type TelemeterClientConfigApplyConfiguration struct {
+ // nodeSelector defines the nodes on which the Pods are scheduled.
+ // nodeSelector is optional.
+ //
+ // When omitted, this means the user has no opinion and the platform is left
+ // to choose reasonable defaults. These defaults are subject to change over time.
+ // The current default value is `kubernetes.io/os: linux`.
+ // When specified, nodeSelector must contain at least 1 entry and must not contain more than 10 entries.
+ NodeSelector map[string]string `json:"nodeSelector,omitempty"`
+ // resources defines the compute resource requests and limits for the Telemeter Client container.
+ // This includes CPU, memory and HugePages constraints to help control scheduling and resource usage.
+ // When not specified, defaults are used by the platform. Requests cannot exceed limits.
+ // This field is optional.
+ // More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/
+ // This is a simplified API that maps to Kubernetes ResourceRequirements.
+ // The current default values are:
+ // resources:
+ // - name: cpu
+ // request: 1m
+ // limit: null
+ // - name: memory
+ // request: 40Mi
+ // limit: null
+ // Maximum length for this list is 5.
+ // Minimum length for this list is 1.
+ // Each resource name must be unique within this list.
+ Resources []ContainerResourceApplyConfiguration `json:"resources,omitempty"`
+ // tolerations defines tolerations for the pods.
+ // tolerations is optional.
+ //
+ // When omitted, this means the user has no opinion and the platform is left
+ // to choose reasonable defaults. These defaults are subject to change over time.
+ // Defaults are empty/unset.
+ // Maximum length for this list is 10.
+ // Minimum length for this list is 1.
+ Tolerations []v1.Toleration `json:"tolerations,omitempty"`
+ // topologySpreadConstraints defines rules for how Telemeter Client Pods should be distributed
+ // across topology domains such as zones, nodes, or other user-defined labels.
+ // topologySpreadConstraints is optional.
+ // This helps improve high availability and resource efficiency by avoiding placing
+ // too many replicas in the same failure domain.
+ //
+ // When omitted, this means no opinion and the platform is left to choose a default, which is subject to change over time.
+ // This field maps directly to the `topologySpreadConstraints` field in the Pod spec.
+ // Default is empty list.
+ // Maximum length for this list is 10.
+ // Minimum length for this list is 1.
+ // Entries must have unique topologyKey and whenUnsatisfiable pairs.
+ TopologySpreadConstraints []v1.TopologySpreadConstraint `json:"topologySpreadConstraints,omitempty"`
+}
+
+// TelemeterClientConfigApplyConfiguration constructs a declarative configuration of the TelemeterClientConfig type for use with
+// apply.
+func TelemeterClientConfig() *TelemeterClientConfigApplyConfiguration {
+ return &TelemeterClientConfigApplyConfiguration{}
+}
+
+// WithNodeSelector puts the entries into the NodeSelector field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, the entries provided by each call will be put on the NodeSelector field,
+// overwriting an existing map entries in NodeSelector field with the same key.
+func (b *TelemeterClientConfigApplyConfiguration) WithNodeSelector(entries map[string]string) *TelemeterClientConfigApplyConfiguration {
+ if b.NodeSelector == nil && len(entries) > 0 {
+ b.NodeSelector = make(map[string]string, len(entries))
+ }
+ for k, v := range entries {
+ b.NodeSelector[k] = v
+ }
+ return b
+}
+
+// WithResources adds the given value to the Resources field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the Resources field.
+func (b *TelemeterClientConfigApplyConfiguration) WithResources(values ...*ContainerResourceApplyConfiguration) *TelemeterClientConfigApplyConfiguration {
+ for i := range values {
+ if values[i] == nil {
+ panic("nil value passed to WithResources")
+ }
+ b.Resources = append(b.Resources, *values[i])
+ }
+ return b
+}
+
+// WithTolerations adds the given value to the Tolerations field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the Tolerations field.
+func (b *TelemeterClientConfigApplyConfiguration) WithTolerations(values ...v1.Toleration) *TelemeterClientConfigApplyConfiguration {
+ for i := range values {
+ b.Tolerations = append(b.Tolerations, values[i])
+ }
+ return b
+}
+
+// WithTopologySpreadConstraints adds the given value to the TopologySpreadConstraints field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the TopologySpreadConstraints field.
+func (b *TelemeterClientConfigApplyConfiguration) WithTopologySpreadConstraints(values ...v1.TopologySpreadConstraint) *TelemeterClientConfigApplyConfiguration {
+ for i := range values {
+ b.TopologySpreadConstraints = append(b.TopologySpreadConstraints, values[i])
+ }
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/thanosquerierconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/thanosquerierconfig.go
new file mode 100644
index 0000000000..9210a0a308
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/thanosquerierconfig.go
@@ -0,0 +1,167 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ configv1alpha1 "github.com/openshift/api/config/v1alpha1"
+ v1 "k8s.io/api/core/v1"
+)
+
+// ThanosQuerierConfigApplyConfiguration represents a declarative configuration of the ThanosQuerierConfig type for use
+// with apply.
+//
+// ThanosQuerierConfig provides configuration options for the Thanos Querier component
+// that runs in the `openshift-monitoring` namespace.
+// At least one field must be specified; an empty thanosQuerierConfig object is not allowed.
+type ThanosQuerierConfigApplyConfiguration struct {
+ // logLevel defines the verbosity of logs emitted by Thanos Querier.
+ // logLevel is optional.
+ // Allowed values are Error, Warn, Info, and Debug.
+ // When set to Error, only errors will be logged.
+ // When set to Warn, both warnings and errors will be logged.
+ // When set to Info, general information, warnings, and errors will all be logged.
+ // When set to Debug, detailed debugging information will be logged.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, that is subject to change over time.
+ // The current default value is `Info`.
+ LogLevel *configv1alpha1.LogLevel `json:"logLevel,omitempty"`
+ // requestLogging configures request logging for Thanos Querier.
+ // requestLogging is optional.
+ // When provided, the policy field within is required.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, that is subject to change over time.
+ // The current default behavior is to not log any requests.
+ RequestLogging *ThanosQuerierRequestLoggingConfigApplyConfiguration `json:"requestLogging,omitempty"`
+ // crossOriginRequestPolicy configures the CORS (Cross-Origin Resource Sharing) policy
+ // for Thanos Querier's HTTP endpoints.
+ // crossOriginRequestPolicy is optional.
+ // Valid values are "AllowAll" and "DenyAll".
+ // When set to "AllowAll", CORS headers are added to responses, allowing cross-origin requests from any domain.
+ // When set to "DenyAll", no CORS headers are added and cross-origin requests are rejected by the browser.
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, that is subject to change over time.
+ // The current default value is "DenyAll".
+ CrossOriginRequestPolicy *configv1alpha1.CrossOriginRequestPolicy `json:"crossOriginRequestPolicy,omitempty"`
+ // nodeSelector defines the nodes on which the Pods are scheduled.
+ // nodeSelector is optional.
+ //
+ // When omitted, this means the user has no opinion and the platform is left
+ // to choose reasonable defaults. These defaults are subject to change over time.
+ // The current default value is `kubernetes.io/os: linux`.
+ // When specified, nodeSelector must contain at least 1 entry and must not contain more than 10 entries.
+ NodeSelector map[string]string `json:"nodeSelector,omitempty"`
+ // resources defines the compute resource requests and limits for the Thanos Querier container.
+ // resources is optional.
+ //
+ // When omitted, this means the user has no opinion and the platform is left
+ // to choose reasonable defaults. These defaults are subject to change over time.
+ // Requests cannot exceed limits.
+ // More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/
+ // This is a simplified API that maps to Kubernetes ResourceRequirements.
+ // The current default values are:
+ // resources:
+ // - name: cpu
+ // request: 5m
+ // - name: memory
+ // request: 12Mi
+ // Maximum length for this list is 5.
+ // Minimum length for this list is 1.
+ // Each resource name must be unique within this list.
+ Resources []ContainerResourceApplyConfiguration `json:"resources,omitempty"`
+ // tolerations defines tolerations for the pods.
+ // tolerations is optional.
+ //
+ // When omitted, this means the user has no opinion and the platform is left
+ // to choose reasonable defaults. These defaults are subject to change over time.
+ // Defaults are empty/unset.
+ // Maximum length for this list is 10.
+ // Minimum length for this list is 1.
+ Tolerations []v1.Toleration `json:"tolerations,omitempty"`
+ // topologySpreadConstraints defines rules for how Thanos Querier Pods should be distributed
+ // across topology domains such as zones, nodes, or other user-defined labels.
+ // topologySpreadConstraints is optional.
+ // This helps improve high availability and resource efficiency by avoiding placing
+ // too many replicas in the same failure domain.
+ //
+ // When omitted, this means no opinion and the platform is left to choose a default, which is subject to change over time.
+ // This field maps directly to the `topologySpreadConstraints` field in the Pod spec.
+ // Defaults are empty/unset.
+ // Maximum length for this list is 10.
+ // Minimum length for this list is 1.
+ // Entries must have unique topologyKey and whenUnsatisfiable pairs.
+ TopologySpreadConstraints []v1.TopologySpreadConstraint `json:"topologySpreadConstraints,omitempty"`
+}
+
+// ThanosQuerierConfigApplyConfiguration constructs a declarative configuration of the ThanosQuerierConfig type for use with
+// apply.
+func ThanosQuerierConfig() *ThanosQuerierConfigApplyConfiguration {
+ return &ThanosQuerierConfigApplyConfiguration{}
+}
+
+// WithLogLevel sets the LogLevel field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the LogLevel field is set to the value of the last call.
+func (b *ThanosQuerierConfigApplyConfiguration) WithLogLevel(value configv1alpha1.LogLevel) *ThanosQuerierConfigApplyConfiguration {
+ b.LogLevel = &value
+ return b
+}
+
+// WithRequestLogging sets the RequestLogging field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the RequestLogging field is set to the value of the last call.
+func (b *ThanosQuerierConfigApplyConfiguration) WithRequestLogging(value *ThanosQuerierRequestLoggingConfigApplyConfiguration) *ThanosQuerierConfigApplyConfiguration {
+ b.RequestLogging = value
+ return b
+}
+
+// WithCrossOriginRequestPolicy sets the CrossOriginRequestPolicy field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the CrossOriginRequestPolicy field is set to the value of the last call.
+func (b *ThanosQuerierConfigApplyConfiguration) WithCrossOriginRequestPolicy(value configv1alpha1.CrossOriginRequestPolicy) *ThanosQuerierConfigApplyConfiguration {
+ b.CrossOriginRequestPolicy = &value
+ return b
+}
+
+// WithNodeSelector puts the entries into the NodeSelector field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, the entries provided by each call will be put on the NodeSelector field,
+// overwriting an existing map entries in NodeSelector field with the same key.
+func (b *ThanosQuerierConfigApplyConfiguration) WithNodeSelector(entries map[string]string) *ThanosQuerierConfigApplyConfiguration {
+ if b.NodeSelector == nil && len(entries) > 0 {
+ b.NodeSelector = make(map[string]string, len(entries))
+ }
+ for k, v := range entries {
+ b.NodeSelector[k] = v
+ }
+ return b
+}
+
+// WithResources adds the given value to the Resources field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the Resources field.
+func (b *ThanosQuerierConfigApplyConfiguration) WithResources(values ...*ContainerResourceApplyConfiguration) *ThanosQuerierConfigApplyConfiguration {
+ for i := range values {
+ if values[i] == nil {
+ panic("nil value passed to WithResources")
+ }
+ b.Resources = append(b.Resources, *values[i])
+ }
+ return b
+}
+
+// WithTolerations adds the given value to the Tolerations field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the Tolerations field.
+func (b *ThanosQuerierConfigApplyConfiguration) WithTolerations(values ...v1.Toleration) *ThanosQuerierConfigApplyConfiguration {
+ for i := range values {
+ b.Tolerations = append(b.Tolerations, values[i])
+ }
+ return b
+}
+
+// WithTopologySpreadConstraints adds the given value to the TopologySpreadConstraints field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the TopologySpreadConstraints field.
+func (b *ThanosQuerierConfigApplyConfiguration) WithTopologySpreadConstraints(values ...v1.TopologySpreadConstraint) *ThanosQuerierConfigApplyConfiguration {
+ for i := range values {
+ b.TopologySpreadConstraints = append(b.TopologySpreadConstraints, values[i])
+ }
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/thanosquerierrequestloggingconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/thanosquerierrequestloggingconfig.go
new file mode 100644
index 0000000000..d9a6264426
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/thanosquerierrequestloggingconfig.go
@@ -0,0 +1,34 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ configv1alpha1 "github.com/openshift/api/config/v1alpha1"
+)
+
+// ThanosQuerierRequestLoggingConfigApplyConfiguration represents a declarative configuration of the ThanosQuerierRequestLoggingConfig type for use
+// with apply.
+//
+// ThanosQuerierRequestLoggingConfig configures request logging for Thanos Querier.
+type ThanosQuerierRequestLoggingConfigApplyConfiguration struct {
+ // policy determines which HTTP and gRPC requests are logged by Thanos Querier.
+ // Valid values are "AllRequests" and "NoRequests".
+ // When set to "AllRequests", every request received by Thanos Querier is logged with method, path, and response status.
+ // The log level for request logs is derived from the logLevel field.
+ // When set to "NoRequests", request logging is turned off.
+ Policy *configv1alpha1.RequestLoggingPolicy `json:"policy,omitempty"`
+}
+
+// ThanosQuerierRequestLoggingConfigApplyConfiguration constructs a declarative configuration of the ThanosQuerierRequestLoggingConfig type for use with
+// apply.
+func ThanosQuerierRequestLoggingConfig() *ThanosQuerierRequestLoggingConfigApplyConfiguration {
+ return &ThanosQuerierRequestLoggingConfigApplyConfiguration{}
+}
+
+// WithPolicy sets the Policy field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Policy field is set to the value of the last call.
+func (b *ThanosQuerierRequestLoggingConfigApplyConfiguration) WithPolicy(value configv1alpha1.RequestLoggingPolicy) *ThanosQuerierRequestLoggingConfigApplyConfiguration {
+ b.Policy = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/tlsconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/tlsconfig.go
new file mode 100644
index 0000000000..dc74026618
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/tlsconfig.go
@@ -0,0 +1,81 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ configv1alpha1 "github.com/openshift/api/config/v1alpha1"
+)
+
+// TLSConfigApplyConfiguration represents a declarative configuration of the TLSConfig type for use
+// with apply.
+//
+// TLSConfig represents TLS configuration for Alertmanager connections.
+// At least one TLS configuration option must be specified.
+// For mutual TLS (mTLS), both cert and key must be specified together, or both omitted.
+type TLSConfigApplyConfiguration struct {
+ // ca is an optional CA certificate to use for TLS connections.
+ // When omitted, the system's default CA bundle is used.
+ CA *SecretKeySelectorApplyConfiguration `json:"ca,omitempty"`
+ // cert is an optional client certificate to use for mutual TLS connections.
+ // When omitted, no client certificate is presented.
+ Cert *SecretKeySelectorApplyConfiguration `json:"cert,omitempty"`
+ // key is an optional client key to use for mutual TLS connections.
+ // When omitted, no client key is used.
+ Key *SecretKeySelectorApplyConfiguration `json:"key,omitempty"`
+ // serverName is an optional server name to use for TLS connections.
+ // When specified, must be a valid DNS subdomain as per RFC 1123.
+ // When omitted, the server name is derived from the URL.
+ // Must be between 1 and 253 characters in length.
+ ServerName *string `json:"serverName,omitempty"`
+ // certificateVerification determines the policy for TLS certificate verification.
+ // Allowed values are "Verify" (performs certificate verification, secure) and "SkipVerify" (skips verification, insecure).
+ // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time.
+ // The default value is "Verify".
+ CertificateVerification *configv1alpha1.CertificateVerificationType `json:"certificateVerification,omitempty"`
+}
+
+// TLSConfigApplyConfiguration constructs a declarative configuration of the TLSConfig type for use with
+// apply.
+func TLSConfig() *TLSConfigApplyConfiguration {
+ return &TLSConfigApplyConfiguration{}
+}
+
+// WithCA sets the CA field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the CA field is set to the value of the last call.
+func (b *TLSConfigApplyConfiguration) WithCA(value *SecretKeySelectorApplyConfiguration) *TLSConfigApplyConfiguration {
+ b.CA = value
+ return b
+}
+
+// WithCert sets the Cert field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Cert field is set to the value of the last call.
+func (b *TLSConfigApplyConfiguration) WithCert(value *SecretKeySelectorApplyConfiguration) *TLSConfigApplyConfiguration {
+ b.Cert = value
+ return b
+}
+
+// WithKey sets the Key field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Key field is set to the value of the last call.
+func (b *TLSConfigApplyConfiguration) WithKey(value *SecretKeySelectorApplyConfiguration) *TLSConfigApplyConfiguration {
+ b.Key = value
+ return b
+}
+
+// WithServerName sets the ServerName field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the ServerName field is set to the value of the last call.
+func (b *TLSConfigApplyConfiguration) WithServerName(value string) *TLSConfigApplyConfiguration {
+ b.ServerName = &value
+ return b
+}
+
+// WithCertificateVerification sets the CertificateVerification field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the CertificateVerification field is set to the value of the last call.
+func (b *TLSConfigApplyConfiguration) WithCertificateVerification(value configv1alpha1.CertificateVerificationType) *TLSConfigApplyConfiguration {
+ b.CertificateVerification = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/uppercaseactionconfig.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/uppercaseactionconfig.go
new file mode 100644
index 0000000000..6d3a6a804a
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/uppercaseactionconfig.go
@@ -0,0 +1,29 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+// UppercaseActionConfigApplyConfiguration represents a declarative configuration of the UppercaseActionConfig type for use
+// with apply.
+//
+// UppercaseActionConfig configures the Uppercase action.
+// Maps the concatenated source_labels to their upper case and writes to target_label.
+// Requires Prometheus >= v2.36.0.
+type UppercaseActionConfigApplyConfiguration struct {
+ // targetLabel is the label name where the upper-cased value is written.
+ // Must be between 1 and 128 characters in length.
+ TargetLabel *string `json:"targetLabel,omitempty"`
+}
+
+// UppercaseActionConfigApplyConfiguration constructs a declarative configuration of the UppercaseActionConfig type for use with
+// apply.
+func UppercaseActionConfig() *UppercaseActionConfigApplyConfiguration {
+ return &UppercaseActionConfigApplyConfiguration{}
+}
+
+// WithTargetLabel sets the TargetLabel field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the TargetLabel field is set to the value of the last call.
+func (b *UppercaseActionConfigApplyConfiguration) WithTargetLabel(value string) *UppercaseActionConfigApplyConfiguration {
+ b.TargetLabel = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/internal/internal.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/internal/internal.go
index 8c2fd43b21..12c03ff097 100644
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/internal/internal.go
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/internal/internal.go
@@ -49,7 +49,8 @@ var schemaYAML = typed.YAMLObject(`types:
fields:
- name: kms
type:
- namedType: com.github.openshift.api.config.v1.KMSConfig
+ namedType: com.github.openshift.api.config.v1.KMSPluginConfig
+ default: {}
- name: type
type:
scalar: string
@@ -105,6 +106,9 @@ var schemaYAML = typed.YAMLObject(`types:
type:
namedType: com.github.openshift.api.config.v1.APIServerServingCerts
default: {}
+ - name: tlsAdherence
+ type:
+ scalar: string
- name: tlsSecurityProfile
type:
namedType: com.github.openshift.api.config.v1.TLSSecurityProfile
@@ -136,17 +140,6 @@ var schemaYAML = typed.YAMLObject(`types:
default: ""
unions:
- discriminator: type
-- name: com.github.openshift.api.config.v1.AWSKMSConfig
- map:
- fields:
- - name: keyARN
- type:
- scalar: string
- default: ""
- - name: region
- type:
- scalar: string
- default: ""
- name: com.github.openshift.api.config.v1.AWSPlatformSpec
map:
fields:
@@ -469,6 +462,9 @@ var schemaYAML = typed.YAMLObject(`types:
- name: nodeDNSIP
type:
scalar: string
+ - name: vipManagement
+ type:
+ scalar: string
- name: com.github.openshift.api.config.v1.BasicAuthIdentityProvider
map:
fields:
@@ -568,6 +564,75 @@ var schemaYAML = typed.YAMLObject(`types:
type:
namedType: com.github.openshift.api.config.v1.BuildOverrides
default: {}
+- name: com.github.openshift.api.config.v1.CRIOCredentialProviderConfig
+ map:
+ fields:
+ - name: apiVersion
+ type:
+ scalar: string
+ - name: kind
+ type:
+ scalar: string
+ - name: metadata
+ type:
+ namedType: io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta
+ default: {}
+ - name: spec
+ type:
+ namedType: com.github.openshift.api.config.v1.CRIOCredentialProviderConfigSpec
+ - name: status
+ type:
+ namedType: com.github.openshift.api.config.v1.CRIOCredentialProviderConfigStatus
+ default: {}
+- name: com.github.openshift.api.config.v1.CRIOCredentialProviderConfigSpec
+ map:
+ fields:
+ - name: matchImages
+ type:
+ list:
+ elementType:
+ scalar: string
+ elementRelationship: associative
+- name: com.github.openshift.api.config.v1.CRIOCredentialProviderConfigStatus
+ map:
+ fields:
+ - name: conditions
+ type:
+ list:
+ elementType:
+ namedType: io.k8s.apimachinery.pkg.apis.meta.v1.Condition
+ elementRelationship: associative
+ keys:
+ - type
+- name: com.github.openshift.api.config.v1.ClientCredentialConfig
+ map:
+ fields:
+ - name: clientID
+ type:
+ scalar: string
+ - name: clientSecret
+ type:
+ namedType: com.github.openshift.api.config.v1.ClientSecretSecretReference
+ default: {}
+ - name: scopes
+ type:
+ list:
+ elementType:
+ scalar: string
+ elementRelationship: associative
+ - name: tls
+ type:
+ namedType: com.github.openshift.api.config.v1.ExternalSourceTLS
+ default: {}
+ - name: tokenEndpoint
+ type:
+ scalar: string
+- name: com.github.openshift.api.config.v1.ClientSecretSecretReference
+ map:
+ fields:
+ - name: name
+ type:
+ scalar: string
- name: com.github.openshift.api.config.v1.CloudControllerManagerStatus
map:
fields:
@@ -924,6 +989,12 @@ var schemaYAML = typed.YAMLObject(`types:
type:
scalar: string
default: ""
+ - name: labels
+ type:
+ map:
+ elementType:
+ scalar: string
+ elementRelationship: separable
- name: name
type:
scalar: string
@@ -1128,6 +1199,12 @@ var schemaYAML = typed.YAMLObject(`types:
elementType:
scalar: string
elementRelationship: atomic
+ - name: groups
+ type:
+ list:
+ elementType:
+ scalar: string
+ elementRelationship: associative
- name: minTLSVersion
type:
scalar: string
@@ -1236,6 +1313,37 @@ var schemaYAML = typed.YAMLObject(`types:
- name: ingressIP
type:
scalar: string
+- name: com.github.openshift.api.config.v1.ExternalClaimsSource
+ map:
+ fields:
+ - name: authentication
+ type:
+ namedType: com.github.openshift.api.config.v1.ExternalSourceAuthentication
+ default: {}
+ - name: mappings
+ type:
+ list:
+ elementType:
+ namedType: com.github.openshift.api.config.v1.SourcedClaimMapping
+ elementRelationship: associative
+ keys:
+ - name
+ - name: predicates
+ type:
+ list:
+ elementType:
+ namedType: com.github.openshift.api.config.v1.ExternalSourcePredicate
+ elementRelationship: associative
+ keys:
+ - expression
+ - name: tls
+ type:
+ namedType: com.github.openshift.api.config.v1.ExternalSourceTLS
+ default: {}
+ - name: url
+ type:
+ namedType: com.github.openshift.api.config.v1.SourceURL
+ default: {}
- name: com.github.openshift.api.config.v1.ExternalIPConfig
map:
fields:
@@ -1277,6 +1385,35 @@ var schemaYAML = typed.YAMLObject(`types:
type:
namedType: com.github.openshift.api.config.v1.CloudControllerManagerStatus
default: {}
+- name: com.github.openshift.api.config.v1.ExternalSourceAuthentication
+ map:
+ fields:
+ - name: clientCredential
+ type:
+ namedType: com.github.openshift.api.config.v1.ClientCredentialConfig
+ default: {}
+ - name: type
+ type:
+ scalar: string
+- name: com.github.openshift.api.config.v1.ExternalSourceCertificateAuthorityConfigMapReference
+ map:
+ fields:
+ - name: name
+ type:
+ scalar: string
+- name: com.github.openshift.api.config.v1.ExternalSourcePredicate
+ map:
+ fields:
+ - name: expression
+ type:
+ scalar: string
+- name: com.github.openshift.api.config.v1.ExternalSourceTLS
+ map:
+ fields:
+ - name: certificateAuthority
+ type:
+ namedType: com.github.openshift.api.config.v1.ExternalSourceCertificateAuthorityConfigMapReference
+ default: {}
- name: com.github.openshift.api.config.v1.ExtraMapping
map:
fields:
@@ -1412,6 +1549,9 @@ var schemaYAML = typed.YAMLObject(`types:
elementRelationship: associative
keys:
- key
+ - name: universeDomain
+ type:
+ scalar: string
- name: com.github.openshift.api.config.v1.GCPResourceLabel
map:
fields:
@@ -1565,9 +1705,17 @@ var schemaYAML = typed.YAMLObject(`types:
- name: com.github.openshift.api.config.v1.HubSourceStatus
map:
fields:
+ - name: disabled
+ type:
+ scalar: boolean
+ default: false
- name: message
type:
scalar: string
+ - name: name
+ type:
+ scalar: string
+ default: ""
- name: status
type:
scalar: string
@@ -1995,6 +2143,9 @@ var schemaYAML = typed.YAMLObject(`types:
type:
namedType: com.github.openshift.api.config.v1.ConfigMapFileReference
default: {}
+ - name: controlPlaneTopology
+ type:
+ scalar: string
- name: platformSpec
type:
namedType: com.github.openshift.api.config.v1.PlatformSpec
@@ -2152,21 +2303,22 @@ var schemaYAML = typed.YAMLObject(`types:
elementType:
namedType: __untyped_deduced_
elementRelationship: separable
-- name: com.github.openshift.api.config.v1.KMSConfig
+- name: com.github.openshift.api.config.v1.KMSPluginConfig
map:
fields:
- - name: aws
- type:
- namedType: com.github.openshift.api.config.v1.AWSKMSConfig
- name: type
type:
scalar: string
default: ""
+ - name: vault
+ type:
+ namedType: com.github.openshift.api.config.v1.VaultKMSPluginConfig
+ default: {}
unions:
- discriminator: type
fields:
- - fieldName: aws
- discriminatorValue: AWS
+ - fieldName: vault
+ discriminatorValue: Vault
- name: com.github.openshift.api.config.v1.KeystoneIdentityProvider
map:
fields:
@@ -2384,6 +2536,12 @@ var schemaYAML = typed.YAMLObject(`types:
- name: networkType
type:
scalar: string
+- name: com.github.openshift.api.config.v1.NetworkObservabilitySpec
+ map:
+ fields:
+ - name: installationPolicy
+ type:
+ scalar: string
- name: com.github.openshift.api.config.v1.NetworkSpec
map:
fields:
@@ -2400,6 +2558,10 @@ var schemaYAML = typed.YAMLObject(`types:
type:
namedType: com.github.openshift.api.config.v1.NetworkDiagnostics
default: {}
+ - name: networkObservability
+ type:
+ namedType: com.github.openshift.api.config.v1.NetworkObservabilitySpec
+ default: {}
- name: networkType
type:
scalar: string
@@ -2762,6 +2924,12 @@ var schemaYAML = typed.YAMLObject(`types:
elementType:
namedType: com.github.openshift.api.config.v1.TokenClaimValidationRule
elementRelationship: atomic
+ - name: externalClaimsSources
+ type:
+ list:
+ elementType:
+ namedType: com.github.openshift.api.config.v1.ExternalClaimsSource
+ elementRelationship: atomic
- name: issuer
type:
namedType: com.github.openshift.api.config.v1.TokenIssuer
@@ -3645,6 +3813,24 @@ var schemaYAML = typed.YAMLObject(`types:
type:
scalar: string
default: ""
+- name: com.github.openshift.api.config.v1.SourceURL
+ map:
+ fields:
+ - name: hostname
+ type:
+ scalar: string
+ - name: pathExpression
+ type:
+ scalar: string
+- name: com.github.openshift.api.config.v1.SourcedClaimMapping
+ map:
+ fields:
+ - name: expression
+ type:
+ scalar: string
+ - name: name
+ type:
+ scalar: string
- name: com.github.openshift.api.config.v1.Storage
map:
fields:
@@ -3826,6 +4012,9 @@ var schemaYAML = typed.YAMLObject(`types:
type:
scalar: string
default: ""
+ - name: mode
+ type:
+ scalar: string
- name: version
type:
scalar: string
@@ -4119,6 +4308,76 @@ var schemaYAML = typed.YAMLObject(`types:
type:
scalar: string
default: ""
+- name: com.github.openshift.api.config.v1.VaultAppRoleAuthentication
+ map:
+ fields:
+ - name: secret
+ type:
+ namedType: com.github.openshift.api.config.v1.VaultSecretReference
+ default: {}
+- name: com.github.openshift.api.config.v1.VaultAuthentication
+ map:
+ fields:
+ - name: appRole
+ type:
+ namedType: com.github.openshift.api.config.v1.VaultAppRoleAuthentication
+ default: {}
+ - name: type
+ type:
+ scalar: string
+ unions:
+ - discriminator: type
+ fields:
+ - fieldName: appRole
+ discriminatorValue: AppRole
+- name: com.github.openshift.api.config.v1.VaultConfigMapReference
+ map:
+ fields:
+ - name: name
+ type:
+ scalar: string
+- name: com.github.openshift.api.config.v1.VaultKMSPluginConfig
+ map:
+ fields:
+ - name: authentication
+ type:
+ namedType: com.github.openshift.api.config.v1.VaultAuthentication
+ default: {}
+ - name: kmsPluginImage
+ type:
+ scalar: string
+ - name: tls
+ type:
+ namedType: com.github.openshift.api.config.v1.VaultTLSConfig
+ default: {}
+ - name: vaultAddress
+ type:
+ scalar: string
+ - name: vaultAuthNamespace
+ type:
+ scalar: string
+ - name: vaultKeyPath
+ type:
+ scalar: string
+ - name: vaultNamespace
+ type:
+ scalar: string
+- name: com.github.openshift.api.config.v1.VaultSecretReference
+ map:
+ fields:
+ - name: name
+ type:
+ scalar: string
+- name: com.github.openshift.api.config.v1.VaultTLSConfig
+ map:
+ fields:
+ - name: caBundle
+ type:
+ namedType: com.github.openshift.api.config.v1.VaultConfigMapReference
+ default: {}
+ - name: serverName
+ type:
+ scalar: string
- name: com.github.openshift.api.config.v1.WebhookTokenAuthenticator
map:
fields:
@@ -4126,6 +4385,35 @@ var schemaYAML = typed.YAMLObject(`types:
type:
namedType: com.github.openshift.api.config.v1.SecretNameReference
default: {}
+- name: com.github.openshift.api.config.v1alpha1.AdditionalAlertmanagerConfig
+ map:
+ fields:
+ - name: authorization
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.AuthorizationConfig
+ default: {}
+ - name: name
+ type:
+ scalar: string
+ - name: pathPrefix
+ type:
+ scalar: string
+ - name: scheme
+ type:
+ scalar: string
+ - name: staticConfigs
+ type:
+ list:
+ elementType:
+ scalar: string
+ elementRelationship: associative
+ - name: timeoutSeconds
+ type:
+ scalar: numeric
+ - name: tlsConfig
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.TLSConfig
+ default: {}
- name: com.github.openshift.api.config.v1alpha1.AlertmanagerConfig
map:
fields:
@@ -4176,6 +4464,9 @@ var schemaYAML = typed.YAMLObject(`types:
keys:
- topologyKey
- whenUnsatisfiable
+ - name: userAlertmanagerConfigSelection
+ type:
+ scalar: string
- name: volumeClaimTemplate
type:
namedType: io.k8s.api.core.v1.PersistentVolumeClaim
@@ -4185,6 +4476,21 @@ var schemaYAML = typed.YAMLObject(`types:
- name: profile
type:
scalar: string
+- name: com.github.openshift.api.config.v1alpha1.AuthorizationConfig
+ map:
+ fields:
+ - name: bearerToken
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.SecretKeySelector
+ default: {}
+ - name: type
+ type:
+ scalar: string
+ unions:
+ - discriminator: type
+ fields:
+ - fieldName: bearerToken
+ discriminatorValue: BearerToken
- name: com.github.openshift.api.config.v1alpha1.Backup
map:
fields:
@@ -4225,12 +4531,23 @@ var schemaYAML = typed.YAMLObject(`types:
elementType:
namedType: __untyped_deduced_
elementRelationship: separable
-- name: com.github.openshift.api.config.v1alpha1.CRIOCredentialProviderConfig
+- name: com.github.openshift.api.config.v1alpha1.BasicAuth
map:
fields:
- - name: apiVersion
+ - name: password
type:
- scalar: string
+ namedType: com.github.openshift.api.config.v1alpha1.SecretKeySelector
+ default: {}
+ - name: username
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.SecretKeySelector
+ default: {}
+- name: com.github.openshift.api.config.v1alpha1.CRIOCredentialProviderConfig
+ map:
+ fields:
+ - name: apiVersion
+ type:
+ scalar: string
- name: kind
type:
scalar: string
@@ -4265,16 +4582,6 @@ var schemaYAML = typed.YAMLObject(`types:
elementRelationship: associative
keys:
- type
-- name: com.github.openshift.api.config.v1alpha1.CategoryOverride
- map:
- fields:
- - name: certificate
- type:
- namedType: com.github.openshift.api.config.v1alpha1.CertificateConfig
- default: {}
- - name: name
- type:
- scalar: string
- name: com.github.openshift.api.config.v1alpha1.CertificateConfig
map:
fields:
@@ -4282,22 +4589,7 @@ var schemaYAML = typed.YAMLObject(`types:
type:
namedType: com.github.openshift.api.config.v1alpha1.KeyConfig
default: {}
-- name: com.github.openshift.api.config.v1alpha1.CertificateOverride
- map:
- fields:
- - name: category
- type:
- namedType: com.github.openshift.api.config.v1alpha1.CategoryOverride
- default: {}
- - name: type
- type:
- scalar: string
- unions:
- - discriminator: type
- fields:
- - fieldName: category
- discriminatorValue: Category
-- name: com.github.openshift.api.config.v1alpha1.ClusterImagePolicy
+- name: com.github.openshift.api.config.v1alpha1.ClusterMonitoring
map:
fields:
- name: apiVersion
@@ -4312,72 +4604,59 @@ var schemaYAML = typed.YAMLObject(`types:
default: {}
- name: spec
type:
- namedType: com.github.openshift.api.config.v1alpha1.ClusterImagePolicySpec
+ namedType: com.github.openshift.api.config.v1alpha1.ClusterMonitoringSpec
default: {}
- name: status
type:
- namedType: com.github.openshift.api.config.v1alpha1.ClusterImagePolicyStatus
+ namedType: com.github.openshift.api.config.v1alpha1.ClusterMonitoringStatus
default: {}
-- name: com.github.openshift.api.config.v1alpha1.ClusterImagePolicySpec
+- name: com.github.openshift.api.config.v1alpha1.ClusterMonitoringSpec
map:
fields:
- - name: policy
+ - name: alertmanagerConfig
type:
- namedType: com.github.openshift.api.config.v1alpha1.ImageSigstoreVerificationPolicy
+ namedType: com.github.openshift.api.config.v1alpha1.AlertmanagerConfig
default: {}
- - name: scopes
- type:
- list:
- elementType:
- scalar: string
- elementRelationship: associative
-- name: com.github.openshift.api.config.v1alpha1.ClusterImagePolicyStatus
- map:
- fields:
- - name: conditions
- type:
- list:
- elementType:
- namedType: io.k8s.apimachinery.pkg.apis.meta.v1.Condition
- elementRelationship: associative
- keys:
- - type
-- name: com.github.openshift.api.config.v1alpha1.ClusterMonitoring
- map:
- fields:
- - name: apiVersion
+ - name: kubeStateMetricsConfig
type:
- scalar: string
- - name: kind
+ namedType: com.github.openshift.api.config.v1alpha1.KubeStateMetricsConfig
+ default: {}
+ - name: metricsServerConfig
type:
- scalar: string
- - name: metadata
+ namedType: com.github.openshift.api.config.v1alpha1.MetricsServerConfig
+ default: {}
+ - name: monitoringPluginConfig
type:
- namedType: io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta
+ namedType: com.github.openshift.api.config.v1alpha1.MonitoringPluginConfig
default: {}
- - name: spec
+ - name: nodeExporterConfig
type:
- namedType: com.github.openshift.api.config.v1alpha1.ClusterMonitoringSpec
+ namedType: com.github.openshift.api.config.v1alpha1.NodeExporterConfig
default: {}
- - name: status
+ - name: openShiftStateMetricsConfig
type:
- namedType: com.github.openshift.api.config.v1alpha1.ClusterMonitoringStatus
+ namedType: com.github.openshift.api.config.v1alpha1.OpenShiftStateMetricsConfig
default: {}
-- name: com.github.openshift.api.config.v1alpha1.ClusterMonitoringSpec
- map:
- fields:
- - name: alertmanagerConfig
+ - name: prometheusConfig
type:
- namedType: com.github.openshift.api.config.v1alpha1.AlertmanagerConfig
+ namedType: com.github.openshift.api.config.v1alpha1.PrometheusConfig
default: {}
- - name: metricsServerConfig
+ - name: prometheusOperatorAdmissionWebhookConfig
type:
- namedType: com.github.openshift.api.config.v1alpha1.MetricsServerConfig
+ namedType: com.github.openshift.api.config.v1alpha1.PrometheusOperatorAdmissionWebhookConfig
default: {}
- name: prometheusOperatorConfig
type:
namedType: com.github.openshift.api.config.v1alpha1.PrometheusOperatorConfig
default: {}
+ - name: telemeterClientConfig
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.TelemeterClientConfig
+ default: {}
+ - name: thanosQuerierConfig
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.ThanosQuerierConfig
+ default: {}
- name: userDefined
type:
namedType: com.github.openshift.api.config.v1alpha1.UserDefinedMonitoring
@@ -4409,16 +4688,22 @@ var schemaYAML = typed.YAMLObject(`types:
- name: com.github.openshift.api.config.v1alpha1.CustomPKIPolicy
map:
fields:
+ - name: clientCertificates
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.CertificateConfig
+ default: {}
- name: defaults
type:
namedType: com.github.openshift.api.config.v1alpha1.DefaultCertificateConfig
default: {}
- - name: overrides
+ - name: servingCertificates
type:
- list:
- elementType:
- namedType: com.github.openshift.api.config.v1alpha1.CertificateOverride
- elementRelationship: atomic
+ namedType: com.github.openshift.api.config.v1alpha1.CertificateConfig
+ default: {}
+ - name: signerCertificates
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.CertificateConfig
+ default: {}
- name: com.github.openshift.api.config.v1alpha1.DefaultCertificateConfig
map:
fields:
@@ -4426,6 +4711,12 @@ var schemaYAML = typed.YAMLObject(`types:
type:
namedType: com.github.openshift.api.config.v1alpha1.KeyConfig
default: {}
+- name: com.github.openshift.api.config.v1alpha1.DropEqualActionConfig
+ map:
+ fields:
+ - name: targetLabel
+ type:
+ scalar: string
- name: com.github.openshift.api.config.v1alpha1.ECDSAKeyConfig
map:
fields:
@@ -4466,97 +4757,15 @@ var schemaYAML = typed.YAMLObject(`types:
- name: storage
type:
namedType: com.github.openshift.api.config.v1alpha1.Storage
-- name: com.github.openshift.api.config.v1alpha1.ImagePolicy
- map:
- fields:
- - name: apiVersion
- type:
- scalar: string
- - name: kind
- type:
- scalar: string
- - name: metadata
- type:
- namedType: io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta
- default: {}
- - name: spec
- type:
- namedType: com.github.openshift.api.config.v1alpha1.ImagePolicySpec
- default: {}
- - name: status
- type:
- namedType: com.github.openshift.api.config.v1alpha1.ImagePolicyStatus
- default: {}
-- name: com.github.openshift.api.config.v1alpha1.ImagePolicyFulcioCAWithRekorRootOfTrust
- map:
- fields:
- - name: fulcioCAData
- type:
- scalar: string
- - name: fulcioSubject
- type:
- namedType: com.github.openshift.api.config.v1alpha1.PolicyFulcioSubject
- default: {}
- - name: rekorKeyData
- type:
- scalar: string
-- name: com.github.openshift.api.config.v1alpha1.ImagePolicyPKIRootOfTrust
- map:
- fields:
- - name: caIntermediatesData
- type:
- scalar: string
- - name: caRootsData
- type:
- scalar: string
- - name: pkiCertificateSubject
- type:
- namedType: com.github.openshift.api.config.v1alpha1.PKICertificateSubject
- default: {}
-- name: com.github.openshift.api.config.v1alpha1.ImagePolicyPublicKeyRootOfTrust
+- name: com.github.openshift.api.config.v1alpha1.HashModActionConfig
map:
fields:
- - name: keyData
+ - name: modulus
type:
- scalar: string
- - name: rekorKeyData
+ scalar: numeric
+ - name: targetLabel
type:
scalar: string
-- name: com.github.openshift.api.config.v1alpha1.ImagePolicySpec
- map:
- fields:
- - name: policy
- type:
- namedType: com.github.openshift.api.config.v1alpha1.ImageSigstoreVerificationPolicy
- default: {}
- - name: scopes
- type:
- list:
- elementType:
- scalar: string
- elementRelationship: associative
-- name: com.github.openshift.api.config.v1alpha1.ImagePolicyStatus
- map:
- fields:
- - name: conditions
- type:
- list:
- elementType:
- namedType: io.k8s.apimachinery.pkg.apis.meta.v1.Condition
- elementRelationship: associative
- keys:
- - type
-- name: com.github.openshift.api.config.v1alpha1.ImageSigstoreVerificationPolicy
- map:
- fields:
- - name: rootOfTrust
- type:
- namedType: com.github.openshift.api.config.v1alpha1.PolicyRootOfTrust
- default: {}
- - name: signedIdentity
- type:
- namedType: com.github.openshift.api.config.v1alpha1.PolicyIdentity
- default: {}
- name: com.github.openshift.api.config.v1alpha1.InsightsDataGather
map:
fields:
@@ -4597,6 +4806,12 @@ var schemaYAML = typed.YAMLObject(`types:
elementType:
namedType: __untyped_deduced_
elementRelationship: separable
+- name: com.github.openshift.api.config.v1alpha1.KeepEqualActionConfig
+ map:
+ fields:
+ - name: targetLabel
+ type:
+ scalar: string
- name: com.github.openshift.api.config.v1alpha1.KeyConfig
map:
fields:
@@ -4618,13 +4833,17 @@ var schemaYAML = typed.YAMLObject(`types:
discriminatorValue: ECDSA
- fieldName: rsa
discriminatorValue: RSA
-- name: com.github.openshift.api.config.v1alpha1.MetricsServerConfig
+- name: com.github.openshift.api.config.v1alpha1.KubeStateMetricsConfig
map:
fields:
- - name: audit
+ - name: additionalResourceLabels
type:
- namedType: com.github.openshift.api.config.v1alpha1.Audit
- default: {}
+ list:
+ elementType:
+ namedType: com.github.openshift.api.config.v1alpha1.KubeStateMetricsResourceLabels
+ elementRelationship: associative
+ keys:
+ - resource
- name: nodeSelector
type:
map:
@@ -4653,148 +4872,542 @@ var schemaYAML = typed.YAMLObject(`types:
keys:
- topologyKey
- whenUnsatisfiable
- - name: verbosity
- type:
- scalar: string
-- name: com.github.openshift.api.config.v1alpha1.PKI
- map:
- fields:
- - name: apiVersion
- type:
- scalar: string
- - name: kind
- type:
- scalar: string
- - name: metadata
- type:
- namedType: io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta
- default: {}
- - name: spec
- type:
- namedType: com.github.openshift.api.config.v1alpha1.PKISpec
- default: {}
-- name: com.github.openshift.api.config.v1alpha1.PKICertificateManagement
+- name: com.github.openshift.api.config.v1alpha1.KubeStateMetricsResourceLabels
map:
fields:
- - name: custom
+ - name: labels
type:
- namedType: com.github.openshift.api.config.v1alpha1.CustomPKIPolicy
- default: {}
- - name: mode
+ list:
+ elementType:
+ scalar: string
+ elementRelationship: associative
+ - name: resource
type:
scalar: string
- unions:
- - discriminator: mode
- fields:
- - fieldName: custom
- discriminatorValue: Custom
-- name: com.github.openshift.api.config.v1alpha1.PKICertificateSubject
+- name: com.github.openshift.api.config.v1alpha1.Label
map:
fields:
- - name: email
+ - name: key
type:
scalar: string
- - name: hostname
+ - name: value
type:
scalar: string
-- name: com.github.openshift.api.config.v1alpha1.PKISpec
+- name: com.github.openshift.api.config.v1alpha1.LabelMapActionConfig
map:
fields:
- - name: certificateManagement
+ - name: replacement
type:
- namedType: com.github.openshift.api.config.v1alpha1.PKICertificateManagement
- default: {}
-- name: com.github.openshift.api.config.v1alpha1.PersistentVolumeClaimReference
+ scalar: string
+- name: com.github.openshift.api.config.v1alpha1.LowercaseActionConfig
map:
fields:
- - name: name
+ - name: targetLabel
type:
scalar: string
- default: ""
-- name: com.github.openshift.api.config.v1alpha1.PersistentVolumeConfig
+- name: com.github.openshift.api.config.v1alpha1.MetadataConfig
map:
fields:
- - name: claim
+ - name: custom
type:
- namedType: com.github.openshift.api.config.v1alpha1.PersistentVolumeClaimReference
+ namedType: com.github.openshift.api.config.v1alpha1.MetadataConfigCustom
default: {}
- - name: mountPath
+ - name: sendPolicy
type:
scalar: string
-- name: com.github.openshift.api.config.v1alpha1.PolicyFulcioSubject
+- name: com.github.openshift.api.config.v1alpha1.MetadataConfigCustom
map:
fields:
- - name: oidcIssuer
- type:
- scalar: string
- default: ""
- - name: signedEmail
+ - name: sendIntervalSeconds
type:
- scalar: string
- default: ""
-- name: com.github.openshift.api.config.v1alpha1.PolicyIdentity
+ scalar: numeric
+- name: com.github.openshift.api.config.v1alpha1.MetricsServerConfig
map:
fields:
- - name: exactRepository
+ - name: audit
type:
- namedType: com.github.openshift.api.config.v1alpha1.PolicyMatchExactRepository
- - name: matchPolicy
+ namedType: com.github.openshift.api.config.v1alpha1.Audit
+ default: {}
+ - name: nodeSelector
type:
- scalar: string
- default: ""
- - name: remapIdentity
+ map:
+ elementType:
+ scalar: string
+ - name: resources
type:
- namedType: com.github.openshift.api.config.v1alpha1.PolicyMatchRemapIdentity
- unions:
- - discriminator: matchPolicy
+ list:
+ elementType:
+ namedType: com.github.openshift.api.config.v1alpha1.ContainerResource
+ elementRelationship: associative
+ keys:
+ - name
+ - name: tolerations
+ type:
+ list:
+ elementType:
+ namedType: io.k8s.api.core.v1.Toleration
+ elementRelationship: atomic
+ - name: topologySpreadConstraints
+ type:
+ list:
+ elementType:
+ namedType: io.k8s.api.core.v1.TopologySpreadConstraint
+ elementRelationship: associative
+ keys:
+ - topologyKey
+ - whenUnsatisfiable
+ - name: verbosity
+ type:
+ scalar: string
+- name: com.github.openshift.api.config.v1alpha1.MonitoringPluginConfig
+ map:
+ fields:
+ - name: nodeSelector
+ type:
+ map:
+ elementType:
+ scalar: string
+ - name: resources
+ type:
+ list:
+ elementType:
+ namedType: com.github.openshift.api.config.v1alpha1.ContainerResource
+ elementRelationship: associative
+ keys:
+ - name
+ - name: tolerations
+ type:
+ list:
+ elementType:
+ namedType: io.k8s.api.core.v1.Toleration
+ elementRelationship: atomic
+ - name: topologySpreadConstraints
+ type:
+ list:
+ elementType:
+ namedType: io.k8s.api.core.v1.TopologySpreadConstraint
+ elementRelationship: associative
+ keys:
+ - topologyKey
+ - whenUnsatisfiable
+- name: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorBuddyInfoConfig
+ map:
+ fields:
+ - name: collectionPolicy
+ type:
+ scalar: string
+- name: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorConfig
+ map:
+ fields:
+ - name: buddyInfo
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorBuddyInfoConfig
+ default: {}
+ - name: cpuFreq
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorCpufreqConfig
+ default: {}
+ - name: deviceMapperMultipath
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorDeviceMapperMultipathConfig
+ default: {}
+ - name: ethtool
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorEthtoolConfig
+ default: {}
+ - name: ksmd
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorKSMDConfig
+ default: {}
+ - name: mountStats
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorMountStatsConfig
+ default: {}
+ - name: netClass
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorNetClassConfig
+ default: {}
+ - name: netDev
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorNetDevConfig
+ default: {}
+ - name: nvmExpressSubsystem
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorNVMExpressSubsystemConfig
+ default: {}
+ - name: processes
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorProcessesConfig
+ default: {}
+ - name: softirqs
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorSoftirqsConfig
+ default: {}
+ - name: systemd
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorSystemdConfig
+ default: {}
+ - name: tcpStat
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorTcpStatConfig
+ default: {}
+ - name: zoneinfo
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorZoneinfoConfig
+ default: {}
+- name: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorCpufreqConfig
+ map:
+ fields:
+ - name: collectionPolicy
+ type:
+ scalar: string
+- name: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorDeviceMapperMultipathConfig
+ map:
+ fields:
+ - name: collectionPolicy
+ type:
+ scalar: string
+- name: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorEthtoolConfig
+ map:
+ fields:
+ - name: collectionPolicy
+ type:
+ scalar: string
+- name: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorKSMDConfig
+ map:
+ fields:
+ - name: collectionPolicy
+ type:
+ scalar: string
+- name: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorMountStatsConfig
+ map:
+ fields:
+ - name: collectionPolicy
+ type:
+ scalar: string
+- name: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorNVMExpressSubsystemConfig
+ map:
+ fields:
+ - name: collectionPolicy
+ type:
+ scalar: string
+- name: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorNetClassCollectConfig
+ map:
+ fields:
+ - name: statsGatherer
+ type:
+ scalar: string
+- name: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorNetClassConfig
+ map:
+ fields:
+ - name: collect
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorNetClassCollectConfig
+ default: {}
+ - name: collectionPolicy
+ type:
+ scalar: string
+ unions:
+ - discriminator: collectionPolicy
fields:
- - fieldName: exactRepository
- discriminatorValue: PolicyMatchExactRepository
- - fieldName: remapIdentity
- discriminatorValue: PolicyMatchRemapIdentity
-- name: com.github.openshift.api.config.v1alpha1.PolicyMatchExactRepository
+ - fieldName: collect
+ discriminatorValue: Collect
+- name: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorNetDevConfig
map:
fields:
- - name: repository
+ - name: collectionPolicy
type:
scalar: string
- default: ""
-- name: com.github.openshift.api.config.v1alpha1.PolicyMatchRemapIdentity
+- name: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorProcessesConfig
map:
fields:
- - name: prefix
+ - name: collectionPolicy
type:
scalar: string
- default: ""
- - name: signedPrefix
+- name: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorSoftirqsConfig
+ map:
+ fields:
+ - name: collectionPolicy
type:
scalar: string
- default: ""
-- name: com.github.openshift.api.config.v1alpha1.PolicyRootOfTrust
+- name: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorSystemdCollectConfig
map:
fields:
- - name: fulcioCAWithRekor
+ - name: units
type:
- namedType: com.github.openshift.api.config.v1alpha1.ImagePolicyFulcioCAWithRekorRootOfTrust
- - name: pki
+ list:
+ elementType:
+ scalar: string
+ elementRelationship: associative
+- name: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorSystemdConfig
+ map:
+ fields:
+ - name: collect
type:
- namedType: com.github.openshift.api.config.v1alpha1.ImagePolicyPKIRootOfTrust
- - name: policyType
+ namedType: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorSystemdCollectConfig
+ default: {}
+ - name: collectionPolicy
type:
scalar: string
- default: ""
- - name: publicKey
+ unions:
+ - discriminator: collectionPolicy
+ fields:
+ - fieldName: collect
+ discriminatorValue: Collect
+- name: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorTcpStatConfig
+ map:
+ fields:
+ - name: collectionPolicy
+ type:
+ scalar: string
+- name: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorZoneinfoConfig
+ map:
+ fields:
+ - name: collectionPolicy
+ type:
+ scalar: string
+- name: com.github.openshift.api.config.v1alpha1.NodeExporterConfig
+ map:
+ fields:
+ - name: collectors
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.NodeExporterCollectorConfig
+ default: {}
+ - name: ignoredNetworkDevices
+ type:
+ list:
+ elementType:
+ scalar: string
+ elementRelationship: associative
+ - name: maxProcs
+ type:
+ scalar: numeric
+ - name: resources
+ type:
+ list:
+ elementType:
+ namedType: com.github.openshift.api.config.v1alpha1.ContainerResource
+ elementRelationship: associative
+ keys:
+ - name
+- name: com.github.openshift.api.config.v1alpha1.OAuth2
+ map:
+ fields:
+ - name: clientId
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.SecretKeySelector
+ default: {}
+ - name: clientSecret
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.SecretKeySelector
+ default: {}
+ - name: endpointParams
+ type:
+ list:
+ elementType:
+ namedType: com.github.openshift.api.config.v1alpha1.OAuth2EndpointParam
+ elementRelationship: associative
+ keys:
+ - name
+ - name: scopes
+ type:
+ list:
+ elementType:
+ scalar: string
+ elementRelationship: atomic
+ - name: tokenUrl
+ type:
+ scalar: string
+- name: com.github.openshift.api.config.v1alpha1.OAuth2EndpointParam
+ map:
+ fields:
+ - name: name
+ type:
+ scalar: string
+ - name: value
type:
- namedType: com.github.openshift.api.config.v1alpha1.ImagePolicyPublicKeyRootOfTrust
+ scalar: string
+- name: com.github.openshift.api.config.v1alpha1.OpenShiftStateMetricsConfig
+ map:
+ fields:
+ - name: nodeSelector
+ type:
+ map:
+ elementType:
+ scalar: string
+ - name: resources
+ type:
+ list:
+ elementType:
+ namedType: com.github.openshift.api.config.v1alpha1.ContainerResource
+ elementRelationship: associative
+ keys:
+ - name
+ - name: tolerations
+ type:
+ list:
+ elementType:
+ namedType: io.k8s.api.core.v1.Toleration
+ elementRelationship: atomic
+ - name: topologySpreadConstraints
+ type:
+ list:
+ elementType:
+ namedType: io.k8s.api.core.v1.TopologySpreadConstraint
+ elementRelationship: associative
+ keys:
+ - topologyKey
+ - whenUnsatisfiable
+- name: com.github.openshift.api.config.v1alpha1.PKI
+ map:
+ fields:
+ - name: apiVersion
+ type:
+ scalar: string
+ - name: kind
+ type:
+ scalar: string
+ - name: metadata
+ type:
+ namedType: io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta
+ default: {}
+ - name: spec
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.PKISpec
+ default: {}
+- name: com.github.openshift.api.config.v1alpha1.PKICertificateManagement
+ map:
+ fields:
+ - name: custom
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.CustomPKIPolicy
+ default: {}
+ - name: mode
+ type:
+ scalar: string
unions:
- - discriminator: policyType
+ - discriminator: mode
fields:
- - fieldName: fulcioCAWithRekor
- discriminatorValue: FulcioCAWithRekor
- - fieldName: pki
- discriminatorValue: PKI
- - fieldName: publicKey
- discriminatorValue: PublicKey
+ - fieldName: custom
+ discriminatorValue: Custom
+- name: com.github.openshift.api.config.v1alpha1.PKISpec
+ map:
+ fields:
+ - name: certificateManagement
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.PKICertificateManagement
+ default: {}
+- name: com.github.openshift.api.config.v1alpha1.PersistentVolumeClaimReference
+ map:
+ fields:
+ - name: name
+ type:
+ scalar: string
+ default: ""
+- name: com.github.openshift.api.config.v1alpha1.PersistentVolumeConfig
+ map:
+ fields:
+ - name: claim
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.PersistentVolumeClaimReference
+ default: {}
+ - name: mountPath
+ type:
+ scalar: string
+- name: com.github.openshift.api.config.v1alpha1.PrometheusConfig
+ map:
+ fields:
+ - name: additionalAlertmanagerConfigs
+ type:
+ list:
+ elementType:
+ namedType: com.github.openshift.api.config.v1alpha1.AdditionalAlertmanagerConfig
+ elementRelationship: associative
+ keys:
+ - name
+ - name: collectionProfile
+ type:
+ scalar: string
+ - name: enforcedBodySizeLimitBytes
+ type:
+ scalar: numeric
+ - name: externalLabels
+ type:
+ list:
+ elementType:
+ namedType: com.github.openshift.api.config.v1alpha1.Label
+ elementRelationship: associative
+ keys:
+ - key
+ - name: logLevel
+ type:
+ scalar: string
+ - name: nodeSelector
+ type:
+ map:
+ elementType:
+ scalar: string
+ - name: queryLogFile
+ type:
+ scalar: string
+ - name: remoteWrite
+ type:
+ list:
+ elementType:
+ namedType: com.github.openshift.api.config.v1alpha1.RemoteWriteSpec
+ elementRelationship: associative
+ keys:
+ - name
+ - name: resources
+ type:
+ list:
+ elementType:
+ namedType: com.github.openshift.api.config.v1alpha1.ContainerResource
+ elementRelationship: associative
+ keys:
+ - name
+ - name: retention
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.Retention
+ default: {}
+ - name: tolerations
+ type:
+ list:
+ elementType:
+ namedType: io.k8s.api.core.v1.Toleration
+ elementRelationship: atomic
+ - name: topologySpreadConstraints
+ type:
+ list:
+ elementType:
+ namedType: io.k8s.api.core.v1.TopologySpreadConstraint
+ elementRelationship: associative
+ keys:
+ - topologyKey
+ - whenUnsatisfiable
+ - name: volumeClaimTemplate
+ type:
+ namedType: io.k8s.api.core.v1.PersistentVolumeClaim
+- name: com.github.openshift.api.config.v1alpha1.PrometheusOperatorAdmissionWebhookConfig
+ map:
+ fields:
+ - name: resources
+ type:
+ list:
+ elementType:
+ namedType: com.github.openshift.api.config.v1alpha1.ContainerResource
+ elementRelationship: associative
+ keys:
+ - name
+ - name: topologySpreadConstraints
+ type:
+ list:
+ elementType:
+ namedType: io.k8s.api.core.v1.TopologySpreadConstraint
+ elementRelationship: associative
+ keys:
+ - topologyKey
+ - whenUnsatisfiable
- name: com.github.openshift.api.config.v1alpha1.PrometheusOperatorConfig
map:
fields:
@@ -4829,12 +5442,225 @@ var schemaYAML = typed.YAMLObject(`types:
keys:
- topologyKey
- whenUnsatisfiable
+- name: com.github.openshift.api.config.v1alpha1.PrometheusRemoteWriteHeader
+ map:
+ fields:
+ - name: name
+ type:
+ scalar: string
+ - name: value
+ type:
+ scalar: string
+- name: com.github.openshift.api.config.v1alpha1.QueueConfig
+ map:
+ fields:
+ - name: batchSendDeadlineSeconds
+ type:
+ scalar: numeric
+ - name: capacity
+ type:
+ scalar: numeric
+ - name: maxBackoffMilliseconds
+ type:
+ scalar: numeric
+ - name: maxSamplesPerSend
+ type:
+ scalar: numeric
+ - name: maxShards
+ type:
+ scalar: numeric
+ - name: minBackoffMilliseconds
+ type:
+ scalar: numeric
+ - name: minShards
+ type:
+ scalar: numeric
+ - name: rateLimitedAction
+ type:
+ scalar: string
- name: com.github.openshift.api.config.v1alpha1.RSAKeyConfig
map:
fields:
- name: keySize
type:
scalar: numeric
+- name: com.github.openshift.api.config.v1alpha1.RelabelActionConfig
+ map:
+ fields:
+ - name: dropEqual
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.DropEqualActionConfig
+ default: {}
+ - name: hashMod
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.HashModActionConfig
+ default: {}
+ - name: keepEqual
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.KeepEqualActionConfig
+ default: {}
+ - name: labelMap
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.LabelMapActionConfig
+ default: {}
+ - name: lowercase
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.LowercaseActionConfig
+ default: {}
+ - name: replace
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.ReplaceActionConfig
+ default: {}
+ - name: type
+ type:
+ scalar: string
+ - name: uppercase
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.UppercaseActionConfig
+ default: {}
+ unions:
+ - discriminator: type
+ fields:
+ - fieldName: dropEqual
+ discriminatorValue: DropEqual
+ - fieldName: hashMod
+ discriminatorValue: HashMod
+ - fieldName: keepEqual
+ discriminatorValue: KeepEqual
+ - fieldName: labelMap
+ discriminatorValue: LabelMap
+ - fieldName: lowercase
+ discriminatorValue: Lowercase
+ - fieldName: replace
+ discriminatorValue: Replace
+ - fieldName: uppercase
+ discriminatorValue: Uppercase
+- name: com.github.openshift.api.config.v1alpha1.RelabelConfig
+ map:
+ fields:
+ - name: action
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.RelabelActionConfig
+ default: {}
+ - name: name
+ type:
+ scalar: string
+ - name: regex
+ type:
+ scalar: string
+ - name: separator
+ type:
+ scalar: string
+ - name: sourceLabels
+ type:
+ list:
+ elementType:
+ scalar: string
+ elementRelationship: associative
+- name: com.github.openshift.api.config.v1alpha1.RemoteWriteAuthorization
+ map:
+ fields:
+ - name: authorization
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.SecretKeySelector
+ default: {}
+ - name: basicAuth
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.BasicAuth
+ default: {}
+ - name: oauth2
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.OAuth2
+ default: {}
+ - name: sigv4
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.Sigv4
+ default: {}
+ - name: type
+ type:
+ scalar: string
+ unions:
+ - discriminator: type
+ fields:
+ - fieldName: authorization
+ discriminatorValue: Authorization
+ - fieldName: basicAuth
+ discriminatorValue: BasicAuth
+ - fieldName: oauth2
+ discriminatorValue: OAuth2
+ - fieldName: sigv4
+ discriminatorValue: Sigv4
+- name: com.github.openshift.api.config.v1alpha1.RemoteWriteSpec
+ map:
+ fields:
+ - name: authorization
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.RemoteWriteAuthorization
+ default: {}
+ - name: exemplarsMode
+ type:
+ scalar: string
+ - name: headers
+ type:
+ list:
+ elementType:
+ namedType: com.github.openshift.api.config.v1alpha1.PrometheusRemoteWriteHeader
+ elementRelationship: associative
+ keys:
+ - name
+ - name: messageVersion
+ type:
+ scalar: string
+ - name: metadataConfig
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.MetadataConfig
+ default: {}
+ - name: name
+ type:
+ scalar: string
+ - name: proxyUrl
+ type:
+ scalar: string
+ - name: queueConfig
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.QueueConfig
+ default: {}
+ - name: remoteTimeoutSeconds
+ type:
+ scalar: numeric
+ - name: tlsConfig
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.TLSConfig
+ default: {}
+ - name: url
+ type:
+ scalar: string
+ - name: writeRelabelConfigs
+ type:
+ list:
+ elementType:
+ namedType: com.github.openshift.api.config.v1alpha1.RelabelConfig
+ elementRelationship: associative
+ keys:
+ - name
+- name: com.github.openshift.api.config.v1alpha1.ReplaceActionConfig
+ map:
+ fields:
+ - name: replacement
+ type:
+ scalar: string
+ - name: targetLabel
+ type:
+ scalar: string
+- name: com.github.openshift.api.config.v1alpha1.Retention
+ map:
+ fields:
+ - name: duration
+ type:
+ scalar: string
+ - name: size
+ type:
+ scalar: string
- name: com.github.openshift.api.config.v1alpha1.RetentionNumberConfig
map:
fields:
@@ -4869,6 +5695,36 @@ var schemaYAML = typed.YAMLObject(`types:
type:
scalar: numeric
default: 0
+- name: com.github.openshift.api.config.v1alpha1.SecretKeySelector
+ map:
+ fields:
+ - name: key
+ type:
+ scalar: string
+ - name: name
+ type:
+ scalar: string
+ elementRelationship: atomic
+- name: com.github.openshift.api.config.v1alpha1.Sigv4
+ map:
+ fields:
+ - name: accessKey
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.SecretKeySelector
+ default: {}
+ - name: profile
+ type:
+ scalar: string
+ - name: region
+ type:
+ scalar: string
+ - name: roleArn
+ type:
+ scalar: string
+ - name: secretKey
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.SecretKeySelector
+ default: {}
- name: com.github.openshift.api.config.v1alpha1.Storage
map:
fields:
@@ -4879,6 +5735,111 @@ var schemaYAML = typed.YAMLObject(`types:
type:
scalar: string
default: ""
+- name: com.github.openshift.api.config.v1alpha1.TLSConfig
+ map:
+ fields:
+ - name: ca
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.SecretKeySelector
+ default: {}
+ - name: cert
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.SecretKeySelector
+ default: {}
+ - name: certificateVerification
+ type:
+ scalar: string
+ - name: key
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.SecretKeySelector
+ default: {}
+ - name: serverName
+ type:
+ scalar: string
+- name: com.github.openshift.api.config.v1alpha1.TelemeterClientConfig
+ map:
+ fields:
+ - name: nodeSelector
+ type:
+ map:
+ elementType:
+ scalar: string
+ - name: resources
+ type:
+ list:
+ elementType:
+ namedType: com.github.openshift.api.config.v1alpha1.ContainerResource
+ elementRelationship: associative
+ keys:
+ - name
+ - name: tolerations
+ type:
+ list:
+ elementType:
+ namedType: io.k8s.api.core.v1.Toleration
+ elementRelationship: atomic
+ - name: topologySpreadConstraints
+ type:
+ list:
+ elementType:
+ namedType: io.k8s.api.core.v1.TopologySpreadConstraint
+ elementRelationship: associative
+ keys:
+ - topologyKey
+ - whenUnsatisfiable
+- name: com.github.openshift.api.config.v1alpha1.ThanosQuerierConfig
+ map:
+ fields:
+ - name: crossOriginRequestPolicy
+ type:
+ scalar: string
+ - name: logLevel
+ type:
+ scalar: string
+ - name: nodeSelector
+ type:
+ map:
+ elementType:
+ scalar: string
+ - name: requestLogging
+ type:
+ namedType: com.github.openshift.api.config.v1alpha1.ThanosQuerierRequestLoggingConfig
+ default: {}
+ - name: resources
+ type:
+ list:
+ elementType:
+ namedType: com.github.openshift.api.config.v1alpha1.ContainerResource
+ elementRelationship: associative
+ keys:
+ - name
+ - name: tolerations
+ type:
+ list:
+ elementType:
+ namedType: io.k8s.api.core.v1.Toleration
+ elementRelationship: atomic
+ - name: topologySpreadConstraints
+ type:
+ list:
+ elementType:
+ namedType: io.k8s.api.core.v1.TopologySpreadConstraint
+ elementRelationship: associative
+ keys:
+ - topologyKey
+ - whenUnsatisfiable
+- name: com.github.openshift.api.config.v1alpha1.ThanosQuerierRequestLoggingConfig
+ map:
+ fields:
+ - name: policy
+ type:
+ scalar: string
+- name: com.github.openshift.api.config.v1alpha1.UppercaseActionConfig
+ map:
+ fields:
+ - name: targetLabel
+ type:
+ scalar: string
- name: com.github.openshift.api.config.v1alpha1.UserDefinedMonitoring
map:
fields:
diff --git a/vendor/github.com/openshift/client-go/config/applyconfigurations/utils.go b/vendor/github.com/openshift/client-go/config/applyconfigurations/utils.go
index 420c06ad22..62dd8d61f4 100644
--- a/vendor/github.com/openshift/client-go/config/applyconfigurations/utils.go
+++ b/vendor/github.com/openshift/client-go/config/applyconfigurations/utils.go
@@ -50,8 +50,6 @@ func ForKind(kind schema.GroupVersionKind) interface{} {
return &configv1.AWSDNSSpecApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("AWSIngressSpec"):
return &configv1.AWSIngressSpecApplyConfiguration{}
- case v1.SchemeGroupVersion.WithKind("AWSKMSConfig"):
- return &configv1.AWSKMSConfigApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("AWSPlatformSpec"):
return &configv1.AWSPlatformSpecApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("AWSPlatformStatus"):
@@ -80,6 +78,10 @@ func ForKind(kind schema.GroupVersionKind) interface{} {
return &configv1.BuildOverridesApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("BuildSpec"):
return &configv1.BuildSpecApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("ClientCredentialConfig"):
+ return &configv1.ClientCredentialConfigApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("ClientSecretSecretReference"):
+ return &configv1.ClientSecretSecretReferenceApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("CloudControllerManagerStatus"):
return &configv1.CloudControllerManagerStatusApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("CloudLoadBalancerConfig"):
@@ -134,6 +136,12 @@ func ForKind(kind schema.GroupVersionKind) interface{} {
return &configv1.ConsoleSpecApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("ConsoleStatus"):
return &configv1.ConsoleStatusApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("CRIOCredentialProviderConfig"):
+ return &configv1.CRIOCredentialProviderConfigApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("CRIOCredentialProviderConfigSpec"):
+ return &configv1.CRIOCredentialProviderConfigSpecApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("CRIOCredentialProviderConfigStatus"):
+ return &configv1.CRIOCredentialProviderConfigStatusApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("Custom"):
return &configv1.CustomApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("CustomFeatureGates"):
@@ -152,6 +160,8 @@ func ForKind(kind schema.GroupVersionKind) interface{} {
return &configv1.DNSZoneApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("EquinixMetalPlatformStatus"):
return &configv1.EquinixMetalPlatformStatusApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("ExternalClaimsSource"):
+ return &configv1.ExternalClaimsSourceApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("ExternalIPConfig"):
return &configv1.ExternalIPConfigApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("ExternalIPPolicy"):
@@ -160,6 +170,14 @@ func ForKind(kind schema.GroupVersionKind) interface{} {
return &configv1.ExternalPlatformSpecApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("ExternalPlatformStatus"):
return &configv1.ExternalPlatformStatusApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("ExternalSourceAuthentication"):
+ return &configv1.ExternalSourceAuthenticationApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("ExternalSourceCertificateAuthorityConfigMapReference"):
+ return &configv1.ExternalSourceCertificateAuthorityConfigMapReferenceApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("ExternalSourcePredicate"):
+ return &configv1.ExternalSourcePredicateApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("ExternalSourceTLS"):
+ return &configv1.ExternalSourceTLSApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("ExtraMapping"):
return &configv1.ExtraMappingApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("FeatureGate"):
@@ -266,8 +284,8 @@ func ForKind(kind schema.GroupVersionKind) interface{} {
return &configv1.InsightsDataGatherSpecApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("KeystoneIdentityProvider"):
return &configv1.KeystoneIdentityProviderApplyConfiguration{}
- case v1.SchemeGroupVersion.WithKind("KMSConfig"):
- return &configv1.KMSConfigApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("KMSPluginConfig"):
+ return &configv1.KMSPluginConfigApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("KubevirtPlatformStatus"):
return &configv1.KubevirtPlatformStatusApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("LDAPAttributeMapping"):
@@ -292,6 +310,8 @@ func ForKind(kind schema.GroupVersionKind) interface{} {
return &configv1.NetworkDiagnosticsTargetPlacementApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("NetworkMigration"):
return &configv1.NetworkMigrationApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("NetworkObservabilitySpec"):
+ return &configv1.NetworkObservabilitySpecApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("NetworkSpec"):
return &configv1.NetworkSpecApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("NetworkStatus"):
@@ -418,6 +438,10 @@ func ForKind(kind schema.GroupVersionKind) interface{} {
return &configv1.SecretNameReferenceApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("SignatureStore"):
return &configv1.SignatureStoreApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("SourcedClaimMapping"):
+ return &configv1.SourcedClaimMappingApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("SourceURL"):
+ return &configv1.SourceURLApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("Storage"):
return &configv1.StorageApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("TemplateReference"):
@@ -452,6 +476,18 @@ func ForKind(kind schema.GroupVersionKind) interface{} {
return &configv1.UsernameClaimMappingApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("UsernamePrefix"):
return &configv1.UsernamePrefixApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("VaultAppRoleAuthentication"):
+ return &configv1.VaultAppRoleAuthenticationApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("VaultAuthentication"):
+ return &configv1.VaultAuthenticationApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("VaultConfigMapReference"):
+ return &configv1.VaultConfigMapReferenceApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("VaultKMSPluginConfig"):
+ return &configv1.VaultKMSPluginConfigApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("VaultSecretReference"):
+ return &configv1.VaultSecretReferenceApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("VaultTLSConfig"):
+ return &configv1.VaultTLSConfigApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("VSphereFailureDomainHostGroup"):
return &configv1.VSphereFailureDomainHostGroupApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("VSphereFailureDomainRegionAffinity"):
@@ -478,24 +514,24 @@ func ForKind(kind schema.GroupVersionKind) interface{} {
return &configv1.WebhookTokenAuthenticatorApplyConfiguration{}
// Group=config.openshift.io, Version=v1alpha1
+ case v1alpha1.SchemeGroupVersion.WithKind("AdditionalAlertmanagerConfig"):
+ return &configv1alpha1.AdditionalAlertmanagerConfigApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("AlertmanagerConfig"):
return &configv1alpha1.AlertmanagerConfigApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("AlertmanagerCustomConfig"):
return &configv1alpha1.AlertmanagerCustomConfigApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("Audit"):
return &configv1alpha1.AuditApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("AuthorizationConfig"):
+ return &configv1alpha1.AuthorizationConfigApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("Backup"):
return &configv1alpha1.BackupApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("BackupSpec"):
return &configv1alpha1.BackupSpecApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("BasicAuth"):
+ return &configv1alpha1.BasicAuthApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("CertificateConfig"):
return &configv1alpha1.CertificateConfigApplyConfiguration{}
- case v1alpha1.SchemeGroupVersion.WithKind("ClusterImagePolicy"):
- return &configv1alpha1.ClusterImagePolicyApplyConfiguration{}
- case v1alpha1.SchemeGroupVersion.WithKind("ClusterImagePolicySpec"):
- return &configv1alpha1.ClusterImagePolicySpecApplyConfiguration{}
- case v1alpha1.SchemeGroupVersion.WithKind("ClusterImagePolicyStatus"):
- return &configv1alpha1.ClusterImagePolicyStatusApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("ClusterMonitoring"):
return &configv1alpha1.ClusterMonitoringApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("ClusterMonitoringSpec"):
@@ -512,34 +548,84 @@ func ForKind(kind schema.GroupVersionKind) interface{} {
return &configv1alpha1.CustomPKIPolicyApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("DefaultCertificateConfig"):
return &configv1alpha1.DefaultCertificateConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("DropEqualActionConfig"):
+ return &configv1alpha1.DropEqualActionConfigApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("ECDSAKeyConfig"):
return &configv1alpha1.ECDSAKeyConfigApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("EtcdBackupSpec"):
return &configv1alpha1.EtcdBackupSpecApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("GatherConfig"):
return &configv1alpha1.GatherConfigApplyConfiguration{}
- case v1alpha1.SchemeGroupVersion.WithKind("ImagePolicy"):
- return &configv1alpha1.ImagePolicyApplyConfiguration{}
- case v1alpha1.SchemeGroupVersion.WithKind("ImagePolicyFulcioCAWithRekorRootOfTrust"):
- return &configv1alpha1.ImagePolicyFulcioCAWithRekorRootOfTrustApplyConfiguration{}
- case v1alpha1.SchemeGroupVersion.WithKind("ImagePolicyPKIRootOfTrust"):
- return &configv1alpha1.ImagePolicyPKIRootOfTrustApplyConfiguration{}
- case v1alpha1.SchemeGroupVersion.WithKind("ImagePolicyPublicKeyRootOfTrust"):
- return &configv1alpha1.ImagePolicyPublicKeyRootOfTrustApplyConfiguration{}
- case v1alpha1.SchemeGroupVersion.WithKind("ImagePolicySpec"):
- return &configv1alpha1.ImagePolicySpecApplyConfiguration{}
- case v1alpha1.SchemeGroupVersion.WithKind("ImagePolicyStatus"):
- return &configv1alpha1.ImagePolicyStatusApplyConfiguration{}
- case v1alpha1.SchemeGroupVersion.WithKind("ImageSigstoreVerificationPolicy"):
- return &configv1alpha1.ImageSigstoreVerificationPolicyApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("HashModActionConfig"):
+ return &configv1alpha1.HashModActionConfigApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("InsightsDataGather"):
return &configv1alpha1.InsightsDataGatherApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("InsightsDataGatherSpec"):
return &configv1alpha1.InsightsDataGatherSpecApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("KeepEqualActionConfig"):
+ return &configv1alpha1.KeepEqualActionConfigApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("KeyConfig"):
return &configv1alpha1.KeyConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("KubeStateMetricsConfig"):
+ return &configv1alpha1.KubeStateMetricsConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("KubeStateMetricsResourceLabels"):
+ return &configv1alpha1.KubeStateMetricsResourceLabelsApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("Label"):
+ return &configv1alpha1.LabelApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("LabelMapActionConfig"):
+ return &configv1alpha1.LabelMapActionConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("LowercaseActionConfig"):
+ return &configv1alpha1.LowercaseActionConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("MetadataConfig"):
+ return &configv1alpha1.MetadataConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("MetadataConfigCustom"):
+ return &configv1alpha1.MetadataConfigCustomApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("MetricsServerConfig"):
return &configv1alpha1.MetricsServerConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("MonitoringPluginConfig"):
+ return &configv1alpha1.MonitoringPluginConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("NodeExporterCollectorBuddyInfoConfig"):
+ return &configv1alpha1.NodeExporterCollectorBuddyInfoConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("NodeExporterCollectorConfig"):
+ return &configv1alpha1.NodeExporterCollectorConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("NodeExporterCollectorCpufreqConfig"):
+ return &configv1alpha1.NodeExporterCollectorCpufreqConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("NodeExporterCollectorDeviceMapperMultipathConfig"):
+ return &configv1alpha1.NodeExporterCollectorDeviceMapperMultipathConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("NodeExporterCollectorEthtoolConfig"):
+ return &configv1alpha1.NodeExporterCollectorEthtoolConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("NodeExporterCollectorKSMDConfig"):
+ return &configv1alpha1.NodeExporterCollectorKSMDConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("NodeExporterCollectorMountStatsConfig"):
+ return &configv1alpha1.NodeExporterCollectorMountStatsConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("NodeExporterCollectorNetClassCollectConfig"):
+ return &configv1alpha1.NodeExporterCollectorNetClassCollectConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("NodeExporterCollectorNetClassConfig"):
+ return &configv1alpha1.NodeExporterCollectorNetClassConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("NodeExporterCollectorNetDevConfig"):
+ return &configv1alpha1.NodeExporterCollectorNetDevConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("NodeExporterCollectorNVMExpressSubsystemConfig"):
+ return &configv1alpha1.NodeExporterCollectorNVMExpressSubsystemConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("NodeExporterCollectorProcessesConfig"):
+ return &configv1alpha1.NodeExporterCollectorProcessesConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("NodeExporterCollectorSoftirqsConfig"):
+ return &configv1alpha1.NodeExporterCollectorSoftirqsConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("NodeExporterCollectorSystemdCollectConfig"):
+ return &configv1alpha1.NodeExporterCollectorSystemdCollectConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("NodeExporterCollectorSystemdConfig"):
+ return &configv1alpha1.NodeExporterCollectorSystemdConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("NodeExporterCollectorTcpStatConfig"):
+ return &configv1alpha1.NodeExporterCollectorTcpStatConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("NodeExporterCollectorZoneinfoConfig"):
+ return &configv1alpha1.NodeExporterCollectorZoneinfoConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("NodeExporterConfig"):
+ return &configv1alpha1.NodeExporterConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("OAuth2"):
+ return &configv1alpha1.OAuth2ApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("OAuth2EndpointParam"):
+ return &configv1alpha1.OAuth2EndpointParamApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("OpenShiftStateMetricsConfig"):
+ return &configv1alpha1.OpenShiftStateMetricsConfigApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("PersistentVolumeClaimReference"):
return &configv1alpha1.PersistentVolumeClaimReferenceApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("PersistentVolumeConfig"):
@@ -548,26 +634,32 @@ func ForKind(kind schema.GroupVersionKind) interface{} {
return &configv1alpha1.PKIApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("PKICertificateManagement"):
return &configv1alpha1.PKICertificateManagementApplyConfiguration{}
- case v1alpha1.SchemeGroupVersion.WithKind("PKICertificateSubject"):
- return &configv1alpha1.PKICertificateSubjectApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("PKIProfile"):
return &configv1alpha1.PKIProfileApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("PKISpec"):
return &configv1alpha1.PKISpecApplyConfiguration{}
- case v1alpha1.SchemeGroupVersion.WithKind("PolicyFulcioSubject"):
- return &configv1alpha1.PolicyFulcioSubjectApplyConfiguration{}
- case v1alpha1.SchemeGroupVersion.WithKind("PolicyIdentity"):
- return &configv1alpha1.PolicyIdentityApplyConfiguration{}
- case v1alpha1.SchemeGroupVersion.WithKind("PolicyMatchExactRepository"):
- return &configv1alpha1.PolicyMatchExactRepositoryApplyConfiguration{}
- case v1alpha1.SchemeGroupVersion.WithKind("PolicyMatchRemapIdentity"):
- return &configv1alpha1.PolicyMatchRemapIdentityApplyConfiguration{}
- case v1alpha1.SchemeGroupVersion.WithKind("PolicyRootOfTrust"):
- return &configv1alpha1.PolicyRootOfTrustApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("PrometheusConfig"):
+ return &configv1alpha1.PrometheusConfigApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("PrometheusOperatorAdmissionWebhookConfig"):
return &configv1alpha1.PrometheusOperatorAdmissionWebhookConfigApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("PrometheusOperatorConfig"):
return &configv1alpha1.PrometheusOperatorConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("PrometheusRemoteWriteHeader"):
+ return &configv1alpha1.PrometheusRemoteWriteHeaderApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("QueueConfig"):
+ return &configv1alpha1.QueueConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("RelabelActionConfig"):
+ return &configv1alpha1.RelabelActionConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("RelabelConfig"):
+ return &configv1alpha1.RelabelConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("RemoteWriteAuthorization"):
+ return &configv1alpha1.RemoteWriteAuthorizationApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("RemoteWriteSpec"):
+ return &configv1alpha1.RemoteWriteSpecApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("ReplaceActionConfig"):
+ return &configv1alpha1.ReplaceActionConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("Retention"):
+ return &configv1alpha1.RetentionApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("RetentionNumberConfig"):
return &configv1alpha1.RetentionNumberConfigApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("RetentionPolicy"):
@@ -576,8 +668,22 @@ func ForKind(kind schema.GroupVersionKind) interface{} {
return &configv1alpha1.RetentionSizeConfigApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("RSAKeyConfig"):
return &configv1alpha1.RSAKeyConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("SecretKeySelector"):
+ return &configv1alpha1.SecretKeySelectorApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("Sigv4"):
+ return &configv1alpha1.Sigv4ApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("Storage"):
return &configv1alpha1.StorageApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("TelemeterClientConfig"):
+ return &configv1alpha1.TelemeterClientConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("ThanosQuerierConfig"):
+ return &configv1alpha1.ThanosQuerierConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("ThanosQuerierRequestLoggingConfig"):
+ return &configv1alpha1.ThanosQuerierRequestLoggingConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("TLSConfig"):
+ return &configv1alpha1.TLSConfigApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("UppercaseActionConfig"):
+ return &configv1alpha1.UppercaseActionConfigApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("UserDefinedMonitoring"):
return &configv1alpha1.UserDefinedMonitoringApplyConfiguration{}
diff --git a/vendor/github.com/openshift/client-go/config/clientset/versioned/fake/clientset_generated.go b/vendor/github.com/openshift/client-go/config/clientset/versioned/fake/clientset_generated.go
index 0a3678b49a..f69c38e77b 100644
--- a/vendor/github.com/openshift/client-go/config/clientset/versioned/fake/clientset_generated.go
+++ b/vendor/github.com/openshift/client-go/config/clientset/versioned/fake/clientset_generated.go
@@ -23,10 +23,6 @@ import (
// It's backed by a very simple object tracker that processes creates, updates and deletions as-is,
// without applying any field management, validations and/or defaults. It shouldn't be considered a replacement
// for a real clientset and is mostly useful in simple unit tests.
-//
-// Deprecated: NewClientset replaces this with support for field management, which significantly improves
-// server side apply testing. NewClientset is only available when apply configurations are generated (e.g.
-// via --with-applyconfig).
func NewSimpleClientset(objects ...runtime.Object) *Clientset {
o := testing.NewObjectTracker(scheme, codecs.UniversalDecoder())
for _, obj := range objects {
@@ -72,7 +68,7 @@ func (c *Clientset) Tracker() testing.ObjectTracker {
return c.tracker
}
-// IsWatchListSemanticsSupported informs the reflector that this client
+// IsWatchListSemanticsUnSupported informs the reflector that this client
// doesn't support WatchList semantics.
//
// This is a synthetic method whose sole purpose is to satisfy the optional
@@ -87,6 +83,10 @@ func (c *Clientset) IsWatchListSemanticsUnSupported() bool {
// It's backed by a very simple object tracker that processes creates, updates and deletions as-is,
// without applying any validations and/or defaults. It shouldn't be considered a replacement
// for a real clientset and is mostly useful in simple unit tests.
+//
+// Compared to NewSimpleClientset, the Clientset returned here supports field tracking and thus
+// server-side apply. Beware though that support in that for CRDs is missing
+// (https://github.com/kubernetes/kubernetes/issues/126850).
func NewClientset(objects ...runtime.Object) *Clientset {
o := testing.NewFieldManagedObjectTracker(
scheme,
diff --git a/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1/config_client.go b/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1/config_client.go
index afce6aef52..6235cd977b 100644
--- a/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1/config_client.go
+++ b/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1/config_client.go
@@ -15,6 +15,7 @@ type ConfigV1Interface interface {
APIServersGetter
AuthenticationsGetter
BuildsGetter
+ CRIOCredentialProviderConfigsGetter
ClusterImagePoliciesGetter
ClusterOperatorsGetter
ClusterVersionsGetter
@@ -55,6 +56,10 @@ func (c *ConfigV1Client) Builds() BuildInterface {
return newBuilds(c)
}
+func (c *ConfigV1Client) CRIOCredentialProviderConfigs() CRIOCredentialProviderConfigInterface {
+ return newCRIOCredentialProviderConfigs(c)
+}
+
func (c *ConfigV1Client) ClusterImagePolicies() ClusterImagePolicyInterface {
return newClusterImagePolicies(c)
}
diff --git a/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1/criocredentialproviderconfig.go b/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1/criocredentialproviderconfig.go
new file mode 100644
index 0000000000..69272fac40
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1/criocredentialproviderconfig.go
@@ -0,0 +1,58 @@
+// Code generated by client-gen. DO NOT EDIT.
+
+package v1
+
+import (
+ context "context"
+
+ configv1 "github.com/openshift/api/config/v1"
+ applyconfigurationsconfigv1 "github.com/openshift/client-go/config/applyconfigurations/config/v1"
+ scheme "github.com/openshift/client-go/config/clientset/versioned/scheme"
+ metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
+ types "k8s.io/apimachinery/pkg/types"
+ watch "k8s.io/apimachinery/pkg/watch"
+ gentype "k8s.io/client-go/gentype"
+)
+
+// CRIOCredentialProviderConfigsGetter has a method to return a CRIOCredentialProviderConfigInterface.
+// A group's client should implement this interface.
+type CRIOCredentialProviderConfigsGetter interface {
+ CRIOCredentialProviderConfigs() CRIOCredentialProviderConfigInterface
+}
+
+// CRIOCredentialProviderConfigInterface has methods to work with CRIOCredentialProviderConfig resources.
+type CRIOCredentialProviderConfigInterface interface {
+ Create(ctx context.Context, cRIOCredentialProviderConfig *configv1.CRIOCredentialProviderConfig, opts metav1.CreateOptions) (*configv1.CRIOCredentialProviderConfig, error)
+ Update(ctx context.Context, cRIOCredentialProviderConfig *configv1.CRIOCredentialProviderConfig, opts metav1.UpdateOptions) (*configv1.CRIOCredentialProviderConfig, error)
+ // Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
+ UpdateStatus(ctx context.Context, cRIOCredentialProviderConfig *configv1.CRIOCredentialProviderConfig, opts metav1.UpdateOptions) (*configv1.CRIOCredentialProviderConfig, error)
+ Delete(ctx context.Context, name string, opts metav1.DeleteOptions) error
+ DeleteCollection(ctx context.Context, opts metav1.DeleteOptions, listOpts metav1.ListOptions) error
+ Get(ctx context.Context, name string, opts metav1.GetOptions) (*configv1.CRIOCredentialProviderConfig, error)
+ List(ctx context.Context, opts metav1.ListOptions) (*configv1.CRIOCredentialProviderConfigList, error)
+ Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error)
+ Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts metav1.PatchOptions, subresources ...string) (result *configv1.CRIOCredentialProviderConfig, err error)
+ Apply(ctx context.Context, cRIOCredentialProviderConfig *applyconfigurationsconfigv1.CRIOCredentialProviderConfigApplyConfiguration, opts metav1.ApplyOptions) (result *configv1.CRIOCredentialProviderConfig, err error)
+ // Add a +genclient:noStatus comment above the type to avoid generating ApplyStatus().
+ ApplyStatus(ctx context.Context, cRIOCredentialProviderConfig *applyconfigurationsconfigv1.CRIOCredentialProviderConfigApplyConfiguration, opts metav1.ApplyOptions) (result *configv1.CRIOCredentialProviderConfig, err error)
+ CRIOCredentialProviderConfigExpansion
+}
+
+// cRIOCredentialProviderConfigs implements CRIOCredentialProviderConfigInterface
+type cRIOCredentialProviderConfigs struct {
+ *gentype.ClientWithListAndApply[*configv1.CRIOCredentialProviderConfig, *configv1.CRIOCredentialProviderConfigList, *applyconfigurationsconfigv1.CRIOCredentialProviderConfigApplyConfiguration]
+}
+
+// newCRIOCredentialProviderConfigs returns a CRIOCredentialProviderConfigs
+func newCRIOCredentialProviderConfigs(c *ConfigV1Client) *cRIOCredentialProviderConfigs {
+ return &cRIOCredentialProviderConfigs{
+ gentype.NewClientWithListAndApply[*configv1.CRIOCredentialProviderConfig, *configv1.CRIOCredentialProviderConfigList, *applyconfigurationsconfigv1.CRIOCredentialProviderConfigApplyConfiguration](
+ "criocredentialproviderconfigs",
+ c.RESTClient(),
+ scheme.ParameterCodec,
+ "",
+ func() *configv1.CRIOCredentialProviderConfig { return &configv1.CRIOCredentialProviderConfig{} },
+ func() *configv1.CRIOCredentialProviderConfigList { return &configv1.CRIOCredentialProviderConfigList{} },
+ ),
+ }
+}
diff --git a/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1/fake/fake_config_client.go b/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1/fake/fake_config_client.go
index b5a1a52573..5fb7425da0 100644
--- a/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1/fake/fake_config_client.go
+++ b/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1/fake/fake_config_client.go
@@ -24,6 +24,10 @@ func (c *FakeConfigV1) Builds() v1.BuildInterface {
return newFakeBuilds(c)
}
+func (c *FakeConfigV1) CRIOCredentialProviderConfigs() v1.CRIOCredentialProviderConfigInterface {
+ return newFakeCRIOCredentialProviderConfigs(c)
+}
+
func (c *FakeConfigV1) ClusterImagePolicies() v1.ClusterImagePolicyInterface {
return newFakeClusterImagePolicies(c)
}
diff --git a/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1/fake/fake_criocredentialproviderconfig.go b/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1/fake/fake_criocredentialproviderconfig.go
new file mode 100644
index 0000000000..d4c3fd7f1c
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1/fake/fake_criocredentialproviderconfig.go
@@ -0,0 +1,37 @@
+// Code generated by client-gen. DO NOT EDIT.
+
+package fake
+
+import (
+ v1 "github.com/openshift/api/config/v1"
+ configv1 "github.com/openshift/client-go/config/applyconfigurations/config/v1"
+ typedconfigv1 "github.com/openshift/client-go/config/clientset/versioned/typed/config/v1"
+ gentype "k8s.io/client-go/gentype"
+)
+
+// fakeCRIOCredentialProviderConfigs implements CRIOCredentialProviderConfigInterface
+type fakeCRIOCredentialProviderConfigs struct {
+ *gentype.FakeClientWithListAndApply[*v1.CRIOCredentialProviderConfig, *v1.CRIOCredentialProviderConfigList, *configv1.CRIOCredentialProviderConfigApplyConfiguration]
+ Fake *FakeConfigV1
+}
+
+func newFakeCRIOCredentialProviderConfigs(fake *FakeConfigV1) typedconfigv1.CRIOCredentialProviderConfigInterface {
+ return &fakeCRIOCredentialProviderConfigs{
+ gentype.NewFakeClientWithListAndApply[*v1.CRIOCredentialProviderConfig, *v1.CRIOCredentialProviderConfigList, *configv1.CRIOCredentialProviderConfigApplyConfiguration](
+ fake.Fake,
+ "",
+ v1.SchemeGroupVersion.WithResource("criocredentialproviderconfigs"),
+ v1.SchemeGroupVersion.WithKind("CRIOCredentialProviderConfig"),
+ func() *v1.CRIOCredentialProviderConfig { return &v1.CRIOCredentialProviderConfig{} },
+ func() *v1.CRIOCredentialProviderConfigList { return &v1.CRIOCredentialProviderConfigList{} },
+ func(dst, src *v1.CRIOCredentialProviderConfigList) { dst.ListMeta = src.ListMeta },
+ func(list *v1.CRIOCredentialProviderConfigList) []*v1.CRIOCredentialProviderConfig {
+ return gentype.ToPointerSlice(list.Items)
+ },
+ func(list *v1.CRIOCredentialProviderConfigList, items []*v1.CRIOCredentialProviderConfig) {
+ list.Items = gentype.FromPointerSlice(items)
+ },
+ ),
+ fake,
+ }
+}
diff --git a/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1/generated_expansion.go b/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1/generated_expansion.go
index 27c5fd110b..0f3e44588f 100644
--- a/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1/generated_expansion.go
+++ b/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1/generated_expansion.go
@@ -8,6 +8,8 @@ type AuthenticationExpansion interface{}
type BuildExpansion interface{}
+type CRIOCredentialProviderConfigExpansion interface{}
+
type ClusterImagePolicyExpansion interface{}
type ClusterOperatorExpansion interface{}
diff --git a/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1alpha1/clusterimagepolicy.go b/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1alpha1/clusterimagepolicy.go
deleted file mode 100644
index 8391f7b40e..0000000000
--- a/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1alpha1/clusterimagepolicy.go
+++ /dev/null
@@ -1,58 +0,0 @@
-// Code generated by client-gen. DO NOT EDIT.
-
-package v1alpha1
-
-import (
- context "context"
-
- configv1alpha1 "github.com/openshift/api/config/v1alpha1"
- applyconfigurationsconfigv1alpha1 "github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1"
- scheme "github.com/openshift/client-go/config/clientset/versioned/scheme"
- v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
- types "k8s.io/apimachinery/pkg/types"
- watch "k8s.io/apimachinery/pkg/watch"
- gentype "k8s.io/client-go/gentype"
-)
-
-// ClusterImagePoliciesGetter has a method to return a ClusterImagePolicyInterface.
-// A group's client should implement this interface.
-type ClusterImagePoliciesGetter interface {
- ClusterImagePolicies() ClusterImagePolicyInterface
-}
-
-// ClusterImagePolicyInterface has methods to work with ClusterImagePolicy resources.
-type ClusterImagePolicyInterface interface {
- Create(ctx context.Context, clusterImagePolicy *configv1alpha1.ClusterImagePolicy, opts v1.CreateOptions) (*configv1alpha1.ClusterImagePolicy, error)
- Update(ctx context.Context, clusterImagePolicy *configv1alpha1.ClusterImagePolicy, opts v1.UpdateOptions) (*configv1alpha1.ClusterImagePolicy, error)
- // Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
- UpdateStatus(ctx context.Context, clusterImagePolicy *configv1alpha1.ClusterImagePolicy, opts v1.UpdateOptions) (*configv1alpha1.ClusterImagePolicy, error)
- Delete(ctx context.Context, name string, opts v1.DeleteOptions) error
- DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error
- Get(ctx context.Context, name string, opts v1.GetOptions) (*configv1alpha1.ClusterImagePolicy, error)
- List(ctx context.Context, opts v1.ListOptions) (*configv1alpha1.ClusterImagePolicyList, error)
- Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
- Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *configv1alpha1.ClusterImagePolicy, err error)
- Apply(ctx context.Context, clusterImagePolicy *applyconfigurationsconfigv1alpha1.ClusterImagePolicyApplyConfiguration, opts v1.ApplyOptions) (result *configv1alpha1.ClusterImagePolicy, err error)
- // Add a +genclient:noStatus comment above the type to avoid generating ApplyStatus().
- ApplyStatus(ctx context.Context, clusterImagePolicy *applyconfigurationsconfigv1alpha1.ClusterImagePolicyApplyConfiguration, opts v1.ApplyOptions) (result *configv1alpha1.ClusterImagePolicy, err error)
- ClusterImagePolicyExpansion
-}
-
-// clusterImagePolicies implements ClusterImagePolicyInterface
-type clusterImagePolicies struct {
- *gentype.ClientWithListAndApply[*configv1alpha1.ClusterImagePolicy, *configv1alpha1.ClusterImagePolicyList, *applyconfigurationsconfigv1alpha1.ClusterImagePolicyApplyConfiguration]
-}
-
-// newClusterImagePolicies returns a ClusterImagePolicies
-func newClusterImagePolicies(c *ConfigV1alpha1Client) *clusterImagePolicies {
- return &clusterImagePolicies{
- gentype.NewClientWithListAndApply[*configv1alpha1.ClusterImagePolicy, *configv1alpha1.ClusterImagePolicyList, *applyconfigurationsconfigv1alpha1.ClusterImagePolicyApplyConfiguration](
- "clusterimagepolicies",
- c.RESTClient(),
- scheme.ParameterCodec,
- "",
- func() *configv1alpha1.ClusterImagePolicy { return &configv1alpha1.ClusterImagePolicy{} },
- func() *configv1alpha1.ClusterImagePolicyList { return &configv1alpha1.ClusterImagePolicyList{} },
- ),
- }
-}
diff --git a/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1alpha1/config_client.go b/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1alpha1/config_client.go
index ce3b84174d..23ba9a19c0 100644
--- a/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1alpha1/config_client.go
+++ b/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1alpha1/config_client.go
@@ -14,9 +14,7 @@ type ConfigV1alpha1Interface interface {
RESTClient() rest.Interface
BackupsGetter
CRIOCredentialProviderConfigsGetter
- ClusterImagePoliciesGetter
ClusterMonitoringsGetter
- ImagePoliciesGetter
InsightsDataGathersGetter
PKIsGetter
}
@@ -34,18 +32,10 @@ func (c *ConfigV1alpha1Client) CRIOCredentialProviderConfigs() CRIOCredentialPro
return newCRIOCredentialProviderConfigs(c)
}
-func (c *ConfigV1alpha1Client) ClusterImagePolicies() ClusterImagePolicyInterface {
- return newClusterImagePolicies(c)
-}
-
func (c *ConfigV1alpha1Client) ClusterMonitorings() ClusterMonitoringInterface {
return newClusterMonitorings(c)
}
-func (c *ConfigV1alpha1Client) ImagePolicies(namespace string) ImagePolicyInterface {
- return newImagePolicies(c, namespace)
-}
-
func (c *ConfigV1alpha1Client) InsightsDataGathers() InsightsDataGatherInterface {
return newInsightsDataGathers(c)
}
diff --git a/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1alpha1/fake/fake_clusterimagepolicy.go b/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1alpha1/fake/fake_clusterimagepolicy.go
deleted file mode 100644
index 50d94e1a91..0000000000
--- a/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1alpha1/fake/fake_clusterimagepolicy.go
+++ /dev/null
@@ -1,37 +0,0 @@
-// Code generated by client-gen. DO NOT EDIT.
-
-package fake
-
-import (
- v1alpha1 "github.com/openshift/api/config/v1alpha1"
- configv1alpha1 "github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1"
- typedconfigv1alpha1 "github.com/openshift/client-go/config/clientset/versioned/typed/config/v1alpha1"
- gentype "k8s.io/client-go/gentype"
-)
-
-// fakeClusterImagePolicies implements ClusterImagePolicyInterface
-type fakeClusterImagePolicies struct {
- *gentype.FakeClientWithListAndApply[*v1alpha1.ClusterImagePolicy, *v1alpha1.ClusterImagePolicyList, *configv1alpha1.ClusterImagePolicyApplyConfiguration]
- Fake *FakeConfigV1alpha1
-}
-
-func newFakeClusterImagePolicies(fake *FakeConfigV1alpha1) typedconfigv1alpha1.ClusterImagePolicyInterface {
- return &fakeClusterImagePolicies{
- gentype.NewFakeClientWithListAndApply[*v1alpha1.ClusterImagePolicy, *v1alpha1.ClusterImagePolicyList, *configv1alpha1.ClusterImagePolicyApplyConfiguration](
- fake.Fake,
- "",
- v1alpha1.SchemeGroupVersion.WithResource("clusterimagepolicies"),
- v1alpha1.SchemeGroupVersion.WithKind("ClusterImagePolicy"),
- func() *v1alpha1.ClusterImagePolicy { return &v1alpha1.ClusterImagePolicy{} },
- func() *v1alpha1.ClusterImagePolicyList { return &v1alpha1.ClusterImagePolicyList{} },
- func(dst, src *v1alpha1.ClusterImagePolicyList) { dst.ListMeta = src.ListMeta },
- func(list *v1alpha1.ClusterImagePolicyList) []*v1alpha1.ClusterImagePolicy {
- return gentype.ToPointerSlice(list.Items)
- },
- func(list *v1alpha1.ClusterImagePolicyList, items []*v1alpha1.ClusterImagePolicy) {
- list.Items = gentype.FromPointerSlice(items)
- },
- ),
- fake,
- }
-}
diff --git a/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1alpha1/fake/fake_config_client.go b/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1alpha1/fake/fake_config_client.go
index ab264f559b..381179df9c 100644
--- a/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1alpha1/fake/fake_config_client.go
+++ b/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1alpha1/fake/fake_config_client.go
@@ -20,18 +20,10 @@ func (c *FakeConfigV1alpha1) CRIOCredentialProviderConfigs() v1alpha1.CRIOCreden
return newFakeCRIOCredentialProviderConfigs(c)
}
-func (c *FakeConfigV1alpha1) ClusterImagePolicies() v1alpha1.ClusterImagePolicyInterface {
- return newFakeClusterImagePolicies(c)
-}
-
func (c *FakeConfigV1alpha1) ClusterMonitorings() v1alpha1.ClusterMonitoringInterface {
return newFakeClusterMonitorings(c)
}
-func (c *FakeConfigV1alpha1) ImagePolicies(namespace string) v1alpha1.ImagePolicyInterface {
- return newFakeImagePolicies(c, namespace)
-}
-
func (c *FakeConfigV1alpha1) InsightsDataGathers() v1alpha1.InsightsDataGatherInterface {
return newFakeInsightsDataGathers(c)
}
diff --git a/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1alpha1/fake/fake_imagepolicy.go b/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1alpha1/fake/fake_imagepolicy.go
deleted file mode 100644
index 9bf6cb9c04..0000000000
--- a/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1alpha1/fake/fake_imagepolicy.go
+++ /dev/null
@@ -1,37 +0,0 @@
-// Code generated by client-gen. DO NOT EDIT.
-
-package fake
-
-import (
- v1alpha1 "github.com/openshift/api/config/v1alpha1"
- configv1alpha1 "github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1"
- typedconfigv1alpha1 "github.com/openshift/client-go/config/clientset/versioned/typed/config/v1alpha1"
- gentype "k8s.io/client-go/gentype"
-)
-
-// fakeImagePolicies implements ImagePolicyInterface
-type fakeImagePolicies struct {
- *gentype.FakeClientWithListAndApply[*v1alpha1.ImagePolicy, *v1alpha1.ImagePolicyList, *configv1alpha1.ImagePolicyApplyConfiguration]
- Fake *FakeConfigV1alpha1
-}
-
-func newFakeImagePolicies(fake *FakeConfigV1alpha1, namespace string) typedconfigv1alpha1.ImagePolicyInterface {
- return &fakeImagePolicies{
- gentype.NewFakeClientWithListAndApply[*v1alpha1.ImagePolicy, *v1alpha1.ImagePolicyList, *configv1alpha1.ImagePolicyApplyConfiguration](
- fake.Fake,
- namespace,
- v1alpha1.SchemeGroupVersion.WithResource("imagepolicies"),
- v1alpha1.SchemeGroupVersion.WithKind("ImagePolicy"),
- func() *v1alpha1.ImagePolicy { return &v1alpha1.ImagePolicy{} },
- func() *v1alpha1.ImagePolicyList { return &v1alpha1.ImagePolicyList{} },
- func(dst, src *v1alpha1.ImagePolicyList) { dst.ListMeta = src.ListMeta },
- func(list *v1alpha1.ImagePolicyList) []*v1alpha1.ImagePolicy {
- return gentype.ToPointerSlice(list.Items)
- },
- func(list *v1alpha1.ImagePolicyList, items []*v1alpha1.ImagePolicy) {
- list.Items = gentype.FromPointerSlice(items)
- },
- ),
- fake,
- }
-}
diff --git a/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1alpha1/generated_expansion.go b/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1alpha1/generated_expansion.go
index 3908fe8d17..bc1f603194 100644
--- a/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1alpha1/generated_expansion.go
+++ b/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1alpha1/generated_expansion.go
@@ -6,12 +6,8 @@ type BackupExpansion interface{}
type CRIOCredentialProviderConfigExpansion interface{}
-type ClusterImagePolicyExpansion interface{}
-
type ClusterMonitoringExpansion interface{}
-type ImagePolicyExpansion interface{}
-
type InsightsDataGatherExpansion interface{}
type PKIExpansion interface{}
diff --git a/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1alpha1/imagepolicy.go b/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1alpha1/imagepolicy.go
deleted file mode 100644
index a893efeea7..0000000000
--- a/vendor/github.com/openshift/client-go/config/clientset/versioned/typed/config/v1alpha1/imagepolicy.go
+++ /dev/null
@@ -1,58 +0,0 @@
-// Code generated by client-gen. DO NOT EDIT.
-
-package v1alpha1
-
-import (
- context "context"
-
- configv1alpha1 "github.com/openshift/api/config/v1alpha1"
- applyconfigurationsconfigv1alpha1 "github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1"
- scheme "github.com/openshift/client-go/config/clientset/versioned/scheme"
- v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
- types "k8s.io/apimachinery/pkg/types"
- watch "k8s.io/apimachinery/pkg/watch"
- gentype "k8s.io/client-go/gentype"
-)
-
-// ImagePoliciesGetter has a method to return a ImagePolicyInterface.
-// A group's client should implement this interface.
-type ImagePoliciesGetter interface {
- ImagePolicies(namespace string) ImagePolicyInterface
-}
-
-// ImagePolicyInterface has methods to work with ImagePolicy resources.
-type ImagePolicyInterface interface {
- Create(ctx context.Context, imagePolicy *configv1alpha1.ImagePolicy, opts v1.CreateOptions) (*configv1alpha1.ImagePolicy, error)
- Update(ctx context.Context, imagePolicy *configv1alpha1.ImagePolicy, opts v1.UpdateOptions) (*configv1alpha1.ImagePolicy, error)
- // Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
- UpdateStatus(ctx context.Context, imagePolicy *configv1alpha1.ImagePolicy, opts v1.UpdateOptions) (*configv1alpha1.ImagePolicy, error)
- Delete(ctx context.Context, name string, opts v1.DeleteOptions) error
- DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error
- Get(ctx context.Context, name string, opts v1.GetOptions) (*configv1alpha1.ImagePolicy, error)
- List(ctx context.Context, opts v1.ListOptions) (*configv1alpha1.ImagePolicyList, error)
- Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
- Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *configv1alpha1.ImagePolicy, err error)
- Apply(ctx context.Context, imagePolicy *applyconfigurationsconfigv1alpha1.ImagePolicyApplyConfiguration, opts v1.ApplyOptions) (result *configv1alpha1.ImagePolicy, err error)
- // Add a +genclient:noStatus comment above the type to avoid generating ApplyStatus().
- ApplyStatus(ctx context.Context, imagePolicy *applyconfigurationsconfigv1alpha1.ImagePolicyApplyConfiguration, opts v1.ApplyOptions) (result *configv1alpha1.ImagePolicy, err error)
- ImagePolicyExpansion
-}
-
-// imagePolicies implements ImagePolicyInterface
-type imagePolicies struct {
- *gentype.ClientWithListAndApply[*configv1alpha1.ImagePolicy, *configv1alpha1.ImagePolicyList, *applyconfigurationsconfigv1alpha1.ImagePolicyApplyConfiguration]
-}
-
-// newImagePolicies returns a ImagePolicies
-func newImagePolicies(c *ConfigV1alpha1Client, namespace string) *imagePolicies {
- return &imagePolicies{
- gentype.NewClientWithListAndApply[*configv1alpha1.ImagePolicy, *configv1alpha1.ImagePolicyList, *applyconfigurationsconfigv1alpha1.ImagePolicyApplyConfiguration](
- "imagepolicies",
- c.RESTClient(),
- scheme.ParameterCodec,
- namespace,
- func() *configv1alpha1.ImagePolicy { return &configv1alpha1.ImagePolicy{} },
- func() *configv1alpha1.ImagePolicyList { return &configv1alpha1.ImagePolicyList{} },
- ),
- }
-}
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/apiserver.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/apiserver.go
index 7fa3cc852e..e7107fe1f9 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/apiserver.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/apiserver.go
@@ -12,6 +12,7 @@ import (
configv1 "github.com/openshift/client-go/config/listers/config/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type aPIServerInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewAPIServerInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredAPIServerInformer(client, resyncPeriod, indexers, nil)
+ return NewAPIServerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredAPIServerInformer constructs a new informer for APIServer type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredAPIServerInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewAPIServerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewAPIServerInformerWithOptions constructs a new informer for APIServer type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewAPIServerInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1", Resource: "apiservers"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().APIServers().List(context.Background(), options)
+ return client.ConfigV1().APIServers().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().APIServers().Watch(context.Background(), options)
+ return client.ConfigV1().APIServers().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().APIServers().List(ctx, options)
+ return client.ConfigV1().APIServers().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().APIServers().Watch(ctx, options)
+ return client.ConfigV1().APIServers().Watch(ctx, opts)
},
}, client),
&apiconfigv1.APIServer{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *aPIServerInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredAPIServerInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewAPIServerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *aPIServerInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/authentication.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/authentication.go
index 902537e4ec..b3aca8cd2c 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/authentication.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/authentication.go
@@ -12,6 +12,7 @@ import (
configv1 "github.com/openshift/client-go/config/listers/config/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type authenticationInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewAuthenticationInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredAuthenticationInformer(client, resyncPeriod, indexers, nil)
+ return NewAuthenticationInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredAuthenticationInformer constructs a new informer for Authentication type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredAuthenticationInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewAuthenticationInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewAuthenticationInformerWithOptions constructs a new informer for Authentication type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewAuthenticationInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1", Resource: "authentications"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Authentications().List(context.Background(), options)
+ return client.ConfigV1().Authentications().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Authentications().Watch(context.Background(), options)
+ return client.ConfigV1().Authentications().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Authentications().List(ctx, options)
+ return client.ConfigV1().Authentications().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Authentications().Watch(ctx, options)
+ return client.ConfigV1().Authentications().Watch(ctx, opts)
},
}, client),
&apiconfigv1.Authentication{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *authenticationInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredAuthenticationInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewAuthenticationInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *authenticationInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/build.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/build.go
index f1680fe8b2..3cfc51f9a2 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/build.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/build.go
@@ -12,6 +12,7 @@ import (
configv1 "github.com/openshift/client-go/config/listers/config/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type buildInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewBuildInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredBuildInformer(client, resyncPeriod, indexers, nil)
+ return NewBuildInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredBuildInformer constructs a new informer for Build type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredBuildInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewBuildInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewBuildInformerWithOptions constructs a new informer for Build type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewBuildInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1", Resource: "builds"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Builds().List(context.Background(), options)
+ return client.ConfigV1().Builds().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Builds().Watch(context.Background(), options)
+ return client.ConfigV1().Builds().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Builds().List(ctx, options)
+ return client.ConfigV1().Builds().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Builds().Watch(ctx, options)
+ return client.ConfigV1().Builds().Watch(ctx, opts)
},
}, client),
&apiconfigv1.Build{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *buildInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredBuildInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewBuildInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *buildInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/clusterimagepolicy.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/clusterimagepolicy.go
index d172bdecf5..8825c60f1f 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/clusterimagepolicy.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/clusterimagepolicy.go
@@ -12,6 +12,7 @@ import (
configv1 "github.com/openshift/client-go/config/listers/config/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type clusterImagePolicyInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewClusterImagePolicyInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredClusterImagePolicyInformer(client, resyncPeriod, indexers, nil)
+ return NewClusterImagePolicyInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredClusterImagePolicyInformer constructs a new informer for ClusterImagePolicy type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredClusterImagePolicyInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewClusterImagePolicyInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewClusterImagePolicyInformerWithOptions constructs a new informer for ClusterImagePolicy type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewClusterImagePolicyInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1", Resource: "clusterimagepolicys"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().ClusterImagePolicies().List(context.Background(), options)
+ return client.ConfigV1().ClusterImagePolicies().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().ClusterImagePolicies().Watch(context.Background(), options)
+ return client.ConfigV1().ClusterImagePolicies().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().ClusterImagePolicies().List(ctx, options)
+ return client.ConfigV1().ClusterImagePolicies().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().ClusterImagePolicies().Watch(ctx, options)
+ return client.ConfigV1().ClusterImagePolicies().Watch(ctx, opts)
},
}, client),
&apiconfigv1.ClusterImagePolicy{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *clusterImagePolicyInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredClusterImagePolicyInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewClusterImagePolicyInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *clusterImagePolicyInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/clusteroperator.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/clusteroperator.go
index 0b524565e9..a49d4f314b 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/clusteroperator.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/clusteroperator.go
@@ -12,6 +12,7 @@ import (
configv1 "github.com/openshift/client-go/config/listers/config/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type clusterOperatorInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewClusterOperatorInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredClusterOperatorInformer(client, resyncPeriod, indexers, nil)
+ return NewClusterOperatorInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredClusterOperatorInformer constructs a new informer for ClusterOperator type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredClusterOperatorInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewClusterOperatorInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewClusterOperatorInformerWithOptions constructs a new informer for ClusterOperator type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewClusterOperatorInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1", Resource: "clusteroperators"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().ClusterOperators().List(context.Background(), options)
+ return client.ConfigV1().ClusterOperators().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().ClusterOperators().Watch(context.Background(), options)
+ return client.ConfigV1().ClusterOperators().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().ClusterOperators().List(ctx, options)
+ return client.ConfigV1().ClusterOperators().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().ClusterOperators().Watch(ctx, options)
+ return client.ConfigV1().ClusterOperators().Watch(ctx, opts)
},
}, client),
&apiconfigv1.ClusterOperator{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *clusterOperatorInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredClusterOperatorInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewClusterOperatorInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *clusterOperatorInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/clusterversion.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/clusterversion.go
index 5ba9f5e2e8..aeb49b2791 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/clusterversion.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/clusterversion.go
@@ -12,6 +12,7 @@ import (
configv1 "github.com/openshift/client-go/config/listers/config/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type clusterVersionInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewClusterVersionInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredClusterVersionInformer(client, resyncPeriod, indexers, nil)
+ return NewClusterVersionInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredClusterVersionInformer constructs a new informer for ClusterVersion type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredClusterVersionInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewClusterVersionInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewClusterVersionInformerWithOptions constructs a new informer for ClusterVersion type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewClusterVersionInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1", Resource: "clusterversions"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().ClusterVersions().List(context.Background(), options)
+ return client.ConfigV1().ClusterVersions().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().ClusterVersions().Watch(context.Background(), options)
+ return client.ConfigV1().ClusterVersions().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().ClusterVersions().List(ctx, options)
+ return client.ConfigV1().ClusterVersions().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().ClusterVersions().Watch(ctx, options)
+ return client.ConfigV1().ClusterVersions().Watch(ctx, opts)
},
}, client),
&apiconfigv1.ClusterVersion{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *clusterVersionInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredClusterVersionInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewClusterVersionInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *clusterVersionInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/console.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/console.go
index 8c4a901dc6..66074549d3 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/console.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/console.go
@@ -12,6 +12,7 @@ import (
configv1 "github.com/openshift/client-go/config/listers/config/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type consoleInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewConsoleInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredConsoleInformer(client, resyncPeriod, indexers, nil)
+ return NewConsoleInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredConsoleInformer constructs a new informer for Console type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredConsoleInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewConsoleInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewConsoleInformerWithOptions constructs a new informer for Console type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewConsoleInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1", Resource: "consoles"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Consoles().List(context.Background(), options)
+ return client.ConfigV1().Consoles().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Consoles().Watch(context.Background(), options)
+ return client.ConfigV1().Consoles().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Consoles().List(ctx, options)
+ return client.ConfigV1().Consoles().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Consoles().Watch(ctx, options)
+ return client.ConfigV1().Consoles().Watch(ctx, opts)
},
}, client),
&apiconfigv1.Console{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *consoleInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredConsoleInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewConsoleInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *consoleInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/criocredentialproviderconfig.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/criocredentialproviderconfig.go
new file mode 100644
index 0000000000..aaae42ac3d
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/criocredentialproviderconfig.go
@@ -0,0 +1,99 @@
+// Code generated by informer-gen. DO NOT EDIT.
+
+package v1
+
+import (
+ context "context"
+ time "time"
+
+ apiconfigv1 "github.com/openshift/api/config/v1"
+ versioned "github.com/openshift/client-go/config/clientset/versioned"
+ internalinterfaces "github.com/openshift/client-go/config/informers/externalversions/internalinterfaces"
+ configv1 "github.com/openshift/client-go/config/listers/config/v1"
+ metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
+ runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
+ watch "k8s.io/apimachinery/pkg/watch"
+ cache "k8s.io/client-go/tools/cache"
+)
+
+// CRIOCredentialProviderConfigInformer provides access to a shared informer and lister for
+// CRIOCredentialProviderConfigs.
+type CRIOCredentialProviderConfigInformer interface {
+ Informer() cache.SharedIndexInformer
+ Lister() configv1.CRIOCredentialProviderConfigLister
+}
+
+type cRIOCredentialProviderConfigInformer struct {
+ factory internalinterfaces.SharedInformerFactory
+ tweakListOptions internalinterfaces.TweakListOptionsFunc
+}
+
+// NewCRIOCredentialProviderConfigInformer constructs a new informer for CRIOCredentialProviderConfig type.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewCRIOCredentialProviderConfigInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
+ return NewCRIOCredentialProviderConfigInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
+}
+
+// NewFilteredCRIOCredentialProviderConfigInformer constructs a new informer for CRIOCredentialProviderConfig type.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewFilteredCRIOCredentialProviderConfigInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
+ return NewCRIOCredentialProviderConfigInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewCRIOCredentialProviderConfigInformerWithOptions constructs a new informer for CRIOCredentialProviderConfig type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewCRIOCredentialProviderConfigInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1", Resource: "criocredentialproviderconfigs"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
+ cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
+ if tweakListOptions != nil {
+ tweakListOptions(&opts)
+ }
+ return client.ConfigV1().CRIOCredentialProviderConfigs().List(context.Background(), opts)
+ },
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
+ if tweakListOptions != nil {
+ tweakListOptions(&opts)
+ }
+ return client.ConfigV1().CRIOCredentialProviderConfigs().Watch(context.Background(), opts)
+ },
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
+ if tweakListOptions != nil {
+ tweakListOptions(&opts)
+ }
+ return client.ConfigV1().CRIOCredentialProviderConfigs().List(ctx, opts)
+ },
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
+ if tweakListOptions != nil {
+ tweakListOptions(&opts)
+ }
+ return client.ConfigV1().CRIOCredentialProviderConfigs().Watch(ctx, opts)
+ },
+ }, client),
+ &apiconfigv1.CRIOCredentialProviderConfig{},
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
+ )
+}
+
+func (f *cRIOCredentialProviderConfigInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
+ return NewCRIOCredentialProviderConfigInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
+}
+
+func (f *cRIOCredentialProviderConfigInformer) Informer() cache.SharedIndexInformer {
+ return f.factory.InformerFor(&apiconfigv1.CRIOCredentialProviderConfig{}, f.defaultInformer)
+}
+
+func (f *cRIOCredentialProviderConfigInformer) Lister() configv1.CRIOCredentialProviderConfigLister {
+ return configv1.NewCRIOCredentialProviderConfigLister(f.Informer().GetIndexer())
+}
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/dns.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/dns.go
index 2e8ae5b572..9a235ad346 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/dns.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/dns.go
@@ -12,6 +12,7 @@ import (
configv1 "github.com/openshift/client-go/config/listers/config/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type dNSInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewDNSInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredDNSInformer(client, resyncPeriod, indexers, nil)
+ return NewDNSInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredDNSInformer constructs a new informer for DNS type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredDNSInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewDNSInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewDNSInformerWithOptions constructs a new informer for DNS type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewDNSInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1", Resource: "dnss"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().DNSes().List(context.Background(), options)
+ return client.ConfigV1().DNSes().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().DNSes().Watch(context.Background(), options)
+ return client.ConfigV1().DNSes().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().DNSes().List(ctx, options)
+ return client.ConfigV1().DNSes().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().DNSes().Watch(ctx, options)
+ return client.ConfigV1().DNSes().Watch(ctx, opts)
},
}, client),
&apiconfigv1.DNS{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *dNSInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredDNSInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewDNSInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *dNSInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/featuregate.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/featuregate.go
index e26cdb9ac3..f8956e01e0 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/featuregate.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/featuregate.go
@@ -12,6 +12,7 @@ import (
configv1 "github.com/openshift/client-go/config/listers/config/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type featureGateInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFeatureGateInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredFeatureGateInformer(client, resyncPeriod, indexers, nil)
+ return NewFeatureGateInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredFeatureGateInformer constructs a new informer for FeatureGate type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredFeatureGateInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewFeatureGateInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewFeatureGateInformerWithOptions constructs a new informer for FeatureGate type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewFeatureGateInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1", Resource: "featuregates"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().FeatureGates().List(context.Background(), options)
+ return client.ConfigV1().FeatureGates().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().FeatureGates().Watch(context.Background(), options)
+ return client.ConfigV1().FeatureGates().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().FeatureGates().List(ctx, options)
+ return client.ConfigV1().FeatureGates().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().FeatureGates().Watch(ctx, options)
+ return client.ConfigV1().FeatureGates().Watch(ctx, opts)
},
}, client),
&apiconfigv1.FeatureGate{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *featureGateInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredFeatureGateInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewFeatureGateInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *featureGateInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/image.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/image.go
index 0992eba82b..81f93f678d 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/image.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/image.go
@@ -12,6 +12,7 @@ import (
configv1 "github.com/openshift/client-go/config/listers/config/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type imageInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewImageInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredImageInformer(client, resyncPeriod, indexers, nil)
+ return NewImageInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredImageInformer constructs a new informer for Image type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredImageInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewImageInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewImageInformerWithOptions constructs a new informer for Image type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewImageInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1", Resource: "images"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Images().List(context.Background(), options)
+ return client.ConfigV1().Images().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Images().Watch(context.Background(), options)
+ return client.ConfigV1().Images().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Images().List(ctx, options)
+ return client.ConfigV1().Images().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Images().Watch(ctx, options)
+ return client.ConfigV1().Images().Watch(ctx, opts)
},
}, client),
&apiconfigv1.Image{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *imageInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredImageInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewImageInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *imageInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/imagecontentpolicy.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/imagecontentpolicy.go
index 9960674341..36e7af7997 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/imagecontentpolicy.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/imagecontentpolicy.go
@@ -12,6 +12,7 @@ import (
configv1 "github.com/openshift/client-go/config/listers/config/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type imageContentPolicyInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewImageContentPolicyInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredImageContentPolicyInformer(client, resyncPeriod, indexers, nil)
+ return NewImageContentPolicyInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredImageContentPolicyInformer constructs a new informer for ImageContentPolicy type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredImageContentPolicyInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewImageContentPolicyInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewImageContentPolicyInformerWithOptions constructs a new informer for ImageContentPolicy type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewImageContentPolicyInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1", Resource: "imagecontentpolicys"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().ImageContentPolicies().List(context.Background(), options)
+ return client.ConfigV1().ImageContentPolicies().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().ImageContentPolicies().Watch(context.Background(), options)
+ return client.ConfigV1().ImageContentPolicies().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().ImageContentPolicies().List(ctx, options)
+ return client.ConfigV1().ImageContentPolicies().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().ImageContentPolicies().Watch(ctx, options)
+ return client.ConfigV1().ImageContentPolicies().Watch(ctx, opts)
},
}, client),
&apiconfigv1.ImageContentPolicy{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *imageContentPolicyInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredImageContentPolicyInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewImageContentPolicyInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *imageContentPolicyInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/imagedigestmirrorset.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/imagedigestmirrorset.go
index 7efd71d7e0..ac43768aca 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/imagedigestmirrorset.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/imagedigestmirrorset.go
@@ -12,6 +12,7 @@ import (
configv1 "github.com/openshift/client-go/config/listers/config/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type imageDigestMirrorSetInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewImageDigestMirrorSetInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredImageDigestMirrorSetInformer(client, resyncPeriod, indexers, nil)
+ return NewImageDigestMirrorSetInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredImageDigestMirrorSetInformer constructs a new informer for ImageDigestMirrorSet type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredImageDigestMirrorSetInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewImageDigestMirrorSetInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewImageDigestMirrorSetInformerWithOptions constructs a new informer for ImageDigestMirrorSet type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewImageDigestMirrorSetInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1", Resource: "imagedigestmirrorsets"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().ImageDigestMirrorSets().List(context.Background(), options)
+ return client.ConfigV1().ImageDigestMirrorSets().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().ImageDigestMirrorSets().Watch(context.Background(), options)
+ return client.ConfigV1().ImageDigestMirrorSets().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().ImageDigestMirrorSets().List(ctx, options)
+ return client.ConfigV1().ImageDigestMirrorSets().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().ImageDigestMirrorSets().Watch(ctx, options)
+ return client.ConfigV1().ImageDigestMirrorSets().Watch(ctx, opts)
},
}, client),
&apiconfigv1.ImageDigestMirrorSet{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *imageDigestMirrorSetInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredImageDigestMirrorSetInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewImageDigestMirrorSetInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *imageDigestMirrorSetInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/imagepolicy.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/imagepolicy.go
index 64a4d13bce..237e5259b4 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/imagepolicy.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/imagepolicy.go
@@ -12,6 +12,7 @@ import (
configv1 "github.com/openshift/client-go/config/listers/config/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -33,48 +34,61 @@ type imagePolicyInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewImagePolicyInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredImagePolicyInformer(client, namespace, resyncPeriod, indexers, nil)
+ return NewImagePolicyInformerWithOptions(client, namespace, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredImagePolicyInformer constructs a new informer for ImagePolicy type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredImagePolicyInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewImagePolicyInformerWithOptions(client, namespace, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewImagePolicyInformerWithOptions constructs a new informer for ImagePolicy type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewImagePolicyInformerWithOptions(client versioned.Interface, namespace string, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1", Resource: "imagepolicys"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().ImagePolicies(namespace).List(context.Background(), options)
+ return client.ConfigV1().ImagePolicies(namespace).List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().ImagePolicies(namespace).Watch(context.Background(), options)
+ return client.ConfigV1().ImagePolicies(namespace).Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().ImagePolicies(namespace).List(ctx, options)
+ return client.ConfigV1().ImagePolicies(namespace).List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().ImagePolicies(namespace).Watch(ctx, options)
+ return client.ConfigV1().ImagePolicies(namespace).Watch(ctx, opts)
},
}, client),
&apiconfigv1.ImagePolicy{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *imagePolicyInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredImagePolicyInformer(client, f.namespace, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewImagePolicyInformerWithOptions(client, f.namespace, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *imagePolicyInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/imagetagmirrorset.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/imagetagmirrorset.go
index e50f27fdeb..49109c8379 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/imagetagmirrorset.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/imagetagmirrorset.go
@@ -12,6 +12,7 @@ import (
configv1 "github.com/openshift/client-go/config/listers/config/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type imageTagMirrorSetInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewImageTagMirrorSetInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredImageTagMirrorSetInformer(client, resyncPeriod, indexers, nil)
+ return NewImageTagMirrorSetInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredImageTagMirrorSetInformer constructs a new informer for ImageTagMirrorSet type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredImageTagMirrorSetInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewImageTagMirrorSetInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewImageTagMirrorSetInformerWithOptions constructs a new informer for ImageTagMirrorSet type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewImageTagMirrorSetInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1", Resource: "imagetagmirrorsets"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().ImageTagMirrorSets().List(context.Background(), options)
+ return client.ConfigV1().ImageTagMirrorSets().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().ImageTagMirrorSets().Watch(context.Background(), options)
+ return client.ConfigV1().ImageTagMirrorSets().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().ImageTagMirrorSets().List(ctx, options)
+ return client.ConfigV1().ImageTagMirrorSets().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().ImageTagMirrorSets().Watch(ctx, options)
+ return client.ConfigV1().ImageTagMirrorSets().Watch(ctx, opts)
},
}, client),
&apiconfigv1.ImageTagMirrorSet{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *imageTagMirrorSetInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredImageTagMirrorSetInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewImageTagMirrorSetInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *imageTagMirrorSetInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/infrastructure.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/infrastructure.go
index a5bbe9f513..1c8d5716c3 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/infrastructure.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/infrastructure.go
@@ -12,6 +12,7 @@ import (
configv1 "github.com/openshift/client-go/config/listers/config/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type infrastructureInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewInfrastructureInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredInfrastructureInformer(client, resyncPeriod, indexers, nil)
+ return NewInfrastructureInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredInfrastructureInformer constructs a new informer for Infrastructure type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredInfrastructureInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewInfrastructureInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewInfrastructureInformerWithOptions constructs a new informer for Infrastructure type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewInfrastructureInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1", Resource: "infrastructures"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Infrastructures().List(context.Background(), options)
+ return client.ConfigV1().Infrastructures().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Infrastructures().Watch(context.Background(), options)
+ return client.ConfigV1().Infrastructures().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Infrastructures().List(ctx, options)
+ return client.ConfigV1().Infrastructures().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Infrastructures().Watch(ctx, options)
+ return client.ConfigV1().Infrastructures().Watch(ctx, opts)
},
}, client),
&apiconfigv1.Infrastructure{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *infrastructureInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredInfrastructureInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewInfrastructureInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *infrastructureInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/ingress.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/ingress.go
index 112b941af9..fd2a7cbf76 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/ingress.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/ingress.go
@@ -12,6 +12,7 @@ import (
configv1 "github.com/openshift/client-go/config/listers/config/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type ingressInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewIngressInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredIngressInformer(client, resyncPeriod, indexers, nil)
+ return NewIngressInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredIngressInformer constructs a new informer for Ingress type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredIngressInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewIngressInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewIngressInformerWithOptions constructs a new informer for Ingress type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewIngressInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1", Resource: "ingresss"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Ingresses().List(context.Background(), options)
+ return client.ConfigV1().Ingresses().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Ingresses().Watch(context.Background(), options)
+ return client.ConfigV1().Ingresses().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Ingresses().List(ctx, options)
+ return client.ConfigV1().Ingresses().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Ingresses().Watch(ctx, options)
+ return client.ConfigV1().Ingresses().Watch(ctx, opts)
},
}, client),
&apiconfigv1.Ingress{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *ingressInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredIngressInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewIngressInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *ingressInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/insightsdatagather.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/insightsdatagather.go
index 5872bfc6ab..afbffdfa03 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/insightsdatagather.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/insightsdatagather.go
@@ -12,6 +12,7 @@ import (
configv1 "github.com/openshift/client-go/config/listers/config/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type insightsDataGatherInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewInsightsDataGatherInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredInsightsDataGatherInformer(client, resyncPeriod, indexers, nil)
+ return NewInsightsDataGatherInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredInsightsDataGatherInformer constructs a new informer for InsightsDataGather type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredInsightsDataGatherInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewInsightsDataGatherInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewInsightsDataGatherInformerWithOptions constructs a new informer for InsightsDataGather type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewInsightsDataGatherInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1", Resource: "insightsdatagathers"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().InsightsDataGathers().List(context.Background(), options)
+ return client.ConfigV1().InsightsDataGathers().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().InsightsDataGathers().Watch(context.Background(), options)
+ return client.ConfigV1().InsightsDataGathers().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().InsightsDataGathers().List(ctx, options)
+ return client.ConfigV1().InsightsDataGathers().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().InsightsDataGathers().Watch(ctx, options)
+ return client.ConfigV1().InsightsDataGathers().Watch(ctx, opts)
},
}, client),
&apiconfigv1.InsightsDataGather{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *insightsDataGatherInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredInsightsDataGatherInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewInsightsDataGatherInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *insightsDataGatherInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/interface.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/interface.go
index 0ad1b98f37..2f762ff422 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/interface.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/interface.go
@@ -14,6 +14,8 @@ type Interface interface {
Authentications() AuthenticationInformer
// Builds returns a BuildInformer.
Builds() BuildInformer
+ // CRIOCredentialProviderConfigs returns a CRIOCredentialProviderConfigInformer.
+ CRIOCredentialProviderConfigs() CRIOCredentialProviderConfigInformer
// ClusterImagePolicies returns a ClusterImagePolicyInformer.
ClusterImagePolicies() ClusterImagePolicyInformer
// ClusterOperators returns a ClusterOperatorInformer.
@@ -84,6 +86,11 @@ func (v *version) Builds() BuildInformer {
return &buildInformer{factory: v.factory, tweakListOptions: v.tweakListOptions}
}
+// CRIOCredentialProviderConfigs returns a CRIOCredentialProviderConfigInformer.
+func (v *version) CRIOCredentialProviderConfigs() CRIOCredentialProviderConfigInformer {
+ return &cRIOCredentialProviderConfigInformer{factory: v.factory, tweakListOptions: v.tweakListOptions}
+}
+
// ClusterImagePolicies returns a ClusterImagePolicyInformer.
func (v *version) ClusterImagePolicies() ClusterImagePolicyInformer {
return &clusterImagePolicyInformer{factory: v.factory, tweakListOptions: v.tweakListOptions}
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/network.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/network.go
index ad36857a1a..66456bbf66 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/network.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/network.go
@@ -12,6 +12,7 @@ import (
configv1 "github.com/openshift/client-go/config/listers/config/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type networkInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewNetworkInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredNetworkInformer(client, resyncPeriod, indexers, nil)
+ return NewNetworkInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredNetworkInformer constructs a new informer for Network type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredNetworkInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewNetworkInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewNetworkInformerWithOptions constructs a new informer for Network type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewNetworkInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1", Resource: "networks"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Networks().List(context.Background(), options)
+ return client.ConfigV1().Networks().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Networks().Watch(context.Background(), options)
+ return client.ConfigV1().Networks().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Networks().List(ctx, options)
+ return client.ConfigV1().Networks().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Networks().Watch(ctx, options)
+ return client.ConfigV1().Networks().Watch(ctx, opts)
},
}, client),
&apiconfigv1.Network{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *networkInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredNetworkInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewNetworkInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *networkInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/node.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/node.go
index 666868895c..4f5f58479a 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/node.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/node.go
@@ -12,6 +12,7 @@ import (
configv1 "github.com/openshift/client-go/config/listers/config/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type nodeInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewNodeInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredNodeInformer(client, resyncPeriod, indexers, nil)
+ return NewNodeInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredNodeInformer constructs a new informer for Node type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredNodeInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewNodeInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewNodeInformerWithOptions constructs a new informer for Node type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewNodeInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1", Resource: "nodes"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Nodes().List(context.Background(), options)
+ return client.ConfigV1().Nodes().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Nodes().Watch(context.Background(), options)
+ return client.ConfigV1().Nodes().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Nodes().List(ctx, options)
+ return client.ConfigV1().Nodes().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Nodes().Watch(ctx, options)
+ return client.ConfigV1().Nodes().Watch(ctx, opts)
},
}, client),
&apiconfigv1.Node{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *nodeInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredNodeInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewNodeInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *nodeInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/oauth.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/oauth.go
index bd19ddeea6..a0162ac6f7 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/oauth.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/oauth.go
@@ -12,6 +12,7 @@ import (
configv1 "github.com/openshift/client-go/config/listers/config/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type oAuthInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewOAuthInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredOAuthInformer(client, resyncPeriod, indexers, nil)
+ return NewOAuthInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredOAuthInformer constructs a new informer for OAuth type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredOAuthInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewOAuthInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewOAuthInformerWithOptions constructs a new informer for OAuth type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewOAuthInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1", Resource: "oauths"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().OAuths().List(context.Background(), options)
+ return client.ConfigV1().OAuths().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().OAuths().Watch(context.Background(), options)
+ return client.ConfigV1().OAuths().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().OAuths().List(ctx, options)
+ return client.ConfigV1().OAuths().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().OAuths().Watch(ctx, options)
+ return client.ConfigV1().OAuths().Watch(ctx, opts)
},
}, client),
&apiconfigv1.OAuth{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *oAuthInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredOAuthInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewOAuthInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *oAuthInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/operatorhub.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/operatorhub.go
index eb76c7694b..0633f748e6 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/operatorhub.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/operatorhub.go
@@ -12,6 +12,7 @@ import (
configv1 "github.com/openshift/client-go/config/listers/config/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type operatorHubInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewOperatorHubInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredOperatorHubInformer(client, resyncPeriod, indexers, nil)
+ return NewOperatorHubInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredOperatorHubInformer constructs a new informer for OperatorHub type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredOperatorHubInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewOperatorHubInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewOperatorHubInformerWithOptions constructs a new informer for OperatorHub type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewOperatorHubInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1", Resource: "operatorhubs"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().OperatorHubs().List(context.Background(), options)
+ return client.ConfigV1().OperatorHubs().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().OperatorHubs().Watch(context.Background(), options)
+ return client.ConfigV1().OperatorHubs().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().OperatorHubs().List(ctx, options)
+ return client.ConfigV1().OperatorHubs().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().OperatorHubs().Watch(ctx, options)
+ return client.ConfigV1().OperatorHubs().Watch(ctx, opts)
},
}, client),
&apiconfigv1.OperatorHub{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *operatorHubInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredOperatorHubInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewOperatorHubInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *operatorHubInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/project.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/project.go
index bcbdabcc6e..cdc3875a83 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/project.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/project.go
@@ -12,6 +12,7 @@ import (
configv1 "github.com/openshift/client-go/config/listers/config/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type projectInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewProjectInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredProjectInformer(client, resyncPeriod, indexers, nil)
+ return NewProjectInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredProjectInformer constructs a new informer for Project type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredProjectInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewProjectInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewProjectInformerWithOptions constructs a new informer for Project type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewProjectInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1", Resource: "projects"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Projects().List(context.Background(), options)
+ return client.ConfigV1().Projects().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Projects().Watch(context.Background(), options)
+ return client.ConfigV1().Projects().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Projects().List(ctx, options)
+ return client.ConfigV1().Projects().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Projects().Watch(ctx, options)
+ return client.ConfigV1().Projects().Watch(ctx, opts)
},
}, client),
&apiconfigv1.Project{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *projectInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredProjectInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewProjectInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *projectInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/proxy.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/proxy.go
index 12dc67e518..be463759c5 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/proxy.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/proxy.go
@@ -12,6 +12,7 @@ import (
configv1 "github.com/openshift/client-go/config/listers/config/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type proxyInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewProxyInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredProxyInformer(client, resyncPeriod, indexers, nil)
+ return NewProxyInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredProxyInformer constructs a new informer for Proxy type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredProxyInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewProxyInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewProxyInformerWithOptions constructs a new informer for Proxy type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewProxyInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1", Resource: "proxys"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Proxies().List(context.Background(), options)
+ return client.ConfigV1().Proxies().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Proxies().Watch(context.Background(), options)
+ return client.ConfigV1().Proxies().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Proxies().List(ctx, options)
+ return client.ConfigV1().Proxies().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Proxies().Watch(ctx, options)
+ return client.ConfigV1().Proxies().Watch(ctx, opts)
},
}, client),
&apiconfigv1.Proxy{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *proxyInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredProxyInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewProxyInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *proxyInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/scheduler.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/scheduler.go
index f31b64a3a4..6a390cd6ce 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/scheduler.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1/scheduler.go
@@ -12,6 +12,7 @@ import (
configv1 "github.com/openshift/client-go/config/listers/config/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type schedulerInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewSchedulerInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredSchedulerInformer(client, resyncPeriod, indexers, nil)
+ return NewSchedulerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredSchedulerInformer constructs a new informer for Scheduler type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredSchedulerInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewSchedulerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewSchedulerInformerWithOptions constructs a new informer for Scheduler type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewSchedulerInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1", Resource: "schedulers"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Schedulers().List(context.Background(), options)
+ return client.ConfigV1().Schedulers().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Schedulers().Watch(context.Background(), options)
+ return client.ConfigV1().Schedulers().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Schedulers().List(ctx, options)
+ return client.ConfigV1().Schedulers().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1().Schedulers().Watch(ctx, options)
+ return client.ConfigV1().Schedulers().Watch(ctx, opts)
},
}, client),
&apiconfigv1.Scheduler{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *schedulerInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredSchedulerInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewSchedulerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *schedulerInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/backup.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/backup.go
index 43a7e5abc6..e3ddf964a3 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/backup.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/backup.go
@@ -12,6 +12,7 @@ import (
configv1alpha1 "github.com/openshift/client-go/config/listers/config/v1alpha1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type backupInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewBackupInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredBackupInformer(client, resyncPeriod, indexers, nil)
+ return NewBackupInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredBackupInformer constructs a new informer for Backup type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredBackupInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewBackupInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewBackupInformerWithOptions constructs a new informer for Backup type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewBackupInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1alpha1", Resource: "backups"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options v1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts v1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1alpha1().Backups().List(context.Background(), options)
+ return client.ConfigV1alpha1().Backups().List(context.Background(), opts)
},
- WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts v1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1alpha1().Backups().Watch(context.Background(), options)
+ return client.ConfigV1alpha1().Backups().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options v1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts v1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1alpha1().Backups().List(ctx, options)
+ return client.ConfigV1alpha1().Backups().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options v1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1alpha1().Backups().Watch(ctx, options)
+ return client.ConfigV1alpha1().Backups().Watch(ctx, opts)
},
}, client),
&apiconfigv1alpha1.Backup{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *backupInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredBackupInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewBackupInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *backupInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/clusterimagepolicy.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/clusterimagepolicy.go
deleted file mode 100644
index af5c3e27f1..0000000000
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/clusterimagepolicy.go
+++ /dev/null
@@ -1,85 +0,0 @@
-// Code generated by informer-gen. DO NOT EDIT.
-
-package v1alpha1
-
-import (
- context "context"
- time "time"
-
- apiconfigv1alpha1 "github.com/openshift/api/config/v1alpha1"
- versioned "github.com/openshift/client-go/config/clientset/versioned"
- internalinterfaces "github.com/openshift/client-go/config/informers/externalversions/internalinterfaces"
- configv1alpha1 "github.com/openshift/client-go/config/listers/config/v1alpha1"
- v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
- runtime "k8s.io/apimachinery/pkg/runtime"
- watch "k8s.io/apimachinery/pkg/watch"
- cache "k8s.io/client-go/tools/cache"
-)
-
-// ClusterImagePolicyInformer provides access to a shared informer and lister for
-// ClusterImagePolicies.
-type ClusterImagePolicyInformer interface {
- Informer() cache.SharedIndexInformer
- Lister() configv1alpha1.ClusterImagePolicyLister
-}
-
-type clusterImagePolicyInformer struct {
- factory internalinterfaces.SharedInformerFactory
- tweakListOptions internalinterfaces.TweakListOptionsFunc
-}
-
-// NewClusterImagePolicyInformer constructs a new informer for ClusterImagePolicy type.
-// Always prefer using an informer factory to get a shared informer instead of getting an independent
-// one. This reduces memory footprint and number of connections to the server.
-func NewClusterImagePolicyInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredClusterImagePolicyInformer(client, resyncPeriod, indexers, nil)
-}
-
-// NewFilteredClusterImagePolicyInformer constructs a new informer for ClusterImagePolicy type.
-// Always prefer using an informer factory to get a shared informer instead of getting an independent
-// one. This reduces memory footprint and number of connections to the server.
-func NewFilteredClusterImagePolicyInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
- cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options v1.ListOptions) (runtime.Object, error) {
- if tweakListOptions != nil {
- tweakListOptions(&options)
- }
- return client.ConfigV1alpha1().ClusterImagePolicies().List(context.Background(), options)
- },
- WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
- if tweakListOptions != nil {
- tweakListOptions(&options)
- }
- return client.ConfigV1alpha1().ClusterImagePolicies().Watch(context.Background(), options)
- },
- ListWithContextFunc: func(ctx context.Context, options v1.ListOptions) (runtime.Object, error) {
- if tweakListOptions != nil {
- tweakListOptions(&options)
- }
- return client.ConfigV1alpha1().ClusterImagePolicies().List(ctx, options)
- },
- WatchFuncWithContext: func(ctx context.Context, options v1.ListOptions) (watch.Interface, error) {
- if tweakListOptions != nil {
- tweakListOptions(&options)
- }
- return client.ConfigV1alpha1().ClusterImagePolicies().Watch(ctx, options)
- },
- }, client),
- &apiconfigv1alpha1.ClusterImagePolicy{},
- resyncPeriod,
- indexers,
- )
-}
-
-func (f *clusterImagePolicyInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredClusterImagePolicyInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
-}
-
-func (f *clusterImagePolicyInformer) Informer() cache.SharedIndexInformer {
- return f.factory.InformerFor(&apiconfigv1alpha1.ClusterImagePolicy{}, f.defaultInformer)
-}
-
-func (f *clusterImagePolicyInformer) Lister() configv1alpha1.ClusterImagePolicyLister {
- return configv1alpha1.NewClusterImagePolicyLister(f.Informer().GetIndexer())
-}
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/clustermonitoring.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/clustermonitoring.go
index 36e2fa631e..73d70fb331 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/clustermonitoring.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/clustermonitoring.go
@@ -12,6 +12,7 @@ import (
configv1alpha1 "github.com/openshift/client-go/config/listers/config/v1alpha1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type clusterMonitoringInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewClusterMonitoringInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredClusterMonitoringInformer(client, resyncPeriod, indexers, nil)
+ return NewClusterMonitoringInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredClusterMonitoringInformer constructs a new informer for ClusterMonitoring type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredClusterMonitoringInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewClusterMonitoringInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewClusterMonitoringInformerWithOptions constructs a new informer for ClusterMonitoring type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewClusterMonitoringInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1alpha1", Resource: "clustermonitorings"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options v1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts v1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1alpha1().ClusterMonitorings().List(context.Background(), options)
+ return client.ConfigV1alpha1().ClusterMonitorings().List(context.Background(), opts)
},
- WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts v1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1alpha1().ClusterMonitorings().Watch(context.Background(), options)
+ return client.ConfigV1alpha1().ClusterMonitorings().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options v1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts v1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1alpha1().ClusterMonitorings().List(ctx, options)
+ return client.ConfigV1alpha1().ClusterMonitorings().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options v1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1alpha1().ClusterMonitorings().Watch(ctx, options)
+ return client.ConfigV1alpha1().ClusterMonitorings().Watch(ctx, opts)
},
}, client),
&apiconfigv1alpha1.ClusterMonitoring{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *clusterMonitoringInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredClusterMonitoringInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewClusterMonitoringInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *clusterMonitoringInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/criocredentialproviderconfig.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/criocredentialproviderconfig.go
index 132ca8041e..c3c241a388 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/criocredentialproviderconfig.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/criocredentialproviderconfig.go
@@ -12,6 +12,7 @@ import (
configv1alpha1 "github.com/openshift/client-go/config/listers/config/v1alpha1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type cRIOCredentialProviderConfigInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewCRIOCredentialProviderConfigInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredCRIOCredentialProviderConfigInformer(client, resyncPeriod, indexers, nil)
+ return NewCRIOCredentialProviderConfigInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredCRIOCredentialProviderConfigInformer constructs a new informer for CRIOCredentialProviderConfig type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredCRIOCredentialProviderConfigInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewCRIOCredentialProviderConfigInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewCRIOCredentialProviderConfigInformerWithOptions constructs a new informer for CRIOCredentialProviderConfig type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewCRIOCredentialProviderConfigInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1alpha1", Resource: "criocredentialproviderconfigs"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options v1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts v1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1alpha1().CRIOCredentialProviderConfigs().List(context.Background(), options)
+ return client.ConfigV1alpha1().CRIOCredentialProviderConfigs().List(context.Background(), opts)
},
- WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts v1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1alpha1().CRIOCredentialProviderConfigs().Watch(context.Background(), options)
+ return client.ConfigV1alpha1().CRIOCredentialProviderConfigs().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options v1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts v1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1alpha1().CRIOCredentialProviderConfigs().List(ctx, options)
+ return client.ConfigV1alpha1().CRIOCredentialProviderConfigs().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options v1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1alpha1().CRIOCredentialProviderConfigs().Watch(ctx, options)
+ return client.ConfigV1alpha1().CRIOCredentialProviderConfigs().Watch(ctx, opts)
},
}, client),
&apiconfigv1alpha1.CRIOCredentialProviderConfig{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *cRIOCredentialProviderConfigInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredCRIOCredentialProviderConfigInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewCRIOCredentialProviderConfigInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *cRIOCredentialProviderConfigInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/imagepolicy.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/imagepolicy.go
deleted file mode 100644
index d56c1e834f..0000000000
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/imagepolicy.go
+++ /dev/null
@@ -1,86 +0,0 @@
-// Code generated by informer-gen. DO NOT EDIT.
-
-package v1alpha1
-
-import (
- context "context"
- time "time"
-
- apiconfigv1alpha1 "github.com/openshift/api/config/v1alpha1"
- versioned "github.com/openshift/client-go/config/clientset/versioned"
- internalinterfaces "github.com/openshift/client-go/config/informers/externalversions/internalinterfaces"
- configv1alpha1 "github.com/openshift/client-go/config/listers/config/v1alpha1"
- v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
- runtime "k8s.io/apimachinery/pkg/runtime"
- watch "k8s.io/apimachinery/pkg/watch"
- cache "k8s.io/client-go/tools/cache"
-)
-
-// ImagePolicyInformer provides access to a shared informer and lister for
-// ImagePolicies.
-type ImagePolicyInformer interface {
- Informer() cache.SharedIndexInformer
- Lister() configv1alpha1.ImagePolicyLister
-}
-
-type imagePolicyInformer struct {
- factory internalinterfaces.SharedInformerFactory
- tweakListOptions internalinterfaces.TweakListOptionsFunc
- namespace string
-}
-
-// NewImagePolicyInformer constructs a new informer for ImagePolicy type.
-// Always prefer using an informer factory to get a shared informer instead of getting an independent
-// one. This reduces memory footprint and number of connections to the server.
-func NewImagePolicyInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredImagePolicyInformer(client, namespace, resyncPeriod, indexers, nil)
-}
-
-// NewFilteredImagePolicyInformer constructs a new informer for ImagePolicy type.
-// Always prefer using an informer factory to get a shared informer instead of getting an independent
-// one. This reduces memory footprint and number of connections to the server.
-func NewFilteredImagePolicyInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
- cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options v1.ListOptions) (runtime.Object, error) {
- if tweakListOptions != nil {
- tweakListOptions(&options)
- }
- return client.ConfigV1alpha1().ImagePolicies(namespace).List(context.Background(), options)
- },
- WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
- if tweakListOptions != nil {
- tweakListOptions(&options)
- }
- return client.ConfigV1alpha1().ImagePolicies(namespace).Watch(context.Background(), options)
- },
- ListWithContextFunc: func(ctx context.Context, options v1.ListOptions) (runtime.Object, error) {
- if tweakListOptions != nil {
- tweakListOptions(&options)
- }
- return client.ConfigV1alpha1().ImagePolicies(namespace).List(ctx, options)
- },
- WatchFuncWithContext: func(ctx context.Context, options v1.ListOptions) (watch.Interface, error) {
- if tweakListOptions != nil {
- tweakListOptions(&options)
- }
- return client.ConfigV1alpha1().ImagePolicies(namespace).Watch(ctx, options)
- },
- }, client),
- &apiconfigv1alpha1.ImagePolicy{},
- resyncPeriod,
- indexers,
- )
-}
-
-func (f *imagePolicyInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredImagePolicyInformer(client, f.namespace, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
-}
-
-func (f *imagePolicyInformer) Informer() cache.SharedIndexInformer {
- return f.factory.InformerFor(&apiconfigv1alpha1.ImagePolicy{}, f.defaultInformer)
-}
-
-func (f *imagePolicyInformer) Lister() configv1alpha1.ImagePolicyLister {
- return configv1alpha1.NewImagePolicyLister(f.Informer().GetIndexer())
-}
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/insightsdatagather.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/insightsdatagather.go
index 39624071e4..44e980ff79 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/insightsdatagather.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/insightsdatagather.go
@@ -12,6 +12,7 @@ import (
configv1alpha1 "github.com/openshift/client-go/config/listers/config/v1alpha1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type insightsDataGatherInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewInsightsDataGatherInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredInsightsDataGatherInformer(client, resyncPeriod, indexers, nil)
+ return NewInsightsDataGatherInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredInsightsDataGatherInformer constructs a new informer for InsightsDataGather type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredInsightsDataGatherInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewInsightsDataGatherInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewInsightsDataGatherInformerWithOptions constructs a new informer for InsightsDataGather type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewInsightsDataGatherInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1alpha1", Resource: "insightsdatagathers"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options v1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts v1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1alpha1().InsightsDataGathers().List(context.Background(), options)
+ return client.ConfigV1alpha1().InsightsDataGathers().List(context.Background(), opts)
},
- WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts v1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1alpha1().InsightsDataGathers().Watch(context.Background(), options)
+ return client.ConfigV1alpha1().InsightsDataGathers().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options v1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts v1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1alpha1().InsightsDataGathers().List(ctx, options)
+ return client.ConfigV1alpha1().InsightsDataGathers().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options v1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1alpha1().InsightsDataGathers().Watch(ctx, options)
+ return client.ConfigV1alpha1().InsightsDataGathers().Watch(ctx, opts)
},
}, client),
&apiconfigv1alpha1.InsightsDataGather{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *insightsDataGatherInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredInsightsDataGatherInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewInsightsDataGatherInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *insightsDataGatherInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/interface.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/interface.go
index 5d0818a188..17b0ebcc0b 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/interface.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/interface.go
@@ -12,12 +12,8 @@ type Interface interface {
Backups() BackupInformer
// CRIOCredentialProviderConfigs returns a CRIOCredentialProviderConfigInformer.
CRIOCredentialProviderConfigs() CRIOCredentialProviderConfigInformer
- // ClusterImagePolicies returns a ClusterImagePolicyInformer.
- ClusterImagePolicies() ClusterImagePolicyInformer
// ClusterMonitorings returns a ClusterMonitoringInformer.
ClusterMonitorings() ClusterMonitoringInformer
- // ImagePolicies returns a ImagePolicyInformer.
- ImagePolicies() ImagePolicyInformer
// InsightsDataGathers returns a InsightsDataGatherInformer.
InsightsDataGathers() InsightsDataGatherInformer
// PKIs returns a PKIInformer.
@@ -45,21 +41,11 @@ func (v *version) CRIOCredentialProviderConfigs() CRIOCredentialProviderConfigIn
return &cRIOCredentialProviderConfigInformer{factory: v.factory, tweakListOptions: v.tweakListOptions}
}
-// ClusterImagePolicies returns a ClusterImagePolicyInformer.
-func (v *version) ClusterImagePolicies() ClusterImagePolicyInformer {
- return &clusterImagePolicyInformer{factory: v.factory, tweakListOptions: v.tweakListOptions}
-}
-
// ClusterMonitorings returns a ClusterMonitoringInformer.
func (v *version) ClusterMonitorings() ClusterMonitoringInformer {
return &clusterMonitoringInformer{factory: v.factory, tweakListOptions: v.tweakListOptions}
}
-// ImagePolicies returns a ImagePolicyInformer.
-func (v *version) ImagePolicies() ImagePolicyInformer {
- return &imagePolicyInformer{factory: v.factory, namespace: v.namespace, tweakListOptions: v.tweakListOptions}
-}
-
// InsightsDataGathers returns a InsightsDataGatherInformer.
func (v *version) InsightsDataGathers() InsightsDataGatherInformer {
return &insightsDataGatherInformer{factory: v.factory, tweakListOptions: v.tweakListOptions}
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/pki.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/pki.go
index 3613eec8c0..1dce29e56b 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/pki.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha1/pki.go
@@ -12,6 +12,7 @@ import (
configv1alpha1 "github.com/openshift/client-go/config/listers/config/v1alpha1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type pKIInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewPKIInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredPKIInformer(client, resyncPeriod, indexers, nil)
+ return NewPKIInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredPKIInformer constructs a new informer for PKI type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredPKIInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewPKIInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewPKIInformerWithOptions constructs a new informer for PKI type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewPKIInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1alpha1", Resource: "pkis"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options v1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts v1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1alpha1().PKIs().List(context.Background(), options)
+ return client.ConfigV1alpha1().PKIs().List(context.Background(), opts)
},
- WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts v1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1alpha1().PKIs().Watch(context.Background(), options)
+ return client.ConfigV1alpha1().PKIs().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options v1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts v1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1alpha1().PKIs().List(ctx, options)
+ return client.ConfigV1alpha1().PKIs().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options v1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1alpha1().PKIs().Watch(ctx, options)
+ return client.ConfigV1alpha1().PKIs().Watch(ctx, opts)
},
}, client),
&apiconfigv1alpha1.PKI{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *pKIInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredPKIInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewPKIInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *pKIInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha2/insightsdatagather.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha2/insightsdatagather.go
index 471c79f1e8..1b20501cf6 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha2/insightsdatagather.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/config/v1alpha2/insightsdatagather.go
@@ -12,6 +12,7 @@ import (
configv1alpha2 "github.com/openshift/client-go/config/listers/config/v1alpha2"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type insightsDataGatherInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewInsightsDataGatherInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredInsightsDataGatherInformer(client, resyncPeriod, indexers, nil)
+ return NewInsightsDataGatherInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredInsightsDataGatherInformer constructs a new informer for InsightsDataGather type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredInsightsDataGatherInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewInsightsDataGatherInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewInsightsDataGatherInformerWithOptions constructs a new informer for InsightsDataGather type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewInsightsDataGatherInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "config.openshift.io", Version: "v1alpha2", Resource: "insightsdatagathers"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options v1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts v1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1alpha2().InsightsDataGathers().List(context.Background(), options)
+ return client.ConfigV1alpha2().InsightsDataGathers().List(context.Background(), opts)
},
- WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts v1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1alpha2().InsightsDataGathers().Watch(context.Background(), options)
+ return client.ConfigV1alpha2().InsightsDataGathers().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options v1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts v1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1alpha2().InsightsDataGathers().List(ctx, options)
+ return client.ConfigV1alpha2().InsightsDataGathers().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options v1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ConfigV1alpha2().InsightsDataGathers().Watch(ctx, options)
+ return client.ConfigV1alpha2().InsightsDataGathers().Watch(ctx, opts)
},
}, client),
&apiconfigv1alpha2.InsightsDataGather{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *insightsDataGatherInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredInsightsDataGatherInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewInsightsDataGatherInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *insightsDataGatherInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/factory.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/factory.go
index befdfaabd0..1e357ea7b4 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/factory.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/factory.go
@@ -3,6 +3,7 @@
package externalversions
import (
+ context "context"
reflect "reflect"
sync "sync"
time "time"
@@ -13,6 +14,7 @@ import (
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
schema "k8s.io/apimachinery/pkg/runtime/schema"
+ wait "k8s.io/apimachinery/pkg/util/wait"
cache "k8s.io/client-go/tools/cache"
)
@@ -27,6 +29,7 @@ type sharedInformerFactory struct {
defaultResync time.Duration
customResync map[reflect.Type]time.Duration
transform cache.TransformFunc
+ informerName *cache.InformerName
informers map[reflect.Type]cache.SharedIndexInformer
// startedInformers is used for tracking which informers have been started.
@@ -73,6 +76,21 @@ func WithTransform(transform cache.TransformFunc) SharedInformerOption {
}
}
+// WithInformerName sets the InformerName for informer identity used in metrics.
+// The InformerName must be created via cache.NewInformerName() at startup,
+// which validates global uniqueness. Each informer type will register its
+// GVR under this name.
+func WithInformerName(informerName *cache.InformerName) SharedInformerOption {
+ return func(factory *sharedInformerFactory) *sharedInformerFactory {
+ factory.informerName = informerName
+ return factory
+ }
+}
+
+func (f *sharedInformerFactory) InformerName() *cache.InformerName {
+ return f.informerName
+}
+
// NewSharedInformerFactory constructs a new instance of sharedInformerFactory for all namespaces.
func NewSharedInformerFactory(client versioned.Interface, defaultResync time.Duration) SharedInformerFactory {
return NewSharedInformerFactoryWithOptions(client, defaultResync)
@@ -107,6 +125,10 @@ func NewSharedInformerFactoryWithOptions(client versioned.Interface, defaultResy
}
func (f *sharedInformerFactory) Start(stopCh <-chan struct{}) {
+ f.StartWithContext(wait.ContextForChannel(stopCh))
+}
+
+func (f *sharedInformerFactory) StartWithContext(ctx context.Context) {
f.lock.Lock()
defer f.lock.Unlock()
@@ -116,15 +138,9 @@ func (f *sharedInformerFactory) Start(stopCh <-chan struct{}) {
for informerType, informer := range f.informers {
if !f.startedInformers[informerType] {
- f.wg.Add(1)
- // We need a new variable in each loop iteration,
- // otherwise the goroutine would use the loop variable
- // and that keeps changing.
- informer := informer
- go func() {
- defer f.wg.Done()
- informer.Run(stopCh)
- }()
+ f.wg.Go(func() {
+ informer.RunWithContext(ctx)
+ })
f.startedInformers[informerType] = true
}
}
@@ -137,9 +153,15 @@ func (f *sharedInformerFactory) Shutdown() {
// Will return immediately if there is nothing to wait for.
f.wg.Wait()
+ f.informerName.Release()
}
func (f *sharedInformerFactory) WaitForCacheSync(stopCh <-chan struct{}) map[reflect.Type]bool {
+ result := f.WaitForCacheSyncWithContext(wait.ContextForChannel(stopCh))
+ return result.Synced
+}
+
+func (f *sharedInformerFactory) WaitForCacheSyncWithContext(ctx context.Context) cache.SyncResult {
informers := func() map[reflect.Type]cache.SharedIndexInformer {
f.lock.Lock()
defer f.lock.Unlock()
@@ -153,10 +175,31 @@ func (f *sharedInformerFactory) WaitForCacheSync(stopCh <-chan struct{}) map[ref
return informers
}()
- res := map[reflect.Type]bool{}
+ // Wait for informers to sync, without polling.
+ cacheSyncs := make([]cache.DoneChecker, 0, len(informers))
+ for _, informer := range informers {
+ cacheSyncs = append(cacheSyncs, informer.HasSyncedChecker())
+ }
+ cache.WaitFor(ctx, "" /* no logging */, cacheSyncs...)
+
+ res := cache.SyncResult{
+ Synced: make(map[reflect.Type]bool, len(informers)),
+ }
+ failed := false
for informType, informer := range informers {
- res[informType] = cache.WaitForCacheSync(stopCh, informer.HasSynced)
+ hasSynced := informer.HasSynced()
+ if !hasSynced {
+ failed = true
+ }
+ res.Synced[informType] = hasSynced
}
+ if failed {
+ // context.Cause is more informative than ctx.Err().
+ // This must be non-nil, otherwise WaitFor wouldn't have stopped
+ // prematurely.
+ res.Err = context.Cause(ctx)
+ }
+
return res
}
@@ -178,7 +221,9 @@ func (f *sharedInformerFactory) InformerFor(obj runtime.Object, newFunc internal
}
informer = newFunc(f.client, resyncPeriod)
- informer.SetTransform(f.transform)
+ if f.transform != nil {
+ informer.SetTransform(f.transform)
+ }
f.informers[informerType] = informer
return informer
@@ -195,27 +240,46 @@ func (f *sharedInformerFactory) InformerFor(obj runtime.Object, newFunc internal
// defer factory.WaitForStop() // Returns immediately if nothing was started.
// genericInformer := factory.ForResource(resource)
// typedInformer := factory.SomeAPIGroup().V1().SomeType()
-// factory.Start(ctx.Done()) // Start processing these informers.
-// synced := factory.WaitForCacheSync(ctx.Done())
-// for v, ok := range synced {
-// if !ok {
-// fmt.Fprintf(os.Stderr, "caches failed to sync: %v", v)
-// return
-// }
+// handle, err := typeInformer.Informer().AddEventHandler(...)
+// if err != nil {
+// return fmt.Errorf("register event handler: %v", err)
+// }
+// defer typeInformer.Informer().RemoveEventHandler(handle) // Avoids leaking goroutines.
+// factory.StartWithContext(ctx) // Start processing these informers.
+// synced := factory.WaitForCacheSyncWithContext(ctx)
+// if err := synced.AsError(); err != nil {
+// return err
+// }
+// for v := range synced {
+// // Only if desired log some information similar to this.
+// fmt.Fprintf(os.Stdout, "cache synced: %s", v)
+// }
+//
+// // Also make sure that all of the initial cache events have been delivered.
+// if !WaitFor(ctx, "event handler sync", handle.HasSyncedChecker()) {
+// // Must have failed because of context.
+// return fmt.Errorf("sync event handler: %w", context.Cause(ctx))
// }
//
// // Creating informers can also be created after Start, but then
// // Start must be called again:
// anotherGenericInformer := factory.ForResource(resource)
-// factory.Start(ctx.Done())
+// factory.StartWithContext(ctx)
type SharedInformerFactory interface {
internalinterfaces.SharedInformerFactory
// Start initializes all requested informers. They are handled in goroutines
// which run until the stop channel gets closed.
// Warning: Start does not block. When run in a go-routine, it will race with a later WaitForCacheSync.
+ //
+ // Contextual logging: StartWithContext should be used instead of Start in code which supports contextual logging.
Start(stopCh <-chan struct{})
+ // StartWithContext initializes all requested informers. They are handled in goroutines
+ // which run until the context gets canceled.
+ // Warning: StartWithContext does not block. When run in a go-routine, it will race with a later WaitForCacheSync.
+ StartWithContext(ctx context.Context)
+
// Shutdown marks a factory as shutting down. At that point no new
// informers can be started anymore and Start will return without
// doing anything.
@@ -230,8 +294,14 @@ type SharedInformerFactory interface {
// WaitForCacheSync blocks until all started informers' caches were synced
// or the stop channel gets closed.
+ //
+ // Contextual logging: WaitForCacheSync should be used instead of WaitForCacheSync in code which supports contextual logging. It also returns a more useful result.
WaitForCacheSync(stopCh <-chan struct{}) map[reflect.Type]bool
+ // WaitForCacheSyncWithContext blocks until all started informers' caches were synced
+ // or the context gets canceled.
+ WaitForCacheSyncWithContext(ctx context.Context) cache.SyncResult
+
// ForResource gives generic access to a shared informer of the matching type.
ForResource(resource schema.GroupVersionResource) (GenericInformer, error)
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/generic.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/generic.go
index 3e7ec33751..fbc19aaefd 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/generic.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/generic.go
@@ -45,6 +45,8 @@ func (f *sharedInformerFactory) ForResource(resource schema.GroupVersionResource
return &genericInformer{resource: resource.GroupResource(), informer: f.Config().V1().Authentications().Informer()}, nil
case v1.SchemeGroupVersion.WithResource("builds"):
return &genericInformer{resource: resource.GroupResource(), informer: f.Config().V1().Builds().Informer()}, nil
+ case v1.SchemeGroupVersion.WithResource("criocredentialproviderconfigs"):
+ return &genericInformer{resource: resource.GroupResource(), informer: f.Config().V1().CRIOCredentialProviderConfigs().Informer()}, nil
case v1.SchemeGroupVersion.WithResource("clusterimagepolicies"):
return &genericInformer{resource: resource.GroupResource(), informer: f.Config().V1().ClusterImagePolicies().Informer()}, nil
case v1.SchemeGroupVersion.WithResource("clusteroperators"):
@@ -93,12 +95,8 @@ func (f *sharedInformerFactory) ForResource(resource schema.GroupVersionResource
return &genericInformer{resource: resource.GroupResource(), informer: f.Config().V1alpha1().Backups().Informer()}, nil
case v1alpha1.SchemeGroupVersion.WithResource("criocredentialproviderconfigs"):
return &genericInformer{resource: resource.GroupResource(), informer: f.Config().V1alpha1().CRIOCredentialProviderConfigs().Informer()}, nil
- case v1alpha1.SchemeGroupVersion.WithResource("clusterimagepolicies"):
- return &genericInformer{resource: resource.GroupResource(), informer: f.Config().V1alpha1().ClusterImagePolicies().Informer()}, nil
case v1alpha1.SchemeGroupVersion.WithResource("clustermonitorings"):
return &genericInformer{resource: resource.GroupResource(), informer: f.Config().V1alpha1().ClusterMonitorings().Informer()}, nil
- case v1alpha1.SchemeGroupVersion.WithResource("imagepolicies"):
- return &genericInformer{resource: resource.GroupResource(), informer: f.Config().V1alpha1().ImagePolicies().Informer()}, nil
case v1alpha1.SchemeGroupVersion.WithResource("insightsdatagathers"):
return &genericInformer{resource: resource.GroupResource(), informer: f.Config().V1alpha1().InsightsDataGathers().Informer()}, nil
case v1alpha1.SchemeGroupVersion.WithResource("pkis"):
diff --git a/vendor/github.com/openshift/client-go/config/informers/externalversions/internalinterfaces/factory_interfaces.go b/vendor/github.com/openshift/client-go/config/informers/externalversions/internalinterfaces/factory_interfaces.go
index 720235c485..28d9ec5e5e 100644
--- a/vendor/github.com/openshift/client-go/config/informers/externalversions/internalinterfaces/factory_interfaces.go
+++ b/vendor/github.com/openshift/client-go/config/informers/externalversions/internalinterfaces/factory_interfaces.go
@@ -18,7 +18,26 @@ type NewInformerFunc func(versioned.Interface, time.Duration) cache.SharedIndexI
type SharedInformerFactory interface {
Start(stopCh <-chan struct{})
InformerFor(obj runtime.Object, newFunc NewInformerFunc) cache.SharedIndexInformer
+ InformerName() *cache.InformerName
}
// TweakListOptionsFunc is a function that transforms a v1.ListOptions.
type TweakListOptionsFunc func(*v1.ListOptions)
+
+// InformerOptions holds the options for creating an informer.
+type InformerOptions struct {
+ // ResyncPeriod is the resync period for this informer.
+ // If not set, defaults to 0 (no resync).
+ ResyncPeriod time.Duration
+
+ // Indexers are the indexers for this informer.
+ Indexers cache.Indexers
+
+ // InformerName is used to uniquely identify this informer for metrics.
+ // If not set, metrics will not be published for this informer.
+ // Use cache.NewInformerName() to create an InformerName at startup.
+ InformerName *cache.InformerName
+
+ // TweakListOptions is an optional function to modify the list options.
+ TweakListOptions TweakListOptionsFunc
+}
diff --git a/vendor/github.com/openshift/client-go/config/listers/config/v1/criocredentialproviderconfig.go b/vendor/github.com/openshift/client-go/config/listers/config/v1/criocredentialproviderconfig.go
new file mode 100644
index 0000000000..7b4c42adeb
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/config/listers/config/v1/criocredentialproviderconfig.go
@@ -0,0 +1,32 @@
+// Code generated by lister-gen. DO NOT EDIT.
+
+package v1
+
+import (
+ configv1 "github.com/openshift/api/config/v1"
+ labels "k8s.io/apimachinery/pkg/labels"
+ listers "k8s.io/client-go/listers"
+ cache "k8s.io/client-go/tools/cache"
+)
+
+// CRIOCredentialProviderConfigLister helps list CRIOCredentialProviderConfigs.
+// All objects returned here must be treated as read-only.
+type CRIOCredentialProviderConfigLister interface {
+ // List lists all CRIOCredentialProviderConfigs in the indexer.
+ // Objects returned here must be treated as read-only.
+ List(selector labels.Selector) (ret []*configv1.CRIOCredentialProviderConfig, err error)
+ // Get retrieves the CRIOCredentialProviderConfig from the index for a given name.
+ // Objects returned here must be treated as read-only.
+ Get(name string) (*configv1.CRIOCredentialProviderConfig, error)
+ CRIOCredentialProviderConfigListerExpansion
+}
+
+// cRIOCredentialProviderConfigLister implements the CRIOCredentialProviderConfigLister interface.
+type cRIOCredentialProviderConfigLister struct {
+ listers.ResourceIndexer[*configv1.CRIOCredentialProviderConfig]
+}
+
+// NewCRIOCredentialProviderConfigLister returns a new CRIOCredentialProviderConfigLister.
+func NewCRIOCredentialProviderConfigLister(indexer cache.Indexer) CRIOCredentialProviderConfigLister {
+ return &cRIOCredentialProviderConfigLister{listers.New[*configv1.CRIOCredentialProviderConfig](indexer, configv1.Resource("criocredentialproviderconfig"))}
+}
diff --git a/vendor/github.com/openshift/client-go/config/listers/config/v1/expansion_generated.go b/vendor/github.com/openshift/client-go/config/listers/config/v1/expansion_generated.go
index ca93cb2838..f41c1f2fb4 100644
--- a/vendor/github.com/openshift/client-go/config/listers/config/v1/expansion_generated.go
+++ b/vendor/github.com/openshift/client-go/config/listers/config/v1/expansion_generated.go
@@ -14,6 +14,10 @@ type AuthenticationListerExpansion interface{}
// BuildLister.
type BuildListerExpansion interface{}
+// CRIOCredentialProviderConfigListerExpansion allows custom methods to be added to
+// CRIOCredentialProviderConfigLister.
+type CRIOCredentialProviderConfigListerExpansion interface{}
+
// ClusterImagePolicyListerExpansion allows custom methods to be added to
// ClusterImagePolicyLister.
type ClusterImagePolicyListerExpansion interface{}
diff --git a/vendor/github.com/openshift/client-go/config/listers/config/v1alpha1/clusterimagepolicy.go b/vendor/github.com/openshift/client-go/config/listers/config/v1alpha1/clusterimagepolicy.go
deleted file mode 100644
index 0512d3682f..0000000000
--- a/vendor/github.com/openshift/client-go/config/listers/config/v1alpha1/clusterimagepolicy.go
+++ /dev/null
@@ -1,32 +0,0 @@
-// Code generated by lister-gen. DO NOT EDIT.
-
-package v1alpha1
-
-import (
- configv1alpha1 "github.com/openshift/api/config/v1alpha1"
- labels "k8s.io/apimachinery/pkg/labels"
- listers "k8s.io/client-go/listers"
- cache "k8s.io/client-go/tools/cache"
-)
-
-// ClusterImagePolicyLister helps list ClusterImagePolicies.
-// All objects returned here must be treated as read-only.
-type ClusterImagePolicyLister interface {
- // List lists all ClusterImagePolicies in the indexer.
- // Objects returned here must be treated as read-only.
- List(selector labels.Selector) (ret []*configv1alpha1.ClusterImagePolicy, err error)
- // Get retrieves the ClusterImagePolicy from the index for a given name.
- // Objects returned here must be treated as read-only.
- Get(name string) (*configv1alpha1.ClusterImagePolicy, error)
- ClusterImagePolicyListerExpansion
-}
-
-// clusterImagePolicyLister implements the ClusterImagePolicyLister interface.
-type clusterImagePolicyLister struct {
- listers.ResourceIndexer[*configv1alpha1.ClusterImagePolicy]
-}
-
-// NewClusterImagePolicyLister returns a new ClusterImagePolicyLister.
-func NewClusterImagePolicyLister(indexer cache.Indexer) ClusterImagePolicyLister {
- return &clusterImagePolicyLister{listers.New[*configv1alpha1.ClusterImagePolicy](indexer, configv1alpha1.Resource("clusterimagepolicy"))}
-}
diff --git a/vendor/github.com/openshift/client-go/config/listers/config/v1alpha1/expansion_generated.go b/vendor/github.com/openshift/client-go/config/listers/config/v1alpha1/expansion_generated.go
index dbcd1a084c..3baf74bc8b 100644
--- a/vendor/github.com/openshift/client-go/config/listers/config/v1alpha1/expansion_generated.go
+++ b/vendor/github.com/openshift/client-go/config/listers/config/v1alpha1/expansion_generated.go
@@ -10,22 +10,10 @@ type BackupListerExpansion interface{}
// CRIOCredentialProviderConfigLister.
type CRIOCredentialProviderConfigListerExpansion interface{}
-// ClusterImagePolicyListerExpansion allows custom methods to be added to
-// ClusterImagePolicyLister.
-type ClusterImagePolicyListerExpansion interface{}
-
// ClusterMonitoringListerExpansion allows custom methods to be added to
// ClusterMonitoringLister.
type ClusterMonitoringListerExpansion interface{}
-// ImagePolicyListerExpansion allows custom methods to be added to
-// ImagePolicyLister.
-type ImagePolicyListerExpansion interface{}
-
-// ImagePolicyNamespaceListerExpansion allows custom methods to be added to
-// ImagePolicyNamespaceLister.
-type ImagePolicyNamespaceListerExpansion interface{}
-
// InsightsDataGatherListerExpansion allows custom methods to be added to
// InsightsDataGatherLister.
type InsightsDataGatherListerExpansion interface{}
diff --git a/vendor/github.com/openshift/client-go/config/listers/config/v1alpha1/imagepolicy.go b/vendor/github.com/openshift/client-go/config/listers/config/v1alpha1/imagepolicy.go
deleted file mode 100644
index 7050c57718..0000000000
--- a/vendor/github.com/openshift/client-go/config/listers/config/v1alpha1/imagepolicy.go
+++ /dev/null
@@ -1,54 +0,0 @@
-// Code generated by lister-gen. DO NOT EDIT.
-
-package v1alpha1
-
-import (
- configv1alpha1 "github.com/openshift/api/config/v1alpha1"
- labels "k8s.io/apimachinery/pkg/labels"
- listers "k8s.io/client-go/listers"
- cache "k8s.io/client-go/tools/cache"
-)
-
-// ImagePolicyLister helps list ImagePolicies.
-// All objects returned here must be treated as read-only.
-type ImagePolicyLister interface {
- // List lists all ImagePolicies in the indexer.
- // Objects returned here must be treated as read-only.
- List(selector labels.Selector) (ret []*configv1alpha1.ImagePolicy, err error)
- // ImagePolicies returns an object that can list and get ImagePolicies.
- ImagePolicies(namespace string) ImagePolicyNamespaceLister
- ImagePolicyListerExpansion
-}
-
-// imagePolicyLister implements the ImagePolicyLister interface.
-type imagePolicyLister struct {
- listers.ResourceIndexer[*configv1alpha1.ImagePolicy]
-}
-
-// NewImagePolicyLister returns a new ImagePolicyLister.
-func NewImagePolicyLister(indexer cache.Indexer) ImagePolicyLister {
- return &imagePolicyLister{listers.New[*configv1alpha1.ImagePolicy](indexer, configv1alpha1.Resource("imagepolicy"))}
-}
-
-// ImagePolicies returns an object that can list and get ImagePolicies.
-func (s *imagePolicyLister) ImagePolicies(namespace string) ImagePolicyNamespaceLister {
- return imagePolicyNamespaceLister{listers.NewNamespaced[*configv1alpha1.ImagePolicy](s.ResourceIndexer, namespace)}
-}
-
-// ImagePolicyNamespaceLister helps list and get ImagePolicies.
-// All objects returned here must be treated as read-only.
-type ImagePolicyNamespaceLister interface {
- // List lists all ImagePolicies in the indexer for a given namespace.
- // Objects returned here must be treated as read-only.
- List(selector labels.Selector) (ret []*configv1alpha1.ImagePolicy, err error)
- // Get retrieves the ImagePolicy from the indexer for a given namespace and name.
- // Objects returned here must be treated as read-only.
- Get(name string) (*configv1alpha1.ImagePolicy, error)
- ImagePolicyNamespaceListerExpansion
-}
-
-// imagePolicyNamespaceLister implements the ImagePolicyNamespaceLister
-// interface.
-type imagePolicyNamespaceLister struct {
- listers.ResourceIndexer[*configv1alpha1.ImagePolicy]
-}
diff --git a/vendor/github.com/openshift/client-go/image/clientset/versioned/fake/clientset_generated.go b/vendor/github.com/openshift/client-go/image/clientset/versioned/fake/clientset_generated.go
index 0be85415ac..c2a62a2ee9 100644
--- a/vendor/github.com/openshift/client-go/image/clientset/versioned/fake/clientset_generated.go
+++ b/vendor/github.com/openshift/client-go/image/clientset/versioned/fake/clientset_generated.go
@@ -19,10 +19,6 @@ import (
// It's backed by a very simple object tracker that processes creates, updates and deletions as-is,
// without applying any field management, validations and/or defaults. It shouldn't be considered a replacement
// for a real clientset and is mostly useful in simple unit tests.
-//
-// Deprecated: NewClientset replaces this with support for field management, which significantly improves
-// server side apply testing. NewClientset is only available when apply configurations are generated (e.g.
-// via --with-applyconfig).
func NewSimpleClientset(objects ...runtime.Object) *Clientset {
o := testing.NewObjectTracker(scheme, codecs.UniversalDecoder())
for _, obj := range objects {
@@ -68,7 +64,7 @@ func (c *Clientset) Tracker() testing.ObjectTracker {
return c.tracker
}
-// IsWatchListSemanticsSupported informs the reflector that this client
+// IsWatchListSemanticsUnSupported informs the reflector that this client
// doesn't support WatchList semantics.
//
// This is a synthetic method whose sole purpose is to satisfy the optional
@@ -83,6 +79,10 @@ func (c *Clientset) IsWatchListSemanticsUnSupported() bool {
// It's backed by a very simple object tracker that processes creates, updates and deletions as-is,
// without applying any validations and/or defaults. It shouldn't be considered a replacement
// for a real clientset and is mostly useful in simple unit tests.
+//
+// Compared to NewSimpleClientset, the Clientset returned here supports field tracking and thus
+// server-side apply. Beware though that support in that for CRDs is missing
+// (https://github.com/kubernetes/kubernetes/issues/126850).
func NewClientset(objects ...runtime.Object) *Clientset {
o := testing.NewFieldManagedObjectTracker(
scheme,
diff --git a/vendor/github.com/openshift/client-go/image/informers/externalversions/factory.go b/vendor/github.com/openshift/client-go/image/informers/externalversions/factory.go
index 74bef556ae..c41e80e53a 100644
--- a/vendor/github.com/openshift/client-go/image/informers/externalversions/factory.go
+++ b/vendor/github.com/openshift/client-go/image/informers/externalversions/factory.go
@@ -3,6 +3,7 @@
package externalversions
import (
+ context "context"
reflect "reflect"
sync "sync"
time "time"
@@ -13,6 +14,7 @@ import (
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
schema "k8s.io/apimachinery/pkg/runtime/schema"
+ wait "k8s.io/apimachinery/pkg/util/wait"
cache "k8s.io/client-go/tools/cache"
)
@@ -27,6 +29,7 @@ type sharedInformerFactory struct {
defaultResync time.Duration
customResync map[reflect.Type]time.Duration
transform cache.TransformFunc
+ informerName *cache.InformerName
informers map[reflect.Type]cache.SharedIndexInformer
// startedInformers is used for tracking which informers have been started.
@@ -73,6 +76,21 @@ func WithTransform(transform cache.TransformFunc) SharedInformerOption {
}
}
+// WithInformerName sets the InformerName for informer identity used in metrics.
+// The InformerName must be created via cache.NewInformerName() at startup,
+// which validates global uniqueness. Each informer type will register its
+// GVR under this name.
+func WithInformerName(informerName *cache.InformerName) SharedInformerOption {
+ return func(factory *sharedInformerFactory) *sharedInformerFactory {
+ factory.informerName = informerName
+ return factory
+ }
+}
+
+func (f *sharedInformerFactory) InformerName() *cache.InformerName {
+ return f.informerName
+}
+
// NewSharedInformerFactory constructs a new instance of sharedInformerFactory for all namespaces.
func NewSharedInformerFactory(client versioned.Interface, defaultResync time.Duration) SharedInformerFactory {
return NewSharedInformerFactoryWithOptions(client, defaultResync)
@@ -107,6 +125,10 @@ func NewSharedInformerFactoryWithOptions(client versioned.Interface, defaultResy
}
func (f *sharedInformerFactory) Start(stopCh <-chan struct{}) {
+ f.StartWithContext(wait.ContextForChannel(stopCh))
+}
+
+func (f *sharedInformerFactory) StartWithContext(ctx context.Context) {
f.lock.Lock()
defer f.lock.Unlock()
@@ -116,15 +138,9 @@ func (f *sharedInformerFactory) Start(stopCh <-chan struct{}) {
for informerType, informer := range f.informers {
if !f.startedInformers[informerType] {
- f.wg.Add(1)
- // We need a new variable in each loop iteration,
- // otherwise the goroutine would use the loop variable
- // and that keeps changing.
- informer := informer
- go func() {
- defer f.wg.Done()
- informer.Run(stopCh)
- }()
+ f.wg.Go(func() {
+ informer.RunWithContext(ctx)
+ })
f.startedInformers[informerType] = true
}
}
@@ -137,9 +153,15 @@ func (f *sharedInformerFactory) Shutdown() {
// Will return immediately if there is nothing to wait for.
f.wg.Wait()
+ f.informerName.Release()
}
func (f *sharedInformerFactory) WaitForCacheSync(stopCh <-chan struct{}) map[reflect.Type]bool {
+ result := f.WaitForCacheSyncWithContext(wait.ContextForChannel(stopCh))
+ return result.Synced
+}
+
+func (f *sharedInformerFactory) WaitForCacheSyncWithContext(ctx context.Context) cache.SyncResult {
informers := func() map[reflect.Type]cache.SharedIndexInformer {
f.lock.Lock()
defer f.lock.Unlock()
@@ -153,10 +175,31 @@ func (f *sharedInformerFactory) WaitForCacheSync(stopCh <-chan struct{}) map[ref
return informers
}()
- res := map[reflect.Type]bool{}
+ // Wait for informers to sync, without polling.
+ cacheSyncs := make([]cache.DoneChecker, 0, len(informers))
+ for _, informer := range informers {
+ cacheSyncs = append(cacheSyncs, informer.HasSyncedChecker())
+ }
+ cache.WaitFor(ctx, "" /* no logging */, cacheSyncs...)
+
+ res := cache.SyncResult{
+ Synced: make(map[reflect.Type]bool, len(informers)),
+ }
+ failed := false
for informType, informer := range informers {
- res[informType] = cache.WaitForCacheSync(stopCh, informer.HasSynced)
+ hasSynced := informer.HasSynced()
+ if !hasSynced {
+ failed = true
+ }
+ res.Synced[informType] = hasSynced
}
+ if failed {
+ // context.Cause is more informative than ctx.Err().
+ // This must be non-nil, otherwise WaitFor wouldn't have stopped
+ // prematurely.
+ res.Err = context.Cause(ctx)
+ }
+
return res
}
@@ -178,7 +221,9 @@ func (f *sharedInformerFactory) InformerFor(obj runtime.Object, newFunc internal
}
informer = newFunc(f.client, resyncPeriod)
- informer.SetTransform(f.transform)
+ if f.transform != nil {
+ informer.SetTransform(f.transform)
+ }
f.informers[informerType] = informer
return informer
@@ -195,27 +240,46 @@ func (f *sharedInformerFactory) InformerFor(obj runtime.Object, newFunc internal
// defer factory.WaitForStop() // Returns immediately if nothing was started.
// genericInformer := factory.ForResource(resource)
// typedInformer := factory.SomeAPIGroup().V1().SomeType()
-// factory.Start(ctx.Done()) // Start processing these informers.
-// synced := factory.WaitForCacheSync(ctx.Done())
-// for v, ok := range synced {
-// if !ok {
-// fmt.Fprintf(os.Stderr, "caches failed to sync: %v", v)
-// return
-// }
+// handle, err := typeInformer.Informer().AddEventHandler(...)
+// if err != nil {
+// return fmt.Errorf("register event handler: %v", err)
+// }
+// defer typeInformer.Informer().RemoveEventHandler(handle) // Avoids leaking goroutines.
+// factory.StartWithContext(ctx) // Start processing these informers.
+// synced := factory.WaitForCacheSyncWithContext(ctx)
+// if err := synced.AsError(); err != nil {
+// return err
+// }
+// for v := range synced {
+// // Only if desired log some information similar to this.
+// fmt.Fprintf(os.Stdout, "cache synced: %s", v)
+// }
+//
+// // Also make sure that all of the initial cache events have been delivered.
+// if !WaitFor(ctx, "event handler sync", handle.HasSyncedChecker()) {
+// // Must have failed because of context.
+// return fmt.Errorf("sync event handler: %w", context.Cause(ctx))
// }
//
// // Creating informers can also be created after Start, but then
// // Start must be called again:
// anotherGenericInformer := factory.ForResource(resource)
-// factory.Start(ctx.Done())
+// factory.StartWithContext(ctx)
type SharedInformerFactory interface {
internalinterfaces.SharedInformerFactory
// Start initializes all requested informers. They are handled in goroutines
// which run until the stop channel gets closed.
// Warning: Start does not block. When run in a go-routine, it will race with a later WaitForCacheSync.
+ //
+ // Contextual logging: StartWithContext should be used instead of Start in code which supports contextual logging.
Start(stopCh <-chan struct{})
+ // StartWithContext initializes all requested informers. They are handled in goroutines
+ // which run until the context gets canceled.
+ // Warning: StartWithContext does not block. When run in a go-routine, it will race with a later WaitForCacheSync.
+ StartWithContext(ctx context.Context)
+
// Shutdown marks a factory as shutting down. At that point no new
// informers can be started anymore and Start will return without
// doing anything.
@@ -230,8 +294,14 @@ type SharedInformerFactory interface {
// WaitForCacheSync blocks until all started informers' caches were synced
// or the stop channel gets closed.
+ //
+ // Contextual logging: WaitForCacheSync should be used instead of WaitForCacheSync in code which supports contextual logging. It also returns a more useful result.
WaitForCacheSync(stopCh <-chan struct{}) map[reflect.Type]bool
+ // WaitForCacheSyncWithContext blocks until all started informers' caches were synced
+ // or the context gets canceled.
+ WaitForCacheSyncWithContext(ctx context.Context) cache.SyncResult
+
// ForResource gives generic access to a shared informer of the matching type.
ForResource(resource schema.GroupVersionResource) (GenericInformer, error)
diff --git a/vendor/github.com/openshift/client-go/image/informers/externalversions/image/v1/image.go b/vendor/github.com/openshift/client-go/image/informers/externalversions/image/v1/image.go
index e6eaccb365..00c0885f79 100644
--- a/vendor/github.com/openshift/client-go/image/informers/externalversions/image/v1/image.go
+++ b/vendor/github.com/openshift/client-go/image/informers/externalversions/image/v1/image.go
@@ -12,6 +12,7 @@ import (
imagev1 "github.com/openshift/client-go/image/listers/image/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type imageInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewImageInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredImageInformer(client, resyncPeriod, indexers, nil)
+ return NewImageInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredImageInformer constructs a new informer for Image type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredImageInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewImageInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewImageInformerWithOptions constructs a new informer for Image type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewImageInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "image.openshift.io", Version: "v1", Resource: "images"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ImageV1().Images().List(context.Background(), options)
+ return client.ImageV1().Images().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ImageV1().Images().Watch(context.Background(), options)
+ return client.ImageV1().Images().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ImageV1().Images().List(ctx, options)
+ return client.ImageV1().Images().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ImageV1().Images().Watch(ctx, options)
+ return client.ImageV1().Images().Watch(ctx, opts)
},
}, client),
&apiimagev1.Image{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *imageInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredImageInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewImageInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *imageInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/image/informers/externalversions/image/v1/imagestream.go b/vendor/github.com/openshift/client-go/image/informers/externalversions/image/v1/imagestream.go
index fab01df76e..3ea9f432fd 100644
--- a/vendor/github.com/openshift/client-go/image/informers/externalversions/image/v1/imagestream.go
+++ b/vendor/github.com/openshift/client-go/image/informers/externalversions/image/v1/imagestream.go
@@ -12,6 +12,7 @@ import (
imagev1 "github.com/openshift/client-go/image/listers/image/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -33,48 +34,61 @@ type imageStreamInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewImageStreamInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredImageStreamInformer(client, namespace, resyncPeriod, indexers, nil)
+ return NewImageStreamInformerWithOptions(client, namespace, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredImageStreamInformer constructs a new informer for ImageStream type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredImageStreamInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewImageStreamInformerWithOptions(client, namespace, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewImageStreamInformerWithOptions constructs a new informer for ImageStream type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewImageStreamInformerWithOptions(client versioned.Interface, namespace string, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "image.openshift.io", Version: "v1", Resource: "imagestreams"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ImageV1().ImageStreams(namespace).List(context.Background(), options)
+ return client.ImageV1().ImageStreams(namespace).List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ImageV1().ImageStreams(namespace).Watch(context.Background(), options)
+ return client.ImageV1().ImageStreams(namespace).Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ImageV1().ImageStreams(namespace).List(ctx, options)
+ return client.ImageV1().ImageStreams(namespace).List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.ImageV1().ImageStreams(namespace).Watch(ctx, options)
+ return client.ImageV1().ImageStreams(namespace).Watch(ctx, opts)
},
}, client),
&apiimagev1.ImageStream{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *imageStreamInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredImageStreamInformer(client, f.namespace, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewImageStreamInformerWithOptions(client, f.namespace, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *imageStreamInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/image/informers/externalversions/internalinterfaces/factory_interfaces.go b/vendor/github.com/openshift/client-go/image/informers/externalversions/internalinterfaces/factory_interfaces.go
index c35dcbfa44..dbceaeaae5 100644
--- a/vendor/github.com/openshift/client-go/image/informers/externalversions/internalinterfaces/factory_interfaces.go
+++ b/vendor/github.com/openshift/client-go/image/informers/externalversions/internalinterfaces/factory_interfaces.go
@@ -18,7 +18,26 @@ type NewInformerFunc func(versioned.Interface, time.Duration) cache.SharedIndexI
type SharedInformerFactory interface {
Start(stopCh <-chan struct{})
InformerFor(obj runtime.Object, newFunc NewInformerFunc) cache.SharedIndexInformer
+ InformerName() *cache.InformerName
}
// TweakListOptionsFunc is a function that transforms a v1.ListOptions.
type TweakListOptionsFunc func(*v1.ListOptions)
+
+// InformerOptions holds the options for creating an informer.
+type InformerOptions struct {
+ // ResyncPeriod is the resync period for this informer.
+ // If not set, defaults to 0 (no resync).
+ ResyncPeriod time.Duration
+
+ // Indexers are the indexers for this informer.
+ Indexers cache.Indexers
+
+ // InformerName is used to uniquely identify this informer for metrics.
+ // If not set, metrics will not be published for this informer.
+ // Use cache.NewInformerName() to create an InformerName at startup.
+ InformerName *cache.InformerName
+
+ // TweakListOptions is an optional function to modify the list options.
+ TweakListOptions TweakListOptionsFunc
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/internal/internal.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/internal/internal.go
index 13bc4fc94f..bbc2e8ad6c 100644
--- a/vendor/github.com/openshift/client-go/operator/applyconfigurations/internal/internal.go
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/internal/internal.go
@@ -49,6 +49,12 @@ var schemaYAML = typed.YAMLObject(`types:
elementType:
scalar: string
elementRelationship: atomic
+ - name: groups
+ type:
+ list:
+ elementType:
+ scalar: string
+ elementRelationship: associative
- name: minTLSVersion
type:
scalar: string
@@ -105,6 +111,12 @@ var schemaYAML = typed.YAMLObject(`types:
elementType:
scalar: string
elementRelationship: atomic
+ - name: groups
+ type:
+ list:
+ elementType:
+ scalar: string
+ elementRelationship: associative
- name: minTLSVersion
type:
scalar: string
@@ -210,6 +222,9 @@ var schemaYAML = typed.YAMLObject(`types:
elementType:
scalar: string
elementRelationship: atomic
+ - name: protocol
+ type:
+ scalar: string
- name: subnets
type:
namedType: com.github.openshift.api.operator.v1.AWSSubnets
@@ -310,6 +325,31 @@ var schemaYAML = typed.YAMLObject(`types:
type:
namedType: com.github.openshift.api.operator.v1.AuthenticationStatus
default: {}
+- name: com.github.openshift.api.operator.v1.AuthenticationConfigMapReference
+ map:
+ fields:
+ - name: name
+ type:
+ scalar: string
+- name: com.github.openshift.api.operator.v1.AuthenticationProxyConfig
+ map:
+ fields:
+ - name: httpProxy
+ type:
+ scalar: string
+ - name: httpsProxy
+ type:
+ scalar: string
+ - name: noProxy
+ type:
+ list:
+ elementType:
+ scalar: string
+ elementRelationship: associative
+ - name: trustedCA
+ type:
+ namedType: com.github.openshift.api.operator.v1.AuthenticationConfigMapReference
+ default: {}
- name: com.github.openshift.api.operator.v1.AuthenticationSpec
map:
fields:
@@ -326,6 +366,10 @@ var schemaYAML = typed.YAMLObject(`types:
- name: operatorLogLevel
type:
scalar: string
+ - name: proxy
+ type:
+ namedType: com.github.openshift.api.operator.v1.AuthenticationProxyConfig
+ default: {}
- name: unsupportedConfigOverrides
type:
namedType: __untyped_atomic_
@@ -389,6 +433,16 @@ var schemaYAML = typed.YAMLObject(`types:
type:
scalar: string
default: ""
+- name: com.github.openshift.api.operator.v1.BGPManagedConfig
+ map:
+ fields:
+ - name: asNumber
+ type:
+ scalar: numeric
+ default: 64512
+ - name: bgpTopology
+ type:
+ scalar: string
- name: com.github.openshift.api.operator.v1.BootImageSkewEnforcementConfig
map:
fields:
@@ -444,6 +498,10 @@ var schemaYAML = typed.YAMLObject(`types:
- name: ibmcloud
type:
namedType: com.github.openshift.api.operator.v1.IBMCloudCSIDriverConfigSpec
+ - name: secretsStore
+ type:
+ namedType: com.github.openshift.api.operator.v1.SecretsStoreCSIDriverConfigSpec
+ default: {}
- name: vSphere
type:
namedType: com.github.openshift.api.operator.v1.VSphereCSIDriverConfigSpec
@@ -458,6 +516,8 @@ var schemaYAML = typed.YAMLObject(`types:
discriminatorValue: GCP
- fieldName: ibmcloud
discriminatorValue: IBMCloud
+ - fieldName: secretsStore
+ discriminatorValue: SecretsStore
- fieldName: vSphere
discriminatorValue: VSphere
- name: com.github.openshift.api.operator.v1.CSISnapshotController
@@ -1032,6 +1092,12 @@ var schemaYAML = typed.YAMLObject(`types:
- name: maxLength
type:
scalar: numeric
+- name: com.github.openshift.api.operator.v1.CustomSecretRotation
+ map:
+ fields:
+ - name: minimumRefreshAge
+ type:
+ scalar: numeric
- name: com.github.openshift.api.operator.v1.DNS
map:
fields:
@@ -1873,6 +1939,9 @@ var schemaYAML = typed.YAMLObject(`types:
- name: endpointPublishingStrategy
type:
namedType: com.github.openshift.api.operator.v1.EndpointPublishingStrategy
+ - name: haproxyVersion
+ type:
+ scalar: string
- name: httpCompression
type:
namedType: com.github.openshift.api.operator.v1.HTTPCompressionPolicy
@@ -1938,6 +2007,9 @@ var schemaYAML = typed.YAMLObject(`types:
type:
scalar: string
default: ""
+ - name: effectiveHAProxyVersion
+ type:
+ scalar: string
- name: endpointPublishingStrategy
type:
namedType: com.github.openshift.api.operator.v1.EndpointPublishingStrategy
@@ -1966,6 +2038,9 @@ var schemaYAML = typed.YAMLObject(`types:
- name: clientTimeout
type:
namedType: io.k8s.apimachinery.pkg.apis.meta.v1.Duration
+ - name: configurationManagement
+ type:
+ scalar: string
- name: connectTimeout
type:
namedType: io.k8s.apimachinery.pkg.apis.meta.v1.Duration
@@ -2106,6 +2181,65 @@ var schemaYAML = typed.YAMLObject(`types:
elementType:
scalar: string
elementRelationship: associative
+- name: com.github.openshift.api.operator.v1.KMSEncryptionStatus
+ map:
+ fields:
+ - name: healthReports
+ type:
+ list:
+ elementType:
+ namedType: com.github.openshift.api.operator.v1.KMSPluginHealthReport
+ elementRelationship: associative
+ keys:
+ - nodeName
+ - keyID
+ - name: preflight
+ type:
+ namedType: com.github.openshift.api.operator.v1.KMSPreflightCheck
+ default: {}
+- name: com.github.openshift.api.operator.v1.KMSPluginHealthReport
+ map:
+ fields:
+ - name: detail
+ type:
+ scalar: string
+ - name: keyID
+ type:
+ scalar: string
+ - name: lastCheckedTime
+ type:
+ namedType: io.k8s.apimachinery.pkg.apis.meta.v1.Time
+ - name: nodeName
+ type:
+ scalar: string
+ - name: remoteKeyID
+ type:
+ scalar: string
+ - name: status
+ type:
+ scalar: string
+- name: com.github.openshift.api.operator.v1.KMSPreflightCheck
+ map:
+ fields:
+ - name: observedConfigHash
+ type:
+ scalar: string
+ - name: result
+ type:
+ namedType: com.github.openshift.api.operator.v1.KMSPreflightResult
+ default: {}
+- name: com.github.openshift.api.operator.v1.KMSPreflightResult
+ map:
+ fields:
+ - name: configHash
+ type:
+ scalar: string
+ - name: remoteKeyID
+ type:
+ scalar: string
+ - name: status
+ type:
+ scalar: string
- name: com.github.openshift.api.operator.v1.KubeAPIServer
map:
fields:
@@ -2170,6 +2304,10 @@ var schemaYAML = typed.YAMLObject(`types:
elementRelationship: associative
keys:
- type
+ - name: encryptionStatus
+ type:
+ namedType: com.github.openshift.api.operator.v1.KMSEncryptionStatus
+ default: {}
- name: generations
type:
list:
@@ -2689,6 +2827,17 @@ var schemaYAML = typed.YAMLObject(`types:
keys:
- resource
- apiGroup
+- name: com.github.openshift.api.operator.v1.ManagedTokenRequests
+ map:
+ fields:
+ - name: audiences
+ type:
+ list:
+ elementType:
+ namedType: com.github.openshift.api.operator.v1.SecretsStoreTokenRequest
+ elementRelationship: associative
+ keys:
+ - audience
- name: com.github.openshift.api.operator.v1.NetFlowConfig
map:
fields:
@@ -2837,6 +2986,15 @@ var schemaYAML = typed.YAMLObject(`types:
- name: version
type:
scalar: string
+- name: com.github.openshift.api.operator.v1.NoOverlayConfig
+ map:
+ fields:
+ - name: outboundSNAT
+ type:
+ scalar: string
+ - name: routing
+ type:
+ scalar: string
- name: com.github.openshift.api.operator.v1.NodeDisruptionPolicyClusterStatus
map:
fields:
@@ -3049,12 +3207,19 @@ var schemaYAML = typed.YAMLObject(`types:
type:
scalar: string
default: ""
+ - name: nodeUID
+ type:
+ scalar: string
- name: targetRevision
type:
scalar: numeric
- name: com.github.openshift.api.operator.v1.OAuthAPIServerStatus
map:
fields:
+ - name: encryptionStatus
+ type:
+ namedType: com.github.openshift.api.operator.v1.KMSEncryptionStatus
+ default: {}
- name: latestAvailableRevision
type:
scalar: numeric
@@ -3136,6 +3301,10 @@ var schemaYAML = typed.YAMLObject(`types:
- name: com.github.openshift.api.operator.v1.OVNKubernetesConfig
map:
fields:
+ - name: bgpManagedConfig
+ type:
+ namedType: com.github.openshift.api.operator.v1.BGPManagedConfig
+ default: {}
- name: egressIPConfig
type:
namedType: com.github.openshift.api.operator.v1.EgressIPConfig
@@ -3163,12 +3332,19 @@ var schemaYAML = typed.YAMLObject(`types:
- name: mtu
type:
scalar: numeric
+ - name: noOverlayConfig
+ type:
+ namedType: com.github.openshift.api.operator.v1.NoOverlayConfig
+ default: {}
- name: policyAuditConfig
type:
namedType: com.github.openshift.api.operator.v1.PolicyAuditConfig
- name: routeAdvertisements
type:
scalar: string
+ - name: transport
+ type:
+ scalar: string
- name: v4InternalSubnet
type:
scalar: string
@@ -3226,6 +3402,10 @@ var schemaYAML = typed.YAMLObject(`types:
elementRelationship: associative
keys:
- type
+ - name: encryptionStatus
+ type:
+ namedType: com.github.openshift.api.operator.v1.KMSEncryptionStatus
+ default: {}
- name: generations
type:
list:
@@ -3559,6 +3739,56 @@ var schemaYAML = typed.YAMLObject(`types:
elementType:
scalar: string
elementRelationship: atomic
+- name: com.github.openshift.api.operator.v1.SecretsStoreCSIDriverConfigSpec
+ map:
+ fields:
+ - name: secretRotation
+ type:
+ namedType: com.github.openshift.api.operator.v1.SecretsStoreSecretRotation
+ default: {}
+ - name: tokenRequests
+ type:
+ namedType: com.github.openshift.api.operator.v1.SecretsStoreTokenRequests
+ default: {}
+- name: com.github.openshift.api.operator.v1.SecretsStoreSecretRotation
+ map:
+ fields:
+ - name: custom
+ type:
+ namedType: com.github.openshift.api.operator.v1.CustomSecretRotation
+ default: {}
+ - name: type
+ type:
+ scalar: string
+ unions:
+ - discriminator: type
+ fields:
+ - fieldName: custom
+ discriminatorValue: Custom
+- name: com.github.openshift.api.operator.v1.SecretsStoreTokenRequest
+ map:
+ fields:
+ - name: audience
+ type:
+ scalar: string
+ - name: expirationSeconds
+ type:
+ scalar: numeric
+- name: com.github.openshift.api.operator.v1.SecretsStoreTokenRequests
+ map:
+ fields:
+ - name: managed
+ type:
+ namedType: com.github.openshift.api.operator.v1.ManagedTokenRequests
+ default: {}
+ - name: type
+ type:
+ scalar: string
+ unions:
+ - discriminator: type
+ fields:
+ - fieldName: managed
+ discriminatorValue: Managed
- name: com.github.openshift.api.operator.v1.Server
map:
fields:
@@ -4088,6 +4318,9 @@ var schemaYAML = typed.YAMLObject(`types:
type:
namedType: com.github.openshift.api.operator.v1alpha1.ClusterAPIInstallerComponentImage
default: {}
+ - name: name
+ type:
+ scalar: string
- name: type
type:
scalar: string
@@ -4117,6 +4350,14 @@ var schemaYAML = typed.YAMLObject(`types:
- name: contentID
type:
scalar: string
+ - name: manifestSubstitutions
+ type:
+ list:
+ elementType:
+ namedType: com.github.openshift.api.operator.v1alpha1.ClusterAPIInstallerRevisionManifestSubstitution
+ elementRelationship: associative
+ keys:
+ - key
- name: name
type:
scalar: string
@@ -4130,6 +4371,15 @@ var schemaYAML = typed.YAMLObject(`types:
scalar: string
elementRelationship: atomic
elementRelationship: atomic
+- name: com.github.openshift.api.operator.v1alpha1.ClusterAPIInstallerRevisionManifestSubstitution
+ map:
+ fields:
+ - name: key
+ type:
+ scalar: string
+ - name: value
+ type:
+ scalar: string
- name: com.github.openshift.api.operator.v1alpha1.ClusterAPISpec
map:
fields:
@@ -4148,6 +4398,9 @@ var schemaYAML = typed.YAMLObject(`types:
- name: desiredRevision
type:
scalar: string
+ - name: observedRevisionGeneration
+ type:
+ scalar: numeric
- name: revisions
type:
list:
@@ -4229,6 +4482,12 @@ var schemaYAML = typed.YAMLObject(`types:
elementRelationship: associative
keys:
- type
+- name: com.github.openshift.api.operator.v1alpha1.GatewayAPIIngressConfig
+ map:
+ fields:
+ - name: managementMode
+ type:
+ scalar: string
- name: com.github.openshift.api.operator.v1alpha1.ImageContentSourcePolicy
map:
fields:
@@ -4255,6 +4514,48 @@ var schemaYAML = typed.YAMLObject(`types:
elementType:
namedType: com.github.openshift.api.operator.v1alpha1.RepositoryDigestMirrors
elementRelationship: atomic
+- name: com.github.openshift.api.operator.v1alpha1.Ingress
+ map:
+ fields:
+ - name: apiVersion
+ type:
+ scalar: string
+ - name: kind
+ type:
+ scalar: string
+ - name: metadata
+ type:
+ namedType: io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta
+ default: {}
+ - name: spec
+ type:
+ namedType: com.github.openshift.api.operator.v1alpha1.IngressSpec
+ default: {}
+ - name: status
+ type:
+ namedType: com.github.openshift.api.operator.v1alpha1.IngressStatus
+ default: {}
+- name: com.github.openshift.api.operator.v1alpha1.IngressSpec
+ map:
+ fields:
+ - name: gatewayAPI
+ type:
+ namedType: com.github.openshift.api.operator.v1alpha1.GatewayAPIIngressConfig
+ default: {}
+- name: com.github.openshift.api.operator.v1alpha1.IngressStatus
+ map:
+ fields:
+ - name: conditions
+ type:
+ list:
+ elementType:
+ namedType: io.k8s.apimachinery.pkg.apis.meta.v1.Condition
+ elementRelationship: associative
+ keys:
+ - type
+ - name: observedGeneration
+ type:
+ scalar: numeric
- name: com.github.openshift.api.operator.v1alpha1.OLM
map:
fields:
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/authenticationconfigmapreference.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/authenticationconfigmapreference.go
new file mode 100644
index 0000000000..0743906641
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/authenticationconfigmapreference.go
@@ -0,0 +1,30 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+// AuthenticationConfigMapReferenceApplyConfiguration represents a declarative configuration of the AuthenticationConfigMapReference type for use
+// with apply.
+//
+// AuthenticationConfigMapReference references a ConfigMap in the
+// openshift-config namespace.
+type AuthenticationConfigMapReferenceApplyConfiguration struct {
+ // name is the metadata.name of the referenced ConfigMap.
+ // Must be a valid DNS subdomain name (RFC 1123): at most 253
+ // characters, only lowercase alphanumeric characters, '-' or
+ // '.', starting and ending with an alphanumeric character.
+ Name *string `json:"name,omitempty"`
+}
+
+// AuthenticationConfigMapReferenceApplyConfiguration constructs a declarative configuration of the AuthenticationConfigMapReference type for use with
+// apply.
+func AuthenticationConfigMapReference() *AuthenticationConfigMapReferenceApplyConfiguration {
+ return &AuthenticationConfigMapReferenceApplyConfiguration{}
+}
+
+// WithName sets the Name field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Name field is set to the value of the last call.
+func (b *AuthenticationConfigMapReferenceApplyConfiguration) WithName(value string) *AuthenticationConfigMapReferenceApplyConfiguration {
+ b.Name = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/authenticationproxyconfig.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/authenticationproxyconfig.go
new file mode 100644
index 0000000000..8b5e291443
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/authenticationproxyconfig.go
@@ -0,0 +1,79 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+// AuthenticationProxyConfigApplyConfiguration represents a declarative configuration of the AuthenticationProxyConfig type for use
+// with apply.
+//
+// AuthenticationProxyConfig holds proxy configuration scoped to
+// authentication components (the OAuth server and the cluster
+// authentication operator).
+type AuthenticationProxyConfigApplyConfiguration struct {
+ // httpProxy is the URL of the proxy for HTTP requests.
+ // Must be a valid URL with http or https scheme, a non-empty
+ // hostname, and no path, query parameters, or fragment.
+ // Userinfo (e.g. user:password@host) is allowed for proxy
+ // authentication. Maximum length is 2048 characters.
+ HTTPProxy *string `json:"httpProxy,omitempty"`
+ // httpsProxy is the URL of the proxy for HTTPS requests.
+ // Must be a valid URL with http or https scheme, a non-empty
+ // hostname, and no path, query parameters, or fragment.
+ // Userinfo (e.g. user:password@host) is allowed for proxy
+ // authentication. Maximum length is 2048 characters.
+ HTTPSProxy *string `json:"httpsProxy,omitempty"`
+ // noProxy is a list of hostnames and/or CIDRs and/or IPs for which
+ // the proxy should not be used. Must contain at least one entry
+ // when set. Each entry must be between 1 and 253 characters long
+ // and at most 64 entries are allowed. Duplicate
+ // entries are not permitted. Entries that are not valid hostnames,
+ // CIDRs, or IPs are silently ignored. Cluster-internal defaults
+ // (.cluster.local, .svc, 127.0.0.1, localhost) are always appended
+ // automatically and do not need to be included.
+ NoProxy []string `json:"noProxy,omitempty"`
+ // trustedCA is a reference to a ConfigMap in the openshift-config
+ // namespace containing a CA certificate bundle under the key
+ // "ca-bundle.crt". This bundle is appended to the system trust store
+ // used by authentication components for proxy TLS connections.
+ // When omitted, only the system trust store is used.
+ TrustedCA *AuthenticationConfigMapReferenceApplyConfiguration `json:"trustedCA,omitempty"`
+}
+
+// AuthenticationProxyConfigApplyConfiguration constructs a declarative configuration of the AuthenticationProxyConfig type for use with
+// apply.
+func AuthenticationProxyConfig() *AuthenticationProxyConfigApplyConfiguration {
+ return &AuthenticationProxyConfigApplyConfiguration{}
+}
+
+// WithHTTPProxy sets the HTTPProxy field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the HTTPProxy field is set to the value of the last call.
+func (b *AuthenticationProxyConfigApplyConfiguration) WithHTTPProxy(value string) *AuthenticationProxyConfigApplyConfiguration {
+ b.HTTPProxy = &value
+ return b
+}
+
+// WithHTTPSProxy sets the HTTPSProxy field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the HTTPSProxy field is set to the value of the last call.
+func (b *AuthenticationProxyConfigApplyConfiguration) WithHTTPSProxy(value string) *AuthenticationProxyConfigApplyConfiguration {
+ b.HTTPSProxy = &value
+ return b
+}
+
+// WithNoProxy adds the given value to the NoProxy field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the NoProxy field.
+func (b *AuthenticationProxyConfigApplyConfiguration) WithNoProxy(values ...string) *AuthenticationProxyConfigApplyConfiguration {
+ for i := range values {
+ b.NoProxy = append(b.NoProxy, values[i])
+ }
+ return b
+}
+
+// WithTrustedCA sets the TrustedCA field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the TrustedCA field is set to the value of the last call.
+func (b *AuthenticationProxyConfigApplyConfiguration) WithTrustedCA(value *AuthenticationConfigMapReferenceApplyConfiguration) *AuthenticationProxyConfigApplyConfiguration {
+ b.TrustedCA = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/authenticationspec.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/authenticationspec.go
index ac90816bce..4d2fb8c7ce 100644
--- a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/authenticationspec.go
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/authenticationspec.go
@@ -11,6 +11,14 @@ import (
// with apply.
type AuthenticationSpecApplyConfiguration struct {
OperatorSpecApplyConfiguration `json:",inline"`
+ // proxy configures proxy settings for outbound connections made
+ // by the authentication stack. When set, it replaces the
+ // cluster-wide proxy (proxy.config.openshift.io/cluster)
+ // entirely for authentication — individual fields are not
+ // inherited from the cluster-wide configuration. When omitted,
+ // the cluster-wide proxy is used if configured; otherwise no
+ // proxy is used.
+ Proxy *AuthenticationProxyConfigApplyConfiguration `json:"proxy,omitempty"`
}
// AuthenticationSpecApplyConfiguration constructs a declarative configuration of the AuthenticationSpec type for use with
@@ -58,3 +66,11 @@ func (b *AuthenticationSpecApplyConfiguration) WithObservedConfig(value runtime.
b.OperatorSpecApplyConfiguration.ObservedConfig = &value
return b
}
+
+// WithProxy sets the Proxy field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Proxy field is set to the value of the last call.
+func (b *AuthenticationSpecApplyConfiguration) WithProxy(value *AuthenticationProxyConfigApplyConfiguration) *AuthenticationSpecApplyConfiguration {
+ b.Proxy = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/awscsidriverconfigspec.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/awscsidriverconfigspec.go
index 9274b84ad6..f527a9312a 100644
--- a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/awscsidriverconfigspec.go
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/awscsidriverconfigspec.go
@@ -10,6 +10,12 @@ type AWSCSIDriverConfigSpecApplyConfiguration struct {
// kmsKeyARN sets the cluster default storage class to encrypt volumes with a user-defined KMS key,
// rather than the default KMS key used by AWS.
// The value may be either the ARN or Alias ARN of a KMS key.
+ //
+ // The ARN must follow the format: arn::kms:::(key|alias)/, where:
+ // is the AWS partition (aws, aws-cn, aws-us-gov, aws-iso, aws-iso-b, aws-iso-e, aws-iso-f, or aws-eusc),
+ // is the AWS region,
+ // is a 12-digit numeric identifier for the AWS account,
+ // is the KMS key ID or alias name.
KMSKeyARN *string `json:"kmsKeyARN,omitempty"`
// efsVolumeMetrics sets the configuration for collecting metrics from EFS volumes used by the EFS CSI Driver.
EFSVolumeMetrics *AWSEFSVolumeMetricsApplyConfiguration `json:"efsVolumeMetrics,omitempty"`
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/awsnetworkloadbalancerparameters.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/awsnetworkloadbalancerparameters.go
index 3785c6995e..40cd5a65b0 100644
--- a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/awsnetworkloadbalancerparameters.go
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/awsnetworkloadbalancerparameters.go
@@ -38,6 +38,33 @@ type AWSNetworkLoadBalancerParametersApplyConfiguration struct {
// See https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/elastic-ip-addresses-eip.html for general
// information about configuration, characteristics, and limitations of Elastic IP addresses.
EIPAllocations []operatorv1.EIPAllocation `json:"eipAllocations,omitempty"`
+ // protocol specifies whether the Network Load Balancer uses PROXY
+ // protocol to forward connections to the IngressController.
+ //
+ // When set to "TCP", the NLB uses AWS's native client IP preservation.
+ // This may cause hairpin connection failures for internal load
+ // balancers when connections are made from pods to router pods on
+ // the same node.
+ //
+ // When set to "PROXY", the NLB disables native client IP preservation
+ // and uses PROXY protocol v2. The IngressController enables PROXY
+ // protocol on HAProxy so that it can parse PROXY protocol headers to
+ // obtain the original client IP. This avoids hairpin connection
+ // failures.
+ //
+ // The following values are valid for this field:
+ //
+ // * "TCP".
+ // * "PROXY".
+ //
+ // When omitted, this means the user has no opinion and the value is
+ // left to the platform to choose a reasonable default, which is subject to
+ // change over time. The current default is "PROXY".
+ //
+ // Note that changing this field may cause brief connection failures
+ // during the transition as the NLB attribute change and router rollout
+ // occur independently.
+ Protocol *operatorv1.NLBProtocol `json:"protocol,omitempty"`
}
// AWSNetworkLoadBalancerParametersApplyConfiguration constructs a declarative configuration of the AWSNetworkLoadBalancerParameters type for use with
@@ -63,3 +90,11 @@ func (b *AWSNetworkLoadBalancerParametersApplyConfiguration) WithEIPAllocations(
}
return b
}
+
+// WithProtocol sets the Protocol field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Protocol field is set to the value of the last call.
+func (b *AWSNetworkLoadBalancerParametersApplyConfiguration) WithProtocol(value operatorv1.NLBProtocol) *AWSNetworkLoadBalancerParametersApplyConfiguration {
+ b.Protocol = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/bgpmanagedconfig.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/bgpmanagedconfig.go
new file mode 100644
index 0000000000..071ac3fc23
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/bgpmanagedconfig.go
@@ -0,0 +1,46 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+import (
+ operatorv1 "github.com/openshift/api/operator/v1"
+)
+
+// BGPManagedConfigApplyConfiguration represents a declarative configuration of the BGPManagedConfig type for use
+// with apply.
+//
+// BGPManagedConfig contains configuration options for BGP when routing is "Managed".
+type BGPManagedConfigApplyConfiguration struct {
+ // asNumber is the 2-byte or 4-byte Autonomous System Number (ASN)
+ // to be used in the generated FRR configuration.
+ // Valid values are 1 to 4294967295.
+ // When omitted, this defaults to 64512.
+ ASNumber *int64 `json:"asNumber,omitempty"`
+ // bgpTopology defines the BGP topology to be used.
+ // Allowed values are "FullMesh".
+ // When set to "FullMesh", every node peers directly with every other node via BGP.
+ // This field is required when BGPManagedConfig is specified.
+ BGPTopology *operatorv1.BGPTopology `json:"bgpTopology,omitempty"`
+}
+
+// BGPManagedConfigApplyConfiguration constructs a declarative configuration of the BGPManagedConfig type for use with
+// apply.
+func BGPManagedConfig() *BGPManagedConfigApplyConfiguration {
+ return &BGPManagedConfigApplyConfiguration{}
+}
+
+// WithASNumber sets the ASNumber field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the ASNumber field is set to the value of the last call.
+func (b *BGPManagedConfigApplyConfiguration) WithASNumber(value int64) *BGPManagedConfigApplyConfiguration {
+ b.ASNumber = &value
+ return b
+}
+
+// WithBGPTopology sets the BGPTopology field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the BGPTopology field is set to the value of the last call.
+func (b *BGPManagedConfigApplyConfiguration) WithBGPTopology(value operatorv1.BGPTopology) *BGPManagedConfigApplyConfiguration {
+ b.BGPTopology = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/csidriverconfigspec.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/csidriverconfigspec.go
index 215a65371c..4ff829f8a7 100644
--- a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/csidriverconfigspec.go
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/csidriverconfigspec.go
@@ -14,7 +14,7 @@ import (
type CSIDriverConfigSpecApplyConfiguration struct {
// driverType indicates type of CSI driver for which the
// driverConfig is being applied to.
- // Valid values are: AWS, Azure, GCP, IBMCloud, vSphere and omitted.
+ // Valid values are: AWS, Azure, GCP, IBMCloud, vSphere, SecretsStore and omitted.
// Consumers should treat unknown values as a NO-OP.
DriverType *operatorv1.CSIDriverType `json:"driverType,omitempty"`
// aws is used to configure the AWS CSI driver.
@@ -27,6 +27,8 @@ type CSIDriverConfigSpecApplyConfiguration struct {
IBMCloud *IBMCloudCSIDriverConfigSpecApplyConfiguration `json:"ibmcloud,omitempty"`
// vSphere is used to configure the vsphere CSI driver.
VSphere *VSphereCSIDriverConfigSpecApplyConfiguration `json:"vSphere,omitempty"`
+ // secretsStore is used to configure the Secrets Store CSI driver.
+ SecretsStore *SecretsStoreCSIDriverConfigSpecApplyConfiguration `json:"secretsStore,omitempty"`
}
// CSIDriverConfigSpecApplyConfiguration constructs a declarative configuration of the CSIDriverConfigSpec type for use with
@@ -82,3 +84,11 @@ func (b *CSIDriverConfigSpecApplyConfiguration) WithVSphere(value *VSphereCSIDri
b.VSphere = value
return b
}
+
+// WithSecretsStore sets the SecretsStore field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the SecretsStore field is set to the value of the last call.
+func (b *CSIDriverConfigSpecApplyConfiguration) WithSecretsStore(value *SecretsStoreCSIDriverConfigSpecApplyConfiguration) *CSIDriverConfigSpecApplyConfiguration {
+ b.SecretsStore = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/customsecretrotation.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/customsecretrotation.go
new file mode 100644
index 0000000000..189d31ad7e
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/customsecretrotation.go
@@ -0,0 +1,35 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+// CustomSecretRotationApplyConfiguration represents a declarative configuration of the CustomSecretRotation type for use
+// with apply.
+//
+// CustomSecretRotation holds configuration for custom secret rotation behavior.
+type CustomSecretRotationApplyConfiguration struct {
+ // minimumRefreshAge is the minimum time in seconds between secret
+ // rotation attempts. Each time kubelet calls NodePublishVolume, the driver
+ // checks whether this interval has elapsed since the last successful provider
+ // call. If it has, the driver contacts the secret provider to fetch the latest
+ // secret values and updates the mounted volume.
+ // Setting this value below the kubelet syncFrequency (default: 1 minute)
+ // has no additional effect on the actual rotation cadence.
+ // Must be at least 1 second and no more than 31560000 seconds (~1 year).
+ // When omitted, this means no opinion and the platform is left to choose a
+ // reasonable default, which is subject to change over time.
+ MinimumRefreshAge *int32 `json:"minimumRefreshAge,omitempty"`
+}
+
+// CustomSecretRotationApplyConfiguration constructs a declarative configuration of the CustomSecretRotation type for use with
+// apply.
+func CustomSecretRotation() *CustomSecretRotationApplyConfiguration {
+ return &CustomSecretRotationApplyConfiguration{}
+}
+
+// WithMinimumRefreshAge sets the MinimumRefreshAge field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the MinimumRefreshAge field is set to the value of the last call.
+func (b *CustomSecretRotationApplyConfiguration) WithMinimumRefreshAge(value int32) *CustomSecretRotationApplyConfiguration {
+ b.MinimumRefreshAge = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/etcdspec.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/etcdspec.go
index c3f57e5165..5b685313a2 100644
--- a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/etcdspec.go
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/etcdspec.go
@@ -19,7 +19,7 @@ type EtcdSpecApplyConfiguration struct {
// which is subject to change without notice.
HardwareSpeed *operatorv1.ControlPlaneHardwareSpeed `json:"controlPlaneHardwareSpeed,omitempty"`
// backendQuotaGiB sets the etcd backend storage size limit in gibibytes.
- // The value should be an integer not less than 8 and not more than 32.
+ // The value should be an integer not less than 8 and not more than 16.
// When not specified, the default value is 8.
BackendQuotaGiB *int32 `json:"backendQuotaGiB,omitempty"`
}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/ingresscontrollerspec.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/ingresscontrollerspec.go
index 9874c3b63b..b6337158c3 100644
--- a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/ingresscontrollerspec.go
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/ingresscontrollerspec.go
@@ -285,6 +285,27 @@ type IngressControllerSpecApplyConfiguration struct {
// - Using RSA keys larger than 2048 bits can significantly slow down
// TLS computations. Consider using the "Abort" policy to reduce CPU usage.
ClosedClientConnectionPolicy *operatorv1.IngressControllerClosedClientConnectionPolicy `json:"closedClientConnectionPolicy,omitempty"`
+ // haproxyVersion specifies the HAProxy version to use for this
+ // IngressController.
+ //
+ // OpenShift 5.0 introduces HAProxy 3.2 as its default version and supports
+ // HAProxy 2.8 from OpenShift 4.22 for migration purposes. When an OpenShift
+ // release introduces a new default HAProxy version, that HAProxy version
+ // becomes available as a pinnable value in subsequent OpenShift releases,
+ // providing a smooth migration path for administrators who want to defer
+ // HAProxy upgrades.
+ //
+ // Valid values for OpenShift 5.0:
+ // - Unset (default): Uses HAProxy 3.2 (the default for OpenShift 5.0)
+ // - "3.2": Explicitly pins HAProxy 3.2 for preservation during cluster
+ // upgrades to future OpenShift releases
+ // - "2.8": Uses HAProxy 2.8 from OpenShift 4.22 (migration support, will
+ // be dropped in the next OpenShift release)
+ //
+ // If a specific HAProxy version is set and would become unsupported in a
+ // target cluster upgrade, a preflight check will block the cluster upgrade
+ // until this field is updated to unset or a supported version.
+ HAProxyVersion *operatorv1.HAProxyVersion `json:"haproxyVersion,omitempty"`
}
// IngressControllerSpecApplyConfiguration constructs a declarative configuration of the IngressControllerSpec type for use with
@@ -444,3 +465,11 @@ func (b *IngressControllerSpecApplyConfiguration) WithClosedClientConnectionPoli
b.ClosedClientConnectionPolicy = &value
return b
}
+
+// WithHAProxyVersion sets the HAProxyVersion field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the HAProxyVersion field is set to the value of the last call.
+func (b *IngressControllerSpecApplyConfiguration) WithHAProxyVersion(value operatorv1.HAProxyVersion) *IngressControllerSpecApplyConfiguration {
+ b.HAProxyVersion = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/ingresscontrollerstatus.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/ingresscontrollerstatus.go
index d42313f040..169f158b6f 100644
--- a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/ingresscontrollerstatus.go
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/ingresscontrollerstatus.go
@@ -4,6 +4,7 @@ package v1
import (
configv1 "github.com/openshift/api/config/v1"
+ operatorv1 "github.com/openshift/api/operator/v1"
metav1 "k8s.io/client-go/applyconfigurations/meta/v1"
)
@@ -64,6 +65,15 @@ type IngressControllerStatusApplyConfiguration struct {
NamespaceSelector *metav1.LabelSelectorApplyConfiguration `json:"namespaceSelector,omitempty"`
// routeSelector is the actual routeSelector in use.
RouteSelector *metav1.LabelSelectorApplyConfiguration `json:"routeSelector,omitempty"`
+ // effectiveHAProxyVersion reports the HAProxy version currently in use by
+ // this IngressController. This reflects the resolved value of the
+ // spec.haproxyVersion field. When omitted, the effective value has not yet
+ // been resolved by the operator or the feature is not enabled for this cluster.
+ //
+ // Examples for OpenShift 5.0:
+ // - "3.2": Using HAProxy 3.2
+ // - "2.8": Using HAProxy 2.8
+ EffectiveHAProxyVersion *operatorv1.HAProxyVersion `json:"effectiveHAProxyVersion,omitempty"`
}
// IngressControllerStatusApplyConfiguration constructs a declarative configuration of the IngressControllerStatus type for use with
@@ -148,3 +158,11 @@ func (b *IngressControllerStatusApplyConfiguration) WithRouteSelector(value *met
b.RouteSelector = value
return b
}
+
+// WithEffectiveHAProxyVersion sets the EffectiveHAProxyVersion field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the EffectiveHAProxyVersion field is set to the value of the last call.
+func (b *IngressControllerStatusApplyConfiguration) WithEffectiveHAProxyVersion(value operatorv1.HAProxyVersion) *IngressControllerStatusApplyConfiguration {
+ b.EffectiveHAProxyVersion = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/ingresscontrollertuningoptions.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/ingresscontrollertuningoptions.go
index 831ef5130e..d62c99282a 100644
--- a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/ingresscontrollertuningoptions.go
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/ingresscontrollertuningoptions.go
@@ -3,6 +3,7 @@
package v1
import (
+ operatorv1 "github.com/openshift/api/operator/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
)
@@ -209,6 +210,32 @@ type IngressControllerTuningOptionsApplyConfiguration struct {
// be reloaded less frequently, and newly created routes will not be served until the
// subsequent reload.
ReloadInterval *metav1.Duration `json:"reloadInterval,omitempty"`
+ // configurationManagement specifies how OpenShift router should update
+ // the HAProxy configuration. The following values are valid for this
+ // field:
+ //
+ // * "ForkAndReload".
+ // * "Dynamic".
+ //
+ // Omitting this field means that the user has no opinion and the
+ // platform may choose a reasonable default. This default is subject to
+ // change over time. The current default is "ForkAndReload".
+ //
+ // "ForkAndReload" means that OpenShift router should rewrite the
+ // HAProxy configuration file and instruct HAProxy to fork and reload.
+ // This is OpenShift router's traditional approach.
+ //
+ // "Dynamic" means that OpenShift router may use HAProxy's control
+ // socket for some configuration updates and fall back to fork and
+ // reload for other configuration updates. This is a newer approach,
+ // which may be less mature than ForkAndReload. This setting can
+ // improve load-balancing fairness and metrics accuracy and reduce CPU
+ // and memory usage if HAProxy has frequent configuration updates for
+ // route and endpoints updates.
+ //
+ // Note: The "Dynamic" option is currently experimental and should not
+ // be enabled on production clusters.
+ ConfigurationManagement *operatorv1.IngressControllerConfigurationManagement `json:"configurationManagement,omitempty"`
}
// IngressControllerTuningOptionsApplyConfiguration constructs a declarative configuration of the IngressControllerTuningOptions type for use with
@@ -328,3 +355,11 @@ func (b *IngressControllerTuningOptionsApplyConfiguration) WithReloadInterval(va
b.ReloadInterval = &value
return b
}
+
+// WithConfigurationManagement sets the ConfigurationManagement field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the ConfigurationManagement field is set to the value of the last call.
+func (b *IngressControllerTuningOptionsApplyConfiguration) WithConfigurationManagement(value operatorv1.IngressControllerConfigurationManagement) *IngressControllerTuningOptionsApplyConfiguration {
+ b.ConfigurationManagement = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/kmsencryptionstatus.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/kmsencryptionstatus.go
new file mode 100644
index 0000000000..11e54164ad
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/kmsencryptionstatus.go
@@ -0,0 +1,45 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+// KMSEncryptionStatusApplyConfiguration represents a declarative configuration of the KMSEncryptionStatus type for use
+// with apply.
+type KMSEncryptionStatusApplyConfiguration struct {
+ // healthReports contains all KMS plugin health reports.
+ // When omitted, no health reports are available.
+ // Each entry must have a unique combination of nodeName and keyID.
+ HealthReports []KMSPluginHealthReportApplyConfiguration `json:"healthReports,omitempty"`
+ // preflight contains the state of KMS preflight validation for this operator.
+ // The preflight validates the KMS provider configuration before it is used
+ // to create a new encryption key, catching configuration issues early such
+ // as incorrect login credentials or an unreachable Vault service.
+ // When omitted, no preflight validation is in progress.
+ Preflight *KMSPreflightCheckApplyConfiguration `json:"preflight,omitempty"`
+}
+
+// KMSEncryptionStatusApplyConfiguration constructs a declarative configuration of the KMSEncryptionStatus type for use with
+// apply.
+func KMSEncryptionStatus() *KMSEncryptionStatusApplyConfiguration {
+ return &KMSEncryptionStatusApplyConfiguration{}
+}
+
+// WithHealthReports adds the given value to the HealthReports field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the HealthReports field.
+func (b *KMSEncryptionStatusApplyConfiguration) WithHealthReports(values ...*KMSPluginHealthReportApplyConfiguration) *KMSEncryptionStatusApplyConfiguration {
+ for i := range values {
+ if values[i] == nil {
+ panic("nil value passed to WithHealthReports")
+ }
+ b.HealthReports = append(b.HealthReports, *values[i])
+ }
+ return b
+}
+
+// WithPreflight sets the Preflight field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Preflight field is set to the value of the last call.
+func (b *KMSEncryptionStatusApplyConfiguration) WithPreflight(value *KMSPreflightCheckApplyConfiguration) *KMSEncryptionStatusApplyConfiguration {
+ b.Preflight = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/kmspluginhealthreport.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/kmspluginhealthreport.go
new file mode 100644
index 0000000000..023f134a95
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/kmspluginhealthreport.go
@@ -0,0 +1,91 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+import (
+ operatorv1 "github.com/openshift/api/operator/v1"
+ metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
+)
+
+// KMSPluginHealthReportApplyConfiguration represents a declarative configuration of the KMSPluginHealthReport type for use
+// with apply.
+type KMSPluginHealthReportApplyConfiguration struct {
+ // nodeName is the name of the node this instance of the plugin runs on.
+ // The combination of nodeName and keyID makes this health report unique.
+ // The value must be a valid Kubernetes node name: a lowercase RFC 1123 subdomain
+ // consisting of lowercase alphanumeric characters, '-' or '.', starting and ending with
+ // an alphanumeric character, and be at most 253 characters in length.
+ NodeName *string `json:"nodeName,omitempty"`
+ // keyID is the encryption-key-secret id (kms-{keyID}.sock), a unique identifier of the plugin on that node.
+ // This is not a cryptographic key used to encrypt/decrypt any resources.
+ // The value must be between 1 and 512 characters.
+ KeyID *string `json:"keyID,omitempty"`
+ // status contains a health indicator for the respective KMS plugin
+ // The field can have three states: healthy, unhealthy, error.
+ // With error and unhealthy containing additional information in Detail.
+ Status *operatorv1.KMSPluginHealthStatus `json:"status,omitempty"`
+ // lastCheckedTime is a timestamp of when the probe was last checked.
+ LastCheckedTime *metav1.Time `json:"lastCheckedTime,omitempty"`
+ // remoteKeyID refers to the remote key identifier from KMS v2 StatusResponse.key_id.
+ // This is not a cryptographic key, but a unique representation of the KEK.
+ // The value must be between 1 and 1024 characters.
+ RemoteKeyID *string `json:"remoteKeyID,omitempty"`
+ // detail contains additional error/health information for the respective KMS plugin.
+ // When omitted, no additional error or health information is provided.
+ // When set, the value must be between 1 and 1024 characters.
+ Detail *string `json:"detail,omitempty"`
+}
+
+// KMSPluginHealthReportApplyConfiguration constructs a declarative configuration of the KMSPluginHealthReport type for use with
+// apply.
+func KMSPluginHealthReport() *KMSPluginHealthReportApplyConfiguration {
+ return &KMSPluginHealthReportApplyConfiguration{}
+}
+
+// WithNodeName sets the NodeName field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the NodeName field is set to the value of the last call.
+func (b *KMSPluginHealthReportApplyConfiguration) WithNodeName(value string) *KMSPluginHealthReportApplyConfiguration {
+ b.NodeName = &value
+ return b
+}
+
+// WithKeyID sets the KeyID field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the KeyID field is set to the value of the last call.
+func (b *KMSPluginHealthReportApplyConfiguration) WithKeyID(value string) *KMSPluginHealthReportApplyConfiguration {
+ b.KeyID = &value
+ return b
+}
+
+// WithStatus sets the Status field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Status field is set to the value of the last call.
+func (b *KMSPluginHealthReportApplyConfiguration) WithStatus(value operatorv1.KMSPluginHealthStatus) *KMSPluginHealthReportApplyConfiguration {
+ b.Status = &value
+ return b
+}
+
+// WithLastCheckedTime sets the LastCheckedTime field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the LastCheckedTime field is set to the value of the last call.
+func (b *KMSPluginHealthReportApplyConfiguration) WithLastCheckedTime(value metav1.Time) *KMSPluginHealthReportApplyConfiguration {
+ b.LastCheckedTime = &value
+ return b
+}
+
+// WithRemoteKeyID sets the RemoteKeyID field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the RemoteKeyID field is set to the value of the last call.
+func (b *KMSPluginHealthReportApplyConfiguration) WithRemoteKeyID(value string) *KMSPluginHealthReportApplyConfiguration {
+ b.RemoteKeyID = &value
+ return b
+}
+
+// WithDetail sets the Detail field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Detail field is set to the value of the last call.
+func (b *KMSPluginHealthReportApplyConfiguration) WithDetail(value string) *KMSPluginHealthReportApplyConfiguration {
+ b.Detail = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/kmspreflightcheck.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/kmspreflightcheck.go
new file mode 100644
index 0000000000..020e88e998
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/kmspreflightcheck.go
@@ -0,0 +1,42 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+// KMSPreflightCheckApplyConfiguration represents a declarative configuration of the KMSPreflightCheck type for use
+// with apply.
+//
+// KMSPreflightCheck describes a preflight validation request and its result.
+type KMSPreflightCheckApplyConfiguration struct {
+ // observedConfigHash is a hash of the KMS provider configuration and
+ // its referenced resources that has been observed and requires preflight
+ // validation before a new encryption key can be created.
+ // The value must be exactly 8 characters.
+ ObservedConfigHash *string `json:"observedConfigHash,omitempty"`
+ // result contains the outcome of the most recent preflight check.
+ // Preflight is considered passed when result.status is Succeeded and
+ // result.configHash matches observedConfigHash.
+ // When omitted, no preflight check result has been reported yet.
+ Result *KMSPreflightResultApplyConfiguration `json:"result,omitempty"`
+}
+
+// KMSPreflightCheckApplyConfiguration constructs a declarative configuration of the KMSPreflightCheck type for use with
+// apply.
+func KMSPreflightCheck() *KMSPreflightCheckApplyConfiguration {
+ return &KMSPreflightCheckApplyConfiguration{}
+}
+
+// WithObservedConfigHash sets the ObservedConfigHash field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the ObservedConfigHash field is set to the value of the last call.
+func (b *KMSPreflightCheckApplyConfiguration) WithObservedConfigHash(value string) *KMSPreflightCheckApplyConfiguration {
+ b.ObservedConfigHash = &value
+ return b
+}
+
+// WithResult sets the Result field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Result field is set to the value of the last call.
+func (b *KMSPreflightCheckApplyConfiguration) WithResult(value *KMSPreflightResultApplyConfiguration) *KMSPreflightCheckApplyConfiguration {
+ b.Result = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/kmspreflightresult.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/kmspreflightresult.go
new file mode 100644
index 0000000000..a5c86c13a2
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/kmspreflightresult.go
@@ -0,0 +1,59 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+import (
+ operatorv1 "github.com/openshift/api/operator/v1"
+)
+
+// KMSPreflightResultApplyConfiguration represents a declarative configuration of the KMSPreflightResult type for use
+// with apply.
+//
+// KMSPreflightResult contains the outcome of a preflight validation.
+type KMSPreflightResultApplyConfiguration struct {
+ // status indicates the outcome of the preflight check.
+ // Succeeded means the KMS plugin responded to Status, Encrypt, and
+ // Decrypt calls successfully.
+ // Failed means the validation did not pass.
+ Status *operatorv1.KMSPreflightResultStatus `json:"status,omitempty"`
+ // configHash is the hash of the configuration that was validated.
+ // This is compared against observedConfigHash to confirm the result
+ // corresponds to the current configuration.
+ // The value must be exactly 8 characters.
+ ConfigHash *string `json:"configHash,omitempty"`
+ // remoteKeyID is the remote key encryption key identifier from KMS v2
+ // StatusResponse.key_id. This is not a cryptographic key, but a unique
+ // representation of the remote key used to encrypt data.
+ // The value must be between 1 and 1024 characters.
+ RemoteKeyID *string `json:"remoteKeyID,omitempty"`
+}
+
+// KMSPreflightResultApplyConfiguration constructs a declarative configuration of the KMSPreflightResult type for use with
+// apply.
+func KMSPreflightResult() *KMSPreflightResultApplyConfiguration {
+ return &KMSPreflightResultApplyConfiguration{}
+}
+
+// WithStatus sets the Status field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Status field is set to the value of the last call.
+func (b *KMSPreflightResultApplyConfiguration) WithStatus(value operatorv1.KMSPreflightResultStatus) *KMSPreflightResultApplyConfiguration {
+ b.Status = &value
+ return b
+}
+
+// WithConfigHash sets the ConfigHash field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the ConfigHash field is set to the value of the last call.
+func (b *KMSPreflightResultApplyConfiguration) WithConfigHash(value string) *KMSPreflightResultApplyConfiguration {
+ b.ConfigHash = &value
+ return b
+}
+
+// WithRemoteKeyID sets the RemoteKeyID field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the RemoteKeyID field is set to the value of the last call.
+func (b *KMSPreflightResultApplyConfiguration) WithRemoteKeyID(value string) *KMSPreflightResultApplyConfiguration {
+ b.RemoteKeyID = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/kubeapiserverstatus.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/kubeapiserverstatus.go
index b6b6bd8664..c6eec2ce4f 100644
--- a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/kubeapiserverstatus.go
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/kubeapiserverstatus.go
@@ -12,6 +12,8 @@ type KubeAPIServerStatusApplyConfiguration struct {
// The default expiration for the items is set by the platform and it defaults to 24h.
// see: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/#service-account-token-volume-projection
ServiceAccountIssuers []ServiceAccountIssuerStatusApplyConfiguration `json:"serviceAccountIssuers,omitempty"`
+ // encryptionStatus contains status reports for the KMS plugin health and its key rotation.
+ EncryptionStatus *KMSEncryptionStatusApplyConfiguration `json:"encryptionStatus,omitempty"`
}
// KubeAPIServerStatusApplyConfiguration constructs a declarative configuration of the KubeAPIServerStatus type for use with
@@ -111,3 +113,11 @@ func (b *KubeAPIServerStatusApplyConfiguration) WithServiceAccountIssuers(values
}
return b
}
+
+// WithEncryptionStatus sets the EncryptionStatus field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the EncryptionStatus field is set to the value of the last call.
+func (b *KubeAPIServerStatusApplyConfiguration) WithEncryptionStatus(value *KMSEncryptionStatusApplyConfiguration) *KubeAPIServerStatusApplyConfiguration {
+ b.EncryptionStatus = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/managedtokenrequests.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/managedtokenrequests.go
new file mode 100644
index 0000000000..5b65a6628d
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/managedtokenrequests.go
@@ -0,0 +1,43 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+// ManagedTokenRequestsApplyConfiguration represents a declarative configuration of the ManagedTokenRequests type for use
+// with apply.
+//
+// ManagedTokenRequests holds the configuration for operator-managed
+// service account token requests.
+type ManagedTokenRequestsApplyConfiguration struct {
+ // audiences specifies service account token audiences that kubelet will
+ // provide to the CSI driver during NodePublishVolume calls. These tokens
+ // enable workload identity federation (WIF) with cloud providers such as
+ // AWS, Azure, and GCP.
+ // When empty, the operator clears all tokenRequests from the CSIDriver object.
+ Audiences *[]SecretsStoreTokenRequestApplyConfiguration `json:"audiences,omitempty"`
+}
+
+// ManagedTokenRequestsApplyConfiguration constructs a declarative configuration of the ManagedTokenRequests type for use with
+// apply.
+func ManagedTokenRequests() *ManagedTokenRequestsApplyConfiguration {
+ return &ManagedTokenRequestsApplyConfiguration{}
+}
+
+func (b *ManagedTokenRequestsApplyConfiguration) ensureSecretsStoreTokenRequestApplyConfigurationExists() {
+ if b.Audiences == nil {
+ b.Audiences = &[]SecretsStoreTokenRequestApplyConfiguration{}
+ }
+}
+
+// WithAudiences adds the given value to the Audiences field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the Audiences field.
+func (b *ManagedTokenRequestsApplyConfiguration) WithAudiences(values ...*SecretsStoreTokenRequestApplyConfiguration) *ManagedTokenRequestsApplyConfiguration {
+ b.ensureSecretsStoreTokenRequestApplyConfigurationExists()
+ for i := range values {
+ if values[i] == nil {
+ panic("nil value passed to WithAudiences")
+ }
+ *b.Audiences = append(*b.Audiences, *values[i])
+ }
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/nodestatus.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/nodestatus.go
index f107c370d2..ab2db04ade 100644
--- a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/nodestatus.go
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/nodestatus.go
@@ -13,6 +13,13 @@ import (
type NodeStatusApplyConfiguration struct {
// nodeName is the name of the node
NodeName *string `json:"nodeName,omitempty"`
+ // nodeUID is the UID of the node.
+ // This field is used to detect that a node has been deleted and recreated
+ // with the same name. When the UID changes, it indicates the node is a
+ // new instance and the controller should treat this status entry as stale.
+ // When omitted, UID-based node replacement detection is not available
+ // for this entry.
+ NodeUID *string `json:"nodeUID,omitempty"`
// currentRevision is the generation of the most recently successful deployment.
// Can not be set on creation of a nodeStatus. Updates must only increase the value.
CurrentRevision *int32 `json:"currentRevision,omitempty"`
@@ -47,6 +54,14 @@ func (b *NodeStatusApplyConfiguration) WithNodeName(value string) *NodeStatusApp
return b
}
+// WithNodeUID sets the NodeUID field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the NodeUID field is set to the value of the last call.
+func (b *NodeStatusApplyConfiguration) WithNodeUID(value string) *NodeStatusApplyConfiguration {
+ b.NodeUID = &value
+ return b
+}
+
// WithCurrentRevision sets the CurrentRevision field in the declarative configuration to the given value
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
// If called multiple times, the CurrentRevision field is set to the value of the last call.
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/nooverlayconfig.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/nooverlayconfig.go
new file mode 100644
index 0000000000..0feb3009ea
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/nooverlayconfig.go
@@ -0,0 +1,50 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+import (
+ operatorv1 "github.com/openshift/api/operator/v1"
+)
+
+// NoOverlayConfigApplyConfiguration represents a declarative configuration of the NoOverlayConfig type for use
+// with apply.
+//
+// NoOverlayConfig contains configuration options for networks operating in no-overlay mode.
+type NoOverlayConfigApplyConfiguration struct {
+ // outboundSNAT defines the SNAT behavior for outbound traffic from pods.
+ // Allowed values are "Enabled" and "Disabled".
+ // When set to "Enabled", SNAT is performed on outbound traffic from pods.
+ // When set to "Disabled", SNAT is not performed and pod IPs are preserved in outbound traffic.
+ // This field is required when the network operates in no-overlay mode.
+ // This field can be set to any value at installation time and can be changed afterwards.
+ OutboundSNAT *operatorv1.SNATOption `json:"outboundSNAT,omitempty"`
+ // routing specifies whether the pod network routing is managed by OVN-Kubernetes or users.
+ // Allowed values are "Managed" and "Unmanaged".
+ // When set to "Managed", OVN-Kubernetes manages the pod network routing configuration through BGP.
+ // When set to "Unmanaged", users are responsible for configuring the pod network routing.
+ // This field is required when the network operates in no-overlay mode.
+ // This field is immutable once set.
+ Routing *operatorv1.RoutingOption `json:"routing,omitempty"`
+}
+
+// NoOverlayConfigApplyConfiguration constructs a declarative configuration of the NoOverlayConfig type for use with
+// apply.
+func NoOverlayConfig() *NoOverlayConfigApplyConfiguration {
+ return &NoOverlayConfigApplyConfiguration{}
+}
+
+// WithOutboundSNAT sets the OutboundSNAT field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the OutboundSNAT field is set to the value of the last call.
+func (b *NoOverlayConfigApplyConfiguration) WithOutboundSNAT(value operatorv1.SNATOption) *NoOverlayConfigApplyConfiguration {
+ b.OutboundSNAT = &value
+ return b
+}
+
+// WithRouting sets the Routing field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Routing field is set to the value of the last call.
+func (b *NoOverlayConfigApplyConfiguration) WithRouting(value operatorv1.RoutingOption) *NoOverlayConfigApplyConfiguration {
+ b.Routing = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/oauthapiserverstatus.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/oauthapiserverstatus.go
index 381d4a7e7b..1ccbf802f2 100644
--- a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/oauthapiserverstatus.go
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/oauthapiserverstatus.go
@@ -8,6 +8,8 @@ type OAuthAPIServerStatusApplyConfiguration struct {
// latestAvailableRevision is the latest revision used as suffix of revisioned
// secrets like encryption-config. A new revision causes a new deployment of pods.
LatestAvailableRevision *int32 `json:"latestAvailableRevision,omitempty"`
+ // encryptionStatus contains status reports for the KMS plugin health and its key rotation.
+ EncryptionStatus *KMSEncryptionStatusApplyConfiguration `json:"encryptionStatus,omitempty"`
}
// OAuthAPIServerStatusApplyConfiguration constructs a declarative configuration of the OAuthAPIServerStatus type for use with
@@ -23,3 +25,11 @@ func (b *OAuthAPIServerStatusApplyConfiguration) WithLatestAvailableRevision(val
b.LatestAvailableRevision = &value
return b
}
+
+// WithEncryptionStatus sets the EncryptionStatus field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the EncryptionStatus field is set to the value of the last call.
+func (b *OAuthAPIServerStatusApplyConfiguration) WithEncryptionStatus(value *KMSEncryptionStatusApplyConfiguration) *OAuthAPIServerStatusApplyConfiguration {
+ b.EncryptionStatus = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/openshiftapiserverstatus.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/openshiftapiserverstatus.go
index 776701d546..3a68909d54 100644
--- a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/openshiftapiserverstatus.go
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/openshiftapiserverstatus.go
@@ -6,6 +6,8 @@ package v1
// with apply.
type OpenShiftAPIServerStatusApplyConfiguration struct {
OperatorStatusApplyConfiguration `json:",inline"`
+ // encryptionStatus contains status reports for the KMS plugin health and its key rotation.
+ EncryptionStatus *KMSEncryptionStatusApplyConfiguration `json:"encryptionStatus,omitempty"`
}
// OpenShiftAPIServerStatusApplyConfiguration constructs a declarative configuration of the OpenShiftAPIServerStatus type for use with
@@ -71,3 +73,11 @@ func (b *OpenShiftAPIServerStatusApplyConfiguration) WithGenerations(values ...*
}
return b
}
+
+// WithEncryptionStatus sets the EncryptionStatus field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the EncryptionStatus field is set to the value of the last call.
+func (b *OpenShiftAPIServerStatusApplyConfiguration) WithEncryptionStatus(value *KMSEncryptionStatusApplyConfiguration) *OpenShiftAPIServerStatusApplyConfiguration {
+ b.EncryptionStatus = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/ovnkubernetesconfig.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/ovnkubernetesconfig.go
index 6a2d864421..ead45f83b5 100644
--- a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/ovnkubernetesconfig.go
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/ovnkubernetesconfig.go
@@ -62,6 +62,27 @@ type OVNKubernetesConfigApplyConfiguration struct {
// reasonable defaults. These defaults are subject to change over time. The
// current default is "Disabled".
RouteAdvertisements *operatorv1.RouteAdvertisementsEnablement `json:"routeAdvertisements,omitempty"`
+ // transport sets the transport mode for pods on the default network.
+ // Allowed values are "NoOverlay" and "Geneve".
+ // "NoOverlay" avoids tunnel encapsulation, routing pod traffic directly between nodes.
+ // "Geneve" encapsulates pod traffic using Geneve tunnels between nodes.
+ // When omitted, this means the user has no opinion and the platform chooses
+ // a reasonable default which is subject to change over time.
+ // The current default is "Geneve".
+ // "NoOverlay" can only be set at installation time and cannot be changed afterwards.
+ // "Geneve" may be set explicitly at any time to lock in the current default.
+ Transport *operatorv1.TransportOption `json:"transport,omitempty"`
+ // noOverlayConfig contains configuration for no-overlay mode.
+ // This configuration applies to the default network only.
+ // It is required when transport is "NoOverlay".
+ // When omitted, this means the user does not configure no-overlay mode options.
+ NoOverlayConfig *NoOverlayConfigApplyConfiguration `json:"noOverlayConfig,omitempty"`
+ // bgpManagedConfig configures the BGP properties for networks (default network or CUDNs)
+ // in no-overlay mode that specify routing="Managed" in their noOverlayConfig.
+ // It is required when noOverlayConfig.routing is set to "Managed".
+ // When omitted, this means the user does not configure BGP for managed routing.
+ // This field can be set at installation time or on day 2, and can be modified at any time.
+ BGPManagedConfig *BGPManagedConfigApplyConfiguration `json:"bgpManagedConfig,omitempty"`
}
// OVNKubernetesConfigApplyConfiguration constructs a declarative configuration of the OVNKubernetesConfig type for use with
@@ -165,3 +186,27 @@ func (b *OVNKubernetesConfigApplyConfiguration) WithRouteAdvertisements(value op
b.RouteAdvertisements = &value
return b
}
+
+// WithTransport sets the Transport field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Transport field is set to the value of the last call.
+func (b *OVNKubernetesConfigApplyConfiguration) WithTransport(value operatorv1.TransportOption) *OVNKubernetesConfigApplyConfiguration {
+ b.Transport = &value
+ return b
+}
+
+// WithNoOverlayConfig sets the NoOverlayConfig field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the NoOverlayConfig field is set to the value of the last call.
+func (b *OVNKubernetesConfigApplyConfiguration) WithNoOverlayConfig(value *NoOverlayConfigApplyConfiguration) *OVNKubernetesConfigApplyConfiguration {
+ b.NoOverlayConfig = value
+ return b
+}
+
+// WithBGPManagedConfig sets the BGPManagedConfig field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the BGPManagedConfig field is set to the value of the last call.
+func (b *OVNKubernetesConfigApplyConfiguration) WithBGPManagedConfig(value *BGPManagedConfigApplyConfiguration) *OVNKubernetesConfigApplyConfiguration {
+ b.BGPManagedConfig = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/secretsstorecsidriverconfigspec.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/secretsstorecsidriverconfigspec.go
new file mode 100644
index 0000000000..145aa90709
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/secretsstorecsidriverconfigspec.go
@@ -0,0 +1,40 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+// SecretsStoreCSIDriverConfigSpecApplyConfiguration represents a declarative configuration of the SecretsStoreCSIDriverConfigSpec type for use
+// with apply.
+//
+// SecretsStoreCSIDriverConfigSpec defines properties that can be configured for the Secrets Store CSI driver.
+type SecretsStoreCSIDriverConfigSpecApplyConfiguration struct {
+ // secretRotation controls automatic secret rotation behavior.
+ // When omitted, secret rotation is enabled with a default poll interval of 2 minutes.
+ SecretRotation *SecretsStoreSecretRotationApplyConfiguration `json:"secretRotation,omitempty"`
+ // tokenRequests controls service account token configuration for
+ // workload identity federation (WIF) with cloud providers.
+ // When omitted, the operator preserves any existing tokenRequests
+ // already configured on the CSIDriver object without modification.
+ TokenRequests *SecretsStoreTokenRequestsApplyConfiguration `json:"tokenRequests,omitempty"`
+}
+
+// SecretsStoreCSIDriverConfigSpecApplyConfiguration constructs a declarative configuration of the SecretsStoreCSIDriverConfigSpec type for use with
+// apply.
+func SecretsStoreCSIDriverConfigSpec() *SecretsStoreCSIDriverConfigSpecApplyConfiguration {
+ return &SecretsStoreCSIDriverConfigSpecApplyConfiguration{}
+}
+
+// WithSecretRotation sets the SecretRotation field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the SecretRotation field is set to the value of the last call.
+func (b *SecretsStoreCSIDriverConfigSpecApplyConfiguration) WithSecretRotation(value *SecretsStoreSecretRotationApplyConfiguration) *SecretsStoreCSIDriverConfigSpecApplyConfiguration {
+ b.SecretRotation = value
+ return b
+}
+
+// WithTokenRequests sets the TokenRequests field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the TokenRequests field is set to the value of the last call.
+func (b *SecretsStoreCSIDriverConfigSpecApplyConfiguration) WithTokenRequests(value *SecretsStoreTokenRequestsApplyConfiguration) *SecretsStoreCSIDriverConfigSpecApplyConfiguration {
+ b.TokenRequests = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/secretsstoresecretrotation.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/secretsstoresecretrotation.go
new file mode 100644
index 0000000000..0624fe9c67
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/secretsstoresecretrotation.go
@@ -0,0 +1,46 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+import (
+ operatorv1 "github.com/openshift/api/operator/v1"
+)
+
+// SecretsStoreSecretRotationApplyConfiguration represents a declarative configuration of the SecretsStoreSecretRotation type for use
+// with apply.
+//
+// SecretsStoreSecretRotation configures the automatic secret rotation behavior
+// for the Secrets Store CSI driver.
+type SecretsStoreSecretRotationApplyConfiguration struct {
+ // type determines the secret rotation behavior.
+ // When "None", secret rotation is disabled and secrets are only fetched at
+ // initial pod mount time.
+ // When "Custom", secret rotation is enabled with the configuration specified
+ // in the custom field.
+ Type *operatorv1.SecretRotationType `json:"type,omitempty"`
+ // custom holds the custom rotation configuration.
+ // Only valid when type is "Custom".
+ Custom *CustomSecretRotationApplyConfiguration `json:"custom,omitempty"`
+}
+
+// SecretsStoreSecretRotationApplyConfiguration constructs a declarative configuration of the SecretsStoreSecretRotation type for use with
+// apply.
+func SecretsStoreSecretRotation() *SecretsStoreSecretRotationApplyConfiguration {
+ return &SecretsStoreSecretRotationApplyConfiguration{}
+}
+
+// WithType sets the Type field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Type field is set to the value of the last call.
+func (b *SecretsStoreSecretRotationApplyConfiguration) WithType(value operatorv1.SecretRotationType) *SecretsStoreSecretRotationApplyConfiguration {
+ b.Type = &value
+ return b
+}
+
+// WithCustom sets the Custom field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Custom field is set to the value of the last call.
+func (b *SecretsStoreSecretRotationApplyConfiguration) WithCustom(value *CustomSecretRotationApplyConfiguration) *SecretsStoreSecretRotationApplyConfiguration {
+ b.Custom = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/secretsstoretokenrequest.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/secretsstoretokenrequest.go
new file mode 100644
index 0000000000..b8eb7597f7
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/secretsstoretokenrequest.go
@@ -0,0 +1,41 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+// SecretsStoreTokenRequestApplyConfiguration represents a declarative configuration of the SecretsStoreTokenRequest type for use
+// with apply.
+//
+// SecretsStoreTokenRequest specifies a service account token audience configuration
+// for workload identity federation (WIF) with the Secrets Store CSI driver.
+type SecretsStoreTokenRequestApplyConfiguration struct {
+ // audience is the intended audience of the service account token.
+ // An empty string means the issued token will use the kube-apiserver's default APIAudiences.
+ Audience *string `json:"audience,omitempty"`
+ // expirationSeconds is the requested duration of validity of the service account token.
+ // The token issuer may return a token with a different validity duration.
+ // When omitted, the token expiration is determined by the kube-apiserver.
+ // Must be at least 600 seconds (10 minutes) and no more than 315360000 seconds (~10 years).
+ ExpirationSeconds *int32 `json:"expirationSeconds,omitempty"`
+}
+
+// SecretsStoreTokenRequestApplyConfiguration constructs a declarative configuration of the SecretsStoreTokenRequest type for use with
+// apply.
+func SecretsStoreTokenRequest() *SecretsStoreTokenRequestApplyConfiguration {
+ return &SecretsStoreTokenRequestApplyConfiguration{}
+}
+
+// WithAudience sets the Audience field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Audience field is set to the value of the last call.
+func (b *SecretsStoreTokenRequestApplyConfiguration) WithAudience(value string) *SecretsStoreTokenRequestApplyConfiguration {
+ b.Audience = &value
+ return b
+}
+
+// WithExpirationSeconds sets the ExpirationSeconds field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the ExpirationSeconds field is set to the value of the last call.
+func (b *SecretsStoreTokenRequestApplyConfiguration) WithExpirationSeconds(value int32) *SecretsStoreTokenRequestApplyConfiguration {
+ b.ExpirationSeconds = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/secretsstoretokenrequests.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/secretsstoretokenrequests.go
new file mode 100644
index 0000000000..ea9ac415de
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/secretsstoretokenrequests.go
@@ -0,0 +1,47 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1
+
+import (
+ operatorv1 "github.com/openshift/api/operator/v1"
+)
+
+// SecretsStoreTokenRequestsApplyConfiguration represents a declarative configuration of the SecretsStoreTokenRequests type for use
+// with apply.
+//
+// SecretsStoreTokenRequests configures how service account tokens are
+// provided to the Secrets Store CSI driver for workload identity federation.
+type SecretsStoreTokenRequestsApplyConfiguration struct {
+ // type determines how the operator manages tokenRequests on the CSIDriver object.
+ // When "Unmanaged", existing tokenRequests on the CSIDriver are preserved
+ // and the managed field is not used.
+ // When "Managed", the operator sets tokenRequests from the audiences
+ // specified in the managed field, replacing any previously configured values.
+ // Once set to "Managed", type cannot be reverted back to "Unmanaged".
+ Type *operatorv1.TokenRequestsType `json:"type,omitempty"`
+ // managed holds configuration for operator-managed tokenRequests.
+ // Only valid when type is "Managed".
+ Managed *ManagedTokenRequestsApplyConfiguration `json:"managed,omitempty"`
+}
+
+// SecretsStoreTokenRequestsApplyConfiguration constructs a declarative configuration of the SecretsStoreTokenRequests type for use with
+// apply.
+func SecretsStoreTokenRequests() *SecretsStoreTokenRequestsApplyConfiguration {
+ return &SecretsStoreTokenRequestsApplyConfiguration{}
+}
+
+// WithType sets the Type field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Type field is set to the value of the last call.
+func (b *SecretsStoreTokenRequestsApplyConfiguration) WithType(value operatorv1.TokenRequestsType) *SecretsStoreTokenRequestsApplyConfiguration {
+ b.Type = &value
+ return b
+}
+
+// WithManaged sets the Managed field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Managed field is set to the value of the last call.
+func (b *SecretsStoreTokenRequestsApplyConfiguration) WithManaged(value *ManagedTokenRequestsApplyConfiguration) *SecretsStoreTokenRequestsApplyConfiguration {
+ b.Managed = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/clusterapiinstallercomponent.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/clusterapiinstallercomponent.go
index 1de725d88e..17044ff5cf 100644
--- a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/clusterapiinstallercomponent.go
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/clusterapiinstallercomponent.go
@@ -11,13 +11,12 @@ import (
//
// ClusterAPIInstallerComponent defines a component which will be installed by this revision.
type ClusterAPIInstallerComponentApplyConfiguration struct {
- // type is the source type of the component.
- // The only valid value is Image.
- // When set to Image, the image field must be set and will define an image source for the component.
- Type *operatorv1alpha1.InstallerComponentType `json:"type,omitempty"`
- // image defines an image source for a component. The image must contain a
- // /capi-operator-installer directory containing the component manifests.
- Image *ClusterAPIInstallerComponentImageApplyConfiguration `json:"image,omitempty"`
+ // name is the human-readable name of the component. The value has no
+ // effect, and will not be set if the component does not define a name in
+ // its manifests. If set it must consist of alphanumeric characters, or
+ // '-', and may not exceed 255 characters.
+ Name *string `json:"name,omitempty"`
+ ClusterAPIInstallerComponentSourceApplyConfiguration `json:",inline"`
}
// ClusterAPIInstallerComponentApplyConfiguration constructs a declarative configuration of the ClusterAPIInstallerComponent type for use with
@@ -26,11 +25,19 @@ func ClusterAPIInstallerComponent() *ClusterAPIInstallerComponentApplyConfigurat
return &ClusterAPIInstallerComponentApplyConfiguration{}
}
+// WithName sets the Name field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Name field is set to the value of the last call.
+func (b *ClusterAPIInstallerComponentApplyConfiguration) WithName(value string) *ClusterAPIInstallerComponentApplyConfiguration {
+ b.Name = &value
+ return b
+}
+
// WithType sets the Type field in the declarative configuration to the given value
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
// If called multiple times, the Type field is set to the value of the last call.
func (b *ClusterAPIInstallerComponentApplyConfiguration) WithType(value operatorv1alpha1.InstallerComponentType) *ClusterAPIInstallerComponentApplyConfiguration {
- b.Type = &value
+ b.ClusterAPIInstallerComponentSourceApplyConfiguration.Type = &value
return b
}
@@ -38,6 +45,6 @@ func (b *ClusterAPIInstallerComponentApplyConfiguration) WithType(value operator
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
// If called multiple times, the Image field is set to the value of the last call.
func (b *ClusterAPIInstallerComponentApplyConfiguration) WithImage(value *ClusterAPIInstallerComponentImageApplyConfiguration) *ClusterAPIInstallerComponentApplyConfiguration {
- b.Image = value
+ b.ClusterAPIInstallerComponentSourceApplyConfiguration.Image = value
return b
}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/clusterapiinstallercomponentsource.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/clusterapiinstallercomponentsource.go
new file mode 100644
index 0000000000..03f0ac94ee
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/clusterapiinstallercomponentsource.go
@@ -0,0 +1,43 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ operatorv1alpha1 "github.com/openshift/api/operator/v1alpha1"
+)
+
+// ClusterAPIInstallerComponentSourceApplyConfiguration represents a declarative configuration of the ClusterAPIInstallerComponentSource type for use
+// with apply.
+//
+// ClusterAPIInstallerComponentSource defines the source of a component which will be installed by this revision.
+type ClusterAPIInstallerComponentSourceApplyConfiguration struct {
+ // type is the source type of the component.
+ // The only valid value is Image.
+ // When set to Image, the image field must be set and will define an image source for the component.
+ Type *operatorv1alpha1.InstallerComponentType `json:"type,omitempty"`
+ // image defines an image source for a component. The image must contain a
+ // /capi-operator-installer directory containing the component manifests.
+ Image *ClusterAPIInstallerComponentImageApplyConfiguration `json:"image,omitempty"`
+}
+
+// ClusterAPIInstallerComponentSourceApplyConfiguration constructs a declarative configuration of the ClusterAPIInstallerComponentSource type for use with
+// apply.
+func ClusterAPIInstallerComponentSource() *ClusterAPIInstallerComponentSourceApplyConfiguration {
+ return &ClusterAPIInstallerComponentSourceApplyConfiguration{}
+}
+
+// WithType sets the Type field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Type field is set to the value of the last call.
+func (b *ClusterAPIInstallerComponentSourceApplyConfiguration) WithType(value operatorv1alpha1.InstallerComponentType) *ClusterAPIInstallerComponentSourceApplyConfiguration {
+ b.Type = &value
+ return b
+}
+
+// WithImage sets the Image field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Image field is set to the value of the last call.
+func (b *ClusterAPIInstallerComponentSourceApplyConfiguration) WithImage(value *ClusterAPIInstallerComponentImageApplyConfiguration) *ClusterAPIInstallerComponentSourceApplyConfiguration {
+ b.Image = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/clusterapiinstallerrevision.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/clusterapiinstallerrevision.go
index fbd3687f68..1206e0825c 100644
--- a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/clusterapiinstallerrevision.go
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/clusterapiinstallerrevision.go
@@ -21,6 +21,11 @@ type ClusterAPIInstallerRevisionApplyConfiguration struct {
// revision, but which should not be installed or updated. If not set, all
// CRDs in the revision will be managed by the CAPI operator.
UnmanagedCustomResourceDefinitions []string `json:"unmanagedCustomResourceDefinitions,omitempty"`
+ // manifestSubstitutions is a list of envsubst style substitutions which
+ // will be applied to manifests in the revision during rendering. If
+ // defined it must not be empty, and may not contain more than 32 items.
+ // Each manifest substitution must have a unique key.
+ ManifestSubstitutions []ClusterAPIInstallerRevisionManifestSubstitutionApplyConfiguration `json:"manifestSubstitutions,omitempty"`
// components is a list of components which will be installed by this
// revision. Components will be installed in the order they are listed. If
// omitted no components will be installed.
@@ -69,6 +74,19 @@ func (b *ClusterAPIInstallerRevisionApplyConfiguration) WithUnmanagedCustomResou
return b
}
+// WithManifestSubstitutions adds the given value to the ManifestSubstitutions field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the ManifestSubstitutions field.
+func (b *ClusterAPIInstallerRevisionApplyConfiguration) WithManifestSubstitutions(values ...*ClusterAPIInstallerRevisionManifestSubstitutionApplyConfiguration) *ClusterAPIInstallerRevisionApplyConfiguration {
+ for i := range values {
+ if values[i] == nil {
+ panic("nil value passed to WithManifestSubstitutions")
+ }
+ b.ManifestSubstitutions = append(b.ManifestSubstitutions, *values[i])
+ }
+ return b
+}
+
// WithComponents adds the given value to the Components field in the declarative configuration
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
// If called multiple times, values provided by each call will be appended to the Components field.
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/clusterapiinstallerrevisionmanifestsubstitution.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/clusterapiinstallerrevisionmanifestsubstitution.go
new file mode 100644
index 0000000000..1731b5cb3b
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/clusterapiinstallerrevisionmanifestsubstitution.go
@@ -0,0 +1,43 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+// ClusterAPIInstallerRevisionManifestSubstitutionApplyConfiguration represents a declarative configuration of the ClusterAPIInstallerRevisionManifestSubstitution type for use
+// with apply.
+//
+// ClusterAPIInstallerRevisionManifestSubstitution defines an envsubst style
+// substitution which will be applied to manifests in a revision during
+// rendering.
+type ClusterAPIInstallerRevisionManifestSubstitutionApplyConfiguration struct {
+ // key is the name of the envsubst variable to substitute. It must be a
+ // valid envsubst variable name, consisting of letters, digits, and
+ // underscores, and must start with a letter or underscore. The key must
+ // not be empty, and must not exceed 255 characters.
+ Key *string `json:"key,omitempty"`
+ // value is the value to substitute for the envsubst variable. It may be
+ // empty, in which case the variable will be substituted with an empty
+ // string. The value must not exceed 4096 characters.
+ Value *string `json:"value,omitempty"`
+}
+
+// ClusterAPIInstallerRevisionManifestSubstitutionApplyConfiguration constructs a declarative configuration of the ClusterAPIInstallerRevisionManifestSubstitution type for use with
+// apply.
+func ClusterAPIInstallerRevisionManifestSubstitution() *ClusterAPIInstallerRevisionManifestSubstitutionApplyConfiguration {
+ return &ClusterAPIInstallerRevisionManifestSubstitutionApplyConfiguration{}
+}
+
+// WithKey sets the Key field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Key field is set to the value of the last call.
+func (b *ClusterAPIInstallerRevisionManifestSubstitutionApplyConfiguration) WithKey(value string) *ClusterAPIInstallerRevisionManifestSubstitutionApplyConfiguration {
+ b.Key = &value
+ return b
+}
+
+// WithValue sets the Value field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Value field is set to the value of the last call.
+func (b *ClusterAPIInstallerRevisionManifestSubstitutionApplyConfiguration) WithValue(value string) *ClusterAPIInstallerRevisionManifestSubstitutionApplyConfiguration {
+ b.Value = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/clusterapistatus.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/clusterapistatus.go
index a684c0a6ce..300921f5bd 100644
--- a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/clusterapistatus.go
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/clusterapistatus.go
@@ -30,6 +30,9 @@ type ClusterAPIStatusApplyConfiguration struct {
// When adding a revision, the revision number must be greater than the highest revision number in the list.
// Revisions are immutable, although they can be deleted.
Revisions []ClusterAPIInstallerRevisionApplyConfiguration `json:"revisions,omitempty"`
+ // observedRevisionGeneration is the generation of the ClusterAPI object that was last observed by the revision controller.
+ // If specified it must be greater than or equal to 1, and less than 2^53. It may not decrease or be unset once set.
+ ObservedRevisionGeneration *int64 `json:"observedRevisionGeneration,omitempty"`
}
// ClusterAPIStatusApplyConfiguration constructs a declarative configuration of the ClusterAPIStatus type for use with
@@ -66,3 +69,11 @@ func (b *ClusterAPIStatusApplyConfiguration) WithRevisions(values ...*ClusterAPI
}
return b
}
+
+// WithObservedRevisionGeneration sets the ObservedRevisionGeneration field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the ObservedRevisionGeneration field is set to the value of the last call.
+func (b *ClusterAPIStatusApplyConfiguration) WithObservedRevisionGeneration(value int64) *ClusterAPIStatusApplyConfiguration {
+ b.ObservedRevisionGeneration = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/gatewayapiingressconfig.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/gatewayapiingressconfig.go
new file mode 100644
index 0000000000..c2c03ed463
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/gatewayapiingressconfig.go
@@ -0,0 +1,46 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ operatorv1alpha1 "github.com/openshift/api/operator/v1alpha1"
+)
+
+// GatewayAPIIngressConfigApplyConfiguration represents a declarative configuration of the GatewayAPIIngressConfig type for use
+// with apply.
+//
+// GatewayAPIIngressConfig holds configuration for Gateway API integration in the
+// Cluster Ingress Operator.
+type GatewayAPIIngressConfigApplyConfiguration struct {
+ // managementMode specifies how the Cluster Ingress Operator manages Gateway API
+ // Custom Resource Definitions (CRDs), the OpenShift Gateway API implementation,
+ // and its Gateway API controllers.
+ //
+ // Allowed values are "Managed" and "Unmanaged".
+ //
+ // When omitted or set to "Managed", the ingress operator installs, owns, and
+ // upgrades the Gateway API CRDs, protects them with a Validating Admission
+ // Policy, and deploys the OpenShift Gateway API implementation and its Gateway
+ // API controllers.
+ //
+ // When set to "Unmanaged", the ingress operator does not install or manage
+ // Gateway API CRDs and does not deploy the OpenShift Gateway API implementation
+ // or its Gateway API controllers. The cluster administrator or a third-party
+ // product is responsible for providing their own CRDs and Gateway controller.
+ // The ingress operator reports observational status only.
+ ManagementMode *operatorv1alpha1.GatewayAPIManagementMode `json:"managementMode,omitempty"`
+}
+
+// GatewayAPIIngressConfigApplyConfiguration constructs a declarative configuration of the GatewayAPIIngressConfig type for use with
+// apply.
+func GatewayAPIIngressConfig() *GatewayAPIIngressConfigApplyConfiguration {
+ return &GatewayAPIIngressConfigApplyConfiguration{}
+}
+
+// WithManagementMode sets the ManagementMode field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the ManagementMode field is set to the value of the last call.
+func (b *GatewayAPIIngressConfigApplyConfiguration) WithManagementMode(value operatorv1alpha1.GatewayAPIManagementMode) *GatewayAPIIngressConfigApplyConfiguration {
+ b.ManagementMode = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/ingress.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/ingress.go
new file mode 100644
index 0000000000..d97b01aa95
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/ingress.go
@@ -0,0 +1,278 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ operatorv1alpha1 "github.com/openshift/api/operator/v1alpha1"
+ internal "github.com/openshift/client-go/operator/applyconfigurations/internal"
+ metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
+ types "k8s.io/apimachinery/pkg/types"
+ managedfields "k8s.io/apimachinery/pkg/util/managedfields"
+ v1 "k8s.io/client-go/applyconfigurations/meta/v1"
+)
+
+// IngressApplyConfiguration represents a declarative configuration of the Ingress type for use
+// with apply.
+//
+// Ingress contains configuration options specific to the Ingress Operator itself,
+// including how it manages Gateway API integration.
+//
+// Compatibility level 4: No compatibility is provided, the API can change at any point for any reason. These capabilities should not be used by applications needing long term support.
+type IngressApplyConfiguration struct {
+ v1.TypeMetaApplyConfiguration `json:",inline"`
+ // metadata is the standard object's metadata.
+ // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
+ *v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"`
+ // spec holds user settable values for configuration.
+ Spec *IngressSpecApplyConfiguration `json:"spec,omitempty"`
+ // status holds observed values from the cluster.
+ Status *IngressStatusApplyConfiguration `json:"status,omitempty"`
+}
+
+// Ingress constructs a declarative configuration of the Ingress type for use with
+// apply.
+func Ingress(name string) *IngressApplyConfiguration {
+ b := &IngressApplyConfiguration{}
+ b.WithName(name)
+ b.WithKind("Ingress")
+ b.WithAPIVersion("operator.openshift.io/v1alpha1")
+ return b
+}
+
+// ExtractIngressFrom extracts the applied configuration owned by fieldManager from
+// ingress for the specified subresource. Pass an empty string for subresource to extract
+// the main resource. Common subresources include "status", "scale", etc.
+// ingress must be a unmodified Ingress API object that was retrieved from the Kubernetes API.
+// ExtractIngressFrom provides a way to perform a extract/modify-in-place/apply workflow.
+// Note that an extracted apply configuration will contain fewer fields than what the fieldManager previously
+// applied if another fieldManager has updated or force applied any of the previously applied fields.
+func ExtractIngressFrom(ingress *operatorv1alpha1.Ingress, fieldManager string, subresource string) (*IngressApplyConfiguration, error) {
+ b := &IngressApplyConfiguration{}
+ err := managedfields.ExtractInto(ingress, internal.Parser().Type("com.github.openshift.api.operator.v1alpha1.Ingress"), fieldManager, b, subresource)
+ if err != nil {
+ return nil, err
+ }
+ b.WithName(ingress.Name)
+
+ b.WithKind("Ingress")
+ b.WithAPIVersion("operator.openshift.io/v1alpha1")
+ return b, nil
+}
+
+// ExtractIngress extracts the applied configuration owned by fieldManager from
+// ingress. If no managedFields are found in ingress for fieldManager, a
+// IngressApplyConfiguration is returned with only the Name, Namespace (if applicable),
+// APIVersion and Kind populated. It is possible that no managed fields were found for because other
+// field managers have taken ownership of all the fields previously owned by fieldManager, or because
+// the fieldManager never owned fields any fields.
+// ingress must be a unmodified Ingress API object that was retrieved from the Kubernetes API.
+// ExtractIngress provides a way to perform a extract/modify-in-place/apply workflow.
+// Note that an extracted apply configuration will contain fewer fields than what the fieldManager previously
+// applied if another fieldManager has updated or force applied any of the previously applied fields.
+func ExtractIngress(ingress *operatorv1alpha1.Ingress, fieldManager string) (*IngressApplyConfiguration, error) {
+ return ExtractIngressFrom(ingress, fieldManager, "")
+}
+
+// ExtractIngressStatus extracts the applied configuration owned by fieldManager from
+// ingress for the status subresource.
+func ExtractIngressStatus(ingress *operatorv1alpha1.Ingress, fieldManager string) (*IngressApplyConfiguration, error) {
+ return ExtractIngressFrom(ingress, fieldManager, "status")
+}
+
+func (b IngressApplyConfiguration) IsApplyConfiguration() {}
+
+// WithKind sets the Kind field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Kind field is set to the value of the last call.
+func (b *IngressApplyConfiguration) WithKind(value string) *IngressApplyConfiguration {
+ b.TypeMetaApplyConfiguration.Kind = &value
+ return b
+}
+
+// WithAPIVersion sets the APIVersion field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the APIVersion field is set to the value of the last call.
+func (b *IngressApplyConfiguration) WithAPIVersion(value string) *IngressApplyConfiguration {
+ b.TypeMetaApplyConfiguration.APIVersion = &value
+ return b
+}
+
+// WithName sets the Name field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Name field is set to the value of the last call.
+func (b *IngressApplyConfiguration) WithName(value string) *IngressApplyConfiguration {
+ b.ensureObjectMetaApplyConfigurationExists()
+ b.ObjectMetaApplyConfiguration.Name = &value
+ return b
+}
+
+// WithGenerateName sets the GenerateName field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the GenerateName field is set to the value of the last call.
+func (b *IngressApplyConfiguration) WithGenerateName(value string) *IngressApplyConfiguration {
+ b.ensureObjectMetaApplyConfigurationExists()
+ b.ObjectMetaApplyConfiguration.GenerateName = &value
+ return b
+}
+
+// WithNamespace sets the Namespace field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Namespace field is set to the value of the last call.
+func (b *IngressApplyConfiguration) WithNamespace(value string) *IngressApplyConfiguration {
+ b.ensureObjectMetaApplyConfigurationExists()
+ b.ObjectMetaApplyConfiguration.Namespace = &value
+ return b
+}
+
+// WithUID sets the UID field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the UID field is set to the value of the last call.
+func (b *IngressApplyConfiguration) WithUID(value types.UID) *IngressApplyConfiguration {
+ b.ensureObjectMetaApplyConfigurationExists()
+ b.ObjectMetaApplyConfiguration.UID = &value
+ return b
+}
+
+// WithResourceVersion sets the ResourceVersion field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the ResourceVersion field is set to the value of the last call.
+func (b *IngressApplyConfiguration) WithResourceVersion(value string) *IngressApplyConfiguration {
+ b.ensureObjectMetaApplyConfigurationExists()
+ b.ObjectMetaApplyConfiguration.ResourceVersion = &value
+ return b
+}
+
+// WithGeneration sets the Generation field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Generation field is set to the value of the last call.
+func (b *IngressApplyConfiguration) WithGeneration(value int64) *IngressApplyConfiguration {
+ b.ensureObjectMetaApplyConfigurationExists()
+ b.ObjectMetaApplyConfiguration.Generation = &value
+ return b
+}
+
+// WithCreationTimestamp sets the CreationTimestamp field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the CreationTimestamp field is set to the value of the last call.
+func (b *IngressApplyConfiguration) WithCreationTimestamp(value metav1.Time) *IngressApplyConfiguration {
+ b.ensureObjectMetaApplyConfigurationExists()
+ b.ObjectMetaApplyConfiguration.CreationTimestamp = &value
+ return b
+}
+
+// WithDeletionTimestamp sets the DeletionTimestamp field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the DeletionTimestamp field is set to the value of the last call.
+func (b *IngressApplyConfiguration) WithDeletionTimestamp(value metav1.Time) *IngressApplyConfiguration {
+ b.ensureObjectMetaApplyConfigurationExists()
+ b.ObjectMetaApplyConfiguration.DeletionTimestamp = &value
+ return b
+}
+
+// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the DeletionGracePeriodSeconds field is set to the value of the last call.
+func (b *IngressApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *IngressApplyConfiguration {
+ b.ensureObjectMetaApplyConfigurationExists()
+ b.ObjectMetaApplyConfiguration.DeletionGracePeriodSeconds = &value
+ return b
+}
+
+// WithLabels puts the entries into the Labels field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, the entries provided by each call will be put on the Labels field,
+// overwriting an existing map entries in Labels field with the same key.
+func (b *IngressApplyConfiguration) WithLabels(entries map[string]string) *IngressApplyConfiguration {
+ b.ensureObjectMetaApplyConfigurationExists()
+ if b.ObjectMetaApplyConfiguration.Labels == nil && len(entries) > 0 {
+ b.ObjectMetaApplyConfiguration.Labels = make(map[string]string, len(entries))
+ }
+ for k, v := range entries {
+ b.ObjectMetaApplyConfiguration.Labels[k] = v
+ }
+ return b
+}
+
+// WithAnnotations puts the entries into the Annotations field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, the entries provided by each call will be put on the Annotations field,
+// overwriting an existing map entries in Annotations field with the same key.
+func (b *IngressApplyConfiguration) WithAnnotations(entries map[string]string) *IngressApplyConfiguration {
+ b.ensureObjectMetaApplyConfigurationExists()
+ if b.ObjectMetaApplyConfiguration.Annotations == nil && len(entries) > 0 {
+ b.ObjectMetaApplyConfiguration.Annotations = make(map[string]string, len(entries))
+ }
+ for k, v := range entries {
+ b.ObjectMetaApplyConfiguration.Annotations[k] = v
+ }
+ return b
+}
+
+// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the OwnerReferences field.
+func (b *IngressApplyConfiguration) WithOwnerReferences(values ...*v1.OwnerReferenceApplyConfiguration) *IngressApplyConfiguration {
+ b.ensureObjectMetaApplyConfigurationExists()
+ for i := range values {
+ if values[i] == nil {
+ panic("nil value passed to WithOwnerReferences")
+ }
+ b.ObjectMetaApplyConfiguration.OwnerReferences = append(b.ObjectMetaApplyConfiguration.OwnerReferences, *values[i])
+ }
+ return b
+}
+
+// WithFinalizers adds the given value to the Finalizers field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the Finalizers field.
+func (b *IngressApplyConfiguration) WithFinalizers(values ...string) *IngressApplyConfiguration {
+ b.ensureObjectMetaApplyConfigurationExists()
+ for i := range values {
+ b.ObjectMetaApplyConfiguration.Finalizers = append(b.ObjectMetaApplyConfiguration.Finalizers, values[i])
+ }
+ return b
+}
+
+func (b *IngressApplyConfiguration) ensureObjectMetaApplyConfigurationExists() {
+ if b.ObjectMetaApplyConfiguration == nil {
+ b.ObjectMetaApplyConfiguration = &v1.ObjectMetaApplyConfiguration{}
+ }
+}
+
+// WithSpec sets the Spec field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Spec field is set to the value of the last call.
+func (b *IngressApplyConfiguration) WithSpec(value *IngressSpecApplyConfiguration) *IngressApplyConfiguration {
+ b.Spec = value
+ return b
+}
+
+// WithStatus sets the Status field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the Status field is set to the value of the last call.
+func (b *IngressApplyConfiguration) WithStatus(value *IngressStatusApplyConfiguration) *IngressApplyConfiguration {
+ b.Status = value
+ return b
+}
+
+// GetKind retrieves the value of the Kind field in the declarative configuration.
+func (b *IngressApplyConfiguration) GetKind() *string {
+ return b.TypeMetaApplyConfiguration.Kind
+}
+
+// GetAPIVersion retrieves the value of the APIVersion field in the declarative configuration.
+func (b *IngressApplyConfiguration) GetAPIVersion() *string {
+ return b.TypeMetaApplyConfiguration.APIVersion
+}
+
+// GetName retrieves the value of the Name field in the declarative configuration.
+func (b *IngressApplyConfiguration) GetName() *string {
+ b.ensureObjectMetaApplyConfigurationExists()
+ return b.ObjectMetaApplyConfiguration.Name
+}
+
+// GetNamespace retrieves the value of the Namespace field in the declarative configuration.
+func (b *IngressApplyConfiguration) GetNamespace() *string {
+ b.ensureObjectMetaApplyConfigurationExists()
+ return b.ObjectMetaApplyConfiguration.Namespace
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/ingressspec.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/ingressspec.go
new file mode 100644
index 0000000000..6fea3908d1
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/ingressspec.go
@@ -0,0 +1,28 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+// IngressSpecApplyConfiguration represents a declarative configuration of the IngressSpec type for use
+// with apply.
+//
+// IngressSpec is the specification of the desired behavior of the Ingress Operator.
+type IngressSpecApplyConfiguration struct {
+ // gatewayAPI holds configuration for Gateway API integration, including how the
+ // ingress operator manages Gateway API CRDs, the OpenShift Gateway API
+ // implementation, and its Gateway API controllers.
+ GatewayAPI *GatewayAPIIngressConfigApplyConfiguration `json:"gatewayAPI,omitempty"`
+}
+
+// IngressSpecApplyConfiguration constructs a declarative configuration of the IngressSpec type for use with
+// apply.
+func IngressSpec() *IngressSpecApplyConfiguration {
+ return &IngressSpecApplyConfiguration{}
+}
+
+// WithGatewayAPI sets the GatewayAPI field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the GatewayAPI field is set to the value of the last call.
+func (b *IngressSpecApplyConfiguration) WithGatewayAPI(value *GatewayAPIIngressConfigApplyConfiguration) *IngressSpecApplyConfiguration {
+ b.GatewayAPI = value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/ingressstatus.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/ingressstatus.go
new file mode 100644
index 0000000000..9af1720f83
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/ingressstatus.go
@@ -0,0 +1,57 @@
+// Code generated by applyconfiguration-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ v1 "k8s.io/client-go/applyconfigurations/meta/v1"
+)
+
+// IngressStatusApplyConfiguration represents a declarative configuration of the IngressStatus type for use
+// with apply.
+//
+// IngressStatus defines the observed status of the Ingress Operator.
+type IngressStatusApplyConfiguration struct {
+ // conditions is a list of conditions and their status.
+ //
+ // Gateway API CRD management conditions are reported here with the "GatewayAPI" prefix:
+ //
+ // * "GatewayAPICRDsManaged" indicates whether the ingress operator is actively
+ // managing Gateway API CRDs.
+ // * "GatewayAPICRDsPresent" indicates whether Gateway API CRDs exist on the
+ // cluster.
+ // * "GatewayAPICRDsCompliant" indicates whether the installed CRDs match the
+ // version expected by this ingress operator release.
+ Conditions []v1.ConditionApplyConfiguration `json:"conditions,omitempty"`
+ // observedGeneration represents the most recent generation observed by the operator and specifies the version of
+ // the spec field currently being synced.
+ //
+ // When omitted, the operator has not yet observed the resource.
+ ObservedGeneration *int64 `json:"observedGeneration,omitempty"`
+}
+
+// IngressStatusApplyConfiguration constructs a declarative configuration of the IngressStatus type for use with
+// apply.
+func IngressStatus() *IngressStatusApplyConfiguration {
+ return &IngressStatusApplyConfiguration{}
+}
+
+// WithConditions adds the given value to the Conditions field in the declarative configuration
+// and returns the receiver, so that objects can be build by chaining "With" function invocations.
+// If called multiple times, values provided by each call will be appended to the Conditions field.
+func (b *IngressStatusApplyConfiguration) WithConditions(values ...*v1.ConditionApplyConfiguration) *IngressStatusApplyConfiguration {
+ for i := range values {
+ if values[i] == nil {
+ panic("nil value passed to WithConditions")
+ }
+ b.Conditions = append(b.Conditions, *values[i])
+ }
+ return b
+}
+
+// WithObservedGeneration sets the ObservedGeneration field in the declarative configuration to the given value
+// and returns the receiver, so that objects can be built by chaining "With" function invocations.
+// If called multiple times, the ObservedGeneration field is set to the value of the last call.
+func (b *IngressStatusApplyConfiguration) WithObservedGeneration(value int64) *IngressStatusApplyConfiguration {
+ b.ObservedGeneration = &value
+ return b
+}
diff --git a/vendor/github.com/openshift/client-go/operator/applyconfigurations/utils.go b/vendor/github.com/openshift/client-go/operator/applyconfigurations/utils.go
index 3d08f40d09..30d79b6ec8 100644
--- a/vendor/github.com/openshift/client-go/operator/applyconfigurations/utils.go
+++ b/vendor/github.com/openshift/client-go/operator/applyconfigurations/utils.go
@@ -28,6 +28,10 @@ func ForKind(kind schema.GroupVersionKind) interface{} {
return &operatorv1.AddPageApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("Authentication"):
return &operatorv1.AuthenticationApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("AuthenticationConfigMapReference"):
+ return &operatorv1.AuthenticationConfigMapReferenceApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("AuthenticationProxyConfig"):
+ return &operatorv1.AuthenticationProxyConfigApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("AuthenticationSpec"):
return &operatorv1.AuthenticationSpecApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("AuthenticationStatus"):
@@ -50,6 +54,8 @@ func ForKind(kind schema.GroupVersionKind) interface{} {
return &operatorv1.AzureCSIDriverConfigSpecApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("AzureDiskEncryptionSet"):
return &operatorv1.AzureDiskEncryptionSetApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("BGPManagedConfig"):
+ return &operatorv1.BGPManagedConfigApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("BootImageSkewEnforcementConfig"):
return &operatorv1.BootImageSkewEnforcementConfigApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("BootImageSkewEnforcementStatus"):
@@ -108,6 +114,8 @@ func ForKind(kind schema.GroupVersionKind) interface{} {
return &operatorv1.CSISnapshotControllerSpecApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("CSISnapshotControllerStatus"):
return &operatorv1.CSISnapshotControllerStatusApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("CustomSecretRotation"):
+ return &operatorv1.CustomSecretRotationApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("DefaultNetworkDefinition"):
return &operatorv1.DefaultNetworkDefinitionApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("DeveloperConsoleCatalogCategory"):
@@ -234,6 +242,14 @@ func ForKind(kind schema.GroupVersionKind) interface{} {
return &operatorv1.IPv6OVNKubernetesConfigApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("IrreconcilableValidationOverrides"):
return &operatorv1.IrreconcilableValidationOverridesApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("KMSEncryptionStatus"):
+ return &operatorv1.KMSEncryptionStatusApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("KMSPluginHealthReport"):
+ return &operatorv1.KMSPluginHealthReportApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("KMSPreflightCheck"):
+ return &operatorv1.KMSPreflightCheckApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("KMSPreflightResult"):
+ return &operatorv1.KMSPreflightResultApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("KubeAPIServer"):
return &operatorv1.KubeAPIServerApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("KubeAPIServerSpec"):
@@ -276,6 +292,8 @@ func ForKind(kind schema.GroupVersionKind) interface{} {
return &operatorv1.MachineManagerSelectorApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("ManagedBootImages"):
return &operatorv1.ManagedBootImagesApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("ManagedTokenRequests"):
+ return &operatorv1.ManagedTokenRequestsApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("MTUMigration"):
return &operatorv1.MTUMigrationApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("MTUMigrationValues"):
@@ -318,6 +336,8 @@ func ForKind(kind schema.GroupVersionKind) interface{} {
return &operatorv1.NodePortStrategyApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("NodeStatus"):
return &operatorv1.NodeStatusApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("NoOverlayConfig"):
+ return &operatorv1.NoOverlayConfigApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("OAuthAPIServerStatus"):
return &operatorv1.OAuthAPIServerStatusApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("OLM"):
@@ -378,6 +398,14 @@ func ForKind(kind schema.GroupVersionKind) interface{} {
return &operatorv1.RestartServiceApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("RouteAdmissionPolicy"):
return &operatorv1.RouteAdmissionPolicyApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("SecretsStoreCSIDriverConfigSpec"):
+ return &operatorv1.SecretsStoreCSIDriverConfigSpecApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("SecretsStoreSecretRotation"):
+ return &operatorv1.SecretsStoreSecretRotationApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("SecretsStoreTokenRequest"):
+ return &operatorv1.SecretsStoreTokenRequestApplyConfiguration{}
+ case v1.SchemeGroupVersion.WithKind("SecretsStoreTokenRequests"):
+ return &operatorv1.SecretsStoreTokenRequestsApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("Server"):
return &operatorv1.ServerApplyConfiguration{}
case v1.SchemeGroupVersion.WithKind("ServiceAccountIssuerStatus"):
@@ -444,8 +472,12 @@ func ForKind(kind schema.GroupVersionKind) interface{} {
return &operatorv1alpha1.ClusterAPIInstallerComponentApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("ClusterAPIInstallerComponentImage"):
return &operatorv1alpha1.ClusterAPIInstallerComponentImageApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("ClusterAPIInstallerComponentSource"):
+ return &operatorv1alpha1.ClusterAPIInstallerComponentSourceApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("ClusterAPIInstallerRevision"):
return &operatorv1alpha1.ClusterAPIInstallerRevisionApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("ClusterAPIInstallerRevisionManifestSubstitution"):
+ return &operatorv1alpha1.ClusterAPIInstallerRevisionManifestSubstitutionApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("ClusterAPISpec"):
return &operatorv1alpha1.ClusterAPISpecApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("ClusterAPIStatus"):
@@ -462,10 +494,18 @@ func ForKind(kind schema.GroupVersionKind) interface{} {
return &operatorv1alpha1.EtcdBackupSpecApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("EtcdBackupStatus"):
return &operatorv1alpha1.EtcdBackupStatusApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("GatewayAPIIngressConfig"):
+ return &operatorv1alpha1.GatewayAPIIngressConfigApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("ImageContentSourcePolicy"):
return &operatorv1alpha1.ImageContentSourcePolicyApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("ImageContentSourcePolicySpec"):
return &operatorv1alpha1.ImageContentSourcePolicySpecApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("Ingress"):
+ return &operatorv1alpha1.IngressApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("IngressSpec"):
+ return &operatorv1alpha1.IngressSpecApplyConfiguration{}
+ case v1alpha1.SchemeGroupVersion.WithKind("IngressStatus"):
+ return &operatorv1alpha1.IngressStatusApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("OLM"):
return &operatorv1alpha1.OLMApplyConfiguration{}
case v1alpha1.SchemeGroupVersion.WithKind("OLMSpec"):
diff --git a/vendor/github.com/openshift/client-go/operator/clientset/versioned/fake/clientset_generated.go b/vendor/github.com/openshift/client-go/operator/clientset/versioned/fake/clientset_generated.go
index 9cb092b253..9d7aa5dc74 100644
--- a/vendor/github.com/openshift/client-go/operator/clientset/versioned/fake/clientset_generated.go
+++ b/vendor/github.com/openshift/client-go/operator/clientset/versioned/fake/clientset_generated.go
@@ -21,10 +21,6 @@ import (
// It's backed by a very simple object tracker that processes creates, updates and deletions as-is,
// without applying any field management, validations and/or defaults. It shouldn't be considered a replacement
// for a real clientset and is mostly useful in simple unit tests.
-//
-// Deprecated: NewClientset replaces this with support for field management, which significantly improves
-// server side apply testing. NewClientset is only available when apply configurations are generated (e.g.
-// via --with-applyconfig).
func NewSimpleClientset(objects ...runtime.Object) *Clientset {
o := testing.NewObjectTracker(scheme, codecs.UniversalDecoder())
for _, obj := range objects {
@@ -70,7 +66,7 @@ func (c *Clientset) Tracker() testing.ObjectTracker {
return c.tracker
}
-// IsWatchListSemanticsSupported informs the reflector that this client
+// IsWatchListSemanticsUnSupported informs the reflector that this client
// doesn't support WatchList semantics.
//
// This is a synthetic method whose sole purpose is to satisfy the optional
@@ -85,6 +81,10 @@ func (c *Clientset) IsWatchListSemanticsUnSupported() bool {
// It's backed by a very simple object tracker that processes creates, updates and deletions as-is,
// without applying any validations and/or defaults. It shouldn't be considered a replacement
// for a real clientset and is mostly useful in simple unit tests.
+//
+// Compared to NewSimpleClientset, the Clientset returned here supports field tracking and thus
+// server-side apply. Beware though that support in that for CRDs is missing
+// (https://github.com/kubernetes/kubernetes/issues/126850).
func NewClientset(objects ...runtime.Object) *Clientset {
o := testing.NewFieldManagedObjectTracker(
scheme,
diff --git a/vendor/github.com/openshift/client-go/operator/clientset/versioned/typed/operator/v1alpha1/fake/fake_ingress.go b/vendor/github.com/openshift/client-go/operator/clientset/versioned/typed/operator/v1alpha1/fake/fake_ingress.go
new file mode 100644
index 0000000000..f8cb0f4332
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/operator/clientset/versioned/typed/operator/v1alpha1/fake/fake_ingress.go
@@ -0,0 +1,35 @@
+// Code generated by client-gen. DO NOT EDIT.
+
+package fake
+
+import (
+ v1alpha1 "github.com/openshift/api/operator/v1alpha1"
+ operatorv1alpha1 "github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1"
+ typedoperatorv1alpha1 "github.com/openshift/client-go/operator/clientset/versioned/typed/operator/v1alpha1"
+ gentype "k8s.io/client-go/gentype"
+)
+
+// fakeIngresses implements IngressInterface
+type fakeIngresses struct {
+ *gentype.FakeClientWithListAndApply[*v1alpha1.Ingress, *v1alpha1.IngressList, *operatorv1alpha1.IngressApplyConfiguration]
+ Fake *FakeOperatorV1alpha1
+}
+
+func newFakeIngresses(fake *FakeOperatorV1alpha1) typedoperatorv1alpha1.IngressInterface {
+ return &fakeIngresses{
+ gentype.NewFakeClientWithListAndApply[*v1alpha1.Ingress, *v1alpha1.IngressList, *operatorv1alpha1.IngressApplyConfiguration](
+ fake.Fake,
+ "",
+ v1alpha1.SchemeGroupVersion.WithResource("ingresses"),
+ v1alpha1.SchemeGroupVersion.WithKind("Ingress"),
+ func() *v1alpha1.Ingress { return &v1alpha1.Ingress{} },
+ func() *v1alpha1.IngressList { return &v1alpha1.IngressList{} },
+ func(dst, src *v1alpha1.IngressList) { dst.ListMeta = src.ListMeta },
+ func(list *v1alpha1.IngressList) []*v1alpha1.Ingress { return gentype.ToPointerSlice(list.Items) },
+ func(list *v1alpha1.IngressList, items []*v1alpha1.Ingress) {
+ list.Items = gentype.FromPointerSlice(items)
+ },
+ ),
+ fake,
+ }
+}
diff --git a/vendor/github.com/openshift/client-go/operator/clientset/versioned/typed/operator/v1alpha1/fake/fake_operator_client.go b/vendor/github.com/openshift/client-go/operator/clientset/versioned/typed/operator/v1alpha1/fake/fake_operator_client.go
index 67792010a4..2abd4defc4 100644
--- a/vendor/github.com/openshift/client-go/operator/clientset/versioned/typed/operator/v1alpha1/fake/fake_operator_client.go
+++ b/vendor/github.com/openshift/client-go/operator/clientset/versioned/typed/operator/v1alpha1/fake/fake_operator_client.go
@@ -28,6 +28,10 @@ func (c *FakeOperatorV1alpha1) ImageContentSourcePolicies() v1alpha1.ImageConten
return newFakeImageContentSourcePolicies(c)
}
+func (c *FakeOperatorV1alpha1) Ingresses() v1alpha1.IngressInterface {
+ return newFakeIngresses(c)
+}
+
func (c *FakeOperatorV1alpha1) OLMs() v1alpha1.OLMInterface {
return newFakeOLMs(c)
}
diff --git a/vendor/github.com/openshift/client-go/operator/clientset/versioned/typed/operator/v1alpha1/generated_expansion.go b/vendor/github.com/openshift/client-go/operator/clientset/versioned/typed/operator/v1alpha1/generated_expansion.go
index a19ef54dc1..09baa63c3d 100644
--- a/vendor/github.com/openshift/client-go/operator/clientset/versioned/typed/operator/v1alpha1/generated_expansion.go
+++ b/vendor/github.com/openshift/client-go/operator/clientset/versioned/typed/operator/v1alpha1/generated_expansion.go
@@ -10,4 +10,6 @@ type EtcdBackupExpansion interface{}
type ImageContentSourcePolicyExpansion interface{}
+type IngressExpansion interface{}
+
type OLMExpansion interface{}
diff --git a/vendor/github.com/openshift/client-go/operator/clientset/versioned/typed/operator/v1alpha1/ingress.go b/vendor/github.com/openshift/client-go/operator/clientset/versioned/typed/operator/v1alpha1/ingress.go
new file mode 100644
index 0000000000..5c84be3bee
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/operator/clientset/versioned/typed/operator/v1alpha1/ingress.go
@@ -0,0 +1,58 @@
+// Code generated by client-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ context "context"
+
+ operatorv1alpha1 "github.com/openshift/api/operator/v1alpha1"
+ applyconfigurationsoperatorv1alpha1 "github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1"
+ scheme "github.com/openshift/client-go/operator/clientset/versioned/scheme"
+ v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
+ types "k8s.io/apimachinery/pkg/types"
+ watch "k8s.io/apimachinery/pkg/watch"
+ gentype "k8s.io/client-go/gentype"
+)
+
+// IngressesGetter has a method to return a IngressInterface.
+// A group's client should implement this interface.
+type IngressesGetter interface {
+ Ingresses() IngressInterface
+}
+
+// IngressInterface has methods to work with Ingress resources.
+type IngressInterface interface {
+ Create(ctx context.Context, ingress *operatorv1alpha1.Ingress, opts v1.CreateOptions) (*operatorv1alpha1.Ingress, error)
+ Update(ctx context.Context, ingress *operatorv1alpha1.Ingress, opts v1.UpdateOptions) (*operatorv1alpha1.Ingress, error)
+ // Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
+ UpdateStatus(ctx context.Context, ingress *operatorv1alpha1.Ingress, opts v1.UpdateOptions) (*operatorv1alpha1.Ingress, error)
+ Delete(ctx context.Context, name string, opts v1.DeleteOptions) error
+ DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error
+ Get(ctx context.Context, name string, opts v1.GetOptions) (*operatorv1alpha1.Ingress, error)
+ List(ctx context.Context, opts v1.ListOptions) (*operatorv1alpha1.IngressList, error)
+ Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
+ Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *operatorv1alpha1.Ingress, err error)
+ Apply(ctx context.Context, ingress *applyconfigurationsoperatorv1alpha1.IngressApplyConfiguration, opts v1.ApplyOptions) (result *operatorv1alpha1.Ingress, err error)
+ // Add a +genclient:noStatus comment above the type to avoid generating ApplyStatus().
+ ApplyStatus(ctx context.Context, ingress *applyconfigurationsoperatorv1alpha1.IngressApplyConfiguration, opts v1.ApplyOptions) (result *operatorv1alpha1.Ingress, err error)
+ IngressExpansion
+}
+
+// ingresses implements IngressInterface
+type ingresses struct {
+ *gentype.ClientWithListAndApply[*operatorv1alpha1.Ingress, *operatorv1alpha1.IngressList, *applyconfigurationsoperatorv1alpha1.IngressApplyConfiguration]
+}
+
+// newIngresses returns a Ingresses
+func newIngresses(c *OperatorV1alpha1Client) *ingresses {
+ return &ingresses{
+ gentype.NewClientWithListAndApply[*operatorv1alpha1.Ingress, *operatorv1alpha1.IngressList, *applyconfigurationsoperatorv1alpha1.IngressApplyConfiguration](
+ "ingresses",
+ c.RESTClient(),
+ scheme.ParameterCodec,
+ "",
+ func() *operatorv1alpha1.Ingress { return &operatorv1alpha1.Ingress{} },
+ func() *operatorv1alpha1.IngressList { return &operatorv1alpha1.IngressList{} },
+ ),
+ }
+}
diff --git a/vendor/github.com/openshift/client-go/operator/clientset/versioned/typed/operator/v1alpha1/operator_client.go b/vendor/github.com/openshift/client-go/operator/clientset/versioned/typed/operator/v1alpha1/operator_client.go
index 6ed123d5e3..fd1b968a3b 100644
--- a/vendor/github.com/openshift/client-go/operator/clientset/versioned/typed/operator/v1alpha1/operator_client.go
+++ b/vendor/github.com/openshift/client-go/operator/clientset/versioned/typed/operator/v1alpha1/operator_client.go
@@ -16,6 +16,7 @@ type OperatorV1alpha1Interface interface {
ClusterVersionOperatorsGetter
EtcdBackupsGetter
ImageContentSourcePoliciesGetter
+ IngressesGetter
OLMsGetter
}
@@ -40,6 +41,10 @@ func (c *OperatorV1alpha1Client) ImageContentSourcePolicies() ImageContentSource
return newImageContentSourcePolicies(c)
}
+func (c *OperatorV1alpha1Client) Ingresses() IngressInterface {
+ return newIngresses(c)
+}
+
func (c *OperatorV1alpha1Client) OLMs() OLMInterface {
return newOLMs(c)
}
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/factory.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/factory.go
index 4f1751045f..cc57daa2a3 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/factory.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/factory.go
@@ -3,6 +3,7 @@
package externalversions
import (
+ context "context"
reflect "reflect"
sync "sync"
time "time"
@@ -13,6 +14,7 @@ import (
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
schema "k8s.io/apimachinery/pkg/runtime/schema"
+ wait "k8s.io/apimachinery/pkg/util/wait"
cache "k8s.io/client-go/tools/cache"
)
@@ -27,6 +29,7 @@ type sharedInformerFactory struct {
defaultResync time.Duration
customResync map[reflect.Type]time.Duration
transform cache.TransformFunc
+ informerName *cache.InformerName
informers map[reflect.Type]cache.SharedIndexInformer
// startedInformers is used for tracking which informers have been started.
@@ -73,6 +76,21 @@ func WithTransform(transform cache.TransformFunc) SharedInformerOption {
}
}
+// WithInformerName sets the InformerName for informer identity used in metrics.
+// The InformerName must be created via cache.NewInformerName() at startup,
+// which validates global uniqueness. Each informer type will register its
+// GVR under this name.
+func WithInformerName(informerName *cache.InformerName) SharedInformerOption {
+ return func(factory *sharedInformerFactory) *sharedInformerFactory {
+ factory.informerName = informerName
+ return factory
+ }
+}
+
+func (f *sharedInformerFactory) InformerName() *cache.InformerName {
+ return f.informerName
+}
+
// NewSharedInformerFactory constructs a new instance of sharedInformerFactory for all namespaces.
func NewSharedInformerFactory(client versioned.Interface, defaultResync time.Duration) SharedInformerFactory {
return NewSharedInformerFactoryWithOptions(client, defaultResync)
@@ -107,6 +125,10 @@ func NewSharedInformerFactoryWithOptions(client versioned.Interface, defaultResy
}
func (f *sharedInformerFactory) Start(stopCh <-chan struct{}) {
+ f.StartWithContext(wait.ContextForChannel(stopCh))
+}
+
+func (f *sharedInformerFactory) StartWithContext(ctx context.Context) {
f.lock.Lock()
defer f.lock.Unlock()
@@ -116,15 +138,9 @@ func (f *sharedInformerFactory) Start(stopCh <-chan struct{}) {
for informerType, informer := range f.informers {
if !f.startedInformers[informerType] {
- f.wg.Add(1)
- // We need a new variable in each loop iteration,
- // otherwise the goroutine would use the loop variable
- // and that keeps changing.
- informer := informer
- go func() {
- defer f.wg.Done()
- informer.Run(stopCh)
- }()
+ f.wg.Go(func() {
+ informer.RunWithContext(ctx)
+ })
f.startedInformers[informerType] = true
}
}
@@ -137,9 +153,15 @@ func (f *sharedInformerFactory) Shutdown() {
// Will return immediately if there is nothing to wait for.
f.wg.Wait()
+ f.informerName.Release()
}
func (f *sharedInformerFactory) WaitForCacheSync(stopCh <-chan struct{}) map[reflect.Type]bool {
+ result := f.WaitForCacheSyncWithContext(wait.ContextForChannel(stopCh))
+ return result.Synced
+}
+
+func (f *sharedInformerFactory) WaitForCacheSyncWithContext(ctx context.Context) cache.SyncResult {
informers := func() map[reflect.Type]cache.SharedIndexInformer {
f.lock.Lock()
defer f.lock.Unlock()
@@ -153,10 +175,31 @@ func (f *sharedInformerFactory) WaitForCacheSync(stopCh <-chan struct{}) map[ref
return informers
}()
- res := map[reflect.Type]bool{}
+ // Wait for informers to sync, without polling.
+ cacheSyncs := make([]cache.DoneChecker, 0, len(informers))
+ for _, informer := range informers {
+ cacheSyncs = append(cacheSyncs, informer.HasSyncedChecker())
+ }
+ cache.WaitFor(ctx, "" /* no logging */, cacheSyncs...)
+
+ res := cache.SyncResult{
+ Synced: make(map[reflect.Type]bool, len(informers)),
+ }
+ failed := false
for informType, informer := range informers {
- res[informType] = cache.WaitForCacheSync(stopCh, informer.HasSynced)
+ hasSynced := informer.HasSynced()
+ if !hasSynced {
+ failed = true
+ }
+ res.Synced[informType] = hasSynced
}
+ if failed {
+ // context.Cause is more informative than ctx.Err().
+ // This must be non-nil, otherwise WaitFor wouldn't have stopped
+ // prematurely.
+ res.Err = context.Cause(ctx)
+ }
+
return res
}
@@ -178,7 +221,9 @@ func (f *sharedInformerFactory) InformerFor(obj runtime.Object, newFunc internal
}
informer = newFunc(f.client, resyncPeriod)
- informer.SetTransform(f.transform)
+ if f.transform != nil {
+ informer.SetTransform(f.transform)
+ }
f.informers[informerType] = informer
return informer
@@ -195,27 +240,46 @@ func (f *sharedInformerFactory) InformerFor(obj runtime.Object, newFunc internal
// defer factory.WaitForStop() // Returns immediately if nothing was started.
// genericInformer := factory.ForResource(resource)
// typedInformer := factory.SomeAPIGroup().V1().SomeType()
-// factory.Start(ctx.Done()) // Start processing these informers.
-// synced := factory.WaitForCacheSync(ctx.Done())
-// for v, ok := range synced {
-// if !ok {
-// fmt.Fprintf(os.Stderr, "caches failed to sync: %v", v)
-// return
-// }
+// handle, err := typeInformer.Informer().AddEventHandler(...)
+// if err != nil {
+// return fmt.Errorf("register event handler: %v", err)
+// }
+// defer typeInformer.Informer().RemoveEventHandler(handle) // Avoids leaking goroutines.
+// factory.StartWithContext(ctx) // Start processing these informers.
+// synced := factory.WaitForCacheSyncWithContext(ctx)
+// if err := synced.AsError(); err != nil {
+// return err
+// }
+// for v := range synced {
+// // Only if desired log some information similar to this.
+// fmt.Fprintf(os.Stdout, "cache synced: %s", v)
+// }
+//
+// // Also make sure that all of the initial cache events have been delivered.
+// if !WaitFor(ctx, "event handler sync", handle.HasSyncedChecker()) {
+// // Must have failed because of context.
+// return fmt.Errorf("sync event handler: %w", context.Cause(ctx))
// }
//
// // Creating informers can also be created after Start, but then
// // Start must be called again:
// anotherGenericInformer := factory.ForResource(resource)
-// factory.Start(ctx.Done())
+// factory.StartWithContext(ctx)
type SharedInformerFactory interface {
internalinterfaces.SharedInformerFactory
// Start initializes all requested informers. They are handled in goroutines
// which run until the stop channel gets closed.
// Warning: Start does not block. When run in a go-routine, it will race with a later WaitForCacheSync.
+ //
+ // Contextual logging: StartWithContext should be used instead of Start in code which supports contextual logging.
Start(stopCh <-chan struct{})
+ // StartWithContext initializes all requested informers. They are handled in goroutines
+ // which run until the context gets canceled.
+ // Warning: StartWithContext does not block. When run in a go-routine, it will race with a later WaitForCacheSync.
+ StartWithContext(ctx context.Context)
+
// Shutdown marks a factory as shutting down. At that point no new
// informers can be started anymore and Start will return without
// doing anything.
@@ -230,8 +294,14 @@ type SharedInformerFactory interface {
// WaitForCacheSync blocks until all started informers' caches were synced
// or the stop channel gets closed.
+ //
+ // Contextual logging: WaitForCacheSync should be used instead of WaitForCacheSync in code which supports contextual logging. It also returns a more useful result.
WaitForCacheSync(stopCh <-chan struct{}) map[reflect.Type]bool
+ // WaitForCacheSyncWithContext blocks until all started informers' caches were synced
+ // or the context gets canceled.
+ WaitForCacheSyncWithContext(ctx context.Context) cache.SyncResult
+
// ForResource gives generic access to a shared informer of the matching type.
ForResource(resource schema.GroupVersionResource) (GenericInformer, error)
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/generic.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/generic.go
index 327a1b6e89..7f5fe4eed8 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/generic.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/generic.go
@@ -94,6 +94,8 @@ func (f *sharedInformerFactory) ForResource(resource schema.GroupVersionResource
return &genericInformer{resource: resource.GroupResource(), informer: f.Operator().V1alpha1().EtcdBackups().Informer()}, nil
case v1alpha1.SchemeGroupVersion.WithResource("imagecontentsourcepolicies"):
return &genericInformer{resource: resource.GroupResource(), informer: f.Operator().V1alpha1().ImageContentSourcePolicies().Informer()}, nil
+ case v1alpha1.SchemeGroupVersion.WithResource("ingresses"):
+ return &genericInformer{resource: resource.GroupResource(), informer: f.Operator().V1alpha1().Ingresses().Informer()}, nil
case v1alpha1.SchemeGroupVersion.WithResource("olms"):
return &genericInformer{resource: resource.GroupResource(), informer: f.Operator().V1alpha1().OLMs().Informer()}, nil
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/internalinterfaces/factory_interfaces.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/internalinterfaces/factory_interfaces.go
index bf4618167f..e3fe8030d3 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/internalinterfaces/factory_interfaces.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/internalinterfaces/factory_interfaces.go
@@ -18,7 +18,26 @@ type NewInformerFunc func(versioned.Interface, time.Duration) cache.SharedIndexI
type SharedInformerFactory interface {
Start(stopCh <-chan struct{})
InformerFor(obj runtime.Object, newFunc NewInformerFunc) cache.SharedIndexInformer
+ InformerName() *cache.InformerName
}
// TweakListOptionsFunc is a function that transforms a v1.ListOptions.
type TweakListOptionsFunc func(*v1.ListOptions)
+
+// InformerOptions holds the options for creating an informer.
+type InformerOptions struct {
+ // ResyncPeriod is the resync period for this informer.
+ // If not set, defaults to 0 (no resync).
+ ResyncPeriod time.Duration
+
+ // Indexers are the indexers for this informer.
+ Indexers cache.Indexers
+
+ // InformerName is used to uniquely identify this informer for metrics.
+ // If not set, metrics will not be published for this informer.
+ // Use cache.NewInformerName() to create an InformerName at startup.
+ InformerName *cache.InformerName
+
+ // TweakListOptions is an optional function to modify the list options.
+ TweakListOptions TweakListOptionsFunc
+}
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/authentication.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/authentication.go
index f0f0e0d198..eb63815e2e 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/authentication.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/authentication.go
@@ -12,6 +12,7 @@ import (
operatorv1 "github.com/openshift/client-go/operator/listers/operator/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type authenticationInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewAuthenticationInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredAuthenticationInformer(client, resyncPeriod, indexers, nil)
+ return NewAuthenticationInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredAuthenticationInformer constructs a new informer for Authentication type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredAuthenticationInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewAuthenticationInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewAuthenticationInformerWithOptions constructs a new informer for Authentication type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewAuthenticationInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1", Resource: "authentications"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().Authentications().List(context.Background(), options)
+ return client.OperatorV1().Authentications().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().Authentications().Watch(context.Background(), options)
+ return client.OperatorV1().Authentications().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().Authentications().List(ctx, options)
+ return client.OperatorV1().Authentications().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().Authentications().Watch(ctx, options)
+ return client.OperatorV1().Authentications().Watch(ctx, opts)
},
}, client),
&apioperatorv1.Authentication{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *authenticationInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredAuthenticationInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewAuthenticationInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *authenticationInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/cloudcredential.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/cloudcredential.go
index 726cdea8c4..82a15b21ca 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/cloudcredential.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/cloudcredential.go
@@ -12,6 +12,7 @@ import (
operatorv1 "github.com/openshift/client-go/operator/listers/operator/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type cloudCredentialInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewCloudCredentialInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredCloudCredentialInformer(client, resyncPeriod, indexers, nil)
+ return NewCloudCredentialInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredCloudCredentialInformer constructs a new informer for CloudCredential type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredCloudCredentialInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewCloudCredentialInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewCloudCredentialInformerWithOptions constructs a new informer for CloudCredential type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewCloudCredentialInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1", Resource: "cloudcredentials"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().CloudCredentials().List(context.Background(), options)
+ return client.OperatorV1().CloudCredentials().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().CloudCredentials().Watch(context.Background(), options)
+ return client.OperatorV1().CloudCredentials().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().CloudCredentials().List(ctx, options)
+ return client.OperatorV1().CloudCredentials().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().CloudCredentials().Watch(ctx, options)
+ return client.OperatorV1().CloudCredentials().Watch(ctx, opts)
},
}, client),
&apioperatorv1.CloudCredential{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *cloudCredentialInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredCloudCredentialInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewCloudCredentialInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *cloudCredentialInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/clustercsidriver.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/clustercsidriver.go
index c2ff698afc..4c9c3dfad4 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/clustercsidriver.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/clustercsidriver.go
@@ -12,6 +12,7 @@ import (
operatorv1 "github.com/openshift/client-go/operator/listers/operator/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type clusterCSIDriverInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewClusterCSIDriverInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredClusterCSIDriverInformer(client, resyncPeriod, indexers, nil)
+ return NewClusterCSIDriverInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredClusterCSIDriverInformer constructs a new informer for ClusterCSIDriver type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredClusterCSIDriverInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewClusterCSIDriverInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewClusterCSIDriverInformerWithOptions constructs a new informer for ClusterCSIDriver type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewClusterCSIDriverInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1", Resource: "clustercsidrivers"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().ClusterCSIDrivers().List(context.Background(), options)
+ return client.OperatorV1().ClusterCSIDrivers().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().ClusterCSIDrivers().Watch(context.Background(), options)
+ return client.OperatorV1().ClusterCSIDrivers().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().ClusterCSIDrivers().List(ctx, options)
+ return client.OperatorV1().ClusterCSIDrivers().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().ClusterCSIDrivers().Watch(ctx, options)
+ return client.OperatorV1().ClusterCSIDrivers().Watch(ctx, opts)
},
}, client),
&apioperatorv1.ClusterCSIDriver{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *clusterCSIDriverInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredClusterCSIDriverInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewClusterCSIDriverInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *clusterCSIDriverInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/config.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/config.go
index d8b12b3ad4..04ecf5cb57 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/config.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/config.go
@@ -12,6 +12,7 @@ import (
operatorv1 "github.com/openshift/client-go/operator/listers/operator/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type configInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewConfigInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredConfigInformer(client, resyncPeriod, indexers, nil)
+ return NewConfigInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredConfigInformer constructs a new informer for Config type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredConfigInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewConfigInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewConfigInformerWithOptions constructs a new informer for Config type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewConfigInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1", Resource: "configs"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().Configs().List(context.Background(), options)
+ return client.OperatorV1().Configs().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().Configs().Watch(context.Background(), options)
+ return client.OperatorV1().Configs().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().Configs().List(ctx, options)
+ return client.OperatorV1().Configs().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().Configs().Watch(ctx, options)
+ return client.OperatorV1().Configs().Watch(ctx, opts)
},
}, client),
&apioperatorv1.Config{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *configInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredConfigInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewConfigInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *configInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/console.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/console.go
index 17752bfc4b..0233906c49 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/console.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/console.go
@@ -12,6 +12,7 @@ import (
operatorv1 "github.com/openshift/client-go/operator/listers/operator/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type consoleInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewConsoleInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredConsoleInformer(client, resyncPeriod, indexers, nil)
+ return NewConsoleInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredConsoleInformer constructs a new informer for Console type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredConsoleInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewConsoleInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewConsoleInformerWithOptions constructs a new informer for Console type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewConsoleInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1", Resource: "consoles"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().Consoles().List(context.Background(), options)
+ return client.OperatorV1().Consoles().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().Consoles().Watch(context.Background(), options)
+ return client.OperatorV1().Consoles().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().Consoles().List(ctx, options)
+ return client.OperatorV1().Consoles().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().Consoles().Watch(ctx, options)
+ return client.OperatorV1().Consoles().Watch(ctx, opts)
},
}, client),
&apioperatorv1.Console{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *consoleInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredConsoleInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewConsoleInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *consoleInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/csisnapshotcontroller.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/csisnapshotcontroller.go
index b6f7881bb6..59a719280e 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/csisnapshotcontroller.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/csisnapshotcontroller.go
@@ -12,6 +12,7 @@ import (
operatorv1 "github.com/openshift/client-go/operator/listers/operator/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type cSISnapshotControllerInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewCSISnapshotControllerInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredCSISnapshotControllerInformer(client, resyncPeriod, indexers, nil)
+ return NewCSISnapshotControllerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredCSISnapshotControllerInformer constructs a new informer for CSISnapshotController type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredCSISnapshotControllerInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewCSISnapshotControllerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewCSISnapshotControllerInformerWithOptions constructs a new informer for CSISnapshotController type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewCSISnapshotControllerInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1", Resource: "csisnapshotcontrollers"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().CSISnapshotControllers().List(context.Background(), options)
+ return client.OperatorV1().CSISnapshotControllers().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().CSISnapshotControllers().Watch(context.Background(), options)
+ return client.OperatorV1().CSISnapshotControllers().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().CSISnapshotControllers().List(ctx, options)
+ return client.OperatorV1().CSISnapshotControllers().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().CSISnapshotControllers().Watch(ctx, options)
+ return client.OperatorV1().CSISnapshotControllers().Watch(ctx, opts)
},
}, client),
&apioperatorv1.CSISnapshotController{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *cSISnapshotControllerInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredCSISnapshotControllerInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewCSISnapshotControllerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *cSISnapshotControllerInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/dns.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/dns.go
index 6459b2ae44..9a21310a52 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/dns.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/dns.go
@@ -12,6 +12,7 @@ import (
operatorv1 "github.com/openshift/client-go/operator/listers/operator/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type dNSInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewDNSInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredDNSInformer(client, resyncPeriod, indexers, nil)
+ return NewDNSInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredDNSInformer constructs a new informer for DNS type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredDNSInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewDNSInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewDNSInformerWithOptions constructs a new informer for DNS type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewDNSInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1", Resource: "dnss"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().DNSes().List(context.Background(), options)
+ return client.OperatorV1().DNSes().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().DNSes().Watch(context.Background(), options)
+ return client.OperatorV1().DNSes().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().DNSes().List(ctx, options)
+ return client.OperatorV1().DNSes().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().DNSes().Watch(ctx, options)
+ return client.OperatorV1().DNSes().Watch(ctx, opts)
},
}, client),
&apioperatorv1.DNS{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *dNSInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredDNSInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewDNSInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *dNSInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/etcd.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/etcd.go
index d68ca3a1b5..b8481922ef 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/etcd.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/etcd.go
@@ -12,6 +12,7 @@ import (
operatorv1 "github.com/openshift/client-go/operator/listers/operator/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type etcdInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewEtcdInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredEtcdInformer(client, resyncPeriod, indexers, nil)
+ return NewEtcdInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredEtcdInformer constructs a new informer for Etcd type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredEtcdInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewEtcdInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewEtcdInformerWithOptions constructs a new informer for Etcd type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewEtcdInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1", Resource: "etcds"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().Etcds().List(context.Background(), options)
+ return client.OperatorV1().Etcds().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().Etcds().Watch(context.Background(), options)
+ return client.OperatorV1().Etcds().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().Etcds().List(ctx, options)
+ return client.OperatorV1().Etcds().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().Etcds().Watch(ctx, options)
+ return client.OperatorV1().Etcds().Watch(ctx, opts)
},
}, client),
&apioperatorv1.Etcd{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *etcdInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredEtcdInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewEtcdInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *etcdInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/ingresscontroller.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/ingresscontroller.go
index 4fc4b106ac..423907ea46 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/ingresscontroller.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/ingresscontroller.go
@@ -12,6 +12,7 @@ import (
operatorv1 "github.com/openshift/client-go/operator/listers/operator/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -33,48 +34,61 @@ type ingressControllerInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewIngressControllerInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredIngressControllerInformer(client, namespace, resyncPeriod, indexers, nil)
+ return NewIngressControllerInformerWithOptions(client, namespace, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredIngressControllerInformer constructs a new informer for IngressController type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredIngressControllerInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewIngressControllerInformerWithOptions(client, namespace, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewIngressControllerInformerWithOptions constructs a new informer for IngressController type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewIngressControllerInformerWithOptions(client versioned.Interface, namespace string, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1", Resource: "ingresscontrollers"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().IngressControllers(namespace).List(context.Background(), options)
+ return client.OperatorV1().IngressControllers(namespace).List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().IngressControllers(namespace).Watch(context.Background(), options)
+ return client.OperatorV1().IngressControllers(namespace).Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().IngressControllers(namespace).List(ctx, options)
+ return client.OperatorV1().IngressControllers(namespace).List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().IngressControllers(namespace).Watch(ctx, options)
+ return client.OperatorV1().IngressControllers(namespace).Watch(ctx, opts)
},
}, client),
&apioperatorv1.IngressController{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *ingressControllerInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredIngressControllerInformer(client, f.namespace, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewIngressControllerInformerWithOptions(client, f.namespace, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *ingressControllerInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/insightsoperator.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/insightsoperator.go
index c3a0fa480d..b7fb76bf19 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/insightsoperator.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/insightsoperator.go
@@ -12,6 +12,7 @@ import (
operatorv1 "github.com/openshift/client-go/operator/listers/operator/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type insightsOperatorInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewInsightsOperatorInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredInsightsOperatorInformer(client, resyncPeriod, indexers, nil)
+ return NewInsightsOperatorInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredInsightsOperatorInformer constructs a new informer for InsightsOperator type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredInsightsOperatorInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewInsightsOperatorInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewInsightsOperatorInformerWithOptions constructs a new informer for InsightsOperator type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewInsightsOperatorInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1", Resource: "insightsoperators"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().InsightsOperators().List(context.Background(), options)
+ return client.OperatorV1().InsightsOperators().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().InsightsOperators().Watch(context.Background(), options)
+ return client.OperatorV1().InsightsOperators().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().InsightsOperators().List(ctx, options)
+ return client.OperatorV1().InsightsOperators().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().InsightsOperators().Watch(ctx, options)
+ return client.OperatorV1().InsightsOperators().Watch(ctx, opts)
},
}, client),
&apioperatorv1.InsightsOperator{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *insightsOperatorInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredInsightsOperatorInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewInsightsOperatorInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *insightsOperatorInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/kubeapiserver.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/kubeapiserver.go
index 07991798e1..3c2ec8a91b 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/kubeapiserver.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/kubeapiserver.go
@@ -12,6 +12,7 @@ import (
operatorv1 "github.com/openshift/client-go/operator/listers/operator/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type kubeAPIServerInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewKubeAPIServerInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredKubeAPIServerInformer(client, resyncPeriod, indexers, nil)
+ return NewKubeAPIServerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredKubeAPIServerInformer constructs a new informer for KubeAPIServer type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredKubeAPIServerInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewKubeAPIServerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewKubeAPIServerInformerWithOptions constructs a new informer for KubeAPIServer type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewKubeAPIServerInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1", Resource: "kubeapiservers"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().KubeAPIServers().List(context.Background(), options)
+ return client.OperatorV1().KubeAPIServers().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().KubeAPIServers().Watch(context.Background(), options)
+ return client.OperatorV1().KubeAPIServers().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().KubeAPIServers().List(ctx, options)
+ return client.OperatorV1().KubeAPIServers().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().KubeAPIServers().Watch(ctx, options)
+ return client.OperatorV1().KubeAPIServers().Watch(ctx, opts)
},
}, client),
&apioperatorv1.KubeAPIServer{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *kubeAPIServerInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredKubeAPIServerInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewKubeAPIServerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *kubeAPIServerInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/kubecontrollermanager.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/kubecontrollermanager.go
index d876f60c5d..b872d2cb00 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/kubecontrollermanager.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/kubecontrollermanager.go
@@ -12,6 +12,7 @@ import (
operatorv1 "github.com/openshift/client-go/operator/listers/operator/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type kubeControllerManagerInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewKubeControllerManagerInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredKubeControllerManagerInformer(client, resyncPeriod, indexers, nil)
+ return NewKubeControllerManagerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredKubeControllerManagerInformer constructs a new informer for KubeControllerManager type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredKubeControllerManagerInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewKubeControllerManagerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewKubeControllerManagerInformerWithOptions constructs a new informer for KubeControllerManager type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewKubeControllerManagerInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1", Resource: "kubecontrollermanagers"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().KubeControllerManagers().List(context.Background(), options)
+ return client.OperatorV1().KubeControllerManagers().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().KubeControllerManagers().Watch(context.Background(), options)
+ return client.OperatorV1().KubeControllerManagers().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().KubeControllerManagers().List(ctx, options)
+ return client.OperatorV1().KubeControllerManagers().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().KubeControllerManagers().Watch(ctx, options)
+ return client.OperatorV1().KubeControllerManagers().Watch(ctx, opts)
},
}, client),
&apioperatorv1.KubeControllerManager{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *kubeControllerManagerInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredKubeControllerManagerInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewKubeControllerManagerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *kubeControllerManagerInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/kubescheduler.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/kubescheduler.go
index f8a455a175..a882c19c07 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/kubescheduler.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/kubescheduler.go
@@ -12,6 +12,7 @@ import (
operatorv1 "github.com/openshift/client-go/operator/listers/operator/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type kubeSchedulerInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewKubeSchedulerInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredKubeSchedulerInformer(client, resyncPeriod, indexers, nil)
+ return NewKubeSchedulerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredKubeSchedulerInformer constructs a new informer for KubeScheduler type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredKubeSchedulerInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewKubeSchedulerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewKubeSchedulerInformerWithOptions constructs a new informer for KubeScheduler type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewKubeSchedulerInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1", Resource: "kubeschedulers"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().KubeSchedulers().List(context.Background(), options)
+ return client.OperatorV1().KubeSchedulers().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().KubeSchedulers().Watch(context.Background(), options)
+ return client.OperatorV1().KubeSchedulers().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().KubeSchedulers().List(ctx, options)
+ return client.OperatorV1().KubeSchedulers().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().KubeSchedulers().Watch(ctx, options)
+ return client.OperatorV1().KubeSchedulers().Watch(ctx, opts)
},
}, client),
&apioperatorv1.KubeScheduler{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *kubeSchedulerInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredKubeSchedulerInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewKubeSchedulerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *kubeSchedulerInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/kubestorageversionmigrator.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/kubestorageversionmigrator.go
index fdd3b27a8e..55b40f7494 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/kubestorageversionmigrator.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/kubestorageversionmigrator.go
@@ -12,6 +12,7 @@ import (
operatorv1 "github.com/openshift/client-go/operator/listers/operator/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type kubeStorageVersionMigratorInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewKubeStorageVersionMigratorInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredKubeStorageVersionMigratorInformer(client, resyncPeriod, indexers, nil)
+ return NewKubeStorageVersionMigratorInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredKubeStorageVersionMigratorInformer constructs a new informer for KubeStorageVersionMigrator type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredKubeStorageVersionMigratorInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewKubeStorageVersionMigratorInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewKubeStorageVersionMigratorInformerWithOptions constructs a new informer for KubeStorageVersionMigrator type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewKubeStorageVersionMigratorInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1", Resource: "kubestorageversionmigrators"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().KubeStorageVersionMigrators().List(context.Background(), options)
+ return client.OperatorV1().KubeStorageVersionMigrators().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().KubeStorageVersionMigrators().Watch(context.Background(), options)
+ return client.OperatorV1().KubeStorageVersionMigrators().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().KubeStorageVersionMigrators().List(ctx, options)
+ return client.OperatorV1().KubeStorageVersionMigrators().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().KubeStorageVersionMigrators().Watch(ctx, options)
+ return client.OperatorV1().KubeStorageVersionMigrators().Watch(ctx, opts)
},
}, client),
&apioperatorv1.KubeStorageVersionMigrator{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *kubeStorageVersionMigratorInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredKubeStorageVersionMigratorInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewKubeStorageVersionMigratorInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *kubeStorageVersionMigratorInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/machineconfiguration.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/machineconfiguration.go
index a88cdc8dd0..3895f81327 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/machineconfiguration.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/machineconfiguration.go
@@ -12,6 +12,7 @@ import (
operatorv1 "github.com/openshift/client-go/operator/listers/operator/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type machineConfigurationInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewMachineConfigurationInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredMachineConfigurationInformer(client, resyncPeriod, indexers, nil)
+ return NewMachineConfigurationInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredMachineConfigurationInformer constructs a new informer for MachineConfiguration type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredMachineConfigurationInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewMachineConfigurationInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewMachineConfigurationInformerWithOptions constructs a new informer for MachineConfiguration type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewMachineConfigurationInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1", Resource: "machineconfigurations"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().MachineConfigurations().List(context.Background(), options)
+ return client.OperatorV1().MachineConfigurations().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().MachineConfigurations().Watch(context.Background(), options)
+ return client.OperatorV1().MachineConfigurations().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().MachineConfigurations().List(ctx, options)
+ return client.OperatorV1().MachineConfigurations().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().MachineConfigurations().Watch(ctx, options)
+ return client.OperatorV1().MachineConfigurations().Watch(ctx, opts)
},
}, client),
&apioperatorv1.MachineConfiguration{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *machineConfigurationInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredMachineConfigurationInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewMachineConfigurationInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *machineConfigurationInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/network.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/network.go
index a076e969ac..d26b9e2e5b 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/network.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/network.go
@@ -12,6 +12,7 @@ import (
operatorv1 "github.com/openshift/client-go/operator/listers/operator/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type networkInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewNetworkInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredNetworkInformer(client, resyncPeriod, indexers, nil)
+ return NewNetworkInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredNetworkInformer constructs a new informer for Network type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredNetworkInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewNetworkInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewNetworkInformerWithOptions constructs a new informer for Network type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewNetworkInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1", Resource: "networks"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().Networks().List(context.Background(), options)
+ return client.OperatorV1().Networks().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().Networks().Watch(context.Background(), options)
+ return client.OperatorV1().Networks().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().Networks().List(ctx, options)
+ return client.OperatorV1().Networks().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().Networks().Watch(ctx, options)
+ return client.OperatorV1().Networks().Watch(ctx, opts)
},
}, client),
&apioperatorv1.Network{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *networkInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredNetworkInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewNetworkInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *networkInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/olm.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/olm.go
index 0e3ab4c07f..ad2a46c083 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/olm.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/olm.go
@@ -12,6 +12,7 @@ import (
operatorv1 "github.com/openshift/client-go/operator/listers/operator/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type oLMInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewOLMInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredOLMInformer(client, resyncPeriod, indexers, nil)
+ return NewOLMInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredOLMInformer constructs a new informer for OLM type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredOLMInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewOLMInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewOLMInformerWithOptions constructs a new informer for OLM type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewOLMInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1", Resource: "olms"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().OLMs().List(context.Background(), options)
+ return client.OperatorV1().OLMs().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().OLMs().Watch(context.Background(), options)
+ return client.OperatorV1().OLMs().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().OLMs().List(ctx, options)
+ return client.OperatorV1().OLMs().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().OLMs().Watch(ctx, options)
+ return client.OperatorV1().OLMs().Watch(ctx, opts)
},
}, client),
&apioperatorv1.OLM{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *oLMInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredOLMInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewOLMInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *oLMInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/openshiftapiserver.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/openshiftapiserver.go
index 00d95d1ff5..e87994a048 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/openshiftapiserver.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/openshiftapiserver.go
@@ -12,6 +12,7 @@ import (
operatorv1 "github.com/openshift/client-go/operator/listers/operator/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type openShiftAPIServerInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewOpenShiftAPIServerInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredOpenShiftAPIServerInformer(client, resyncPeriod, indexers, nil)
+ return NewOpenShiftAPIServerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredOpenShiftAPIServerInformer constructs a new informer for OpenShiftAPIServer type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredOpenShiftAPIServerInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewOpenShiftAPIServerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewOpenShiftAPIServerInformerWithOptions constructs a new informer for OpenShiftAPIServer type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewOpenShiftAPIServerInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1", Resource: "openshiftapiservers"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().OpenShiftAPIServers().List(context.Background(), options)
+ return client.OperatorV1().OpenShiftAPIServers().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().OpenShiftAPIServers().Watch(context.Background(), options)
+ return client.OperatorV1().OpenShiftAPIServers().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().OpenShiftAPIServers().List(ctx, options)
+ return client.OperatorV1().OpenShiftAPIServers().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().OpenShiftAPIServers().Watch(ctx, options)
+ return client.OperatorV1().OpenShiftAPIServers().Watch(ctx, opts)
},
}, client),
&apioperatorv1.OpenShiftAPIServer{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *openShiftAPIServerInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredOpenShiftAPIServerInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewOpenShiftAPIServerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *openShiftAPIServerInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/openshiftcontrollermanager.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/openshiftcontrollermanager.go
index f94c4e7d1b..6d6221764e 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/openshiftcontrollermanager.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/openshiftcontrollermanager.go
@@ -12,6 +12,7 @@ import (
operatorv1 "github.com/openshift/client-go/operator/listers/operator/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type openShiftControllerManagerInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewOpenShiftControllerManagerInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredOpenShiftControllerManagerInformer(client, resyncPeriod, indexers, nil)
+ return NewOpenShiftControllerManagerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredOpenShiftControllerManagerInformer constructs a new informer for OpenShiftControllerManager type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredOpenShiftControllerManagerInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewOpenShiftControllerManagerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewOpenShiftControllerManagerInformerWithOptions constructs a new informer for OpenShiftControllerManager type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewOpenShiftControllerManagerInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1", Resource: "openshiftcontrollermanagers"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().OpenShiftControllerManagers().List(context.Background(), options)
+ return client.OperatorV1().OpenShiftControllerManagers().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().OpenShiftControllerManagers().Watch(context.Background(), options)
+ return client.OperatorV1().OpenShiftControllerManagers().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().OpenShiftControllerManagers().List(ctx, options)
+ return client.OperatorV1().OpenShiftControllerManagers().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().OpenShiftControllerManagers().Watch(ctx, options)
+ return client.OperatorV1().OpenShiftControllerManagers().Watch(ctx, opts)
},
}, client),
&apioperatorv1.OpenShiftControllerManager{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *openShiftControllerManagerInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredOpenShiftControllerManagerInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewOpenShiftControllerManagerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *openShiftControllerManagerInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/serviceca.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/serviceca.go
index e3f8870298..bd11c17ba4 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/serviceca.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/serviceca.go
@@ -12,6 +12,7 @@ import (
operatorv1 "github.com/openshift/client-go/operator/listers/operator/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type serviceCAInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewServiceCAInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredServiceCAInformer(client, resyncPeriod, indexers, nil)
+ return NewServiceCAInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredServiceCAInformer constructs a new informer for ServiceCA type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredServiceCAInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewServiceCAInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewServiceCAInformerWithOptions constructs a new informer for ServiceCA type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewServiceCAInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1", Resource: "servicecas"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().ServiceCAs().List(context.Background(), options)
+ return client.OperatorV1().ServiceCAs().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().ServiceCAs().Watch(context.Background(), options)
+ return client.OperatorV1().ServiceCAs().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().ServiceCAs().List(ctx, options)
+ return client.OperatorV1().ServiceCAs().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().ServiceCAs().Watch(ctx, options)
+ return client.OperatorV1().ServiceCAs().Watch(ctx, opts)
},
}, client),
&apioperatorv1.ServiceCA{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *serviceCAInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredServiceCAInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewServiceCAInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *serviceCAInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/servicecatalogapiserver.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/servicecatalogapiserver.go
index 98b0722d48..b99cbca68f 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/servicecatalogapiserver.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/servicecatalogapiserver.go
@@ -12,6 +12,7 @@ import (
operatorv1 "github.com/openshift/client-go/operator/listers/operator/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type serviceCatalogAPIServerInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewServiceCatalogAPIServerInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredServiceCatalogAPIServerInformer(client, resyncPeriod, indexers, nil)
+ return NewServiceCatalogAPIServerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredServiceCatalogAPIServerInformer constructs a new informer for ServiceCatalogAPIServer type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredServiceCatalogAPIServerInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewServiceCatalogAPIServerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewServiceCatalogAPIServerInformerWithOptions constructs a new informer for ServiceCatalogAPIServer type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewServiceCatalogAPIServerInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1", Resource: "servicecatalogapiservers"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().ServiceCatalogAPIServers().List(context.Background(), options)
+ return client.OperatorV1().ServiceCatalogAPIServers().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().ServiceCatalogAPIServers().Watch(context.Background(), options)
+ return client.OperatorV1().ServiceCatalogAPIServers().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().ServiceCatalogAPIServers().List(ctx, options)
+ return client.OperatorV1().ServiceCatalogAPIServers().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().ServiceCatalogAPIServers().Watch(ctx, options)
+ return client.OperatorV1().ServiceCatalogAPIServers().Watch(ctx, opts)
},
}, client),
&apioperatorv1.ServiceCatalogAPIServer{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *serviceCatalogAPIServerInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredServiceCatalogAPIServerInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewServiceCatalogAPIServerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *serviceCatalogAPIServerInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/servicecatalogcontrollermanager.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/servicecatalogcontrollermanager.go
index a80ad9c33c..049e099f75 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/servicecatalogcontrollermanager.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/servicecatalogcontrollermanager.go
@@ -12,6 +12,7 @@ import (
operatorv1 "github.com/openshift/client-go/operator/listers/operator/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type serviceCatalogControllerManagerInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewServiceCatalogControllerManagerInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredServiceCatalogControllerManagerInformer(client, resyncPeriod, indexers, nil)
+ return NewServiceCatalogControllerManagerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredServiceCatalogControllerManagerInformer constructs a new informer for ServiceCatalogControllerManager type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredServiceCatalogControllerManagerInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewServiceCatalogControllerManagerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewServiceCatalogControllerManagerInformerWithOptions constructs a new informer for ServiceCatalogControllerManager type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewServiceCatalogControllerManagerInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1", Resource: "servicecatalogcontrollermanagers"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().ServiceCatalogControllerManagers().List(context.Background(), options)
+ return client.OperatorV1().ServiceCatalogControllerManagers().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().ServiceCatalogControllerManagers().Watch(context.Background(), options)
+ return client.OperatorV1().ServiceCatalogControllerManagers().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().ServiceCatalogControllerManagers().List(ctx, options)
+ return client.OperatorV1().ServiceCatalogControllerManagers().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().ServiceCatalogControllerManagers().Watch(ctx, options)
+ return client.OperatorV1().ServiceCatalogControllerManagers().Watch(ctx, opts)
},
}, client),
&apioperatorv1.ServiceCatalogControllerManager{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *serviceCatalogControllerManagerInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredServiceCatalogControllerManagerInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewServiceCatalogControllerManagerInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *serviceCatalogControllerManagerInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/storage.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/storage.go
index 570fb4ebca..f11dc38096 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/storage.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1/storage.go
@@ -12,6 +12,7 @@ import (
operatorv1 "github.com/openshift/client-go/operator/listers/operator/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type storageInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewStorageInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredStorageInformer(client, resyncPeriod, indexers, nil)
+ return NewStorageInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredStorageInformer constructs a new informer for Storage type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredStorageInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewStorageInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewStorageInformerWithOptions constructs a new informer for Storage type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewStorageInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1", Resource: "storages"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().Storages().List(context.Background(), options)
+ return client.OperatorV1().Storages().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().Storages().Watch(context.Background(), options)
+ return client.OperatorV1().Storages().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().Storages().List(ctx, options)
+ return client.OperatorV1().Storages().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1().Storages().Watch(ctx, options)
+ return client.OperatorV1().Storages().Watch(ctx, opts)
},
}, client),
&apioperatorv1.Storage{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *storageInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredStorageInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewStorageInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *storageInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1alpha1/clusterapi.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1alpha1/clusterapi.go
index 2b61949c1b..b5accc851d 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1alpha1/clusterapi.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1alpha1/clusterapi.go
@@ -12,6 +12,7 @@ import (
operatorv1alpha1 "github.com/openshift/client-go/operator/listers/operator/v1alpha1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type clusterAPIInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewClusterAPIInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredClusterAPIInformer(client, resyncPeriod, indexers, nil)
+ return NewClusterAPIInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredClusterAPIInformer constructs a new informer for ClusterAPI type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredClusterAPIInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewClusterAPIInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewClusterAPIInformerWithOptions constructs a new informer for ClusterAPI type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewClusterAPIInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1alpha1", Resource: "clusterapis"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options v1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts v1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1alpha1().ClusterAPIs().List(context.Background(), options)
+ return client.OperatorV1alpha1().ClusterAPIs().List(context.Background(), opts)
},
- WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts v1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1alpha1().ClusterAPIs().Watch(context.Background(), options)
+ return client.OperatorV1alpha1().ClusterAPIs().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options v1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts v1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1alpha1().ClusterAPIs().List(ctx, options)
+ return client.OperatorV1alpha1().ClusterAPIs().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options v1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1alpha1().ClusterAPIs().Watch(ctx, options)
+ return client.OperatorV1alpha1().ClusterAPIs().Watch(ctx, opts)
},
}, client),
&apioperatorv1alpha1.ClusterAPI{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *clusterAPIInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredClusterAPIInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewClusterAPIInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *clusterAPIInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1alpha1/clusterversionoperator.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1alpha1/clusterversionoperator.go
index 001b92c885..19b14b84fa 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1alpha1/clusterversionoperator.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1alpha1/clusterversionoperator.go
@@ -12,6 +12,7 @@ import (
operatorv1alpha1 "github.com/openshift/client-go/operator/listers/operator/v1alpha1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type clusterVersionOperatorInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewClusterVersionOperatorInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredClusterVersionOperatorInformer(client, resyncPeriod, indexers, nil)
+ return NewClusterVersionOperatorInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredClusterVersionOperatorInformer constructs a new informer for ClusterVersionOperator type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredClusterVersionOperatorInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewClusterVersionOperatorInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewClusterVersionOperatorInformerWithOptions constructs a new informer for ClusterVersionOperator type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewClusterVersionOperatorInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1alpha1", Resource: "clusterversionoperators"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options v1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts v1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1alpha1().ClusterVersionOperators().List(context.Background(), options)
+ return client.OperatorV1alpha1().ClusterVersionOperators().List(context.Background(), opts)
},
- WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts v1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1alpha1().ClusterVersionOperators().Watch(context.Background(), options)
+ return client.OperatorV1alpha1().ClusterVersionOperators().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options v1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts v1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1alpha1().ClusterVersionOperators().List(ctx, options)
+ return client.OperatorV1alpha1().ClusterVersionOperators().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options v1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1alpha1().ClusterVersionOperators().Watch(ctx, options)
+ return client.OperatorV1alpha1().ClusterVersionOperators().Watch(ctx, opts)
},
}, client),
&apioperatorv1alpha1.ClusterVersionOperator{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *clusterVersionOperatorInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredClusterVersionOperatorInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewClusterVersionOperatorInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *clusterVersionOperatorInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1alpha1/etcdbackup.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1alpha1/etcdbackup.go
index d7094f67d8..3a00de22eb 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1alpha1/etcdbackup.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1alpha1/etcdbackup.go
@@ -12,6 +12,7 @@ import (
operatorv1alpha1 "github.com/openshift/client-go/operator/listers/operator/v1alpha1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type etcdBackupInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewEtcdBackupInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredEtcdBackupInformer(client, resyncPeriod, indexers, nil)
+ return NewEtcdBackupInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredEtcdBackupInformer constructs a new informer for EtcdBackup type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredEtcdBackupInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewEtcdBackupInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewEtcdBackupInformerWithOptions constructs a new informer for EtcdBackup type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewEtcdBackupInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1alpha1", Resource: "etcdbackups"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options v1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts v1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1alpha1().EtcdBackups().List(context.Background(), options)
+ return client.OperatorV1alpha1().EtcdBackups().List(context.Background(), opts)
},
- WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts v1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1alpha1().EtcdBackups().Watch(context.Background(), options)
+ return client.OperatorV1alpha1().EtcdBackups().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options v1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts v1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1alpha1().EtcdBackups().List(ctx, options)
+ return client.OperatorV1alpha1().EtcdBackups().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options v1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1alpha1().EtcdBackups().Watch(ctx, options)
+ return client.OperatorV1alpha1().EtcdBackups().Watch(ctx, opts)
},
}, client),
&apioperatorv1alpha1.EtcdBackup{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *etcdBackupInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredEtcdBackupInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewEtcdBackupInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *etcdBackupInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1alpha1/imagecontentsourcepolicy.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1alpha1/imagecontentsourcepolicy.go
index ccdac78ab9..d3d89018bc 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1alpha1/imagecontentsourcepolicy.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1alpha1/imagecontentsourcepolicy.go
@@ -12,6 +12,7 @@ import (
operatorv1alpha1 "github.com/openshift/client-go/operator/listers/operator/v1alpha1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type imageContentSourcePolicyInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewImageContentSourcePolicyInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredImageContentSourcePolicyInformer(client, resyncPeriod, indexers, nil)
+ return NewImageContentSourcePolicyInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredImageContentSourcePolicyInformer constructs a new informer for ImageContentSourcePolicy type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredImageContentSourcePolicyInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewImageContentSourcePolicyInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewImageContentSourcePolicyInformerWithOptions constructs a new informer for ImageContentSourcePolicy type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewImageContentSourcePolicyInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1alpha1", Resource: "imagecontentsourcepolicys"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options v1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts v1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1alpha1().ImageContentSourcePolicies().List(context.Background(), options)
+ return client.OperatorV1alpha1().ImageContentSourcePolicies().List(context.Background(), opts)
},
- WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts v1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1alpha1().ImageContentSourcePolicies().Watch(context.Background(), options)
+ return client.OperatorV1alpha1().ImageContentSourcePolicies().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options v1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts v1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1alpha1().ImageContentSourcePolicies().List(ctx, options)
+ return client.OperatorV1alpha1().ImageContentSourcePolicies().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options v1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1alpha1().ImageContentSourcePolicies().Watch(ctx, options)
+ return client.OperatorV1alpha1().ImageContentSourcePolicies().Watch(ctx, opts)
},
}, client),
&apioperatorv1alpha1.ImageContentSourcePolicy{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *imageContentSourcePolicyInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredImageContentSourcePolicyInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewImageContentSourcePolicyInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *imageContentSourcePolicyInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1alpha1/ingress.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1alpha1/ingress.go
new file mode 100644
index 0000000000..6f132ffcaa
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1alpha1/ingress.go
@@ -0,0 +1,99 @@
+// Code generated by informer-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ context "context"
+ time "time"
+
+ apioperatorv1alpha1 "github.com/openshift/api/operator/v1alpha1"
+ versioned "github.com/openshift/client-go/operator/clientset/versioned"
+ internalinterfaces "github.com/openshift/client-go/operator/informers/externalversions/internalinterfaces"
+ operatorv1alpha1 "github.com/openshift/client-go/operator/listers/operator/v1alpha1"
+ v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
+ runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
+ watch "k8s.io/apimachinery/pkg/watch"
+ cache "k8s.io/client-go/tools/cache"
+)
+
+// IngressInformer provides access to a shared informer and lister for
+// Ingresses.
+type IngressInformer interface {
+ Informer() cache.SharedIndexInformer
+ Lister() operatorv1alpha1.IngressLister
+}
+
+type ingressInformer struct {
+ factory internalinterfaces.SharedInformerFactory
+ tweakListOptions internalinterfaces.TweakListOptionsFunc
+}
+
+// NewIngressInformer constructs a new informer for Ingress type.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewIngressInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
+ return NewIngressInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
+}
+
+// NewFilteredIngressInformer constructs a new informer for Ingress type.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewFilteredIngressInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
+ return NewIngressInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewIngressInformerWithOptions constructs a new informer for Ingress type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewIngressInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1alpha1", Resource: "ingresss"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
+ cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
+ ListFunc: func(opts v1.ListOptions) (runtime.Object, error) {
+ if tweakListOptions != nil {
+ tweakListOptions(&opts)
+ }
+ return client.OperatorV1alpha1().Ingresses().List(context.Background(), opts)
+ },
+ WatchFunc: func(opts v1.ListOptions) (watch.Interface, error) {
+ if tweakListOptions != nil {
+ tweakListOptions(&opts)
+ }
+ return client.OperatorV1alpha1().Ingresses().Watch(context.Background(), opts)
+ },
+ ListWithContextFunc: func(ctx context.Context, opts v1.ListOptions) (runtime.Object, error) {
+ if tweakListOptions != nil {
+ tweakListOptions(&opts)
+ }
+ return client.OperatorV1alpha1().Ingresses().List(ctx, opts)
+ },
+ WatchFuncWithContext: func(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
+ if tweakListOptions != nil {
+ tweakListOptions(&opts)
+ }
+ return client.OperatorV1alpha1().Ingresses().Watch(ctx, opts)
+ },
+ }, client),
+ &apioperatorv1alpha1.Ingress{},
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
+ )
+}
+
+func (f *ingressInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
+ return NewIngressInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
+}
+
+func (f *ingressInformer) Informer() cache.SharedIndexInformer {
+ return f.factory.InformerFor(&apioperatorv1alpha1.Ingress{}, f.defaultInformer)
+}
+
+func (f *ingressInformer) Lister() operatorv1alpha1.IngressLister {
+ return operatorv1alpha1.NewIngressLister(f.Informer().GetIndexer())
+}
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1alpha1/interface.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1alpha1/interface.go
index cff20e8060..8377b34a6c 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1alpha1/interface.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1alpha1/interface.go
@@ -16,6 +16,8 @@ type Interface interface {
EtcdBackups() EtcdBackupInformer
// ImageContentSourcePolicies returns a ImageContentSourcePolicyInformer.
ImageContentSourcePolicies() ImageContentSourcePolicyInformer
+ // Ingresses returns a IngressInformer.
+ Ingresses() IngressInformer
// OLMs returns a OLMInformer.
OLMs() OLMInformer
}
@@ -51,6 +53,11 @@ func (v *version) ImageContentSourcePolicies() ImageContentSourcePolicyInformer
return &imageContentSourcePolicyInformer{factory: v.factory, tweakListOptions: v.tweakListOptions}
}
+// Ingresses returns a IngressInformer.
+func (v *version) Ingresses() IngressInformer {
+ return &ingressInformer{factory: v.factory, tweakListOptions: v.tweakListOptions}
+}
+
// OLMs returns a OLMInformer.
func (v *version) OLMs() OLMInformer {
return &oLMInformer{factory: v.factory, tweakListOptions: v.tweakListOptions}
diff --git a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1alpha1/olm.go b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1alpha1/olm.go
index 2c4da12db0..cb4a0cb01f 100644
--- a/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1alpha1/olm.go
+++ b/vendor/github.com/openshift/client-go/operator/informers/externalversions/operator/v1alpha1/olm.go
@@ -12,6 +12,7 @@ import (
operatorv1alpha1 "github.com/openshift/client-go/operator/listers/operator/v1alpha1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type oLMInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewOLMInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredOLMInformer(client, resyncPeriod, indexers, nil)
+ return NewOLMInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredOLMInformer constructs a new informer for OLM type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredOLMInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewOLMInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewOLMInformerWithOptions constructs a new informer for OLM type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewOLMInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1alpha1", Resource: "olms"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options v1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts v1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1alpha1().OLMs().List(context.Background(), options)
+ return client.OperatorV1alpha1().OLMs().List(context.Background(), opts)
},
- WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts v1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1alpha1().OLMs().Watch(context.Background(), options)
+ return client.OperatorV1alpha1().OLMs().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options v1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts v1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1alpha1().OLMs().List(ctx, options)
+ return client.OperatorV1alpha1().OLMs().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options v1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.OperatorV1alpha1().OLMs().Watch(ctx, options)
+ return client.OperatorV1alpha1().OLMs().Watch(ctx, opts)
},
}, client),
&apioperatorv1alpha1.OLM{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *oLMInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredOLMInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewOLMInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *oLMInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/operator/listers/operator/v1alpha1/expansion_generated.go b/vendor/github.com/openshift/client-go/operator/listers/operator/v1alpha1/expansion_generated.go
index 5380503733..a1e4d6e3e8 100644
--- a/vendor/github.com/openshift/client-go/operator/listers/operator/v1alpha1/expansion_generated.go
+++ b/vendor/github.com/openshift/client-go/operator/listers/operator/v1alpha1/expansion_generated.go
@@ -18,6 +18,10 @@ type EtcdBackupListerExpansion interface{}
// ImageContentSourcePolicyLister.
type ImageContentSourcePolicyListerExpansion interface{}
+// IngressListerExpansion allows custom methods to be added to
+// IngressLister.
+type IngressListerExpansion interface{}
+
// OLMListerExpansion allows custom methods to be added to
// OLMLister.
type OLMListerExpansion interface{}
diff --git a/vendor/github.com/openshift/client-go/operator/listers/operator/v1alpha1/ingress.go b/vendor/github.com/openshift/client-go/operator/listers/operator/v1alpha1/ingress.go
new file mode 100644
index 0000000000..5c5527a0df
--- /dev/null
+++ b/vendor/github.com/openshift/client-go/operator/listers/operator/v1alpha1/ingress.go
@@ -0,0 +1,32 @@
+// Code generated by lister-gen. DO NOT EDIT.
+
+package v1alpha1
+
+import (
+ operatorv1alpha1 "github.com/openshift/api/operator/v1alpha1"
+ labels "k8s.io/apimachinery/pkg/labels"
+ listers "k8s.io/client-go/listers"
+ cache "k8s.io/client-go/tools/cache"
+)
+
+// IngressLister helps list Ingresses.
+// All objects returned here must be treated as read-only.
+type IngressLister interface {
+ // List lists all Ingresses in the indexer.
+ // Objects returned here must be treated as read-only.
+ List(selector labels.Selector) (ret []*operatorv1alpha1.Ingress, err error)
+ // Get retrieves the Ingress from the index for a given name.
+ // Objects returned here must be treated as read-only.
+ Get(name string) (*operatorv1alpha1.Ingress, error)
+ IngressListerExpansion
+}
+
+// ingressLister implements the IngressLister interface.
+type ingressLister struct {
+ listers.ResourceIndexer[*operatorv1alpha1.Ingress]
+}
+
+// NewIngressLister returns a new IngressLister.
+func NewIngressLister(indexer cache.Indexer) IngressLister {
+ return &ingressLister{listers.New[*operatorv1alpha1.Ingress](indexer, operatorv1alpha1.Resource("ingress"))}
+}
diff --git a/vendor/github.com/openshift/client-go/security/applyconfigurations/security/v1/securitycontextconstraints.go b/vendor/github.com/openshift/client-go/security/applyconfigurations/security/v1/securitycontextconstraints.go
index d2e392506f..b5bd21b51f 100644
--- a/vendor/github.com/openshift/client-go/security/applyconfigurations/security/v1/securitycontextconstraints.go
+++ b/vendor/github.com/openshift/client-go/security/applyconfigurations/security/v1/securitycontextconstraints.go
@@ -38,7 +38,7 @@ type SecurityContextConstraintsApplyConfiguration struct {
// allowPrivilegedContainer determines if a container can request to be run as privileged.
AllowPrivilegedContainer *bool `json:"allowPrivilegedContainer,omitempty"`
// defaultAddCapabilities is the default set of capabilities that will be added to the container
- // unless the pod spec specifically drops the capability. You may not list a capabiility in both
+ // unless the pod spec specifically drops the capability. You may not list a capability in both
// DefaultAddCapabilities and RequiredDropCapabilities.
DefaultAddCapabilities []corev1.Capability `json:"defaultAddCapabilities,omitempty"`
// requiredDropCapabilities are the capabilities that will be dropped from the container. These
@@ -99,7 +99,7 @@ type SecurityContextConstraintsApplyConfiguration struct {
Groups []string `json:"groups,omitempty"`
// seccompProfiles lists the allowed profiles that may be set for the pod or
// container's seccomp annotations. An unset (nil) or empty value means that no profiles may
- // be specifid by the pod or container. The wildcard '*' may be used to allow all profiles. When
+ // be specified by the pod or container. The wildcard '*' may be used to allow all profiles. When
// used to generate a value for a pod the first non-wildcard profile will be used as
// the default.
SeccompProfiles []string `json:"seccompProfiles,omitempty"`
diff --git a/vendor/github.com/openshift/client-go/template/clientset/versioned/fake/clientset_generated.go b/vendor/github.com/openshift/client-go/template/clientset/versioned/fake/clientset_generated.go
index 411b7208e1..e378c8e25a 100644
--- a/vendor/github.com/openshift/client-go/template/clientset/versioned/fake/clientset_generated.go
+++ b/vendor/github.com/openshift/client-go/template/clientset/versioned/fake/clientset_generated.go
@@ -19,10 +19,6 @@ import (
// It's backed by a very simple object tracker that processes creates, updates and deletions as-is,
// without applying any field management, validations and/or defaults. It shouldn't be considered a replacement
// for a real clientset and is mostly useful in simple unit tests.
-//
-// Deprecated: NewClientset replaces this with support for field management, which significantly improves
-// server side apply testing. NewClientset is only available when apply configurations are generated (e.g.
-// via --with-applyconfig).
func NewSimpleClientset(objects ...runtime.Object) *Clientset {
o := testing.NewObjectTracker(scheme, codecs.UniversalDecoder())
for _, obj := range objects {
@@ -68,7 +64,7 @@ func (c *Clientset) Tracker() testing.ObjectTracker {
return c.tracker
}
-// IsWatchListSemanticsSupported informs the reflector that this client
+// IsWatchListSemanticsUnSupported informs the reflector that this client
// doesn't support WatchList semantics.
//
// This is a synthetic method whose sole purpose is to satisfy the optional
@@ -83,6 +79,10 @@ func (c *Clientset) IsWatchListSemanticsUnSupported() bool {
// It's backed by a very simple object tracker that processes creates, updates and deletions as-is,
// without applying any validations and/or defaults. It shouldn't be considered a replacement
// for a real clientset and is mostly useful in simple unit tests.
+//
+// Compared to NewSimpleClientset, the Clientset returned here supports field tracking and thus
+// server-side apply. Beware though that support in that for CRDs is missing
+// (https://github.com/kubernetes/kubernetes/issues/126850).
func NewClientset(objects ...runtime.Object) *Clientset {
o := testing.NewFieldManagedObjectTracker(
scheme,
diff --git a/vendor/github.com/openshift/client-go/template/informers/externalversions/factory.go b/vendor/github.com/openshift/client-go/template/informers/externalversions/factory.go
index a257279d7d..a395304267 100644
--- a/vendor/github.com/openshift/client-go/template/informers/externalversions/factory.go
+++ b/vendor/github.com/openshift/client-go/template/informers/externalversions/factory.go
@@ -3,6 +3,7 @@
package externalversions
import (
+ context "context"
reflect "reflect"
sync "sync"
time "time"
@@ -13,6 +14,7 @@ import (
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
schema "k8s.io/apimachinery/pkg/runtime/schema"
+ wait "k8s.io/apimachinery/pkg/util/wait"
cache "k8s.io/client-go/tools/cache"
)
@@ -27,6 +29,7 @@ type sharedInformerFactory struct {
defaultResync time.Duration
customResync map[reflect.Type]time.Duration
transform cache.TransformFunc
+ informerName *cache.InformerName
informers map[reflect.Type]cache.SharedIndexInformer
// startedInformers is used for tracking which informers have been started.
@@ -73,6 +76,21 @@ func WithTransform(transform cache.TransformFunc) SharedInformerOption {
}
}
+// WithInformerName sets the InformerName for informer identity used in metrics.
+// The InformerName must be created via cache.NewInformerName() at startup,
+// which validates global uniqueness. Each informer type will register its
+// GVR under this name.
+func WithInformerName(informerName *cache.InformerName) SharedInformerOption {
+ return func(factory *sharedInformerFactory) *sharedInformerFactory {
+ factory.informerName = informerName
+ return factory
+ }
+}
+
+func (f *sharedInformerFactory) InformerName() *cache.InformerName {
+ return f.informerName
+}
+
// NewSharedInformerFactory constructs a new instance of sharedInformerFactory for all namespaces.
func NewSharedInformerFactory(client versioned.Interface, defaultResync time.Duration) SharedInformerFactory {
return NewSharedInformerFactoryWithOptions(client, defaultResync)
@@ -107,6 +125,10 @@ func NewSharedInformerFactoryWithOptions(client versioned.Interface, defaultResy
}
func (f *sharedInformerFactory) Start(stopCh <-chan struct{}) {
+ f.StartWithContext(wait.ContextForChannel(stopCh))
+}
+
+func (f *sharedInformerFactory) StartWithContext(ctx context.Context) {
f.lock.Lock()
defer f.lock.Unlock()
@@ -116,15 +138,9 @@ func (f *sharedInformerFactory) Start(stopCh <-chan struct{}) {
for informerType, informer := range f.informers {
if !f.startedInformers[informerType] {
- f.wg.Add(1)
- // We need a new variable in each loop iteration,
- // otherwise the goroutine would use the loop variable
- // and that keeps changing.
- informer := informer
- go func() {
- defer f.wg.Done()
- informer.Run(stopCh)
- }()
+ f.wg.Go(func() {
+ informer.RunWithContext(ctx)
+ })
f.startedInformers[informerType] = true
}
}
@@ -137,9 +153,15 @@ func (f *sharedInformerFactory) Shutdown() {
// Will return immediately if there is nothing to wait for.
f.wg.Wait()
+ f.informerName.Release()
}
func (f *sharedInformerFactory) WaitForCacheSync(stopCh <-chan struct{}) map[reflect.Type]bool {
+ result := f.WaitForCacheSyncWithContext(wait.ContextForChannel(stopCh))
+ return result.Synced
+}
+
+func (f *sharedInformerFactory) WaitForCacheSyncWithContext(ctx context.Context) cache.SyncResult {
informers := func() map[reflect.Type]cache.SharedIndexInformer {
f.lock.Lock()
defer f.lock.Unlock()
@@ -153,10 +175,31 @@ func (f *sharedInformerFactory) WaitForCacheSync(stopCh <-chan struct{}) map[ref
return informers
}()
- res := map[reflect.Type]bool{}
+ // Wait for informers to sync, without polling.
+ cacheSyncs := make([]cache.DoneChecker, 0, len(informers))
+ for _, informer := range informers {
+ cacheSyncs = append(cacheSyncs, informer.HasSyncedChecker())
+ }
+ cache.WaitFor(ctx, "" /* no logging */, cacheSyncs...)
+
+ res := cache.SyncResult{
+ Synced: make(map[reflect.Type]bool, len(informers)),
+ }
+ failed := false
for informType, informer := range informers {
- res[informType] = cache.WaitForCacheSync(stopCh, informer.HasSynced)
+ hasSynced := informer.HasSynced()
+ if !hasSynced {
+ failed = true
+ }
+ res.Synced[informType] = hasSynced
}
+ if failed {
+ // context.Cause is more informative than ctx.Err().
+ // This must be non-nil, otherwise WaitFor wouldn't have stopped
+ // prematurely.
+ res.Err = context.Cause(ctx)
+ }
+
return res
}
@@ -178,7 +221,9 @@ func (f *sharedInformerFactory) InformerFor(obj runtime.Object, newFunc internal
}
informer = newFunc(f.client, resyncPeriod)
- informer.SetTransform(f.transform)
+ if f.transform != nil {
+ informer.SetTransform(f.transform)
+ }
f.informers[informerType] = informer
return informer
@@ -195,27 +240,46 @@ func (f *sharedInformerFactory) InformerFor(obj runtime.Object, newFunc internal
// defer factory.WaitForStop() // Returns immediately if nothing was started.
// genericInformer := factory.ForResource(resource)
// typedInformer := factory.SomeAPIGroup().V1().SomeType()
-// factory.Start(ctx.Done()) // Start processing these informers.
-// synced := factory.WaitForCacheSync(ctx.Done())
-// for v, ok := range synced {
-// if !ok {
-// fmt.Fprintf(os.Stderr, "caches failed to sync: %v", v)
-// return
-// }
+// handle, err := typeInformer.Informer().AddEventHandler(...)
+// if err != nil {
+// return fmt.Errorf("register event handler: %v", err)
+// }
+// defer typeInformer.Informer().RemoveEventHandler(handle) // Avoids leaking goroutines.
+// factory.StartWithContext(ctx) // Start processing these informers.
+// synced := factory.WaitForCacheSyncWithContext(ctx)
+// if err := synced.AsError(); err != nil {
+// return err
+// }
+// for v := range synced {
+// // Only if desired log some information similar to this.
+// fmt.Fprintf(os.Stdout, "cache synced: %s", v)
+// }
+//
+// // Also make sure that all of the initial cache events have been delivered.
+// if !WaitFor(ctx, "event handler sync", handle.HasSyncedChecker()) {
+// // Must have failed because of context.
+// return fmt.Errorf("sync event handler: %w", context.Cause(ctx))
// }
//
// // Creating informers can also be created after Start, but then
// // Start must be called again:
// anotherGenericInformer := factory.ForResource(resource)
-// factory.Start(ctx.Done())
+// factory.StartWithContext(ctx)
type SharedInformerFactory interface {
internalinterfaces.SharedInformerFactory
// Start initializes all requested informers. They are handled in goroutines
// which run until the stop channel gets closed.
// Warning: Start does not block. When run in a go-routine, it will race with a later WaitForCacheSync.
+ //
+ // Contextual logging: StartWithContext should be used instead of Start in code which supports contextual logging.
Start(stopCh <-chan struct{})
+ // StartWithContext initializes all requested informers. They are handled in goroutines
+ // which run until the context gets canceled.
+ // Warning: StartWithContext does not block. When run in a go-routine, it will race with a later WaitForCacheSync.
+ StartWithContext(ctx context.Context)
+
// Shutdown marks a factory as shutting down. At that point no new
// informers can be started anymore and Start will return without
// doing anything.
@@ -230,8 +294,14 @@ type SharedInformerFactory interface {
// WaitForCacheSync blocks until all started informers' caches were synced
// or the stop channel gets closed.
+ //
+ // Contextual logging: WaitForCacheSync should be used instead of WaitForCacheSync in code which supports contextual logging. It also returns a more useful result.
WaitForCacheSync(stopCh <-chan struct{}) map[reflect.Type]bool
+ // WaitForCacheSyncWithContext blocks until all started informers' caches were synced
+ // or the context gets canceled.
+ WaitForCacheSyncWithContext(ctx context.Context) cache.SyncResult
+
// ForResource gives generic access to a shared informer of the matching type.
ForResource(resource schema.GroupVersionResource) (GenericInformer, error)
diff --git a/vendor/github.com/openshift/client-go/template/informers/externalversions/internalinterfaces/factory_interfaces.go b/vendor/github.com/openshift/client-go/template/informers/externalversions/internalinterfaces/factory_interfaces.go
index 1b2aea92f9..1c531b728c 100644
--- a/vendor/github.com/openshift/client-go/template/informers/externalversions/internalinterfaces/factory_interfaces.go
+++ b/vendor/github.com/openshift/client-go/template/informers/externalversions/internalinterfaces/factory_interfaces.go
@@ -18,7 +18,26 @@ type NewInformerFunc func(versioned.Interface, time.Duration) cache.SharedIndexI
type SharedInformerFactory interface {
Start(stopCh <-chan struct{})
InformerFor(obj runtime.Object, newFunc NewInformerFunc) cache.SharedIndexInformer
+ InformerName() *cache.InformerName
}
// TweakListOptionsFunc is a function that transforms a v1.ListOptions.
type TweakListOptionsFunc func(*v1.ListOptions)
+
+// InformerOptions holds the options for creating an informer.
+type InformerOptions struct {
+ // ResyncPeriod is the resync period for this informer.
+ // If not set, defaults to 0 (no resync).
+ ResyncPeriod time.Duration
+
+ // Indexers are the indexers for this informer.
+ Indexers cache.Indexers
+
+ // InformerName is used to uniquely identify this informer for metrics.
+ // If not set, metrics will not be published for this informer.
+ // Use cache.NewInformerName() to create an InformerName at startup.
+ InformerName *cache.InformerName
+
+ // TweakListOptions is an optional function to modify the list options.
+ TweakListOptions TweakListOptionsFunc
+}
diff --git a/vendor/github.com/openshift/client-go/template/informers/externalversions/template/v1/brokertemplateinstance.go b/vendor/github.com/openshift/client-go/template/informers/externalversions/template/v1/brokertemplateinstance.go
index 8b3ad5a84e..a1e82f4b4d 100644
--- a/vendor/github.com/openshift/client-go/template/informers/externalversions/template/v1/brokertemplateinstance.go
+++ b/vendor/github.com/openshift/client-go/template/informers/externalversions/template/v1/brokertemplateinstance.go
@@ -12,6 +12,7 @@ import (
templatev1 "github.com/openshift/client-go/template/listers/template/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -32,48 +33,61 @@ type brokerTemplateInstanceInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewBrokerTemplateInstanceInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredBrokerTemplateInstanceInformer(client, resyncPeriod, indexers, nil)
+ return NewBrokerTemplateInstanceInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredBrokerTemplateInstanceInformer constructs a new informer for BrokerTemplateInstance type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredBrokerTemplateInstanceInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewBrokerTemplateInstanceInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewBrokerTemplateInstanceInformerWithOptions constructs a new informer for BrokerTemplateInstance type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewBrokerTemplateInstanceInformerWithOptions(client versioned.Interface, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "template.openshift.io", Version: "v1", Resource: "brokertemplateinstances"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.TemplateV1().BrokerTemplateInstances().List(context.Background(), options)
+ return client.TemplateV1().BrokerTemplateInstances().List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.TemplateV1().BrokerTemplateInstances().Watch(context.Background(), options)
+ return client.TemplateV1().BrokerTemplateInstances().Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.TemplateV1().BrokerTemplateInstances().List(ctx, options)
+ return client.TemplateV1().BrokerTemplateInstances().List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.TemplateV1().BrokerTemplateInstances().Watch(ctx, options)
+ return client.TemplateV1().BrokerTemplateInstances().Watch(ctx, opts)
},
}, client),
&apitemplatev1.BrokerTemplateInstance{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *brokerTemplateInstanceInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredBrokerTemplateInstanceInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewBrokerTemplateInstanceInformerWithOptions(client, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *brokerTemplateInstanceInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/template/informers/externalversions/template/v1/template.go b/vendor/github.com/openshift/client-go/template/informers/externalversions/template/v1/template.go
index 0dbb2b4b97..921fe0cfbb 100644
--- a/vendor/github.com/openshift/client-go/template/informers/externalversions/template/v1/template.go
+++ b/vendor/github.com/openshift/client-go/template/informers/externalversions/template/v1/template.go
@@ -12,6 +12,7 @@ import (
templatev1 "github.com/openshift/client-go/template/listers/template/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -33,48 +34,61 @@ type templateInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewTemplateInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredTemplateInformer(client, namespace, resyncPeriod, indexers, nil)
+ return NewTemplateInformerWithOptions(client, namespace, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredTemplateInformer constructs a new informer for Template type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredTemplateInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewTemplateInformerWithOptions(client, namespace, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewTemplateInformerWithOptions constructs a new informer for Template type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewTemplateInformerWithOptions(client versioned.Interface, namespace string, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "template.openshift.io", Version: "v1", Resource: "templates"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.TemplateV1().Templates(namespace).List(context.Background(), options)
+ return client.TemplateV1().Templates(namespace).List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.TemplateV1().Templates(namespace).Watch(context.Background(), options)
+ return client.TemplateV1().Templates(namespace).Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.TemplateV1().Templates(namespace).List(ctx, options)
+ return client.TemplateV1().Templates(namespace).List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.TemplateV1().Templates(namespace).Watch(ctx, options)
+ return client.TemplateV1().Templates(namespace).Watch(ctx, opts)
},
}, client),
&apitemplatev1.Template{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *templateInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredTemplateInformer(client, f.namespace, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewTemplateInformerWithOptions(client, f.namespace, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *templateInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/client-go/template/informers/externalversions/template/v1/templateinstance.go b/vendor/github.com/openshift/client-go/template/informers/externalversions/template/v1/templateinstance.go
index c0e55621e0..35078ef4c9 100644
--- a/vendor/github.com/openshift/client-go/template/informers/externalversions/template/v1/templateinstance.go
+++ b/vendor/github.com/openshift/client-go/template/informers/externalversions/template/v1/templateinstance.go
@@ -12,6 +12,7 @@ import (
templatev1 "github.com/openshift/client-go/template/listers/template/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
+ schema "k8s.io/apimachinery/pkg/runtime/schema"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
@@ -33,48 +34,61 @@ type templateInstanceInformer struct {
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewTemplateInstanceInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
- return NewFilteredTemplateInstanceInformer(client, namespace, resyncPeriod, indexers, nil)
+ return NewTemplateInstanceInformerWithOptions(client, namespace, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers})
}
// NewFilteredTemplateInstanceInformer constructs a new informer for TemplateInstance type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredTemplateInstanceInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
- return cache.NewSharedIndexInformer(
+ return NewTemplateInstanceInformerWithOptions(client, namespace, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: indexers, TweakListOptions: tweakListOptions})
+}
+
+// NewTemplateInstanceInformerWithOptions constructs a new informer for TemplateInstance type with additional options.
+// Always prefer using an informer factory to get a shared informer instead of getting an independent
+// one. This reduces memory footprint and number of connections to the server.
+func NewTemplateInstanceInformerWithOptions(client versioned.Interface, namespace string, options internalinterfaces.InformerOptions) cache.SharedIndexInformer {
+ gvr := schema.GroupVersionResource{Group: "template.openshift.io", Version: "v1", Resource: "templateinstances"}
+ identifier := options.InformerName.WithResource(gvr)
+ tweakListOptions := options.TweakListOptions
+ return cache.NewSharedIndexInformerWithOptions(
cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{
- ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
+ ListFunc: func(opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.TemplateV1().TemplateInstances(namespace).List(context.Background(), options)
+ return client.TemplateV1().TemplateInstances(namespace).List(context.Background(), opts)
},
- WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
+ WatchFunc: func(opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.TemplateV1().TemplateInstances(namespace).Watch(context.Background(), options)
+ return client.TemplateV1().TemplateInstances(namespace).Watch(context.Background(), opts)
},
- ListWithContextFunc: func(ctx context.Context, options metav1.ListOptions) (runtime.Object, error) {
+ ListWithContextFunc: func(ctx context.Context, opts metav1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.TemplateV1().TemplateInstances(namespace).List(ctx, options)
+ return client.TemplateV1().TemplateInstances(namespace).List(ctx, opts)
},
- WatchFuncWithContext: func(ctx context.Context, options metav1.ListOptions) (watch.Interface, error) {
+ WatchFuncWithContext: func(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
- tweakListOptions(&options)
+ tweakListOptions(&opts)
}
- return client.TemplateV1().TemplateInstances(namespace).Watch(ctx, options)
+ return client.TemplateV1().TemplateInstances(namespace).Watch(ctx, opts)
},
}, client),
&apitemplatev1.TemplateInstance{},
- resyncPeriod,
- indexers,
+ cache.SharedIndexInformerOptions{
+ ResyncPeriod: options.ResyncPeriod,
+ Indexers: options.Indexers,
+ Identifier: identifier,
+ },
)
}
func (f *templateInstanceInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
- return NewFilteredTemplateInstanceInformer(client, f.namespace, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
+ return NewTemplateInstanceInformerWithOptions(client, f.namespace, internalinterfaces.InformerOptions{ResyncPeriod: resyncPeriod, Indexers: cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, InformerName: f.factory.InformerName(), TweakListOptions: f.tweakListOptions})
}
func (f *templateInstanceInformer) Informer() cache.SharedIndexInformer {
diff --git a/vendor/github.com/openshift/library-go/pkg/config/serving/server.go b/vendor/github.com/openshift/library-go/pkg/config/serving/server.go
index 41c0374bf5..d469d17c13 100644
--- a/vendor/github.com/openshift/library-go/pkg/config/serving/server.go
+++ b/vendor/github.com/openshift/library-go/pkg/config/serving/server.go
@@ -23,7 +23,7 @@ import (
operatorv1alpha1 "github.com/openshift/api/operator/v1alpha1"
)
-func ToServerConfig(ctx context.Context, servingInfo configv1.HTTPServingInfo, authenticationConfig operatorv1alpha1.DelegatedAuthentication, authorizationConfig operatorv1alpha1.DelegatedAuthorization, kubeConfigFile string, kubeClient *kubernetes.Clientset, le *configv1.LeaderElection, enableHTTP2 bool, versionInfo *version.Info) (*genericapiserver.Config, error) {
+func ToServerConfig(ctx context.Context, servingInfo configv1.HTTPServingInfo, authenticationConfig operatorv1alpha1.DelegatedAuthentication, authorizationConfig operatorv1alpha1.DelegatedAuthorization, kubeConfigFile string, kubeClient *kubernetes.Clientset, le *configv1.LeaderElection, enableHTTP2 bool, skipInClusterAuthLookup bool, versionInfo *version.Info) (*genericapiserver.Config, error) {
scheme := runtime.NewScheme()
metav1.AddToGroupVersion(scheme, metav1.SchemeGroupVersion)
config := genericapiserver.NewConfig(serializer.NewCodecFactory(scheme))
@@ -45,6 +45,7 @@ func ToServerConfig(ctx context.Context, servingInfo configv1.HTTPServingInfo, a
authenticationOptions.RemoteKubeConfigFile = kubeConfigFile
// the platform generally uses 30s for /metrics scraping, avoid API request for every other /metrics request to the component
authenticationOptions.CacheTTL = 35 * time.Second
+ authenticationOptions.SkipInClusterLookup = skipInClusterAuthLookup
// In some cases the API server can return connection refused when getting the "extension-apiserver-authentication"
// config map.
diff --git a/vendor/github.com/openshift/library-go/pkg/controller/controllercmd/builder.go b/vendor/github.com/openshift/library-go/pkg/controller/controllercmd/builder.go
index 8390b7e784..b71ceea189 100644
--- a/vendor/github.com/openshift/library-go/pkg/controller/controllercmd/builder.go
+++ b/vendor/github.com/openshift/library-go/pkg/controller/controllercmd/builder.go
@@ -104,6 +104,8 @@ type ControllerBuilder struct {
// Allow enabling HTTP2
enableHTTP2 bool
+
+ skipInClusterAuthLookup bool
}
type TopologyDetector interface {
@@ -214,6 +216,13 @@ func (b *ControllerBuilder) WithHTTP2() *ControllerBuilder {
return b
}
+// WithSkipInClusterAuthenticationLookup skips the synchronous read of the
+// extension-apiserver-authentication configmap during serving setup.
+func (b *ControllerBuilder) WithSkipInClusterAuthenticationLookup() *ControllerBuilder {
+ b.skipInClusterAuthLookup = true
+ return b
+}
+
// WithHealthChecks adds a list of healthchecks to the server
func (b *ControllerBuilder) WithHealthChecks(healthChecks ...healthz.HealthChecker) *ControllerBuilder {
b.healthChecks = append(b.healthChecks, healthChecks...)
@@ -311,7 +320,7 @@ func (b *ControllerBuilder) Run(ctx context.Context, config *unstructured.Unstru
var server *genericapiserver.GenericAPIServer
if b.servingInfo != nil {
- serverConfig, err := serving.ToServerConfig(ctx, *b.servingInfo, *b.authenticationConfig, *b.authorizationConfig, kubeConfig, kubeClient, b.leaderElection, b.enableHTTP2, b.versionInfo)
+ serverConfig, err := serving.ToServerConfig(ctx, *b.servingInfo, *b.authenticationConfig, *b.authorizationConfig, kubeConfig, kubeClient, b.leaderElection, b.enableHTTP2, b.skipInClusterAuthLookup, b.versionInfo)
if err != nil {
return err
}
diff --git a/vendor/github.com/openshift/library-go/pkg/controller/controllercmd/cmd.go b/vendor/github.com/openshift/library-go/pkg/controller/controllercmd/cmd.go
index 634053521c..34787a976b 100644
--- a/vendor/github.com/openshift/library-go/pkg/controller/controllercmd/cmd.go
+++ b/vendor/github.com/openshift/library-go/pkg/controller/controllercmd/cmd.go
@@ -3,12 +3,13 @@ package controllercmd
import (
"context"
"fmt"
- "k8s.io/utils/clock"
"math/rand"
"os"
"path/filepath"
"time"
+ "k8s.io/utils/clock"
+
"github.com/spf13/cobra"
"k8s.io/apiserver/pkg/server/healthz"
@@ -55,6 +56,13 @@ type ControllerCommandConfig struct {
// DisableLeaderElection allows leader election to be suspended
DisableLeaderElection bool
+ // SkipInClusterAuthenticationLookup skips the synchronous read of the
+ // extension-apiserver-authentication configmap during serving setup.
+ // Use this for sidecar controllers that serve metrics/health but don't
+ // need request-header (front-proxy) authentication from the aggregation layer.
+ // Bearer-token authentication via TokenReview is preserved.
+ SkipInClusterAuthenticationLookup bool
+
// LeaseDuration is the duration that non-leader candidates will
// wait to force acquire leadership. This is measured against time of
// last observed ack.
@@ -280,7 +288,7 @@ func (c *ControllerCommandConfig) AddDefaultRotationToConfig(config *operatorv1a
config.ServingInfo.CertFile = filepath.Join(temporaryCertDir, "tls.crt")
config.ServingInfo.KeyFile = filepath.Join(temporaryCertDir, "tls.key")
// nothing can trust this, so we don't really care about hostnames
- servingCert, err := ca.MakeServerCert(sets.New("localhost"), 30)
+ servingCert, err := ca.MakeServerCert(sets.New("localhost"), time.Hour*24*30)
if err != nil {
return nil, nil, err
}
@@ -340,6 +348,9 @@ func (c *ControllerCommandConfig) StartController(ctx context.Context) error {
if c.EnableHTTP2 {
builder = builder.WithHTTP2()
}
+ if c.SkipInClusterAuthenticationLookup {
+ builder = builder.WithSkipInClusterAuthenticationLookup()
+ }
}
if c.TopologyDetector != nil {
diff --git a/vendor/github.com/openshift/library-go/pkg/crypto/cert_config.go b/vendor/github.com/openshift/library-go/pkg/crypto/cert_config.go
new file mode 100644
index 0000000000..76d71da2ab
--- /dev/null
+++ b/vendor/github.com/openshift/library-go/pkg/crypto/cert_config.go
@@ -0,0 +1,225 @@
+package crypto
+
+import (
+ "crypto"
+ "crypto/x509"
+ "crypto/x509/pkix"
+ "fmt"
+ "time"
+
+ "k8s.io/apimachinery/pkg/util/sets"
+ "k8s.io/apiserver/pkg/authentication/user"
+)
+
+// KeyPairGenerator generates a cryptographic key pair.
+type KeyPairGenerator interface {
+ GenerateKeyPair() (crypto.PublicKey, crypto.PrivateKey, error)
+}
+
+// NewSigningCertificate creates a CA certificate.
+// By default it creates a self-signed root CA. Use WithSigner to create an
+// intermediate CA signed by a parent CA.
+// The name parameter is used as the CommonName unless overridden with WithSubject.
+// Optional: WithSigner, WithSubject, WithLifetime (defaults to DefaultCACertificateLifetimeDuration).
+func NewSigningCertificate(name string, keyGen KeyPairGenerator, opts ...CertificateOption) (*TLSCertificateConfig, error) {
+ o := &CertificateOptions{
+ lifetime: DefaultCACertificateLifetimeDuration,
+ }
+ for _, opt := range opts {
+ opt(o)
+ }
+
+ subject := pkix.Name{CommonName: name}
+ if o.subject != nil {
+ subject = *o.subject
+ }
+
+ publicKey, privateKey, err := keyGen.GenerateKeyPair()
+ if err != nil {
+ return nil, fmt.Errorf("failed to generate key pair: %w", err)
+ }
+ subjectKeyId, err := SubjectKeyIDFromPublicKey(publicKey)
+ if err != nil {
+ return nil, fmt.Errorf("failed to compute subject key ID: %w", err)
+ }
+
+ if o.signer != nil {
+ // Intermediate CA signed by the provided signer.
+ authorityKeyId := o.signer.Config.Certs[0].SubjectKeyId
+ template := newSigningCertificateTemplateForDuration(subject, o.lifetime, time.Now, authorityKeyId, subjectKeyId)
+ template.SignatureAlgorithm = 0
+ template.KeyUsage = KeyUsageForPublicKey(publicKey) | x509.KeyUsageCertSign
+
+ cert, err := o.signer.SignCertificate(template, publicKey)
+ if err != nil {
+ return nil, fmt.Errorf("failed to sign certificate: %w", err)
+ }
+
+ return &TLSCertificateConfig{
+ Certs: append([]*x509.Certificate{cert}, o.signer.Config.Certs...),
+ Key: privateKey,
+ }, nil
+ }
+
+ // Self-signed root CA. AuthorityKeyId and SubjectKeyId match.
+ template := newSigningCertificateTemplateForDuration(subject, o.lifetime, time.Now, subjectKeyId, subjectKeyId)
+ template.SignatureAlgorithm = 0
+ template.KeyUsage = KeyUsageForPublicKey(publicKey) | x509.KeyUsageCertSign
+
+ cert, err := signCertificate(template, publicKey, template, privateKey)
+ if err != nil {
+ return nil, fmt.Errorf("failed to sign certificate: %w", err)
+ }
+
+ return &TLSCertificateConfig{
+ Certs: []*x509.Certificate{cert},
+ Key: privateKey,
+ }, nil
+}
+
+// NewServerCertificate creates a server/serving certificate signed by this CA.
+// Optional: WithLifetime (defaults to DefaultCertificateLifetimeDuration), WithExtensions.
+func (ca *CA) NewServerCertificate(hostnames sets.Set[string], keyGen KeyPairGenerator, opts ...CertificateOption) (*TLSCertificateConfig, error) {
+ o := &CertificateOptions{
+ lifetime: DefaultCertificateLifetimeDuration,
+ }
+ for _, opt := range opts {
+ opt(o)
+ }
+
+ publicKey, privateKey, err := keyGen.GenerateKeyPair()
+ if err != nil {
+ return nil, fmt.Errorf("failed to generate key pair: %w", err)
+ }
+ subjectKeyId, err := SubjectKeyIDFromPublicKey(publicKey)
+ if err != nil {
+ return nil, fmt.Errorf("failed to compute subject key ID: %w", err)
+ }
+
+ sortedHostnames := sets.List(hostnames)
+ authorityKeyId := ca.Config.Certs[0].SubjectKeyId
+ template := newServerCertificateTemplateForDuration(
+ pkix.Name{CommonName: sortedHostnames[0]},
+ sortedHostnames,
+ o.lifetime,
+ time.Now,
+ authorityKeyId,
+ subjectKeyId,
+ )
+ // Let x509.CreateCertificate auto-detect the signature algorithm from the CA's key.
+ template.SignatureAlgorithm = 0
+ template.KeyUsage = KeyUsageForPublicKey(publicKey)
+
+ for _, fn := range o.extensionFns {
+ if err := fn(template); err != nil {
+ return nil, fmt.Errorf("failed to apply certificate extension: %w", err)
+ }
+ }
+
+ cert, err := ca.SignCertificate(template, publicKey)
+ if err != nil {
+ return nil, fmt.Errorf("failed to sign certificate: %w", err)
+ }
+
+ return &TLSCertificateConfig{
+ Certs: append([]*x509.Certificate{cert}, ca.Config.Certs...),
+ Key: privateKey,
+ }, nil
+}
+
+// NewClientCertificate creates a client certificate signed by this CA.
+// Optional: WithLifetime (defaults to DefaultCertificateLifetimeDuration).
+func (ca *CA) NewClientCertificate(u user.Info, keyGen KeyPairGenerator, opts ...CertificateOption) (*TLSCertificateConfig, error) {
+ o := &CertificateOptions{
+ lifetime: DefaultCertificateLifetimeDuration,
+ }
+ for _, opt := range opts {
+ opt(o)
+ }
+
+ publicKey, privateKey, err := keyGen.GenerateKeyPair()
+ if err != nil {
+ return nil, fmt.Errorf("failed to generate key pair: %w", err)
+ }
+ subjectKeyId, err := SubjectKeyIDFromPublicKey(publicKey)
+ if err != nil {
+ return nil, fmt.Errorf("failed to compute subject key ID: %w", err)
+ }
+
+ authorityKeyId := ca.Config.Certs[0].SubjectKeyId
+ template := NewClientCertificateTemplateForDuration(UserToSubject(u), o.lifetime, time.Now)
+ template.AuthorityKeyId = authorityKeyId
+ template.SubjectKeyId = subjectKeyId
+ // Let x509.CreateCertificate auto-detect the signature algorithm from the CA's key.
+ template.SignatureAlgorithm = 0
+ template.KeyUsage = KeyUsageForPublicKey(publicKey)
+
+ cert, err := ca.SignCertificate(template, publicKey)
+ if err != nil {
+ return nil, fmt.Errorf("failed to sign certificate: %w", err)
+ }
+
+ return &TLSCertificateConfig{
+ Certs: append([]*x509.Certificate{cert}, ca.Config.Certs...),
+ Key: privateKey,
+ }, nil
+}
+
+// NewPeerCertificate creates a peer certificate (both server and client auth)
+// signed by this CA.
+// Optional: WithLifetime (defaults to DefaultCertificateLifetimeDuration), WithExtensions.
+func (ca *CA) NewPeerCertificate(hostnames sets.Set[string], u user.Info, keyGen KeyPairGenerator, opts ...CertificateOption) (*TLSCertificateConfig, error) {
+ o := &CertificateOptions{
+ lifetime: DefaultCertificateLifetimeDuration,
+ }
+ for _, opt := range opts {
+ opt(o)
+ }
+
+ publicKey, privateKey, err := keyGen.GenerateKeyPair()
+ if err != nil {
+ return nil, fmt.Errorf("failed to generate key pair: %w", err)
+ }
+ subjectKeyId, err := SubjectKeyIDFromPublicKey(publicKey)
+ if err != nil {
+ return nil, fmt.Errorf("failed to compute subject key ID: %w", err)
+ }
+
+ sortedHostnames := sets.List(hostnames)
+ authorityKeyId := ca.Config.Certs[0].SubjectKeyId
+
+ // Start from a server certificate template for the hostnames.
+ template := newServerCertificateTemplateForDuration(
+ pkix.Name{CommonName: sortedHostnames[0]},
+ sortedHostnames,
+ o.lifetime,
+ time.Now,
+ authorityKeyId,
+ subjectKeyId,
+ )
+ // Let x509.CreateCertificate auto-detect the signature algorithm from the CA's key.
+ template.SignatureAlgorithm = 0
+ template.KeyUsage = KeyUsageForPublicKey(publicKey)
+
+ // Set subject from user info for client authentication.
+ template.Subject = UserToSubject(u)
+
+ // Enable both server and client authentication.
+ template.ExtKeyUsage = []x509.ExtKeyUsage{x509.ExtKeyUsageServerAuth, x509.ExtKeyUsageClientAuth}
+
+ for _, fn := range o.extensionFns {
+ if err := fn(template); err != nil {
+ return nil, fmt.Errorf("failed to apply certificate extension: %w", err)
+ }
+ }
+
+ cert, err := ca.SignCertificate(template, publicKey)
+ if err != nil {
+ return nil, fmt.Errorf("failed to sign certificate: %w", err)
+ }
+
+ return &TLSCertificateConfig{
+ Certs: append([]*x509.Certificate{cert}, ca.Config.Certs...),
+ Key: privateKey,
+ }, nil
+}
diff --git a/vendor/github.com/openshift/library-go/pkg/crypto/crypto.go b/vendor/github.com/openshift/library-go/pkg/crypto/crypto.go
index be0337b900..58d08d28ba 100644
--- a/vendor/github.com/openshift/library-go/pkg/crypto/crypto.go
+++ b/vendor/github.com/openshift/library-go/pkg/crypto/crypto.go
@@ -20,8 +20,10 @@ import (
"os"
"path/filepath"
"reflect"
+ "slices"
"sort"
"strconv"
+ "strings"
"sync"
"time"
@@ -34,17 +36,29 @@ import (
configv1 "github.com/openshift/api/config/v1"
)
-// TLS versions that are known to golang. Go 1.13 adds support for
-// TLS 1.3 that's opt-out with a build flag.
-var versions = map[string]uint16{
+// TLS configuration
+//
+// The OpenShift API defines TLS profiles using OpenSSL cipher suite names.
+// Go's crypto/tls uses IANA-standard cipher suite names (which happen to
+// match the Go constant names). This package bridges the two naming schemes:
+// OpenSSLToIANACipherSuites translates API-level OpenSSL names into the IANA
+// names that Go understands, silently dropping any cipher that Go's crypto/tls
+// cannot negotiate. This silent narrowing is by design: Go literally cannot
+// serve those ciphers, so listing them would be misleading.
+
+// goTLSVersions lists all TLS versions that Go's crypto/tls can negotiate.
+// Kept in sync with the crypto/tls package by TestConstantMaps.
+var goTLSVersions = map[string]uint16{
"VersionTLS10": tls.VersionTLS10,
"VersionTLS11": tls.VersionTLS11,
"VersionTLS12": tls.VersionTLS12,
"VersionTLS13": tls.VersionTLS13,
}
-// TLS versions that are enabled.
-var supportedVersions = map[string]uint16{
+// enabledTLSVersions is the subset of goTLSVersions that OpenShift allows
+// in TLS configurations. Remove an entry here (not from goTLSVersions) to
+// phase out a version while still being able to parse legacy references.
+var enabledTLSVersions = map[string]uint16{
"VersionTLS10": tls.VersionTLS10,
"VersionTLS11": tls.VersionTLS11,
"VersionTLS12": tls.VersionTLS12,
@@ -54,7 +68,7 @@ var supportedVersions = map[string]uint16{
// TLSVersionToNameOrDie given a tls version as an int, return its readable name
func TLSVersionToNameOrDie(intVal uint16) string {
matches := []string{}
- for key, version := range versions {
+ for key, version := range goTLSVersions {
if version == intVal {
matches = append(matches, key)
}
@@ -73,7 +87,7 @@ func TLSVersion(versionName string) (uint16, error) {
if len(versionName) == 0 {
return DefaultTLSVersion(), nil
}
- if version, ok := versions[versionName]; ok {
+ if version, ok := goTLSVersions[versionName]; ok {
return version, nil
}
return 0, fmt.Errorf("unknown tls version %q", versionName)
@@ -86,20 +100,22 @@ func TLSVersionOrDie(versionName string) uint16 {
return version
}
-// TLS versions that are known to golang, but may not necessarily be enabled.
+// GolangTLSVersions returns all TLS versions known to this Go build.
+//
+// Deprecated: Use ValidTLSVersions instead.
func GolangTLSVersions() []string {
supported := []string{}
- for k := range versions {
+ for k := range goTLSVersions {
supported = append(supported, k)
}
sort.Strings(supported)
return supported
}
-// Returns the build enabled TLS versions.
+// ValidTLSVersions returns the TLS versions that OpenShift allows in configurations.
func ValidTLSVersions() []string {
validVersions := []string{}
- for k := range supportedVersions {
+ for k := range enabledTLSVersions {
validVersions = append(validVersions, k)
}
sort.Strings(validVersions)
@@ -112,7 +128,9 @@ func DefaultTLSVersion() uint16 {
return tls.VersionTLS12
}
-var ciphers = map[string]uint16{
+// goCipherSuites lists all cipher suites recognized by Go's crypto/tls, keyed
+// by IANA name. Kept in sync with the crypto/tls package by TestConstantMaps.
+var goCipherSuites = map[string]uint16{
"TLS_RSA_WITH_RC4_128_SHA": tls.TLS_RSA_WITH_RC4_128_SHA,
"TLS_RSA_WITH_3DES_EDE_CBC_SHA": tls.TLS_RSA_WITH_3DES_EDE_CBC_SHA,
"TLS_RSA_WITH_AES_128_CBC_SHA": tls.TLS_RSA_WITH_AES_128_CBC_SHA,
@@ -142,14 +160,13 @@ var ciphers = map[string]uint16{
"TLS_CHACHA20_POLY1305_SHA256": tls.TLS_CHACHA20_POLY1305_SHA256,
}
-// openSSLToIANACiphersMap maps OpenSSL cipher suite names to IANA names
+// openSSLToIANACiphers maps OpenSSL cipher suite names to IANA names for
+// every cipher that Go's crypto/tls can negotiate.
// Ref: https://www.iana.org/assignments/tls-parameters/tls-parameters.xml
-// This must hold a 1:1 mapping for each OpenSSL cipher defined in openshift/api TLSSecurityProfiles,
-// so it can be used to translate OpenSSL ciphers to IANA ciphers, which is what go's crypto/tls understands.
-// Ciphers in this map must also be compatible with go's crypto/tls ciphers:
-// https://github.com/golang/go/blob/d4febb45179fa99ee1d5783bcb693ed7ba14115c/src/crypto/tls/cipher_suites.go#L682-L724
-var openSSLToIANACiphersMap = map[string]string{
- // TLS 1.3 ciphers - not configurable in go 1.13, all of them are used in TLSv1.3 flows
+// Ciphers defined in the API but absent from Go are tracked in
+// ciphersUnsupportedByGo (below) so tests detect when Go gains support.
+var openSSLToIANACiphers = map[string]string{
+ // TLS 1.3 ciphers - always negotiated by Go; not individually configurable.
"TLS_AES_128_GCM_SHA256": "TLS_AES_128_GCM_SHA256", // 0x13,0x01
"TLS_AES_256_GCM_SHA384": "TLS_AES_256_GCM_SHA384", // 0x13,0x02
"TLS_CHACHA20_POLY1305_SHA256": "TLS_CHACHA20_POLY1305_SHA256", // 0x13,0x03
@@ -167,20 +184,8 @@ var openSSLToIANACiphersMap = map[string]string{
"AES256-GCM-SHA384": "TLS_RSA_WITH_AES_256_GCM_SHA384", // 0x00,0x9D
"AES128-SHA256": "TLS_RSA_WITH_AES_128_CBC_SHA256", // 0x00,0x3C
- // Go's crypto/tls does not support CBC mode and DHE ciphers, so we don't want to include them here.
- // See:
- // - https://github.com/golang/go/issues/26652
- // - https://github.com/golang/go/issues/7758
- // - https://redhat-internal.slack.com/archives/C098FU5MRAB/p1770309657097269
- //
- // "ECDHE-ECDSA-AES256-SHA384": "TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384", // 0xC0,0x24
- // "ECDHE-RSA-AES256-SHA384": "TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384", // 0xC0,0x28
- // "AES256-SHA256": "TLS_RSA_WITH_AES_256_CBC_SHA256", // 0x00,0x3D
- // "DHE-RSA-AES128-GCM-SHA256": "TLS_DHE_RSA_WITH_AES_128_GCM_SHA256", // 0x00,0x9E
- // "DHE-RSA-AES256-GCM-SHA384": "TLS_DHE_RSA_WITH_AES_256_GCM_SHA384", // 0x00,0x9F
- // "DHE-RSA-CHACHA20-POLY1305": "TLS_DHE_RSA_WITH_CHACHA20_POLY1305_SHA256", // 0xCC,0xAA
- // "DHE-RSA-AES128-SHA256": "TLS_DHE_RSA_WITH_AES_128_CBC_SHA256", // 0x00,0x67
- // "DHE-RSA-AES256-SHA256": "TLS_DHE_RSA_WITH_AES_256_CBC_SHA256", // 0x00,0x6B
+ // Ciphers defined in the API but not supported by Go are listed in
+ // ciphersUnsupportedByGo below.
// TLS 1
"ECDHE-ECDSA-AES128-SHA": "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA", // 0xC0,0x09
@@ -195,6 +200,30 @@ var openSSLToIANACiphersMap = map[string]string{
"ECDHE-RSA-DES-CBC3-SHA": "TLS_ECDHE_RSA_WITH_3DES_EDE_CBC_SHA", // 0xC0,0x12
}
+// ciphersUnsupportedByGo lists cipher suites that are defined in the OpenShift API
+// TLS profiles (from the Mozilla guidelines) but are not supported by Go's crypto/tls.
+// These are intentionally excluded from openSSLToIANACiphers and silently filtered
+// out during profile translation. The IANA names come from the IANA TLS Cipher Suite
+// Registry (https://www.iana.org/assignments/tls-parameters/) and are retained so
+// TestCiphersUnsupportedByGoAreActuallyUnsupported can detect if a future Go
+// release adds support.
+var ciphersUnsupportedByGo = map[string]string{
+ "ECDHE-ECDSA-AES256-SHA384": "TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384",
+ "ECDHE-RSA-AES256-SHA384": "TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384",
+ "AES256-SHA256": "TLS_RSA_WITH_AES_256_CBC_SHA256",
+}
+
+// tlsGroupToCurveID maps OpenShift API TLSGroup values to Go's tls.CurveID.
+var tlsGroupToCurveID = map[configv1.TLSGroup]tls.CurveID{
+ configv1.TLSGroupX25519: tls.X25519,
+ configv1.TLSGroupSecP256r1: tls.CurveP256,
+ configv1.TLSGroupSecP384r1: tls.CurveP384,
+ configv1.TLSGroupSecP521r1: tls.CurveP521,
+ configv1.TLSGroupX25519MLKEM768: tls.X25519MLKEM768,
+ configv1.TLSGroupSecP256r1MLKEM768: tls.SecP256r1MLKEM768,
+ configv1.TLSGroupSecP384r1MLKEM1024: tls.SecP384r1MLKEM1024,
+}
+
// CipherSuitesToNamesOrDie given a list of cipher suites as ints, return their readable names
func CipherSuitesToNamesOrDie(intVals []uint16) []string {
ret := []string{}
@@ -219,7 +248,7 @@ func CipherSuiteToNameOrDie(intVal uint16) string {
}
matches := []string{}
- for key, version := range ciphers {
+ for key, version := range goCipherSuites {
if version == intVal {
matches = append(matches, key)
}
@@ -235,7 +264,7 @@ func CipherSuiteToNameOrDie(intVal uint16) string {
}
func CipherSuite(cipherName string) (uint16, error) {
- if cipher, ok := ciphers[cipherName]; ok {
+ if cipher, ok := goCipherSuites[cipherName]; ok {
return cipher, nil
}
@@ -258,7 +287,7 @@ func CipherSuitesOrDie(cipherNames []string) []uint16 {
}
func ValidCipherSuites() []string {
validCipherSuites := []string{}
- for k := range ciphers {
+ for k := range goCipherSuites {
validCipherSuites = append(validCipherSuites, k)
}
sort.Strings(validCipherSuites)
@@ -323,20 +352,61 @@ func SecureTLSConfig(config *tls.Config) *tls.Config {
// OpenSSLToIANACipherSuites maps input OpenSSL Cipher Suite names to their
// IANA counterparts.
-// Unknown ciphers are left out.
+// Ciphers that Go's crypto/tls cannot negotiate are silently dropped and
+// logged at V(4).
func OpenSSLToIANACipherSuites(ciphers []string) []string {
ianaCiphers := make([]string, 0, len(ciphers))
for _, c := range ciphers {
- ianaCipher, found := openSSLToIANACiphersMap[c]
+ ianaCipher, found := openSSLToIANACiphers[c]
if found {
ianaCiphers = append(ianaCiphers, ianaCipher)
+ } else {
+ klog.V(4).Infof("Dropping cipher %q: not supported by Go's crypto/tls", c)
}
}
return ianaCiphers
}
+// TLSGroupToCurveID returns the Go tls.CurveID for an OpenShift API TLSGroup
+// constant, or (0, false) if the group is not recognized.
+func TLSGroupToCurveID(group configv1.TLSGroup) (tls.CurveID, bool) {
+ id, ok := tlsGroupToCurveID[group]
+ return id, ok
+}
+
+// TLSGroupsToCurveIDs converts a slice of TLSGroup values to their tls.CurveID
+// codes. Returns the mapped curve IDs and a list of unrecognized groups.
+// Unrecognized groups are silently filtered — callers should log warnings.
+func TLSGroupsToCurveIDs(groups []configv1.TLSGroup) ([]tls.CurveID, []configv1.TLSGroup) {
+ var curves []tls.CurveID
+ var unrecognized []configv1.TLSGroup
+
+ for _, group := range groups {
+ id, ok := TLSGroupToCurveID(group)
+ if !ok {
+ unrecognized = append(unrecognized, group)
+ continue
+ }
+ curves = append(curves, id)
+ }
+
+ return curves, unrecognized
+}
+
+// ValidTLSGroups returns the recognized TLS group names, sorted alphabetically.
+func ValidTLSGroups() []configv1.TLSGroup {
+ groups := make([]configv1.TLSGroup, 0, len(tlsGroupToCurveID))
+ for g := range tlsGroupToCurveID {
+ groups = append(groups, g)
+ }
+ slices.SortFunc(groups, func(a, b configv1.TLSGroup) int {
+ return strings.Compare(string(a), string(b))
+ })
+ return groups
+}
+
type TLSCertificateConfig struct {
Certs []*x509.Certificate
Key crypto.PrivateKey
diff --git a/vendor/github.com/openshift/library-go/pkg/crypto/keygen.go b/vendor/github.com/openshift/library-go/pkg/crypto/keygen.go
new file mode 100644
index 0000000000..96b7559468
--- /dev/null
+++ b/vendor/github.com/openshift/library-go/pkg/crypto/keygen.go
@@ -0,0 +1,118 @@
+package crypto
+
+import (
+ "crypto"
+ "crypto/ecdsa"
+ "crypto/elliptic"
+ "crypto/rand"
+ "crypto/rsa"
+ "crypto/sha256"
+ "crypto/x509"
+ "fmt"
+)
+
+// KeyAlgorithm identifies the key generation algorithm.
+type KeyAlgorithm string
+
+const (
+ // RSAKeyAlgorithm specifies RSA key generation.
+ RSAKeyAlgorithm KeyAlgorithm = "RSA"
+ // ECDSAKeyAlgorithm specifies ECDSA key generation.
+ ECDSAKeyAlgorithm KeyAlgorithm = "ECDSA"
+)
+
+// ECDSACurve identifies a named ECDSA curve.
+type ECDSACurve string
+
+const (
+ // P256 specifies the NIST P-256 curve (secp256r1), providing 128-bit security.
+ P256 ECDSACurve = "P256"
+ // P384 specifies the NIST P-384 curve (secp384r1), providing 192-bit security.
+ P384 ECDSACurve = "P384"
+ // P521 specifies the NIST P-521 curve (secp521r1), providing 256-bit security.
+ P521 ECDSACurve = "P521"
+)
+
+// RSAKeyPairGenerator generates RSA key pairs.
+type RSAKeyPairGenerator struct {
+ // Bits is the RSA key size in bits. Must be >= 2048.
+ Bits int
+}
+
+func (g RSAKeyPairGenerator) GenerateKeyPair() (crypto.PublicKey, crypto.PrivateKey, error) {
+ bits := g.Bits
+ if bits == 0 {
+ bits = keyBits
+ }
+ privateKey, err := rsa.GenerateKey(rand.Reader, bits)
+ if err != nil {
+ return nil, nil, err
+ }
+ return &privateKey.PublicKey, privateKey, nil
+}
+
+// ECDSAKeyPairGenerator generates ECDSA key pairs.
+type ECDSAKeyPairGenerator struct {
+ // Curve is the named ECDSA curve.
+ Curve ECDSACurve
+}
+
+func (g ECDSAKeyPairGenerator) GenerateKeyPair() (crypto.PublicKey, crypto.PrivateKey, error) {
+ curve, err := g.ellipticCurve()
+ if err != nil {
+ return nil, nil, err
+ }
+ privateKey, err := ecdsa.GenerateKey(curve, rand.Reader)
+ if err != nil {
+ return nil, nil, err
+ }
+ return &privateKey.PublicKey, privateKey, nil
+}
+
+func (g ECDSAKeyPairGenerator) ellipticCurve() (elliptic.Curve, error) {
+ switch g.Curve {
+ case P256:
+ return elliptic.P256(), nil
+ case P384:
+ return elliptic.P384(), nil
+ case P521:
+ return elliptic.P521(), nil
+ default:
+ return nil, fmt.Errorf("unsupported ECDSA curve: %q", g.Curve)
+ }
+}
+
+// KeyUsageForPublicKey returns the x509.KeyUsage flags appropriate for the
+// given public key type. ECDSA keys use DigitalSignature only; RSA keys also
+// include KeyEncipherment.
+func KeyUsageForPublicKey(pub crypto.PublicKey) x509.KeyUsage {
+ switch pub.(type) {
+ case *ecdsa.PublicKey:
+ return x509.KeyUsageDigitalSignature
+ default:
+ return x509.KeyUsageKeyEncipherment | x509.KeyUsageDigitalSignature
+ }
+}
+
+// SubjectKeyIDFromPublicKey computes a truncated SHA-256 hash suitable for
+// use as a certificate SubjectKeyId from any supported public key type.
+// This uses the first 160 bits of the SHA-256 hash per RFC 7093, consistent
+// with the Go standard library since Go 1.25 (go.dev/issue/71746) and
+// Let's Encrypt. Prior Go versions used SHA-1 which is not FIPS-compatible.
+func SubjectKeyIDFromPublicKey(pub crypto.PublicKey) ([]byte, error) {
+ var rawBytes []byte
+ switch pub := pub.(type) {
+ case *rsa.PublicKey:
+ rawBytes = pub.N.Bytes()
+ case *ecdsa.PublicKey:
+ ecdhKey, err := pub.ECDH()
+ if err != nil {
+ return nil, fmt.Errorf("failed to convert ECDSA public key: %w", err)
+ }
+ rawBytes = ecdhKey.Bytes()
+ default:
+ return nil, fmt.Errorf("unsupported public key type: %T", pub)
+ }
+ hash := sha256.Sum256(rawBytes)
+ return hash[:20], nil
+}
diff --git a/vendor/github.com/openshift/library-go/pkg/crypto/options.go b/vendor/github.com/openshift/library-go/pkg/crypto/options.go
new file mode 100644
index 0000000000..983b115d22
--- /dev/null
+++ b/vendor/github.com/openshift/library-go/pkg/crypto/options.go
@@ -0,0 +1,49 @@
+package crypto
+
+import (
+ "crypto/x509/pkix"
+ "time"
+)
+
+// CertificateOptions holds optional configuration collected from functional options.
+type CertificateOptions struct {
+ lifetime time.Duration
+ subject *pkix.Name
+ extensionFns []CertificateExtensionFunc
+ signer *CA
+}
+
+// CertificateOption is a functional option for certificate creation.
+type CertificateOption func(*CertificateOptions)
+
+// WithLifetime sets the certificate lifetime duration.
+func WithLifetime(d time.Duration) CertificateOption {
+ return func(o *CertificateOptions) {
+ o.lifetime = d
+ }
+}
+
+// WithSubject overrides the certificate subject. For signing certificates,
+// this overrides the default subject derived from the name parameter.
+func WithSubject(s pkix.Name) CertificateOption {
+ return func(o *CertificateOptions) {
+ o.subject = &s
+ }
+}
+
+// WithSigner specifies a CA to sign the certificate. When used with
+// NewSigningCertificate, this creates an intermediate CA signed by the
+// given CA instead of a self-signed root CA.
+func WithSigner(ca *CA) CertificateOption {
+ return func(o *CertificateOptions) {
+ o.signer = ca
+ }
+}
+
+// WithExtensions adds certificate extension functions that are called
+// to modify the certificate template before signing.
+func WithExtensions(fns ...CertificateExtensionFunc) CertificateOption {
+ return func(o *CertificateOptions) {
+ o.extensionFns = append(o.extensionFns, fns...)
+ }
+}
diff --git a/vendor/github.com/openshift/library-go/pkg/crypto/tls_adherence.go b/vendor/github.com/openshift/library-go/pkg/crypto/tls_adherence.go
new file mode 100644
index 0000000000..ef0e1af51a
--- /dev/null
+++ b/vendor/github.com/openshift/library-go/pkg/crypto/tls_adherence.go
@@ -0,0 +1,23 @@
+package crypto
+
+import (
+ configv1 "github.com/openshift/api/config/v1"
+)
+
+// ShouldHonorClusterTLSProfile returns true if the component should honor the
+// cluster-wide TLS security profile settings from apiserver.config.openshift.io/cluster.
+//
+// When this returns true (StrictAllComponents mode), components must honor the
+// cluster-wide TLS profile unless they have a component-specific TLS configuration
+// that overrides it.
+//
+// Unknown enum values are treated as StrictAllComponents for forward compatibility
+// and to default to the more secure behavior.
+func ShouldHonorClusterTLSProfile(tlsAdherence configv1.TLSAdherencePolicy) bool {
+ switch tlsAdherence {
+ case configv1.TLSAdherencePolicyNoOpinion, configv1.TLSAdherencePolicyLegacyAdheringComponentsOnly:
+ return false
+ default:
+ return true
+ }
+}
diff --git a/vendor/github.com/openshift/library-go/pkg/operator/events/recorder_in_memory.go b/vendor/github.com/openshift/library-go/pkg/operator/events/recorder_in_memory.go
index d97be0de6c..bbddd98299 100644
--- a/vendor/github.com/openshift/library-go/pkg/operator/events/recorder_in_memory.go
+++ b/vendor/github.com/openshift/library-go/pkg/operator/events/recorder_in_memory.go
@@ -42,6 +42,8 @@ func NewInMemoryRecorder(sourceComponent string, clock clock.PassiveClock) InMem
}
func (r *inMemoryEventRecorder) ComponentName() string {
+ r.Lock()
+ defer r.Unlock()
return r.source
}
@@ -55,6 +57,8 @@ func (r *inMemoryEventRecorder) ForComponent(component string) Recorder {
}
func (r *inMemoryEventRecorder) WithContext(ctx context.Context) Recorder {
+ r.Lock()
+ defer r.Unlock()
r.ctx = ctx
return r
}
@@ -65,7 +69,9 @@ func (r *inMemoryEventRecorder) WithComponentSuffix(suffix string) Recorder {
// Events returns list of recorded events
func (r *inMemoryEventRecorder) Events() []*corev1.Event {
- return r.events
+ r.Lock()
+ defer r.Unlock()
+ return append([]*corev1.Event(nil), r.events...)
}
func (r *inMemoryEventRecorder) Event(reason, message string) {
diff --git a/vendor/github.com/prometheus/common/expfmt/decode.go b/vendor/github.com/prometheus/common/expfmt/decode.go
index 7b762370e2..8f8dc65d38 100644
--- a/vendor/github.com/prometheus/common/expfmt/decode.go
+++ b/vendor/github.com/prometheus/common/expfmt/decode.go
@@ -220,7 +220,7 @@ func extractSamples(f *dto.MetricFamily, o *DecodeOptions) (model.Vector, error)
return extractSummary(o, f), nil
case dto.MetricType_UNTYPED:
return extractUntyped(o, f), nil
- case dto.MetricType_HISTOGRAM:
+ case dto.MetricType_HISTOGRAM, dto.MetricType_GAUGE_HISTOGRAM:
return extractHistogram(o, f), nil
}
return nil, fmt.Errorf("expfmt.extractSamples: unknown metric family type %v", f.GetType())
@@ -403,9 +403,13 @@ func extractHistogram(o *DecodeOptions, f *dto.MetricFamily) model.Vector {
infSeen = true
}
+ v := q.GetCumulativeCountFloat()
+ if v <= 0 {
+ v = float64(q.GetCumulativeCount())
+ }
samples = append(samples, &model.Sample{
Metric: model.Metric(lset),
- Value: model.SampleValue(q.GetCumulativeCount()),
+ Value: model.SampleValue(v),
Timestamp: timestamp,
})
}
@@ -428,9 +432,13 @@ func extractHistogram(o *DecodeOptions, f *dto.MetricFamily) model.Vector {
}
lset[model.MetricNameLabel] = model.LabelValue(f.GetName() + "_count")
+ v := m.Histogram.GetSampleCountFloat()
+ if v <= 0 {
+ v = float64(m.Histogram.GetSampleCount())
+ }
count := &model.Sample{
Metric: model.Metric(lset),
- Value: model.SampleValue(m.Histogram.GetSampleCount()),
+ Value: model.SampleValue(v),
Timestamp: timestamp,
}
samples = append(samples, count)
diff --git a/vendor/github.com/prometheus/common/expfmt/expfmt.go b/vendor/github.com/prometheus/common/expfmt/expfmt.go
index c34c7de432..4e4c13e724 100644
--- a/vendor/github.com/prometheus/common/expfmt/expfmt.go
+++ b/vendor/github.com/prometheus/common/expfmt/expfmt.go
@@ -45,6 +45,7 @@ const (
// The Content-Type values for the different wire protocols. Do not do direct
// comparisons to these constants, instead use the comparison functions.
+ //
// Deprecated: Use expfmt.NewFormat(expfmt.TypeUnknown) instead.
FmtUnknown Format = ``
// Deprecated: Use expfmt.NewFormat(expfmt.TypeTextPlain) instead.
diff --git a/vendor/github.com/prometheus/common/expfmt/fuzz.go b/vendor/github.com/prometheus/common/expfmt/fuzz.go
index 0290f6abc4..872c0c15b4 100644
--- a/vendor/github.com/prometheus/common/expfmt/fuzz.go
+++ b/vendor/github.com/prometheus/common/expfmt/fuzz.go
@@ -13,7 +13,6 @@
// Build only when actually fuzzing
//go:build gofuzz
-// +build gofuzz
package expfmt
diff --git a/vendor/github.com/prometheus/common/expfmt/openmetrics_create.go b/vendor/github.com/prometheus/common/expfmt/openmetrics_create.go
index 8dbf6d04ed..21b93bca36 100644
--- a/vendor/github.com/prometheus/common/expfmt/openmetrics_create.go
+++ b/vendor/github.com/prometheus/common/expfmt/openmetrics_create.go
@@ -160,38 +160,38 @@ func MetricFamilyToOpenMetrics(out io.Writer, in *dto.MetricFamily, options ...E
n, err = w.WriteString("# HELP ")
written += n
if err != nil {
- return
+ return written, err
}
n, err = writeName(w, compliantName)
written += n
if err != nil {
- return
+ return written, err
}
err = w.WriteByte(' ')
written++
if err != nil {
- return
+ return written, err
}
n, err = writeEscapedString(w, *in.Help, true)
written += n
if err != nil {
- return
+ return written, err
}
err = w.WriteByte('\n')
written++
if err != nil {
- return
+ return written, err
}
}
n, err = w.WriteString("# TYPE ")
written += n
if err != nil {
- return
+ return written, err
}
n, err = writeName(w, compliantName)
written += n
if err != nil {
- return
+ return written, err
}
switch metricType {
case dto.MetricType_COUNTER:
@@ -208,39 +208,41 @@ func MetricFamilyToOpenMetrics(out io.Writer, in *dto.MetricFamily, options ...E
n, err = w.WriteString(" unknown\n")
case dto.MetricType_HISTOGRAM:
n, err = w.WriteString(" histogram\n")
+ case dto.MetricType_GAUGE_HISTOGRAM:
+ n, err = w.WriteString(" gaugehistogram\n")
default:
return written, fmt.Errorf("unknown metric type %s", metricType.String())
}
written += n
if err != nil {
- return
+ return written, err
}
if toOM.withUnit && in.Unit != nil {
n, err = w.WriteString("# UNIT ")
written += n
if err != nil {
- return
+ return written, err
}
n, err = writeName(w, compliantName)
written += n
if err != nil {
- return
+ return written, err
}
err = w.WriteByte(' ')
written++
if err != nil {
- return
+ return written, err
}
n, err = writeEscapedString(w, *in.Unit, true)
written += n
if err != nil {
- return
+ return written, err
}
err = w.WriteByte('\n')
written++
if err != nil {
- return
+ return written, err
}
}
@@ -304,7 +306,7 @@ func MetricFamilyToOpenMetrics(out io.Writer, in *dto.MetricFamily, options ...E
)
written += n
if err != nil {
- return
+ return written, err
}
}
n, err = writeOpenMetricsSample(
@@ -314,7 +316,7 @@ func MetricFamilyToOpenMetrics(out io.Writer, in *dto.MetricFamily, options ...E
)
written += n
if err != nil {
- return
+ return written, err
}
n, err = writeOpenMetricsSample(
w, compliantName, "_count", metric, "", 0,
@@ -325,7 +327,7 @@ func MetricFamilyToOpenMetrics(out io.Writer, in *dto.MetricFamily, options ...E
createdTsBytesWritten, err = writeOpenMetricsCreated(w, compliantName, "", metric, "", 0, metric.Summary.GetCreatedTimestamp())
n += createdTsBytesWritten
}
- case dto.MetricType_HISTOGRAM:
+ case dto.MetricType_HISTOGRAM, dto.MetricType_GAUGE_HISTOGRAM:
if metric.Histogram == nil {
return written, fmt.Errorf(
"expected histogram in metric %s %s", compliantName, metric,
@@ -333,6 +335,12 @@ func MetricFamilyToOpenMetrics(out io.Writer, in *dto.MetricFamily, options ...E
}
infSeen := false
for _, b := range metric.Histogram.Bucket {
+ if b.GetCumulativeCountFloat() > 0 {
+ return written, fmt.Errorf(
+ "OpenMetrics v1.0 does not support float histogram %s %s",
+ compliantName, metric,
+ )
+ }
n, err = writeOpenMetricsSample(
w, compliantName, "_bucket", metric,
model.BucketLabel, b.GetUpperBound(),
@@ -341,7 +349,7 @@ func MetricFamilyToOpenMetrics(out io.Writer, in *dto.MetricFamily, options ...E
)
written += n
if err != nil {
- return
+ return written, err
}
if math.IsInf(b.GetUpperBound(), +1) {
infSeen = true
@@ -354,9 +362,12 @@ func MetricFamilyToOpenMetrics(out io.Writer, in *dto.MetricFamily, options ...E
0, metric.Histogram.GetSampleCount(), true,
nil,
)
+ // We do not check for a float sample count here
+ // because we will check for it below (and error
+ // out if needed).
written += n
if err != nil {
- return
+ return written, err
}
}
n, err = writeOpenMetricsSample(
@@ -366,7 +377,13 @@ func MetricFamilyToOpenMetrics(out io.Writer, in *dto.MetricFamily, options ...E
)
written += n
if err != nil {
- return
+ return written, err
+ }
+ if metric.Histogram.GetSampleCountFloat() > 0 {
+ return written, fmt.Errorf(
+ "OpenMetrics v1.0 does not support float histogram %s %s",
+ compliantName, metric,
+ )
}
n, err = writeOpenMetricsSample(
w, compliantName, "_count", metric, "", 0,
@@ -384,10 +401,10 @@ func MetricFamilyToOpenMetrics(out io.Writer, in *dto.MetricFamily, options ...E
}
written += n
if err != nil {
- return
+ return written, err
}
}
- return
+ return written, err
}
// FinalizeOpenMetrics writes the final `# EOF\n` line required by OpenMetrics.
diff --git a/vendor/github.com/prometheus/common/expfmt/text_create.go b/vendor/github.com/prometheus/common/expfmt/text_create.go
index c4e9c1bbc3..6b89781456 100644
--- a/vendor/github.com/prometheus/common/expfmt/text_create.go
+++ b/vendor/github.com/prometheus/common/expfmt/text_create.go
@@ -108,38 +108,38 @@ func MetricFamilyToText(out io.Writer, in *dto.MetricFamily) (written int, err e
n, err = w.WriteString("# HELP ")
written += n
if err != nil {
- return
+ return written, err
}
n, err = writeName(w, name)
written += n
if err != nil {
- return
+ return written, err
}
err = w.WriteByte(' ')
written++
if err != nil {
- return
+ return written, err
}
n, err = writeEscapedString(w, *in.Help, false)
written += n
if err != nil {
- return
+ return written, err
}
err = w.WriteByte('\n')
written++
if err != nil {
- return
+ return written, err
}
}
n, err = w.WriteString("# TYPE ")
written += n
if err != nil {
- return
+ return written, err
}
n, err = writeName(w, name)
written += n
if err != nil {
- return
+ return written, err
}
metricType := in.GetType()
switch metricType {
@@ -151,14 +151,17 @@ func MetricFamilyToText(out io.Writer, in *dto.MetricFamily) (written int, err e
n, err = w.WriteString(" summary\n")
case dto.MetricType_UNTYPED:
n, err = w.WriteString(" untyped\n")
- case dto.MetricType_HISTOGRAM:
+ case dto.MetricType_HISTOGRAM, dto.MetricType_GAUGE_HISTOGRAM:
+ // The classic Prometheus text format has no notion of a gauge
+ // histogram. We render a gauge histogram in the same way as a
+ // regular histogram.
n, err = w.WriteString(" histogram\n")
default:
return written, fmt.Errorf("unknown metric type %s", metricType.String())
}
written += n
if err != nil {
- return
+ return written, err
}
// Finally the samples, one line for each.
@@ -208,7 +211,7 @@ func MetricFamilyToText(out io.Writer, in *dto.MetricFamily) (written int, err e
)
written += n
if err != nil {
- return
+ return written, err
}
}
n, err = writeSample(
@@ -217,13 +220,13 @@ func MetricFamilyToText(out io.Writer, in *dto.MetricFamily) (written int, err e
)
written += n
if err != nil {
- return
+ return written, err
}
n, err = writeSample(
w, name, "_count", metric, "", 0,
float64(metric.Summary.GetSampleCount()),
)
- case dto.MetricType_HISTOGRAM:
+ case dto.MetricType_HISTOGRAM, dto.MetricType_GAUGE_HISTOGRAM:
if metric.Histogram == nil {
return written, fmt.Errorf(
"expected histogram in metric %s %s", name, metric,
@@ -231,28 +234,36 @@ func MetricFamilyToText(out io.Writer, in *dto.MetricFamily) (written int, err e
}
infSeen := false
for _, b := range metric.Histogram.Bucket {
+ v := b.GetCumulativeCountFloat()
+ if v == 0 {
+ v = float64(b.GetCumulativeCount())
+ }
n, err = writeSample(
w, name, "_bucket", metric,
model.BucketLabel, b.GetUpperBound(),
- float64(b.GetCumulativeCount()),
+ v,
)
written += n
if err != nil {
- return
+ return written, err
}
if math.IsInf(b.GetUpperBound(), +1) {
infSeen = true
}
}
if !infSeen {
+ v := metric.Histogram.GetSampleCountFloat()
+ if v == 0 {
+ v = float64(metric.Histogram.GetSampleCount())
+ }
n, err = writeSample(
w, name, "_bucket", metric,
model.BucketLabel, math.Inf(+1),
- float64(metric.Histogram.GetSampleCount()),
+ v,
)
written += n
if err != nil {
- return
+ return written, err
}
}
n, err = writeSample(
@@ -261,12 +272,13 @@ func MetricFamilyToText(out io.Writer, in *dto.MetricFamily) (written int, err e
)
written += n
if err != nil {
- return
+ return written, err
}
- n, err = writeSample(
- w, name, "_count", metric, "", 0,
- float64(metric.Histogram.GetSampleCount()),
- )
+ v := metric.Histogram.GetSampleCountFloat()
+ if v == 0 {
+ v = float64(metric.Histogram.GetSampleCount())
+ }
+ n, err = writeSample(w, name, "_count", metric, "", 0, v)
default:
return written, fmt.Errorf(
"unexpected type in metric %s %s", name, metric,
@@ -274,10 +286,10 @@ func MetricFamilyToText(out io.Writer, in *dto.MetricFamily) (written int, err e
}
written += n
if err != nil {
- return
+ return written, err
}
}
- return
+ return written, err
}
// writeSample writes a single sample in text format to w, given the metric
diff --git a/vendor/github.com/prometheus/common/expfmt/text_parse.go b/vendor/github.com/prometheus/common/expfmt/text_parse.go
index 8f2edde324..00c8841a10 100644
--- a/vendor/github.com/prometheus/common/expfmt/text_parse.go
+++ b/vendor/github.com/prometheus/common/expfmt/text_parse.go
@@ -48,8 +48,10 @@ func (e ParseError) Error() string {
return fmt.Sprintf("text format parsing error in line %d: %s", e.Line, e.Msg)
}
-// TextParser is used to parse the simple and flat text-based exchange format. Its
-// zero value is ready to use.
+// TextParser is used to parse the simple and flat text-based exchange format.
+//
+// TextParser instances must be created with NewTextParser, the zero value of
+// TextParser is invalid.
type TextParser struct {
metricFamiliesByName map[string]*dto.MetricFamily
buf *bufio.Reader // Where the parsed input is read through.
@@ -129,9 +131,44 @@ func (p *TextParser) TextToMetricFamilies(in io.Reader) (map[string]*dto.MetricF
if p.err != nil && errors.Is(p.err, io.EOF) {
p.parseError("unexpected end of input stream")
}
+ for _, histogramMetric := range p.histograms {
+ normalizeHistogram(histogramMetric.GetHistogram())
+ }
return p.metricFamiliesByName, p.err
}
+// normalizeHistogram makes sure that all the buckets and the count in each
+// histogram is either completely float or completely integer.
+func normalizeHistogram(histogram *dto.Histogram) {
+ if histogram == nil {
+ return
+ }
+ anyFloats := false
+ if histogram.GetSampleCountFloat() != 0 {
+ anyFloats = true
+ } else {
+ for _, b := range histogram.GetBucket() {
+ if b.GetCumulativeCountFloat() != 0 {
+ anyFloats = true
+ break
+ }
+ }
+ }
+ if !anyFloats {
+ return
+ }
+ if histogram.GetSampleCountFloat() == 0 {
+ histogram.SampleCountFloat = proto.Float64(float64(histogram.GetSampleCount()))
+ histogram.SampleCount = nil
+ }
+ for _, b := range histogram.GetBucket() {
+ if b.GetCumulativeCountFloat() == 0 {
+ b.CumulativeCountFloat = proto.Float64(float64(b.GetCumulativeCount()))
+ b.CumulativeCount = nil
+ }
+ }
+}
+
func (p *TextParser) reset(in io.Reader) {
p.metricFamiliesByName = map[string]*dto.MetricFamily{}
p.currentLabelPairs = nil
@@ -281,7 +318,9 @@ func (p *TextParser) readingLabels() stateFn {
// Summaries/histograms are special. We have to reset the
// currentLabels map, currentQuantile and currentBucket before starting to
// read labels.
- if p.currentMF.GetType() == dto.MetricType_SUMMARY || p.currentMF.GetType() == dto.MetricType_HISTOGRAM {
+ if p.currentMF.GetType() == dto.MetricType_SUMMARY ||
+ p.currentMF.GetType() == dto.MetricType_HISTOGRAM ||
+ p.currentMF.GetType() == dto.MetricType_GAUGE_HISTOGRAM {
p.currentLabels = map[string]string{}
p.currentLabels[string(model.MetricNameLabel)] = p.currentMF.GetName()
p.currentQuantile = math.NaN()
@@ -374,7 +413,9 @@ func (p *TextParser) startLabelName() stateFn {
// Special summary/histogram treatment. Don't add 'quantile' and 'le'
// labels to 'real' labels.
if (p.currentMF.GetType() != dto.MetricType_SUMMARY || p.currentLabelPair.GetName() != model.QuantileLabel) &&
- (p.currentMF.GetType() != dto.MetricType_HISTOGRAM || p.currentLabelPair.GetName() != model.BucketLabel) {
+ ((p.currentMF.GetType() != dto.MetricType_HISTOGRAM &&
+ p.currentMF.GetType() != dto.MetricType_GAUGE_HISTOGRAM) ||
+ p.currentLabelPair.GetName() != model.BucketLabel) {
p.currentLabelPairs = append(p.currentLabelPairs, p.currentLabelPair)
}
// Check for duplicate label names.
@@ -425,7 +466,7 @@ func (p *TextParser) startLabelValue() stateFn {
}
}
// Similar special treatment of histograms.
- if p.currentMF.GetType() == dto.MetricType_HISTOGRAM {
+ if p.currentMF.GetType() == dto.MetricType_HISTOGRAM || p.currentMF.GetType() == dto.MetricType_GAUGE_HISTOGRAM {
if p.currentLabelPair.GetName() == model.BucketLabel {
if p.currentBucket, p.err = parseFloat(p.currentLabelPair.GetValue()); p.err != nil {
// Create a more helpful error message.
@@ -476,7 +517,7 @@ func (p *TextParser) readingValue() stateFn {
p.summaries[signature] = p.currentMetric
p.currentMF.Metric = append(p.currentMF.Metric, p.currentMetric)
}
- case dto.MetricType_HISTOGRAM:
+ case dto.MetricType_HISTOGRAM, dto.MetricType_GAUGE_HISTOGRAM:
signature := model.LabelsToSignature(p.currentLabels)
if histogram := p.histograms[signature]; histogram != nil {
p.currentMetric = histogram
@@ -522,24 +563,38 @@ func (p *TextParser) readingValue() stateFn {
},
)
}
- case dto.MetricType_HISTOGRAM:
+ case dto.MetricType_HISTOGRAM, dto.MetricType_GAUGE_HISTOGRAM:
// *sigh*
if p.currentMetric.Histogram == nil {
p.currentMetric.Histogram = &dto.Histogram{}
}
switch {
case p.currentIsHistogramCount:
- p.currentMetric.Histogram.SampleCount = proto.Uint64(uint64(value))
+ if uintValue := uint64(value); value == float64(uintValue) {
+ p.currentMetric.Histogram.SampleCount = proto.Uint64(uintValue)
+ } else {
+ if value < 0 {
+ p.parseError(fmt.Sprintf("negative count for histogram %q", p.currentMF.GetName()))
+ return nil
+ }
+ p.currentMetric.Histogram.SampleCountFloat = proto.Float64(value)
+ }
case p.currentIsHistogramSum:
p.currentMetric.Histogram.SampleSum = proto.Float64(value)
case !math.IsNaN(p.currentBucket):
- p.currentMetric.Histogram.Bucket = append(
- p.currentMetric.Histogram.Bucket,
- &dto.Bucket{
- UpperBound: proto.Float64(p.currentBucket),
- CumulativeCount: proto.Uint64(uint64(value)),
- },
- )
+ b := &dto.Bucket{
+ UpperBound: proto.Float64(p.currentBucket),
+ }
+ if uintValue := uint64(value); value == float64(uintValue) {
+ b.CumulativeCount = proto.Uint64(uintValue)
+ } else {
+ if value < 0 {
+ p.parseError(fmt.Sprintf("negative bucket population for histogram %q", p.currentMF.GetName()))
+ return nil
+ }
+ b.CumulativeCountFloat = proto.Float64(value)
+ }
+ p.currentMetric.Histogram.Bucket = append(p.currentMetric.Histogram.Bucket, b)
}
default:
p.err = fmt.Errorf("unexpected type for metric name %q", p.currentMF.GetName())
@@ -602,10 +657,18 @@ func (p *TextParser) readingType() stateFn {
if p.readTokenUntilNewline(false); p.err != nil {
return nil // Unexpected end of input.
}
- metricType, ok := dto.MetricType_value[strings.ToUpper(p.currentToken.String())]
+ typ := strings.ToUpper(p.currentToken.String()) // Tolerate any combination of upper and lower case.
+ metricType, ok := dto.MetricType_value[typ] // Tolerate "gauge_histogram" (not originally part of the text format).
if !ok {
- p.parseError(fmt.Sprintf("unknown metric type %q", p.currentToken.String()))
- return nil
+ // We also want to tolerate "gaugehistogram" to mark a gauge
+ // histogram, because that string is used in OpenMetrics. Note,
+ // however, that gauge histograms do not officially exist in the
+ // classic text format.
+ if typ != "GAUGEHISTOGRAM" {
+ p.parseError(fmt.Sprintf("unknown metric type %q", p.currentToken.String()))
+ return nil
+ }
+ metricType = int32(dto.MetricType_GAUGE_HISTOGRAM)
}
p.currentMF.Type = dto.MetricType(metricType).Enum()
return p.startOfLine
@@ -855,7 +918,8 @@ func (p *TextParser) setOrCreateCurrentMF() {
}
histogramName := histogramMetricName(name)
if p.currentMF = p.metricFamiliesByName[histogramName]; p.currentMF != nil {
- if p.currentMF.GetType() == dto.MetricType_HISTOGRAM {
+ if p.currentMF.GetType() == dto.MetricType_HISTOGRAM ||
+ p.currentMF.GetType() == dto.MetricType_GAUGE_HISTOGRAM {
if isCount(name) {
p.currentIsHistogramCount = true
}
diff --git a/vendor/github.com/prometheus/procfs/.golangci.yml b/vendor/github.com/prometheus/procfs/.golangci.yml
index 3c3bf910fd..23ecd4505b 100644
--- a/vendor/github.com/prometheus/procfs/.golangci.yml
+++ b/vendor/github.com/prometheus/procfs/.golangci.yml
@@ -1,7 +1,9 @@
version: "2"
linters:
enable:
+ - errorlint
- forbidigo
+ - gocritic
- godot
- misspell
- revive
@@ -11,6 +13,20 @@ linters:
forbid:
- pattern: ^fmt\.Print.*$
msg: Do not commit print statements.
+ gocritic:
+ enable-all: true
+ disabled-checks:
+ - commentFormatting
+ - commentedOutCode
+ - deferInLoop
+ - filepathJoin
+ - hugeParam
+ - importShadow
+ - paramTypeCombine
+ - rangeValCopy
+ - tooManyResultsChecker
+ - unnamedResult
+ - whyNoLint
godot:
exclude:
# Ignore "See: URL".
@@ -19,16 +35,12 @@ linters:
misspell:
locale: US
exclusions:
- generated: lax
presets:
- comments
- common-false-positives
- legacy
- std-error-handling
- paths:
- - third_party$
- - builtin$
- - examples$
+ warn-unused: true
formatters:
enable:
- gofmt
@@ -37,9 +49,3 @@ formatters:
goimports:
local-prefixes:
- github.com/prometheus/procfs
- exclusions:
- generated: lax
- paths:
- - third_party$
- - builtin$
- - examples$
diff --git a/vendor/github.com/prometheus/procfs/Makefile b/vendor/github.com/prometheus/procfs/Makefile
index 7edfe4d093..bce50a19c5 100644
--- a/vendor/github.com/prometheus/procfs/Makefile
+++ b/vendor/github.com/prometheus/procfs/Makefile
@@ -1,4 +1,4 @@
-# Copyright 2018 The Prometheus Authors
+# Copyright The Prometheus Authors
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/Makefile.common b/vendor/github.com/prometheus/procfs/Makefile.common
index 0ed55c2ba2..6f61bec48f 100644
--- a/vendor/github.com/prometheus/procfs/Makefile.common
+++ b/vendor/github.com/prometheus/procfs/Makefile.common
@@ -33,7 +33,7 @@ GOHOSTOS ?= $(shell $(GO) env GOHOSTOS)
GOHOSTARCH ?= $(shell $(GO) env GOHOSTARCH)
GO_VERSION ?= $(shell $(GO) version)
-GO_VERSION_NUMBER ?= $(word 3, $(GO_VERSION))Error Parsing File
+GO_VERSION_NUMBER ?= $(word 3, $(GO_VERSION))
PRE_GO_111 ?= $(shell echo $(GO_VERSION_NUMBER) | grep -E 'go1\.(10|[0-9])\.')
PROMU := $(FIRST_GOPATH)/bin/promu
@@ -61,7 +61,8 @@ PROMU_URL := https://github.com/prometheus/promu/releases/download/v$(PROMU_
SKIP_GOLANGCI_LINT :=
GOLANGCI_LINT :=
GOLANGCI_LINT_OPTS ?=
-GOLANGCI_LINT_VERSION ?= v2.0.2
+GOLANGCI_LINT_VERSION ?= v2.1.5
+GOLANGCI_FMT_OPTS ?=
# golangci-lint only supports linux, darwin and windows platforms on i386/amd64/arm64.
# windows isn't included here because of the path separator being different.
ifeq ($(GOHOSTOS),$(filter $(GOHOSTOS),linux darwin))
@@ -138,7 +139,7 @@ common-deps:
update-go-deps:
@echo ">> updating Go dependencies"
@for m in $$($(GO) list -mod=readonly -m -f '{{ if and (not .Indirect) (not .Main)}}{{.Path}}{{end}}' all); do \
- $(GO) get -d $$m; \
+ $(GO) get $$m; \
done
$(GO) mod tidy
@@ -156,9 +157,13 @@ $(GOTEST_DIR):
@mkdir -p $@
.PHONY: common-format
-common-format:
+common-format: $(GOLANGCI_LINT)
@echo ">> formatting code"
$(GO) fmt $(pkgs)
+ifdef GOLANGCI_LINT
+ @echo ">> formatting code with golangci-lint"
+ $(GOLANGCI_LINT) fmt $(GOLANGCI_FMT_OPTS)
+endif
.PHONY: common-vet
common-vet:
@@ -248,8 +253,8 @@ $(PROMU):
cp $(PROMU_TMP)/promu-$(PROMU_VERSION).$(GO_BUILD_PLATFORM)/promu $(FIRST_GOPATH)/bin/promu
rm -r $(PROMU_TMP)
-.PHONY: proto
-proto:
+.PHONY: common-proto
+common-proto:
@echo ">> generating code from proto files"
@./scripts/genproto.sh
diff --git a/vendor/github.com/prometheus/procfs/arp.go b/vendor/github.com/prometheus/procfs/arp.go
index 2e53344151..716bdef109 100644
--- a/vendor/github.com/prometheus/procfs/arp.go
+++ b/vendor/github.com/prometheus/procfs/arp.go
@@ -1,4 +1,4 @@
-// Copyright 2019 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
@@ -73,15 +73,16 @@ func parseARPEntries(data []byte) ([]ARPEntry, error) {
columns := strings.Fields(line)
width := len(columns)
- if width == expectedHeaderWidth || width == 0 {
+ switch width {
+ case expectedHeaderWidth, 0:
continue
- } else if width == expectedDataWidth {
+ case expectedDataWidth:
entry, err := parseARPEntry(columns)
if err != nil {
return []ARPEntry{}, fmt.Errorf("%w: Failed to parse ARP entry: %v: %w", ErrFileParse, entry, err)
}
entries = append(entries, entry)
- } else {
+ default:
return []ARPEntry{}, fmt.Errorf("%w: %d columns found, but expected %d: %w", ErrFileParse, width, expectedDataWidth, err)
}
diff --git a/vendor/github.com/prometheus/procfs/buddyinfo.go b/vendor/github.com/prometheus/procfs/buddyinfo.go
index 8380750090..53243e6875 100644
--- a/vendor/github.com/prometheus/procfs/buddyinfo.go
+++ b/vendor/github.com/prometheus/procfs/buddyinfo.go
@@ -1,4 +1,4 @@
-// Copyright 2017 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
@@ -64,14 +64,12 @@ func parseBuddyInfo(r io.Reader) ([]BuddyInfo, error) {
if bucketCount == -1 {
bucketCount = arraySize
- } else {
- if bucketCount != arraySize {
- return nil, fmt.Errorf("%w: mismatch in number of buddyinfo buckets, previous count %d, new count %d", ErrFileParse, bucketCount, arraySize)
- }
+ } else if bucketCount != arraySize {
+ return nil, fmt.Errorf("%w: mismatch in number of buddyinfo buckets, previous count %d, new count %d", ErrFileParse, bucketCount, arraySize)
}
sizes := make([]float64, arraySize)
- for i := 0; i < arraySize; i++ {
+ for i := range arraySize {
sizes[i], err = strconv.ParseFloat(parts[i+4], 64)
if err != nil {
return nil, fmt.Errorf("%w: Invalid valid in buddyinfo: %f: %w", ErrFileParse, sizes[i], err)
diff --git a/vendor/github.com/prometheus/procfs/cmdline.go b/vendor/github.com/prometheus/procfs/cmdline.go
index bf4f3b48c0..4f1cac1f0a 100644
--- a/vendor/github.com/prometheus/procfs/cmdline.go
+++ b/vendor/github.com/prometheus/procfs/cmdline.go
@@ -1,4 +1,4 @@
-// Copyright 2021 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/cpuinfo.go b/vendor/github.com/prometheus/procfs/cpuinfo.go
index f0950bb495..5fe6cecd3d 100644
--- a/vendor/github.com/prometheus/procfs/cpuinfo.go
+++ b/vendor/github.com/prometheus/procfs/cpuinfo.go
@@ -1,4 +1,4 @@
-// Copyright 2019 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/cpuinfo_armx.go b/vendor/github.com/prometheus/procfs/cpuinfo_armx.go
index 64cfd534c1..8f155551e5 100644
--- a/vendor/github.com/prometheus/procfs/cpuinfo_armx.go
+++ b/vendor/github.com/prometheus/procfs/cpuinfo_armx.go
@@ -1,4 +1,4 @@
-// Copyright 2020 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/cpuinfo_loong64.go b/vendor/github.com/prometheus/procfs/cpuinfo_loong64.go
index d88442f0ed..e81a5db949 100644
--- a/vendor/github.com/prometheus/procfs/cpuinfo_loong64.go
+++ b/vendor/github.com/prometheus/procfs/cpuinfo_loong64.go
@@ -1,4 +1,4 @@
-// Copyright 2022 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/cpuinfo_mipsx.go b/vendor/github.com/prometheus/procfs/cpuinfo_mipsx.go
index c11207f3ab..4be2b1cc54 100644
--- a/vendor/github.com/prometheus/procfs/cpuinfo_mipsx.go
+++ b/vendor/github.com/prometheus/procfs/cpuinfo_mipsx.go
@@ -1,4 +1,4 @@
-// Copyright 2020 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/cpuinfo_others.go b/vendor/github.com/prometheus/procfs/cpuinfo_others.go
index a6b2b3127c..e713bae8df 100644
--- a/vendor/github.com/prometheus/procfs/cpuinfo_others.go
+++ b/vendor/github.com/prometheus/procfs/cpuinfo_others.go
@@ -1,4 +1,4 @@
-// Copyright 2020 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/cpuinfo_ppcx.go b/vendor/github.com/prometheus/procfs/cpuinfo_ppcx.go
index 003bc2ad4a..0825aa1a83 100644
--- a/vendor/github.com/prometheus/procfs/cpuinfo_ppcx.go
+++ b/vendor/github.com/prometheus/procfs/cpuinfo_ppcx.go
@@ -1,4 +1,4 @@
-// Copyright 2020 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/cpuinfo_riscvx.go b/vendor/github.com/prometheus/procfs/cpuinfo_riscvx.go
index 1c9b7313b6..496770b05f 100644
--- a/vendor/github.com/prometheus/procfs/cpuinfo_riscvx.go
+++ b/vendor/github.com/prometheus/procfs/cpuinfo_riscvx.go
@@ -1,4 +1,4 @@
-// Copyright 2020 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/cpuinfo_s390x.go b/vendor/github.com/prometheus/procfs/cpuinfo_s390x.go
index fa3686bc00..b3228ce3d8 100644
--- a/vendor/github.com/prometheus/procfs/cpuinfo_s390x.go
+++ b/vendor/github.com/prometheus/procfs/cpuinfo_s390x.go
@@ -1,4 +1,4 @@
-// Copyright 2020 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/cpuinfo_x86.go b/vendor/github.com/prometheus/procfs/cpuinfo_x86.go
index a0ef55562e..575eb022eb 100644
--- a/vendor/github.com/prometheus/procfs/cpuinfo_x86.go
+++ b/vendor/github.com/prometheus/procfs/cpuinfo_x86.go
@@ -1,4 +1,4 @@
-// Copyright 2020 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/crypto.go b/vendor/github.com/prometheus/procfs/crypto.go
index 5f2a37a78b..e4a5876eaf 100644
--- a/vendor/github.com/prometheus/procfs/crypto.go
+++ b/vendor/github.com/prometheus/procfs/crypto.go
@@ -1,4 +1,4 @@
-// Copyright 2019 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/doc.go b/vendor/github.com/prometheus/procfs/doc.go
index f9d961e441..26bfea071b 100644
--- a/vendor/github.com/prometheus/procfs/doc.go
+++ b/vendor/github.com/prometheus/procfs/doc.go
@@ -1,4 +1,4 @@
-// Copyright 2014 Prometheus Team
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/fs.go b/vendor/github.com/prometheus/procfs/fs.go
index 9bdaccc7c8..8f27912a13 100644
--- a/vendor/github.com/prometheus/procfs/fs.go
+++ b/vendor/github.com/prometheus/procfs/fs.go
@@ -1,4 +1,4 @@
-// Copyright 2018 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/fs_statfs_notype.go b/vendor/github.com/prometheus/procfs/fs_statfs_notype.go
index 1b5bdbdf84..3c53023c54 100644
--- a/vendor/github.com/prometheus/procfs/fs_statfs_notype.go
+++ b/vendor/github.com/prometheus/procfs/fs_statfs_notype.go
@@ -1,4 +1,4 @@
-// Copyright 2018 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/fs_statfs_type.go b/vendor/github.com/prometheus/procfs/fs_statfs_type.go
index 80df79c319..80fce48478 100644
--- a/vendor/github.com/prometheus/procfs/fs_statfs_type.go
+++ b/vendor/github.com/prometheus/procfs/fs_statfs_type.go
@@ -1,4 +1,4 @@
-// Copyright 2018 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/fscache.go b/vendor/github.com/prometheus/procfs/fscache.go
index 7db8633077..9dde857073 100644
--- a/vendor/github.com/prometheus/procfs/fscache.go
+++ b/vendor/github.com/prometheus/procfs/fscache.go
@@ -1,4 +1,4 @@
-// Copyright 2019 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
@@ -388,20 +388,21 @@ func parseFscacheinfo(r io.Reader) (*Fscacheinfo, error) {
}
}
case "CacheOp:":
- if strings.Split(fields[1], "=")[0] == "alo" {
+ switch strings.Split(fields[1], "=")[0] {
+ case "alo":
err := setFSCacheFields(fields[1:], &m.CacheopAllocationsinProgress, &m.CacheopLookupObjectInProgress,
&m.CacheopLookupCompleteInPorgress, &m.CacheopGrabObjectInProgress)
if err != nil {
return &m, err
}
- } else if strings.Split(fields[1], "=")[0] == "inv" {
+ case "inv":
err := setFSCacheFields(fields[1:], &m.CacheopInvalidations, &m.CacheopUpdateObjectInProgress,
&m.CacheopDropObjectInProgress, &m.CacheopPutObjectInProgress, &m.CacheopAttributeChangeInProgress,
&m.CacheopSyncCacheInProgress)
if err != nil {
return &m, err
}
- } else {
+ default:
err := setFSCacheFields(fields[1:], &m.CacheopReadOrAllocPageInProgress, &m.CacheopReadOrAllocPagesInProgress,
&m.CacheopAllocatePageInProgress, &m.CacheopAllocatePagesInProgress, &m.CacheopWritePagesInProgress,
&m.CacheopUncachePagesInProgress, &m.CacheopDissociatePagesInProgress)
diff --git a/vendor/github.com/prometheus/procfs/internal/fs/fs.go b/vendor/github.com/prometheus/procfs/internal/fs/fs.go
index 3a43e83915..e7ccad66b2 100644
--- a/vendor/github.com/prometheus/procfs/internal/fs/fs.go
+++ b/vendor/github.com/prometheus/procfs/internal/fs/fs.go
@@ -1,4 +1,4 @@
-// Copyright 2019 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/internal/util/parse.go b/vendor/github.com/prometheus/procfs/internal/util/parse.go
index 5a7d2df06a..30c5872019 100644
--- a/vendor/github.com/prometheus/procfs/internal/util/parse.go
+++ b/vendor/github.com/prometheus/procfs/internal/util/parse.go
@@ -1,4 +1,4 @@
-// Copyright 2018 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/internal/util/readfile.go b/vendor/github.com/prometheus/procfs/internal/util/readfile.go
index 71b7a70ebd..0e41f71af1 100644
--- a/vendor/github.com/prometheus/procfs/internal/util/readfile.go
+++ b/vendor/github.com/prometheus/procfs/internal/util/readfile.go
@@ -1,4 +1,4 @@
-// Copyright 2019 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/internal/util/sysreadfile.go b/vendor/github.com/prometheus/procfs/internal/util/sysreadfile.go
index d5404a6d72..8318d8dfd5 100644
--- a/vendor/github.com/prometheus/procfs/internal/util/sysreadfile.go
+++ b/vendor/github.com/prometheus/procfs/internal/util/sysreadfile.go
@@ -1,4 +1,4 @@
-// Copyright 2018 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/internal/util/sysreadfile_compat.go b/vendor/github.com/prometheus/procfs/internal/util/sysreadfile_compat.go
index 1d86f5e63f..15bb096ee2 100644
--- a/vendor/github.com/prometheus/procfs/internal/util/sysreadfile_compat.go
+++ b/vendor/github.com/prometheus/procfs/internal/util/sysreadfile_compat.go
@@ -1,4 +1,4 @@
-// Copyright 2019 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/internal/util/valueparser.go b/vendor/github.com/prometheus/procfs/internal/util/valueparser.go
index fe2355d3c6..e0ed671ea0 100644
--- a/vendor/github.com/prometheus/procfs/internal/util/valueparser.go
+++ b/vendor/github.com/prometheus/procfs/internal/util/valueparser.go
@@ -1,4 +1,4 @@
-// Copyright 2019 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/ipvs.go b/vendor/github.com/prometheus/procfs/ipvs.go
index bc3a20c932..5374da9fa8 100644
--- a/vendor/github.com/prometheus/procfs/ipvs.go
+++ b/vendor/github.com/prometheus/procfs/ipvs.go
@@ -1,4 +1,4 @@
-// Copyright 2018 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/kernel_hung.go b/vendor/github.com/prometheus/procfs/kernel_hung.go
new file mode 100644
index 0000000000..539c111514
--- /dev/null
+++ b/vendor/github.com/prometheus/procfs/kernel_hung.go
@@ -0,0 +1,45 @@
+// Copyright The Prometheus Authors
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+//go:build !windows
+// +build !windows
+
+package procfs
+
+import (
+ "os"
+ "strconv"
+ "strings"
+)
+
+// KernelHung contains information about to the kernel's hung_task_detect_count number.
+type KernelHung struct {
+ // Indicates the total number of tasks that have been detected as hung since the system boot.
+ // This file shows up if `CONFIG_DETECT_HUNG_TASK` is enabled.
+ HungTaskDetectCount *uint64
+}
+
+// KernelHung returns values from /proc/sys/kernel/hung_task_detect_count.
+func (fs FS) KernelHung() (KernelHung, error) {
+ data, err := os.ReadFile(fs.proc.Path("sys", "kernel", "hung_task_detect_count"))
+ if err != nil {
+ return KernelHung{}, err
+ }
+ val, err := strconv.ParseUint(strings.TrimSpace(string(data)), 10, 64)
+ if err != nil {
+ return KernelHung{}, err
+ }
+ return KernelHung{
+ HungTaskDetectCount: &val,
+ }, nil
+}
diff --git a/vendor/github.com/prometheus/procfs/kernel_random.go b/vendor/github.com/prometheus/procfs/kernel_random.go
index db88566bdf..b66565a104 100644
--- a/vendor/github.com/prometheus/procfs/kernel_random.go
+++ b/vendor/github.com/prometheus/procfs/kernel_random.go
@@ -1,4 +1,4 @@
-// Copyright 2020 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/loadavg.go b/vendor/github.com/prometheus/procfs/loadavg.go
index 332e76c17f..c8c78a65ed 100644
--- a/vendor/github.com/prometheus/procfs/loadavg.go
+++ b/vendor/github.com/prometheus/procfs/loadavg.go
@@ -1,4 +1,4 @@
-// Copyright 2019 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/mdstat.go b/vendor/github.com/prometheus/procfs/mdstat.go
index 67a9d2b448..d66eeda82a 100644
--- a/vendor/github.com/prometheus/procfs/mdstat.go
+++ b/vendor/github.com/prometheus/procfs/mdstat.go
@@ -1,4 +1,4 @@
-// Copyright 2018 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
@@ -27,13 +27,34 @@ var (
recoveryLinePctRE = regexp.MustCompile(`= (.+)%`)
recoveryLineFinishRE = regexp.MustCompile(`finish=(.+)min`)
recoveryLineSpeedRE = regexp.MustCompile(`speed=(.+)[A-Z]`)
- componentDeviceRE = regexp.MustCompile(`(.*)\[\d+\]`)
+ componentDeviceRE = regexp.MustCompile(`(.*)\[(\d+)\](\([SF]+\))?`)
+ personalitiesPrefix = "Personalities : "
)
+type MDStatComponent struct {
+ // Name of the component device.
+ Name string
+ // DescriptorIndex number of component device, e.g. the order in the superblock.
+ DescriptorIndex int32
+ // Flags per Linux drivers/md/md.[ch] as of v6.12-rc1
+ // Subset that are exposed in mdstat
+ WriteMostly bool
+ Journal bool
+ Faulty bool // "Faulty" is what kernel source uses for "(F)"
+ Spare bool
+ Replacement bool
+ // Some additional flags that are NOT exposed in procfs today; they may
+ // be available via sysfs.
+ // In_sync, Bitmap_sync, Blocked, WriteErrorSeen, FaultRecorded,
+ // BlockedBadBlocks, WantReplacement, Candidate, ...
+}
+
// MDStat holds info parsed from /proc/mdstat.
type MDStat struct {
// Name of the device.
Name string
+ // raid type of the device.
+ Type string
// activity-state of the device.
ActivityState string
// Number of active disks.
@@ -58,8 +79,8 @@ type MDStat struct {
BlocksSyncedFinishTime float64
// current sync speed (in Kilobytes/sec)
BlocksSyncedSpeed float64
- // Name of md component devices
- Devices []string
+ // component devices
+ Devices []MDStatComponent
}
// MDStat parses an mdstat-file (/proc/mdstat) and returns a slice of
@@ -80,28 +101,52 @@ func (fs FS) MDStat() ([]MDStat, error) {
// parseMDStat parses data from mdstat file (/proc/mdstat) and returns a slice of
// structs containing the relevant info.
func parseMDStat(mdStatData []byte) ([]MDStat, error) {
+ // TODO:
+ // - parse global hotspares from the "unused devices" line.
mdStats := []MDStat{}
lines := strings.Split(string(mdStatData), "\n")
+ knownRaidTypes := make(map[string]bool)
for i, line := range lines {
if strings.TrimSpace(line) == "" || line[0] == ' ' ||
- strings.HasPrefix(line, "Personalities") ||
strings.HasPrefix(line, "unused") {
continue
}
+ // Personalities : [linear] [multipath] [raid0] [raid1] [raid6] [raid5] [raid4] [raid10]
+ if len(knownRaidTypes) == 0 && strings.HasPrefix(line, personalitiesPrefix) {
+ personalities := strings.Fields(line[len(personalitiesPrefix):])
+ for _, word := range personalities {
+ word := word[1 : len(word)-1]
+ knownRaidTypes[word] = true
+ }
+ continue
+ }
deviceFields := strings.Fields(line)
if len(deviceFields) < 3 {
return nil, fmt.Errorf("%w: Expected 3+ lines, got %q", ErrFileParse, line)
}
mdName := deviceFields[0] // mdx
- state := deviceFields[2] // active or inactive
+ state := deviceFields[2] // active, inactive, broken
+
+ mdType := "unknown" // raid1, raid5, etc.
+ var deviceStartIndex int
+ if len(deviceFields) > 3 { // mdType may be in the 3rd or 4th field
+ if isRaidType(deviceFields[3], knownRaidTypes) {
+ mdType = deviceFields[3]
+ deviceStartIndex = 4
+ } else if len(deviceFields) > 4 && isRaidType(deviceFields[4], knownRaidTypes) {
+ // if the 3rd field is (...), the 4th field is the mdType
+ mdType = deviceFields[4]
+ deviceStartIndex = 5
+ }
+ }
if len(lines) <= i+3 {
return nil, fmt.Errorf("%w: Too few lines for md device: %q", ErrFileParse, mdName)
}
- // Failed disks have the suffix (F) & Spare disks have the suffix (S).
+ // Failed (Faulty) disks have the suffix (F) & Spare disks have the suffix (S).
fail := int64(strings.Count(line, "(F)"))
spare := int64(strings.Count(line, "(S)"))
active, total, down, size, err := evalStatusLine(lines[i], lines[i+1])
@@ -123,16 +168,20 @@ func parseMDStat(mdStatData []byte) ([]MDStat, error) {
finish := float64(0)
pct := float64(0)
recovering := strings.Contains(lines[syncLineIdx], "recovery")
+ reshaping := strings.Contains(lines[syncLineIdx], "reshape")
resyncing := strings.Contains(lines[syncLineIdx], "resync")
checking := strings.Contains(lines[syncLineIdx], "check")
// Append recovery and resyncing state info.
- if recovering || resyncing || checking {
- if recovering {
+ if recovering || resyncing || checking || reshaping {
+ switch {
+ case recovering:
state = "recovering"
- } else if checking {
+ case reshaping:
+ state = "reshaping"
+ case checking:
state = "checking"
- } else {
+ default:
state = "resyncing"
}
@@ -148,8 +197,14 @@ func parseMDStat(mdStatData []byte) ([]MDStat, error) {
}
}
+ devices, err := evalComponentDevices(deviceFields[deviceStartIndex:])
+ if err != nil {
+ return nil, fmt.Errorf("error parsing components in md device %q: %w", mdName, err)
+ }
+
mdStats = append(mdStats, MDStat{
Name: mdName,
+ Type: mdType,
ActivityState: state,
DisksActive: active,
DisksFailed: fail,
@@ -162,14 +217,24 @@ func parseMDStat(mdStatData []byte) ([]MDStat, error) {
BlocksSyncedPct: pct,
BlocksSyncedFinishTime: finish,
BlocksSyncedSpeed: speed,
- Devices: evalComponentDevices(deviceFields),
+ Devices: devices,
})
}
return mdStats, nil
}
+// check if a string's format is like the mdType
+// Rule 1: mdType should not be like (...)
+// Rule 2: mdType should not be like sda[0]
+// .
+func isRaidType(mdType string, knownRaidTypes map[string]bool) bool {
+ _, ok := knownRaidTypes[mdType]
+ return !strings.ContainsAny(mdType, "([") && ok
+}
+
func evalStatusLine(deviceLine, statusLine string) (active, total, down, size int64, err error) {
+ // e.g. 523968 blocks super 1.2 [4/4] [UUUU]
statusFields := strings.Fields(statusLine)
if len(statusFields) < 1 {
return 0, 0, 0, 0, fmt.Errorf("%w: Unexpected statusline %q: %w", ErrFileParse, statusLine, err)
@@ -260,17 +325,29 @@ func evalRecoveryLine(recoveryLine string) (blocksSynced int64, blocksToBeSynced
return blocksSynced, blocksToBeSynced, pct, finish, speed, nil
}
-func evalComponentDevices(deviceFields []string) []string {
- mdComponentDevices := make([]string, 0)
- if len(deviceFields) > 3 {
- for _, field := range deviceFields[4:] {
- match := componentDeviceRE.FindStringSubmatch(field)
- if match == nil {
- continue
- }
- mdComponentDevices = append(mdComponentDevices, match[1])
+func evalComponentDevices(deviceFields []string) ([]MDStatComponent, error) {
+ mdComponentDevices := make([]MDStatComponent, 0)
+ for _, field := range deviceFields {
+ match := componentDeviceRE.FindStringSubmatch(field)
+ if match == nil {
+ continue
+ }
+ descriptorIndex, err := strconv.ParseInt(match[2], 10, 32)
+ if err != nil {
+ return mdComponentDevices, fmt.Errorf("error parsing int from device %q: %w", match[2], err)
}
+ mdComponentDevices = append(mdComponentDevices, MDStatComponent{
+ Name: match[1],
+ DescriptorIndex: int32(descriptorIndex),
+ // match may contain one or more of these
+ // https://github.com/torvalds/linux/blob/7ec462100ef9142344ddbf86f2c3008b97acddbe/drivers/md/md.c#L8376-L8392
+ Faulty: strings.Contains(match[3], "(F)"),
+ Spare: strings.Contains(match[3], "(S)"),
+ Journal: strings.Contains(match[3], "(J)"),
+ Replacement: strings.Contains(match[3], "(R)"),
+ WriteMostly: strings.Contains(match[3], "(W)"),
+ })
}
- return mdComponentDevices
+ return mdComponentDevices, nil
}
diff --git a/vendor/github.com/prometheus/procfs/meminfo.go b/vendor/github.com/prometheus/procfs/meminfo.go
index 4b2c4050a3..3420383187 100644
--- a/vendor/github.com/prometheus/procfs/meminfo.go
+++ b/vendor/github.com/prometheus/procfs/meminfo.go
@@ -1,4 +1,4 @@
-// Copyright 2019 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
@@ -66,6 +66,10 @@ type Meminfo struct {
// Memory which has been evicted from RAM, and is temporarily
// on the disk
SwapFree *uint64
+ // Memory consumed by the zswap backend (compressed size)
+ Zswap *uint64
+ // Amount of anonymous memory stored in zswap (original size)
+ Zswapped *uint64
// Memory which is waiting to get written back to the disk
Dirty *uint64
// Memory which is actively being written back to the disk
@@ -85,6 +89,8 @@ type Meminfo struct {
// amount of memory dedicated to the lowest level of page
// tables.
PageTables *uint64
+ // secondary page tables.
+ SecPageTables *uint64
// NFS pages sent to the server, but not yet committed to
// stable storage
NFSUnstable *uint64
@@ -129,15 +135,18 @@ type Meminfo struct {
Percpu *uint64
HardwareCorrupted *uint64
AnonHugePages *uint64
+ FileHugePages *uint64
ShmemHugePages *uint64
ShmemPmdMapped *uint64
CmaTotal *uint64
CmaFree *uint64
+ Unaccepted *uint64
HugePagesTotal *uint64
HugePagesFree *uint64
HugePagesRsvd *uint64
HugePagesSurp *uint64
Hugepagesize *uint64
+ Hugetlb *uint64
DirectMap4k *uint64
DirectMap2M *uint64
DirectMap1G *uint64
@@ -161,6 +170,8 @@ type Meminfo struct {
MlockedBytes *uint64
SwapTotalBytes *uint64
SwapFreeBytes *uint64
+ ZswapBytes *uint64
+ ZswappedBytes *uint64
DirtyBytes *uint64
WritebackBytes *uint64
AnonPagesBytes *uint64
@@ -171,6 +182,7 @@ type Meminfo struct {
SUnreclaimBytes *uint64
KernelStackBytes *uint64
PageTablesBytes *uint64
+ SecPageTablesBytes *uint64
NFSUnstableBytes *uint64
BounceBytes *uint64
WritebackTmpBytes *uint64
@@ -182,11 +194,14 @@ type Meminfo struct {
PercpuBytes *uint64
HardwareCorruptedBytes *uint64
AnonHugePagesBytes *uint64
+ FileHugePagesBytes *uint64
ShmemHugePagesBytes *uint64
ShmemPmdMappedBytes *uint64
CmaTotalBytes *uint64
CmaFreeBytes *uint64
+ UnacceptedBytes *uint64
HugepagesizeBytes *uint64
+ HugetlbBytes *uint64
DirectMap4kBytes *uint64
DirectMap2MBytes *uint64
DirectMap1GBytes *uint64
@@ -287,6 +302,12 @@ func parseMemInfo(r io.Reader) (*Meminfo, error) {
case "SwapFree:":
m.SwapFree = &val
m.SwapFreeBytes = &valBytes
+ case "Zswap:":
+ m.Zswap = &val
+ m.ZswapBytes = &valBytes
+ case "Zswapped:":
+ m.Zswapped = &val
+ m.ZswappedBytes = &valBytes
case "Dirty:":
m.Dirty = &val
m.DirtyBytes = &valBytes
@@ -317,6 +338,9 @@ func parseMemInfo(r io.Reader) (*Meminfo, error) {
case "PageTables:":
m.PageTables = &val
m.PageTablesBytes = &valBytes
+ case "SecPageTables:":
+ m.SecPageTables = &val
+ m.SecPageTablesBytes = &valBytes
case "NFS_Unstable:":
m.NFSUnstable = &val
m.NFSUnstableBytes = &valBytes
@@ -350,6 +374,9 @@ func parseMemInfo(r io.Reader) (*Meminfo, error) {
case "AnonHugePages:":
m.AnonHugePages = &val
m.AnonHugePagesBytes = &valBytes
+ case "FileHugePages:":
+ m.FileHugePages = &val
+ m.FileHugePagesBytes = &valBytes
case "ShmemHugePages:":
m.ShmemHugePages = &val
m.ShmemHugePagesBytes = &valBytes
@@ -362,6 +389,9 @@ func parseMemInfo(r io.Reader) (*Meminfo, error) {
case "CmaFree:":
m.CmaFree = &val
m.CmaFreeBytes = &valBytes
+ case "Unaccepted:":
+ m.Unaccepted = &val
+ m.UnacceptedBytes = &valBytes
case "HugePages_Total:":
m.HugePagesTotal = &val
case "HugePages_Free:":
@@ -373,6 +403,9 @@ func parseMemInfo(r io.Reader) (*Meminfo, error) {
case "Hugepagesize:":
m.Hugepagesize = &val
m.HugepagesizeBytes = &valBytes
+ case "Hugetlb:":
+ m.Hugetlb = &val
+ m.HugetlbBytes = &valBytes
case "DirectMap4k:":
m.DirectMap4k = &val
m.DirectMap4kBytes = &valBytes
diff --git a/vendor/github.com/prometheus/procfs/mountinfo.go b/vendor/github.com/prometheus/procfs/mountinfo.go
index a704c5e735..9414a12f42 100644
--- a/vendor/github.com/prometheus/procfs/mountinfo.go
+++ b/vendor/github.com/prometheus/procfs/mountinfo.go
@@ -1,4 +1,4 @@
-// Copyright 2019 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
@@ -147,8 +147,7 @@ func mountOptionsParseOptionalFields(o []string) (map[string]string, error) {
// mountOptionsParser parses the mount options, superblock options.
func mountOptionsParser(mountOptions string) map[string]string {
opts := make(map[string]string)
- options := strings.Split(mountOptions, ",")
- for _, opt := range options {
+ for opt := range strings.SplitSeq(mountOptions, ",") {
splitOption := strings.Split(opt, "=")
if len(splitOption) < 2 {
key := splitOption[0]
@@ -178,3 +177,21 @@ func GetProcMounts(pid int) ([]*MountInfo, error) {
}
return parseMountInfo(data)
}
+
+// GetMounts retrieves mountinfo information from `/proc/self/mountinfo`.
+func (fs FS) GetMounts() ([]*MountInfo, error) {
+ data, err := util.ReadFileNoStat(fs.proc.Path("self/mountinfo"))
+ if err != nil {
+ return nil, err
+ }
+ return parseMountInfo(data)
+}
+
+// GetProcMounts retrieves mountinfo information from a processes' `/proc//mountinfo`.
+func (fs FS) GetProcMounts(pid int) ([]*MountInfo, error) {
+ data, err := util.ReadFileNoStat(fs.proc.Path(fmt.Sprintf("%d/mountinfo", pid)))
+ if err != nil {
+ return nil, err
+ }
+ return parseMountInfo(data)
+}
diff --git a/vendor/github.com/prometheus/procfs/mountstats.go b/vendor/github.com/prometheus/procfs/mountstats.go
index 50caa73274..e503cb3a6c 100644
--- a/vendor/github.com/prometheus/procfs/mountstats.go
+++ b/vendor/github.com/prometheus/procfs/mountstats.go
@@ -1,4 +1,4 @@
-// Copyright 2018 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
@@ -383,7 +383,7 @@ func parseMountStatsNFS(s *bufio.Scanner, statVersion string) (*MountStatsNFS, e
if stats.Opts == nil {
stats.Opts = map[string]string{}
}
- for _, opt := range strings.Split(ss[1], ",") {
+ for opt := range strings.SplitSeq(ss[1], ",") {
split := strings.Split(opt, "=")
if len(split) == 2 {
stats.Opts[split[0]] = split[1]
diff --git a/vendor/github.com/prometheus/procfs/net_conntrackstat.go b/vendor/github.com/prometheus/procfs/net_conntrackstat.go
index 316df5fbb7..e9ca357079 100644
--- a/vendor/github.com/prometheus/procfs/net_conntrackstat.go
+++ b/vendor/github.com/prometheus/procfs/net_conntrackstat.go
@@ -1,4 +1,4 @@
-// Copyright 2020 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/net_dev.go b/vendor/github.com/prometheus/procfs/net_dev.go
index e66208aa05..7b3e1d61c9 100644
--- a/vendor/github.com/prometheus/procfs/net_dev.go
+++ b/vendor/github.com/prometheus/procfs/net_dev.go
@@ -1,4 +1,4 @@
-// Copyright 2018 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/net_dev_snmp6.go b/vendor/github.com/prometheus/procfs/net_dev_snmp6.go
index f50b38e352..2a0f60f29f 100644
--- a/vendor/github.com/prometheus/procfs/net_dev_snmp6.go
+++ b/vendor/github.com/prometheus/procfs/net_dev_snmp6.go
@@ -1,4 +1,4 @@
-// Copyright 2018 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
@@ -18,6 +18,7 @@ import (
"errors"
"io"
"os"
+ "path/filepath"
"strconv"
"strings"
)
@@ -56,7 +57,9 @@ func newNetDevSNMP6(dir string) (NetDevSNMP6, error) {
}
for _, iFaceFile := range ifaceFiles {
- f, err := os.Open(dir + "/" + iFaceFile.Name())
+ filePath := filepath.Join(dir, iFaceFile.Name())
+
+ f, err := os.Open(filePath)
if err != nil {
return netDevSNMP6, err
}
diff --git a/vendor/github.com/prometheus/procfs/net_ip_socket.go b/vendor/github.com/prometheus/procfs/net_ip_socket.go
index 19e3378f72..9291f8cd4c 100644
--- a/vendor/github.com/prometheus/procfs/net_ip_socket.go
+++ b/vendor/github.com/prometheus/procfs/net_ip_socket.go
@@ -1,4 +1,4 @@
-// Copyright 2020 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/net_protocols.go b/vendor/github.com/prometheus/procfs/net_protocols.go
index 8d4b1ac05b..eaa996cbcf 100644
--- a/vendor/github.com/prometheus/procfs/net_protocols.go
+++ b/vendor/github.com/prometheus/procfs/net_protocols.go
@@ -1,4 +1,4 @@
-// Copyright 2020 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
@@ -169,7 +169,7 @@ func (pc *NetProtocolCapabilities) parseCapabilities(capabilities []string) erro
&pc.EnterMemoryPressure,
}
- for i := 0; i < len(capabilities); i++ {
+ for i := range capabilities {
switch capabilities[i] {
case "y":
*capabilityFields[i] = true
diff --git a/vendor/github.com/prometheus/procfs/net_route.go b/vendor/github.com/prometheus/procfs/net_route.go
index deb7029fe1..fa3812d9d0 100644
--- a/vendor/github.com/prometheus/procfs/net_route.go
+++ b/vendor/github.com/prometheus/procfs/net_route.go
@@ -1,4 +1,4 @@
-// Copyright 2023 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/net_sockstat.go b/vendor/github.com/prometheus/procfs/net_sockstat.go
index fae62b13d9..8b221ebfff 100644
--- a/vendor/github.com/prometheus/procfs/net_sockstat.go
+++ b/vendor/github.com/prometheus/procfs/net_sockstat.go
@@ -1,4 +1,4 @@
-// Copyright 2019 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
@@ -139,9 +139,6 @@ func parseSockstatKVs(kvs []string) (map[string]int, error) {
func parseSockstatProtocol(kvs map[string]int) NetSockstatProtocol {
var nsp NetSockstatProtocol
for k, v := range kvs {
- // Capture the range variable to ensure we get unique pointers for
- // each of the optional fields.
- v := v
switch k {
case "inuse":
nsp.InUse = v
diff --git a/vendor/github.com/prometheus/procfs/net_softnet.go b/vendor/github.com/prometheus/procfs/net_softnet.go
index 71c8059f4d..4a2dfa18fd 100644
--- a/vendor/github.com/prometheus/procfs/net_softnet.go
+++ b/vendor/github.com/prometheus/procfs/net_softnet.go
@@ -1,4 +1,4 @@
-// Copyright 2019 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/net_tcp.go b/vendor/github.com/prometheus/procfs/net_tcp.go
index 0396d72015..610ea78e56 100644
--- a/vendor/github.com/prometheus/procfs/net_tcp.go
+++ b/vendor/github.com/prometheus/procfs/net_tcp.go
@@ -1,4 +1,4 @@
-// Copyright 2020 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/net_tls_stat.go b/vendor/github.com/prometheus/procfs/net_tls_stat.go
index 13994c1782..b1b3f6a6a2 100644
--- a/vendor/github.com/prometheus/procfs/net_tls_stat.go
+++ b/vendor/github.com/prometheus/procfs/net_tls_stat.go
@@ -1,4 +1,4 @@
-// Copyright 2023 Prometheus Team
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/net_udp.go b/vendor/github.com/prometheus/procfs/net_udp.go
index 9ac3daf2d4..8a32779102 100644
--- a/vendor/github.com/prometheus/procfs/net_udp.go
+++ b/vendor/github.com/prometheus/procfs/net_udp.go
@@ -1,4 +1,4 @@
-// Copyright 2020 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/net_unix.go b/vendor/github.com/prometheus/procfs/net_unix.go
index d7e0cacb4c..e4d6359236 100644
--- a/vendor/github.com/prometheus/procfs/net_unix.go
+++ b/vendor/github.com/prometheus/procfs/net_unix.go
@@ -1,4 +1,4 @@
-// Copyright 2018 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/net_wireless.go b/vendor/github.com/prometheus/procfs/net_wireless.go
index 7c597bc870..69d0794451 100644
--- a/vendor/github.com/prometheus/procfs/net_wireless.go
+++ b/vendor/github.com/prometheus/procfs/net_wireless.go
@@ -1,4 +1,4 @@
-// Copyright 2023 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/net_xfrm.go b/vendor/github.com/prometheus/procfs/net_xfrm.go
index 932ef20468..5a9f497d19 100644
--- a/vendor/github.com/prometheus/procfs/net_xfrm.go
+++ b/vendor/github.com/prometheus/procfs/net_xfrm.go
@@ -1,4 +1,4 @@
-// Copyright 2017 Prometheus Team
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/netstat.go b/vendor/github.com/prometheus/procfs/netstat.go
index 742dff453b..dbdae47392 100644
--- a/vendor/github.com/prometheus/procfs/netstat.go
+++ b/vendor/github.com/prometheus/procfs/netstat.go
@@ -1,4 +1,4 @@
-// Copyright 2020 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/nfnetlink_queue.go b/vendor/github.com/prometheus/procfs/nfnetlink_queue.go
new file mode 100644
index 0000000000..b0a73b11e9
--- /dev/null
+++ b/vendor/github.com/prometheus/procfs/nfnetlink_queue.go
@@ -0,0 +1,85 @@
+// Copyright The Prometheus Authors
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+package procfs
+
+import (
+ "bufio"
+ "bytes"
+ "fmt"
+
+ "github.com/prometheus/procfs/internal/util"
+)
+
+const nfNetLinkQueueFormat = "%d %d %d %d %d %d %d %d %d"
+
+// NFNetLinkQueue contains general information about netfilter queues found in /proc/net/netfilter/nfnetlink_queue.
+type NFNetLinkQueue struct {
+ // id of the queue
+ QueueID uint
+ // pid of process handling the queue
+ PeerPID uint
+ // number of packets waiting for a decision
+ QueueTotal uint
+ // indicate how userspace receive packets
+ CopyMode uint
+ // size of copy
+ CopyRange uint
+ // number of items dropped by the kernel because too many packets were waiting a decision.
+ // It queue_total is superior to queue_max_len (1024 per default) the packets are dropped.
+ QueueDropped uint
+ // number of packets dropped by userspace (due to kernel send failure on the netlink socket)
+ QueueUserDropped uint
+ // sequence number of packets queued. It gives a correct approximation of the number of queued packets.
+ SequenceID uint
+ // internal value (number of entity using the queue)
+ Use uint
+}
+
+// NFNetLinkQueue returns information about current state of netfilter queues.
+func (fs FS) NFNetLinkQueue() ([]NFNetLinkQueue, error) {
+ data, err := util.ReadFileNoStat(fs.proc.Path("net/netfilter/nfnetlink_queue"))
+ if err != nil {
+ return nil, err
+ }
+
+ queue := []NFNetLinkQueue{}
+ if len(data) == 0 {
+ return queue, nil
+ }
+
+ scanner := bufio.NewScanner(bytes.NewReader(data))
+ for scanner.Scan() {
+ line := scanner.Text()
+ nFNetLinkQueue, err := parseNFNetLinkQueueLine(line)
+ if err != nil {
+ return nil, err
+ }
+ queue = append(queue, *nFNetLinkQueue)
+ }
+ return queue, nil
+}
+
+// parseNFNetLinkQueueLine parses each line of the /proc/net/netfilter/nfnetlink_queue file.
+func parseNFNetLinkQueueLine(line string) (*NFNetLinkQueue, error) {
+ nFNetLinkQueue := NFNetLinkQueue{}
+ _, err := fmt.Sscanf(
+ line, nfNetLinkQueueFormat,
+ &nFNetLinkQueue.QueueID, &nFNetLinkQueue.PeerPID, &nFNetLinkQueue.QueueTotal, &nFNetLinkQueue.CopyMode,
+ &nFNetLinkQueue.CopyRange, &nFNetLinkQueue.QueueDropped, &nFNetLinkQueue.QueueUserDropped, &nFNetLinkQueue.SequenceID, &nFNetLinkQueue.Use,
+ )
+ if err != nil {
+ return nil, err
+ }
+ return &nFNetLinkQueue, nil
+}
diff --git a/vendor/github.com/prometheus/procfs/proc.go b/vendor/github.com/prometheus/procfs/proc.go
index 368187fa88..39c14aa55e 100644
--- a/vendor/github.com/prometheus/procfs/proc.go
+++ b/vendor/github.com/prometheus/procfs/proc.go
@@ -1,4 +1,4 @@
-// Copyright 2018 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
@@ -49,7 +49,7 @@ func (p Procs) Less(i, j int) bool { return p[i].PID < p[j].PID }
// Self returns a process for the current process read via /proc/self.
func Self() (Proc, error) {
fs, err := NewFS(DefaultMountPoint)
- if err != nil || errors.Unwrap(err) == ErrMountPoint {
+ if err != nil || errors.Is(err, ErrMountPoint) {
return Proc{}, err
}
return fs.Self()
diff --git a/vendor/github.com/prometheus/procfs/proc_cgroup.go b/vendor/github.com/prometheus/procfs/proc_cgroup.go
index 4a64347c03..535c08d6fc 100644
--- a/vendor/github.com/prometheus/procfs/proc_cgroup.go
+++ b/vendor/github.com/prometheus/procfs/proc_cgroup.go
@@ -1,4 +1,4 @@
-// Copyright 2020 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/proc_cgroups.go b/vendor/github.com/prometheus/procfs/proc_cgroups.go
index 5dd4938999..0b275c3b1f 100644
--- a/vendor/github.com/prometheus/procfs/proc_cgroups.go
+++ b/vendor/github.com/prometheus/procfs/proc_cgroups.go
@@ -1,4 +1,4 @@
-// Copyright 2021 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
@@ -40,13 +40,13 @@ type CgroupSummary struct {
// parseCgroupSummary parses each line of the /proc/cgroup file
// Line format is `subsys_name hierarchy num_cgroups enabled`.
-func parseCgroupSummaryString(CgroupSummaryStr string) (*CgroupSummary, error) {
+func parseCgroupSummaryString(cgroupSummaryStr string) (*CgroupSummary, error) {
var err error
- fields := strings.Fields(CgroupSummaryStr)
+ fields := strings.Fields(cgroupSummaryStr)
// require at least 4 fields
if len(fields) < 4 {
- return nil, fmt.Errorf("%w: 4+ fields required, found %d fields in cgroup info string: %s", ErrFileParse, len(fields), CgroupSummaryStr)
+ return nil, fmt.Errorf("%w: 4+ fields required, found %d fields in cgroup info string: %s", ErrFileParse, len(fields), cgroupSummaryStr)
}
CgroupSummary := &CgroupSummary{
diff --git a/vendor/github.com/prometheus/procfs/proc_environ.go b/vendor/github.com/prometheus/procfs/proc_environ.go
index 57a89895d6..5b941de047 100644
--- a/vendor/github.com/prometheus/procfs/proc_environ.go
+++ b/vendor/github.com/prometheus/procfs/proc_environ.go
@@ -1,4 +1,4 @@
-// Copyright 2019 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/proc_fdinfo.go b/vendor/github.com/prometheus/procfs/proc_fdinfo.go
index fa761b3529..fa57761dbe 100644
--- a/vendor/github.com/prometheus/procfs/proc_fdinfo.go
+++ b/vendor/github.com/prometheus/procfs/proc_fdinfo.go
@@ -1,4 +1,4 @@
-// Copyright 2019 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
@@ -60,15 +60,16 @@ func (p Proc) FDInfo(fd string) (*ProcFDInfo, error) {
scanner := bufio.NewScanner(bytes.NewReader(data))
for scanner.Scan() {
text = scanner.Text()
- if rPos.MatchString(text) {
+ switch {
+ case rPos.MatchString(text):
pos = rPos.FindStringSubmatch(text)[1]
- } else if rFlags.MatchString(text) {
+ case rFlags.MatchString(text):
flags = rFlags.FindStringSubmatch(text)[1]
- } else if rMntID.MatchString(text) {
+ case rMntID.MatchString(text):
mntid = rMntID.FindStringSubmatch(text)[1]
- } else if rIno.MatchString(text) {
+ case rIno.MatchString(text):
ino = rIno.FindStringSubmatch(text)[1]
- } else if rInotify.MatchString(text) {
+ case rInotify.MatchString(text):
newInotify, err := parseInotifyInfo(text)
if err != nil {
return nil, err
diff --git a/vendor/github.com/prometheus/procfs/proc_interrupts.go b/vendor/github.com/prometheus/procfs/proc_interrupts.go
index 86b4b45246..b942c50723 100644
--- a/vendor/github.com/prometheus/procfs/proc_interrupts.go
+++ b/vendor/github.com/prometheus/procfs/proc_interrupts.go
@@ -1,4 +1,4 @@
-// Copyright 2022 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/proc_io.go b/vendor/github.com/prometheus/procfs/proc_io.go
index d15b66ddb6..dd8086ba2e 100644
--- a/vendor/github.com/prometheus/procfs/proc_io.go
+++ b/vendor/github.com/prometheus/procfs/proc_io.go
@@ -1,4 +1,4 @@
-// Copyright 2018 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/proc_limits.go b/vendor/github.com/prometheus/procfs/proc_limits.go
index 9530b14bc6..4b7d337847 100644
--- a/vendor/github.com/prometheus/procfs/proc_limits.go
+++ b/vendor/github.com/prometheus/procfs/proc_limits.go
@@ -1,4 +1,4 @@
-// Copyright 2018 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
@@ -19,6 +19,7 @@ import (
"os"
"regexp"
"strconv"
+ "strings"
)
// ProcLimits represents the soft limits for each of the process's resource
@@ -74,7 +75,7 @@ const (
)
var (
- limitsMatch = regexp.MustCompile(`(Max \w+\s{0,1}?\w*\s{0,1}\w*)\s{2,}(\w+)\s+(\w+)`)
+ limitsMatch = regexp.MustCompile(`(Max \w+\s??\w*\s?\w*)\s{2,}(\w+)\s+(\w+)`)
)
// NewLimits returns the current soft limits of the process.
@@ -106,7 +107,7 @@ func (p Proc) Limits() (ProcLimits, error) {
return ProcLimits{}, fmt.Errorf("%w: couldn't parse %q line %q", ErrFileParse, f.Name(), s.Text())
}
- switch fields[1] {
+ switch strings.TrimSpace(fields[1]) {
case "Max cpu time":
l.CPUTime, err = parseUint(fields[2])
case "Max file size":
diff --git a/vendor/github.com/prometheus/procfs/proc_maps.go b/vendor/github.com/prometheus/procfs/proc_maps.go
index 7e75c286b5..cc519f92f9 100644
--- a/vendor/github.com/prometheus/procfs/proc_maps.go
+++ b/vendor/github.com/prometheus/procfs/proc_maps.go
@@ -1,4 +1,4 @@
-// Copyright 2019 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/proc_netstat.go b/vendor/github.com/prometheus/procfs/proc_netstat.go
index 4248c1716e..7f94cc8914 100644
--- a/vendor/github.com/prometheus/procfs/proc_netstat.go
+++ b/vendor/github.com/prometheus/procfs/proc_netstat.go
@@ -1,4 +1,4 @@
-// Copyright 2022 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/proc_ns.go b/vendor/github.com/prometheus/procfs/proc_ns.go
index 0f8f847f95..5fc0eb9e2f 100644
--- a/vendor/github.com/prometheus/procfs/proc_ns.go
+++ b/vendor/github.com/prometheus/procfs/proc_ns.go
@@ -1,4 +1,4 @@
-// Copyright 2018 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/proc_psi.go b/vendor/github.com/prometheus/procfs/proc_psi.go
index ccd35f153a..cc2c5de873 100644
--- a/vendor/github.com/prometheus/procfs/proc_psi.go
+++ b/vendor/github.com/prometheus/procfs/proc_psi.go
@@ -1,4 +1,4 @@
-// Copyright 2019 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/proc_smaps.go b/vendor/github.com/prometheus/procfs/proc_smaps.go
index 9a297afcf8..3e48afd1d3 100644
--- a/vendor/github.com/prometheus/procfs/proc_smaps.go
+++ b/vendor/github.com/prometheus/procfs/proc_smaps.go
@@ -1,4 +1,4 @@
-// Copyright 2020 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/proc_snmp.go b/vendor/github.com/prometheus/procfs/proc_snmp.go
index 4bdc90b07e..8d9a9bcd67 100644
--- a/vendor/github.com/prometheus/procfs/proc_snmp.go
+++ b/vendor/github.com/prometheus/procfs/proc_snmp.go
@@ -1,4 +1,4 @@
-// Copyright 2022 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/proc_snmp6.go b/vendor/github.com/prometheus/procfs/proc_snmp6.go
index fb7fd3995b..841fef4649 100644
--- a/vendor/github.com/prometheus/procfs/proc_snmp6.go
+++ b/vendor/github.com/prometheus/procfs/proc_snmp6.go
@@ -1,4 +1,4 @@
-// Copyright 2022 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/proc_stat.go b/vendor/github.com/prometheus/procfs/proc_stat.go
index 06a8d931c9..02e3f9e316 100644
--- a/vendor/github.com/prometheus/procfs/proc_stat.go
+++ b/vendor/github.com/prometheus/procfs/proc_stat.go
@@ -1,4 +1,4 @@
-// Copyright 2018 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
@@ -101,6 +101,12 @@ type ProcStat struct {
RSS int
// Soft limit in bytes on the rss of the process.
RSSLimit uint64
+ // The address above which program text can run.
+ StartCode uint64
+ // The address below which program text can run.
+ EndCode uint64
+ // The address of the start (i.e., bottom) of the stack.
+ StartStack uint64
// CPU number last executed on.
Processor uint
// Real-time scheduling priority, a number in the range 1 to 99 for processes
@@ -177,9 +183,9 @@ func (p Proc) Stat() (ProcStat, error) {
&s.VSize,
&s.RSS,
&s.RSSLimit,
- &ignoreUint64,
- &ignoreUint64,
- &ignoreUint64,
+ &s.StartCode,
+ &s.EndCode,
+ &s.StartStack,
&ignoreUint64,
&ignoreUint64,
&ignoreUint64,
diff --git a/vendor/github.com/prometheus/procfs/proc_statm.go b/vendor/github.com/prometheus/procfs/proc_statm.go
new file mode 100644
index 0000000000..b0a9360167
--- /dev/null
+++ b/vendor/github.com/prometheus/procfs/proc_statm.go
@@ -0,0 +1,116 @@
+// Copyright The Prometheus Authors
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+package procfs
+
+import (
+ "os"
+ "strconv"
+ "strings"
+
+ "github.com/prometheus/procfs/internal/util"
+)
+
+// - https://man7.org/linux/man-pages/man5/proc_pid_statm.5.html
+
+// ProcStatm Provides memory usage information for a process, measured in memory pages.
+// Read from /proc/[pid]/statm.
+type ProcStatm struct {
+ // The process ID.
+ PID int
+ // total program size (same as VmSize in status)
+ Size uint64
+ // resident set size (same as VmRSS in status)
+ Resident uint64
+ // number of resident shared pages (i.e., backed by a file)
+ Shared uint64
+ // text (code)
+ Text uint64
+ // library (unused since Linux 2.6; always 0)
+ Lib uint64
+ // data + stack
+ Data uint64
+ // dirty pages (unused since Linux 2.6; always 0)
+ Dt uint64
+}
+
+// NewStatm returns the current status information of the process.
+// Deprecated: Use p.Statm() instead.
+func (p Proc) NewStatm() (ProcStatm, error) {
+ return p.Statm()
+}
+
+// Statm returns the current memory usage information of the process.
+func (p Proc) Statm() (ProcStatm, error) {
+ data, err := util.ReadFileNoStat(p.path("statm"))
+ if err != nil {
+ return ProcStatm{}, err
+ }
+
+ statmSlice, err := parseStatm(data)
+ if err != nil {
+ return ProcStatm{}, err
+ }
+
+ procStatm := ProcStatm{
+ PID: p.PID,
+ Size: statmSlice[0],
+ Resident: statmSlice[1],
+ Shared: statmSlice[2],
+ Text: statmSlice[3],
+ Lib: statmSlice[4],
+ Data: statmSlice[5],
+ Dt: statmSlice[6],
+ }
+
+ return procStatm, nil
+}
+
+// parseStatm return /proc/[pid]/statm data to uint64 slice.
+func parseStatm(data []byte) ([]uint64, error) {
+ var statmSlice []uint64
+ statmItems := strings.Fields(string(data))
+ for i := range statmItems {
+ statmItem, err := strconv.ParseUint(statmItems[i], 10, 64)
+ if err != nil {
+ return nil, err
+ }
+ statmSlice = append(statmSlice, statmItem)
+ }
+ return statmSlice, nil
+}
+
+// SizeBytes returns the process of total program size in bytes.
+func (s ProcStatm) SizeBytes() uint64 {
+ return s.Size * uint64(os.Getpagesize())
+}
+
+// ResidentBytes returns the process of resident set size in bytes.
+func (s ProcStatm) ResidentBytes() uint64 {
+ return s.Resident * uint64(os.Getpagesize())
+}
+
+// SHRBytes returns the process of share memory size in bytes.
+func (s ProcStatm) SHRBytes() uint64 {
+ return s.Shared * uint64(os.Getpagesize())
+}
+
+// TextBytes returns the process of text (code) size in bytes.
+func (s ProcStatm) TextBytes() uint64 {
+ return s.Text * uint64(os.Getpagesize())
+}
+
+// DataBytes returns the process of data + stack size in bytes.
+func (s ProcStatm) DataBytes() uint64 {
+ return s.Data * uint64(os.Getpagesize())
+}
diff --git a/vendor/github.com/prometheus/procfs/proc_status.go b/vendor/github.com/prometheus/procfs/proc_status.go
index dd8aa56885..1ed2bced41 100644
--- a/vendor/github.com/prometheus/procfs/proc_status.go
+++ b/vendor/github.com/prometheus/procfs/proc_status.go
@@ -1,4 +1,4 @@
-// Copyright 2018 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
@@ -16,7 +16,7 @@ package procfs
import (
"bytes"
"math/bits"
- "sort"
+ "slices"
"strconv"
"strings"
@@ -94,8 +94,7 @@ func (p Proc) NewStatus() (ProcStatus, error) {
s := ProcStatus{PID: p.PID}
- lines := strings.Split(string(data), "\n")
- for _, line := range lines {
+ for line := range strings.SplitSeq(string(data), "\n") {
if !bytes.Contains([]byte(line), []byte(":")) {
continue
}
@@ -222,7 +221,7 @@ func calcCpusAllowedList(cpuString string) []uint64 {
}
- sort.Slice(g, func(i, j int) bool { return g[i] < g[j] })
+ slices.Sort(g)
return g
}
diff --git a/vendor/github.com/prometheus/procfs/proc_sys.go b/vendor/github.com/prometheus/procfs/proc_sys.go
index 3810d1ac99..52658a4d52 100644
--- a/vendor/github.com/prometheus/procfs/proc_sys.go
+++ b/vendor/github.com/prometheus/procfs/proc_sys.go
@@ -1,4 +1,4 @@
-// Copyright 2022 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/schedstat.go b/vendor/github.com/prometheus/procfs/schedstat.go
index 5f7f32dc83..fafd8dff74 100644
--- a/vendor/github.com/prometheus/procfs/schedstat.go
+++ b/vendor/github.com/prometheus/procfs/schedstat.go
@@ -1,4 +1,4 @@
-// Copyright 2019 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/slab.go b/vendor/github.com/prometheus/procfs/slab.go
index 8611c90177..32a04678ad 100644
--- a/vendor/github.com/prometheus/procfs/slab.go
+++ b/vendor/github.com/prometheus/procfs/slab.go
@@ -1,4 +1,4 @@
-// Copyright 2020 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/softirqs.go b/vendor/github.com/prometheus/procfs/softirqs.go
index 403e6ae708..47b73a7297 100644
--- a/vendor/github.com/prometheus/procfs/softirqs.go
+++ b/vendor/github.com/prometheus/procfs/softirqs.go
@@ -1,4 +1,4 @@
-// Copyright 2022 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/stat.go b/vendor/github.com/prometheus/procfs/stat.go
index e36b41c18a..593ad0f62f 100644
--- a/vendor/github.com/prometheus/procfs/stat.go
+++ b/vendor/github.com/prometheus/procfs/stat.go
@@ -1,4 +1,4 @@
-// Copyright 2018 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
@@ -16,6 +16,7 @@ package procfs
import (
"bufio"
"bytes"
+ "errors"
"fmt"
"io"
"strconv"
@@ -92,7 +93,7 @@ func parseCPUStat(line string) (CPUStat, int64, error) {
&cpuStat.Iowait, &cpuStat.IRQ, &cpuStat.SoftIRQ, &cpuStat.Steal,
&cpuStat.Guest, &cpuStat.GuestNice)
- if err != nil && err != io.EOF {
+ if err != nil && !errors.Is(err, io.EOF) {
return CPUStat{}, -1, fmt.Errorf("%w: couldn't parse %q (cpu): %w", ErrFileParse, line, err)
}
if count == 0 {
diff --git a/vendor/github.com/prometheus/procfs/swaps.go b/vendor/github.com/prometheus/procfs/swaps.go
index 65fec834bf..ee17bf4888 100644
--- a/vendor/github.com/prometheus/procfs/swaps.go
+++ b/vendor/github.com/prometheus/procfs/swaps.go
@@ -1,4 +1,4 @@
-// Copyright 2019 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/thread.go b/vendor/github.com/prometheus/procfs/thread.go
index 80e0e947be..0cfbb54184 100644
--- a/vendor/github.com/prometheus/procfs/thread.go
+++ b/vendor/github.com/prometheus/procfs/thread.go
@@ -1,4 +1,4 @@
-// Copyright 2022 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/vm.go b/vendor/github.com/prometheus/procfs/vm.go
index 51c49d89e8..2a8d763909 100644
--- a/vendor/github.com/prometheus/procfs/vm.go
+++ b/vendor/github.com/prometheus/procfs/vm.go
@@ -1,4 +1,4 @@
-// Copyright 2019 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
diff --git a/vendor/github.com/prometheus/procfs/zoneinfo.go b/vendor/github.com/prometheus/procfs/zoneinfo.go
index e54d94b090..806e171147 100644
--- a/vendor/github.com/prometheus/procfs/zoneinfo.go
+++ b/vendor/github.com/prometheus/procfs/zoneinfo.go
@@ -1,4 +1,4 @@
-// Copyright 2019 The Prometheus Authors
+// Copyright The Prometheus Authors
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
@@ -88,11 +88,9 @@ func parseZoneinfo(zoneinfoData []byte) ([]Zoneinfo, error) {
zoneinfo := []Zoneinfo{}
- zoneinfoBlocks := bytes.Split(zoneinfoData, []byte("\nNode"))
- for _, block := range zoneinfoBlocks {
+ for block := range bytes.SplitSeq(zoneinfoData, []byte("\nNode")) {
var zoneinfoElement Zoneinfo
- lines := strings.Split(string(block), "\n")
- for _, line := range lines {
+ for line := range strings.SplitSeq(string(block), "\n") {
if nodeZone := nodeZoneRE.FindStringSubmatch(line); nodeZone != nil {
zoneinfoElement.Node = nodeZone[1]
diff --git a/vendor/github.com/spf13/cobra/.golangci.yml b/vendor/github.com/spf13/cobra/.golangci.yml
index 6acf8ab1ea..104dc24407 100644
--- a/vendor/github.com/spf13/cobra/.golangci.yml
+++ b/vendor/github.com/spf13/cobra/.golangci.yml
@@ -57,3 +57,10 @@ linters:
- common-false-positives
- legacy
- std-error-handling
+ settings:
+ govet:
+ # Disable buildtag check to allow dual build tag syntax (both //go:build and // +build).
+ # This is necessary for Go 1.15 compatibility since //go:build was introduced in Go 1.17.
+ # This can be removed once Cobra requires Go 1.17 or higher.
+ disable:
+ - buildtag
diff --git a/vendor/github.com/spf13/cobra/command.go b/vendor/github.com/spf13/cobra/command.go
index 78088db69c..c05fed45ae 100644
--- a/vendor/github.com/spf13/cobra/command.go
+++ b/vendor/github.com/spf13/cobra/command.go
@@ -557,7 +557,7 @@ func (c *Command) FlagErrorFunc() (f func(*Command, error) error) {
}
}
-var minUsagePadding = 25
+const minUsagePadding = 25
// UsagePadding return padding for the usage.
func (c *Command) UsagePadding() int {
@@ -567,7 +567,7 @@ func (c *Command) UsagePadding() int {
return c.parent.commandsMaxUseLen
}
-var minCommandPathPadding = 11
+const minCommandPathPadding = 11
// CommandPathPadding return padding for the command path.
func (c *Command) CommandPathPadding() int {
@@ -577,7 +577,7 @@ func (c *Command) CommandPathPadding() int {
return c.parent.commandsMaxCommandPathLen
}
-var minNamePadding = 11
+const minNamePadding = 11
// NamePadding returns padding for the name.
func (c *Command) NamePadding() int {
@@ -1939,7 +1939,7 @@ type tmplFunc struct {
fn func(io.Writer, interface{}) error
}
-var defaultUsageTemplate = `Usage:{{if .Runnable}}
+const defaultUsageTemplate = `Usage:{{if .Runnable}}
{{.UseLine}}{{end}}{{if .HasAvailableSubCommands}}
{{.CommandPath}} [command]{{end}}{{if gt (len .Aliases) 0}}
@@ -2039,7 +2039,7 @@ func defaultUsageFunc(w io.Writer, in interface{}) error {
return nil
}
-var defaultHelpTemplate = `{{with (or .Long .Short)}}{{. | trimTrailingWhitespaces}}
+const defaultHelpTemplate = `{{with (or .Long .Short)}}{{. | trimTrailingWhitespaces}}
{{end}}{{if or .Runnable .HasSubCommands}}{{.UsageString}}{{end}}`
@@ -2061,7 +2061,7 @@ func defaultHelpFunc(w io.Writer, in interface{}) error {
return nil
}
-var defaultVersionTemplate = `{{with .DisplayName}}{{printf "%s " .}}{{end}}{{printf "version %s" .Version}}
+const defaultVersionTemplate = `{{with .DisplayName}}{{printf "%s " .}}{{end}}{{printf "version %s" .Version}}
`
// defaultVersionFunc is equivalent to executing defaultVersionTemplate. The two should be changed in sync.
diff --git a/vendor/github.com/spf13/pflag/flag.go b/vendor/github.com/spf13/pflag/flag.go
index eeed1e92b0..2fd3c57597 100644
--- a/vendor/github.com/spf13/pflag/flag.go
+++ b/vendor/github.com/spf13/pflag/flag.go
@@ -143,8 +143,9 @@ type ParseErrorsAllowlist struct {
UnknownFlags bool
}
-// DEPRECATED: please use ParseErrorsAllowlist instead
-// This type will be removed in a future release
+// ParseErrorsWhitelist defines the parsing errors that can be ignored.
+//
+// Deprecated: use [ParseErrorsAllowlist] instead. This type will be removed in a future release.
type ParseErrorsWhitelist = ParseErrorsAllowlist
// NormalizedName is a flag name that has been normalized according to rules
@@ -165,8 +166,9 @@ type FlagSet struct {
// ParseErrorsAllowlist is used to configure an allowlist of errors
ParseErrorsAllowlist ParseErrorsAllowlist
- // DEPRECATED: please use ParseErrorsAllowlist instead
- // This field will be removed in a future release
+ // ParseErrorsAllowlist is used to configure an allowlist of errors.
+ //
+ // Deprecated: use [FlagSet.ParseErrorsAllowlist] instead. This field will be removed in a future release.
ParseErrorsWhitelist ParseErrorsAllowlist
name string
@@ -1185,7 +1187,7 @@ func (f *FlagSet) Parse(arguments []string) error {
case ContinueOnError:
return err
case ExitOnError:
- if errors.Is(err, ErrHelp) {
+ if err == ErrHelp {
os.Exit(0)
}
fmt.Fprintln(f.Output(), err)
@@ -1214,7 +1216,7 @@ func (f *FlagSet) ParseAll(arguments []string, fn func(flag *Flag, value string)
case ContinueOnError:
return err
case ExitOnError:
- if errors.Is(err, ErrHelp) {
+ if err == ErrHelp {
os.Exit(0)
}
fmt.Fprintln(f.Output(), err)
diff --git a/vendor/go.etcd.io/etcd/api/v3/version/version.go b/vendor/go.etcd.io/etcd/api/v3/version/version.go
index 9e7bc64c17..cd0b63ea67 100644
--- a/vendor/go.etcd.io/etcd/api/v3/version/version.go
+++ b/vendor/go.etcd.io/etcd/api/v3/version/version.go
@@ -26,7 +26,7 @@ import (
var (
// MinClusterVersion is the min cluster version this etcd binary is compatible with.
MinClusterVersion = "3.0.0"
- Version = "3.6.5"
+ Version = "3.6.8"
APIVersion = "unknown"
// Git SHA Value will be set during build
diff --git a/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/id.go b/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/id.go
index e854d7e84e..2950fdb42e 100644
--- a/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/id.go
+++ b/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/id.go
@@ -82,7 +82,7 @@ func marshalJSON(id []byte) ([]byte, error) {
}
// unmarshalJSON inflates trace id from hex string, possibly enclosed in quotes.
-func unmarshalJSON(dst []byte, src []byte) error {
+func unmarshalJSON(dst, src []byte) error {
if l := len(src); l >= 2 && src[0] == '"' && src[l-1] == '"' {
src = src[1 : l-1]
}
diff --git a/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/number.go b/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/number.go
index 29e629d667..5bb3b16c70 100644
--- a/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/number.go
+++ b/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/number.go
@@ -41,7 +41,7 @@ func (i *protoInt64) UnmarshalJSON(data []byte) error {
// strings or integers.
type protoUint64 uint64
-// Int64 returns the protoUint64 as a uint64.
+// Uint64 returns the protoUint64 as a uint64.
func (i *protoUint64) Uint64() uint64 { return uint64(*i) }
// UnmarshalJSON decodes both strings and integers.
diff --git a/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/span.go b/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/span.go
index a13a6b733d..67f80b6aa0 100644
--- a/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/span.go
+++ b/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/span.go
@@ -10,6 +10,7 @@ import (
"errors"
"fmt"
"io"
+ "math"
"time"
)
@@ -151,8 +152,8 @@ func (s Span) MarshalJSON() ([]byte, error) {
}{
Alias: Alias(s),
ParentSpanID: parentSpanId,
- StartTime: uint64(startT),
- EndTime: uint64(endT),
+ StartTime: uint64(startT), // nolint:gosec // >0 checked above.
+ EndTime: uint64(endT), // nolint:gosec // >0 checked above.
})
}
@@ -201,11 +202,13 @@ func (s *Span) UnmarshalJSON(data []byte) error {
case "startTimeUnixNano", "start_time_unix_nano":
var val protoUint64
err = decoder.Decode(&val)
- s.StartTime = time.Unix(0, int64(val.Uint64()))
+ v := int64(min(val.Uint64(), math.MaxInt64)) //nolint:gosec // Overflow checked.
+ s.StartTime = time.Unix(0, v)
case "endTimeUnixNano", "end_time_unix_nano":
var val protoUint64
err = decoder.Decode(&val)
- s.EndTime = time.Unix(0, int64(val.Uint64()))
+ v := int64(min(val.Uint64(), math.MaxInt64)) //nolint:gosec // Overflow checked.
+ s.EndTime = time.Unix(0, v)
case "attributes":
err = decoder.Decode(&s.Attrs)
case "droppedAttributesCount", "dropped_attributes_count":
@@ -248,13 +251,20 @@ func (s *Span) UnmarshalJSON(data []byte) error {
type SpanFlags int32
const (
+ // SpanFlagsTraceFlagsMask is a mask for trace-flags.
+ //
// Bits 0-7 are used for trace flags.
SpanFlagsTraceFlagsMask SpanFlags = 255
- // Bits 8 and 9 are used to indicate that the parent span or link span is remote.
- // Bit 8 (`HAS_IS_REMOTE`) indicates whether the value is known.
- // Bit 9 (`IS_REMOTE`) indicates whether the span or link is remote.
+ // SpanFlagsContextHasIsRemoteMask is a mask for HAS_IS_REMOTE status.
+ //
+ // Bits 8 and 9 are used to indicate that the parent span or link span is
+ // remote. Bit 8 (`HAS_IS_REMOTE`) indicates whether the value is known.
SpanFlagsContextHasIsRemoteMask SpanFlags = 256
- // SpanFlagsContextHasIsRemoteMask indicates the Span is remote.
+ // SpanFlagsContextIsRemoteMask is a mask for IS_REMOTE status.
+ //
+ // Bits 8 and 9 are used to indicate that the parent span or link span is
+ // remote. Bit 9 (`IS_REMOTE`) indicates whether the span or link is
+ // remote.
SpanFlagsContextIsRemoteMask SpanFlags = 512
)
@@ -263,26 +273,30 @@ const (
type SpanKind int32
const (
- // Indicates that the span represents an internal operation within an application,
- // as opposed to an operation happening at the boundaries. Default value.
+ // SpanKindInternal indicates that the span represents an internal
+ // operation within an application, as opposed to an operation happening at
+ // the boundaries.
SpanKindInternal SpanKind = 1
- // Indicates that the span covers server-side handling of an RPC or other
- // remote network request.
+ // SpanKindServer indicates that the span covers server-side handling of an
+ // RPC or other remote network request.
SpanKindServer SpanKind = 2
- // Indicates that the span describes a request to some remote service.
+ // SpanKindClient indicates that the span describes a request to some
+ // remote service.
SpanKindClient SpanKind = 3
- // Indicates that the span describes a producer sending a message to a broker.
- // Unlike CLIENT and SERVER, there is often no direct critical path latency relationship
- // between producer and consumer spans. A PRODUCER span ends when the message was accepted
- // by the broker while the logical processing of the message might span a much longer time.
+ // SpanKindProducer indicates that the span describes a producer sending a
+ // message to a broker. Unlike SpanKindClient and SpanKindServer, there is
+ // often no direct critical path latency relationship between producer and
+ // consumer spans. A SpanKindProducer span ends when the message was
+ // accepted by the broker while the logical processing of the message might
+ // span a much longer time.
SpanKindProducer SpanKind = 4
- // Indicates that the span describes consumer receiving a message from a broker.
- // Like the PRODUCER kind, there is often no direct critical path latency relationship
- // between producer and consumer spans.
+ // SpanKindConsumer indicates that the span describes a consumer receiving
+ // a message from a broker. Like SpanKindProducer, there is often no direct
+ // critical path latency relationship between producer and consumer spans.
SpanKindConsumer SpanKind = 5
)
-// Event is a time-stamped annotation of the span, consisting of user-supplied
+// SpanEvent is a time-stamped annotation of the span, consisting of user-supplied
// text description and key-value pairs.
type SpanEvent struct {
// time_unix_nano is the time the event occurred.
@@ -312,7 +326,7 @@ func (e SpanEvent) MarshalJSON() ([]byte, error) {
Time uint64 `json:"timeUnixNano,omitempty"`
}{
Alias: Alias(e),
- Time: uint64(t),
+ Time: uint64(t), //nolint:gosec // >0 checked above
})
}
@@ -347,7 +361,8 @@ func (se *SpanEvent) UnmarshalJSON(data []byte) error {
case "timeUnixNano", "time_unix_nano":
var val protoUint64
err = decoder.Decode(&val)
- se.Time = time.Unix(0, int64(val.Uint64()))
+ v := int64(min(val.Uint64(), math.MaxInt64)) //nolint:gosec // Overflow checked.
+ se.Time = time.Unix(0, v)
case "name":
err = decoder.Decode(&se.Name)
case "attributes":
@@ -365,10 +380,11 @@ func (se *SpanEvent) UnmarshalJSON(data []byte) error {
return nil
}
-// A pointer from the current span to another span in the same trace or in a
-// different trace. For example, this can be used in batching operations,
-// where a single batch handler processes multiple requests from different
-// traces or when the handler receives a request from a different project.
+// SpanLink is a reference from the current span to another span in the same
+// trace or in a different trace. For example, this can be used in batching
+// operations, where a single batch handler processes multiple requests from
+// different traces or when the handler receives a request from a different
+// project.
type SpanLink struct {
// A unique identifier of a trace that this linked span is part of. The ID is a
// 16-byte array.
diff --git a/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/status.go b/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/status.go
index 1217776ead..a2802764f8 100644
--- a/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/status.go
+++ b/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/status.go
@@ -3,17 +3,19 @@
package telemetry
+// StatusCode is the status of a Span.
+//
// For the semantics of status codes see
// https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/trace/api.md#set-status
type StatusCode int32
const (
- // The default status.
+ // StatusCodeUnset is the default status.
StatusCodeUnset StatusCode = 0
- // The Span has been validated by an Application developer or Operator to
- // have completed successfully.
+ // StatusCodeOK is used when the Span has been validated by an Application
+ // developer or Operator to have completed successfully.
StatusCodeOK StatusCode = 1
- // The Span contains an error.
+ // StatusCodeError is used when the Span contains an error.
StatusCodeError StatusCode = 2
)
diff --git a/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/traces.go b/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/traces.go
index 69a348f0f0..44197b8084 100644
--- a/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/traces.go
+++ b/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/traces.go
@@ -71,7 +71,7 @@ func (td *Traces) UnmarshalJSON(data []byte) error {
return nil
}
-// A collection of ScopeSpans from a Resource.
+// ResourceSpans is a collection of ScopeSpans from a Resource.
type ResourceSpans struct {
// The resource for the spans in this message.
// If this field is not set then no resource info is known.
@@ -128,7 +128,7 @@ func (rs *ResourceSpans) UnmarshalJSON(data []byte) error {
return nil
}
-// A collection of Spans produced by an InstrumentationScope.
+// ScopeSpans is a collection of Spans produced by an InstrumentationScope.
type ScopeSpans struct {
// The instrumentation scope information for the spans in this message.
// Semantically when InstrumentationScope isn't set, it is equivalent with
diff --git a/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/value.go b/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/value.go
index 0dd01b063a..022768bb50 100644
--- a/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/value.go
+++ b/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/value.go
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0
-//go:generate stringer -type=ValueKind -trimprefix=ValueKind
-
package telemetry
import (
@@ -23,7 +21,7 @@ import (
// A zero value is valid and represents an empty value.
type Value struct {
// Ensure forward compatibility by explicitly making this not comparable.
- noCmp [0]func() //nolint: unused // This is indeed used.
+ noCmp [0]func() //nolint:unused // This is indeed used.
// num holds the value for Int64, Float64, and Bool. It holds the length
// for String, Bytes, Slice, Map.
@@ -92,7 +90,7 @@ func IntValue(v int) Value { return Int64Value(int64(v)) }
// Int64Value returns a [Value] for an int64.
func Int64Value(v int64) Value {
- return Value{num: uint64(v), any: ValueKindInt64}
+ return Value{num: uint64(v), any: ValueKindInt64} //nolint:gosec // Raw value conv.
}
// Float64Value returns a [Value] for a float64.
@@ -164,7 +162,7 @@ func (v Value) AsInt64() int64 {
// this will return garbage.
func (v Value) asInt64() int64 {
// Assumes v.num was a valid int64 (overflow not checked).
- return int64(v.num) // nolint: gosec
+ return int64(v.num) //nolint:gosec // Bounded.
}
// AsBool returns the value held by v as a bool.
@@ -309,13 +307,13 @@ func (v Value) String() string {
return v.asString()
case ValueKindInt64:
// Assumes v.num was a valid int64 (overflow not checked).
- return strconv.FormatInt(int64(v.num), 10) // nolint: gosec
+ return strconv.FormatInt(int64(v.num), 10) //nolint:gosec // Bounded.
case ValueKindFloat64:
return strconv.FormatFloat(v.asFloat64(), 'g', -1, 64)
case ValueKindBool:
return strconv.FormatBool(v.asBool())
case ValueKindBytes:
- return fmt.Sprint(v.asBytes())
+ return string(v.asBytes())
case ValueKindMap:
return fmt.Sprint(v.asMap())
case ValueKindSlice:
@@ -343,7 +341,7 @@ func (v *Value) MarshalJSON() ([]byte, error) {
case ValueKindInt64:
return json.Marshal(struct {
Value string `json:"intValue"`
- }{strconv.FormatInt(int64(v.num), 10)})
+ }{strconv.FormatInt(int64(v.num), 10)}) //nolint:gosec // Raw value conv.
case ValueKindFloat64:
return json.Marshal(struct {
Value float64 `json:"doubleValue"`
diff --git a/vendor/go.opentelemetry.io/auto/sdk/span.go b/vendor/go.opentelemetry.io/auto/sdk/span.go
index 6ebea12a9e..815d271ffb 100644
--- a/vendor/go.opentelemetry.io/auto/sdk/span.go
+++ b/vendor/go.opentelemetry.io/auto/sdk/span.go
@@ -6,6 +6,7 @@ package sdk
import (
"encoding/json"
"fmt"
+ "math"
"reflect"
"runtime"
"strings"
@@ -16,7 +17,7 @@ import (
"go.opentelemetry.io/otel/attribute"
"go.opentelemetry.io/otel/codes"
- semconv "go.opentelemetry.io/otel/semconv/v1.26.0"
+ semconv "go.opentelemetry.io/otel/semconv/v1.37.0"
"go.opentelemetry.io/otel/trace"
"go.opentelemetry.io/otel/trace/noop"
@@ -85,7 +86,12 @@ func (s *span) SetAttributes(attrs ...attribute.KeyValue) {
limit := maxSpan.Attrs
if limit == 0 {
// No attributes allowed.
- s.span.DroppedAttrs += uint32(len(attrs))
+ n := int64(len(attrs))
+ if n > 0 {
+ s.span.DroppedAttrs += uint32( //nolint:gosec // Bounds checked.
+ min(n, math.MaxUint32),
+ )
+ }
return
}
@@ -121,8 +127,13 @@ func (s *span) SetAttributes(attrs ...attribute.KeyValue) {
// convCappedAttrs converts up to limit attrs into a []telemetry.Attr. The
// number of dropped attributes is also returned.
func convCappedAttrs(limit int, attrs []attribute.KeyValue) ([]telemetry.Attr, uint32) {
+ n := len(attrs)
if limit == 0 {
- return nil, uint32(len(attrs))
+ var out uint32
+ if n > 0 {
+ out = uint32(min(int64(n), math.MaxUint32)) //nolint:gosec // Bounds checked.
+ }
+ return nil, out
}
if limit < 0 {
@@ -130,8 +141,12 @@ func convCappedAttrs(limit int, attrs []attribute.KeyValue) ([]telemetry.Attr, u
return convAttrs(attrs), 0
}
- limit = min(len(attrs), limit)
- return convAttrs(attrs[:limit]), uint32(len(attrs) - limit)
+ if n < 0 {
+ n = 0
+ }
+
+ limit = min(n, limit)
+ return convAttrs(attrs[:limit]), uint32(n - limit) //nolint:gosec // Bounds checked.
}
func convAttrs(attrs []attribute.KeyValue) []telemetry.Attr {
diff --git a/vendor/go.opentelemetry.io/auto/sdk/tracer.go b/vendor/go.opentelemetry.io/auto/sdk/tracer.go
index cbcfabde3b..e09acf022f 100644
--- a/vendor/go.opentelemetry.io/auto/sdk/tracer.go
+++ b/vendor/go.opentelemetry.io/auto/sdk/tracer.go
@@ -5,6 +5,7 @@ package sdk
import (
"context"
+ "math"
"time"
"go.opentelemetry.io/otel/trace"
@@ -21,15 +22,20 @@ type tracer struct {
var _ trace.Tracer = tracer{}
-func (t tracer) Start(ctx context.Context, name string, opts ...trace.SpanStartOption) (context.Context, trace.Span) {
- var psc trace.SpanContext
+func (t tracer) Start(
+ ctx context.Context,
+ name string,
+ opts ...trace.SpanStartOption,
+) (context.Context, trace.Span) {
+ var psc, sc trace.SpanContext
sampled := true
span := new(span)
// Ask eBPF for sampling decision and span context info.
- t.start(ctx, span, &psc, &sampled, &span.spanContext)
+ t.start(ctx, span, &psc, &sampled, &sc)
span.sampled.Store(sampled)
+ span.spanContext = sc
ctx = trace.ContextWithSpan(ctx, span)
@@ -58,7 +64,13 @@ func (t *tracer) start(
// start is used for testing.
var start = func(context.Context, *span, *trace.SpanContext, *bool, *trace.SpanContext) {}
-func (t tracer) traces(name string, cfg trace.SpanConfig, sc, psc trace.SpanContext) (*telemetry.Traces, *telemetry.Span) {
+var intToUint32Bound = min(math.MaxInt, math.MaxUint32)
+
+func (t tracer) traces(
+ name string,
+ cfg trace.SpanConfig,
+ sc, psc trace.SpanContext,
+) (*telemetry.Traces, *telemetry.Span) {
span := &telemetry.Span{
TraceID: telemetry.TraceID(sc.TraceID()),
SpanID: telemetry.SpanID(sc.SpanID()),
@@ -73,11 +85,16 @@ func (t tracer) traces(name string, cfg trace.SpanConfig, sc, psc trace.SpanCont
links := cfg.Links()
if limit := maxSpan.Links; limit == 0 {
- span.DroppedLinks = uint32(len(links))
+ n := len(links)
+ if n > 0 {
+ bounded := max(min(n, intToUint32Bound), 0)
+ span.DroppedLinks = uint32(bounded) //nolint:gosec // Bounds checked.
+ }
} else {
if limit > 0 {
n := max(len(links)-limit, 0)
- span.DroppedLinks = uint32(n)
+ bounded := min(n, intToUint32Bound)
+ span.DroppedLinks = uint32(bounded) //nolint:gosec // Bounds checked.
links = links[n:]
}
span.Links = convLinks(links)
diff --git a/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/LICENSE b/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/LICENSE
index 261eeb9e9f..f1aee0f110 100644
--- a/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/LICENSE
+++ b/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/LICENSE
@@ -199,3 +199,33 @@
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
+
+--------------------------------------------------------------------------------
+
+Copyright 2009 The Go Authors.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are
+met:
+
+ * Redistributions of source code must retain the above copyright
+notice, this list of conditions and the following disclaimer.
+ * Redistributions in binary form must reproduce the above
+copyright notice, this list of conditions and the following disclaimer
+in the documentation and/or other materials provided with the
+distribution.
+ * Neither the name of Google LLC nor the names of its
+contributors may be used to endorse or promote products derived from
+this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
\ No newline at end of file
diff --git a/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/config.go b/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/config.go
index 9e87fb4bb1..0018e2d45f 100644
--- a/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/config.go
+++ b/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/config.go
@@ -4,23 +4,18 @@
package otelgrpc // import "go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc"
import (
- "google.golang.org/grpc/stats"
+ "context"
"go.opentelemetry.io/otel"
"go.opentelemetry.io/otel/attribute"
"go.opentelemetry.io/otel/metric"
- "go.opentelemetry.io/otel/metric/noop"
"go.opentelemetry.io/otel/propagation"
- semconv "go.opentelemetry.io/otel/semconv/v1.17.0"
"go.opentelemetry.io/otel/trace"
+ "google.golang.org/grpc/stats"
)
-const (
- // ScopeName is the instrumentation scope name.
- ScopeName = "go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc"
- // GRPCStatusCodeKey is convention for numeric status code of a gRPC request.
- GRPCStatusCodeKey = attribute.Key("rpc.grpc.status_code")
-)
+// ScopeName is the instrumentation scope name.
+const ScopeName = "go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc"
// InterceptorFilter is a predicate used to determine whether a given request in
// interceptor info should be instrumented. A InterceptorFilter must return true if
@@ -36,26 +31,21 @@ type Filter func(*stats.RPCTagInfo) bool
// config is a group of options for this instrumentation.
type config struct {
- Filter Filter
- InterceptorFilter InterceptorFilter
- Propagators propagation.TextMapPropagator
- TracerProvider trace.TracerProvider
- MeterProvider metric.MeterProvider
- SpanStartOptions []trace.SpanStartOption
- SpanAttributes []attribute.KeyValue
- MetricAttributes []attribute.KeyValue
+ Filter Filter
+ InterceptorFilter InterceptorFilter
+ Propagators propagation.TextMapPropagator
+ TracerProvider trace.TracerProvider
+ MeterProvider metric.MeterProvider
+ SpanStartOptions []trace.SpanStartOption
+ SpanAttributes []attribute.KeyValue
+ MetricAttributes []attribute.KeyValue
+ MetricAttributesFn func(ctx context.Context) []attribute.KeyValue
+
+ PublicEndpoint bool
+ PublicEndpointFn func(ctx context.Context, info *stats.RPCTagInfo) bool
ReceivedEvent bool
SentEvent bool
-
- tracer trace.Tracer
- meter metric.Meter
-
- rpcDuration metric.Float64Histogram
- rpcInBytes metric.Int64Histogram
- rpcOutBytes metric.Int64Histogram
- rpcInMessages metric.Int64Histogram
- rpcOutMessages metric.Int64Histogram
}
// Option applies an option value for a config.
@@ -63,8 +53,14 @@ type Option interface {
apply(*config)
}
+type optionFunc func(*config)
+
+func (f optionFunc) apply(c *config) {
+ f(c)
+}
+
// newConfig returns a config configured with all the passed Options.
-func newConfig(opts []Option, role string) *config {
+func newConfig(opts []Option) *config {
c := &config{
Propagators: otel.GetTextMapPropagator(),
TracerProvider: otel.GetTracerProvider(),
@@ -73,162 +69,77 @@ func newConfig(opts []Option, role string) *config {
for _, o := range opts {
o.apply(c)
}
-
- c.tracer = c.TracerProvider.Tracer(
- ScopeName,
- trace.WithInstrumentationVersion(SemVersion()),
- )
-
- c.meter = c.MeterProvider.Meter(
- ScopeName,
- metric.WithInstrumentationVersion(Version()),
- metric.WithSchemaURL(semconv.SchemaURL),
- )
-
- var err error
- c.rpcDuration, err = c.meter.Float64Histogram("rpc."+role+".duration",
- metric.WithDescription("Measures the duration of inbound RPC."),
- metric.WithUnit("ms"))
- if err != nil {
- otel.Handle(err)
- if c.rpcDuration == nil {
- c.rpcDuration = noop.Float64Histogram{}
- }
- }
-
- rpcRequestSize, err := c.meter.Int64Histogram("rpc."+role+".request.size",
- metric.WithDescription("Measures size of RPC request messages (uncompressed)."),
- metric.WithUnit("By"))
- if err != nil {
- otel.Handle(err)
- if rpcRequestSize == nil {
- rpcRequestSize = noop.Int64Histogram{}
- }
- }
-
- rpcResponseSize, err := c.meter.Int64Histogram("rpc."+role+".response.size",
- metric.WithDescription("Measures size of RPC response messages (uncompressed)."),
- metric.WithUnit("By"))
- if err != nil {
- otel.Handle(err)
- if rpcResponseSize == nil {
- rpcResponseSize = noop.Int64Histogram{}
- }
- }
-
- rpcRequestsPerRPC, err := c.meter.Int64Histogram("rpc."+role+".requests_per_rpc",
- metric.WithDescription("Measures the number of messages received per RPC. Should be 1 for all non-streaming RPCs."),
- metric.WithUnit("{count}"))
- if err != nil {
- otel.Handle(err)
- if rpcRequestsPerRPC == nil {
- rpcRequestsPerRPC = noop.Int64Histogram{}
- }
- }
-
- rpcResponsesPerRPC, err := c.meter.Int64Histogram("rpc."+role+".responses_per_rpc",
- metric.WithDescription("Measures the number of messages received per RPC. Should be 1 for all non-streaming RPCs."),
- metric.WithUnit("{count}"))
- if err != nil {
- otel.Handle(err)
- if rpcResponsesPerRPC == nil {
- rpcResponsesPerRPC = noop.Int64Histogram{}
- }
- }
-
- switch role {
- case "client":
- c.rpcInBytes = rpcResponseSize
- c.rpcInMessages = rpcResponsesPerRPC
- c.rpcOutBytes = rpcRequestSize
- c.rpcOutMessages = rpcRequestsPerRPC
- case "server":
- c.rpcInBytes = rpcRequestSize
- c.rpcInMessages = rpcRequestsPerRPC
- c.rpcOutBytes = rpcResponseSize
- c.rpcOutMessages = rpcResponsesPerRPC
- default:
- c.rpcInBytes = noop.Int64Histogram{}
- c.rpcInMessages = noop.Int64Histogram{}
- c.rpcOutBytes = noop.Int64Histogram{}
- c.rpcOutMessages = noop.Int64Histogram{}
- }
-
return c
}
-type propagatorsOption struct{ p propagation.TextMapPropagator }
+// WithPublicEndpoint configures the Handler to link the span with an incoming
+// span context. If this option is not provided, then the association is a child
+// association instead of a link.
+func WithPublicEndpoint() Option {
+ return optionFunc(func(c *config) {
+ c.PublicEndpoint = true
+ })
+}
-func (o propagatorsOption) apply(c *config) {
- if o.p != nil {
- c.Propagators = o.p
- }
+// WithPublicEndpointFn runs with every request, and allows conditionally
+// configuring the Handler to link the span with an incoming span context. If
+// this option is not provided or returns false, then the association is a
+// child association instead of a link.
+// Note: WithPublicEndpoint takes precedence over WithPublicEndpointFn.
+func WithPublicEndpointFn(fn func(context.Context, *stats.RPCTagInfo) bool) Option {
+ return optionFunc(func(c *config) {
+ c.PublicEndpointFn = fn
+ })
}
// WithPropagators returns an Option to use the Propagators when extracting
// and injecting trace context from requests.
func WithPropagators(p propagation.TextMapPropagator) Option {
- return propagatorsOption{p: p}
-}
-
-type tracerProviderOption struct{ tp trace.TracerProvider }
-
-func (o tracerProviderOption) apply(c *config) {
- if o.tp != nil {
- c.TracerProvider = o.tp
- }
+ return optionFunc(func(c *config) {
+ if p != nil {
+ c.Propagators = p
+ }
+ })
}
// WithInterceptorFilter returns an Option to use the request filter.
//
// Deprecated: Use stats handlers instead.
func WithInterceptorFilter(f InterceptorFilter) Option {
- return interceptorFilterOption{f: f}
-}
-
-type interceptorFilterOption struct {
- f InterceptorFilter
-}
-
-func (o interceptorFilterOption) apply(c *config) {
- if o.f != nil {
- c.InterceptorFilter = o.f
- }
+ return optionFunc(func(c *config) {
+ if f != nil {
+ c.InterceptorFilter = f
+ }
+ })
}
// WithFilter returns an Option to use the request filter.
func WithFilter(f Filter) Option {
- return filterOption{f: f}
-}
-
-type filterOption struct {
- f Filter
-}
-
-func (o filterOption) apply(c *config) {
- if o.f != nil {
- c.Filter = o.f
- }
+ return optionFunc(func(c *config) {
+ if f != nil {
+ c.Filter = f
+ }
+ })
}
// WithTracerProvider returns an Option to use the TracerProvider when
// creating a Tracer.
func WithTracerProvider(tp trace.TracerProvider) Option {
- return tracerProviderOption{tp: tp}
-}
-
-type meterProviderOption struct{ mp metric.MeterProvider }
-
-func (o meterProviderOption) apply(c *config) {
- if o.mp != nil {
- c.MeterProvider = o.mp
- }
+ return optionFunc(func(c *config) {
+ if tp != nil {
+ c.TracerProvider = tp
+ }
+ })
}
// WithMeterProvider returns an Option to use the MeterProvider when
// creating a Meter. If this option is not provide the global MeterProvider will be used.
func WithMeterProvider(mp metric.MeterProvider) Option {
- return meterProviderOption{mp: mp}
+ return optionFunc(func(c *config) {
+ if mp != nil {
+ c.MeterProvider = mp
+ }
+ })
}
// Event type that can be recorded, see WithMessageEvents.
@@ -240,21 +151,6 @@ const (
SentEvents
)
-type messageEventsProviderOption struct {
- events []Event
-}
-
-func (m messageEventsProviderOption) apply(c *config) {
- for _, e := range m.events {
- switch e {
- case ReceivedEvents:
- c.ReceivedEvent = true
- case SentEvents:
- c.SentEvent = true
- }
- }
-}
-
// WithMessageEvents configures the Handler to record the specified events
// (span.AddEvent) on spans. By default only summary attributes are added at the
// end of the request.
@@ -263,43 +159,54 @@ func (m messageEventsProviderOption) apply(c *config) {
// - ReceivedEvents: Record the number of bytes read after every gRPC read operation.
// - SentEvents: Record the number of bytes written after every gRPC write operation.
func WithMessageEvents(events ...Event) Option {
- return messageEventsProviderOption{events: events}
-}
-
-type spanStartOption struct{ opts []trace.SpanStartOption }
-
-func (o spanStartOption) apply(c *config) {
- c.SpanStartOptions = append(c.SpanStartOptions, o.opts...)
+ return optionFunc(func(c *config) {
+ for _, e := range events {
+ switch e {
+ case ReceivedEvents:
+ c.ReceivedEvent = true
+ case SentEvents:
+ c.SentEvent = true
+ }
+ }
+ })
}
// WithSpanOptions configures an additional set of
// trace.SpanOptions, which are applied to each new span.
+//
+// Deprecated: It is only used by the deprecated interceptor, and is unused by [NewClientHandler] and [NewServerHandler].
func WithSpanOptions(opts ...trace.SpanStartOption) Option {
- return spanStartOption{opts}
-}
-
-type spanAttributesOption struct{ a []attribute.KeyValue }
-
-func (o spanAttributesOption) apply(c *config) {
- if o.a != nil {
- c.SpanAttributes = o.a
- }
+ return optionFunc(func(c *config) {
+ c.SpanStartOptions = append(c.SpanStartOptions, opts...)
+ })
}
// WithSpanAttributes returns an Option to add custom attributes to the spans.
func WithSpanAttributes(a ...attribute.KeyValue) Option {
- return spanAttributesOption{a: a}
-}
-
-type metricAttributesOption struct{ a []attribute.KeyValue }
-
-func (o metricAttributesOption) apply(c *config) {
- if o.a != nil {
- c.MetricAttributes = o.a
- }
+ return optionFunc(func(c *config) {
+ if a != nil {
+ c.SpanAttributes = a
+ }
+ })
}
// WithMetricAttributes returns an Option to add custom attributes to the metrics.
func WithMetricAttributes(a ...attribute.KeyValue) Option {
- return metricAttributesOption{a: a}
+ return optionFunc(func(c *config) {
+ if a != nil {
+ c.MetricAttributes = append(c.MetricAttributes, a...)
+ }
+ })
+}
+
+// WithMetricAttributesFn returns an Option to add dynamic custom attributes to the handler's metrics.
+// The function is called once per RPC and the returned attributes are applied to all metrics recorded by this handler.
+//
+// The context parameter is the standard gRPC request context and provides access to request-scoped data.
+func WithMetricAttributesFn(fn func(ctx context.Context) []attribute.KeyValue) Option {
+ return optionFunc(func(c *config) {
+ if fn != nil {
+ c.MetricAttributesFn = fn
+ }
+ })
}
diff --git a/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/interceptor.go b/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/interceptor.go
index 7d5ed05808..24053927ca 100644
--- a/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/interceptor.go
+++ b/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/interceptor.go
@@ -4,506 +4,33 @@
package otelgrpc // import "go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc"
// gRPC tracing middleware
-// https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/trace/semantic_conventions/rpc.md
+// https://opentelemetry.io/docs/specs/semconv/rpc/
import (
- "context"
- "errors"
- "io"
"net"
"strconv"
- "time"
- "google.golang.org/grpc"
- grpc_codes "google.golang.org/grpc/codes"
- "google.golang.org/grpc/metadata"
- "google.golang.org/grpc/peer"
- "google.golang.org/grpc/status"
- "google.golang.org/protobuf/proto"
-
- "go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/internal"
"go.opentelemetry.io/otel/attribute"
"go.opentelemetry.io/otel/codes"
- "go.opentelemetry.io/otel/metric"
- semconv "go.opentelemetry.io/otel/semconv/v1.17.0"
- "go.opentelemetry.io/otel/trace"
-)
-
-type messageType attribute.KeyValue
-
-// Event adds an event of the messageType to the span associated with the
-// passed context with a message id.
-func (m messageType) Event(ctx context.Context, id int, _ interface{}) {
- span := trace.SpanFromContext(ctx)
- if !span.IsRecording() {
- return
- }
- span.AddEvent("message", trace.WithAttributes(
- attribute.KeyValue(m),
- RPCMessageIDKey.Int(id),
- ))
-}
-
-var (
- messageSent = messageType(RPCMessageTypeSent)
- messageReceived = messageType(RPCMessageTypeReceived)
+ semconv "go.opentelemetry.io/otel/semconv/v1.39.0"
+ grpc_codes "google.golang.org/grpc/codes"
+ "google.golang.org/grpc/status"
)
-// UnaryClientInterceptor returns a grpc.UnaryClientInterceptor suitable
-// for use in a grpc.NewClient call.
-//
-// Deprecated: Use [NewClientHandler] instead.
-func UnaryClientInterceptor(opts ...Option) grpc.UnaryClientInterceptor {
- cfg := newConfig(opts, "client")
- tracer := cfg.TracerProvider.Tracer(
- ScopeName,
- trace.WithInstrumentationVersion(Version()),
- )
-
- return func(
- ctx context.Context,
- method string,
- req, reply interface{},
- cc *grpc.ClientConn,
- invoker grpc.UnaryInvoker,
- callOpts ...grpc.CallOption,
- ) error {
- i := &InterceptorInfo{
- Method: method,
- Type: UnaryClient,
- }
- if cfg.InterceptorFilter != nil && !cfg.InterceptorFilter(i) {
- return invoker(ctx, method, req, reply, cc, callOpts...)
- }
-
- name, attr, _ := telemetryAttributes(method, cc.Target())
-
- startOpts := append([]trace.SpanStartOption{
- trace.WithSpanKind(trace.SpanKindClient),
- trace.WithAttributes(attr...),
- },
- cfg.SpanStartOptions...,
- )
-
- ctx, span := tracer.Start(
- ctx,
- name,
- startOpts...,
- )
- defer span.End()
-
- ctx = inject(ctx, cfg.Propagators)
-
- if cfg.SentEvent {
- messageSent.Event(ctx, 1, req)
- }
-
- err := invoker(ctx, method, req, reply, cc, callOpts...)
-
- if cfg.ReceivedEvent {
- messageReceived.Event(ctx, 1, reply)
- }
-
- if err != nil {
- s, _ := status.FromError(err)
- span.SetStatus(codes.Error, s.Message())
- span.SetAttributes(statusCodeAttr(s.Code()))
- } else {
- span.SetAttributes(statusCodeAttr(grpc_codes.OK))
- }
-
- return err
- }
-}
-
-// clientStream wraps around the embedded grpc.ClientStream, and intercepts the RecvMsg and
-// SendMsg method call.
-type clientStream struct {
- grpc.ClientStream
- desc *grpc.StreamDesc
-
- span trace.Span
-
- receivedEvent bool
- sentEvent bool
-
- receivedMessageID int
- sentMessageID int
-}
-
-var _ = proto.Marshal
-
-func (w *clientStream) RecvMsg(m interface{}) error {
- err := w.ClientStream.RecvMsg(m)
-
- if err == nil && !w.desc.ServerStreams {
- w.endSpan(nil)
- } else if errors.Is(err, io.EOF) {
- w.endSpan(nil)
- } else if err != nil {
- w.endSpan(err)
- } else {
- w.receivedMessageID++
-
- if w.receivedEvent {
- messageReceived.Event(w.Context(), w.receivedMessageID, m)
- }
- }
-
- return err
-}
-
-func (w *clientStream) SendMsg(m interface{}) error {
- err := w.ClientStream.SendMsg(m)
-
- w.sentMessageID++
-
- if w.sentEvent {
- messageSent.Event(w.Context(), w.sentMessageID, m)
- }
-
- if err != nil {
- w.endSpan(err)
- }
-
- return err
-}
-
-func (w *clientStream) Header() (metadata.MD, error) {
- md, err := w.ClientStream.Header()
- if err != nil {
- w.endSpan(err)
- }
-
- return md, err
-}
-
-func (w *clientStream) CloseSend() error {
- err := w.ClientStream.CloseSend()
- if err != nil {
- w.endSpan(err)
- }
-
- return err
-}
-
-func wrapClientStream(s grpc.ClientStream, desc *grpc.StreamDesc, span trace.Span, cfg *config) *clientStream {
- return &clientStream{
- ClientStream: s,
- span: span,
- desc: desc,
- receivedEvent: cfg.ReceivedEvent,
- sentEvent: cfg.SentEvent,
- }
-}
-
-func (w *clientStream) endSpan(err error) {
- if err != nil {
- s, _ := status.FromError(err)
- w.span.SetStatus(codes.Error, s.Message())
- w.span.SetAttributes(statusCodeAttr(s.Code()))
- } else {
- w.span.SetAttributes(statusCodeAttr(grpc_codes.OK))
- }
-
- w.span.End()
-}
-
-// StreamClientInterceptor returns a grpc.StreamClientInterceptor suitable
-// for use in a grpc.NewClient call.
-//
-// Deprecated: Use [NewClientHandler] instead.
-func StreamClientInterceptor(opts ...Option) grpc.StreamClientInterceptor {
- cfg := newConfig(opts, "client")
- tracer := cfg.TracerProvider.Tracer(
- ScopeName,
- trace.WithInstrumentationVersion(Version()),
- )
-
- return func(
- ctx context.Context,
- desc *grpc.StreamDesc,
- cc *grpc.ClientConn,
- method string,
- streamer grpc.Streamer,
- callOpts ...grpc.CallOption,
- ) (grpc.ClientStream, error) {
- i := &InterceptorInfo{
- Method: method,
- Type: StreamClient,
- }
- if cfg.InterceptorFilter != nil && !cfg.InterceptorFilter(i) {
- return streamer(ctx, desc, cc, method, callOpts...)
- }
-
- name, attr, _ := telemetryAttributes(method, cc.Target())
-
- startOpts := append([]trace.SpanStartOption{
- trace.WithSpanKind(trace.SpanKindClient),
- trace.WithAttributes(attr...),
- },
- cfg.SpanStartOptions...,
- )
-
- ctx, span := tracer.Start(
- ctx,
- name,
- startOpts...,
- )
-
- ctx = inject(ctx, cfg.Propagators)
-
- s, err := streamer(ctx, desc, cc, method, callOpts...)
- if err != nil {
- grpcStatus, _ := status.FromError(err)
- span.SetStatus(codes.Error, grpcStatus.Message())
- span.SetAttributes(statusCodeAttr(grpcStatus.Code()))
- span.End()
- return s, err
- }
- stream := wrapClientStream(s, desc, span, cfg)
- return stream, nil
- }
-}
-
-// UnaryServerInterceptor returns a grpc.UnaryServerInterceptor suitable
-// for use in a grpc.NewServer call.
-//
-// Deprecated: Use [NewServerHandler] instead.
-func UnaryServerInterceptor(opts ...Option) grpc.UnaryServerInterceptor {
- cfg := newConfig(opts, "server")
- tracer := cfg.TracerProvider.Tracer(
- ScopeName,
- trace.WithInstrumentationVersion(Version()),
- )
-
- return func(
- ctx context.Context,
- req interface{},
- info *grpc.UnaryServerInfo,
- handler grpc.UnaryHandler,
- ) (interface{}, error) {
- i := &InterceptorInfo{
- UnaryServerInfo: info,
- Type: UnaryServer,
- }
- if cfg.InterceptorFilter != nil && !cfg.InterceptorFilter(i) {
- return handler(ctx, req)
- }
-
- ctx = extract(ctx, cfg.Propagators)
- name, attr, metricAttrs := telemetryAttributes(info.FullMethod, peerFromCtx(ctx))
-
- startOpts := append([]trace.SpanStartOption{
- trace.WithSpanKind(trace.SpanKindServer),
- trace.WithAttributes(attr...),
- },
- cfg.SpanStartOptions...,
- )
-
- ctx, span := tracer.Start(
- trace.ContextWithRemoteSpanContext(ctx, trace.SpanContextFromContext(ctx)),
- name,
- startOpts...,
- )
- defer span.End()
-
- if cfg.ReceivedEvent {
- messageReceived.Event(ctx, 1, req)
- }
-
- before := time.Now()
-
- resp, err := handler(ctx, req)
-
- s, _ := status.FromError(err)
- if err != nil {
- statusCode, msg := serverStatus(s)
- span.SetStatus(statusCode, msg)
- if cfg.SentEvent {
- messageSent.Event(ctx, 1, s.Proto())
- }
- } else {
- if cfg.SentEvent {
- messageSent.Event(ctx, 1, resp)
- }
- }
- grpcStatusCodeAttr := statusCodeAttr(s.Code())
- span.SetAttributes(grpcStatusCodeAttr)
-
- // Use floating point division here for higher precision (instead of Millisecond method).
- elapsedTime := float64(time.Since(before)) / float64(time.Millisecond)
-
- metricAttrs = append(metricAttrs, grpcStatusCodeAttr)
- cfg.rpcDuration.Record(ctx, elapsedTime, metric.WithAttributeSet(attribute.NewSet(metricAttrs...)))
-
- return resp, err
- }
-}
-
-// serverStream wraps around the embedded grpc.ServerStream, and intercepts the RecvMsg and
-// SendMsg method call.
-type serverStream struct {
- grpc.ServerStream
- ctx context.Context
-
- receivedMessageID int
- sentMessageID int
-
- receivedEvent bool
- sentEvent bool
-}
-
-func (w *serverStream) Context() context.Context {
- return w.ctx
-}
-
-func (w *serverStream) RecvMsg(m interface{}) error {
- err := w.ServerStream.RecvMsg(m)
-
- if err == nil {
- w.receivedMessageID++
- if w.receivedEvent {
- messageReceived.Event(w.Context(), w.receivedMessageID, m)
- }
- }
-
- return err
-}
-
-func (w *serverStream) SendMsg(m interface{}) error {
- err := w.ServerStream.SendMsg(m)
-
- w.sentMessageID++
- if w.sentEvent {
- messageSent.Event(w.Context(), w.sentMessageID, m)
- }
-
- return err
-}
-
-func wrapServerStream(ctx context.Context, ss grpc.ServerStream, cfg *config) *serverStream {
- return &serverStream{
- ServerStream: ss,
- ctx: ctx,
- receivedEvent: cfg.ReceivedEvent,
- sentEvent: cfg.SentEvent,
- }
-}
-
-// StreamServerInterceptor returns a grpc.StreamServerInterceptor suitable
-// for use in a grpc.NewServer call.
-//
-// Deprecated: Use [NewServerHandler] instead.
-func StreamServerInterceptor(opts ...Option) grpc.StreamServerInterceptor {
- cfg := newConfig(opts, "server")
- tracer := cfg.TracerProvider.Tracer(
- ScopeName,
- trace.WithInstrumentationVersion(Version()),
- )
-
- return func(
- srv interface{},
- ss grpc.ServerStream,
- info *grpc.StreamServerInfo,
- handler grpc.StreamHandler,
- ) error {
- ctx := ss.Context()
- i := &InterceptorInfo{
- StreamServerInfo: info,
- Type: StreamServer,
- }
- if cfg.InterceptorFilter != nil && !cfg.InterceptorFilter(i) {
- return handler(srv, wrapServerStream(ctx, ss, cfg))
- }
-
- ctx = extract(ctx, cfg.Propagators)
- name, attr, _ := telemetryAttributes(info.FullMethod, peerFromCtx(ctx))
-
- startOpts := append([]trace.SpanStartOption{
- trace.WithSpanKind(trace.SpanKindServer),
- trace.WithAttributes(attr...),
- },
- cfg.SpanStartOptions...,
- )
-
- ctx, span := tracer.Start(
- trace.ContextWithRemoteSpanContext(ctx, trace.SpanContextFromContext(ctx)),
- name,
- startOpts...,
- )
- defer span.End()
-
- err := handler(srv, wrapServerStream(ctx, ss, cfg))
- if err != nil {
- s, _ := status.FromError(err)
- statusCode, msg := serverStatus(s)
- span.SetStatus(statusCode, msg)
- span.SetAttributes(statusCodeAttr(s.Code()))
- } else {
- span.SetAttributes(statusCodeAttr(grpc_codes.OK))
- }
-
- return err
- }
-}
-
-// telemetryAttributes returns a span name and span and metric attributes from
-// the gRPC method and peer address.
-func telemetryAttributes(fullMethod, peerAddress string) (string, []attribute.KeyValue, []attribute.KeyValue) {
- name, methodAttrs := internal.ParseFullMethod(fullMethod)
- peerAttrs := peerAttr(peerAddress)
-
- attrs := make([]attribute.KeyValue, 0, 1+len(methodAttrs)+len(peerAttrs))
- attrs = append(attrs, RPCSystemGRPC)
- attrs = append(attrs, methodAttrs...)
- metricAttrs := attrs[:1+len(methodAttrs)]
- attrs = append(attrs, peerAttrs...)
- return name, attrs, metricAttrs
-}
-
-// peerAttr returns attributes about the peer address.
-func peerAttr(addr string) []attribute.KeyValue {
- host, p, err := net.SplitHostPort(addr)
+// serverAddrAttrs returns the server address attributes for the hostport.
+func serverAddrAttrs(hostport string) []attribute.KeyValue {
+ h, pStr, err := net.SplitHostPort(hostport)
if err != nil {
- return nil
- }
-
- if host == "" {
- host = "127.0.0.1"
+ // The server.address attribute is required.
+ return []attribute.KeyValue{semconv.ServerAddress(hostport)}
}
- port, err := strconv.Atoi(p)
+ p, err := strconv.Atoi(pStr)
if err != nil {
- return nil
- }
-
- var attr []attribute.KeyValue
- if ip := net.ParseIP(host); ip != nil {
- attr = []attribute.KeyValue{
- semconv.NetSockPeerAddr(host),
- semconv.NetSockPeerPort(port),
- }
- } else {
- attr = []attribute.KeyValue{
- semconv.NetPeerName(host),
- semconv.NetPeerPort(port),
- }
+ return []attribute.KeyValue{semconv.ServerAddress(h)}
}
-
- return attr
-}
-
-// peerFromCtx returns a peer address from a context, if one exists.
-func peerFromCtx(ctx context.Context) string {
- p, ok := peer.FromContext(ctx)
- if !ok {
- return ""
+ return []attribute.KeyValue{
+ semconv.ServerAddress(h),
+ semconv.ServerPort(p),
}
- return p.Addr.String()
-}
-
-// statusCodeAttr returns status code attribute based on given gRPC code.
-func statusCodeAttr(c grpc_codes.Code) attribute.KeyValue {
- return GRPCStatusCodeKey.Int64(int64(c))
}
// serverStatus returns a span status code and message for a given gRPC
diff --git a/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/internal/parse.go b/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/internal/parse.go
index bef07b7a3c..2ab085031a 100644
--- a/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/internal/parse.go
+++ b/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/internal/parse.go
@@ -1,13 +1,14 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0
+// Package internal provides internal functionality for the otelgrpc package.
package internal // import "go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/internal"
import (
"strings"
"go.opentelemetry.io/otel/attribute"
- semconv "go.opentelemetry.io/otel/semconv/v1.17.0"
+ semconv "go.opentelemetry.io/otel/semconv/v1.39.0"
)
// ParseFullMethod returns a span name following the OpenTelemetry semantic
@@ -22,19 +23,5 @@ func ParseFullMethod(fullMethod string) (string, []attribute.KeyValue) {
return fullMethod, nil
}
name := fullMethod[1:]
- pos := strings.LastIndex(name, "/")
- if pos < 0 {
- // Invalid format, does not follow `/package.service/method`.
- return name, nil
- }
- service, method := name[:pos], name[pos+1:]
-
- var attrs []attribute.KeyValue
- if service != "" {
- attrs = append(attrs, semconv.RPCService(service))
- }
- if method != "" {
- attrs = append(attrs, semconv.RPCMethod(method))
- }
- return name, attrs
+ return name, []attribute.KeyValue{semconv.RPCMethod(name)}
}
diff --git a/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/metadata_supplier.go b/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/metadata_supplier.go
index 3aa37915df..4c62341d66 100644
--- a/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/metadata_supplier.go
+++ b/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/metadata_supplier.go
@@ -6,21 +6,18 @@ package otelgrpc // import "go.opentelemetry.io/contrib/instrumentation/google.g
import (
"context"
- "google.golang.org/grpc/metadata"
-
- "go.opentelemetry.io/otel/baggage"
"go.opentelemetry.io/otel/propagation"
- "go.opentelemetry.io/otel/trace"
+ "google.golang.org/grpc/metadata"
)
type metadataSupplier struct {
- metadata *metadata.MD
+ metadata metadata.MD
}
// assert that metadataSupplier implements the TextMapCarrier interface.
-var _ propagation.TextMapCarrier = &metadataSupplier{}
+var _ propagation.TextMapCarrier = metadataSupplier{}
-func (s *metadataSupplier) Get(key string) string {
+func (s metadataSupplier) Get(key string) string {
values := s.metadata.Get(key)
if len(values) == 0 {
return ""
@@ -28,51 +25,27 @@ func (s *metadataSupplier) Get(key string) string {
return values[0]
}
-func (s *metadataSupplier) Set(key string, value string) {
+func (s metadataSupplier) Set(key, value string) {
s.metadata.Set(key, value)
}
-func (s *metadataSupplier) Keys() []string {
- out := make([]string, 0, len(*s.metadata))
- for key := range *s.metadata {
+func (s metadataSupplier) Keys() []string {
+ out := make([]string, 0, len(s.metadata))
+ for key := range s.metadata {
out = append(out, key)
}
return out
}
-// Inject injects correlation context and span context into the gRPC
-// metadata object. This function is meant to be used on outgoing
-// requests.
-// Deprecated: Unnecessary public func.
-func Inject(ctx context.Context, md *metadata.MD, opts ...Option) {
- c := newConfig(opts, "")
- c.Propagators.Inject(ctx, &metadataSupplier{
- metadata: md,
- })
-}
-
func inject(ctx context.Context, propagators propagation.TextMapPropagator) context.Context {
md, ok := metadata.FromOutgoingContext(ctx)
if !ok {
md = metadata.MD{}
}
- propagators.Inject(ctx, &metadataSupplier{
- metadata: &md,
- })
- return metadata.NewOutgoingContext(ctx, md)
-}
-
-// Extract returns the correlation context and span context that
-// another service encoded in the gRPC metadata object with Inject.
-// This function is meant to be used on incoming requests.
-// Deprecated: Unnecessary public func.
-func Extract(ctx context.Context, md *metadata.MD, opts ...Option) (baggage.Baggage, trace.SpanContext) {
- c := newConfig(opts, "")
- ctx = c.Propagators.Extract(ctx, &metadataSupplier{
+ propagators.Inject(ctx, metadataSupplier{
metadata: md,
})
-
- return baggage.FromContext(ctx), trace.SpanContextFromContext(ctx)
+ return metadata.NewOutgoingContext(ctx, md)
}
func extract(ctx context.Context, propagators propagation.TextMapPropagator) context.Context {
@@ -81,7 +54,7 @@ func extract(ctx context.Context, propagators propagation.TextMapPropagator) con
md = metadata.MD{}
}
- return propagators.Extract(ctx, &metadataSupplier{
- metadata: &md,
+ return propagators.Extract(ctx, metadataSupplier{
+ metadata: md,
})
}
diff --git a/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/semconv.go b/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/semconv.go
deleted file mode 100644
index 409c621b74..0000000000
--- a/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/semconv.go
+++ /dev/null
@@ -1,41 +0,0 @@
-// Copyright The OpenTelemetry Authors
-// SPDX-License-Identifier: Apache-2.0
-
-package otelgrpc // import "go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc"
-
-import (
- "go.opentelemetry.io/otel/attribute"
- semconv "go.opentelemetry.io/otel/semconv/v1.17.0"
-)
-
-// Semantic conventions for attribute keys for gRPC.
-const (
- // Name of message transmitted or received.
- RPCNameKey = attribute.Key("name")
-
- // Type of message transmitted or received.
- RPCMessageTypeKey = attribute.Key("message.type")
-
- // Identifier of message transmitted or received.
- RPCMessageIDKey = attribute.Key("message.id")
-
- // The compressed size of the message transmitted or received in bytes.
- RPCMessageCompressedSizeKey = attribute.Key("message.compressed_size")
-
- // The uncompressed size of the message transmitted or received in
- // bytes.
- RPCMessageUncompressedSizeKey = attribute.Key("message.uncompressed_size")
-)
-
-// Semantic conventions for common RPC attributes.
-var (
- // Semantic convention for gRPC as the remoting system.
- RPCSystemGRPC = semconv.RPCSystemGRPC
-
- // Semantic convention for a message named message.
- RPCNameMessage = RPCNameKey.String("message")
-
- // Semantic conventions for RPC message types.
- RPCMessageTypeSent = RPCMessageTypeKey.String("SENT")
- RPCMessageTypeReceived = RPCMessageTypeKey.String("RECEIVED")
-)
diff --git a/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/stats_handler.go b/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/stats_handler.go
index 216127d6fb..0340ca7766 100644
--- a/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/stats_handler.go
+++ b/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/stats_handler.go
@@ -8,16 +8,17 @@ import (
"sync/atomic"
"time"
- grpc_codes "google.golang.org/grpc/codes"
- "google.golang.org/grpc/peer"
- "google.golang.org/grpc/stats"
- "google.golang.org/grpc/status"
-
+ "go.opentelemetry.io/otel"
"go.opentelemetry.io/otel/attribute"
"go.opentelemetry.io/otel/codes"
"go.opentelemetry.io/otel/metric"
- semconv "go.opentelemetry.io/otel/semconv/v1.17.0"
+ semconv "go.opentelemetry.io/otel/semconv/v1.39.0"
+ "go.opentelemetry.io/otel/semconv/v1.39.0/rpcconv"
"go.opentelemetry.io/otel/trace"
+ grpc_codes "google.golang.org/grpc/codes"
+ "google.golang.org/grpc/peer"
+ "google.golang.org/grpc/stats"
+ "google.golang.org/grpc/status"
"go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/internal"
)
@@ -25,77 +26,168 @@ import (
type gRPCContextKey struct{}
type gRPCContext struct {
- inMessages int64
- outMessages int64
- metricAttrs []attribute.KeyValue
- record bool
+ inMessages int64
+ outMessages int64
+ metricAttrs []attribute.KeyValue
+ metricAttrSet attribute.Set
+ record bool
}
type serverHandler struct {
*config
+
+ tracer trace.Tracer
+
+ duration rpcconv.ServerCallDuration
+ inSize int64Hist
+ outSize int64Hist
}
// NewServerHandler creates a stats.Handler for a gRPC server.
func NewServerHandler(opts ...Option) stats.Handler {
- h := &serverHandler{
- config: newConfig(opts, "server"),
+ c := newConfig(opts)
+ h := &serverHandler{config: c}
+
+ h.tracer = c.TracerProvider.Tracer(
+ ScopeName,
+ trace.WithInstrumentationVersion(Version),
+ )
+
+ meter := c.MeterProvider.Meter(
+ ScopeName,
+ metric.WithInstrumentationVersion(Version),
+ metric.WithSchemaURL(semconv.SchemaURL),
+ )
+
+ var err error
+ h.duration, err = rpcconv.NewServerCallDuration(meter)
+ if err != nil {
+ otel.Handle(err)
+ }
+
+ h.inSize, err = rpcconv.NewServerRequestSize(meter)
+ if err != nil {
+ otel.Handle(err)
+ }
+
+ h.outSize, err = rpcconv.NewServerResponseSize(meter)
+ if err != nil {
+ otel.Handle(err)
}
return h
}
// TagConn can attach some information to the given context.
-func (h *serverHandler) TagConn(ctx context.Context, info *stats.ConnTagInfo) context.Context {
+func (*serverHandler) TagConn(ctx context.Context, _ *stats.ConnTagInfo) context.Context {
return ctx
}
// HandleConn processes the Conn stats.
-func (h *serverHandler) HandleConn(ctx context.Context, info stats.ConnStats) {
+func (*serverHandler) HandleConn(context.Context, stats.ConnStats) {
}
// TagRPC can attach some information to the given context.
func (h *serverHandler) TagRPC(ctx context.Context, info *stats.RPCTagInfo) context.Context {
- ctx = extract(ctx, h.config.Propagators)
+ ctx = extract(ctx, h.Propagators)
name, attrs := internal.ParseFullMethod(info.FullMethodName)
- attrs = append(attrs, RPCSystemGRPC)
+ attrs = append(attrs, semconv.RPCSystemNameGRPC)
record := true
- if h.config.Filter != nil {
- record = h.config.Filter(info)
+ if h.Filter != nil {
+ record = h.Filter(info)
}
if record {
+ // Make a new slice to avoid aliasing into the same attrs slice used by metrics.
+ spanAttributes := make([]attribute.KeyValue, 0, len(attrs)+len(h.SpanAttributes))
+ spanAttributes = append(append(spanAttributes, attrs...), h.SpanAttributes...)
+ opts := []trace.SpanStartOption{
+ trace.WithSpanKind(trace.SpanKindServer),
+ trace.WithAttributes(spanAttributes...),
+ }
+ if h.PublicEndpoint || (h.PublicEndpointFn != nil && h.PublicEndpointFn(ctx, info)) {
+ opts = append(opts, trace.WithNewRoot())
+ // Linking incoming span context if any for public endpoint.
+ if s := trace.SpanContextFromContext(ctx); s.IsValid() && s.IsRemote() {
+ opts = append(opts, trace.WithLinks(trace.Link{SpanContext: s}))
+ }
+ }
ctx, _ = h.tracer.Start(
trace.ContextWithRemoteSpanContext(ctx, trace.SpanContextFromContext(ctx)),
name,
- trace.WithSpanKind(trace.SpanKindServer),
- trace.WithAttributes(append(attrs, h.config.SpanAttributes...)...),
+ opts...,
)
}
gctx := gRPCContext{
- metricAttrs: append(attrs, h.config.MetricAttributes...),
+ metricAttrs: append(attrs, h.MetricAttributes...),
record: record,
}
+ if h.MetricAttributesFn != nil {
+ extraAttrs := h.MetricAttributesFn(ctx)
+ gctx.metricAttrs = append(gctx.metricAttrs, extraAttrs...)
+ }
+
+ gctx.metricAttrSet = attribute.NewSet(gctx.metricAttrs...)
+
return context.WithValue(ctx, gRPCContextKey{}, &gctx)
}
// HandleRPC processes the RPC stats.
func (h *serverHandler) HandleRPC(ctx context.Context, rs stats.RPCStats) {
- isServer := true
- h.handleRPC(ctx, rs, isServer)
+ h.handleRPC(
+ ctx,
+ rs,
+ h.duration.Inst(),
+ h.inSize,
+ h.outSize,
+ serverStatus,
+ )
}
type clientHandler struct {
*config
+
+ tracer trace.Tracer
+
+ duration rpcconv.ClientCallDuration
+ inSize int64Hist
+ outSize int64Hist
}
// NewClientHandler creates a stats.Handler for a gRPC client.
func NewClientHandler(opts ...Option) stats.Handler {
- h := &clientHandler{
- config: newConfig(opts, "client"),
+ c := newConfig(opts)
+ h := &clientHandler{config: c}
+
+ h.tracer = c.TracerProvider.Tracer(
+ ScopeName,
+ trace.WithInstrumentationVersion(Version),
+ )
+
+ meter := c.MeterProvider.Meter(
+ ScopeName,
+ metric.WithInstrumentationVersion(Version),
+ metric.WithSchemaURL(semconv.SchemaURL),
+ )
+
+ var err error
+ h.duration, err = rpcconv.NewClientCallDuration(meter)
+ if err != nil {
+ otel.Handle(err)
+ }
+
+ h.inSize, err = rpcconv.NewClientResponseSize(meter)
+ if err != nil {
+ otel.Handle(err)
+ }
+
+ h.outSize, err = rpcconv.NewClientRequestSize(meter)
+ if err != nil {
+ otel.Handle(err)
}
return h
@@ -104,117 +196,151 @@ func NewClientHandler(opts ...Option) stats.Handler {
// TagRPC can attach some information to the given context.
func (h *clientHandler) TagRPC(ctx context.Context, info *stats.RPCTagInfo) context.Context {
name, attrs := internal.ParseFullMethod(info.FullMethodName)
- attrs = append(attrs, RPCSystemGRPC)
+ attrs = append(attrs, semconv.RPCSystemNameGRPC)
record := true
- if h.config.Filter != nil {
- record = h.config.Filter(info)
+ if h.Filter != nil {
+ record = h.Filter(info)
}
if record {
+ // Make a new slice to avoid aliasing into the same attrs slice used by metrics.
+ spanAttributes := make([]attribute.KeyValue, 0, len(attrs)+len(h.SpanAttributes))
+ spanAttributes = append(append(spanAttributes, attrs...), h.SpanAttributes...)
ctx, _ = h.tracer.Start(
ctx,
name,
trace.WithSpanKind(trace.SpanKindClient),
- trace.WithAttributes(append(attrs, h.config.SpanAttributes...)...),
+ trace.WithAttributes(spanAttributes...),
)
}
gctx := gRPCContext{
- metricAttrs: append(attrs, h.config.MetricAttributes...),
+ metricAttrs: append(attrs, h.MetricAttributes...),
record: record,
}
- return inject(context.WithValue(ctx, gRPCContextKey{}, &gctx), h.config.Propagators)
+ if h.MetricAttributesFn != nil {
+ extraAttrs := h.MetricAttributesFn(ctx)
+ gctx.metricAttrs = append(gctx.metricAttrs, extraAttrs...)
+ }
+
+ gctx.metricAttrSet = attribute.NewSet(gctx.metricAttrs...)
+
+ return inject(context.WithValue(ctx, gRPCContextKey{}, &gctx), h.Propagators)
}
// HandleRPC processes the RPC stats.
func (h *clientHandler) HandleRPC(ctx context.Context, rs stats.RPCStats) {
- isServer := false
- h.handleRPC(ctx, rs, isServer)
+ h.handleRPC(
+ ctx,
+ rs,
+ h.duration.Inst(),
+ h.inSize,
+ h.outSize,
+ func(s *status.Status) (codes.Code, string) {
+ return codes.Error, s.Message()
+ },
+ )
}
// TagConn can attach some information to the given context.
-func (h *clientHandler) TagConn(ctx context.Context, info *stats.ConnTagInfo) context.Context {
+func (*clientHandler) TagConn(ctx context.Context, _ *stats.ConnTagInfo) context.Context {
return ctx
}
// HandleConn processes the Conn stats.
-func (h *clientHandler) HandleConn(context.Context, stats.ConnStats) {
+func (*clientHandler) HandleConn(context.Context, stats.ConnStats) {
// no-op
}
-func (c *config) handleRPC(ctx context.Context, rs stats.RPCStats, isServer bool) { // nolint: revive // isServer is not a control flag.
- span := trace.SpanFromContext(ctx)
- var metricAttrs []attribute.KeyValue
- var messageId int64
+type int64Hist interface {
+ RecordSet(context.Context, int64, attribute.Set)
+}
+func (c *config) handleRPC(
+ ctx context.Context,
+ rs stats.RPCStats,
+ duration metric.Float64Histogram,
+ inSize, outSize int64Hist,
+ recordStatus func(*status.Status) (codes.Code, string),
+) {
gctx, _ := ctx.Value(gRPCContextKey{}).(*gRPCContext)
- if gctx != nil {
- if !gctx.record {
- return
- }
- metricAttrs = make([]attribute.KeyValue, 0, len(gctx.metricAttrs)+1)
- metricAttrs = append(metricAttrs, gctx.metricAttrs...)
+ if gctx != nil && !gctx.record {
+ return
}
+ span := trace.SpanFromContext(ctx)
+ var messageId int64
+
switch rs := rs.(type) {
case *stats.Begin:
case *stats.InPayload:
if gctx != nil {
messageId = atomic.AddInt64(&gctx.inMessages, 1)
- c.rpcInBytes.Record(ctx, int64(rs.Length), metric.WithAttributeSet(attribute.NewSet(metricAttrs...)))
+ inSize.RecordSet(ctx, int64(rs.Length), gctx.metricAttrSet)
}
- if c.ReceivedEvent {
+ if c.ReceivedEvent && span.IsRecording() {
span.AddEvent("message",
trace.WithAttributes(
- semconv.MessageTypeReceived,
- semconv.MessageIDKey.Int64(messageId),
- semconv.MessageCompressedSizeKey.Int(rs.CompressedLength),
- semconv.MessageUncompressedSizeKey.Int(rs.Length),
+ semconv.RPCMessageTypeReceived,
+ semconv.RPCMessageIDKey.Int64(messageId),
+ semconv.RPCMessageCompressedSizeKey.Int(rs.CompressedLength),
+ semconv.RPCMessageUncompressedSizeKey.Int(rs.Length),
),
)
}
case *stats.OutPayload:
if gctx != nil {
messageId = atomic.AddInt64(&gctx.outMessages, 1)
- c.rpcOutBytes.Record(ctx, int64(rs.Length), metric.WithAttributeSet(attribute.NewSet(metricAttrs...)))
+ outSize.RecordSet(ctx, int64(rs.Length), gctx.metricAttrSet)
}
- if c.SentEvent {
+ if c.SentEvent && span.IsRecording() {
span.AddEvent("message",
trace.WithAttributes(
- semconv.MessageTypeSent,
- semconv.MessageIDKey.Int64(messageId),
- semconv.MessageCompressedSizeKey.Int(rs.CompressedLength),
- semconv.MessageUncompressedSizeKey.Int(rs.Length),
+ semconv.RPCMessageTypeSent,
+ semconv.RPCMessageIDKey.Int64(messageId),
+ semconv.RPCMessageCompressedSizeKey.Int(rs.CompressedLength),
+ semconv.RPCMessageUncompressedSizeKey.Int(rs.Length),
),
)
}
case *stats.OutTrailer:
case *stats.OutHeader:
- if p, ok := peer.FromContext(ctx); ok {
- span.SetAttributes(peerAttr(p.Addr.String())...)
+ if span.IsRecording() {
+ if p, ok := peer.FromContext(ctx); ok {
+ span.SetAttributes(serverAddrAttrs(p.Addr.String())...)
+ }
}
case *stats.End:
var rpcStatusAttr attribute.KeyValue
+ var s *status.Status
if rs.Error != nil {
- s, _ := status.FromError(rs.Error)
- if isServer {
- statusCode, msg := serverStatus(s)
- span.SetStatus(statusCode, msg)
- } else {
- span.SetStatus(codes.Error, s.Message())
- }
- rpcStatusAttr = semconv.RPCGRPCStatusCodeKey.Int(int(s.Code()))
+ s, _ = status.FromError(rs.Error)
+ rpcStatusAttr = semconv.RPCResponseStatusCode(s.Code().String())
} else {
- rpcStatusAttr = semconv.RPCGRPCStatusCodeKey.Int(int(grpc_codes.OK))
+ rpcStatusAttr = semconv.RPCResponseStatusCode(grpc_codes.OK.String())
+ }
+ if span.IsRecording() {
+ if s != nil {
+ c, m := recordStatus(s)
+ span.SetStatus(c, m)
+ }
+ span.SetAttributes(rpcStatusAttr)
+ span.End()
}
- span.SetAttributes(rpcStatusAttr)
- span.End()
+ var metricAttrs []attribute.KeyValue
+ if gctx != nil {
+ // Don't use gctx.metricAttrSet here, because it requires passing
+ // multiple RecordOptions, which would call metric.mergeSets and
+ // allocate a new set for each Record call.
+ metricAttrs = make([]attribute.KeyValue, 0, len(gctx.metricAttrs)+1)
+ metricAttrs = append(metricAttrs, gctx.metricAttrs...)
+ }
metricAttrs = append(metricAttrs, rpcStatusAttr)
// Allocate vararg slice once.
recordOpts := []metric.RecordOption{metric.WithAttributeSet(attribute.NewSet(metricAttrs...))}
@@ -223,11 +349,7 @@ func (c *config) handleRPC(ctx context.Context, rs stats.RPCStats, isServer bool
// Measure right before calling Record() to capture as much elapsed time as possible.
elapsedTime := float64(rs.EndTime.Sub(rs.BeginTime)) / float64(time.Millisecond)
- c.rpcDuration.Record(ctx, elapsedTime, recordOpts...)
- if gctx != nil {
- c.rpcInMessages.Record(ctx, atomic.LoadInt64(&gctx.inMessages), recordOpts...)
- c.rpcOutMessages.Record(ctx, atomic.LoadInt64(&gctx.outMessages), recordOpts...)
- }
+ duration.Record(ctx, elapsedTime, recordOpts...)
default:
return
}
diff --git a/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/version.go b/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/version.go
index 442e8a838b..f9f963fdd9 100644
--- a/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/version.go
+++ b/vendor/go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc/version.go
@@ -4,14 +4,4 @@
package otelgrpc // import "go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc"
// Version is the current release version of the gRPC instrumentation.
-func Version() string {
- return "0.60.0"
- // This string is updated by the pre_release.sh script during release
-}
-
-// SemVersion is the semantic version to be supplied to tracer/meter creation.
-//
-// Deprecated: Use [Version] instead.
-func SemVersion() string {
- return Version()
-}
+const Version = "0.65.0"
diff --git a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/LICENSE b/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/LICENSE
index 261eeb9e9f..f1aee0f110 100644
--- a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/LICENSE
+++ b/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/LICENSE
@@ -199,3 +199,33 @@
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
+
+--------------------------------------------------------------------------------
+
+Copyright 2009 The Go Authors.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are
+met:
+
+ * Redistributions of source code must retain the above copyright
+notice, this list of conditions and the following disclaimer.
+ * Redistributions in binary form must reproduce the above
+copyright notice, this list of conditions and the following disclaimer
+in the documentation and/or other materials provided with the
+distribution.
+ * Neither the name of Google LLC nor the names of its
+contributors may be used to endorse or promote products derived from
+this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
\ No newline at end of file
diff --git a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/client.go b/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/client.go
deleted file mode 100644
index b25641c55d..0000000000
--- a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/client.go
+++ /dev/null
@@ -1,50 +0,0 @@
-// Copyright The OpenTelemetry Authors
-// SPDX-License-Identifier: Apache-2.0
-
-package otelhttp // import "go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp"
-
-import (
- "context"
- "io"
- "net/http"
- "net/url"
- "strings"
-)
-
-// DefaultClient is the default Client and is used by Get, Head, Post and PostForm.
-// Please be careful of initialization order - for example, if you change
-// the global propagator, the DefaultClient might still be using the old one.
-var DefaultClient = &http.Client{Transport: NewTransport(http.DefaultTransport)}
-
-// Get is a convenient replacement for http.Get that adds a span around the request.
-func Get(ctx context.Context, targetURL string) (resp *http.Response, err error) {
- req, err := http.NewRequestWithContext(ctx, http.MethodGet, targetURL, nil)
- if err != nil {
- return nil, err
- }
- return DefaultClient.Do(req)
-}
-
-// Head is a convenient replacement for http.Head that adds a span around the request.
-func Head(ctx context.Context, targetURL string) (resp *http.Response, err error) {
- req, err := http.NewRequestWithContext(ctx, http.MethodHead, targetURL, nil)
- if err != nil {
- return nil, err
- }
- return DefaultClient.Do(req)
-}
-
-// Post is a convenient replacement for http.Post that adds a span around the request.
-func Post(ctx context.Context, targetURL, contentType string, body io.Reader) (resp *http.Response, err error) {
- req, err := http.NewRequestWithContext(ctx, http.MethodPost, targetURL, body)
- if err != nil {
- return nil, err
- }
- req.Header.Set("Content-Type", contentType)
- return DefaultClient.Do(req)
-}
-
-// PostForm is a convenient replacement for http.PostForm that adds a span around the request.
-func PostForm(ctx context.Context, targetURL string, data url.Values) (resp *http.Response, err error) {
- return Post(ctx, targetURL, "application/x-www-form-urlencoded", strings.NewReader(data.Encode()))
-}
diff --git a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/common.go b/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/common.go
index a83a026274..3ae0824344 100644
--- a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/common.go
+++ b/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/common.go
@@ -23,5 +23,5 @@ const (
type Filter func(*http.Request) bool
func newTracer(tp trace.TracerProvider) trace.Tracer {
- return tp.Tracer(ScopeName, trace.WithInstrumentationVersion(Version()))
+ return tp.Tracer(ScopeName, trace.WithInstrumentationVersion(Version))
}
diff --git a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/config.go b/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/config.go
index 6bd50d4c9b..f7338b7e52 100644
--- a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/config.go
+++ b/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/config.go
@@ -8,9 +8,8 @@ import (
"net/http"
"net/http/httptrace"
- "go.opentelemetry.io/otel/attribute"
-
"go.opentelemetry.io/otel"
+ "go.opentelemetry.io/otel/attribute"
"go.opentelemetry.io/otel/metric"
"go.opentelemetry.io/otel/propagation"
"go.opentelemetry.io/otel/trace"
@@ -27,7 +26,6 @@ type config struct {
Meter metric.Meter
Propagators propagation.TextMapPropagator
SpanStartOptions []trace.SpanStartOption
- PublicEndpoint bool
PublicEndpointFn func(*http.Request) bool
ReadEvent bool
WriteEvent bool
@@ -68,7 +66,7 @@ func newConfig(opts ...Option) *config {
c.Meter = c.MeterProvider.Meter(
ScopeName,
- metric.WithInstrumentationVersion(Version()),
+ metric.WithInstrumentationVersion(Version),
)
return c
@@ -94,20 +92,10 @@ func WithMeterProvider(provider metric.MeterProvider) Option {
})
}
-// WithPublicEndpoint configures the Handler to link the span with an incoming
-// span context. If this option is not provided, then the association is a child
-// association instead of a link.
-func WithPublicEndpoint() Option {
- return optionFunc(func(c *config) {
- c.PublicEndpoint = true
- })
-}
-
// WithPublicEndpointFn runs with every request, and allows conditionally
// configuring the Handler to link the span with an incoming span context. If
// this option is not provided or returns false, then the association is a
// child association instead of a link.
-// Note: WithPublicEndpoint takes precedence over WithPublicEndpointFn.
func WithPublicEndpointFn(fn func(*http.Request) bool) Option {
return optionFunc(func(c *config) {
c.PublicEndpointFn = fn
@@ -144,11 +132,13 @@ func WithFilter(f Filter) Option {
})
}
-type event int
+// Event represents message event types for [WithMessageEvents].
+type Event int
// Different types of events that can be recorded, see WithMessageEvents.
const (
- ReadEvents event = iota
+ unspecifiedEvents Event = iota
+ ReadEvents
WriteEvents
)
@@ -161,7 +151,7 @@ const (
// using the ReadBytesKey
// - WriteEvents: Record the number of bytes written after every http.ResponeWriter.Write
// using the WriteBytesKey
-func WithMessageEvents(events ...event) Option {
+func WithMessageEvents(events ...Event) Option {
return optionFunc(func(c *config) {
for _, e := range events {
switch e {
diff --git a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/doc.go b/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/doc.go
index 56b24b982a..1c9aa3ff42 100644
--- a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/doc.go
+++ b/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/doc.go
@@ -2,6 +2,5 @@
// SPDX-License-Identifier: Apache-2.0
// Package otelhttp provides an http.Handler and functions that are intended
-// to be used to add tracing by wrapping existing handlers (with Handler) and
-// routes WithRouteTag.
+// to be used to add tracing by wrapping existing handlers.
package otelhttp // import "go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp"
diff --git a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/handler.go b/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/handler.go
index 937f9b4e73..1ecd4be2dd 100644
--- a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/handler.go
+++ b/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/handler.go
@@ -8,13 +8,13 @@ import (
"time"
"github.com/felixge/httpsnoop"
-
- "go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/request"
- "go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv"
"go.opentelemetry.io/otel"
"go.opentelemetry.io/otel/attribute"
"go.opentelemetry.io/otel/propagation"
"go.opentelemetry.io/otel/trace"
+
+ "go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/request"
+ "go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv"
)
// middleware is an http middleware which wraps the next handler in a span.
@@ -29,7 +29,6 @@ type middleware struct {
writeEvent bool
filters []Filter
spanNameFormatter func(string, *http.Request) string
- publicEndpoint bool
publicEndpointFn func(*http.Request) bool
metricAttributesFn func(*http.Request) []attribute.KeyValue
@@ -77,7 +76,6 @@ func (h *middleware) configure(c *config) {
h.writeEvent = c.WriteEvent
h.filters = c.Filters
h.spanNameFormatter = c.SpanNameFormatter
- h.publicEndpoint = c.PublicEndpoint
h.publicEndpointFn = c.PublicEndpointFn
h.server = c.ServerName
h.semconv = semconv.NewHTTPServer(c.Meter)
@@ -102,7 +100,7 @@ func (h *middleware) serveHTTP(w http.ResponseWriter, r *http.Request, next http
}
opts = append(opts, h.spanStartOptions...)
- if h.publicEndpoint || (h.publicEndpointFn != nil && h.publicEndpointFn(r.WithContext(ctx))) {
+ if h.publicEndpointFn != nil && h.publicEndpointFn(r.WithContext(ctx)) {
opts = append(opts, trace.WithNewRoot())
// Linking incoming span context if any for public endpoint.
if s := trace.SpanContextFromContext(ctx); s.IsValid() && s.IsRemote() {
@@ -221,18 +219,3 @@ func (h *middleware) metricAttributesFromRequest(r *http.Request) []attribute.Ke
}
return attributeForRequest
}
-
-// WithRouteTag annotates spans and metrics with the provided route name
-// with HTTP route attribute.
-func WithRouteTag(route string, h http.Handler) http.Handler {
- attr := semconv.NewHTTPServer(nil).Route(route)
- return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
- span := trace.SpanFromContext(r.Context())
- span.SetAttributes(attr)
-
- labeler, _ := LabelerFromContext(r.Context())
- labeler.Add(attr)
-
- h.ServeHTTP(w, r)
- })
-}
diff --git a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv/client.go b/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv/client.go
new file mode 100644
index 0000000000..29d6f508c1
--- /dev/null
+++ b/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv/client.go
@@ -0,0 +1,287 @@
+// Code generated by gotmpl. DO NOT MODIFY.
+// source: internal/shared/semconv/client.go.tmpl
+
+// Copyright The OpenTelemetry Authors
+// SPDX-License-Identifier: Apache-2.0
+
+// Package semconv provides OpenTelemetry semantic convention types and
+// functionality.
+package semconv // import "go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv"
+
+import (
+ "context"
+ "fmt"
+ "net/http"
+ "slices"
+ "strconv"
+ "strings"
+
+ "go.opentelemetry.io/otel/attribute"
+ "go.opentelemetry.io/otel/codes"
+ "go.opentelemetry.io/otel/metric"
+ "go.opentelemetry.io/otel/semconv/v1.39.0"
+ "go.opentelemetry.io/otel/semconv/v1.39.0/httpconv"
+)
+
+type HTTPClient struct{
+ requestBodySize httpconv.ClientRequestBodySize
+ requestDuration httpconv.ClientRequestDuration
+}
+
+func NewHTTPClient(meter metric.Meter) HTTPClient {
+ client := HTTPClient{}
+
+ var err error
+ client.requestBodySize, err = httpconv.NewClientRequestBodySize(meter)
+ handleErr(err)
+
+ client.requestDuration, err = httpconv.NewClientRequestDuration(
+ meter,
+ metric.WithExplicitBucketBoundaries(0.005, 0.01, 0.025, 0.05, 0.075, 0.1, 0.25, 0.5, 0.75, 1, 2.5, 5, 7.5, 10),
+ )
+ handleErr(err)
+
+ return client
+}
+
+func (n HTTPClient) Status(code int) (codes.Code, string) {
+ if code < 100 || code >= 600 {
+ return codes.Error, fmt.Sprintf("Invalid HTTP status code %d", code)
+ }
+ if code >= 400 {
+ return codes.Error, ""
+ }
+ return codes.Unset, ""
+}
+
+// RequestTraceAttrs returns trace attributes for an HTTP request made by a client.
+func (n HTTPClient) RequestTraceAttrs(req *http.Request) []attribute.KeyValue {
+ /*
+ below attributes are returned:
+ - http.request.method
+ - http.request.method.original
+ - url.full
+ - server.address
+ - server.port
+ - network.protocol.name
+ - network.protocol.version
+ */
+ numOfAttributes := 3 // URL, server address, proto, and method.
+
+ var urlHost string
+ if req.URL != nil {
+ urlHost = req.URL.Host
+ }
+ var requestHost string
+ var requestPort int
+ for _, hostport := range []string{urlHost, req.Header.Get("Host")} {
+ requestHost, requestPort = SplitHostPort(hostport)
+ if requestHost != "" || requestPort > 0 {
+ break
+ }
+ }
+
+ eligiblePort := requiredHTTPPort(req.URL != nil && req.URL.Scheme == "https", requestPort)
+ if eligiblePort > 0 {
+ numOfAttributes++
+ }
+ useragent := req.UserAgent()
+ if useragent != "" {
+ numOfAttributes++
+ }
+
+ protoName, protoVersion := netProtocol(req.Proto)
+ if protoName != "" && protoName != "http" {
+ numOfAttributes++
+ }
+ if protoVersion != "" {
+ numOfAttributes++
+ }
+
+ method, originalMethod := n.method(req.Method)
+ if originalMethod != (attribute.KeyValue{}) {
+ numOfAttributes++
+ }
+
+ attrs := make([]attribute.KeyValue, 0, numOfAttributes)
+
+ attrs = append(attrs, method)
+ if originalMethod != (attribute.KeyValue{}) {
+ attrs = append(attrs, originalMethod)
+ }
+
+ var u string
+ if req.URL != nil {
+ // Remove any username/password info that may be in the URL.
+ userinfo := req.URL.User
+ req.URL.User = nil
+ u = req.URL.String()
+ // Restore any username/password info that was removed.
+ req.URL.User = userinfo
+ }
+ attrs = append(attrs, semconv.URLFull(u))
+
+ attrs = append(attrs, semconv.ServerAddress(requestHost))
+ if eligiblePort > 0 {
+ attrs = append(attrs, semconv.ServerPort(eligiblePort))
+ }
+
+ if protoName != "" && protoName != "http" {
+ attrs = append(attrs, semconv.NetworkProtocolName(protoName))
+ }
+ if protoVersion != "" {
+ attrs = append(attrs, semconv.NetworkProtocolVersion(protoVersion))
+ }
+
+ return attrs
+}
+
+// ResponseTraceAttrs returns trace attributes for an HTTP response made by a client.
+func (n HTTPClient) ResponseTraceAttrs(resp *http.Response) []attribute.KeyValue {
+ /*
+ below attributes are returned:
+ - http.response.status_code
+ - error.type
+ */
+ var count int
+ if resp.StatusCode > 0 {
+ count++
+ }
+
+ if isErrorStatusCode(resp.StatusCode) {
+ count++
+ }
+
+ attrs := make([]attribute.KeyValue, 0, count)
+ if resp.StatusCode > 0 {
+ attrs = append(attrs, semconv.HTTPResponseStatusCode(resp.StatusCode))
+ }
+
+ if isErrorStatusCode(resp.StatusCode) {
+ errorType := strconv.Itoa(resp.StatusCode)
+ attrs = append(attrs, semconv.ErrorTypeKey.String(errorType))
+ }
+ return attrs
+}
+
+func (n HTTPClient) method(method string) (attribute.KeyValue, attribute.KeyValue) {
+ if method == "" {
+ return semconv.HTTPRequestMethodGet, attribute.KeyValue{}
+ }
+ if attr, ok := methodLookup[method]; ok {
+ return attr, attribute.KeyValue{}
+ }
+
+ orig := semconv.HTTPRequestMethodOriginal(method)
+ if attr, ok := methodLookup[strings.ToUpper(method)]; ok {
+ return attr, orig
+ }
+ return semconv.HTTPRequestMethodGet, orig
+}
+
+func (n HTTPClient) MetricAttributes(req *http.Request, statusCode int, additionalAttributes []attribute.KeyValue) []attribute.KeyValue {
+ num := len(additionalAttributes) + 2
+ var h string
+ if req.URL != nil {
+ h = req.URL.Host
+ }
+ var requestHost string
+ var requestPort int
+ for _, hostport := range []string{h, req.Header.Get("Host")} {
+ requestHost, requestPort = SplitHostPort(hostport)
+ if requestHost != "" || requestPort > 0 {
+ break
+ }
+ }
+
+ port := requiredHTTPPort(req.URL != nil && req.URL.Scheme == "https", requestPort)
+ if port > 0 {
+ num++
+ }
+
+ protoName, protoVersion := netProtocol(req.Proto)
+ if protoName != "" {
+ num++
+ }
+ if protoVersion != "" {
+ num++
+ }
+
+ if statusCode > 0 {
+ num++
+ }
+
+ attributes := slices.Grow(additionalAttributes, num)
+ attributes = append(attributes,
+ semconv.HTTPRequestMethodKey.String(standardizeHTTPMethod(req.Method)),
+ semconv.ServerAddress(requestHost),
+ n.scheme(req),
+ )
+
+ if port > 0 {
+ attributes = append(attributes, semconv.ServerPort(port))
+ }
+ if protoName != "" {
+ attributes = append(attributes, semconv.NetworkProtocolName(protoName))
+ }
+ if protoVersion != "" {
+ attributes = append(attributes, semconv.NetworkProtocolVersion(protoVersion))
+ }
+
+ if statusCode > 0 {
+ attributes = append(attributes, semconv.HTTPResponseStatusCode(statusCode))
+ }
+ return attributes
+}
+
+type MetricOpts struct {
+ measurement metric.MeasurementOption
+ addOptions metric.AddOption
+}
+
+func (o MetricOpts) MeasurementOption() metric.MeasurementOption {
+ return o.measurement
+}
+
+func (o MetricOpts) AddOptions() metric.AddOption {
+ return o.addOptions
+}
+
+func (n HTTPClient) MetricOptions(ma MetricAttributes) map[string]MetricOpts {
+ opts := map[string]MetricOpts{}
+
+ attributes := n.MetricAttributes(ma.Req, ma.StatusCode, ma.AdditionalAttributes)
+ set := metric.WithAttributeSet(attribute.NewSet(attributes...))
+ opts["new"] = MetricOpts{
+ measurement: set,
+ addOptions: set,
+ }
+
+ return opts
+}
+
+func (n HTTPClient) RecordMetrics(ctx context.Context, md MetricData, opts map[string]MetricOpts) {
+ n.requestBodySize.Inst().Record(ctx, md.RequestSize, opts["new"].MeasurementOption())
+ n.requestDuration.Inst().Record(ctx, md.ElapsedTime/1000, opts["new"].MeasurementOption())
+}
+
+// TraceAttributes returns attributes for httptrace.
+func (n HTTPClient) TraceAttributes(host string) []attribute.KeyValue {
+ return []attribute.KeyValue{
+ semconv.ServerAddress(host),
+ }
+}
+
+func (n HTTPClient) scheme(req *http.Request) attribute.KeyValue {
+ if req.URL != nil && req.URL.Scheme != "" {
+ return semconv.URLScheme(req.URL.Scheme)
+ }
+ if req.TLS != nil {
+ return semconv.URLScheme("https")
+ }
+ return semconv.URLScheme("http")
+}
+
+func isErrorStatusCode(code int) bool {
+ return code >= 400 || code < 100
+}
diff --git a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv/env.go b/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv/env.go
deleted file mode 100644
index 7cb9693d98..0000000000
--- a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv/env.go
+++ /dev/null
@@ -1,323 +0,0 @@
-// Code generated by gotmpl. DO NOT MODIFY.
-// source: internal/shared/semconv/env.go.tmpl
-
-// Copyright The OpenTelemetry Authors
-// SPDX-License-Identifier: Apache-2.0
-
-package semconv // import "go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv"
-
-import (
- "context"
- "fmt"
- "net/http"
- "os"
- "strings"
- "sync"
-
- "go.opentelemetry.io/otel/attribute"
- "go.opentelemetry.io/otel/codes"
- "go.opentelemetry.io/otel/metric"
-)
-
-// OTelSemConvStabilityOptIn is an environment variable.
-// That can be set to "http/dup" to keep getting the old HTTP semantic conventions.
-const OTelSemConvStabilityOptIn = "OTEL_SEMCONV_STABILITY_OPT_IN"
-
-type ResponseTelemetry struct {
- StatusCode int
- ReadBytes int64
- ReadError error
- WriteBytes int64
- WriteError error
-}
-
-type HTTPServer struct {
- duplicate bool
-
- // Old metrics
- requestBytesCounter metric.Int64Counter
- responseBytesCounter metric.Int64Counter
- serverLatencyMeasure metric.Float64Histogram
-
- // New metrics
- requestBodySizeHistogram metric.Int64Histogram
- responseBodySizeHistogram metric.Int64Histogram
- requestDurationHistogram metric.Float64Histogram
-}
-
-// RequestTraceAttrs returns trace attributes for an HTTP request received by a
-// server.
-//
-// The server must be the primary server name if it is known. For example this
-// would be the ServerName directive
-// (https://httpd.apache.org/docs/2.4/mod/core.html#servername) for an Apache
-// server, and the server_name directive
-// (http://nginx.org/en/docs/http/ngx_http_core_module.html#server_name) for an
-// nginx server. More generically, the primary server name would be the host
-// header value that matches the default virtual host of an HTTP server. It
-// should include the host identifier and if a port is used to route to the
-// server that port identifier should be included as an appropriate port
-// suffix.
-//
-// If the primary server name is not known, server should be an empty string.
-// The req Host will be used to determine the server instead.
-func (s HTTPServer) RequestTraceAttrs(server string, req *http.Request, opts RequestTraceAttrsOpts) []attribute.KeyValue {
- attrs := CurrentHTTPServer{}.RequestTraceAttrs(server, req, opts)
- if s.duplicate {
- return OldHTTPServer{}.RequestTraceAttrs(server, req, attrs)
- }
- return attrs
-}
-
-func (s HTTPServer) NetworkTransportAttr(network string) []attribute.KeyValue {
- if s.duplicate {
- return []attribute.KeyValue{
- OldHTTPServer{}.NetworkTransportAttr(network),
- CurrentHTTPServer{}.NetworkTransportAttr(network),
- }
- }
- return []attribute.KeyValue{
- CurrentHTTPServer{}.NetworkTransportAttr(network),
- }
-}
-
-// ResponseTraceAttrs returns trace attributes for telemetry from an HTTP response.
-//
-// If any of the fields in the ResponseTelemetry are not set the attribute will be omitted.
-func (s HTTPServer) ResponseTraceAttrs(resp ResponseTelemetry) []attribute.KeyValue {
- attrs := CurrentHTTPServer{}.ResponseTraceAttrs(resp)
- if s.duplicate {
- return OldHTTPServer{}.ResponseTraceAttrs(resp, attrs)
- }
- return attrs
-}
-
-// Route returns the attribute for the route.
-func (s HTTPServer) Route(route string) attribute.KeyValue {
- return CurrentHTTPServer{}.Route(route)
-}
-
-// Status returns a span status code and message for an HTTP status code
-// value returned by a server. Status codes in the 400-499 range are not
-// returned as errors.
-func (s HTTPServer) Status(code int) (codes.Code, string) {
- if code < 100 || code >= 600 {
- return codes.Error, fmt.Sprintf("Invalid HTTP status code %d", code)
- }
- if code >= 500 {
- return codes.Error, ""
- }
- return codes.Unset, ""
-}
-
-type ServerMetricData struct {
- ServerName string
- ResponseSize int64
-
- MetricData
- MetricAttributes
-}
-
-type MetricAttributes struct {
- Req *http.Request
- StatusCode int
- AdditionalAttributes []attribute.KeyValue
-}
-
-type MetricData struct {
- RequestSize int64
-
- // The request duration, in milliseconds
- ElapsedTime float64
-}
-
-var (
- metricAddOptionPool = &sync.Pool{
- New: func() interface{} {
- return &[]metric.AddOption{}
- },
- }
-
- metricRecordOptionPool = &sync.Pool{
- New: func() interface{} {
- return &[]metric.RecordOption{}
- },
- }
-)
-
-func (s HTTPServer) RecordMetrics(ctx context.Context, md ServerMetricData) {
- if s.requestDurationHistogram != nil && s.requestBodySizeHistogram != nil && s.responseBodySizeHistogram != nil {
- attributes := CurrentHTTPServer{}.MetricAttributes(md.ServerName, md.Req, md.StatusCode, md.AdditionalAttributes)
- o := metric.WithAttributeSet(attribute.NewSet(attributes...))
- recordOpts := metricRecordOptionPool.Get().(*[]metric.RecordOption)
- *recordOpts = append(*recordOpts, o)
- s.requestBodySizeHistogram.Record(ctx, md.RequestSize, *recordOpts...)
- s.responseBodySizeHistogram.Record(ctx, md.ResponseSize, *recordOpts...)
- s.requestDurationHistogram.Record(ctx, md.ElapsedTime/1000.0, o)
- *recordOpts = (*recordOpts)[:0]
- metricRecordOptionPool.Put(recordOpts)
- }
-
- if s.duplicate && s.requestBytesCounter != nil && s.responseBytesCounter != nil && s.serverLatencyMeasure != nil {
- attributes := OldHTTPServer{}.MetricAttributes(md.ServerName, md.Req, md.StatusCode, md.AdditionalAttributes)
- o := metric.WithAttributeSet(attribute.NewSet(attributes...))
- addOpts := metricAddOptionPool.Get().(*[]metric.AddOption)
- *addOpts = append(*addOpts, o)
- s.requestBytesCounter.Add(ctx, md.RequestSize, *addOpts...)
- s.responseBytesCounter.Add(ctx, md.ResponseSize, *addOpts...)
- s.serverLatencyMeasure.Record(ctx, md.ElapsedTime, o)
- *addOpts = (*addOpts)[:0]
- metricAddOptionPool.Put(addOpts)
- }
-}
-
-// hasOptIn returns true if the comma-separated version string contains the
-// exact optIn value.
-func hasOptIn(version, optIn string) bool {
- for _, v := range strings.Split(version, ",") {
- if strings.TrimSpace(v) == optIn {
- return true
- }
- }
- return false
-}
-
-func NewHTTPServer(meter metric.Meter) HTTPServer {
- env := strings.ToLower(os.Getenv(OTelSemConvStabilityOptIn))
- duplicate := hasOptIn(env, "http/dup")
- server := HTTPServer{
- duplicate: duplicate,
- }
- server.requestBodySizeHistogram, server.responseBodySizeHistogram, server.requestDurationHistogram = CurrentHTTPServer{}.createMeasures(meter)
- if duplicate {
- server.requestBytesCounter, server.responseBytesCounter, server.serverLatencyMeasure = OldHTTPServer{}.createMeasures(meter)
- }
- return server
-}
-
-type HTTPClient struct {
- duplicate bool
-
- // old metrics
- requestBytesCounter metric.Int64Counter
- responseBytesCounter metric.Int64Counter
- latencyMeasure metric.Float64Histogram
-
- // new metrics
- requestBodySize metric.Int64Histogram
- requestDuration metric.Float64Histogram
-}
-
-func NewHTTPClient(meter metric.Meter) HTTPClient {
- env := strings.ToLower(os.Getenv(OTelSemConvStabilityOptIn))
- duplicate := hasOptIn(env, "http/dup")
- client := HTTPClient{
- duplicate: duplicate,
- }
- client.requestBodySize, client.requestDuration = CurrentHTTPClient{}.createMeasures(meter)
- if duplicate {
- client.requestBytesCounter, client.responseBytesCounter, client.latencyMeasure = OldHTTPClient{}.createMeasures(meter)
- }
-
- return client
-}
-
-// RequestTraceAttrs returns attributes for an HTTP request made by a client.
-func (c HTTPClient) RequestTraceAttrs(req *http.Request) []attribute.KeyValue {
- attrs := CurrentHTTPClient{}.RequestTraceAttrs(req)
- if c.duplicate {
- return OldHTTPClient{}.RequestTraceAttrs(req, attrs)
- }
- return attrs
-}
-
-// ResponseTraceAttrs returns metric attributes for an HTTP request made by a client.
-func (c HTTPClient) ResponseTraceAttrs(resp *http.Response) []attribute.KeyValue {
- attrs := CurrentHTTPClient{}.ResponseTraceAttrs(resp)
- if c.duplicate {
- return OldHTTPClient{}.ResponseTraceAttrs(resp, attrs)
- }
- return attrs
-}
-
-func (c HTTPClient) Status(code int) (codes.Code, string) {
- if code < 100 || code >= 600 {
- return codes.Error, fmt.Sprintf("Invalid HTTP status code %d", code)
- }
- if code >= 400 {
- return codes.Error, ""
- }
- return codes.Unset, ""
-}
-
-func (c HTTPClient) ErrorType(err error) attribute.KeyValue {
- return CurrentHTTPClient{}.ErrorType(err)
-}
-
-type MetricOpts struct {
- measurement metric.MeasurementOption
- addOptions metric.AddOption
-}
-
-func (o MetricOpts) MeasurementOption() metric.MeasurementOption {
- return o.measurement
-}
-
-func (o MetricOpts) AddOptions() metric.AddOption {
- return o.addOptions
-}
-
-func (c HTTPClient) MetricOptions(ma MetricAttributes) map[string]MetricOpts {
- opts := map[string]MetricOpts{}
-
- attributes := CurrentHTTPClient{}.MetricAttributes(ma.Req, ma.StatusCode, ma.AdditionalAttributes)
- set := metric.WithAttributeSet(attribute.NewSet(attributes...))
- opts["new"] = MetricOpts{
- measurement: set,
- addOptions: set,
- }
-
- if c.duplicate {
- attributes := OldHTTPClient{}.MetricAttributes(ma.Req, ma.StatusCode, ma.AdditionalAttributes)
- set := metric.WithAttributeSet(attribute.NewSet(attributes...))
- opts["old"] = MetricOpts{
- measurement: set,
- addOptions: set,
- }
- }
-
- return opts
-}
-
-func (s HTTPClient) RecordMetrics(ctx context.Context, md MetricData, opts map[string]MetricOpts) {
- if s.requestBodySize == nil || s.requestDuration == nil {
- // This will happen if an HTTPClient{} is used instead of NewHTTPClient().
- return
- }
-
- s.requestBodySize.Record(ctx, md.RequestSize, opts["new"].MeasurementOption())
- s.requestDuration.Record(ctx, md.ElapsedTime/1000, opts["new"].MeasurementOption())
-
- if s.duplicate {
- s.requestBytesCounter.Add(ctx, md.RequestSize, opts["old"].AddOptions())
- s.latencyMeasure.Record(ctx, md.ElapsedTime, opts["old"].MeasurementOption())
- }
-}
-
-func (s HTTPClient) RecordResponseSize(ctx context.Context, responseData int64, opts map[string]MetricOpts) {
- if s.responseBytesCounter == nil {
- // This will happen if an HTTPClient{} is used instead of NewHTTPClient().
- return
- }
-
- s.responseBytesCounter.Add(ctx, responseData, opts["old"].AddOptions())
-}
-
-func (s HTTPClient) TraceAttributes(host string) []attribute.KeyValue {
- attrs := CurrentHTTPClient{}.TraceAttributes(host)
- if s.duplicate {
- return OldHTTPClient{}.TraceAttributes(host, attrs)
- }
-
- return attrs
-}
diff --git a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv/gen.go b/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv/gen.go
index f2cf8a152d..a8a0d58df3 100644
--- a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv/gen.go
+++ b/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv/gen.go
@@ -5,10 +5,11 @@ package semconv // import "go.opentelemetry.io/contrib/instrumentation/net/http/
// Generate semconv package:
//go:generate gotmpl --body=../../../../../../internal/shared/semconv/bench_test.go.tmpl "--data={ \"pkg\": \"go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp\" }" --out=bench_test.go
-//go:generate gotmpl --body=../../../../../../internal/shared/semconv/env.go.tmpl "--data={ \"pkg\": \"go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp\" }" --out=env.go
-//go:generate gotmpl --body=../../../../../../internal/shared/semconv/env_test.go.tmpl "--data={ \"pkg\": \"go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp\" }" --out=env_test.go
-//go:generate gotmpl --body=../../../../../../internal/shared/semconv/httpconv.go.tmpl "--data={ \"pkg\": \"go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp\" }" --out=httpconv.go
-//go:generate gotmpl --body=../../../../../../internal/shared/semconv/httpconv_test.go.tmpl "--data={ \"pkg\": \"go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp\" }" --out=httpconv_test.go
+//go:generate gotmpl --body=../../../../../../internal/shared/semconv/common_test.go.tmpl "--data={ \"pkg\": \"go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp\" }" --out=common_test.go
+//go:generate gotmpl --body=../../../../../../internal/shared/semconv/server.go.tmpl "--data={ \"pkg\": \"go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp\" }" --out=server.go
+//go:generate gotmpl --body=../../../../../../internal/shared/semconv/server_test.go.tmpl "--data={ \"pkg\": \"go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp\" }" --out=server_test.go
+//go:generate gotmpl --body=../../../../../../internal/shared/semconv/client.go.tmpl "--data={ \"pkg\": \"go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp\" }" --out=client.go
+//go:generate gotmpl --body=../../../../../../internal/shared/semconv/client_test.go.tmpl "--data={ \"pkg\": \"go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp\" }" --out=client_test.go
+//go:generate gotmpl --body=../../../../../../internal/shared/semconv/httpconvtest_test.go.tmpl "--data={ \"pkg\": \"go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp\" }" --out=httpconvtest_test.go
//go:generate gotmpl --body=../../../../../../internal/shared/semconv/util.go.tmpl "--data={ \"pkg\": \"go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp\" }" --out=util.go
//go:generate gotmpl --body=../../../../../../internal/shared/semconv/util_test.go.tmpl "--data={ \"pkg\": \"go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp\" }" --out=util_test.go
-//go:generate gotmpl --body=../../../../../../internal/shared/semconv/v1.20.0.go.tmpl "--data={ \"pkg\": \"go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp\" }" --out=v1.20.0.go
diff --git a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv/httpconv.go b/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv/httpconv.go
deleted file mode 100644
index 53976b0d5a..0000000000
--- a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv/httpconv.go
+++ /dev/null
@@ -1,573 +0,0 @@
-// Code generated by gotmpl. DO NOT MODIFY.
-// source: internal/shared/semconv/httpconv.go.tmpl
-
-// Copyright The OpenTelemetry Authors
-// SPDX-License-Identifier: Apache-2.0
-
-// Package semconv provides OpenTelemetry semantic convention types and
-// functionality.
-package semconv // import "go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv"
-
-import (
- "fmt"
- "net/http"
- "reflect"
- "slices"
- "strconv"
- "strings"
-
- "go.opentelemetry.io/otel/attribute"
- "go.opentelemetry.io/otel/metric"
- "go.opentelemetry.io/otel/metric/noop"
- semconvNew "go.opentelemetry.io/otel/semconv/v1.26.0"
-)
-
-type RequestTraceAttrsOpts struct {
- // If set, this is used as value for the "http.client_ip" attribute.
- HTTPClientIP string
-}
-
-type CurrentHTTPServer struct{}
-
-// RequestTraceAttrs returns trace attributes for an HTTP request received by a
-// server.
-//
-// The server must be the primary server name if it is known. For example this
-// would be the ServerName directive
-// (https://httpd.apache.org/docs/2.4/mod/core.html#servername) for an Apache
-// server, and the server_name directive
-// (http://nginx.org/en/docs/http/ngx_http_core_module.html#server_name) for an
-// nginx server. More generically, the primary server name would be the host
-// header value that matches the default virtual host of an HTTP server. It
-// should include the host identifier and if a port is used to route to the
-// server that port identifier should be included as an appropriate port
-// suffix.
-//
-// If the primary server name is not known, server should be an empty string.
-// The req Host will be used to determine the server instead.
-func (n CurrentHTTPServer) RequestTraceAttrs(server string, req *http.Request, opts RequestTraceAttrsOpts) []attribute.KeyValue {
- count := 3 // ServerAddress, Method, Scheme
-
- var host string
- var p int
- if server == "" {
- host, p = SplitHostPort(req.Host)
- } else {
- // Prioritize the primary server name.
- host, p = SplitHostPort(server)
- if p < 0 {
- _, p = SplitHostPort(req.Host)
- }
- }
-
- hostPort := requiredHTTPPort(req.TLS != nil, p)
- if hostPort > 0 {
- count++
- }
-
- method, methodOriginal := n.method(req.Method)
- if methodOriginal != (attribute.KeyValue{}) {
- count++
- }
-
- scheme := n.scheme(req.TLS != nil)
-
- peer, peerPort := SplitHostPort(req.RemoteAddr)
- if peer != "" {
- // The Go HTTP server sets RemoteAddr to "IP:port", this will not be a
- // file-path that would be interpreted with a sock family.
- count++
- if peerPort > 0 {
- count++
- }
- }
-
- useragent := req.UserAgent()
- if useragent != "" {
- count++
- }
-
- // For client IP, use, in order:
- // 1. The value passed in the options
- // 2. The value in the X-Forwarded-For header
- // 3. The peer address
- clientIP := opts.HTTPClientIP
- if clientIP == "" {
- clientIP = serverClientIP(req.Header.Get("X-Forwarded-For"))
- if clientIP == "" {
- clientIP = peer
- }
- }
- if clientIP != "" {
- count++
- }
-
- if req.URL != nil && req.URL.Path != "" {
- count++
- }
-
- protoName, protoVersion := netProtocol(req.Proto)
- if protoName != "" && protoName != "http" {
- count++
- }
- if protoVersion != "" {
- count++
- }
-
- route := httpRoute(req.Pattern)
- if route != "" {
- count++
- }
-
- attrs := make([]attribute.KeyValue, 0, count)
- attrs = append(attrs,
- semconvNew.ServerAddress(host),
- method,
- scheme,
- )
-
- if hostPort > 0 {
- attrs = append(attrs, semconvNew.ServerPort(hostPort))
- }
- if methodOriginal != (attribute.KeyValue{}) {
- attrs = append(attrs, methodOriginal)
- }
-
- if peer, peerPort := SplitHostPort(req.RemoteAddr); peer != "" {
- // The Go HTTP server sets RemoteAddr to "IP:port", this will not be a
- // file-path that would be interpreted with a sock family.
- attrs = append(attrs, semconvNew.NetworkPeerAddress(peer))
- if peerPort > 0 {
- attrs = append(attrs, semconvNew.NetworkPeerPort(peerPort))
- }
- }
-
- if useragent != "" {
- attrs = append(attrs, semconvNew.UserAgentOriginal(useragent))
- }
-
- if clientIP != "" {
- attrs = append(attrs, semconvNew.ClientAddress(clientIP))
- }
-
- if req.URL != nil && req.URL.Path != "" {
- attrs = append(attrs, semconvNew.URLPath(req.URL.Path))
- }
-
- if protoName != "" && protoName != "http" {
- attrs = append(attrs, semconvNew.NetworkProtocolName(protoName))
- }
- if protoVersion != "" {
- attrs = append(attrs, semconvNew.NetworkProtocolVersion(protoVersion))
- }
-
- if route != "" {
- attrs = append(attrs, n.Route(route))
- }
-
- return attrs
-}
-
-func (n CurrentHTTPServer) NetworkTransportAttr(network string) attribute.KeyValue {
- switch network {
- case "tcp", "tcp4", "tcp6":
- return semconvNew.NetworkTransportTCP
- case "udp", "udp4", "udp6":
- return semconvNew.NetworkTransportUDP
- case "unix", "unixgram", "unixpacket":
- return semconvNew.NetworkTransportUnix
- default:
- return semconvNew.NetworkTransportPipe
- }
-}
-
-func (n CurrentHTTPServer) method(method string) (attribute.KeyValue, attribute.KeyValue) {
- if method == "" {
- return semconvNew.HTTPRequestMethodGet, attribute.KeyValue{}
- }
- if attr, ok := methodLookup[method]; ok {
- return attr, attribute.KeyValue{}
- }
-
- orig := semconvNew.HTTPRequestMethodOriginal(method)
- if attr, ok := methodLookup[strings.ToUpper(method)]; ok {
- return attr, orig
- }
- return semconvNew.HTTPRequestMethodGet, orig
-}
-
-func (n CurrentHTTPServer) scheme(https bool) attribute.KeyValue { // nolint:revive
- if https {
- return semconvNew.URLScheme("https")
- }
- return semconvNew.URLScheme("http")
-}
-
-// ResponseTraceAttrs returns trace attributes for telemetry from an HTTP
-// response.
-//
-// If any of the fields in the ResponseTelemetry are not set the attribute will
-// be omitted.
-func (n CurrentHTTPServer) ResponseTraceAttrs(resp ResponseTelemetry) []attribute.KeyValue {
- var count int
-
- if resp.ReadBytes > 0 {
- count++
- }
- if resp.WriteBytes > 0 {
- count++
- }
- if resp.StatusCode > 0 {
- count++
- }
-
- attributes := make([]attribute.KeyValue, 0, count)
-
- if resp.ReadBytes > 0 {
- attributes = append(attributes,
- semconvNew.HTTPRequestBodySize(int(resp.ReadBytes)),
- )
- }
- if resp.WriteBytes > 0 {
- attributes = append(attributes,
- semconvNew.HTTPResponseBodySize(int(resp.WriteBytes)),
- )
- }
- if resp.StatusCode > 0 {
- attributes = append(attributes,
- semconvNew.HTTPResponseStatusCode(resp.StatusCode),
- )
- }
-
- return attributes
-}
-
-// Route returns the attribute for the route.
-func (n CurrentHTTPServer) Route(route string) attribute.KeyValue {
- return semconvNew.HTTPRoute(route)
-}
-
-func (n CurrentHTTPServer) createMeasures(meter metric.Meter) (metric.Int64Histogram, metric.Int64Histogram, metric.Float64Histogram) {
- if meter == nil {
- return noop.Int64Histogram{}, noop.Int64Histogram{}, noop.Float64Histogram{}
- }
-
- var err error
- requestBodySizeHistogram, err := meter.Int64Histogram(
- semconvNew.HTTPServerRequestBodySizeName,
- metric.WithUnit(semconvNew.HTTPServerRequestBodySizeUnit),
- metric.WithDescription(semconvNew.HTTPServerRequestBodySizeDescription),
- )
- handleErr(err)
-
- responseBodySizeHistogram, err := meter.Int64Histogram(
- semconvNew.HTTPServerResponseBodySizeName,
- metric.WithUnit(semconvNew.HTTPServerResponseBodySizeUnit),
- metric.WithDescription(semconvNew.HTTPServerResponseBodySizeDescription),
- )
- handleErr(err)
- requestDurationHistogram, err := meter.Float64Histogram(
- semconvNew.HTTPServerRequestDurationName,
- metric.WithUnit(semconvNew.HTTPServerRequestDurationUnit),
- metric.WithDescription(semconvNew.HTTPServerRequestDurationDescription),
- metric.WithExplicitBucketBoundaries(0.005, 0.01, 0.025, 0.05, 0.075, 0.1, 0.25, 0.5, 0.75, 1, 2.5, 5, 7.5, 10),
- )
- handleErr(err)
-
- return requestBodySizeHistogram, responseBodySizeHistogram, requestDurationHistogram
-}
-
-func (n CurrentHTTPServer) MetricAttributes(server string, req *http.Request, statusCode int, additionalAttributes []attribute.KeyValue) []attribute.KeyValue {
- num := len(additionalAttributes) + 3
- var host string
- var p int
- if server == "" {
- host, p = SplitHostPort(req.Host)
- } else {
- // Prioritize the primary server name.
- host, p = SplitHostPort(server)
- if p < 0 {
- _, p = SplitHostPort(req.Host)
- }
- }
- hostPort := requiredHTTPPort(req.TLS != nil, p)
- if hostPort > 0 {
- num++
- }
- protoName, protoVersion := netProtocol(req.Proto)
- if protoName != "" {
- num++
- }
- if protoVersion != "" {
- num++
- }
-
- if statusCode > 0 {
- num++
- }
-
- attributes := slices.Grow(additionalAttributes, num)
- attributes = append(attributes,
- semconvNew.HTTPRequestMethodKey.String(standardizeHTTPMethod(req.Method)),
- n.scheme(req.TLS != nil),
- semconvNew.ServerAddress(host))
-
- if hostPort > 0 {
- attributes = append(attributes, semconvNew.ServerPort(hostPort))
- }
- if protoName != "" {
- attributes = append(attributes, semconvNew.NetworkProtocolName(protoName))
- }
- if protoVersion != "" {
- attributes = append(attributes, semconvNew.NetworkProtocolVersion(protoVersion))
- }
-
- if statusCode > 0 {
- attributes = append(attributes, semconvNew.HTTPResponseStatusCode(statusCode))
- }
- return attributes
-}
-
-type CurrentHTTPClient struct{}
-
-// RequestTraceAttrs returns trace attributes for an HTTP request made by a client.
-func (n CurrentHTTPClient) RequestTraceAttrs(req *http.Request) []attribute.KeyValue {
- /*
- below attributes are returned:
- - http.request.method
- - http.request.method.original
- - url.full
- - server.address
- - server.port
- - network.protocol.name
- - network.protocol.version
- */
- numOfAttributes := 3 // URL, server address, proto, and method.
-
- var urlHost string
- if req.URL != nil {
- urlHost = req.URL.Host
- }
- var requestHost string
- var requestPort int
- for _, hostport := range []string{urlHost, req.Header.Get("Host")} {
- requestHost, requestPort = SplitHostPort(hostport)
- if requestHost != "" || requestPort > 0 {
- break
- }
- }
-
- eligiblePort := requiredHTTPPort(req.URL != nil && req.URL.Scheme == "https", requestPort)
- if eligiblePort > 0 {
- numOfAttributes++
- }
- useragent := req.UserAgent()
- if useragent != "" {
- numOfAttributes++
- }
-
- protoName, protoVersion := netProtocol(req.Proto)
- if protoName != "" && protoName != "http" {
- numOfAttributes++
- }
- if protoVersion != "" {
- numOfAttributes++
- }
-
- method, originalMethod := n.method(req.Method)
- if originalMethod != (attribute.KeyValue{}) {
- numOfAttributes++
- }
-
- attrs := make([]attribute.KeyValue, 0, numOfAttributes)
-
- attrs = append(attrs, method)
- if originalMethod != (attribute.KeyValue{}) {
- attrs = append(attrs, originalMethod)
- }
-
- var u string
- if req.URL != nil {
- // Remove any username/password info that may be in the URL.
- userinfo := req.URL.User
- req.URL.User = nil
- u = req.URL.String()
- // Restore any username/password info that was removed.
- req.URL.User = userinfo
- }
- attrs = append(attrs, semconvNew.URLFull(u))
-
- attrs = append(attrs, semconvNew.ServerAddress(requestHost))
- if eligiblePort > 0 {
- attrs = append(attrs, semconvNew.ServerPort(eligiblePort))
- }
-
- if protoName != "" && protoName != "http" {
- attrs = append(attrs, semconvNew.NetworkProtocolName(protoName))
- }
- if protoVersion != "" {
- attrs = append(attrs, semconvNew.NetworkProtocolVersion(protoVersion))
- }
-
- return attrs
-}
-
-// ResponseTraceAttrs returns trace attributes for an HTTP response made by a client.
-func (n CurrentHTTPClient) ResponseTraceAttrs(resp *http.Response) []attribute.KeyValue {
- /*
- below attributes are returned:
- - http.response.status_code
- - error.type
- */
- var count int
- if resp.StatusCode > 0 {
- count++
- }
-
- if isErrorStatusCode(resp.StatusCode) {
- count++
- }
-
- attrs := make([]attribute.KeyValue, 0, count)
- if resp.StatusCode > 0 {
- attrs = append(attrs, semconvNew.HTTPResponseStatusCode(resp.StatusCode))
- }
-
- if isErrorStatusCode(resp.StatusCode) {
- errorType := strconv.Itoa(resp.StatusCode)
- attrs = append(attrs, semconvNew.ErrorTypeKey.String(errorType))
- }
- return attrs
-}
-
-func (n CurrentHTTPClient) ErrorType(err error) attribute.KeyValue {
- t := reflect.TypeOf(err)
- var value string
- if t.PkgPath() == "" && t.Name() == "" {
- // Likely a builtin type.
- value = t.String()
- } else {
- value = fmt.Sprintf("%s.%s", t.PkgPath(), t.Name())
- }
-
- if value == "" {
- return semconvNew.ErrorTypeOther
- }
-
- return semconvNew.ErrorTypeKey.String(value)
-}
-
-func (n CurrentHTTPClient) method(method string) (attribute.KeyValue, attribute.KeyValue) {
- if method == "" {
- return semconvNew.HTTPRequestMethodGet, attribute.KeyValue{}
- }
- if attr, ok := methodLookup[method]; ok {
- return attr, attribute.KeyValue{}
- }
-
- orig := semconvNew.HTTPRequestMethodOriginal(method)
- if attr, ok := methodLookup[strings.ToUpper(method)]; ok {
- return attr, orig
- }
- return semconvNew.HTTPRequestMethodGet, orig
-}
-
-func (n CurrentHTTPClient) createMeasures(meter metric.Meter) (metric.Int64Histogram, metric.Float64Histogram) {
- if meter == nil {
- return noop.Int64Histogram{}, noop.Float64Histogram{}
- }
-
- var err error
- requestBodySize, err := meter.Int64Histogram(
- semconvNew.HTTPClientRequestBodySizeName,
- metric.WithUnit(semconvNew.HTTPClientRequestBodySizeUnit),
- metric.WithDescription(semconvNew.HTTPClientRequestBodySizeDescription),
- )
- handleErr(err)
-
- requestDuration, err := meter.Float64Histogram(
- semconvNew.HTTPClientRequestDurationName,
- metric.WithUnit(semconvNew.HTTPClientRequestDurationUnit),
- metric.WithDescription(semconvNew.HTTPClientRequestDurationDescription),
- metric.WithExplicitBucketBoundaries(0.005, 0.01, 0.025, 0.05, 0.075, 0.1, 0.25, 0.5, 0.75, 1, 2.5, 5, 7.5, 10),
- )
- handleErr(err)
-
- return requestBodySize, requestDuration
-}
-
-func (n CurrentHTTPClient) MetricAttributes(req *http.Request, statusCode int, additionalAttributes []attribute.KeyValue) []attribute.KeyValue {
- num := len(additionalAttributes) + 2
- var h string
- if req.URL != nil {
- h = req.URL.Host
- }
- var requestHost string
- var requestPort int
- for _, hostport := range []string{h, req.Header.Get("Host")} {
- requestHost, requestPort = SplitHostPort(hostport)
- if requestHost != "" || requestPort > 0 {
- break
- }
- }
-
- port := requiredHTTPPort(req.URL != nil && req.URL.Scheme == "https", requestPort)
- if port > 0 {
- num++
- }
-
- protoName, protoVersion := netProtocol(req.Proto)
- if protoName != "" {
- num++
- }
- if protoVersion != "" {
- num++
- }
-
- if statusCode > 0 {
- num++
- }
-
- attributes := slices.Grow(additionalAttributes, num)
- attributes = append(attributes,
- semconvNew.HTTPRequestMethodKey.String(standardizeHTTPMethod(req.Method)),
- semconvNew.ServerAddress(requestHost),
- n.scheme(req),
- )
-
- if port > 0 {
- attributes = append(attributes, semconvNew.ServerPort(port))
- }
- if protoName != "" {
- attributes = append(attributes, semconvNew.NetworkProtocolName(protoName))
- }
- if protoVersion != "" {
- attributes = append(attributes, semconvNew.NetworkProtocolVersion(protoVersion))
- }
-
- if statusCode > 0 {
- attributes = append(attributes, semconvNew.HTTPResponseStatusCode(statusCode))
- }
- return attributes
-}
-
-// TraceAttributes returns attributes for httptrace.
-func (n CurrentHTTPClient) TraceAttributes(host string) []attribute.KeyValue {
- return []attribute.KeyValue{
- semconvNew.ServerAddress(host),
- }
-}
-
-func (n CurrentHTTPClient) scheme(req *http.Request) attribute.KeyValue {
- if req.URL != nil && req.URL.Scheme != "" {
- return semconvNew.URLScheme(req.URL.Scheme)
- }
- if req.TLS != nil {
- return semconvNew.URLScheme("https")
- }
- return semconvNew.URLScheme("http")
-}
-
-func isErrorStatusCode(code int) bool {
- return code >= 400 || code < 100
-}
diff --git a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv/server.go b/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv/server.go
new file mode 100644
index 0000000000..e0e9ebc05d
--- /dev/null
+++ b/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv/server.go
@@ -0,0 +1,403 @@
+// Code generated by gotmpl. DO NOT MODIFY.
+// source: internal/shared/semconv/server.go.tmpl
+
+// Copyright The OpenTelemetry Authors
+// SPDX-License-Identifier: Apache-2.0
+
+// Package semconv provides OpenTelemetry semantic convention types and
+// functionality.
+package semconv // import "go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv"
+
+import (
+ "context"
+ "fmt"
+ "net/http"
+ "slices"
+ "strings"
+ "sync"
+
+ "go.opentelemetry.io/otel/attribute"
+ "go.opentelemetry.io/otel/codes"
+ "go.opentelemetry.io/otel/metric"
+ "go.opentelemetry.io/otel/semconv/v1.39.0"
+ "go.opentelemetry.io/otel/semconv/v1.39.0/httpconv"
+)
+
+type RequestTraceAttrsOpts struct {
+ // If set, this is used as value for the "http.client_ip" attribute.
+ HTTPClientIP string
+}
+
+type ResponseTelemetry struct {
+ StatusCode int
+ ReadBytes int64
+ ReadError error
+ WriteBytes int64
+ WriteError error
+}
+
+type HTTPServer struct{
+ requestBodySizeHistogram httpconv.ServerRequestBodySize
+ responseBodySizeHistogram httpconv.ServerResponseBodySize
+ requestDurationHistogram httpconv.ServerRequestDuration
+}
+
+func NewHTTPServer(meter metric.Meter) HTTPServer {
+ server := HTTPServer{}
+
+ var err error
+ server.requestBodySizeHistogram, err = httpconv.NewServerRequestBodySize(meter)
+ handleErr(err)
+
+ server.responseBodySizeHistogram, err = httpconv.NewServerResponseBodySize(meter)
+ handleErr(err)
+
+ server.requestDurationHistogram, err = httpconv.NewServerRequestDuration(
+ meter,
+ metric.WithExplicitBucketBoundaries(
+ 0.005, 0.01, 0.025, 0.05, 0.075, 0.1,
+ 0.25, 0.5, 0.75, 1, 2.5, 5, 7.5, 10,
+ ),
+ )
+ handleErr(err)
+ return server
+}
+
+// Status returns a span status code and message for an HTTP status code
+// value returned by a server. Status codes in the 400-499 range are not
+// returned as errors.
+func (n HTTPServer) Status(code int) (codes.Code, string) {
+ if code < 100 || code >= 600 {
+ return codes.Error, fmt.Sprintf("Invalid HTTP status code %d", code)
+ }
+ if code >= 500 {
+ return codes.Error, ""
+ }
+ return codes.Unset, ""
+}
+
+// RequestTraceAttrs returns trace attributes for an HTTP request received by a
+// server.
+//
+// The server must be the primary server name if it is known. For example this
+// would be the ServerName directive
+// (https://httpd.apache.org/docs/2.4/mod/core.html#servername) for an Apache
+// server, and the server_name directive
+// (http://nginx.org/en/docs/http/ngx_http_core_module.html#server_name) for an
+// nginx server. More generically, the primary server name would be the host
+// header value that matches the default virtual host of an HTTP server. It
+// should include the host identifier and if a port is used to route to the
+// server that port identifier should be included as an appropriate port
+// suffix.
+//
+// If the primary server name is not known, server should be an empty string.
+// The req Host will be used to determine the server instead.
+func (n HTTPServer) RequestTraceAttrs(server string, req *http.Request, opts RequestTraceAttrsOpts) []attribute.KeyValue {
+ count := 3 // ServerAddress, Method, Scheme
+
+ var host string
+ var p int
+ if server == "" {
+ host, p = SplitHostPort(req.Host)
+ } else {
+ // Prioritize the primary server name.
+ host, p = SplitHostPort(server)
+ if p < 0 {
+ _, p = SplitHostPort(req.Host)
+ }
+ }
+
+ hostPort := requiredHTTPPort(req.TLS != nil, p)
+ if hostPort > 0 {
+ count++
+ }
+
+ method, methodOriginal := n.method(req.Method)
+ if methodOriginal != (attribute.KeyValue{}) {
+ count++
+ }
+
+ scheme := n.scheme(req.TLS != nil)
+
+ peer, peerPort := SplitHostPort(req.RemoteAddr)
+ if peer != "" {
+ // The Go HTTP server sets RemoteAddr to "IP:port", this will not be a
+ // file-path that would be interpreted with a sock family.
+ count++
+ if peerPort > 0 {
+ count++
+ }
+ }
+
+ useragent := req.UserAgent()
+ if useragent != "" {
+ count++
+ }
+
+ // For client IP, use, in order:
+ // 1. The value passed in the options
+ // 2. The value in the X-Forwarded-For header
+ // 3. The peer address
+ clientIP := opts.HTTPClientIP
+ if clientIP == "" {
+ clientIP = serverClientIP(req.Header.Get("X-Forwarded-For"))
+ if clientIP == "" {
+ clientIP = peer
+ }
+ }
+ if clientIP != "" {
+ count++
+ }
+
+ if req.URL != nil && req.URL.Path != "" {
+ count++
+ }
+
+ protoName, protoVersion := netProtocol(req.Proto)
+ if protoName != "" && protoName != "http" {
+ count++
+ }
+ if protoVersion != "" {
+ count++
+ }
+
+ route := httpRoute(req.Pattern)
+ if route != "" {
+ count++
+ }
+
+ attrs := make([]attribute.KeyValue, 0, count)
+ attrs = append(attrs,
+ semconv.ServerAddress(host),
+ method,
+ scheme,
+ )
+
+ if hostPort > 0 {
+ attrs = append(attrs, semconv.ServerPort(hostPort))
+ }
+ if methodOriginal != (attribute.KeyValue{}) {
+ attrs = append(attrs, methodOriginal)
+ }
+
+ if peer, peerPort := SplitHostPort(req.RemoteAddr); peer != "" {
+ // The Go HTTP server sets RemoteAddr to "IP:port", this will not be a
+ // file-path that would be interpreted with a sock family.
+ attrs = append(attrs, semconv.NetworkPeerAddress(peer))
+ if peerPort > 0 {
+ attrs = append(attrs, semconv.NetworkPeerPort(peerPort))
+ }
+ }
+
+ if useragent != "" {
+ attrs = append(attrs, semconv.UserAgentOriginal(useragent))
+ }
+
+ if clientIP != "" {
+ attrs = append(attrs, semconv.ClientAddress(clientIP))
+ }
+
+ if req.URL != nil && req.URL.Path != "" {
+ attrs = append(attrs, semconv.URLPath(req.URL.Path))
+ }
+
+ if protoName != "" && protoName != "http" {
+ attrs = append(attrs, semconv.NetworkProtocolName(protoName))
+ }
+ if protoVersion != "" {
+ attrs = append(attrs, semconv.NetworkProtocolVersion(protoVersion))
+ }
+
+ if route != "" {
+ attrs = append(attrs, n.Route(route))
+ }
+
+ return attrs
+}
+
+func (s HTTPServer) NetworkTransportAttr(network string) []attribute.KeyValue {
+ attr := semconv.NetworkTransportPipe
+ switch network {
+ case "tcp", "tcp4", "tcp6":
+ attr = semconv.NetworkTransportTCP
+ case "udp", "udp4", "udp6":
+ attr = semconv.NetworkTransportUDP
+ case "unix", "unixgram", "unixpacket":
+ attr = semconv.NetworkTransportUnix
+ }
+
+ return []attribute.KeyValue{attr}
+}
+
+type ServerMetricData struct {
+ ServerName string
+ ResponseSize int64
+
+ MetricData
+ MetricAttributes
+}
+
+type MetricAttributes struct {
+ Req *http.Request
+ StatusCode int
+ Route string
+ AdditionalAttributes []attribute.KeyValue
+}
+
+type MetricData struct {
+ RequestSize int64
+
+ // The request duration, in milliseconds
+ ElapsedTime float64
+}
+
+var (
+ metricAddOptionPool = &sync.Pool{
+ New: func() any {
+ return &[]metric.AddOption{}
+ },
+ }
+
+ metricRecordOptionPool = &sync.Pool{
+ New: func() any {
+ return &[]metric.RecordOption{}
+ },
+ }
+)
+
+func (n HTTPServer) RecordMetrics(ctx context.Context, md ServerMetricData) {
+ attributes := n.MetricAttributes(md.ServerName, md.Req, md.StatusCode, md.Route, md.AdditionalAttributes)
+ o := metric.WithAttributeSet(attribute.NewSet(attributes...))
+ recordOpts := metricRecordOptionPool.Get().(*[]metric.RecordOption)
+ *recordOpts = append(*recordOpts, o)
+ n.requestBodySizeHistogram.Inst().Record(ctx, md.RequestSize, *recordOpts...)
+ n.responseBodySizeHistogram.Inst().Record(ctx, md.ResponseSize, *recordOpts...)
+ n.requestDurationHistogram.Inst().Record(ctx, md.ElapsedTime/1000.0, o)
+ *recordOpts = (*recordOpts)[:0]
+ metricRecordOptionPool.Put(recordOpts)
+}
+
+func (n HTTPServer) method(method string) (attribute.KeyValue, attribute.KeyValue) {
+ if method == "" {
+ return semconv.HTTPRequestMethodGet, attribute.KeyValue{}
+ }
+ if attr, ok := methodLookup[method]; ok {
+ return attr, attribute.KeyValue{}
+ }
+
+ orig := semconv.HTTPRequestMethodOriginal(method)
+ if attr, ok := methodLookup[strings.ToUpper(method)]; ok {
+ return attr, orig
+ }
+ return semconv.HTTPRequestMethodGet, orig
+}
+
+func (n HTTPServer) scheme(https bool) attribute.KeyValue { //nolint:revive // ignore linter
+ if https {
+ return semconv.URLScheme("https")
+ }
+ return semconv.URLScheme("http")
+}
+
+// ResponseTraceAttrs returns trace attributes for telemetry from an HTTP
+// response.
+//
+// If any of the fields in the ResponseTelemetry are not set the attribute will
+// be omitted.
+func (n HTTPServer) ResponseTraceAttrs(resp ResponseTelemetry) []attribute.KeyValue {
+ var count int
+
+ if resp.ReadBytes > 0 {
+ count++
+ }
+ if resp.WriteBytes > 0 {
+ count++
+ }
+ if resp.StatusCode > 0 {
+ count++
+ }
+
+ attributes := make([]attribute.KeyValue, 0, count)
+
+ if resp.ReadBytes > 0 {
+ attributes = append(attributes,
+ semconv.HTTPRequestBodySize(int(resp.ReadBytes)),
+ )
+ }
+ if resp.WriteBytes > 0 {
+ attributes = append(attributes,
+ semconv.HTTPResponseBodySize(int(resp.WriteBytes)),
+ )
+ }
+ if resp.StatusCode > 0 {
+ attributes = append(attributes,
+ semconv.HTTPResponseStatusCode(resp.StatusCode),
+ )
+ }
+
+ return attributes
+}
+
+// Route returns the attribute for the route.
+func (n HTTPServer) Route(route string) attribute.KeyValue {
+ return semconv.HTTPRoute(route)
+}
+
+func (n HTTPServer) MetricAttributes(server string, req *http.Request, statusCode int, route string, additionalAttributes []attribute.KeyValue) []attribute.KeyValue {
+ num := len(additionalAttributes) + 3
+ var host string
+ var p int
+ if server == "" {
+ host, p = SplitHostPort(req.Host)
+ } else {
+ // Prioritize the primary server name.
+ host, p = SplitHostPort(server)
+ if p < 0 {
+ _, p = SplitHostPort(req.Host)
+ }
+ }
+ hostPort := requiredHTTPPort(req.TLS != nil, p)
+ if hostPort > 0 {
+ num++
+ }
+ protoName, protoVersion := netProtocol(req.Proto)
+ if protoName != "" {
+ num++
+ }
+ if protoVersion != "" {
+ num++
+ }
+
+ if statusCode > 0 {
+ num++
+ }
+
+ if route != "" {
+ num++
+ }
+
+ attributes := slices.Grow(additionalAttributes, num)
+ attributes = append(attributes,
+ semconv.HTTPRequestMethodKey.String(standardizeHTTPMethod(req.Method)),
+ n.scheme(req.TLS != nil),
+ semconv.ServerAddress(host))
+
+ if hostPort > 0 {
+ attributes = append(attributes, semconv.ServerPort(hostPort))
+ }
+ if protoName != "" {
+ attributes = append(attributes, semconv.NetworkProtocolName(protoName))
+ }
+ if protoVersion != "" {
+ attributes = append(attributes, semconv.NetworkProtocolVersion(protoVersion))
+ }
+
+ if statusCode > 0 {
+ attributes = append(attributes, semconv.HTTPResponseStatusCode(statusCode))
+ }
+
+ if route != "" {
+ attributes = append(attributes, semconv.HTTPRoute(route))
+ }
+ return attributes
+}
diff --git a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv/util.go b/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv/util.go
index bc1f7751db..131fda489b 100644
--- a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv/util.go
+++ b/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv/util.go
@@ -14,7 +14,7 @@ import (
"go.opentelemetry.io/otel"
"go.opentelemetry.io/otel/attribute"
- semconvNew "go.opentelemetry.io/otel/semconv/v1.26.0"
+ semconvNew "go.opentelemetry.io/otel/semconv/v1.39.0"
)
// SplitHostPort splits a network address hostport of the form "host",
@@ -53,10 +53,10 @@ func SplitHostPort(hostport string) (host string, port int) {
if err != nil {
return
}
- return host, int(p) // nolint: gosec // Byte size checked 16 above.
+ return host, int(p) //nolint:gosec // Byte size checked 16 above.
}
-func requiredHTTPPort(https bool, port int) int { // nolint:revive
+func requiredHTTPPort(https bool, port int) int { //nolint:revive // ignore linter
if https {
if port > 0 && port != 443 {
return port
diff --git a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv/v1.20.0.go b/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv/v1.20.0.go
deleted file mode 100644
index ba7fccf1ef..0000000000
--- a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv/v1.20.0.go
+++ /dev/null
@@ -1,273 +0,0 @@
-// Code generated by gotmpl. DO NOT MODIFY.
-// source: internal/shared/semconv/v120.0.go.tmpl
-
-// Copyright The OpenTelemetry Authors
-// SPDX-License-Identifier: Apache-2.0
-
-package semconv // import "go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv"
-
-import (
- "errors"
- "io"
- "net/http"
- "slices"
-
- "go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconvutil"
- "go.opentelemetry.io/otel/attribute"
- "go.opentelemetry.io/otel/metric"
- "go.opentelemetry.io/otel/metric/noop"
- semconv "go.opentelemetry.io/otel/semconv/v1.20.0"
-)
-
-type OldHTTPServer struct{}
-
-// RequestTraceAttrs returns trace attributes for an HTTP request received by a
-// server.
-//
-// The server must be the primary server name if it is known. For example this
-// would be the ServerName directive
-// (https://httpd.apache.org/docs/2.4/mod/core.html#servername) for an Apache
-// server, and the server_name directive
-// (http://nginx.org/en/docs/http/ngx_http_core_module.html#server_name) for an
-// nginx server. More generically, the primary server name would be the host
-// header value that matches the default virtual host of an HTTP server. It
-// should include the host identifier and if a port is used to route to the
-// server that port identifier should be included as an appropriate port
-// suffix.
-//
-// If the primary server name is not known, server should be an empty string.
-// The req Host will be used to determine the server instead.
-func (o OldHTTPServer) RequestTraceAttrs(server string, req *http.Request, attrs []attribute.KeyValue) []attribute.KeyValue {
- return semconvutil.HTTPServerRequest(server, req, semconvutil.HTTPServerRequestOptions{}, attrs)
-}
-
-func (o OldHTTPServer) NetworkTransportAttr(network string) attribute.KeyValue {
- return semconvutil.NetTransport(network)
-}
-
-// ResponseTraceAttrs returns trace attributes for telemetry from an HTTP response.
-//
-// If any of the fields in the ResponseTelemetry are not set the attribute will be omitted.
-func (o OldHTTPServer) ResponseTraceAttrs(resp ResponseTelemetry, attributes []attribute.KeyValue) []attribute.KeyValue {
- if resp.ReadBytes > 0 {
- attributes = append(attributes, semconv.HTTPRequestContentLength(int(resp.ReadBytes)))
- }
- if resp.ReadError != nil && !errors.Is(resp.ReadError, io.EOF) {
- // This is not in the semantic conventions, but is historically provided
- attributes = append(attributes, attribute.String("http.read_error", resp.ReadError.Error()))
- }
- if resp.WriteBytes > 0 {
- attributes = append(attributes, semconv.HTTPResponseContentLength(int(resp.WriteBytes)))
- }
- if resp.StatusCode > 0 {
- attributes = append(attributes, semconv.HTTPStatusCode(resp.StatusCode))
- }
- if resp.WriteError != nil && !errors.Is(resp.WriteError, io.EOF) {
- // This is not in the semantic conventions, but is historically provided
- attributes = append(attributes, attribute.String("http.write_error", resp.WriteError.Error()))
- }
-
- return attributes
-}
-
-// Route returns the attribute for the route.
-func (o OldHTTPServer) Route(route string) attribute.KeyValue {
- return semconv.HTTPRoute(route)
-}
-
-// HTTPStatusCode returns the attribute for the HTTP status code.
-// This is a temporary function needed by metrics. This will be removed when MetricsRequest is added.
-func HTTPStatusCode(status int) attribute.KeyValue {
- return semconv.HTTPStatusCode(status)
-}
-
-// Server HTTP metrics.
-const (
- serverRequestSize = "http.server.request.size" // Incoming request bytes total
- serverResponseSize = "http.server.response.size" // Incoming response bytes total
- serverDuration = "http.server.duration" // Incoming end to end duration, milliseconds
-)
-
-func (h OldHTTPServer) createMeasures(meter metric.Meter) (metric.Int64Counter, metric.Int64Counter, metric.Float64Histogram) {
- if meter == nil {
- return noop.Int64Counter{}, noop.Int64Counter{}, noop.Float64Histogram{}
- }
- var err error
- requestBytesCounter, err := meter.Int64Counter(
- serverRequestSize,
- metric.WithUnit("By"),
- metric.WithDescription("Measures the size of HTTP request messages."),
- )
- handleErr(err)
-
- responseBytesCounter, err := meter.Int64Counter(
- serverResponseSize,
- metric.WithUnit("By"),
- metric.WithDescription("Measures the size of HTTP response messages."),
- )
- handleErr(err)
-
- serverLatencyMeasure, err := meter.Float64Histogram(
- serverDuration,
- metric.WithUnit("ms"),
- metric.WithDescription("Measures the duration of inbound HTTP requests."),
- )
- handleErr(err)
-
- return requestBytesCounter, responseBytesCounter, serverLatencyMeasure
-}
-
-func (o OldHTTPServer) MetricAttributes(server string, req *http.Request, statusCode int, additionalAttributes []attribute.KeyValue) []attribute.KeyValue {
- n := len(additionalAttributes) + 3
- var host string
- var p int
- if server == "" {
- host, p = SplitHostPort(req.Host)
- } else {
- // Prioritize the primary server name.
- host, p = SplitHostPort(server)
- if p < 0 {
- _, p = SplitHostPort(req.Host)
- }
- }
- hostPort := requiredHTTPPort(req.TLS != nil, p)
- if hostPort > 0 {
- n++
- }
- protoName, protoVersion := netProtocol(req.Proto)
- if protoName != "" {
- n++
- }
- if protoVersion != "" {
- n++
- }
-
- if statusCode > 0 {
- n++
- }
-
- attributes := slices.Grow(additionalAttributes, n)
- attributes = append(attributes,
- semconv.HTTPMethod(standardizeHTTPMethod(req.Method)),
- o.scheme(req.TLS != nil),
- semconv.NetHostName(host))
-
- if hostPort > 0 {
- attributes = append(attributes, semconv.NetHostPort(hostPort))
- }
- if protoName != "" {
- attributes = append(attributes, semconv.NetProtocolName(protoName))
- }
- if protoVersion != "" {
- attributes = append(attributes, semconv.NetProtocolVersion(protoVersion))
- }
-
- if statusCode > 0 {
- attributes = append(attributes, semconv.HTTPStatusCode(statusCode))
- }
- return attributes
-}
-
-func (o OldHTTPServer) scheme(https bool) attribute.KeyValue { // nolint:revive
- if https {
- return semconv.HTTPSchemeHTTPS
- }
- return semconv.HTTPSchemeHTTP
-}
-
-type OldHTTPClient struct{}
-
-func (o OldHTTPClient) RequestTraceAttrs(req *http.Request, attrs []attribute.KeyValue) []attribute.KeyValue {
- return semconvutil.HTTPClientRequest(req, attrs)
-}
-
-func (o OldHTTPClient) ResponseTraceAttrs(resp *http.Response, attrs []attribute.KeyValue) []attribute.KeyValue {
- return semconvutil.HTTPClientResponse(resp, attrs)
-}
-
-func (o OldHTTPClient) MetricAttributes(req *http.Request, statusCode int, additionalAttributes []attribute.KeyValue) []attribute.KeyValue {
- /* The following semantic conventions are returned if present:
- http.method string
- http.status_code int
- net.peer.name string
- net.peer.port int
- */
-
- n := 2 // method, peer name.
- var h string
- if req.URL != nil {
- h = req.URL.Host
- }
- var requestHost string
- var requestPort int
- for _, hostport := range []string{h, req.Header.Get("Host")} {
- requestHost, requestPort = SplitHostPort(hostport)
- if requestHost != "" || requestPort > 0 {
- break
- }
- }
-
- port := requiredHTTPPort(req.URL != nil && req.URL.Scheme == "https", requestPort)
- if port > 0 {
- n++
- }
-
- if statusCode > 0 {
- n++
- }
-
- attributes := slices.Grow(additionalAttributes, n)
- attributes = append(attributes,
- semconv.HTTPMethod(standardizeHTTPMethod(req.Method)),
- semconv.NetPeerName(requestHost),
- )
-
- if port > 0 {
- attributes = append(attributes, semconv.NetPeerPort(port))
- }
-
- if statusCode > 0 {
- attributes = append(attributes, semconv.HTTPStatusCode(statusCode))
- }
- return attributes
-}
-
-// Client HTTP metrics.
-const (
- clientRequestSize = "http.client.request.size" // Incoming request bytes total
- clientResponseSize = "http.client.response.size" // Incoming response bytes total
- clientDuration = "http.client.duration" // Incoming end to end duration, milliseconds
-)
-
-func (o OldHTTPClient) createMeasures(meter metric.Meter) (metric.Int64Counter, metric.Int64Counter, metric.Float64Histogram) {
- if meter == nil {
- return noop.Int64Counter{}, noop.Int64Counter{}, noop.Float64Histogram{}
- }
- requestBytesCounter, err := meter.Int64Counter(
- clientRequestSize,
- metric.WithUnit("By"),
- metric.WithDescription("Measures the size of HTTP request messages."),
- )
- handleErr(err)
-
- responseBytesCounter, err := meter.Int64Counter(
- clientResponseSize,
- metric.WithUnit("By"),
- metric.WithDescription("Measures the size of HTTP response messages."),
- )
- handleErr(err)
-
- latencyMeasure, err := meter.Float64Histogram(
- clientDuration,
- metric.WithUnit("ms"),
- metric.WithDescription("Measures the duration of outbound HTTP requests."),
- )
- handleErr(err)
-
- return requestBytesCounter, responseBytesCounter, latencyMeasure
-}
-
-// TraceAttributes returns attributes for httptrace.
-func (c OldHTTPClient) TraceAttributes(host string, attrs []attribute.KeyValue) []attribute.KeyValue {
- return append(attrs, semconv.NetHostName(host))
-}
diff --git a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconvutil/gen.go b/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconvutil/gen.go
deleted file mode 100644
index 7aa5f99e81..0000000000
--- a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconvutil/gen.go
+++ /dev/null
@@ -1,10 +0,0 @@
-// Copyright The OpenTelemetry Authors
-// SPDX-License-Identifier: Apache-2.0
-
-package semconvutil // import "go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconvutil"
-
-// Generate semconvutil package:
-//go:generate gotmpl --body=../../../../../../internal/shared/semconvutil/httpconv_test.go.tmpl "--data={}" --out=httpconv_test.go
-//go:generate gotmpl --body=../../../../../../internal/shared/semconvutil/httpconv.go.tmpl "--data={}" --out=httpconv.go
-//go:generate gotmpl --body=../../../../../../internal/shared/semconvutil/netconv_test.go.tmpl "--data={}" --out=netconv_test.go
-//go:generate gotmpl --body=../../../../../../internal/shared/semconvutil/netconv.go.tmpl "--data={}" --out=netconv.go
diff --git a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconvutil/httpconv.go b/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconvutil/httpconv.go
deleted file mode 100644
index b997354793..0000000000
--- a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconvutil/httpconv.go
+++ /dev/null
@@ -1,594 +0,0 @@
-// Code generated by gotmpl. DO NOT MODIFY.
-// source: internal/shared/semconvutil/httpconv.go.tmpl
-
-// Copyright The OpenTelemetry Authors
-// SPDX-License-Identifier: Apache-2.0
-
-// Package semconvutil provides OpenTelemetry semantic convention utilities.
-package semconvutil // import "go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconvutil"
-
-import (
- "fmt"
- "net/http"
- "slices"
- "strings"
-
- "go.opentelemetry.io/otel/attribute"
- "go.opentelemetry.io/otel/codes"
- semconv "go.opentelemetry.io/otel/semconv/v1.20.0"
-)
-
-type HTTPServerRequestOptions struct {
- // If set, this is used as value for the "http.client_ip" attribute.
- HTTPClientIP string
-}
-
-// HTTPClientResponse returns trace attributes for an HTTP response received by a
-// client from a server. It will return the following attributes if the related
-// values are defined in resp: "http.status.code",
-// "http.response_content_length".
-//
-// This does not add all OpenTelemetry required attributes for an HTTP event,
-// it assumes ClientRequest was used to create the span with a complete set of
-// attributes. If a complete set of attributes can be generated using the
-// request contained in resp. For example:
-//
-// HTTPClientResponse(resp, ClientRequest(resp.Request)))
-func HTTPClientResponse(resp *http.Response, attrs []attribute.KeyValue) []attribute.KeyValue {
- return hc.ClientResponse(resp, attrs)
-}
-
-// HTTPClientRequest returns trace attributes for an HTTP request made by a client.
-// The following attributes are always returned: "http.url", "http.method",
-// "net.peer.name". The following attributes are returned if the related values
-// are defined in req: "net.peer.port", "user_agent.original",
-// "http.request_content_length".
-func HTTPClientRequest(req *http.Request, attrs []attribute.KeyValue) []attribute.KeyValue {
- return hc.ClientRequest(req, attrs)
-}
-
-// HTTPClientRequestMetrics returns metric attributes for an HTTP request made by a client.
-// The following attributes are always returned: "http.method", "net.peer.name".
-// The following attributes are returned if the
-// related values are defined in req: "net.peer.port".
-func HTTPClientRequestMetrics(req *http.Request) []attribute.KeyValue {
- return hc.ClientRequestMetrics(req)
-}
-
-// HTTPClientStatus returns a span status code and message for an HTTP status code
-// value received by a client.
-func HTTPClientStatus(code int) (codes.Code, string) {
- return hc.ClientStatus(code)
-}
-
-// HTTPServerRequest returns trace attributes for an HTTP request received by a
-// server.
-//
-// The server must be the primary server name if it is known. For example this
-// would be the ServerName directive
-// (https://httpd.apache.org/docs/2.4/mod/core.html#servername) for an Apache
-// server, and the server_name directive
-// (http://nginx.org/en/docs/http/ngx_http_core_module.html#server_name) for an
-// nginx server. More generically, the primary server name would be the host
-// header value that matches the default virtual host of an HTTP server. It
-// should include the host identifier and if a port is used to route to the
-// server that port identifier should be included as an appropriate port
-// suffix.
-//
-// If the primary server name is not known, server should be an empty string.
-// The req Host will be used to determine the server instead.
-//
-// The following attributes are always returned: "http.method", "http.scheme",
-// "http.target", "net.host.name". The following attributes are returned if
-// they related values are defined in req: "net.host.port", "net.sock.peer.addr",
-// "net.sock.peer.port", "user_agent.original", "http.client_ip".
-func HTTPServerRequest(server string, req *http.Request, opts HTTPServerRequestOptions, attrs []attribute.KeyValue) []attribute.KeyValue {
- return hc.ServerRequest(server, req, opts, attrs)
-}
-
-// HTTPServerRequestMetrics returns metric attributes for an HTTP request received by a
-// server.
-//
-// The server must be the primary server name if it is known. For example this
-// would be the ServerName directive
-// (https://httpd.apache.org/docs/2.4/mod/core.html#servername) for an Apache
-// server, and the server_name directive
-// (http://nginx.org/en/docs/http/ngx_http_core_module.html#server_name) for an
-// nginx server. More generically, the primary server name would be the host
-// header value that matches the default virtual host of an HTTP server. It
-// should include the host identifier and if a port is used to route to the
-// server that port identifier should be included as an appropriate port
-// suffix.
-//
-// If the primary server name is not known, server should be an empty string.
-// The req Host will be used to determine the server instead.
-//
-// The following attributes are always returned: "http.method", "http.scheme",
-// "net.host.name". The following attributes are returned if they related
-// values are defined in req: "net.host.port".
-func HTTPServerRequestMetrics(server string, req *http.Request) []attribute.KeyValue {
- return hc.ServerRequestMetrics(server, req)
-}
-
-// HTTPServerStatus returns a span status code and message for an HTTP status code
-// value returned by a server. Status codes in the 400-499 range are not
-// returned as errors.
-func HTTPServerStatus(code int) (codes.Code, string) {
- return hc.ServerStatus(code)
-}
-
-// httpConv are the HTTP semantic convention attributes defined for a version
-// of the OpenTelemetry specification.
-type httpConv struct {
- NetConv *netConv
-
- HTTPClientIPKey attribute.Key
- HTTPMethodKey attribute.Key
- HTTPRequestContentLengthKey attribute.Key
- HTTPResponseContentLengthKey attribute.Key
- HTTPRouteKey attribute.Key
- HTTPSchemeHTTP attribute.KeyValue
- HTTPSchemeHTTPS attribute.KeyValue
- HTTPStatusCodeKey attribute.Key
- HTTPTargetKey attribute.Key
- HTTPURLKey attribute.Key
- UserAgentOriginalKey attribute.Key
-}
-
-var hc = &httpConv{
- NetConv: nc,
-
- HTTPClientIPKey: semconv.HTTPClientIPKey,
- HTTPMethodKey: semconv.HTTPMethodKey,
- HTTPRequestContentLengthKey: semconv.HTTPRequestContentLengthKey,
- HTTPResponseContentLengthKey: semconv.HTTPResponseContentLengthKey,
- HTTPRouteKey: semconv.HTTPRouteKey,
- HTTPSchemeHTTP: semconv.HTTPSchemeHTTP,
- HTTPSchemeHTTPS: semconv.HTTPSchemeHTTPS,
- HTTPStatusCodeKey: semconv.HTTPStatusCodeKey,
- HTTPTargetKey: semconv.HTTPTargetKey,
- HTTPURLKey: semconv.HTTPURLKey,
- UserAgentOriginalKey: semconv.UserAgentOriginalKey,
-}
-
-// ClientResponse returns attributes for an HTTP response received by a client
-// from a server. The following attributes are returned if the related values
-// are defined in resp: "http.status.code", "http.response_content_length".
-//
-// This does not add all OpenTelemetry required attributes for an HTTP event,
-// it assumes ClientRequest was used to create the span with a complete set of
-// attributes. If a complete set of attributes can be generated using the
-// request contained in resp. For example:
-//
-// ClientResponse(resp, ClientRequest(resp.Request))
-func (c *httpConv) ClientResponse(resp *http.Response, attrs []attribute.KeyValue) []attribute.KeyValue {
- /* The following semantic conventions are returned if present:
- http.status_code int
- http.response_content_length int
- */
- var n int
- if resp.StatusCode > 0 {
- n++
- }
- if resp.ContentLength > 0 {
- n++
- }
- if n == 0 {
- return attrs
- }
-
- attrs = slices.Grow(attrs, n)
- if resp.StatusCode > 0 {
- attrs = append(attrs, c.HTTPStatusCodeKey.Int(resp.StatusCode))
- }
- if resp.ContentLength > 0 {
- attrs = append(attrs, c.HTTPResponseContentLengthKey.Int(int(resp.ContentLength)))
- }
- return attrs
-}
-
-// ClientRequest returns attributes for an HTTP request made by a client. The
-// following attributes are always returned: "http.url", "http.method",
-// "net.peer.name". The following attributes are returned if the related values
-// are defined in req: "net.peer.port", "user_agent.original",
-// "http.request_content_length", "user_agent.original".
-func (c *httpConv) ClientRequest(req *http.Request, attrs []attribute.KeyValue) []attribute.KeyValue {
- /* The following semantic conventions are returned if present:
- http.method string
- user_agent.original string
- http.url string
- net.peer.name string
- net.peer.port int
- http.request_content_length int
- */
-
- /* The following semantic conventions are not returned:
- http.status_code This requires the response. See ClientResponse.
- http.response_content_length This requires the response. See ClientResponse.
- net.sock.family This requires the socket used.
- net.sock.peer.addr This requires the socket used.
- net.sock.peer.name This requires the socket used.
- net.sock.peer.port This requires the socket used.
- http.resend_count This is something outside of a single request.
- net.protocol.name The value is the Request is ignored, and the go client will always use "http".
- net.protocol.version The value in the Request is ignored, and the go client will always use 1.1 or 2.0.
- */
- n := 3 // URL, peer name, proto, and method.
- var h string
- if req.URL != nil {
- h = req.URL.Host
- }
- peer, p := firstHostPort(h, req.Header.Get("Host"))
- port := requiredHTTPPort(req.URL != nil && req.URL.Scheme == "https", p)
- if port > 0 {
- n++
- }
- useragent := req.UserAgent()
- if useragent != "" {
- n++
- }
- if req.ContentLength > 0 {
- n++
- }
-
- attrs = slices.Grow(attrs, n)
- attrs = append(attrs, c.method(req.Method))
-
- var u string
- if req.URL != nil {
- // Remove any username/password info that may be in the URL.
- userinfo := req.URL.User
- req.URL.User = nil
- u = req.URL.String()
- // Restore any username/password info that was removed.
- req.URL.User = userinfo
- }
- attrs = append(attrs, c.HTTPURLKey.String(u))
-
- attrs = append(attrs, c.NetConv.PeerName(peer))
- if port > 0 {
- attrs = append(attrs, c.NetConv.PeerPort(port))
- }
-
- if useragent != "" {
- attrs = append(attrs, c.UserAgentOriginalKey.String(useragent))
- }
-
- if l := req.ContentLength; l > 0 {
- attrs = append(attrs, c.HTTPRequestContentLengthKey.Int64(l))
- }
-
- return attrs
-}
-
-// ClientRequestMetrics returns metric attributes for an HTTP request made by a client. The
-// following attributes are always returned: "http.method", "net.peer.name".
-// The following attributes are returned if the related values
-// are defined in req: "net.peer.port".
-func (c *httpConv) ClientRequestMetrics(req *http.Request) []attribute.KeyValue {
- /* The following semantic conventions are returned if present:
- http.method string
- net.peer.name string
- net.peer.port int
- */
-
- n := 2 // method, peer name.
- var h string
- if req.URL != nil {
- h = req.URL.Host
- }
- peer, p := firstHostPort(h, req.Header.Get("Host"))
- port := requiredHTTPPort(req.URL != nil && req.URL.Scheme == "https", p)
- if port > 0 {
- n++
- }
-
- attrs := make([]attribute.KeyValue, 0, n)
- attrs = append(attrs, c.method(req.Method), c.NetConv.PeerName(peer))
-
- if port > 0 {
- attrs = append(attrs, c.NetConv.PeerPort(port))
- }
-
- return attrs
-}
-
-// ServerRequest returns attributes for an HTTP request received by a server.
-//
-// The server must be the primary server name if it is known. For example this
-// would be the ServerName directive
-// (https://httpd.apache.org/docs/2.4/mod/core.html#servername) for an Apache
-// server, and the server_name directive
-// (http://nginx.org/en/docs/http/ngx_http_core_module.html#server_name) for an
-// nginx server. More generically, the primary server name would be the host
-// header value that matches the default virtual host of an HTTP server. It
-// should include the host identifier and if a port is used to route to the
-// server that port identifier should be included as an appropriate port
-// suffix.
-//
-// If the primary server name is not known, server should be an empty string.
-// The req Host will be used to determine the server instead.
-//
-// The following attributes are always returned: "http.method", "http.scheme",
-// "http.target", "net.host.name". The following attributes are returned if they
-// related values are defined in req: "net.host.port", "net.sock.peer.addr",
-// "net.sock.peer.port", "user_agent.original", "http.client_ip",
-// "net.protocol.name", "net.protocol.version".
-func (c *httpConv) ServerRequest(server string, req *http.Request, opts HTTPServerRequestOptions, attrs []attribute.KeyValue) []attribute.KeyValue {
- /* The following semantic conventions are returned if present:
- http.method string
- http.scheme string
- net.host.name string
- net.host.port int
- net.sock.peer.addr string
- net.sock.peer.port int
- user_agent.original string
- http.client_ip string
- net.protocol.name string Note: not set if the value is "http".
- net.protocol.version string
- http.target string Note: doesn't include the query parameter.
- */
-
- /* The following semantic conventions are not returned:
- http.status_code This requires the response.
- http.request_content_length This requires the len() of body, which can mutate it.
- http.response_content_length This requires the response.
- http.route This is not available.
- net.sock.peer.name This would require a DNS lookup.
- net.sock.host.addr The request doesn't have access to the underlying socket.
- net.sock.host.port The request doesn't have access to the underlying socket.
-
- */
- n := 4 // Method, scheme, proto, and host name.
- var host string
- var p int
- if server == "" {
- host, p = splitHostPort(req.Host)
- } else {
- // Prioritize the primary server name.
- host, p = splitHostPort(server)
- if p < 0 {
- _, p = splitHostPort(req.Host)
- }
- }
- hostPort := requiredHTTPPort(req.TLS != nil, p)
- if hostPort > 0 {
- n++
- }
- peer, peerPort := splitHostPort(req.RemoteAddr)
- if peer != "" {
- n++
- if peerPort > 0 {
- n++
- }
- }
- useragent := req.UserAgent()
- if useragent != "" {
- n++
- }
-
- // For client IP, use, in order:
- // 1. The value passed in the options
- // 2. The value in the X-Forwarded-For header
- // 3. The peer address
- clientIP := opts.HTTPClientIP
- if clientIP == "" {
- clientIP = serverClientIP(req.Header.Get("X-Forwarded-For"))
- if clientIP == "" {
- clientIP = peer
- }
- }
- if clientIP != "" {
- n++
- }
-
- var target string
- if req.URL != nil {
- target = req.URL.Path
- if target != "" {
- n++
- }
- }
- protoName, protoVersion := netProtocol(req.Proto)
- if protoName != "" && protoName != "http" {
- n++
- }
- if protoVersion != "" {
- n++
- }
-
- attrs = slices.Grow(attrs, n)
-
- attrs = append(attrs, c.method(req.Method))
- attrs = append(attrs, c.scheme(req.TLS != nil))
- attrs = append(attrs, c.NetConv.HostName(host))
-
- if hostPort > 0 {
- attrs = append(attrs, c.NetConv.HostPort(hostPort))
- }
-
- if peer != "" {
- // The Go HTTP server sets RemoteAddr to "IP:port", this will not be a
- // file-path that would be interpreted with a sock family.
- attrs = append(attrs, c.NetConv.SockPeerAddr(peer))
- if peerPort > 0 {
- attrs = append(attrs, c.NetConv.SockPeerPort(peerPort))
- }
- }
-
- if useragent != "" {
- attrs = append(attrs, c.UserAgentOriginalKey.String(useragent))
- }
-
- if clientIP != "" {
- attrs = append(attrs, c.HTTPClientIPKey.String(clientIP))
- }
-
- if target != "" {
- attrs = append(attrs, c.HTTPTargetKey.String(target))
- }
-
- if protoName != "" && protoName != "http" {
- attrs = append(attrs, c.NetConv.NetProtocolName.String(protoName))
- }
- if protoVersion != "" {
- attrs = append(attrs, c.NetConv.NetProtocolVersion.String(protoVersion))
- }
-
- return attrs
-}
-
-// ServerRequestMetrics returns metric attributes for an HTTP request received
-// by a server.
-//
-// The server must be the primary server name if it is known. For example this
-// would be the ServerName directive
-// (https://httpd.apache.org/docs/2.4/mod/core.html#servername) for an Apache
-// server, and the server_name directive
-// (http://nginx.org/en/docs/http/ngx_http_core_module.html#server_name) for an
-// nginx server. More generically, the primary server name would be the host
-// header value that matches the default virtual host of an HTTP server. It
-// should include the host identifier and if a port is used to route to the
-// server that port identifier should be included as an appropriate port
-// suffix.
-//
-// If the primary server name is not known, server should be an empty string.
-// The req Host will be used to determine the server instead.
-//
-// The following attributes are always returned: "http.method", "http.scheme",
-// "net.host.name". The following attributes are returned if they related
-// values are defined in req: "net.host.port".
-func (c *httpConv) ServerRequestMetrics(server string, req *http.Request) []attribute.KeyValue {
- /* The following semantic conventions are returned if present:
- http.scheme string
- http.route string
- http.method string
- http.status_code int
- net.host.name string
- net.host.port int
- net.protocol.name string Note: not set if the value is "http".
- net.protocol.version string
- */
-
- n := 3 // Method, scheme, and host name.
- var host string
- var p int
- if server == "" {
- host, p = splitHostPort(req.Host)
- } else {
- // Prioritize the primary server name.
- host, p = splitHostPort(server)
- if p < 0 {
- _, p = splitHostPort(req.Host)
- }
- }
- hostPort := requiredHTTPPort(req.TLS != nil, p)
- if hostPort > 0 {
- n++
- }
- protoName, protoVersion := netProtocol(req.Proto)
- if protoName != "" {
- n++
- }
- if protoVersion != "" {
- n++
- }
-
- attrs := make([]attribute.KeyValue, 0, n)
-
- attrs = append(attrs, c.methodMetric(req.Method))
- attrs = append(attrs, c.scheme(req.TLS != nil))
- attrs = append(attrs, c.NetConv.HostName(host))
-
- if hostPort > 0 {
- attrs = append(attrs, c.NetConv.HostPort(hostPort))
- }
- if protoName != "" {
- attrs = append(attrs, c.NetConv.NetProtocolName.String(protoName))
- }
- if protoVersion != "" {
- attrs = append(attrs, c.NetConv.NetProtocolVersion.String(protoVersion))
- }
-
- return attrs
-}
-
-func (c *httpConv) method(method string) attribute.KeyValue {
- if method == "" {
- return c.HTTPMethodKey.String(http.MethodGet)
- }
- return c.HTTPMethodKey.String(method)
-}
-
-func (c *httpConv) methodMetric(method string) attribute.KeyValue {
- method = strings.ToUpper(method)
- switch method {
- case http.MethodConnect, http.MethodDelete, http.MethodGet, http.MethodHead, http.MethodOptions, http.MethodPatch, http.MethodPost, http.MethodPut, http.MethodTrace:
- default:
- method = "_OTHER"
- }
- return c.HTTPMethodKey.String(method)
-}
-
-func (c *httpConv) scheme(https bool) attribute.KeyValue { // nolint:revive
- if https {
- return c.HTTPSchemeHTTPS
- }
- return c.HTTPSchemeHTTP
-}
-
-func serverClientIP(xForwardedFor string) string {
- if idx := strings.Index(xForwardedFor, ","); idx >= 0 {
- xForwardedFor = xForwardedFor[:idx]
- }
- return xForwardedFor
-}
-
-func requiredHTTPPort(https bool, port int) int { // nolint:revive
- if https {
- if port > 0 && port != 443 {
- return port
- }
- } else {
- if port > 0 && port != 80 {
- return port
- }
- }
- return -1
-}
-
-// Return the request host and port from the first non-empty source.
-func firstHostPort(source ...string) (host string, port int) {
- for _, hostport := range source {
- host, port = splitHostPort(hostport)
- if host != "" || port > 0 {
- break
- }
- }
- return
-}
-
-// ClientStatus returns a span status code and message for an HTTP status code
-// value received by a client.
-func (c *httpConv) ClientStatus(code int) (codes.Code, string) {
- if code < 100 || code >= 600 {
- return codes.Error, fmt.Sprintf("Invalid HTTP status code %d", code)
- }
- if code >= 400 {
- return codes.Error, ""
- }
- return codes.Unset, ""
-}
-
-// ServerStatus returns a span status code and message for an HTTP status code
-// value returned by a server. Status codes in the 400-499 range are not
-// returned as errors.
-func (c *httpConv) ServerStatus(code int) (codes.Code, string) {
- if code < 100 || code >= 600 {
- return codes.Error, fmt.Sprintf("Invalid HTTP status code %d", code)
- }
- if code >= 500 {
- return codes.Error, ""
- }
- return codes.Unset, ""
-}
diff --git a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconvutil/netconv.go b/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconvutil/netconv.go
deleted file mode 100644
index df97255e41..0000000000
--- a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconvutil/netconv.go
+++ /dev/null
@@ -1,214 +0,0 @@
-// Code generated by gotmpl. DO NOT MODIFY.
-// source: internal/shared/semconvutil/netconv.go.tmpl
-
-// Copyright The OpenTelemetry Authors
-// SPDX-License-Identifier: Apache-2.0
-
-package semconvutil // import "go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconvutil"
-
-import (
- "net"
- "strconv"
- "strings"
-
- "go.opentelemetry.io/otel/attribute"
- semconv "go.opentelemetry.io/otel/semconv/v1.20.0"
-)
-
-// NetTransport returns a trace attribute describing the transport protocol of the
-// passed network. See the net.Dial for information about acceptable network
-// values.
-func NetTransport(network string) attribute.KeyValue {
- return nc.Transport(network)
-}
-
-// netConv are the network semantic convention attributes defined for a version
-// of the OpenTelemetry specification.
-type netConv struct {
- NetHostNameKey attribute.Key
- NetHostPortKey attribute.Key
- NetPeerNameKey attribute.Key
- NetPeerPortKey attribute.Key
- NetProtocolName attribute.Key
- NetProtocolVersion attribute.Key
- NetSockFamilyKey attribute.Key
- NetSockPeerAddrKey attribute.Key
- NetSockPeerPortKey attribute.Key
- NetSockHostAddrKey attribute.Key
- NetSockHostPortKey attribute.Key
- NetTransportOther attribute.KeyValue
- NetTransportTCP attribute.KeyValue
- NetTransportUDP attribute.KeyValue
- NetTransportInProc attribute.KeyValue
-}
-
-var nc = &netConv{
- NetHostNameKey: semconv.NetHostNameKey,
- NetHostPortKey: semconv.NetHostPortKey,
- NetPeerNameKey: semconv.NetPeerNameKey,
- NetPeerPortKey: semconv.NetPeerPortKey,
- NetProtocolName: semconv.NetProtocolNameKey,
- NetProtocolVersion: semconv.NetProtocolVersionKey,
- NetSockFamilyKey: semconv.NetSockFamilyKey,
- NetSockPeerAddrKey: semconv.NetSockPeerAddrKey,
- NetSockPeerPortKey: semconv.NetSockPeerPortKey,
- NetSockHostAddrKey: semconv.NetSockHostAddrKey,
- NetSockHostPortKey: semconv.NetSockHostPortKey,
- NetTransportOther: semconv.NetTransportOther,
- NetTransportTCP: semconv.NetTransportTCP,
- NetTransportUDP: semconv.NetTransportUDP,
- NetTransportInProc: semconv.NetTransportInProc,
-}
-
-func (c *netConv) Transport(network string) attribute.KeyValue {
- switch network {
- case "tcp", "tcp4", "tcp6":
- return c.NetTransportTCP
- case "udp", "udp4", "udp6":
- return c.NetTransportUDP
- case "unix", "unixgram", "unixpacket":
- return c.NetTransportInProc
- default:
- // "ip:*", "ip4:*", and "ip6:*" all are considered other.
- return c.NetTransportOther
- }
-}
-
-// Host returns attributes for a network host address.
-func (c *netConv) Host(address string) []attribute.KeyValue {
- h, p := splitHostPort(address)
- var n int
- if h != "" {
- n++
- if p > 0 {
- n++
- }
- }
-
- if n == 0 {
- return nil
- }
-
- attrs := make([]attribute.KeyValue, 0, n)
- attrs = append(attrs, c.HostName(h))
- if p > 0 {
- attrs = append(attrs, c.HostPort(p))
- }
- return attrs
-}
-
-func (c *netConv) HostName(name string) attribute.KeyValue {
- return c.NetHostNameKey.String(name)
-}
-
-func (c *netConv) HostPort(port int) attribute.KeyValue {
- return c.NetHostPortKey.Int(port)
-}
-
-func family(network, address string) string {
- switch network {
- case "unix", "unixgram", "unixpacket":
- return "unix"
- default:
- if ip := net.ParseIP(address); ip != nil {
- if ip.To4() == nil {
- return "inet6"
- }
- return "inet"
- }
- }
- return ""
-}
-
-// Peer returns attributes for a network peer address.
-func (c *netConv) Peer(address string) []attribute.KeyValue {
- h, p := splitHostPort(address)
- var n int
- if h != "" {
- n++
- if p > 0 {
- n++
- }
- }
-
- if n == 0 {
- return nil
- }
-
- attrs := make([]attribute.KeyValue, 0, n)
- attrs = append(attrs, c.PeerName(h))
- if p > 0 {
- attrs = append(attrs, c.PeerPort(p))
- }
- return attrs
-}
-
-func (c *netConv) PeerName(name string) attribute.KeyValue {
- return c.NetPeerNameKey.String(name)
-}
-
-func (c *netConv) PeerPort(port int) attribute.KeyValue {
- return c.NetPeerPortKey.Int(port)
-}
-
-func (c *netConv) SockPeerAddr(addr string) attribute.KeyValue {
- return c.NetSockPeerAddrKey.String(addr)
-}
-
-func (c *netConv) SockPeerPort(port int) attribute.KeyValue {
- return c.NetSockPeerPortKey.Int(port)
-}
-
-// splitHostPort splits a network address hostport of the form "host",
-// "host%zone", "[host]", "[host%zone], "host:port", "host%zone:port",
-// "[host]:port", "[host%zone]:port", or ":port" into host or host%zone and
-// port.
-//
-// An empty host is returned if it is not provided or unparsable. A negative
-// port is returned if it is not provided or unparsable.
-func splitHostPort(hostport string) (host string, port int) {
- port = -1
-
- if strings.HasPrefix(hostport, "[") {
- addrEnd := strings.LastIndex(hostport, "]")
- if addrEnd < 0 {
- // Invalid hostport.
- return
- }
- if i := strings.LastIndex(hostport[addrEnd:], ":"); i < 0 {
- host = hostport[1:addrEnd]
- return
- }
- } else {
- if i := strings.LastIndex(hostport, ":"); i < 0 {
- host = hostport
- return
- }
- }
-
- host, pStr, err := net.SplitHostPort(hostport)
- if err != nil {
- return
- }
-
- p, err := strconv.ParseUint(pStr, 10, 16)
- if err != nil {
- return
- }
- return host, int(p) // nolint: gosec // Bitsize checked to be 16 above.
-}
-
-func netProtocol(proto string) (name string, version string) {
- name, version, _ = strings.Cut(proto, "/")
- switch name {
- case "HTTP":
- name = "http"
- case "QUIC":
- name = "quic"
- case "SPDY":
- name = "spdy"
- default:
- name = strings.ToLower(name)
- }
- return name, version
-}
diff --git a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/transport.go b/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/transport.go
index 44b86ad860..59b6c5498d 100644
--- a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/transport.go
+++ b/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/transport.go
@@ -5,20 +5,22 @@ package otelhttp // import "go.opentelemetry.io/contrib/instrumentation/net/http
import (
"context"
+ "fmt"
"io"
"net/http"
"net/http/httptrace"
"sync/atomic"
"time"
- "go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/request"
- "go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv"
"go.opentelemetry.io/otel"
"go.opentelemetry.io/otel/attribute"
"go.opentelemetry.io/otel/codes"
"go.opentelemetry.io/otel/propagation"
-
+ otelsemconv "go.opentelemetry.io/otel/semconv/v1.39.0"
"go.opentelemetry.io/otel/trace"
+
+ "go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/request"
+ "go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/internal/semconv"
)
// Transport implements the http.RoundTripper interface and wraps
@@ -83,6 +85,8 @@ func defaultTransportFormatter(_ string, r *http.Request) string {
// RoundTrip creates a Span and propagates its context via the provided request's headers
// before handing the request to the configured base RoundTripper. The created span will
// end when the response body is closed or when a read from the body returns io.EOF.
+// If GetBody returns an error, the error is reported via otel.Handle and the request
+// continues with the original Body.
func (t *Transport) RoundTrip(r *http.Request) (*http.Response, error) {
requestStartTime := time.Now()
for _, f := range t.filters {
@@ -117,11 +121,22 @@ func (t *Transport) RoundTrip(r *http.Request) (*http.Response, error) {
r = r.Clone(ctx) // According to RoundTripper spec, we shouldn't modify the origin request.
- // if request body is nil or NoBody, we don't want to mutate the body as it
+ // GetBody is preferred over direct access to Body if the function is set.
+ // If the resulting body is nil or is NoBody, we don't want to mutate the body as it
// will affect the identity of it in an unforeseeable way because we assert
// ReadCloser fulfills a certain interface and it is indeed nil or NoBody.
- bw := request.NewBodyWrapper(r.Body, func(int64) {})
- if r.Body != nil && r.Body != http.NoBody {
+ body := r.Body
+ if r.GetBody != nil {
+ b, err := r.GetBody()
+ if err != nil {
+ otel.Handle(fmt.Errorf("http.Request GetBody returned an error: %w", err))
+ } else {
+ body = b
+ }
+ }
+
+ bw := request.NewBodyWrapper(body, func(int64) {})
+ if body != nil && body != http.NoBody {
r.Body = bw
}
@@ -129,47 +144,49 @@ func (t *Transport) RoundTrip(r *http.Request) (*http.Response, error) {
t.propagators.Inject(ctx, propagation.HeaderCarrier(r.Header))
res, err := t.rt.RoundTrip(r)
- if err != nil {
- // set error type attribute if the error is part of the predefined
- // error types.
- // otherwise, record it as an exception
- if errType := t.semconv.ErrorType(err); errType.Valid() {
- span.SetAttributes(errType)
- } else {
- span.RecordError(err)
+
+ // Defer metrics recording function to record the metrics on error or no error.
+ defer func() {
+ metricAttributes := semconv.MetricAttributes{
+ Req: r,
+ AdditionalAttributes: append(labeler.Get(), t.metricAttributesFromRequest(r)...),
+ }
+
+ if err == nil {
+ metricAttributes.StatusCode = res.StatusCode
}
+ metricOpts := t.semconv.MetricOptions(metricAttributes)
+
+ metricData := semconv.MetricData{
+ RequestSize: bw.BytesRead(),
+ }
+
+ if err == nil {
+ readRecordFunc := func(int64) {}
+ res.Body = newWrappedBody(span, readRecordFunc, res.Body)
+ }
+
+ // Use floating point division here for higher precision (instead of Millisecond method).
+ elapsedTime := float64(time.Since(requestStartTime)) / float64(time.Millisecond)
+
+ metricData.ElapsedTime = elapsedTime
+
+ t.semconv.RecordMetrics(ctx, metricData, metricOpts)
+ }()
+
+ if err != nil {
+ span.SetAttributes(otelsemconv.ErrorType(err))
span.SetStatus(codes.Error, err.Error())
span.End()
- return res, err
- }
- // metrics
- metricOpts := t.semconv.MetricOptions(semconv.MetricAttributes{
- Req: r,
- StatusCode: res.StatusCode,
- AdditionalAttributes: append(labeler.Get(), t.metricAttributesFromRequest(r)...),
- })
-
- // For handling response bytes we leverage a callback when the client reads the http response
- readRecordFunc := func(n int64) {
- t.semconv.RecordResponseSize(ctx, n, metricOpts)
+ return res, err
}
// traces
span.SetAttributes(t.semconv.ResponseTraceAttrs(res)...)
span.SetStatus(t.semconv.Status(res.StatusCode))
- res.Body = newWrappedBody(span, readRecordFunc, res.Body)
-
- // Use floating point division here for higher precision (instead of Millisecond method).
- elapsedTime := float64(time.Since(requestStartTime)) / float64(time.Millisecond)
-
- t.semconv.RecordMetrics(ctx, semconv.MetricData{
- RequestSize: bw.BytesRead(),
- ElapsedTime: elapsedTime,
- }, metricOpts)
-
return res, nil
}
@@ -219,7 +236,7 @@ func (wb *wrappedBody) Write(p []byte) (int, error) {
// This will not panic given the guard in newWrappedBody.
n, err := wb.body.(io.Writer).Write(p)
if err != nil {
- wb.span.RecordError(err)
+ wb.span.SetAttributes(otelsemconv.ErrorType(err))
wb.span.SetStatus(codes.Error, err.Error())
}
return n, err
@@ -237,7 +254,7 @@ func (wb *wrappedBody) Read(b []byte) (int, error) {
wb.recordBytesRead()
wb.span.End()
default:
- wb.span.RecordError(err)
+ wb.span.SetAttributes(otelsemconv.ErrorType(err))
wb.span.SetStatus(codes.Error, err.Error())
}
return n, err
diff --git a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/version.go b/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/version.go
index 6be4c1fde2..d0107952e1 100644
--- a/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/version.go
+++ b/vendor/go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp/version.go
@@ -4,7 +4,4 @@
package otelhttp // import "go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp"
// Version is the current release version of the otelhttp instrumentation.
-func Version() string {
- return "0.61.0"
- // This string is updated by the pre_release.sh script during release
-}
+const Version = "0.65.0"
diff --git a/vendor/go.opentelemetry.io/otel/.clomonitor.yml b/vendor/go.opentelemetry.io/otel/.clomonitor.yml
new file mode 100644
index 0000000000..128d61a226
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/.clomonitor.yml
@@ -0,0 +1,3 @@
+exemptions:
+ - check: artifacthub_badge
+ reason: "Artifact Hub doesn't support Go packages"
diff --git a/vendor/go.opentelemetry.io/otel/.codespellignore b/vendor/go.opentelemetry.io/otel/.codespellignore
index 6bf3abc41e..a6d0cbcc9e 100644
--- a/vendor/go.opentelemetry.io/otel/.codespellignore
+++ b/vendor/go.opentelemetry.io/otel/.codespellignore
@@ -7,3 +7,5 @@ ans
nam
valu
thirdparty
+addOpt
+observ
diff --git a/vendor/go.opentelemetry.io/otel/.golangci.yml b/vendor/go.opentelemetry.io/otel/.golangci.yml
index 888e5da802..d12c8920af 100644
--- a/vendor/go.opentelemetry.io/otel/.golangci.yml
+++ b/vendor/go.opentelemetry.io/otel/.golangci.yml
@@ -10,11 +10,13 @@ linters:
- depguard
- errcheck
- errorlint
+ - gocritic
- godot
- gosec
- govet
- ineffassign
- misspell
+ - modernize
- perfsprint
- revive
- staticcheck
@@ -66,8 +68,6 @@ linters:
desc: Do not use cross-module internal packages.
- pkg: go.opentelemetry.io/otel/internal/internaltest
desc: Do not use cross-module internal packages.
- - pkg: go.opentelemetry.io/otel/internal/matchers
- desc: Do not use cross-module internal packages.
otlp-internal:
files:
- '!**/exporters/otlp/internal/**/*.go'
@@ -88,6 +88,18 @@ linters:
deny:
- pkg: go.opentelemetry.io/otel/exporters/otlp/otlptrace/internal
desc: Do not use cross-module internal packages.
+ gocritic:
+ disabled-checks:
+ - appendAssign
+ - commentedOutCode
+ - dupArg
+ - hugeParam
+ - importShadow
+ - preferDecodeRune
+ - rangeValCopy
+ - unnamedResult
+ - whyNoLint
+ enable-all: true
godot:
exclude:
# Exclude links.
@@ -100,6 +112,9 @@ linters:
locale: US
ignore-rules:
- cancelled
+ modernize:
+ disable:
+ - omitzero
perfsprint:
int-conversion: true
err-error: true
@@ -169,13 +184,17 @@ linters:
- fmt.Print
- fmt.Printf
- fmt.Println
+ - name: unused-parameter
+ - name: unused-receiver
- name: unnecessary-stmt
+ - name: use-any
- name: useless-break
- name: var-declaration
- name: var-naming
arguments:
- ["ID"] # AllowList
- ["Otel", "Aws", "Gcp"] # DenyList
+ - - skip-package-name-collision-with-go-std: true
- name: waitgroup-by-value
testifylint:
enable-all: true
@@ -183,6 +202,9 @@ linters:
- float-compare
- go-require
- require-error
+ usetesting:
+ context-background: true
+ context-todo: true
exclusions:
generated: lax
presets:
@@ -190,6 +212,10 @@ linters:
- legacy
- std-error-handling
rules:
+ - linters:
+ - revive
+ path: schema/v.*/types/.*
+ text: avoid meaningless package names
# TODO: Having appropriate comments for exported objects helps development,
# even for objects in internal packages. Appropriate comments for all
# exported objects should be added and this exclusion removed.
@@ -222,10 +248,6 @@ linters:
- linters:
- gosec
text: 'G402: TLS MinVersion too low.'
- paths:
- - third_party$
- - builtin$
- - examples$
issues:
max-issues-per-linter: 0
max-same-issues: 0
@@ -235,14 +257,12 @@ formatters:
- goimports
- golines
settings:
+ gofumpt:
+ extra-rules: true
goimports:
local-prefixes:
- - go.opentelemetry.io
+ - go.opentelemetry.io/otel
golines:
max-len: 120
exclusions:
generated: lax
- paths:
- - third_party$
- - builtin$
- - examples$
diff --git a/vendor/go.opentelemetry.io/otel/.lycheeignore b/vendor/go.opentelemetry.io/otel/.lycheeignore
index 40d62fa2eb..994b677df7 100644
--- a/vendor/go.opentelemetry.io/otel/.lycheeignore
+++ b/vendor/go.opentelemetry.io/otel/.lycheeignore
@@ -1,6 +1,13 @@
http://localhost
+https://localhost
http://jaeger-collector
https://github.com/open-telemetry/opentelemetry-go/milestone/
https://github.com/open-telemetry/opentelemetry-go/projects
+# Weaver model URL for semantic-conventions repository.
+https?:\/\/github\.com\/open-telemetry\/semantic-conventions\/archive\/refs\/tags\/[^.]+\.zip\[[^]]+]
file:///home/runner/work/opentelemetry-go/opentelemetry-go/libraries
file:///home/runner/work/opentelemetry-go/opentelemetry-go/manual
+http://4.3.2.1:78/user/123
+file:///home/runner/work/opentelemetry-go/opentelemetry-go/exporters/otlp/otlptrace/otlptracegrpc/internal/observ/dns:/:4317
+# URL works, but it has blocked link checkers.
+https://dl.acm.org/doi/10.1145/198429.198435
diff --git a/vendor/go.opentelemetry.io/otel/CHANGELOG.md b/vendor/go.opentelemetry.io/otel/CHANGELOG.md
index 648e4abab8..f0595b5e5e 100644
--- a/vendor/go.opentelemetry.io/otel/CHANGELOG.md
+++ b/vendor/go.opentelemetry.io/otel/CHANGELOG.md
@@ -8,9 +8,274 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm
## [Unreleased]
+## [1.41.0/0.63.0/0.17.0/0.0.15] 2026-03-02
+
+This release is the last to support [Go 1.24].
+The next release will require at least [Go 1.25].
+
+### Added
+
+- Support testing of [Go 1.26]. (#7902)
+
+### Fixed
+
+- Update `Baggage` in `go.opentelemetry.io/otel/propagation` and `Parse` and `New` in `go.opentelemetry.io/otel/baggage` to comply with W3C Baggage specification limits.
+ `New` and `Parse` now return partial baggage along with an error when limits are exceeded.
+ Errors from baggage extraction are reported to the global error handler. (#7880)
+- Return an error when the endpoint is configured as insecure and with TLS configuration in `go.opentelemetry.io/otel/exporters/otlp/otlplog/otlploghttp`. (#7914)
+- Return an error when the endpoint is configured as insecure and with TLS configuration in `go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp`. (#7914)
+- Return an error when the endpoint is configured as insecure and with TLS configuration in `go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp`. (#7914)
+
+## [1.40.0/0.62.0/0.16.0] 2026-02-02
+
+### Added
+
+- Add `AlwaysRecord` sampler in `go.opentelemetry.io/otel/sdk/trace`. (#7724)
+- Add `Enabled` method to all synchronous instrument interfaces (`Float64Counter`, `Float64UpDownCounter`, `Float64Histogram`, `Float64Gauge`, `Int64Counter`, `Int64UpDownCounter`, `Int64Histogram`, `Int64Gauge`,) in `go.opentelemetry.io/otel/metric`.
+ This stabilizes the synchronous instrument enabled feature, allowing users to check if an instrument will process measurements before performing computationally expensive operations. (#7763)
+- Add `go.opentelemetry.io/otel/semconv/v1.39.0` package.
+ The package contains semantic conventions from the `v1.39.0` version of the OpenTelemetry Semantic Conventions.
+ See the [migration documentation](./semconv/v1.39.0/MIGRATION.md) for information on how to upgrade from `go.opentelemetry.io/otel/semconv/v1.38.0.` (#7783, #7789)
+
+### Changed
+
+- Improve the concurrent performance of `HistogramReservoir` in `go.opentelemetry.io/otel/sdk/metric/exemplar` by 4x. (#7443)
+- Improve the concurrent performance of `FixedSizeReservoir` in `go.opentelemetry.io/otel/sdk/metric/exemplar`. (#7447)
+- Improve performance of concurrent histogram measurements in `go.opentelemetry.io/otel/sdk/metric`. (#7474)
+- Improve performance of concurrent synchronous gauge measurements in `go.opentelemetry.io/otel/sdk/metric`. (#7478)
+- Add experimental observability metrics in `go.opentelemetry.io/otel/exporters/stdout/stdoutmetric`. (#7492)
+- `Exporter` in `go.opentelemetry.io/otel/exporters/prometheus` ignores metrics with the scope `go.opentelemetry.io/contrib/bridges/prometheus`.
+ This prevents scrape failures when the Prometheus exporter is misconfigured to get data from the Prometheus bridge. (#7688)
+- Improve performance of concurrent exponential histogram measurements in `go.opentelemetry.io/otel/sdk/metric`. (#7702)
+- The `rpc.grpc.status_code` attribute in the experimental metrics emitted from `go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc` is replaced with the `rpc.response.status_code` attribute to align with the semantic conventions. (#7854)
+- The `rpc.grpc.status_code` attribute in the experimental metrics emitted from `go.opentelemetry.io/otel/exporters/otlp/otlplog/otlploggrpc` is replaced with the `rpc.response.status_code` attribute to align with the semantic conventions. (#7854)
+
+### Fixed
+
+- Fix bad log message when key-value pairs are dropped because of key duplication in `go.opentelemetry.io/otel/sdk/log`. (#7662)
+- Fix `DroppedAttributes` on `Record` in `go.opentelemetry.io/otel/sdk/log` to not count the non-attribute key-value pairs dropped because of key duplication. (#7662)
+- Fix `SetAttributes` on `Record` in `go.opentelemetry.io/otel/sdk/log` to not log that attributes are dropped when they are actually not dropped. (#7662)
+- Fix missing `request.GetBody` in `go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp` to correctly handle HTTP/2 `GOAWAY` frame. (#7794)
+- `WithHostID` detector in `go.opentelemetry.io/otel/sdk/resource` to use full path for `ioreg` command on Darwin (macOS). (#7818)
+
+### Deprecated
+
+- Deprecate `go.opentelemetry.io/otel/exporters/zipkin`.
+ For more information, see the [OTel blog post deprecating the Zipkin exporter](https://opentelemetry.io/blog/2025/deprecating-zipkin-exporters/). (#7670)
+
+## [1.39.0/0.61.0/0.15.0/0.0.14] 2025-12-05
+
+### Added
+
+- Greatly reduce the cost of recording metrics in `go.opentelemetry.io/otel/sdk/metric` using hashing for map keys. (#7175)
+- Add `WithInstrumentationAttributeSet` option to `go.opentelemetry.io/otel/log`, `go.opentelemetry.io/otel/metric`, and `go.opentelemetry.io/otel/trace` packages.
+ This provides a concurrent-safe and performant alternative to `WithInstrumentationAttributes` by accepting a pre-constructed `attribute.Set`. (#7287)
+- Add experimental observability for the Prometheus exporter in `go.opentelemetry.io/otel/exporters/prometheus`.
+ Check the `go.opentelemetry.io/otel/exporters/prometheus/internal/x` package documentation for more information. (#7345)
+- Add experimental observability metrics in `go.opentelemetry.io/otel/exporters/otlp/otlplog/otlploggrpc`. (#7353)
+- Add temporality selector functions `DeltaTemporalitySelector`, `CumulativeTemporalitySelector`, `LowMemoryTemporalitySelector` to `go.opentelemetry.io/otel/sdk/metric`. (#7434)
+- Add experimental observability metrics for simple log processor in `go.opentelemetry.io/otel/sdk/log`. (#7548)
+- Add experimental observability metrics in `go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc`. (#7459)
+- Add experimental observability metrics in `go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp`. (#7486)
+- Add experimental observability metrics for simple span processor in `go.opentelemetry.io/otel/sdk/trace`. (#7374)
+- Add experimental observability metrics in `go.opentelemetry.io/otel/exporters/otlp/otlplog/otlploghttp`. (#7512)
+- Add experimental observability metrics for manual reader in `go.opentelemetry.io/otel/sdk/metric`. (#7524)
+- Add experimental observability metrics for periodic reader in `go.opentelemetry.io/otel/sdk/metric`. (#7571)
+- Support `OTEL_EXPORTER_OTLP_LOGS_INSECURE` and `OTEL_EXPORTER_OTLP_INSECURE` environmental variables in `go.opentelemetry.io/otel/exporters/otlp/otlplog/otlploghttp`. (#7608)
+- Add `Enabled` method to the `Processor` interface in `go.opentelemetry.io/otel/sdk/log`.
+ All `Processor` implementations now include an `Enabled` method. (#7639)
+- The `go.opentelemetry.io/otel/semconv/v1.38.0` package.
+ The package contains semantic conventions from the `v1.38.0` version of the OpenTelemetry Semantic Conventions.
+ See the [migration documentation](./semconv/v1.38.0/MIGRATION.md) for information on how to upgrade from `go.opentelemetry.io/otel/semconv/v1.37.0.`(#7648)
+
+### Changed
+
+- `Distinct` in `go.opentelemetry.io/otel/attribute` is no longer guaranteed to uniquely identify an attribute set.
+ Collisions between `Distinct` values for different Sets are possible with extremely high cardinality (billions of series per instrument), but are highly unlikely. (#7175)
+- `WithInstrumentationAttributes` in `go.opentelemetry.io/otel/trace` synchronously de-duplicates the passed attributes instead of delegating it to the returned `TracerOption`. (#7266)
+- `WithInstrumentationAttributes` in `go.opentelemetry.io/otel/meter` synchronously de-duplicates the passed attributes instead of delegating it to the returned `MeterOption`. (#7266)
+- `WithInstrumentationAttributes` in `go.opentelemetry.io/otel/log` synchronously de-duplicates the passed attributes instead of delegating it to the returned `LoggerOption`. (#7266)
+- Rename the `OTEL_GO_X_SELF_OBSERVABILITY` environment variable to `OTEL_GO_X_OBSERVABILITY` in `go.opentelemetry.io/otel/sdk/trace`, `go.opentelemetry.io/otel/sdk/log`, and `go.opentelemetry.io/otel/exporters/stdout/stdouttrace`. (#7302)
+- Improve performance of histogram `Record` in `go.opentelemetry.io/otel/sdk/metric` when min and max are disabled using `NoMinMax`. (#7306)
+- Improve error handling for dropped data during translation by using `prometheus.NewInvalidMetric` in `go.opentelemetry.io/otel/exporters/prometheus`.
+ ⚠️ **Breaking Change:** Previously, these cases were only logged and scrapes succeeded.
+ Now, when translation would drop data (e.g., invalid label/value), the exporter emits a `NewInvalidMetric`, and Prometheus scrapes **fail with HTTP 500** by default.
+ To preserve the prior behavior (scrapes succeed while errors are logged), configure your Prometheus HTTP handler with: `promhttp.HandlerOpts{ ErrorHandling: promhttp.ContinueOnError }`. (#7363)
+- Replace fnv hash with xxhash in `go.opentelemetry.io/otel/attribute` for better performance. (#7371)
+- The default `TranslationStrategy` in `go.opentelemetry.io/exporters/prometheus` is changed from `otlptranslator.NoUTF8EscapingWithSuffixes` to `otlptranslator.UnderscoreEscapingWithSuffixes`. (#7421)
+- Improve performance of concurrent measurements in `go.opentelemetry.io/otel/sdk/metric`. (#7427)
+- Include W3C TraceFlags (bits 0–7) in the OTLP `Span.Flags` field in `go.opentelemetry.io/exporters/otlp/otlptrace/otlptracehttp` and `go.opentelemetry.io/exporters/otlp/otlptrace/otlptracegrpc`. (#7438)
+- The `ErrorType` function in `go.opentelemetry.io/otel/semconv/v1.37.0` now handles custom error types.
+ If an error implements an `ErrorType() string` method, the return value of that method will be used as the error type. (#7442)
+
+### Fixed
+
+- Fix `WithInstrumentationAttributes` options in `go.opentelemetry.io/otel/trace`, `go.opentelemetry.io/otel/metric`, and `go.opentelemetry.io/otel/log` to properly merge attributes when passed multiple times instead of replacing them.
+ Attributes with duplicate keys will use the last value passed. (#7300)
+- The equality of `attribute.Set` when using the `Equal` method is not affected by the user overriding the empty set pointed to by `attribute.EmptySet` in `go.opentelemetry.io/otel/attribute`. (#7357)
+- Return partial OTLP export errors to the caller in `go.opentelemetry.io/otel/exporters/otlp/otlplog/otlploggrpc`. (#7372)
+- Return partial OTLP export errors to the caller in `go.opentelemetry.io/otel/exporters/otlp/otlplog/otlploghttp`. (#7372)
+- Return partial OTLP export errors to the caller in `go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetricgrpc`. (#7372)
+- Return partial OTLP export errors to the caller in `go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp`. (#7372)
+- Return partial OTLP export errors to the caller in `go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc`. (#7372)
+- Return partial OTLP export errors to the caller in `go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp`. (#7372)
+- Fix `AddAttributes`, `SetAttributes`, `SetBody` on `Record` in `go.opentelemetry.io/otel/sdk/log` to not mutate input. (#7403)
+- Do not double record measurements of `RecordSet` methods in `go.opentelemetry.io/otel/semconv/v1.37.0`. (#7655)
+- Do not double record measurements of `RecordSet` methods in `go.opentelemetry.io/otel/semconv/v1.36.0`. (#7656)
+
+### Removed
+
+- Drop support for [Go 1.23]. (#7274)
+- Remove the `FilterProcessor` interface in `go.opentelemetry.io/otel/sdk/log`.
+ The `Enabled` method has been added to the `Processor` interface instead.
+ All `Processor` implementations must now implement the `Enabled` method.
+ Custom processors that do not filter records can implement `Enabled` to return `true`. (#7639)
+
+## [1.38.0/0.60.0/0.14.0/0.0.13] 2025-08-29
+
+This release is the last to support [Go 1.23].
+The next release will require at least [Go 1.24].
+
+### Added
+
+- Add native histogram exemplar support in `go.opentelemetry.io/otel/exporters/prometheus`. (#6772)
+- Add template attribute functions to the `go.opentelmetry.io/otel/semconv/v1.34.0` package. (#6939)
+ - `ContainerLabel`
+ - `DBOperationParameter`
+ - `DBSystemParameter`
+ - `HTTPRequestHeader`
+ - `HTTPResponseHeader`
+ - `K8SCronJobAnnotation`
+ - `K8SCronJobLabel`
+ - `K8SDaemonSetAnnotation`
+ - `K8SDaemonSetLabel`
+ - `K8SDeploymentAnnotation`
+ - `K8SDeploymentLabel`
+ - `K8SJobAnnotation`
+ - `K8SJobLabel`
+ - `K8SNamespaceAnnotation`
+ - `K8SNamespaceLabel`
+ - `K8SNodeAnnotation`
+ - `K8SNodeLabel`
+ - `K8SPodAnnotation`
+ - `K8SPodLabel`
+ - `K8SReplicaSetAnnotation`
+ - `K8SReplicaSetLabel`
+ - `K8SStatefulSetAnnotation`
+ - `K8SStatefulSetLabel`
+ - `ProcessEnvironmentVariable`
+ - `RPCConnectRPCRequestMetadata`
+ - `RPCConnectRPCResponseMetadata`
+ - `RPCGRPCRequestMetadata`
+ - `RPCGRPCResponseMetadata`
+- Add `ErrorType` attribute helper function to the `go.opentelmetry.io/otel/semconv/v1.34.0` package. (#6962)
+- Add `WithAllowKeyDuplication` in `go.opentelemetry.io/otel/sdk/log` which can be used to disable deduplication for log records. (#6968)
+- Add `WithCardinalityLimit` option to configure the cardinality limit in `go.opentelemetry.io/otel/sdk/metric`. (#6996, #7065, #7081, #7164, #7165, #7179)
+- Add `Clone` method to `Record` in `go.opentelemetry.io/otel/log` that returns a copy of the record with no shared state. (#7001)
+- Add experimental self-observability span and batch span processor metrics in `go.opentelemetry.io/otel/sdk/trace`.
+ Check the `go.opentelemetry.io/otel/sdk/trace/internal/x` package documentation for more information. (#7027, #6393, #7209)
+- The `go.opentelemetry.io/otel/semconv/v1.36.0` package.
+ The package contains semantic conventions from the `v1.36.0` version of the OpenTelemetry Semantic Conventions.
+ See the [migration documentation](./semconv/v1.36.0/MIGRATION.md) for information on how to upgrade from `go.opentelemetry.io/otel/semconv/v1.34.0.`(#7032, #7041)
+- Add support for configuring Prometheus name translation using `WithTranslationStrategy` option in `go.opentelemetry.io/otel/exporters/prometheus`. The current default translation strategy when UTF-8 mode is enabled is `NoUTF8EscapingWithSuffixes`, but a future release will change the default strategy to `UnderscoreEscapingWithSuffixes` for compliance with the specification. (#7111)
+- Add experimental self-observability log metrics in `go.opentelemetry.io/otel/sdk/log`.
+ Check the `go.opentelemetry.io/otel/sdk/log/internal/x` package documentation for more information. (#7121)
+- Add experimental self-observability trace exporter metrics in `go.opentelemetry.io/otel/exporters/stdout/stdouttrace`.
+ Check the `go.opentelemetry.io/otel/exporters/stdout/stdouttrace/internal/x` package documentation for more information. (#7133)
+- Support testing of [Go 1.25]. (#7187)
+- The `go.opentelemetry.io/otel/semconv/v1.37.0` package.
+ The package contains semantic conventions from the `v1.37.0` version of the OpenTelemetry Semantic Conventions.
+ See the [migration documentation](./semconv/v1.37.0/MIGRATION.md) for information on how to upgrade from `go.opentelemetry.io/otel/semconv/v1.36.0.`(#7254)
+
+### Changed
+
+- Optimize `TraceIDFromHex` and `SpanIDFromHex` in `go.opentelemetry.io/otel/sdk/trace`. (#6791)
+- Change `AssertEqual` in `go.opentelemetry.io/otel/log/logtest` to accept `TestingT` in order to support benchmarks and fuzz tests. (#6908)
+- Change `DefaultExemplarReservoirProviderSelector` in `go.opentelemetry.io/otel/sdk/metric` to use `runtime.GOMAXPROCS(0)` instead of `runtime.NumCPU()` for the `FixedSizeReservoirProvider` default size. (#7094)
+
+### Fixed
+
+- `SetBody` method of `Record` in `go.opentelemetry.io/otel/sdk/log` now deduplicates key-value collections (`log.Value` of `log.KindMap` from `go.opentelemetry.io/otel/log`). (#7002)
+- Fix `go.opentelemetry.io/otel/exporters/prometheus` to not append a suffix if it's already present in metric name. (#7088)
+- Fix the `go.opentelemetry.io/otel/exporters/stdout/stdouttrace` self-observability component type and name. (#7195)
+- Fix partial export count metric in `go.opentelemetry.io/otel/exporters/stdout/stdouttrace`. (#7199)
+
+### Deprecated
+
+- Deprecate `WithoutUnits` and `WithoutCounterSuffixes` options, preferring `WithTranslationStrategy` instead. (#7111)
+- Deprecate support for `OTEL_GO_X_CARDINALITY_LIMIT` environment variable in `go.opentelemetry.io/otel/sdk/metric`. Use `WithCardinalityLimit` option instead. (#7166)
+
+## [0.59.1] 2025-07-21
+
+### Changed
+
+- Retract `v0.59.0` release of `go.opentelemetry.io/otel/exporters/prometheus` module which appends incorrect unit suffixes. (#7046)
+- Change `go.opentelemetry.io/otel/exporters/prometheus` to no longer deduplicate suffixes when UTF8 is enabled.
+ It is recommended to disable unit and counter suffixes in the exporter, and manually add suffixes if you rely on the existing behavior. (#7044)
+
+### Fixed
+
+- Fix `go.opentelemetry.io/otel/exporters/prometheus` to properly handle unit suffixes when the unit is in brackets.
+ E.g. `{spans}`. (#7044)
+
+## [1.37.0/0.59.0/0.13.0] 2025-06-25
+
+### Added
+
+- The `go.opentelemetry.io/otel/semconv/v1.33.0` package.
+ The package contains semantic conventions from the `v1.33.0` version of the OpenTelemetry Semantic Conventions.
+ See the [migration documentation](./semconv/v1.33.0/MIGRATION.md) for information on how to upgrade from `go.opentelemetry.io/otel/semconv/v1.32.0.`(#6799)
+- The `go.opentelemetry.io/otel/semconv/v1.34.0` package.
+ The package contains semantic conventions from the `v1.34.0` version of the OpenTelemetry Semantic Conventions. (#6812)
+- Add metric's schema URL as `otel_scope_schema_url` label in `go.opentelemetry.io/otel/exporters/prometheus`. (#5947)
+- Add metric's scope attributes as `otel_scope_[attribute]` labels in `go.opentelemetry.io/otel/exporters/prometheus`. (#5947)
+- Add `EventName` to `EnabledParameters` in `go.opentelemetry.io/otel/log`. (#6825)
+- Add `EventName` to `EnabledParameters` in `go.opentelemetry.io/otel/sdk/log`. (#6825)
+- Changed handling of `go.opentelemetry.io/otel/exporters/prometheus` metric renaming to add unit suffixes when it doesn't match one of the pre-defined values in the unit suffix map. (#6839)
+
+### Changed
+
+- The semantic conventions have been upgraded from `v1.26.0` to `v1.34.0` in `go.opentelemetry.io/otel/bridge/opentracing`. (#6827)
+- The semantic conventions have been upgraded from `v1.26.0` to `v1.34.0` in `go.opentelemetry.io/otel/exporters/zipkin`. (#6829)
+- The semantic conventions have been upgraded from `v1.26.0` to `v1.34.0` in `go.opentelemetry.io/otel/metric`. (#6832)
+- The semantic conventions have been upgraded from `v1.26.0` to `v1.34.0` in `go.opentelemetry.io/otel/sdk/resource`. (#6834)
+- The semantic conventions have been upgraded from `v1.26.0` to `v1.34.0` in `go.opentelemetry.io/otel/sdk/trace`. (#6835)
+- The semantic conventions have been upgraded from `v1.26.0` to `v1.34.0` in `go.opentelemetry.io/otel/trace`. (#6836)
+- `Record.Resource` now returns `*resource.Resource` instead of `resource.Resource` in `go.opentelemetry.io/otel/sdk/log`. (#6864)
+- Retry now shows error cause for context timeout in `go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc`, `go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetricgrpc`, `go.opentelemetry.io/otel/exporters/otlp/otlplog/otlploggrpc`, `go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp`, `go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp`, `go.opentelemetry.io/otel/exporters/otlp/otlplog/otlploghttp`. (#6898)
+
+### Fixed
+
+- Stop stripping trailing slashes from configured endpoint URL in `go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc`. (#6710)
+- Stop stripping trailing slashes from configured endpoint URL in `go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp`. (#6710)
+- Stop stripping trailing slashes from configured endpoint URL in `go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetricgrpc`. (#6710)
+- Stop stripping trailing slashes from configured endpoint URL in `go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp`. (#6710)
+- Validate exponential histogram scale range for Prometheus compatibility in `go.opentelemetry.io/otel/exporters/prometheus`. (#6822)
+- Context cancellation during metric pipeline produce does not corrupt data in `go.opentelemetry.io/otel/sdk/metric`. (#6914)
+
+### Removed
+
+- `go.opentelemetry.io/otel/exporters/prometheus` no longer exports `otel_scope_info` metric. (#6770)
+
+## [0.12.2] 2025-05-22
+
+### Fixed
+
+- Retract `v0.12.0` release of `go.opentelemetry.io/otel/exporters/otlp/otlplog/otlploggrpc` module that contains invalid dependencies. (#6804)
+- Retract `v0.12.0` release of `go.opentelemetry.io/otel/exporters/otlp/otlplog/otlploghttp` module that contains invalid dependencies. (#6804)
+- Retract `v0.12.0` release of `go.opentelemetry.io/otel/exporters/stdout/stdoutlog` module that contains invalid dependencies. (#6804)
+
+## [0.12.1] 2025-05-21
+
+### Fixes
+
+- Use the proper dependency version of `go.opentelemetry.io/otel/sdk/log/logtest` in `go.opentelemetry.io/otel/exporters/otlp/otlplog/otlploggrpc`. (#6800)
+- Use the proper dependency version of `go.opentelemetry.io/otel/sdk/log/logtest` in `go.opentelemetry.io/otel/exporters/otlp/otlplog/otlploghttp`. (#6800)
+- Use the proper dependency version of `go.opentelemetry.io/otel/sdk/log/logtest` in `go.opentelemetry.io/otel/exporters/stdout/stdoutlog`. (#6800)
+
## [1.36.0/0.58.0/0.12.0] 2025-05-20
### Added
@@ -3288,7 +3553,15 @@ It contains api and sdk for trace and meter.
- CircleCI build CI manifest files.
- CODEOWNERS file to track owners of this project.
-[Unreleased]: https://github.com/open-telemetry/opentelemetry-go/compare/v1.36.0...HEAD
+[Unreleased]: https://github.com/open-telemetry/opentelemetry-go/compare/v1.41.0...HEAD
+[1.41.0/0.63.0/0.17.0/0.0.15]: https://github.com/open-telemetry/opentelemetry-go/releases/tag/v1.41.0
+[1.40.0/0.62.0/0.16.0]: https://github.com/open-telemetry/opentelemetry-go/releases/tag/v1.40.0
+[1.39.0/0.61.0/0.15.0/0.0.14]: https://github.com/open-telemetry/opentelemetry-go/releases/tag/v1.39.0
+[1.38.0/0.60.0/0.14.0/0.0.13]: https://github.com/open-telemetry/opentelemetry-go/releases/tag/v1.38.0
+[0.59.1]: https://github.com/open-telemetry/opentelemetry-go/releases/tag/exporters/prometheus/v0.59.1
+[1.37.0/0.59.0/0.13.0]: https://github.com/open-telemetry/opentelemetry-go/releases/tag/v1.37.0
+[0.12.2]: https://github.com/open-telemetry/opentelemetry-go/releases/tag/log/v0.12.2
+[0.12.1]: https://github.com/open-telemetry/opentelemetry-go/releases/tag/log/v0.12.1
[1.36.0/0.58.0/0.12.0]: https://github.com/open-telemetry/opentelemetry-go/releases/tag/v1.36.0
[1.35.0/0.57.0/0.11.0]: https://github.com/open-telemetry/opentelemetry-go/releases/tag/v1.35.0
[1.34.0/0.56.0/0.10.0]: https://github.com/open-telemetry/opentelemetry-go/releases/tag/v1.34.0
@@ -3381,6 +3654,8 @@ It contains api and sdk for trace and meter.
+[Go 1.26]: https://go.dev/doc/go1.26
+[Go 1.25]: https://go.dev/doc/go1.25
[Go 1.24]: https://go.dev/doc/go1.24
[Go 1.23]: https://go.dev/doc/go1.23
[Go 1.22]: https://go.dev/doc/go1.22
diff --git a/vendor/go.opentelemetry.io/otel/CODEOWNERS b/vendor/go.opentelemetry.io/otel/CODEOWNERS
index 945a07d2b0..26a03aed1d 100644
--- a/vendor/go.opentelemetry.io/otel/CODEOWNERS
+++ b/vendor/go.opentelemetry.io/otel/CODEOWNERS
@@ -12,6 +12,6 @@
# https://help.github.com/en/articles/about-code-owners
#
-* @MrAlias @XSAM @dashpole @pellared @dmathieu
+* @MrAlias @XSAM @dashpole @pellared @dmathieu @flc1125
CODEOWNERS @MrAlias @pellared @dashpole @XSAM @dmathieu
diff --git a/vendor/go.opentelemetry.io/otel/CONTRIBUTING.md b/vendor/go.opentelemetry.io/otel/CONTRIBUTING.md
index 1902dac057..38dede9329 100644
--- a/vendor/go.opentelemetry.io/otel/CONTRIBUTING.md
+++ b/vendor/go.opentelemetry.io/otel/CONTRIBUTING.md
@@ -54,8 +54,8 @@ go get -d go.opentelemetry.io/otel
(This may print some warning about "build constraints exclude all Go
files", just ignore it.)
-This will put the project in `${GOPATH}/src/go.opentelemetry.io/otel`. You
-can alternatively use `git` directly with:
+This will put the project in `${GOPATH}/src/go.opentelemetry.io/otel`.
+Alternatively, you can use `git` directly with:
```sh
git clone https://github.com/open-telemetry/opentelemetry-go
@@ -65,8 +65,7 @@ git clone https://github.com/open-telemetry/opentelemetry-go
that name is a kind of a redirector to GitHub that `go get` can
understand, but `git` does not.)
-This would put the project in the `opentelemetry-go` directory in
-current working directory.
+This will add the project as `opentelemetry-go` within the current directory.
Enter the newly created directory and add your fork as a new remote:
@@ -109,10 +108,9 @@ A PR is considered **ready to merge** when:
This is not enforced through automation, but needs to be validated by the
maintainer merging.
- * The qualified approvals need to be from [Approver]s/[Maintainer]s
- affiliated with different companies. Two qualified approvals from
- [Approver]s or [Maintainer]s affiliated with the same company counts as a
- single qualified approval.
+ * At least one of the qualified approvals needs to be from an
+ [Approver]/[Maintainer] affiliated with a different company than the author
+ of the PR.
* PRs introducing changes that have already been discussed and consensus
reached only need one qualified approval. The discussion and resolution
needs to be linked to the PR.
@@ -167,11 +165,11 @@ guidelines](https://opentelemetry.io/docs/specs/otel/library-guidelines).
### Focus on Capabilities, Not Structure Compliance
OpenTelemetry is an evolving specification, one where the desires and
-use cases are clear, but the method to satisfy those uses cases are
+use cases are clear, but the methods to satisfy those use cases are
not.
As such, Contributions should provide functionality and behavior that
-conforms to the specification, but the interface and structure is
+conforms to the specification, but the interface and structure are
flexible.
It is preferable to have contributions follow the idioms of the
@@ -193,6 +191,35 @@ should have `go test -bench` output in their description.
should have [`benchstat`](https://pkg.go.dev/golang.org/x/perf/cmd/benchstat)
output in their description.
+## Dependencies
+
+This project uses [Go Modules] for dependency management. All modules will use
+`go.mod` to explicitly list all direct and indirect dependencies, ensuring a
+clear dependency graph. The `go.sum` file for each module will be committed to
+the repository and used to verify the integrity of downloaded modules,
+preventing malicious tampering.
+
+This project uses automated dependency update tools (i.e. dependabot,
+renovatebot) to manage updates to dependencies. This ensures that dependencies
+are kept up-to-date with the latest security patches and features and are
+reviewed before being merged. If you would like to propose a change to a
+dependency it should be done through a pull request that updates the `go.mod`
+file and includes a description of the change.
+
+See the [versioning and compatibility](./VERSIONING.md) policy for more details
+about dependency compatibility.
+
+[Go Modules]: https://pkg.go.dev/cmd/go#hdr-Modules__module_versions__and_more
+
+### Environment Dependencies
+
+This project does not partition dependencies based on the environment (i.e.
+`development`, `staging`, `production`).
+
+Only the dependencies explicitly included in the released modules have been
+tested and verified to work with the released code. No other guarantee is made
+about the compatibility of other dependencies.
+
## Documentation
Each (non-internal, non-test) package must be documented using
@@ -234,6 +261,10 @@ For a non-comprehensive but foundational overview of these best practices
the [Effective Go](https://golang.org/doc/effective_go.html) documentation
is an excellent starting place.
+We also recommend following the
+[Go Code Review Comments](https://go.dev/wiki/CodeReviewComments)
+that collects common comments made during reviews of Go code.
+
As a convenience for developers building this project the `make precommit`
will format, lint, validate, and in some cases fix the changes you plan to
submit. This check will need to pass for your changes to be able to be
@@ -587,6 +618,10 @@ See also:
### Testing
+We allow using [`testify`](https://github.com/stretchr/testify) even though
+it is seen as non-idiomatic according to
+the [Go Test Comments](https://go.dev/wiki/TestComments#assert-libraries) page.
+
The tests should never leak goroutines.
Use the term `ConcurrentSafe` in the test name when it aims to verify the
@@ -599,8 +634,8 @@ is not in their root name.
The use of internal packages should be scoped to a single module. A sub-module
should never import from a parent internal package. This creates a coupling
-between the two modules where a user can upgrade the parent without the child
-and if the internal package API has changed it will fail to upgrade[^3].
+between the two modules where a user can upgrade the parent without the child,
+and if the internal package API has changed, it will fail to upgrade[^3].
There are two known exceptions to this rule:
@@ -621,7 +656,7 @@ this.
### Ignoring context cancellation
-OpenTelemetry API implementations need to ignore the cancellation of the context that are
+OpenTelemetry API implementations need to ignore the cancellation of the context that is
passed when recording a value (e.g. starting a span, recording a measurement, emitting a log).
Recording methods should not return an error describing the cancellation state of the context
when they complete, nor should they abort any work.
@@ -639,33 +674,478 @@ force flushing telemetry, shutting down a signal provider) the context cancellat
should be honored. This means all work done on behalf of the user provided context
should be canceled.
+### Observability
+
+OpenTelemetry Go SDK components should be instrumented to enable users observability for the health and performance of the telemetry pipeline itself.
+This allows operators to understand how well their observability infrastructure is functioning and to identify potential issues before they impact their applications.
+
+This section outlines the best practices for building instrumentation in OpenTelemetry Go SDK components.
+
+#### Environment Variable Activation
+
+Observability features are currently experimental.
+They should be disabled by default and activated through the `OTEL_GO_X_OBSERVABILITY` environment variable.
+This follows the established experimental feature pattern used throughout the SDK.
+
+Components should check for this environment variable using a consistent pattern:
+
+```go
+import "go.opentelemetry.io/otel/*/internal/x"
+
+if x.Observability.Enabled() {
+ // Initialize observability metrics
+}
+```
+
+**References**:
+
+- [stdouttrace exporter](./exporters/stdout/stdouttrace/internal/x/x.go)
+- [sdk](./sdk/internal/x/x.go)
+
+#### Encapsulation
+
+Instrumentation should be encapsulated within a dedicated `struct` (e.g. `instrumentation`).
+It should not be mixed into the instrumented component.
+
+Prefer this:
+
+```go
+type SDKComponent struct {
+ inst *instrumentation
+}
+
+type instrumentation struct {
+ inflight otelconv.SDKComponentInflight
+ exported otelconv.SDKComponentExported
+}
+```
+
+To this:
+
+```go
+// ❌ Avoid this pattern.
+type SDKComponent struct {
+ /* other SDKComponent fields... */
+
+ inflight otelconv.SDKComponentInflight
+ exported otelconv.SDKComponentExported
+}
+```
+
+The instrumentation code should not bloat the code being instrumented.
+Likely, this means its own file, or its own package if it is complex or reused.
+
+#### Initialization
+
+Instrumentation setup should be explicit, side-effect free, and local to the relevant component.
+Avoid relying on global or implicit [side effects][side-effect] for initialization.
+
+Encapsulate setup in constructor functions, ensuring clear ownership and scope:
+
+```go
+import (
+ "errors"
+
+ semconv "go.opentelemetry.io/otel/semconv/v1.39.0"
+ "go.opentelemetry.io/otel/semconv/v1.39.0/otelconv"
+)
+
+type SDKComponent struct {
+ inst *instrumentation
+}
+
+func NewSDKComponent(config Config) (*SDKComponent, error) {
+ inst, err := newInstrumentation()
+ if err != nil {
+ return nil, err
+ }
+ return &SDKComponent{inst: inst}, nil
+}
+
+type instrumentation struct {
+ inflight otelconv.SDKComponentInflight
+ exported otelconv.SDKComponentExported
+}
+
+func newInstrumentation() (*instrumentation, error) {
+ if !x.Observability.Enabled() {
+ return nil, nil
+ }
+
+ meter := otel.GetMeterProvider().Meter(
+ "",
+ metric.WithInstrumentationVersion(sdk.Version()),
+ metric.WithSchemaURL(semconv.SchemaURL),
+ )
+
+ inst := &instrumentation{}
+
+ var err, e error
+ inst.inflight, e = otelconv.NewSDKComponentInflight(meter)
+ err = errors.Join(err, e)
+
+ inst.exported, e = otelconv.NewSDKComponentExported(meter)
+ err = errors.Join(err, e)
+
+ return inst, err
+}
+```
+
+```go
+// ❌ Avoid this pattern.
+func (c *Component) initObservability() {
+ // Initialize observability metrics
+ if !x.Observability.Enabled() {
+ return
+ }
+
+ // Initialize observability metrics
+ c.inst = &instrumentation{/* ... */}
+}
+```
+
+[side-effect]: https://en.wikipedia.org/wiki/Side_effect_(computer_science)
+
+#### Performance
+
+When observability is disabled there should be little to no overhead.
+
+```go
+func (e *Exporter) ExportSpans(ctx context.Context, spans []trace.ReadOnlySpan) error {
+ if e.inst != nil {
+ attrs := expensiveOperation()
+ e.inst.recordSpanInflight(ctx, int64(len(spans)), attrs...)
+ }
+ // Export spans...
+}
+```
+
+```go
+// ❌ Avoid this pattern.
+func (e *Exporter) ExportSpans(ctx context.Context, spans []trace.ReadOnlySpan) error {
+ attrs := expensiveOperation()
+ e.inst.recordSpanInflight(ctx, int64(len(spans)), attrs...)
+ // Export spans...
+}
+
+func (i *instrumentation) recordSpanInflight(ctx context.Context, count int64, attrs ...attribute.KeyValue) {
+ if i == nil || i.inflight == nil {
+ return
+ }
+ i.inflight.Add(ctx, count, metric.WithAttributes(attrs...))
+}
+```
+
+When observability is enabled, the instrumentation code paths should be optimized to reduce allocation and computation overhead.
+
+##### Attribute and Option Allocation Management
+
+Pool attribute slices and options with [`sync.Pool`] to minimize allocations in measurement calls with dynamic attributes.
+
+```go
+var (
+ attrPool = sync.Pool{
+ New: func() any {
+ // Pre-allocate common capacity
+ knownCap := 8 // Adjust based on expected usage
+ s := make([]attribute.KeyValue, 0, knownCap)
+ // Return a pointer to avoid extra allocation on Put().
+ return &s
+ },
+ }
+
+ addOptPool = &sync.Pool{
+ New: func() any {
+ const n = 1 // WithAttributeSet
+ o := make([]metric.AddOption, 0, n)
+ // Return a pointer to avoid extra allocation on Put().
+ return &o
+ },
+ }
+)
+
+func (i *instrumentation) record(ctx context.Context, value int64, baseAttrs ...attribute.KeyValue) {
+ attrs := attrPool.Get().(*[]attribute.KeyValue)
+ defer func() {
+ *attrs = (*attrs)[:0] // Reset.
+ attrPool.Put(attrs)
+ }()
+
+ *attrs = append(*attrs, baseAttrs...)
+ // Add any dynamic attributes.
+ *attrs = append(*attrs, semconv.OTelComponentName("exporter-1"))
+
+ addOpt := addOptPool.Get().(*[]metric.AddOption)
+ defer func() {
+ *addOpt = (*addOpt)[:0]
+ addOptPool.Put(addOpt)
+ }()
+
+ set := attribute.NewSet(*attrs...)
+ *addOpt = append(*addOpt, metric.WithAttributeSet(set))
+
+ i.counter.Add(ctx, value, *addOpt...)
+}
+```
+
+Pools are most effective when there are many pooled objects of the same sufficiently large size, and the objects are repeatedly used.
+This amortizes the cost of allocation and synchronization.
+Ideally, the pools should be scoped to be used as widely as possible within the component to maximize this efficiency while still ensuring correctness.
+
+[`sync.Pool`]: https://pkg.go.dev/sync#Pool
+
+##### Cache common attribute sets for repeated measurements
+
+If a static set of attributes are used for measurements and they are known at compile time, pre-compute and cache these attributes.
+
+```go
+type spanLiveSetKey struct {
+ sampled bool
+}
+
+var spanLiveSetCache = map[spanLiveSetKey]attribute.Set{
+ {true}: attribute.NewSet(
+ otelconv.SDKSpanLive{}.AttrSpanSamplingResult(
+ otelconv.SpanSamplingResultRecordAndSample,
+ ),
+ ),
+ {false}: attribute.NewSet(
+ otelconv.SDKSpanLive{}.AttrSpanSamplingResult(
+ otelconv.SpanSamplingResultRecordOnly,
+ ),
+ ),
+}
+
+func spanLiveSet(sampled bool) attribute.Set {
+ key := spanLiveSetKey{sampled: sampled}
+ return spanLiveSetCache[key]
+}
+```
+
+##### Benchmarking
+
+Always provide benchmarks when introducing or refactoring instrumentation.
+Demonstrate the impact (allocs/op, B/op, ns/op) in enabled/disabled scenarios:
+
+```go
+func BenchmarkExportSpans(b *testing.B) {
+ scenarios := []struct {
+ name string
+ obsEnabled bool
+ }{
+ {"ObsDisabled", false},
+ {"ObsEnabled", true},
+ }
+
+ for _, scenario := range scenarios {
+ b.Run(scenario.name, func(b *testing.B) {
+ b.Setenv(
+ "OTEL_GO_X_OBSERVABILITY",
+ strconv.FormatBool(scenario.obsEnabled),
+ )
+
+ exporter := NewExporter()
+ spans := generateTestSpans(100)
+
+ b.ResetTimer()
+ b.ReportAllocs()
+
+ for i := 0; i < b.N; i++ {
+ _ = exporter.ExportSpans(context.Background(), spans)
+ }
+ })
+ }
+}
+```
+
+#### Error Handling and Robustness
+
+Errors should be reported back to the caller if possible, and partial failures should be handled as gracefully as possible.
+
+```go
+func newInstrumentation() (*instrumentation, error) {
+ if !x.Observability.Enabled() {
+ return nil, nil
+ }
+
+ m := otel.GetMeterProvider().Meter(/* initialize meter */)
+ counter, err := otelconv.NewSDKComponentCounter(m)
+ // Use the partially initialized counter if available.
+ i := &instrumentation{counter: counter}
+ // Return any error to the caller.
+ return i, err
+}
+```
+
+```go
+// ❌ Avoid this pattern.
+func newInstrumentation() *instrumentation {
+ if !x.Observability.Enabled() {
+ return nil, nil
+ }
+
+ m := otel.GetMeterProvider().Meter(/* initialize meter */)
+ counter, err := otelconv.NewSDKComponentCounter(m)
+ if err != nil {
+ // ❌ Do not dump the error to the OTel Handler. Return it to the
+ // caller.
+ otel.Handle(err)
+ // ❌ Do not return nil if we can still use the partially initialized
+ // counter.
+ return nil
+ }
+ return &instrumentation{counter: counter}
+}
+```
+
+If the instrumented component cannot report the error to the user, let it report the error to `otel.Handle`.
+
+#### Context Propagation
+
+Ensure observability measurements receive the correct context, especially for trace exemplars and distributed context:
+
+```go
+func (e *Exporter) ExportSpans(ctx context.Context, spans []trace.ReadOnlySpan) error {
+ // Use the provided context for observability measurements
+ e.inst.recordSpanExportStarted(ctx, len(spans))
+
+ err := e.doExport(ctx, spans)
+
+ if err != nil {
+ e.inst.recordSpanExportFailed(ctx, len(spans), err)
+ } else {
+ e.inst.recordSpanExportSucceeded(ctx, len(spans))
+ }
+
+ return err
+}
+```
+
+```go
+// ❌ Avoid this pattern.
+func (e *Exporter) ExportSpans(ctx context.Context, spans []trace.ReadOnlySpan) error {
+ // ❌ Do not break the context propagation.
+ e.inst.recordSpanExportStarted(context.Background(), len(spans))
+
+ err := e.doExport(ctx, spans)
+
+ /* ... */
+
+ return err
+}
+```
+
+#### Semantic Conventions Compliance
+
+All observability metrics should follow the [OpenTelemetry Semantic Conventions for SDK metrics](https://github.com/open-telemetry/semantic-conventions/blob/1cf2476ae5e518225a766990a28a6d5602bd5a30/docs/otel/sdk-metrics.md).
+
+Use the metric semantic conventions convenience package [otelconv](./semconv/v1.39.0/otelconv/metric.go).
+
+##### Component Identification
+
+Component names and types should follow [semantic convention](https://github.com/open-telemetry/semantic-conventions/blob/1cf2476ae5e518225a766990a28a6d5602bd5a30/docs/registry/attributes/otel.md#otel-component-attributes).
+
+If a component is not a well-known type specified in the semantic conventions, use the package path scope type as a stable identifier.
+
+```go
+componentType := "go.opentelemetry.io/otel/sdk/trace.Span"
+```
+
+```go
+// ❌ Do not do this.
+componentType := "trace-span"
+```
+
+The component name should be a stable unique identifier for the specific instance of the component.
+
+Use a global counter to ensure uniqueness if necessary.
+
+```go
+// Unique 0-based ID counter for component instances.
+var componentIDCounter atomic.Int64
+
+// nextID returns the next unique ID for a component.
+func nextID() int64 {
+ return componentIDCounter.Add(1) - 1
+}
+
+// componentName returns a unique name for the component instance.
+func componentName() attribute.KeyValue {
+ id := nextID()
+ name := fmt.Sprintf("%s/%d", componentType, id)
+ return semconv.OTelComponentName(name)
+}
+```
+
+The component ID will need to be resettable for deterministic testing.
+If tests are in a different package than the component being tested (i.e. a `_test` package name), use a generated `counter` internal package to manage the counter.
+See [stdouttrace exporter example](./exporters/stdout/stdouttrace/internal/gen.go) for reference.
+
+#### Testing
+
+Use deterministic testing with isolated state:
+
+```go
+func TestObservability(t *testing.T) {
+ // Restore state after test to ensure this does not affect other tests.
+ prev := otel.GetMeterProvider()
+ t.Cleanup(func() { otel.SetMeterProvider(prev) })
+
+ // Isolate the meter provider for deterministic testing
+ reader := metric.NewManualReader()
+ meterProvider := metric.NewMeterProvider(metric.WithReader(reader))
+ otel.SetMeterProvider(meterProvider)
+
+ // Use t.Setenv to ensure environment variable is restored after test.
+ t.Setenv("OTEL_GO_X_OBSERVABILITY", "true")
+
+ // Reset component ID counter to ensure deterministic component names.
+ componentIDCounter.Store(0)
+
+ /* ... test code ... */
+}
+```
+
+Test order should not affect results.
+Ensure that any global state (e.g. component ID counters) is reset between tests.
+
## Approvers and Maintainers
-### Triagers
+### Maintainers
-- [Alex Kats](https://github.com/akats7), Capital One
-- [Cheng-Zhen Yang](https://github.com/scorpionknifes), Independent
+- [Damien Mathieu](https://github.com/dmathieu), Elastic ([GPG](https://keys.openpgp.org/search?q=5A126B972A81A6CE443E5E1B408B8E44F0873832))
+- [David Ashpole](https://github.com/dashpole), Google ([GPG](https://keys.openpgp.org/search?q=C0D1BDDCAAEAE573673085F176327DA4D864DC70))
+- [Robert Pająk](https://github.com/pellared), Splunk ([GPG](https://keys.openpgp.org/search?q=CDAD3A60476A3DE599AA5092E5F7C35A4DBE90C2))
+- [Sam Xie](https://github.com/XSAM), Splunk ([GPG](https://keys.openpgp.org/search?q=AEA033782371ABB18EE39188B8044925D6FEEBEA))
+- [Tyler Yahn](https://github.com/MrAlias), Splunk ([GPG](https://keys.openpgp.org/search?q=0x46B0F3E1A8B1BA5A))
+
+For more information about the maintainer role, see the [community repository](https://github.com/open-telemetry/community/blob/main/guides/contributor/membership.md#maintainer).
### Approvers
-### Maintainers
+- [Flc](https://github.com/flc1125), Independent
+
+For more information about the approver role, see the [community repository](https://github.com/open-telemetry/community/blob/main/guides/contributor/membership.md#approver).
-- [Damien Mathieu](https://github.com/dmathieu), Elastic
-- [David Ashpole](https://github.com/dashpole), Google
-- [Robert Pająk](https://github.com/pellared), Splunk
-- [Sam Xie](https://github.com/XSAM), Cisco/AppDynamics
-- [Tyler Yahn](https://github.com/MrAlias), Splunk
+### Triagers
+
+- [Alex Kats](https://github.com/akats7), Capital One
+
+For more information about the triager role, see the [community repository](https://github.com/open-telemetry/community/blob/main/guides/contributor/membership.md#triager).
### Emeritus
- [Aaron Clawson](https://github.com/MadVikingGod)
- [Anthony Mirabella](https://github.com/Aneurysm9)
+- [Cheng-Zhen Yang](https://github.com/scorpionknifes)
- [Chester Cheung](https://github.com/hanyuancheung)
- [Evan Torrie](https://github.com/evantorrie)
- [Gustavo Silva Paiva](https://github.com/paivagustavo)
- [Josh MacDonald](https://github.com/jmacd)
- [Liz Fong-Jones](https://github.com/lizthegrey)
+For more information about the emeritus role, see the [community repository](https://github.com/open-telemetry/community/blob/main/guides/contributor/membership.md#emeritus-maintainerapprovertriager).
+
### Become an Approver or a Maintainer
See the [community membership document in OpenTelemetry community
diff --git a/vendor/go.opentelemetry.io/otel/LICENSE b/vendor/go.opentelemetry.io/otel/LICENSE
index 261eeb9e9f..f1aee0f110 100644
--- a/vendor/go.opentelemetry.io/otel/LICENSE
+++ b/vendor/go.opentelemetry.io/otel/LICENSE
@@ -199,3 +199,33 @@
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
+
+--------------------------------------------------------------------------------
+
+Copyright 2009 The Go Authors.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are
+met:
+
+ * Redistributions of source code must retain the above copyright
+notice, this list of conditions and the following disclaimer.
+ * Redistributions in binary form must reproduce the above
+copyright notice, this list of conditions and the following disclaimer
+in the documentation and/or other materials provided with the
+distribution.
+ * Neither the name of Google LLC nor the names of its
+contributors may be used to endorse or promote products derived from
+this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
\ No newline at end of file
diff --git a/vendor/go.opentelemetry.io/otel/Makefile b/vendor/go.opentelemetry.io/otel/Makefile
index 62a56f4d34..fc4befb227 100644
--- a/vendor/go.opentelemetry.io/otel/Makefile
+++ b/vendor/go.opentelemetry.io/otel/Makefile
@@ -34,9 +34,6 @@ $(TOOLS)/%: $(TOOLS_MOD_DIR)/go.mod | $(TOOLS)
MULTIMOD = $(TOOLS)/multimod
$(TOOLS)/multimod: PACKAGE=go.opentelemetry.io/build-tools/multimod
-SEMCONVGEN = $(TOOLS)/semconvgen
-$(TOOLS)/semconvgen: PACKAGE=go.opentelemetry.io/build-tools/semconvgen
-
CROSSLINK = $(TOOLS)/crosslink
$(TOOLS)/crosslink: PACKAGE=go.opentelemetry.io/build-tools/crosslink
@@ -71,7 +68,7 @@ GOVULNCHECK = $(TOOLS)/govulncheck
$(TOOLS)/govulncheck: PACKAGE=golang.org/x/vuln/cmd/govulncheck
.PHONY: tools
-tools: $(CROSSLINK) $(GOLANGCI_LINT) $(MISSPELL) $(GOCOVMERGE) $(STRINGER) $(PORTO) $(SEMCONVGEN) $(VERIFYREADMES) $(MULTIMOD) $(SEMCONVKIT) $(GOTMPL) $(GORELEASE)
+tools: $(CROSSLINK) $(GOLANGCI_LINT) $(MISSPELL) $(GOCOVMERGE) $(STRINGER) $(PORTO) $(VERIFYREADMES) $(MULTIMOD) $(SEMCONVKIT) $(GOTMPL) $(GORELEASE)
# Virtualized python tools via docker
@@ -149,11 +146,12 @@ build-tests/%:
# Tests
-TEST_TARGETS := test-default test-bench test-short test-verbose test-race test-concurrent-safe
+TEST_TARGETS := test-default test-bench test-short test-verbose test-race test-concurrent-safe test-fuzz
.PHONY: $(TEST_TARGETS) test
test-default test-race: ARGS=-race
test-bench: ARGS=-run=xxxxxMatchNothingxxxxx -test.benchtime=1ms -bench=.
test-short: ARGS=-short
+test-fuzz: ARGS=-fuzztime=10s -fuzz
test-verbose: ARGS=-v -race
test-concurrent-safe: ARGS=-run=ConcurrentSafe -count=100 -race
test-concurrent-safe: TIMEOUT=120
@@ -217,7 +215,7 @@ go-mod-tidy/%: crosslink
&& $(GO) mod tidy -compat=1.21
.PHONY: lint
-lint: misspell go-mod-tidy golangci-lint govulncheck
+lint: misspell go-mod-tidy golangci-lint
.PHONY: vanity-import-check
vanity-import-check: $(PORTO)
@@ -284,7 +282,7 @@ semconv-generate: $(SEMCONVKIT)
docker run --rm \
-u $(DOCKER_USER) \
--env HOME=/tmp/weaver \
- --mount 'type=bind,source=$(PWD)/semconv,target=/home/weaver/templates/registry/go,readonly' \
+ --mount 'type=bind,source=$(PWD)/semconv/templates,target=/home/weaver/templates,readonly' \
--mount 'type=bind,source=$(PWD)/semconv/${TAG},target=/home/weaver/target' \
--mount 'type=bind,source=$(HOME)/.weaver,target=/tmp/weaver/.weaver' \
$(WEAVER_IMAGE) registry generate \
@@ -293,7 +291,7 @@ semconv-generate: $(SEMCONVKIT)
--param tag=$(TAG) \
go \
/home/weaver/target
- $(SEMCONVKIT) -output "$(SEMCONVPKG)/$(TAG)" -tag "$(TAG)"
+ $(SEMCONVKIT) -semconv "$(SEMCONVPKG)" -tag "$(TAG)"
.PHONY: gorelease
gorelease: $(OTEL_GO_MOD_DIRS:%=gorelease/%)
diff --git a/vendor/go.opentelemetry.io/otel/README.md b/vendor/go.opentelemetry.io/otel/README.md
index b600788121..6b1e170c4b 100644
--- a/vendor/go.opentelemetry.io/otel/README.md
+++ b/vendor/go.opentelemetry.io/otel/README.md
@@ -7,6 +7,7 @@
[](https://scorecard.dev/viewer/?uri=github.com/open-telemetry/opentelemetry-go)
[](https://www.bestpractices.dev/projects/9996)
[](https://issues.oss-fuzz.com/issues?q=project:opentelemetry-go)
+[](https://app.fossa.com/projects/custom%2B162%2Fgithub.com%2Fopen-telemetry%2Fopentelemetry-go?ref=badge_shield&issueType=license)
[](https://cloud-native.slack.com/archives/C01NPAXACKT)
OpenTelemetry-Go is the [Go](https://golang.org/) implementation of [OpenTelemetry](https://opentelemetry.io/).
@@ -52,20 +53,27 @@ Currently, this project supports the following environments.
| OS | Go Version | Architecture |
|----------|------------|--------------|
+| Ubuntu | 1.26 | amd64 |
+| Ubuntu | 1.25 | amd64 |
| Ubuntu | 1.24 | amd64 |
-| Ubuntu | 1.23 | amd64 |
+| Ubuntu | 1.26 | 386 |
+| Ubuntu | 1.25 | 386 |
| Ubuntu | 1.24 | 386 |
-| Ubuntu | 1.23 | 386 |
+| Ubuntu | 1.26 | arm64 |
+| Ubuntu | 1.25 | arm64 |
| Ubuntu | 1.24 | arm64 |
-| Ubuntu | 1.23 | arm64 |
-| macOS 13 | 1.24 | amd64 |
-| macOS 13 | 1.23 | amd64 |
+| macOS | 1.26 | amd64 |
+| macOS | 1.25 | amd64 |
+| macOS | 1.24 | amd64 |
+| macOS | 1.26 | arm64 |
+| macOS | 1.25 | arm64 |
| macOS | 1.24 | arm64 |
-| macOS | 1.23 | arm64 |
+| Windows | 1.26 | amd64 |
+| Windows | 1.25 | amd64 |
| Windows | 1.24 | amd64 |
-| Windows | 1.23 | amd64 |
+| Windows | 1.26 | 386 |
+| Windows | 1.25 | 386 |
| Windows | 1.24 | 386 |
-| Windows | 1.23 | 386 |
While this project should work for other systems, no compatibility guarantees
are made for those systems currently.
diff --git a/vendor/go.opentelemetry.io/otel/RELEASING.md b/vendor/go.opentelemetry.io/otel/RELEASING.md
index 7c1a9119dc..861756fd74 100644
--- a/vendor/go.opentelemetry.io/otel/RELEASING.md
+++ b/vendor/go.opentelemetry.io/otel/RELEASING.md
@@ -24,7 +24,7 @@ Ensure things look correct before submitting a pull request to include the addit
## Breaking changes validation
-You can run `make gorelease` that runs [gorelease](https://pkg.go.dev/golang.org/x/exp/cmd/gorelease) to ensure that there are no unwanted changes done in the public API.
+You can run `make gorelease` which runs [gorelease](https://pkg.go.dev/golang.org/x/exp/cmd/gorelease) to ensure that there are no unwanted changes made in the public API.
You can check/report problems with `gorelease` [here](https://golang.org/issues/26420).
@@ -62,7 +62,7 @@ Update go.mod for submodules to depend on the new release which will happen in t
```
3. Update the [Changelog](./CHANGELOG.md).
- - Make sure all relevant changes for this release are included and are in language that non-contributors to the project can understand.
+ - Make sure all relevant changes for this release are included and are written in language that non-contributors to the project can understand.
To verify this, you can look directly at the commits since the ``.
```
@@ -107,11 +107,50 @@ It is critical you make sure the version you push upstream is correct.
...
```
+## Sign artifacts
+
+To ensure we comply with CNCF best practices, we need to sign the release artifacts.
+
+Download the `.tar.gz` and `.zip` archives from the [tags page](https://github.com/open-telemetry/opentelemetry-go/tags) for the new release tag.
+Both archives need to be signed with your GPG key.
+
+You can use [this script] to verify the contents of the archives before signing them.
+
+To find your GPG key ID, run:
+
+```terminal
+gpg --list-secret-keys --keyid-format=long
+```
+
+The key ID is the 16-character string after `sec rsa4096/` (or similar).
+
+Set environment variables and sign both artifacts:
+
+```terminal
+export VERSION="" # e.g., v1.32.0
+export KEY_ID=""
+
+gpg --local-user $KEY_ID --armor --detach-sign opentelemetry-go-$VERSION.tar.gz
+gpg --local-user $KEY_ID --armor --detach-sign opentelemetry-go-$VERSION.zip
+```
+
+You can verify the signatures with:
+
+```terminal
+gpg --verify opentelemetry-go-$VERSION.tar.gz.asc opentelemetry-go-$VERSION.tar.gz
+gpg --verify opentelemetry-go-$VERSION.zip.asc opentelemetry-go-$VERSION.zip
+```
+
+[this script]: https://github.com/MrAlias/attest-sh
+
## Release
Finally create a Release for the new `` on GitHub.
The release body should include all the release notes from the Changelog for this release.
+***IMPORTANT***: GitHub Releases are immutable once created.
+You must upload the signed artifacts (`.tar.gz`, `.tar.gz.asc`, `.zip`, and `.zip.asc`) when creating the release, as they cannot be added or modified later.
+
## Post-Release
### Contrib Repository
@@ -137,14 +176,6 @@ This helps track what changes were included in each release.
Once all related issues and PRs have been added to the milestone, close the milestone.
-### Demo Repository
-
-Bump the dependencies in the following Go services:
-
-- [`accounting`](https://github.com/open-telemetry/opentelemetry-demo/tree/main/src/accounting)
-- [`checkoutservice`](https://github.com/open-telemetry/opentelemetry-demo/tree/main/src/checkout)
-- [`productcatalogservice`](https://github.com/open-telemetry/opentelemetry-demo/tree/main/src/product-catalog)
-
### Close the `Version Release` issue
Once the todo list in the `Version Release` issue is complete, close the issue.
diff --git a/vendor/go.opentelemetry.io/otel/SECURITY-INSIGHTS.yml b/vendor/go.opentelemetry.io/otel/SECURITY-INSIGHTS.yml
new file mode 100644
index 0000000000..8041fc62e4
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/SECURITY-INSIGHTS.yml
@@ -0,0 +1,203 @@
+header:
+ schema-version: "1.0.0"
+ expiration-date: "2026-08-04T00:00:00.000Z"
+ last-updated: "2025-08-04"
+ last-reviewed: "2025-08-04"
+ commit-hash: 69e81088ad40f45a0764597326722dea8f3f00a8
+ project-url: https://github.com/open-telemetry/opentelemetry-go
+ project-release: "v1.37.0"
+ changelog: https://github.com/open-telemetry/opentelemetry-go/blob/69e81088ad40f45a0764597326722dea8f3f00a8/CHANGELOG.md
+ license: https://github.com/open-telemetry/opentelemetry-go/blob/69e81088ad40f45a0764597326722dea8f3f00a8/LICENSE
+
+project-lifecycle:
+ status: active
+ bug-fixes-only: false
+ core-maintainers:
+ - https://github.com/dmathieu
+ - https://github.com/dashpole
+ - https://github.com/pellared
+ - https://github.com/XSAM
+ - https://github.com/MrAlias
+ release-process: |
+ See https://github.com/open-telemetry/opentelemetry-go/blob/69e81088ad40f45a0764597326722dea8f3f00a8/RELEASING.md
+
+contribution-policy:
+ accepts-pull-requests: true
+ accepts-automated-pull-requests: true
+ automated-tools-list:
+ - automated-tool: dependabot
+ action: allowed
+ comment: Automated dependency updates are accepted.
+ - automated-tool: renovatebot
+ action: allowed
+ comment: Automated dependency updates are accepted.
+ - automated-tool: opentelemetrybot
+ action: allowed
+ comment: Automated OpenTelemetry actions are accepted.
+ contributing-policy: https://github.com/open-telemetry/opentelemetry-go/blob/69e81088ad40f45a0764597326722dea8f3f00a8/CONTRIBUTING.md
+ code-of-conduct: https://github.com/open-telemetry/.github/blob/ffa15f76b65ec7bcc41f6a0b277edbb74f832206/CODE_OF_CONDUCT.md
+
+documentation:
+ - https://pkg.go.dev/go.opentelemetry.io/otel
+ - https://opentelemetry.io/docs/instrumentation/go/
+
+distribution-points:
+ - pkg:golang/go.opentelemetry.io/otel
+ - pkg:golang/go.opentelemetry.io/otel/bridge/opencensus
+ - pkg:golang/go.opentelemetry.io/otel/bridge/opencensus/test
+ - pkg:golang/go.opentelemetry.io/otel/bridge/opentracing
+ - pkg:golang/go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetricgrpc
+ - pkg:golang/go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp
+ - pkg:golang/go.opentelemetry.io/otel/exporters/otlp/otlptrace
+ - pkg:golang/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc
+ - pkg:golang/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp
+ - pkg:golang/go.opentelemetry.io/otel/exporters/stdout/stdoutmetric
+ - pkg:golang/go.opentelemetry.io/otel/exporters/stdout/stdouttrace
+ - pkg:golang/go.opentelemetry.io/otel/exporters/zipkin
+ - pkg:golang/go.opentelemetry.io/otel/metric
+ - pkg:golang/go.opentelemetry.io/otel/sdk
+ - pkg:golang/go.opentelemetry.io/otel/sdk/metric
+ - pkg:golang/go.opentelemetry.io/otel/trace
+ - pkg:golang/go.opentelemetry.io/otel/exporters/prometheus
+ - pkg:golang/go.opentelemetry.io/otel/log
+ - pkg:golang/go.opentelemetry.io/otel/log/logtest
+ - pkg:golang/go.opentelemetry.io/otel/sdk/log
+ - pkg:golang/go.opentelemetry.io/otel/sdk/log/logtest
+ - pkg:golang/go.opentelemetry.io/otel/exporters/otlp/otlplog/otlploggrpc
+ - pkg:golang/go.opentelemetry.io/otel/exporters/otlp/otlplog/otlploghttp
+ - pkg:golang/go.opentelemetry.io/otel/exporters/stdout/stdoutlog
+ - pkg:golang/go.opentelemetry.io/otel/schema
+
+security-artifacts:
+ threat-model:
+ threat-model-created: false
+ comment: |
+ No formal threat model created yet.
+ self-assessment:
+ self-assessment-created: false
+ comment: |
+ No formal self-assessment yet.
+
+security-testing:
+ - tool-type: sca
+ tool-name: Dependabot
+ tool-version: latest
+ tool-url: https://github.com/dependabot
+ tool-rulesets:
+ - built-in
+ integration:
+ ad-hoc: false
+ ci: true
+ before-release: true
+ comment: |
+ Automated dependency updates.
+ - tool-type: sast
+ tool-name: golangci-lint
+ tool-version: latest
+ tool-url: https://github.com/golangci/golangci-lint
+ tool-rulesets:
+ - built-in
+ integration:
+ ad-hoc: false
+ ci: true
+ before-release: true
+ comment: |
+ Static analysis in CI.
+ - tool-type: fuzzing
+ tool-name: OSS-Fuzz
+ tool-version: latest
+ tool-url: https://github.com/google/oss-fuzz
+ tool-rulesets:
+ - default
+ integration:
+ ad-hoc: false
+ ci: false
+ before-release: false
+ comment: |
+ OpenTelemetry Go is integrated with OSS-Fuzz for continuous fuzz testing. See https://github.com/google/oss-fuzz/tree/f0f9b221190c6063a773bea606d192ebfc3d00cf/projects/opentelemetry-go for more details.
+ - tool-type: sast
+ tool-name: CodeQL
+ tool-version: latest
+ tool-url: https://github.com/github/codeql
+ tool-rulesets:
+ - default
+ integration:
+ ad-hoc: false
+ ci: true
+ before-release: true
+ comment: |
+ CodeQL static analysis is run in CI for all commits and pull requests to detect security vulnerabilities in the Go source code. See https://github.com/open-telemetry/opentelemetry-go/blob/d5b5b059849720144a03ca5c87561bfbdb940119/.github/workflows/codeql-analysis.yml for workflow details.
+ - tool-type: sca
+ tool-name: govulncheck
+ tool-version: latest
+ tool-url: https://pkg.go.dev/golang.org/x/vuln/cmd/govulncheck
+ tool-rulesets:
+ - default
+ integration:
+ ad-hoc: false
+ ci: true
+ before-release: true
+ comment: |
+ govulncheck is run in CI to detect known vulnerabilities in Go modules and code paths. See https://github.com/open-telemetry/opentelemetry-go/blob/v1.37.0/.github/workflows/ci.yml for workflow configuration.
+
+security-assessments:
+ - auditor-name: 7ASecurity
+ auditor-url: https://7asecurity.com
+ auditor-report: https://7asecurity.com/reports/pentest-report-opentelemetry.pdf
+ report-year: 2023
+ comment: |
+ This independent penetration test by 7ASecurity covered OpenTelemetry repositories including opentelemetry-go. The assessment focused on codebase review, threat modeling, and vulnerability identification. See the report for details of findings and recommendations applicable to opentelemetry-go. No critical vulnerabilities were found for this repository.
+
+security-contacts:
+ - type: email
+ value: cncf-opentelemetry-security@lists.cncf.io
+ primary: true
+ - type: website
+ value: https://github.com/open-telemetry/opentelemetry-go/security/policy
+ primary: false
+
+vulnerability-reporting:
+ accepts-vulnerability-reports: true
+ email-contact: cncf-opentelemetry-security@lists.cncf.io
+ security-policy: https://github.com/open-telemetry/opentelemetry-go/security/policy
+ comment: |
+ Security issues should be reported via email or GitHub security policy page.
+
+dependencies:
+ third-party-packages: true
+ dependencies-lists:
+ - https://github.com/open-telemetry/opentelemetry-go/blob/v1.37.0/go.mod
+ - https://github.com/open-telemetry/opentelemetry-go/blob/v1.37.0/bridge/opencensus/go.mod
+ - https://github.com/open-telemetry/opentelemetry-go/blob/v1.37.0/bridge/opencensus/test/go.mod
+ - https://github.com/open-telemetry/opentelemetry-go/blob/v1.37.0/bridge/opentracing/go.mod
+ - https://github.com/open-telemetry/opentelemetry-go/blob/v1.37.0/exporters/otlp/otlplog/otlploggrpc/go.mod
+ - https://github.com/open-telemetry/opentelemetry-go/blob/v1.37.0/exporters/otlp/otlplog/otlploghttp/go.mod
+ - https://github.com/open-telemetry/opentelemetry-go/blob/v1.37.0/exporters/otlp/otlpmetric/otlpmetricgrpc/go.mod
+ - https://github.com/open-telemetry/opentelemetry-go/blob/v1.37.0/exporters/otlp/otlpmetric/otlpmetrichttp/go.mod
+ - https://github.com/open-telemetry/opentelemetry-go/blob/v1.37.0/exporters/otlp/otlptrace/go.mod
+ - https://github.com/open-telemetry/opentelemetry-go/blob/v1.37.0/exporters/otlp/otlptrace/otlptracegrpc/go.mod
+ - https://github.com/open-telemetry/opentelemetry-go/blob/v1.37.0/exporters/otlp/otlptrace/otlptracehttp/go.mod
+ - https://github.com/open-telemetry/opentelemetry-go/blob/v1.37.0/exporters/prometheus/go.mod
+ - https://github.com/open-telemetry/opentelemetry-go/blob/v1.37.0/exporters/stdout/stdoutlog/go.mod
+ - https://github.com/open-telemetry/opentelemetry-go/blob/v1.37.0/exporters/stdout/stdoutmetric/go.mod
+ - https://github.com/open-telemetry/opentelemetry-go/blob/v1.37.0/exporters/stdout/stdouttrace/go.mod
+ - https://github.com/open-telemetry/opentelemetry-go/blob/v1.37.0/exporters/zipkin/go.mod
+ - https://github.com/open-telemetry/opentelemetry-go/blob/v1.37.0/internal/tools/go.mod
+ - https://github.com/open-telemetry/opentelemetry-go/blob/v1.37.0/log/go.mod
+ - https://github.com/open-telemetry/opentelemetry-go/blob/v1.37.0/log/logtest/go.mod
+ - https://github.com/open-telemetry/opentelemetry-go/blob/v1.37.0/metric/go.mod
+ - https://github.com/open-telemetry/opentelemetry-go/blob/v1.37.0/schema/go.mod
+ - https://github.com/open-telemetry/opentelemetry-go/blob/v1.37.0/sdk/go.mod
+ - https://github.com/open-telemetry/opentelemetry-go/blob/v1.37.0/sdk/log/go.mod
+ - https://github.com/open-telemetry/opentelemetry-go/blob/v1.37.0/sdk/log/logtest/go.mod
+ - https://github.com/open-telemetry/opentelemetry-go/blob/v1.37.0/sdk/metric/go.mod
+ - https://github.com/open-telemetry/opentelemetry-go/blob/v1.37.0/trace/go.mod
+ - https://github.com/open-telemetry/opentelemetry-go/blob/v1.37.0/trace/internal/telemetry/test/go.mod
+ dependencies-lifecycle:
+ policy-url: https://github.com/open-telemetry/opentelemetry-go/blob/69e81088ad40f45a0764597326722dea8f3f00a8/CONTRIBUTING.md
+ comment: |
+ Dependency lifecycle managed via go.mod and renovatebot.
+ env-dependencies-policy:
+ policy-url: https://github.com/open-telemetry/opentelemetry-go/blob/69e81088ad40f45a0764597326722dea8f3f00a8/CONTRIBUTING.md
+ comment: |
+ See contributing policy for environment usage.
diff --git a/vendor/go.opentelemetry.io/otel/VERSIONING.md b/vendor/go.opentelemetry.io/otel/VERSIONING.md
index b8cb605c16..b27c9e84f5 100644
--- a/vendor/go.opentelemetry.io/otel/VERSIONING.md
+++ b/vendor/go.opentelemetry.io/otel/VERSIONING.md
@@ -83,7 +83,7 @@ is designed so the following goals can be achieved.
in either the module path or the import path.
* In addition to public APIs, telemetry produced by stable instrumentation
will remain stable and backwards compatible. This is to avoid breaking
- alerts and dashboard.
+ alerts and dashboards.
* Modules will be used to encapsulate instrumentation, detectors, exporters,
propagators, and any other independent sets of related components.
* Experimental modules still under active development will be versioned at
diff --git a/vendor/go.opentelemetry.io/otel/attribute/encoder.go b/vendor/go.opentelemetry.io/otel/attribute/encoder.go
index 318e42fcab..6cc1a1655c 100644
--- a/vendor/go.opentelemetry.io/otel/attribute/encoder.go
+++ b/vendor/go.opentelemetry.io/otel/attribute/encoder.go
@@ -16,7 +16,7 @@ type (
// set into a wire representation.
Encoder interface {
// Encode returns the serialized encoding of the attribute set using
- // its Iterator. This result may be cached by a attribute.Set.
+ // its Iterator. This result may be cached by an attribute.Set.
Encode(iterator Iterator) string
// ID returns a value that is unique for each class of attribute
@@ -78,7 +78,7 @@ func DefaultEncoder() Encoder {
defaultEncoderOnce.Do(func() {
defaultEncoderInstance = &defaultAttrEncoder{
pool: sync.Pool{
- New: func() interface{} {
+ New: func() any {
return &bytes.Buffer{}
},
},
@@ -96,11 +96,11 @@ func (d *defaultAttrEncoder) Encode(iter Iterator) string {
for iter.Next() {
i, keyValue := iter.IndexedAttribute()
if i > 0 {
- _, _ = buf.WriteRune(',')
+ _ = buf.WriteByte(',')
}
copyAndEscape(buf, string(keyValue.Key))
- _, _ = buf.WriteRune('=')
+ _ = buf.WriteByte('=')
if keyValue.Value.Type() == STRING {
copyAndEscape(buf, keyValue.Value.AsString())
@@ -122,14 +122,14 @@ func copyAndEscape(buf *bytes.Buffer, val string) {
for _, ch := range val {
switch ch {
case '=', ',', escapeChar:
- _, _ = buf.WriteRune(escapeChar)
+ _ = buf.WriteByte(escapeChar)
}
_, _ = buf.WriteRune(ch)
}
}
-// Valid returns true if this encoder ID was allocated by
-// `NewEncoderID`. Invalid encoder IDs will not be cached.
+// Valid reports whether this encoder ID was allocated by
+// [NewEncoderID]. Invalid encoder IDs will not be cached.
func (id EncoderID) Valid() bool {
return id.value != 0
}
diff --git a/vendor/go.opentelemetry.io/otel/attribute/filter.go b/vendor/go.opentelemetry.io/otel/attribute/filter.go
index 3eeaa5d442..624ebbe381 100644
--- a/vendor/go.opentelemetry.io/otel/attribute/filter.go
+++ b/vendor/go.opentelemetry.io/otel/attribute/filter.go
@@ -15,8 +15,8 @@ type Filter func(KeyValue) bool
//
// If keys is empty a deny-all filter is returned.
func NewAllowKeysFilter(keys ...Key) Filter {
- if len(keys) <= 0 {
- return func(kv KeyValue) bool { return false }
+ if len(keys) == 0 {
+ return func(KeyValue) bool { return false }
}
allowed := make(map[Key]struct{}, len(keys))
@@ -34,8 +34,8 @@ func NewAllowKeysFilter(keys ...Key) Filter {
//
// If keys is empty an allow-all filter is returned.
func NewDenyKeysFilter(keys ...Key) Filter {
- if len(keys) <= 0 {
- return func(kv KeyValue) bool { return true }
+ if len(keys) == 0 {
+ return func(KeyValue) bool { return true }
}
forbid := make(map[Key]struct{}, len(keys))
diff --git a/vendor/go.opentelemetry.io/otel/attribute/hash.go b/vendor/go.opentelemetry.io/otel/attribute/hash.go
new file mode 100644
index 0000000000..6aa69aeaec
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/attribute/hash.go
@@ -0,0 +1,92 @@
+// Copyright The OpenTelemetry Authors
+// SPDX-License-Identifier: Apache-2.0
+
+package attribute // import "go.opentelemetry.io/otel/attribute"
+
+import (
+ "fmt"
+ "reflect"
+
+ "go.opentelemetry.io/otel/attribute/internal/xxhash"
+)
+
+// Type identifiers. These identifiers are hashed before the value of the
+// corresponding type. This is done to distinguish values that are hashed with
+// the same value representation (e.g. `int64(1)` and `true`, []int64{0} and
+// int64(0)).
+//
+// These are all 8 byte length strings converted to a uint64 representation. A
+// uint64 is used instead of the string directly as an optimization, it avoids
+// the for loop in [xxhash] which adds minor overhead.
+const (
+ boolID uint64 = 7953749933313450591 // "_boolean" (little endian)
+ int64ID uint64 = 7592915492740740150 // "64_bit_i" (little endian)
+ float64ID uint64 = 7376742710626956342 // "64_bit_f" (little endian)
+ stringID uint64 = 6874584755375207263 // "_string_" (little endian)
+ boolSliceID uint64 = 6875993255270243167 // "_[]bool_" (little endian)
+ int64SliceID uint64 = 3762322556277578591 // "_[]int64" (little endian)
+ float64SliceID uint64 = 7308324551835016539 // "[]double" (little endian)
+ stringSliceID uint64 = 7453010373645655387 // "[]string" (little endian)
+)
+
+// hashKVs returns a new xxHash64 hash of kvs.
+func hashKVs(kvs []KeyValue) uint64 {
+ h := xxhash.New()
+ for _, kv := range kvs {
+ h = hashKV(h, kv)
+ }
+ return h.Sum64()
+}
+
+// hashKV returns the xxHash64 hash of kv with h as the base.
+func hashKV(h xxhash.Hash, kv KeyValue) xxhash.Hash {
+ h = h.String(string(kv.Key))
+
+ switch kv.Value.Type() {
+ case BOOL:
+ h = h.Uint64(boolID)
+ h = h.Uint64(kv.Value.numeric)
+ case INT64:
+ h = h.Uint64(int64ID)
+ h = h.Uint64(kv.Value.numeric)
+ case FLOAT64:
+ h = h.Uint64(float64ID)
+ // Assumes numeric stored with math.Float64bits.
+ h = h.Uint64(kv.Value.numeric)
+ case STRING:
+ h = h.Uint64(stringID)
+ h = h.String(kv.Value.stringly)
+ case BOOLSLICE:
+ h = h.Uint64(boolSliceID)
+ rv := reflect.ValueOf(kv.Value.slice)
+ for i := 0; i < rv.Len(); i++ {
+ h = h.Bool(rv.Index(i).Bool())
+ }
+ case INT64SLICE:
+ h = h.Uint64(int64SliceID)
+ rv := reflect.ValueOf(kv.Value.slice)
+ for i := 0; i < rv.Len(); i++ {
+ h = h.Int64(rv.Index(i).Int())
+ }
+ case FLOAT64SLICE:
+ h = h.Uint64(float64SliceID)
+ rv := reflect.ValueOf(kv.Value.slice)
+ for i := 0; i < rv.Len(); i++ {
+ h = h.Float64(rv.Index(i).Float())
+ }
+ case STRINGSLICE:
+ h = h.Uint64(stringSliceID)
+ rv := reflect.ValueOf(kv.Value.slice)
+ for i := 0; i < rv.Len(); i++ {
+ h = h.String(rv.Index(i).String())
+ }
+ case INVALID:
+ default:
+ // Logging is an alternative, but using the internal logger here
+ // causes an import cycle so it is not done.
+ v := kv.Value.AsInterface()
+ msg := fmt.Sprintf("unknown value type: %[1]v (%[1]T)", v)
+ panic(msg)
+ }
+ return h
+}
diff --git a/vendor/go.opentelemetry.io/otel/attribute/internal/attribute.go b/vendor/go.opentelemetry.io/otel/attribute/internal/attribute.go
index b76d2bbfdb..7f5eae877d 100644
--- a/vendor/go.opentelemetry.io/otel/attribute/internal/attribute.go
+++ b/vendor/go.opentelemetry.io/otel/attribute/internal/attribute.go
@@ -12,39 +12,35 @@ import (
)
// BoolSliceValue converts a bool slice into an array with same elements as slice.
-func BoolSliceValue(v []bool) interface{} {
- var zero bool
- cp := reflect.New(reflect.ArrayOf(len(v), reflect.TypeOf(zero))).Elem()
+func BoolSliceValue(v []bool) any {
+ cp := reflect.New(reflect.ArrayOf(len(v), reflect.TypeFor[bool]())).Elem()
reflect.Copy(cp, reflect.ValueOf(v))
return cp.Interface()
}
// Int64SliceValue converts an int64 slice into an array with same elements as slice.
-func Int64SliceValue(v []int64) interface{} {
- var zero int64
- cp := reflect.New(reflect.ArrayOf(len(v), reflect.TypeOf(zero))).Elem()
+func Int64SliceValue(v []int64) any {
+ cp := reflect.New(reflect.ArrayOf(len(v), reflect.TypeFor[int64]())).Elem()
reflect.Copy(cp, reflect.ValueOf(v))
return cp.Interface()
}
// Float64SliceValue converts a float64 slice into an array with same elements as slice.
-func Float64SliceValue(v []float64) interface{} {
- var zero float64
- cp := reflect.New(reflect.ArrayOf(len(v), reflect.TypeOf(zero))).Elem()
+func Float64SliceValue(v []float64) any {
+ cp := reflect.New(reflect.ArrayOf(len(v), reflect.TypeFor[float64]())).Elem()
reflect.Copy(cp, reflect.ValueOf(v))
return cp.Interface()
}
// StringSliceValue converts a string slice into an array with same elements as slice.
-func StringSliceValue(v []string) interface{} {
- var zero string
- cp := reflect.New(reflect.ArrayOf(len(v), reflect.TypeOf(zero))).Elem()
+func StringSliceValue(v []string) any {
+ cp := reflect.New(reflect.ArrayOf(len(v), reflect.TypeFor[string]())).Elem()
reflect.Copy(cp, reflect.ValueOf(v))
return cp.Interface()
}
// AsBoolSlice converts a bool array into a slice into with same elements as array.
-func AsBoolSlice(v interface{}) []bool {
+func AsBoolSlice(v any) []bool {
rv := reflect.ValueOf(v)
if rv.Type().Kind() != reflect.Array {
return nil
@@ -57,7 +53,7 @@ func AsBoolSlice(v interface{}) []bool {
}
// AsInt64Slice converts an int64 array into a slice into with same elements as array.
-func AsInt64Slice(v interface{}) []int64 {
+func AsInt64Slice(v any) []int64 {
rv := reflect.ValueOf(v)
if rv.Type().Kind() != reflect.Array {
return nil
@@ -70,7 +66,7 @@ func AsInt64Slice(v interface{}) []int64 {
}
// AsFloat64Slice converts a float64 array into a slice into with same elements as array.
-func AsFloat64Slice(v interface{}) []float64 {
+func AsFloat64Slice(v any) []float64 {
rv := reflect.ValueOf(v)
if rv.Type().Kind() != reflect.Array {
return nil
@@ -83,7 +79,7 @@ func AsFloat64Slice(v interface{}) []float64 {
}
// AsStringSlice converts a string array into a slice into with same elements as array.
-func AsStringSlice(v interface{}) []string {
+func AsStringSlice(v any) []string {
rv := reflect.ValueOf(v)
if rv.Type().Kind() != reflect.Array {
return nil
diff --git a/vendor/go.opentelemetry.io/otel/attribute/internal/xxhash/xxhash.go b/vendor/go.opentelemetry.io/otel/attribute/internal/xxhash/xxhash.go
new file mode 100644
index 0000000000..113a978383
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/attribute/internal/xxhash/xxhash.go
@@ -0,0 +1,64 @@
+// Copyright The OpenTelemetry Authors
+// SPDX-License-Identifier: Apache-2.0
+
+// Package xxhash provides a wrapper around the xxhash library for attribute hashing.
+package xxhash // import "go.opentelemetry.io/otel/attribute/internal/xxhash"
+
+import (
+ "encoding/binary"
+ "math"
+
+ "github.com/cespare/xxhash/v2"
+)
+
+// Hash wraps xxhash.Digest to provide an API friendly for hashing attribute values.
+type Hash struct {
+ d *xxhash.Digest
+}
+
+// New returns a new initialized xxHash64 hasher.
+func New() Hash {
+ return Hash{d: xxhash.New()}
+}
+
+func (h Hash) Uint64(val uint64) Hash {
+ var buf [8]byte
+ binary.LittleEndian.PutUint64(buf[:], val)
+ // errors from Write are always nil for xxhash
+ // if it returns an err then panic
+ _, err := h.d.Write(buf[:])
+ if err != nil {
+ panic("xxhash write of uint64 failed: " + err.Error())
+ }
+ return h
+}
+
+func (h Hash) Bool(val bool) Hash { // nolint:revive // This is a hashing function.
+ if val {
+ return h.Uint64(1)
+ }
+ return h.Uint64(0)
+}
+
+func (h Hash) Float64(val float64) Hash {
+ return h.Uint64(math.Float64bits(val))
+}
+
+func (h Hash) Int64(val int64) Hash {
+ return h.Uint64(uint64(val)) // nolint:gosec // Overflow doesn't matter since we are hashing.
+}
+
+func (h Hash) String(val string) Hash {
+ // errors from WriteString are always nil for xxhash
+ // if it returns an err then panic
+ _, err := h.d.WriteString(val)
+ if err != nil {
+ panic("xxhash write of string failed: " + err.Error())
+ }
+ return h
+}
+
+// Sum64 returns the current hash value.
+func (h Hash) Sum64() uint64 {
+ return h.d.Sum64()
+}
diff --git a/vendor/go.opentelemetry.io/otel/attribute/iterator.go b/vendor/go.opentelemetry.io/otel/attribute/iterator.go
index f2ba89ce4b..8df6249f02 100644
--- a/vendor/go.opentelemetry.io/otel/attribute/iterator.go
+++ b/vendor/go.opentelemetry.io/otel/attribute/iterator.go
@@ -25,8 +25,8 @@ type oneIterator struct {
attr KeyValue
}
-// Next moves the iterator to the next position. Returns false if there are no
-// more attributes.
+// Next moves the iterator to the next position.
+// Next reports whether there are more attributes.
func (i *Iterator) Next() bool {
i.idx++
return i.idx < i.Len()
@@ -106,7 +106,8 @@ func (oi *oneIterator) advance() {
}
}
-// Next returns true if there is another attribute available.
+// Next moves the iterator to the next position.
+// Next reports whether there is another attribute available.
func (m *MergeIterator) Next() bool {
if m.one.done && m.two.done {
return false
diff --git a/vendor/go.opentelemetry.io/otel/attribute/key.go b/vendor/go.opentelemetry.io/otel/attribute/key.go
index d9a22c6502..80a9e5643f 100644
--- a/vendor/go.opentelemetry.io/otel/attribute/key.go
+++ b/vendor/go.opentelemetry.io/otel/attribute/key.go
@@ -117,7 +117,7 @@ func (k Key) StringSlice(v []string) KeyValue {
}
}
-// Defined returns true for non-empty keys.
+// Defined reports whether the key is not empty.
func (k Key) Defined() bool {
return len(k) != 0
}
diff --git a/vendor/go.opentelemetry.io/otel/attribute/kv.go b/vendor/go.opentelemetry.io/otel/attribute/kv.go
index 3028f9a40f..8c6928ca79 100644
--- a/vendor/go.opentelemetry.io/otel/attribute/kv.go
+++ b/vendor/go.opentelemetry.io/otel/attribute/kv.go
@@ -13,7 +13,7 @@ type KeyValue struct {
Value Value
}
-// Valid returns if kv is a valid OpenTelemetry attribute.
+// Valid reports whether kv is a valid OpenTelemetry attribute.
func (kv KeyValue) Valid() bool {
return kv.Key.Defined() && kv.Value.Type() != INVALID
}
diff --git a/vendor/go.opentelemetry.io/otel/attribute/set.go b/vendor/go.opentelemetry.io/otel/attribute/set.go
index 6cbefceadf..6572c98b12 100644
--- a/vendor/go.opentelemetry.io/otel/attribute/set.go
+++ b/vendor/go.opentelemetry.io/otel/attribute/set.go
@@ -9,6 +9,8 @@ import (
"reflect"
"slices"
"sort"
+
+ "go.opentelemetry.io/otel/attribute/internal/xxhash"
)
type (
@@ -23,19 +25,19 @@ type (
// the Equals method to ensure stable equivalence checking.
//
// Users should also use the Distinct returned from Equivalent as a map key
- // instead of a Set directly. In addition to that type providing guarantees
- // on stable equivalence, it may also provide performance improvements.
+ // instead of a Set directly. Set has relatively poor performance when used
+ // as a map key compared to Distinct.
Set struct {
- equivalent Distinct
+ hash uint64
+ data any
}
- // Distinct is a unique identifier of a Set.
+ // Distinct is an identifier of a Set which is very likely to be unique.
//
- // Distinct is designed to be ensures equivalence stability: comparisons
- // will return the save value across versions. For this reason, Distinct
- // should always be used as a map key instead of a Set.
+ // Distinct should be used as a map key instead of a Set for to provide better
+ // performance for map operations.
Distinct struct {
- iface interface{}
+ hash uint64
}
// Sortable implements sort.Interface, used for sorting KeyValue.
@@ -46,15 +48,34 @@ type (
Sortable []KeyValue
)
+// Compile time check these types remain comparable.
+var (
+ _ = isComparable(Set{})
+ _ = isComparable(Distinct{})
+)
+
+func isComparable[T comparable](t T) T { return t }
+
var (
// keyValueType is used in computeDistinctReflect.
- keyValueType = reflect.TypeOf(KeyValue{})
+ keyValueType = reflect.TypeFor[KeyValue]()
+
+ // emptyHash is the hash of an empty set.
+ emptyHash = xxhash.New().Sum64()
- // emptySet is returned for empty attribute sets.
- emptySet = &Set{
- equivalent: Distinct{
- iface: [0]KeyValue{},
- },
+ // userDefinedEmptySet is an empty set. It was mistakenly exposed to users
+ // as something they can assign to, so it must remain addressable and
+ // mutable.
+ //
+ // This is kept for backwards compatibility, but should not be used in new code.
+ userDefinedEmptySet = &Set{
+ hash: emptyHash,
+ data: [0]KeyValue{},
+ }
+
+ emptySet = Set{
+ hash: emptyHash,
+ data: [0]KeyValue{},
}
)
@@ -62,33 +83,35 @@ var (
//
// This is a convenience provided for optimized calling utility.
func EmptySet() *Set {
- return emptySet
+ // Continue to return the pointer to the user-defined empty set for
+ // backwards-compatibility.
+ //
+ // New code should not use this, instead use emptySet.
+ return userDefinedEmptySet
}
-// reflectValue abbreviates reflect.ValueOf(d).
-func (d Distinct) reflectValue() reflect.Value {
- return reflect.ValueOf(d.iface)
-}
+// Valid reports whether this value refers to a valid Set.
+func (d Distinct) Valid() bool { return d.hash != 0 }
-// Valid returns true if this value refers to a valid Set.
-func (d Distinct) Valid() bool {
- return d.iface != nil
+// reflectValue abbreviates reflect.ValueOf(d).
+func (l Set) reflectValue() reflect.Value {
+ return reflect.ValueOf(l.data)
}
// Len returns the number of attributes in this set.
func (l *Set) Len() int {
- if l == nil || !l.equivalent.Valid() {
+ if l == nil || l.hash == 0 {
return 0
}
- return l.equivalent.reflectValue().Len()
+ return l.reflectValue().Len()
}
// Get returns the KeyValue at ordered position idx in this set.
func (l *Set) Get(idx int) (KeyValue, bool) {
- if l == nil || !l.equivalent.Valid() {
+ if l == nil || l.hash == 0 {
return KeyValue{}, false
}
- value := l.equivalent.reflectValue()
+ value := l.reflectValue()
if idx >= 0 && idx < value.Len() {
// Note: The Go compiler successfully avoids an allocation for
@@ -101,10 +124,10 @@ func (l *Set) Get(idx int) (KeyValue, bool) {
// Value returns the value of a specified key in this set.
func (l *Set) Value(k Key) (Value, bool) {
- if l == nil || !l.equivalent.Valid() {
+ if l == nil || l.hash == 0 {
return Value{}, false
}
- rValue := l.equivalent.reflectValue()
+ rValue := l.reflectValue()
vlen := rValue.Len()
idx := sort.Search(vlen, func(idx int) bool {
@@ -120,7 +143,7 @@ func (l *Set) Value(k Key) (Value, bool) {
return Value{}, false
}
-// HasValue tests whether a key is defined in this set.
+// HasValue reports whether a key is defined in this set.
func (l *Set) HasValue(k Key) bool {
if l == nil {
return false
@@ -144,20 +167,29 @@ func (l *Set) ToSlice() []KeyValue {
return iter.ToSlice()
}
-// Equivalent returns a value that may be used as a map key. The Distinct type
-// guarantees that the result will equal the equivalent. Distinct value of any
+// Equivalent returns a value that may be used as a map key. Equal Distinct
+// values are very likely to be equivalent attribute Sets. Distinct value of any
// attribute set with the same elements as this, where sets are made unique by
// choosing the last value in the input for any given key.
func (l *Set) Equivalent() Distinct {
- if l == nil || !l.equivalent.Valid() {
- return emptySet.equivalent
+ if l == nil || l.hash == 0 {
+ return Distinct{hash: emptySet.hash}
}
- return l.equivalent
+ return Distinct{hash: l.hash}
}
-// Equals returns true if the argument set is equivalent to this set.
+// Equals reports whether the argument set is equivalent to this set.
func (l *Set) Equals(o *Set) bool {
- return l.Equivalent() == o.Equivalent()
+ if l.Equivalent() != o.Equivalent() {
+ return false
+ }
+ if l == nil || l.hash == 0 {
+ l = &emptySet
+ }
+ if o == nil || o.hash == 0 {
+ o = &emptySet
+ }
+ return l.data == o.data
}
// Encoded returns the encoded form of this set, according to encoder.
@@ -169,12 +201,6 @@ func (l *Set) Encoded(encoder Encoder) string {
return encoder.Encode(l.Iter())
}
-func empty() Set {
- return Set{
- equivalent: emptySet.equivalent,
- }
-}
-
// NewSet returns a new Set. See the documentation for
// NewSetWithSortableFiltered for more details.
//
@@ -204,7 +230,7 @@ func NewSetWithSortable(kvs []KeyValue, _ *Sortable) Set {
func NewSetWithFiltered(kvs []KeyValue, filter Filter) (Set, []KeyValue) {
// Check for empty set.
if len(kvs) == 0 {
- return empty(), nil
+ return emptySet, nil
}
// Stable sort so the following de-duplication can implement
@@ -233,10 +259,10 @@ func NewSetWithFiltered(kvs []KeyValue, filter Filter) (Set, []KeyValue) {
if filter != nil {
if div := filteredToFront(kvs, filter); div != 0 {
- return Set{equivalent: computeDistinct(kvs[div:])}, kvs[:div]
+ return newSet(kvs[div:]), kvs[:div]
}
}
- return Set{equivalent: computeDistinct(kvs)}, nil
+ return newSet(kvs), nil
}
// NewSetWithSortableFiltered returns a new Set.
@@ -316,7 +342,7 @@ func (l *Set) Filter(re Filter) (Set, []KeyValue) {
if first == 0 {
// It is safe to assume len(slice) >= 1 given we found at least one
// attribute above that needs to be filtered out.
- return Set{equivalent: computeDistinct(slice[1:])}, slice[:1]
+ return newSet(slice[1:]), slice[:1]
}
// Move the filtered slice[first] to the front (preserving order).
@@ -326,25 +352,24 @@ func (l *Set) Filter(re Filter) (Set, []KeyValue) {
// Do not re-evaluate re(slice[first+1:]).
div := filteredToFront(slice[1:first+1], re) + 1
- return Set{equivalent: computeDistinct(slice[div:])}, slice[:div]
+ return newSet(slice[div:]), slice[:div]
}
-// computeDistinct returns a Distinct using either the fixed- or
-// reflect-oriented code path, depending on the size of the input. The input
-// slice is assumed to already be sorted and de-duplicated.
-func computeDistinct(kvs []KeyValue) Distinct {
- iface := computeDistinctFixed(kvs)
- if iface == nil {
- iface = computeDistinctReflect(kvs)
+// newSet returns a new set based on the sorted and uniqued kvs.
+func newSet(kvs []KeyValue) Set {
+ s := Set{
+ hash: hashKVs(kvs),
+ data: computeDataFixed(kvs),
}
- return Distinct{
- iface: iface,
+ if s.data == nil {
+ s.data = computeDataReflect(kvs)
}
+ return s
}
-// computeDistinctFixed computes a Distinct for small slices. It returns nil
-// if the input is too large for this code path.
-func computeDistinctFixed(kvs []KeyValue) interface{} {
+// computeDataFixed computes a Set data for small slices. It returns nil if the
+// input is too large for this code path.
+func computeDataFixed(kvs []KeyValue) any {
switch len(kvs) {
case 1:
return [1]KeyValue(kvs)
@@ -371,9 +396,9 @@ func computeDistinctFixed(kvs []KeyValue) interface{} {
}
}
-// computeDistinctReflect computes a Distinct using reflection, works for any
-// size input.
-func computeDistinctReflect(kvs []KeyValue) interface{} {
+// computeDataReflect computes a Set data using reflection, works for any size
+// input.
+func computeDataReflect(kvs []KeyValue) any {
at := reflect.New(reflect.ArrayOf(len(kvs), keyValueType)).Elem()
for i, keyValue := range kvs {
*(at.Index(i).Addr().Interface().(*KeyValue)) = keyValue
@@ -383,11 +408,11 @@ func computeDistinctReflect(kvs []KeyValue) interface{} {
// MarshalJSON returns the JSON encoding of the Set.
func (l *Set) MarshalJSON() ([]byte, error) {
- return json.Marshal(l.equivalent.iface)
+ return json.Marshal(l.data)
}
// MarshalLog is the marshaling function used by the logging system to represent this Set.
-func (l Set) MarshalLog() interface{} {
+func (l Set) MarshalLog() any {
kvs := make(map[string]string)
for _, kv := range l.ToSlice() {
kvs[string(kv.Key)] = kv.Value.Emit()
diff --git a/vendor/go.opentelemetry.io/otel/attribute/type_string.go b/vendor/go.opentelemetry.io/otel/attribute/type_string.go
index e584b24776..24f1fa37db 100644
--- a/vendor/go.opentelemetry.io/otel/attribute/type_string.go
+++ b/vendor/go.opentelemetry.io/otel/attribute/type_string.go
@@ -24,8 +24,9 @@ const _Type_name = "INVALIDBOOLINT64FLOAT64STRINGBOOLSLICEINT64SLICEFLOAT64SLICE
var _Type_index = [...]uint8{0, 7, 11, 16, 23, 29, 38, 48, 60, 71}
func (i Type) String() string {
- if i < 0 || i >= Type(len(_Type_index)-1) {
+ idx := int(i) - 0
+ if i < 0 || idx >= len(_Type_index)-1 {
return "Type(" + strconv.FormatInt(int64(i), 10) + ")"
}
- return _Type_name[_Type_index[i]:_Type_index[i+1]]
+ return _Type_name[_Type_index[idx]:_Type_index[idx+1]]
}
diff --git a/vendor/go.opentelemetry.io/otel/attribute/value.go b/vendor/go.opentelemetry.io/otel/attribute/value.go
index 817eecacf1..5931e71291 100644
--- a/vendor/go.opentelemetry.io/otel/attribute/value.go
+++ b/vendor/go.opentelemetry.io/otel/attribute/value.go
@@ -22,7 +22,7 @@ type Value struct {
vtype Type
numeric uint64
stringly string
- slice interface{}
+ slice any
}
const (
@@ -66,8 +66,7 @@ func IntValue(v int) Value {
// IntSliceValue creates an INTSLICE Value.
func IntSliceValue(v []int) Value {
- var int64Val int64
- cp := reflect.New(reflect.ArrayOf(len(v), reflect.TypeOf(int64Val)))
+ cp := reflect.New(reflect.ArrayOf(len(v), reflect.TypeFor[int64]()))
for i, val := range v {
cp.Elem().Index(i).SetInt(int64(val))
}
@@ -199,8 +198,8 @@ func (v Value) asStringSlice() []string {
type unknownValueType struct{}
-// AsInterface returns Value's data as interface{}.
-func (v Value) AsInterface() interface{} {
+// AsInterface returns Value's data as any.
+func (v Value) AsInterface() any {
switch v.Type() {
case BOOL:
return v.AsBool()
@@ -262,7 +261,7 @@ func (v Value) Emit() string {
func (v Value) MarshalJSON() ([]byte, error) {
var jsonVal struct {
Type string
- Value interface{}
+ Value any
}
jsonVal.Type = v.Type().String()
jsonVal.Value = v.AsInterface()
diff --git a/vendor/go.opentelemetry.io/otel/baggage/baggage.go b/vendor/go.opentelemetry.io/otel/baggage/baggage.go
index 0e1fe24220..878ffbe43a 100644
--- a/vendor/go.opentelemetry.io/otel/baggage/baggage.go
+++ b/vendor/go.opentelemetry.io/otel/baggage/baggage.go
@@ -14,8 +14,7 @@ import (
)
const (
- maxMembers = 180
- maxBytesPerMembers = 4096
+ maxMembers = 64
maxBytesPerBaggageString = 8192
listDelimiter = ","
@@ -29,7 +28,6 @@ var (
errInvalidProperty = errors.New("invalid baggage list-member property")
errInvalidMember = errors.New("invalid baggage list-member")
errMemberNumber = errors.New("too many list-members in baggage-string")
- errMemberBytes = errors.New("list-member too large")
errBaggageBytes = errors.New("baggage-string too large")
)
@@ -309,15 +307,11 @@ func newInvalidMember() Member {
// an error if the input is invalid according to the W3C Baggage
// specification.
func parseMember(member string) (Member, error) {
- if n := len(member); n > maxBytesPerMembers {
- return newInvalidMember(), fmt.Errorf("%w: %d", errMemberBytes, n)
- }
-
var props properties
keyValue, properties, found := strings.Cut(member, propertyDelimiter)
if found {
// Parse the member properties.
- for _, pStr := range strings.Split(properties, propertyDelimiter) {
+ for pStr := range strings.SplitSeq(properties, propertyDelimiter) {
p, err := parseProperty(pStr)
if err != nil {
return newInvalidMember(), err
@@ -430,6 +424,10 @@ type Baggage struct { //nolint:golint
// New returns a new valid Baggage. It returns an error if it results in a
// Baggage exceeding limits set in that specification.
//
+// If the resulting Baggage exceeds the maximum allowed members or bytes,
+// members are dropped until the limits are satisfied and an error is returned
+// along with the partial result.
+//
// It expects all the provided members to have already been validated.
func New(members ...Member) (Baggage, error) {
if len(members) == 0 {
@@ -441,7 +439,6 @@ func New(members ...Member) (Baggage, error) {
if !m.hasData {
return Baggage{}, errInvalidMember
}
-
// OpenTelemetry resolves duplicates by last-one-wins.
b[m.key] = baggage.Item{
Value: m.value,
@@ -449,17 +446,42 @@ func New(members ...Member) (Baggage, error) {
}
}
- // Check member numbers after deduplication.
+ var truncateErr error
+
+ // Check member count after deduplication.
if len(b) > maxMembers {
- return Baggage{}, errMemberNumber
+ truncateErr = errors.Join(truncateErr, errMemberNumber)
+ for k := range b {
+ if len(b) <= maxMembers {
+ break
+ }
+ delete(b, k)
+ }
}
- bag := Baggage{b}
- if n := len(bag.String()); n > maxBytesPerBaggageString {
- return Baggage{}, fmt.Errorf("%w: %d", errBaggageBytes, n)
+ // Check byte size and drop members if necessary.
+ totalBytes := 0
+ first := true
+ for k := range b {
+ m := Member{
+ key: k,
+ value: b[k].Value,
+ properties: fromInternalProperties(b[k].Properties),
+ }
+ memberSize := len(m.String())
+ if !first {
+ memberSize++ // comma separator
+ }
+ if totalBytes+memberSize > maxBytesPerBaggageString {
+ truncateErr = errors.Join(truncateErr, fmt.Errorf("%w: %d", errBaggageBytes, totalBytes+memberSize))
+ delete(b, k)
+ continue
+ }
+ totalBytes += memberSize
+ first = false
}
- return bag, nil
+ return Baggage{b}, truncateErr
}
// Parse attempts to decode a baggage-string from the passed string. It
@@ -470,36 +492,71 @@ func New(members ...Member) (Baggage, error) {
// defined (reading left-to-right) will be the only one kept. This diverges
// from the W3C Baggage specification which allows duplicate list-members, but
// conforms to the OpenTelemetry Baggage specification.
+//
+// If the baggage-string exceeds the maximum allowed members (64) or bytes
+// (8192), members are dropped until the limits are satisfied and an error is
+// returned along with the partial result.
+//
+// Invalid members are skipped and the error is returned along with the
+// partial result containing the valid members.
func Parse(bStr string) (Baggage, error) {
if bStr == "" {
return Baggage{}, nil
}
- if n := len(bStr); n > maxBytesPerBaggageString {
- return Baggage{}, fmt.Errorf("%w: %d", errBaggageBytes, n)
- }
-
b := make(baggage.List)
- for _, memberStr := range strings.Split(bStr, listDelimiter) {
+ sizes := make(map[string]int) // Track per-key byte sizes
+ var totalBytes int
+ var truncateErr error
+ for memberStr := range strings.SplitSeq(bStr, listDelimiter) {
+ // Check member count limit.
+ if len(b) >= maxMembers {
+ truncateErr = errors.Join(truncateErr, errMemberNumber)
+ break
+ }
+
m, err := parseMember(memberStr)
if err != nil {
- return Baggage{}, err
+ truncateErr = errors.Join(truncateErr, err)
+ continue // skip invalid member, keep processing
}
+
+ // Check byte size limit.
+ // Account for comma separator between members.
+ memberBytes := len(m.String())
+ _, existingKey := b[m.key]
+ if !existingKey && len(b) > 0 {
+ memberBytes++ // comma separator only for new keys
+ }
+
+ // Calculate new totalBytes if we add/overwrite this key
+ var newTotalBytes int
+ if oldSize, exists := sizes[m.key]; exists {
+ // Overwriting existing key: subtract old size, add new size
+ newTotalBytes = totalBytes - oldSize + memberBytes
+ } else {
+ // New key
+ newTotalBytes = totalBytes + memberBytes
+ }
+
+ if newTotalBytes > maxBytesPerBaggageString {
+ truncateErr = errors.Join(truncateErr, errBaggageBytes)
+ break
+ }
+
// OpenTelemetry resolves duplicates by last-one-wins.
b[m.key] = baggage.Item{
Value: m.value,
Properties: m.properties.asInternal(),
}
+ sizes[m.key] = memberBytes
+ totalBytes = newTotalBytes
}
- // OpenTelemetry does not allow for duplicate list-members, but the W3C
- // specification does. Now that we have deduplicated, ensure the baggage
- // does not exceed list-member limits.
- if len(b) > maxMembers {
- return Baggage{}, errMemberNumber
+ if len(b) == 0 {
+ return Baggage{}, truncateErr
}
-
- return Baggage{b}, nil
+ return Baggage{b}, truncateErr
}
// Member returns the baggage list-member identified by key.
@@ -648,7 +705,7 @@ func parsePropertyInternal(s string) (p Property, ok bool) {
// If we couldn't find any valid key character,
// it means the key is either empty or invalid.
if keyStart == keyEnd {
- return
+ return p, ok
}
// Skip spaces after the key: " key< >= value ".
@@ -658,13 +715,13 @@ func parsePropertyInternal(s string) (p Property, ok bool) {
// A key can have no value, like: " key ".
ok = true
p.key = s[keyStart:keyEnd]
- return
+ return p, ok
}
// If we have not reached the end and we can't find the '=' delimiter,
// it means the property is invalid.
if s[index] != keyValueDelimiter[0] {
- return
+ return p, ok
}
// Attempting to parse the value.
@@ -690,14 +747,14 @@ func parsePropertyInternal(s string) (p Property, ok bool) {
// we have not reached the end, it means the property is
// invalid, something like: " key = value value1".
if index != len(s) {
- return
+ return p, ok
}
// Decode a percent-encoded value.
rawVal := s[valueStart:valueEnd]
unescapeVal, err := url.PathUnescape(rawVal)
if err != nil {
- return
+ return p, ok
}
value := replaceInvalidUTF8Sequences(len(rawVal), unescapeVal)
@@ -706,7 +763,7 @@ func parsePropertyInternal(s string) (p Property, ok bool) {
p.hasValue = true
p.value = value
- return
+ return p, ok
}
func skipSpace(s string, offset int) int {
@@ -812,7 +869,7 @@ var safeKeyCharset = [utf8.RuneSelf]bool{
// validateBaggageName checks if the string is a valid OpenTelemetry Baggage name.
// Baggage name is a valid, non-empty UTF-8 string.
func validateBaggageName(s string) bool {
- if len(s) == 0 {
+ if s == "" {
return false
}
@@ -828,7 +885,7 @@ func validateBaggageValue(s string) bool {
// validateKey checks if the string is a valid W3C Baggage key.
func validateKey(s string) bool {
- if len(s) == 0 {
+ if s == "" {
return false
}
diff --git a/vendor/go.opentelemetry.io/otel/codes/codes.go b/vendor/go.opentelemetry.io/otel/codes/codes.go
index 49a35b1225..d48847ed86 100644
--- a/vendor/go.opentelemetry.io/otel/codes/codes.go
+++ b/vendor/go.opentelemetry.io/otel/codes/codes.go
@@ -67,7 +67,7 @@ func (c *Code) UnmarshalJSON(b []byte) error {
return errors.New("nil receiver passed to UnmarshalJSON")
}
- var x interface{}
+ var x any
if err := json.Unmarshal(b, &x); err != nil {
return err
}
@@ -102,5 +102,5 @@ func (c *Code) MarshalJSON() ([]byte, error) {
if !ok {
return nil, fmt.Errorf("invalid code: %d", *c)
}
- return []byte(fmt.Sprintf("%q", str)), nil
+ return fmt.Appendf(nil, "%q", str), nil
}
diff --git a/vendor/go.opentelemetry.io/otel/dependencies.Dockerfile b/vendor/go.opentelemetry.io/otel/dependencies.Dockerfile
index 51fb76b30d..f0cc942bae 100644
--- a/vendor/go.opentelemetry.io/otel/dependencies.Dockerfile
+++ b/vendor/go.opentelemetry.io/otel/dependencies.Dockerfile
@@ -1,4 +1,4 @@
# This is a renovate-friendly source of Docker images.
-FROM python:3.13.3-slim-bullseye@sha256:9e3f9243e06fd68eb9519074b49878eda20ad39a855fac51aaffb741de20726e AS python
-FROM otel/weaver:v0.15.0@sha256:1cf1c72eaed57dad813c2e359133b8a15bd4facf305aae5b13bdca6d3eccff56 AS weaver
+FROM python:3.13.6-slim-bullseye@sha256:e98b521460ee75bca92175c16247bdf7275637a8faaeb2bcfa19d879ae5c4b9a AS python
+FROM otel/weaver:v0.21.2@sha256:2401de985c38bdb98b43918e2f43aa36b2afed4aa5669ac1c1de0a17301cd36d AS weaver
FROM avtodev/markdown-lint:v1@sha256:6aeedc2f49138ce7a1cd0adffc1b1c0321b841dc2102408967d9301c031949ee AS markdown
diff --git a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/LICENSE b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/LICENSE
index 261eeb9e9f..f1aee0f110 100644
--- a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/LICENSE
+++ b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/LICENSE
@@ -199,3 +199,33 @@
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
+
+--------------------------------------------------------------------------------
+
+Copyright 2009 The Go Authors.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are
+met:
+
+ * Redistributions of source code must retain the above copyright
+notice, this list of conditions and the following disclaimer.
+ * Redistributions in binary form must reproduce the above
+copyright notice, this list of conditions and the following disclaimer
+in the documentation and/or other materials provided with the
+distribution.
+ * Neither the name of Google LLC nor the names of its
+contributors may be used to endorse or promote products derived from
+this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
\ No newline at end of file
diff --git a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/exporter.go b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/exporter.go
index 3f0a518ae0..30446bd28b 100644
--- a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/exporter.go
+++ b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/exporter.go
@@ -94,7 +94,7 @@ func NewUnstarted(client Client) *Exporter {
}
// MarshalLog is the marshaling function used by the logging system to represent this Exporter.
-func (e *Exporter) MarshalLog() interface{} {
+func (e *Exporter) MarshalLog() any {
return struct {
Type string
Client Client
diff --git a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/internal/tracetransform/attribute.go b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/internal/tracetransform/attribute.go
index 4571a5ca39..d9bfd6e176 100644
--- a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/internal/tracetransform/attribute.go
+++ b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/internal/tracetransform/attribute.go
@@ -1,12 +1,15 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0
+// Package tracetransform provides conversion functionality for the otlptrace
+// exporters.
package tracetransform // import "go.opentelemetry.io/otel/exporters/otlp/otlptrace/internal/tracetransform"
import (
+ commonpb "go.opentelemetry.io/proto/otlp/common/v1"
+
"go.opentelemetry.io/otel/attribute"
"go.opentelemetry.io/otel/sdk/resource"
- commonpb "go.opentelemetry.io/proto/otlp/common/v1"
)
// KeyValues transforms a slice of attribute KeyValues into OTLP key-values.
diff --git a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/internal/tracetransform/instrumentation.go b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/internal/tracetransform/instrumentation.go
index 2e7690e43a..43359c8944 100644
--- a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/internal/tracetransform/instrumentation.go
+++ b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/internal/tracetransform/instrumentation.go
@@ -4,8 +4,9 @@
package tracetransform // import "go.opentelemetry.io/otel/exporters/otlp/otlptrace/internal/tracetransform"
import (
- "go.opentelemetry.io/otel/sdk/instrumentation"
commonpb "go.opentelemetry.io/proto/otlp/common/v1"
+
+ "go.opentelemetry.io/otel/sdk/instrumentation"
)
func InstrumentationScope(il instrumentation.Scope) *commonpb.InstrumentationScope {
diff --git a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/internal/tracetransform/resource.go b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/internal/tracetransform/resource.go
index db7b698a56..526bb5e070 100644
--- a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/internal/tracetransform/resource.go
+++ b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/internal/tracetransform/resource.go
@@ -4,8 +4,9 @@
package tracetransform // import "go.opentelemetry.io/otel/exporters/otlp/otlptrace/internal/tracetransform"
import (
- "go.opentelemetry.io/otel/sdk/resource"
resourcepb "go.opentelemetry.io/proto/otlp/resource/v1"
+
+ "go.opentelemetry.io/otel/sdk/resource"
)
// Resource transforms a Resource into an OTLP Resource.
diff --git a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/internal/tracetransform/span.go b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/internal/tracetransform/span.go
index bf27ef0220..d431fc4517 100644
--- a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/internal/tracetransform/span.go
+++ b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/internal/tracetransform/span.go
@@ -6,12 +6,13 @@ package tracetransform // import "go.opentelemetry.io/otel/exporters/otlp/otlptr
import (
"math"
+ tracepb "go.opentelemetry.io/proto/otlp/trace/v1"
+
"go.opentelemetry.io/otel/attribute"
"go.opentelemetry.io/otel/codes"
"go.opentelemetry.io/otel/sdk/instrumentation"
tracesdk "go.opentelemetry.io/otel/sdk/trace"
"go.opentelemetry.io/otel/trace"
- tracepb "go.opentelemetry.io/proto/otlp/trace/v1"
)
// Spans transforms a slice of OpenTelemetry spans into a slice of OTLP
@@ -112,7 +113,7 @@ func span(sd tracesdk.ReadOnlySpan) *tracepb.Span {
if psid := sd.Parent().SpanID(); psid.IsValid() {
s.ParentSpanId = psid[:]
}
- s.Flags = buildSpanFlags(sd.Parent())
+ s.Flags = buildSpanFlagsWith(sd.SpanContext().TraceFlags(), sd.Parent())
return s
}
@@ -154,12 +155,11 @@ func links(links []tracesdk.Link) []*tracepb.Span_Link {
for _, otLink := range links {
// This redefinition is necessary to prevent otLink.*ID[:] copies
// being reused -- in short we need a new otLink per iteration.
- otLink := otLink
tid := otLink.SpanContext.TraceID()
sid := otLink.SpanContext.SpanID()
- flags := buildSpanFlags(otLink.SpanContext)
+ flags := buildSpanFlagsWith(otLink.SpanContext.TraceFlags(), otLink.SpanContext)
sl = append(sl, &tracepb.Span_Link{
TraceId: tid[:],
@@ -172,13 +172,15 @@ func links(links []tracesdk.Link) []*tracepb.Span_Link {
return sl
}
-func buildSpanFlags(sc trace.SpanContext) uint32 {
- flags := tracepb.SpanFlags_SPAN_FLAGS_CONTEXT_HAS_IS_REMOTE_MASK
- if sc.IsRemote() {
- flags |= tracepb.SpanFlags_SPAN_FLAGS_CONTEXT_IS_REMOTE_MASK
+func buildSpanFlagsWith(tf trace.TraceFlags, parent trace.SpanContext) uint32 {
+ // Lower 8 bits are the W3C TraceFlags; always indicate that we know whether the parent is remote
+ flags := uint32(tf) | uint32(tracepb.SpanFlags_SPAN_FLAGS_CONTEXT_HAS_IS_REMOTE_MASK)
+ // Set the parent-is-remote bit when applicable
+ if parent.IsRemote() {
+ flags |= uint32(tracepb.SpanFlags_SPAN_FLAGS_CONTEXT_IS_REMOTE_MASK)
}
- return uint32(flags) // nolint:gosec // Flags is a bitmask and can't be negative
+ return flags // nolint:gosec // Flags is a bitmask and can't be negative
}
// spanEvents transforms span Events to an OTLP span events.
@@ -189,7 +191,7 @@ func spanEvents(es []tracesdk.Event) []*tracepb.Span_Event {
events := make([]*tracepb.Span_Event, len(es))
// Transform message events
- for i := 0; i < len(es); i++ {
+ for i := range es {
events[i] = &tracepb.Span_Event{
Name: es[i].Name,
TimeUnixNano: uint64(max(0, es[i].Time.UnixNano())), // nolint:gosec // Overflow checked.
diff --git a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/LICENSE b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/LICENSE
index 261eeb9e9f..f1aee0f110 100644
--- a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/LICENSE
+++ b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/LICENSE
@@ -199,3 +199,33 @@
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
+
+--------------------------------------------------------------------------------
+
+Copyright 2009 The Go Authors.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are
+met:
+
+ * Redistributions of source code must retain the above copyright
+notice, this list of conditions and the following disclaimer.
+ * Redistributions in binary form must reproduce the above
+copyright notice, this list of conditions and the following disclaimer
+in the documentation and/or other materials provided with the
+distribution.
+ * Neither the name of Google LLC nor the names of its
+contributors may be used to endorse or promote products derived from
+this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
\ No newline at end of file
diff --git a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/client.go b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/client.go
index 8409b5f8f9..76b7cd461b 100644
--- a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/client.go
+++ b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/client.go
@@ -9,19 +9,20 @@ import (
"sync"
"time"
+ coltracepb "go.opentelemetry.io/proto/otlp/collector/trace/v1"
+ tracepb "go.opentelemetry.io/proto/otlp/trace/v1"
"google.golang.org/genproto/googleapis/rpc/errdetails"
"google.golang.org/grpc"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/metadata"
"google.golang.org/grpc/status"
- "go.opentelemetry.io/otel"
"go.opentelemetry.io/otel/exporters/otlp/otlptrace"
"go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal"
+ "go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/counter"
+ "go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/observ"
"go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/otlpconfig"
"go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/retry"
- coltracepb "go.opentelemetry.io/proto/otlp/collector/trace/v1"
- tracepb "go.opentelemetry.io/proto/otlp/trace/v1"
)
type client struct {
@@ -45,6 +46,9 @@ type client struct {
conn *grpc.ClientConn
tscMu sync.RWMutex
tsc coltracepb.TraceServiceClient
+
+ instID int64
+ inst *observ.Instrumentation
}
// Compile time check *client implements otlptrace.Client.
@@ -68,6 +72,7 @@ func newClient(opts ...Option) *client {
stopCtx: ctx,
stopFunc: cancel,
conn: cfg.GRPCConn,
+ instID: counter.NextExporterID(),
}
if len(cfg.Traces.Headers) > 0 {
@@ -92,13 +97,24 @@ func (c *client) Start(context.Context) error {
c.conn = conn
}
+ // Initialize the instrumentation if not already done.
+ //
+ // Initialize here instead of NewClient to allow any errors to be passed
+ // back to the caller and so that any setup of the environment variables to
+ // enable instrumentation can be set via code.
+ var err error
+ if c.inst == nil {
+ target := c.conn.CanonicalTarget()
+ c.inst, err = observ.NewInstrumentation(c.instID, target)
+ }
+
// The otlptrace.Client interface states this method is called just once,
// so no need to check if already started.
c.tscMu.Lock()
c.tsc = coltracepb.NewTraceServiceClient(c.conn)
c.tscMu.Unlock()
- return nil
+ return err
}
var errAlreadyStopped = errors.New("the client is already stopped")
@@ -174,7 +190,7 @@ var errShutdown = errors.New("the client is shutdown")
//
// Retryable errors from the server will be handled according to any
// RetryConfig the client was created with.
-func (c *client) UploadTraces(ctx context.Context, protoSpans []*tracepb.ResourceSpans) error {
+func (c *client) UploadTraces(ctx context.Context, protoSpans []*tracepb.ResourceSpans) (uploadErr error) {
// Hold a read lock to ensure a shut down initiated after this starts does
// not abandon the export. This read lock acquire has less priority than a
// write lock acquire (i.e. Stop), meaning if the client is shutting down
@@ -189,6 +205,12 @@ func (c *client) UploadTraces(ctx context.Context, protoSpans []*tracepb.Resourc
ctx, cancel := c.exportContext(ctx)
defer cancel()
+ var code codes.Code
+ if c.inst != nil {
+ op := c.inst.ExportSpans(ctx, len(protoSpans))
+ defer func() { op.End(uploadErr, code) }()
+ }
+
return c.requestFunc(ctx, func(iCtx context.Context) error {
resp, err := c.tsc.Export(iCtx, &coltracepb.ExportTraceServiceRequest{
ResourceSpans: protoSpans,
@@ -197,16 +219,17 @@ func (c *client) UploadTraces(ctx context.Context, protoSpans []*tracepb.Resourc
msg := resp.PartialSuccess.GetErrorMessage()
n := resp.PartialSuccess.GetRejectedSpans()
if n != 0 || msg != "" {
- err := internal.TracePartialSuccessError(n, msg)
- otel.Handle(err)
+ e := internal.TracePartialSuccessError(n, msg)
+ uploadErr = errors.Join(uploadErr, e)
}
}
// nil is converted to OK.
- if status.Code(err) == codes.OK {
+ code = status.Code(err)
+ if code == codes.OK {
// Success.
- return nil
+ return uploadErr
}
- return err
+ return errors.Join(uploadErr, err)
})
}
@@ -223,7 +246,7 @@ func (c *client) exportContext(parent context.Context) (context.Context, context
)
if c.exportTimeout > 0 {
- ctx, cancel = context.WithTimeout(parent, c.exportTimeout)
+ ctx, cancel = context.WithTimeoutCause(parent, c.exportTimeout, errors.New("exporter export timeout"))
} else {
ctx, cancel = context.WithCancel(parent)
}
@@ -289,7 +312,7 @@ func throttleDelay(s *status.Status) (bool, time.Duration) {
}
// MarshalLog is the marshaling function used by the logging system to represent this Client.
-func (c *client) MarshalLog() interface{} {
+func (c *client) MarshalLog() any {
return struct {
Type string
Endpoint string
diff --git a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/counter/counter.go b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/counter/counter.go
new file mode 100644
index 0000000000..323b2a2c9a
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/counter/counter.go
@@ -0,0 +1,31 @@
+// Code generated by gotmpl. DO NOT MODIFY.
+// source: internal/shared/counter/counter.go.tmpl
+
+// Copyright The OpenTelemetry Authors
+// SPDX-License-Identifier: Apache-2.0
+
+// Package counter provides a simple counter for generating unique IDs.
+//
+// This package is used to generate unique IDs while allowing testing packages
+// to reset the counter.
+package counter // import "go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/counter"
+
+import "sync/atomic"
+
+// exporterN is a global 0-based count of the number of exporters created.
+var exporterN atomic.Int64
+
+// NextExporterID returns the next unique ID for an exporter.
+func NextExporterID() int64 {
+ const inc = 1
+ return exporterN.Add(inc) - inc
+}
+
+// SetExporterID sets the exporter ID counter to v and returns the previous
+// value.
+//
+// This function is useful for testing purposes, allowing you to reset the
+// counter. It should not be used in production code.
+func SetExporterID(v int64) int64 {
+ return exporterN.Swap(v)
+}
diff --git a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/envconfig/envconfig.go b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/envconfig/envconfig.go
index 4abf48d1f6..6eacdf311d 100644
--- a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/envconfig/envconfig.go
+++ b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/envconfig/envconfig.go
@@ -1,9 +1,11 @@
-// Code created by gotmpl. DO NOT MODIFY.
+// Code generated by gotmpl. DO NOT MODIFY.
// source: internal/shared/otlp/envconfig/envconfig.go.tmpl
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0
+// Package envconfig provides functionality to parse configuration from
+// environment variables.
package envconfig // import "go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/envconfig"
import (
diff --git a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/gen.go b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/gen.go
index 97cd6c54f7..7fe9c9f3a3 100644
--- a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/gen.go
+++ b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/gen.go
@@ -1,6 +1,7 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0
+// Package internal provides internal functionally for the otlptracegrpc package.
package internal // import "go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal"
//go:generate gotmpl --body=../../../../../internal/shared/otlp/partialsuccess.go.tmpl "--data={}" --out=partialsuccess.go
@@ -22,3 +23,12 @@ package internal // import "go.opentelemetry.io/otel/exporters/otlp/otlptrace/ot
//go:generate gotmpl --body=../../../../../internal/shared/otlp/otlptrace/otlptracetest/collector.go.tmpl "--data={}" --out=otlptracetest/collector.go
//go:generate gotmpl --body=../../../../../internal/shared/otlp/otlptrace/otlptracetest/data.go.tmpl "--data={}" --out=otlptracetest/data.go
//go:generate gotmpl --body=../../../../../internal/shared/otlp/otlptrace/otlptracetest/otlptest.go.tmpl "--data={}" --out=otlptracetest/otlptest.go
+
+//go:generate gotmpl --body=../../../../../internal/shared/x/x.go.tmpl "--data={ \"pkg\": \"go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc\" }" --out=x/x.go
+//go:generate gotmpl --body=../../../../../internal/shared/x/x_test.go.tmpl "--data={}" --out=x/x_test.go
+
+//go:generate gotmpl --body=../../../../../internal/shared/otlp/observ/target.go.tmpl "--data={ \"pkg\": \"observ\", \"pkg_path\": \"go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/observ\" }" --out=observ/target.go
+//go:generate gotmpl --body=../../../../../internal/shared/otlp/observ/target_test.go.tmpl "--data={ \"pkg\": \"observ\" }" --out=observ/target_test.go
+
+//go:generate gotmpl --body=../../../../../internal/shared/counter/counter.go.tmpl "--data={ \"pkg\": \"go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/counter\" }" --out=counter/counter.go
+//go:generate gotmpl --body=../../../../../internal/shared/counter/counter_test.go.tmpl "--data={}" --out=counter/counter_test.go
diff --git a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/observ/doc.go b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/observ/doc.go
new file mode 100644
index 0000000000..0dd54e4b96
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/observ/doc.go
@@ -0,0 +1,6 @@
+// Copyright The OpenTelemetry Authors
+// SPDX-License-Identifier: Apache-2.0
+
+// Package observ provides experimental observability instrumentation for the
+// otlptracegrpc exporter.
+package observ // import "go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/observ"
diff --git a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/observ/instrumentation.go b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/observ/instrumentation.go
new file mode 100644
index 0000000000..d4a69f4d7c
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/observ/instrumentation.go
@@ -0,0 +1,342 @@
+// Copyright The OpenTelemetry Authors
+// SPDX-License-Identifier: Apache-2.0
+
+package observ // import "go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/observ"
+
+import (
+ "context"
+ "errors"
+ "fmt"
+ "sync"
+ "time"
+
+ "google.golang.org/grpc/codes"
+
+ "go.opentelemetry.io/otel"
+ "go.opentelemetry.io/otel/attribute"
+ "go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal"
+ "go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/x"
+ "go.opentelemetry.io/otel/internal/global"
+ "go.opentelemetry.io/otel/metric"
+ semconv "go.opentelemetry.io/otel/semconv/v1.39.0"
+ "go.opentelemetry.io/otel/semconv/v1.39.0/otelconv"
+)
+
+const (
+ // ScopeName is the unique name of the meter used for instrumentation.
+ ScopeName = "go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/observ"
+
+ // SchemaURL is the schema URL of the metrics produced by this
+ // instrumentation.
+ SchemaURL = semconv.SchemaURL
+
+ // Version is the current version of this instrumentation.
+ //
+ // This matches the version of the exporter.
+ Version = internal.Version
+)
+
+var (
+ measureAttrsPool = &sync.Pool{
+ New: func() any {
+ const n = 1 + // component.name
+ 1 + // component.type
+ 1 + // server.addr
+ 1 + // server.port
+ 1 + // error.type
+ 1 // rpc.grpc.status_code
+ s := make([]attribute.KeyValue, 0, n)
+ // Return a pointer to a slice instead of a slice itself
+ // to avoid allocations on every call.
+ return &s
+ },
+ }
+
+ addOptPool = &sync.Pool{
+ New: func() any {
+ const n = 1 // WithAttributeSet
+ o := make([]metric.AddOption, 0, n)
+ return &o
+ },
+ }
+
+ recordOptPool = &sync.Pool{
+ New: func() any {
+ const n = 1 // WithAttributeSet
+ o := make([]metric.RecordOption, 0, n)
+ return &o
+ },
+ }
+)
+
+func get[T any](p *sync.Pool) *[]T { return p.Get().(*[]T) }
+
+func put[T any](p *sync.Pool, s *[]T) {
+ *s = (*s)[:0] // Reset.
+ p.Put(s)
+}
+
+// ComponentName returns the component name for the exporter with the
+// provided ID.
+func ComponentName(id int64) string {
+ t := semconv.OTelComponentTypeOtlpGRPCSpanExporter.Value.AsString()
+ return fmt.Sprintf("%s/%d", t, id)
+}
+
+// Instrumentation is experimental instrumentation for the exporter.
+type Instrumentation struct {
+ inflightSpans metric.Int64UpDownCounter
+ exportedSpans metric.Int64Counter
+ opDuration metric.Float64Histogram
+
+ attrs []attribute.KeyValue
+ addOpt metric.AddOption
+ recOpt metric.RecordOption
+}
+
+// NewInstrumentation returns instrumentation for an OTLP over gPRC trace
+// exporter with the provided ID using the global MeterProvider.
+//
+// The id should be the unique exporter instance ID. It is used
+// to set the "component.name" attribute.
+//
+// The target is the endpoint the exporter is exporting to.
+//
+// If the experimental observability is disabled, nil is returned.
+func NewInstrumentation(id int64, target string) (*Instrumentation, error) {
+ if !x.Observability.Enabled() {
+ return nil, nil
+ }
+
+ attrs := BaseAttrs(id, target)
+ i := &Instrumentation{
+ attrs: attrs,
+ addOpt: metric.WithAttributeSet(attribute.NewSet(attrs...)),
+
+ // Do not modify attrs (NewSet sorts in-place), make a new slice.
+ recOpt: metric.WithAttributeSet(attribute.NewSet(append(
+ // Default to OK status code.
+ []attribute.KeyValue{
+ semconv.RPCResponseStatusCode(codes.OK.String()),
+ },
+ attrs...,
+ )...)),
+ }
+
+ mp := otel.GetMeterProvider()
+ m := mp.Meter(
+ ScopeName,
+ metric.WithInstrumentationVersion(Version),
+ metric.WithSchemaURL(SchemaURL),
+ )
+
+ var err error
+
+ inflightSpans, e := otelconv.NewSDKExporterSpanInflight(m)
+ if e != nil {
+ e = fmt.Errorf("failed to create span inflight metric: %w", e)
+ err = errors.Join(err, e)
+ }
+ i.inflightSpans = inflightSpans.Inst()
+
+ exportedSpans, e := otelconv.NewSDKExporterSpanExported(m)
+ if e != nil {
+ e = fmt.Errorf("failed to create span exported metric: %w", e)
+ err = errors.Join(err, e)
+ }
+ i.exportedSpans = exportedSpans.Inst()
+
+ opDuration, e := otelconv.NewSDKExporterOperationDuration(m)
+ if e != nil {
+ e = fmt.Errorf("failed to create operation duration metric: %w", e)
+ err = errors.Join(err, e)
+ }
+ i.opDuration = opDuration.Inst()
+
+ return i, err
+}
+
+// BaseAttrs returns the base attributes for the exporter with the provided ID
+// and target.
+//
+// The id should be the unique exporter instance ID. It is used
+// to set the "component.name" attribute.
+//
+// The target is the gRPC target the exporter is exporting to. It is expected
+// to be the output of the Client's CanonicalTarget method.
+func BaseAttrs(id int64, target string) []attribute.KeyValue {
+ host, port, err := ParseCanonicalTarget(target)
+ if err != nil || (host == "" && port < 0) {
+ if err != nil {
+ global.Debug("failed to parse target", "target", target, "error", err)
+ }
+ return []attribute.KeyValue{
+ semconv.OTelComponentName(ComponentName(id)),
+ semconv.OTelComponentTypeOtlpGRPCSpanExporter,
+ }
+ }
+
+ // Do not use append so the slice is exactly allocated.
+
+ if port < 0 {
+ return []attribute.KeyValue{
+ semconv.OTelComponentName(ComponentName(id)),
+ semconv.OTelComponentTypeOtlpGRPCSpanExporter,
+ semconv.ServerAddress(host),
+ }
+ }
+
+ if host == "" {
+ return []attribute.KeyValue{
+ semconv.OTelComponentName(ComponentName(id)),
+ semconv.OTelComponentTypeOtlpGRPCSpanExporter,
+ semconv.ServerPort(port),
+ }
+ }
+
+ return []attribute.KeyValue{
+ semconv.OTelComponentName(ComponentName(id)),
+ semconv.OTelComponentTypeOtlpGRPCSpanExporter,
+ semconv.ServerAddress(host),
+ semconv.ServerPort(port),
+ }
+}
+
+// ExportSpans instruments the ExportSpans method of the exporter. It returns
+// an [ExportOp] that must have its [ExportOp.End] method called when the
+// ExportSpans method returns.
+func (i *Instrumentation) ExportSpans(ctx context.Context, nSpans int) ExportOp {
+ start := time.Now()
+
+ addOpt := get[metric.AddOption](addOptPool)
+ defer put(addOptPool, addOpt)
+ *addOpt = append(*addOpt, i.addOpt)
+ i.inflightSpans.Add(ctx, int64(nSpans), *addOpt...)
+
+ return ExportOp{
+ ctx: ctx,
+ start: start,
+ nSpans: int64(nSpans),
+ inst: i,
+ }
+}
+
+// ExportOp tracks the operation being observed by [Instrumentation.ExportSpans].
+type ExportOp struct {
+ ctx context.Context
+ start time.Time
+ nSpans int64
+
+ inst *Instrumentation
+}
+
+// End completes the observation of the operation being observed by a call to
+// [Instrumentation.ExportSpans].
+//
+// Any error that is encountered is provided as err.
+//
+// If err is not nil, all spans will be recorded as failures unless error is of
+// type [internal.PartialSuccess]. In the case of a PartialSuccess, the number
+// of successfully exported spans will be determined by inspecting the
+// RejectedItems field of the PartialSuccess.
+func (e ExportOp) End(err error, code codes.Code) {
+ addOpt := get[metric.AddOption](addOptPool)
+ defer put(addOptPool, addOpt)
+ *addOpt = append(*addOpt, e.inst.addOpt)
+
+ e.inst.inflightSpans.Add(e.ctx, -e.nSpans, *addOpt...)
+
+ success := successful(e.nSpans, err)
+ // Record successfully exported spans, even if the value is 0 which are
+ // meaningful to distribution aggregations.
+ e.inst.exportedSpans.Add(e.ctx, success, *addOpt...)
+
+ if err != nil {
+ attrs := get[attribute.KeyValue](measureAttrsPool)
+ defer put(measureAttrsPool, attrs)
+ *attrs = append(*attrs, e.inst.attrs...)
+ *attrs = append(*attrs, semconv.ErrorType(err))
+
+ // Do not inefficiently make a copy of attrs by using
+ // WithAttributes instead of WithAttributeSet.
+ o := metric.WithAttributeSet(attribute.NewSet(*attrs...))
+ // Reset addOpt with new attribute set.
+ *addOpt = append((*addOpt)[:0], o)
+
+ e.inst.exportedSpans.Add(e.ctx, e.nSpans-success, *addOpt...)
+ }
+
+ recOpt := get[metric.RecordOption](recordOptPool)
+ defer put(recordOptPool, recOpt)
+ *recOpt = append(*recOpt, e.inst.recordOption(err, code))
+
+ d := time.Since(e.start).Seconds()
+ e.inst.opDuration.Record(e.ctx, d, *recOpt...)
+}
+
+// recordOption returns a RecordOption with attributes representing the
+// outcome of the operation being recorded.
+//
+// If err is nil and code is codes.OK, the default recOpt of the
+// Instrumentation is returned.
+//
+// If err is not nil or code is not codes.OK, a new RecordOption is returned
+// with the base attributes of the Instrumentation plus the rpc.grpc.status_code
+// attribute set to the provided code, and if err is not nil, the error.type
+// attribute set to the type of the error.
+func (i *Instrumentation) recordOption(err error, code codes.Code) metric.RecordOption {
+ if err == nil && code == codes.OK {
+ return i.recOpt
+ }
+
+ attrs := get[attribute.KeyValue](measureAttrsPool)
+ defer put(measureAttrsPool, attrs)
+ *attrs = append(*attrs, i.attrs...)
+
+ *attrs = append(*attrs, semconv.RPCResponseStatusCode(code.String()))
+ if err != nil {
+ *attrs = append(*attrs, semconv.ErrorType(err))
+ }
+
+ // Do not inefficiently make a copy of attrs by using WithAttributes
+ // instead of WithAttributeSet.
+ return metric.WithAttributeSet(attribute.NewSet(*attrs...))
+}
+
+// successful returns the number of successfully exported spans out of the n
+// that were exported based on the provided error.
+//
+// If err is nil, n is returned. All spans were successfully exported.
+//
+// If err is not nil and not an [internal.PartialSuccess] error, 0 is returned.
+// It is assumed all spans failed to be exported.
+//
+// If err is an [internal.PartialSuccess] error, the number of successfully
+// exported spans is computed by subtracting the RejectedItems field from n. If
+// RejectedItems is negative, n is returned. If RejectedItems is greater than
+// n, 0 is returned.
+func successful(n int64, err error) int64 {
+ if err == nil {
+ return n // All spans successfully exported.
+ }
+ // Split rejection calculation so successful is inlinable.
+ return n - rejected(n, err)
+}
+
+var errPartialPool = &sync.Pool{
+ New: func() any { return new(internal.PartialSuccess) },
+}
+
+// rejected returns how many out of the n spans exporter were rejected based on
+// the provided non-nil err.
+func rejected(n int64, err error) int64 {
+ ps := errPartialPool.Get().(*internal.PartialSuccess)
+ defer errPartialPool.Put(ps)
+ // Check for partial success.
+ if errors.As(err, ps) {
+ // Bound RejectedItems to [0, n]. This should not be needed,
+ // but be defensive as this is from an external source.
+ return min(max(ps.RejectedItems, 0), n)
+ }
+ return n // All spans rejected.
+}
diff --git a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/observ/target.go b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/observ/target.go
new file mode 100644
index 0000000000..34eee27db0
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/observ/target.go
@@ -0,0 +1,143 @@
+// Code generated by gotmpl. DO NOT MODIFY.
+// source: internal/shared/otlp/observ/target.go.tmpl
+
+// Copyright The OpenTelemetry Authors
+// SPDX-License-Identifier: Apache-2.0
+
+package observ // import "go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/observ"
+
+import (
+ "errors"
+ "fmt"
+ "net"
+ "net/netip"
+ "strconv"
+ "strings"
+)
+
+const (
+ schemeUnix = "unix"
+ schemeUnixAbstract = "unix-abstract"
+)
+
+// ParseCanonicalTarget parses a target string and returns the extracted host
+// (domain address or IP), the target port, or an error.
+//
+// If no port is specified, -1 is returned.
+//
+// If no host is specified, an empty string is returned.
+//
+// The target string is expected to always have the form
+// "://[authority]/". For example:
+// - "dns:///example.com:42"
+// - "dns://8.8.8.8/example.com:42"
+// - "unix:///path/to/socket"
+// - "unix-abstract:///socket-name"
+// - "passthrough:///192.34.2.1:42"
+//
+// The target is expected to come from the CanonicalTarget method of a gRPC
+// Client.
+func ParseCanonicalTarget(target string) (string, int, error) {
+ const sep = "://"
+
+ // Find scheme. Do not allocate the string by using url.Parse.
+ idx := strings.Index(target, sep)
+ if idx == -1 {
+ return "", -1, fmt.Errorf("invalid target %q: missing scheme", target)
+ }
+ scheme, endpoint := target[:idx], target[idx+len(sep):]
+
+ // Check for unix schemes.
+ if scheme == schemeUnix || scheme == schemeUnixAbstract {
+ return parseUnix(endpoint)
+ }
+
+ // Strip leading slash and any authority.
+ if i := strings.Index(endpoint, "/"); i != -1 {
+ endpoint = endpoint[i+1:]
+ }
+
+ // DNS, passthrough, and custom resolvers.
+ return parseEndpoint(endpoint)
+}
+
+// parseUnix parses unix socket targets.
+func parseUnix(endpoint string) (string, int, error) {
+ // Format: unix[-abstract]://path
+ //
+ // We should have "/path" (empty authority) if valid.
+ if len(endpoint) >= 1 && endpoint[0] == '/' {
+ // Return the full path including leading slash.
+ return endpoint, -1, nil
+ }
+
+ // If there's no leading slash, it means there might be an authority
+ // Check for authority case (should error): "authority/path"
+ if slashIdx := strings.Index(endpoint, "/"); slashIdx > 0 {
+ return "", -1, fmt.Errorf("invalid (non-empty) authority: %s", endpoint[:slashIdx])
+ }
+
+ return "", -1, errors.New("invalid unix target format")
+}
+
+// parseEndpoint parses an endpoint from a gRPC target.
+//
+// It supports the following formats:
+// - "host"
+// - "host%zone"
+// - "host:port"
+// - "host%zone:port"
+// - "ipv4"
+// - "ipv4%zone"
+// - "ipv4:port"
+// - "ipv4%zone:port"
+// - "ipv6"
+// - "ipv6%zone"
+// - "[ipv6]"
+// - "[ipv6%zone]"
+// - "[ipv6]:port"
+// - "[ipv6%zone]:port"
+//
+// It returns the host or host%zone (domain address or IP), the port (or -1 if
+// not specified), or an error if the input is not a valid.
+func parseEndpoint(endpoint string) (string, int, error) {
+ // First check if the endpoint is just an IP address.
+ if ip := parseIP(endpoint); ip != "" {
+ return ip, -1, nil
+ }
+
+ // If there's no colon, there is no port (IPv6 with no port checked above).
+ if !strings.Contains(endpoint, ":") {
+ return endpoint, -1, nil
+ }
+
+ host, portStr, err := net.SplitHostPort(endpoint)
+ if err != nil {
+ return "", -1, fmt.Errorf("invalid host:port %q: %w", endpoint, err)
+ }
+
+ const base, bitSize = 10, 16
+ port16, err := strconv.ParseUint(portStr, base, bitSize)
+ if err != nil {
+ return "", -1, fmt.Errorf("invalid port %q: %w", portStr, err)
+ }
+ port := int(port16) // port is guaranteed to be in the range [0, 65535].
+
+ return host, port, nil
+}
+
+// parseIP attempts to parse the entire endpoint as an IP address.
+// It returns the normalized string form of the IP if successful,
+// or an empty string if parsing fails.
+func parseIP(ip string) string {
+ // Strip leading and trailing brackets for IPv6 addresses.
+ if len(ip) >= 2 && ip[0] == '[' && ip[len(ip)-1] == ']' {
+ ip = ip[1 : len(ip)-1]
+ }
+ addr, err := netip.ParseAddr(ip)
+ if err != nil {
+ return ""
+ }
+ // Return the normalized string form of the IP.
+ return addr.String()
+}
diff --git a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/otlpconfig/envconfig.go b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/otlpconfig/envconfig.go
index 7bb189a94b..1d840be205 100644
--- a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/otlpconfig/envconfig.go
+++ b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/otlpconfig/envconfig.go
@@ -1,4 +1,4 @@
-// Code created by gotmpl. DO NOT MODIFY.
+// Code generated by gotmpl. DO NOT MODIFY.
// source: internal/shared/otlp/otlptrace/otlpconfig/envconfig.go.tmpl
// Copyright The OpenTelemetry Authors
@@ -77,8 +77,16 @@ func getOptionsFromEnv() []GenericOption {
}),
envconfig.WithCertPool("CERTIFICATE", func(p *x509.CertPool) { tlsConf.RootCAs = p }),
envconfig.WithCertPool("TRACES_CERTIFICATE", func(p *x509.CertPool) { tlsConf.RootCAs = p }),
- envconfig.WithClientCert("CLIENT_CERTIFICATE", "CLIENT_KEY", func(c tls.Certificate) { tlsConf.Certificates = []tls.Certificate{c} }),
- envconfig.WithClientCert("TRACES_CLIENT_CERTIFICATE", "TRACES_CLIENT_KEY", func(c tls.Certificate) { tlsConf.Certificates = []tls.Certificate{c} }),
+ envconfig.WithClientCert(
+ "CLIENT_CERTIFICATE",
+ "CLIENT_KEY",
+ func(c tls.Certificate) { tlsConf.Certificates = []tls.Certificate{c} },
+ ),
+ envconfig.WithClientCert(
+ "TRACES_CLIENT_CERTIFICATE",
+ "TRACES_CLIENT_KEY",
+ func(c tls.Certificate) { tlsConf.Certificates = []tls.Certificate{c} },
+ ),
withTLSConfig(tlsConf, func(c *tls.Config) { opts = append(opts, WithTLSClientConfig(c)) }),
envconfig.WithBool("INSECURE", func(b bool) { opts = append(opts, withInsecure(b)) }),
envconfig.WithBool("TRACES_INSECURE", func(b bool) { opts = append(opts, withInsecure(b)) }),
diff --git a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/otlpconfig/options.go b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/otlpconfig/options.go
index 0a317d9263..4f47117a58 100644
--- a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/otlpconfig/options.go
+++ b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/otlpconfig/options.go
@@ -1,9 +1,10 @@
-// Code created by gotmpl. DO NOT MODIFY.
+// Code generated by gotmpl. DO NOT MODIFY.
// source: internal/shared/otlp/otlptrace/otlpconfig/options.go.tmpl
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0
+// Package otlpconfig provides configuration for the otlptrace exporters.
package otlpconfig // import "go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/otlpconfig"
import (
@@ -52,7 +53,9 @@ type (
// gRPC configurations
GRPCCredentials credentials.TransportCredentials
- Proxy HTTPTransportProxyFunc
+ // HTTP configurations
+ Proxy HTTPTransportProxyFunc
+ HTTPClient *http.Client
}
Config struct {
@@ -89,12 +92,11 @@ func NewHTTPConfig(opts ...HTTPOption) Config {
return cfg
}
-// cleanPath returns a path with all spaces trimmed and all redundancies
-// removed. If urlPath is empty or cleaning it results in an empty string,
+// cleanPath returns a path with all spaces trimmed. If urlPath is empty,
// defaultPath is returned instead.
func cleanPath(urlPath string, defaultPath string) string {
- tmp := path.Clean(strings.TrimSpace(urlPath))
- if tmp == "." {
+ tmp := strings.TrimSpace(urlPath)
+ if tmp == "" || tmp == "." {
return defaultPath
}
if !path.IsAbs(tmp) {
@@ -349,3 +351,10 @@ func WithProxy(pf HTTPTransportProxyFunc) GenericOption {
return cfg
})
}
+
+func WithHTTPClient(c *http.Client) GenericOption {
+ return newGenericOption(func(cfg Config) Config {
+ cfg.Traces.HTTPClient = c
+ return cfg
+ })
+}
diff --git a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/otlpconfig/optiontypes.go b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/otlpconfig/optiontypes.go
index 3d4f699d47..9184903872 100644
--- a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/otlpconfig/optiontypes.go
+++ b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/otlpconfig/optiontypes.go
@@ -1,4 +1,4 @@
-// Code created by gotmpl. DO NOT MODIFY.
+// Code generated by gotmpl. DO NOT MODIFY.
// source: internal/shared/otlp/otlptrace/otlpconfig/optiontypes.go.tmpl
// Copyright The OpenTelemetry Authors
diff --git a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/otlpconfig/tls.go b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/otlpconfig/tls.go
index 38b97a0131..ba6e411835 100644
--- a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/otlpconfig/tls.go
+++ b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/otlpconfig/tls.go
@@ -1,4 +1,4 @@
-// Code created by gotmpl. DO NOT MODIFY.
+// Code generated by gotmpl. DO NOT MODIFY.
// source: internal/shared/otlp/otlptrace/otlpconfig/tls.go.tmpl
// Copyright The OpenTelemetry Authors
diff --git a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/partialsuccess.go b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/partialsuccess.go
index a12ea4c48e..a811a07b35 100644
--- a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/partialsuccess.go
+++ b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/partialsuccess.go
@@ -1,4 +1,4 @@
-// Code created by gotmpl. DO NOT MODIFY.
+// Code generated by gotmpl. DO NOT MODIFY.
// source: internal/shared/otlp/partialsuccess.go
// Copyright The OpenTelemetry Authors
@@ -29,6 +29,17 @@ func (ps PartialSuccess) Error() string {
return fmt.Sprintf("OTLP partial success: %s (%d %s rejected)", msg, ps.RejectedItems, ps.RejectedKind)
}
+// As returns true if ps can be assigned to target and makes the assignment.
+// Otherwise, it returns false. This supports the errors.As() interface.
+func (ps PartialSuccess) As(target any) bool {
+ t, ok := target.(*PartialSuccess)
+ if !ok {
+ return false
+ }
+ *t = ps
+ return true
+}
+
// Is supports the errors.Is() interface.
func (ps PartialSuccess) Is(err error) bool {
_, ok := err.(PartialSuccess)
diff --git a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/retry/retry.go b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/retry/retry.go
index 1c5450ab62..a7b8e81a78 100644
--- a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/retry/retry.go
+++ b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/retry/retry.go
@@ -1,4 +1,4 @@
-// Code created by gotmpl. DO NOT MODIFY.
+// Code generated by gotmpl. DO NOT MODIFY.
// source: internal/shared/otlp/retry/retry.go.tmpl
// Copyright The OpenTelemetry Authors
@@ -14,7 +14,7 @@ import (
"fmt"
"time"
- "github.com/cenkalti/backoff/v4"
+ "github.com/cenkalti/backoff/v5"
)
// DefaultConfig are the recommended defaults to use.
@@ -77,12 +77,12 @@ func (c Config) RequestFunc(evaluate EvaluateFunc) RequestFunc {
RandomizationFactor: backoff.DefaultRandomizationFactor,
Multiplier: backoff.DefaultMultiplier,
MaxInterval: c.MaxInterval,
- MaxElapsedTime: c.MaxElapsedTime,
- Stop: backoff.Stop,
- Clock: backoff.SystemClock,
}
b.Reset()
+ maxElapsedTime := c.MaxElapsedTime
+ startTime := time.Now()
+
for {
err := fn(ctx)
if err == nil {
@@ -94,21 +94,22 @@ func (c Config) RequestFunc(evaluate EvaluateFunc) RequestFunc {
return err
}
- bOff := b.NextBackOff()
- if bOff == backoff.Stop {
+ // Check if context is canceled before attempting to wait and retry.
+ if ctx.Err() != nil {
+ return fmt.Errorf("%w: %w", ctx.Err(), err)
+ }
+
+ if maxElapsedTime != 0 && time.Since(startTime) > maxElapsedTime {
return fmt.Errorf("max retry time elapsed: %w", err)
}
// Wait for the greater of the backoff or throttle delay.
- var delay time.Duration
- if bOff > throttle {
- delay = bOff
- } else {
- elapsed := b.GetElapsedTime()
- if b.MaxElapsedTime != 0 && elapsed+throttle > b.MaxElapsedTime {
- return fmt.Errorf("max retry time would elapse: %w", err)
- }
- delay = throttle
+ bOff := b.NextBackOff()
+ delay := max(throttle, bOff)
+
+ elapsed := time.Since(startTime)
+ if maxElapsedTime != 0 && elapsed+throttle > maxElapsedTime {
+ return fmt.Errorf("max retry time would elapse: %w", err)
}
if ctxErr := waitFunc(ctx, delay); ctxErr != nil {
@@ -136,7 +137,7 @@ func wait(ctx context.Context, delay time.Duration) error {
select {
case <-timer.C:
default:
- return ctx.Err()
+ return context.Cause(ctx)
}
case <-timer.C:
}
diff --git a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/version.go b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/version.go
new file mode 100644
index 0000000000..19fac1b725
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/version.go
@@ -0,0 +1,8 @@
+// Copyright The OpenTelemetry Authors
+// SPDX-License-Identifier: Apache-2.0
+
+package internal // import "go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal"
+
+// Version is the current release version of the OpenTelemetry OTLP gRPC trace
+// exporter in use.
+const Version = "1.40.0"
diff --git a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/x/README.md b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/x/README.md
new file mode 100644
index 0000000000..15a3011bff
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/x/README.md
@@ -0,0 +1,36 @@
+# Experimental Features
+
+The `otlptracegrpc` exporter contains features that have not yet stabilized in the OpenTelemetry specification.
+These features are added to the `otlptracegrpc` exporter prior to stabilization in the specification so that users can start experimenting with them and provide feedback.
+
+These feature may change in backwards incompatible ways as feedback is applied.
+See the [Compatibility and Stability](#compatibility-and-stability) section for more information.
+
+## Features
+
+- [Observability](#observability)
+
+### Observability
+
+The `otlptracegrpc` exporter provides a observability feature that allows you to monitor the SDK itself.
+
+To opt-in, set the environment variable `OTEL_GO_X_OBSERVABILITY` to `true`.
+
+When enabled, the SDK will create the following metrics using the global `MeterProvider`:
+
+- `otel.sdk.exporter.span.inflight`
+- `otel.sdk.exporter.span.exported`
+- `otel.sdk.exporter.operation.duration`
+
+Please see the [Semantic conventions for OpenTelemetry SDK metrics] documentation for more details on these metrics.
+
+[Semantic conventions for OpenTelemetry SDK metrics]: https://github.com/open-telemetry/semantic-conventions/blob/v1.37.0/docs/otel/sdk-metrics.md
+
+## Compatibility and Stability
+
+Experimental features do not fall within the scope of the OpenTelemetry Go versioning and stability [policy](../../../../../../VERSIONING.md).
+These features may be removed or modified in successive version releases, including patch versions.
+
+When an experimental feature is promoted to a stable feature, a migration path will be included in the changelog entry of the release.
+There is no guarantee that any environment variable feature flags that enabled the experimental feature will be supported by the stable version.
+If they are supported, they may be accompanied with a deprecation notice stating a timeline for the removal of that support.
diff --git a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/x/observ.go b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/x/observ.go
new file mode 100644
index 0000000000..4e89c6524f
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/x/observ.go
@@ -0,0 +1,22 @@
+// Copyright The OpenTelemetry Authors
+// SPDX-License-Identifier: Apache-2.0
+
+package x // import "go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/x"
+
+import "strings"
+
+// Observability is an experimental feature flag that determines if exporter
+// observability metrics are enabled.
+//
+// To enable this feature set the OTEL_GO_X_OBSERVABILITY environment variable
+// to the case-insensitive string value of "true" (i.e. "True" and "TRUE"
+// will also enable this).
+var Observability = newFeature(
+ []string{"OBSERVABILITY"},
+ func(v string) (string, bool) {
+ if strings.EqualFold(v, "true") {
+ return v, true
+ }
+ return "", false
+ },
+)
diff --git a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/x/x.go b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/x/x.go
new file mode 100644
index 0000000000..741ba62c97
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/x/x.go
@@ -0,0 +1,58 @@
+// Code generated by gotmpl. DO NOT MODIFY.
+// source: internal/shared/x/x.go.tmpl
+
+// Copyright The OpenTelemetry Authors
+// SPDX-License-Identifier: Apache-2.0
+
+// Package x documents experimental features for [go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc].
+package x // import "go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal/x"
+
+import (
+ "os"
+)
+
+// Feature is an experimental feature control flag. It provides a uniform way
+// to interact with these feature flags and parse their values.
+type Feature[T any] struct {
+ keys []string
+ parse func(v string) (T, bool)
+}
+
+func newFeature[T any](suffix []string, parse func(string) (T, bool)) Feature[T] {
+ const envKeyRoot = "OTEL_GO_X_"
+ keys := make([]string, 0, len(suffix))
+ for _, s := range suffix {
+ keys = append(keys, envKeyRoot+s)
+ }
+ return Feature[T]{
+ keys: keys,
+ parse: parse,
+ }
+}
+
+// Keys returns the environment variable keys that can be set to enable the
+// feature.
+func (f Feature[T]) Keys() []string { return f.keys }
+
+// Lookup returns the user configured value for the feature and true if the
+// user has enabled the feature. Otherwise, if the feature is not enabled, a
+// zero-value and false are returned.
+func (f Feature[T]) Lookup() (v T, ok bool) {
+ // https://github.com/open-telemetry/opentelemetry-specification/blob/62effed618589a0bec416a87e559c0a9d96289bb/specification/configuration/sdk-environment-variables.md#parsing-empty-value
+ //
+ // > The SDK MUST interpret an empty value of an environment variable the
+ // > same way as when the variable is unset.
+ for _, key := range f.keys {
+ vRaw := os.Getenv(key)
+ if vRaw != "" {
+ return f.parse(vRaw)
+ }
+ }
+ return v, ok
+}
+
+// Enabled reports whether the feature is enabled.
+func (f Feature[T]) Enabled() bool {
+ _, ok := f.Lookup()
+ return ok
+}
diff --git a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/options.go b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/options.go
index 00ab1f20c6..2da2298701 100644
--- a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/options.go
+++ b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/options.go
@@ -199,8 +199,9 @@ func WithTimeout(duration time.Duration) Option {
// explicitly returns a backoff time in the response. That time will take
// precedence over these settings.
//
-// These settings do not define any network retry strategy. That is entirely
-// handled by the gRPC ClientConn.
+// These settings define the retry strategy implemented by the exporter.
+// These settings do not define any network retry strategy.
+// That is handled by the gRPC ClientConn.
//
// If unset, the default retry policy will be used. It will retry the export
// 5 seconds after receiving a retryable error and increase exponentially
diff --git a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/version.go b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/version.go
index f156ee6672..370cd2a6f8 100644
--- a/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/version.go
+++ b/vendor/go.opentelemetry.io/otel/exporters/otlp/otlptrace/version.go
@@ -5,5 +5,5 @@ package otlptrace // import "go.opentelemetry.io/otel/exporters/otlp/otlptrace"
// Version is the current release version of the OpenTelemetry OTLP trace exporter in use.
func Version() string {
- return "1.34.0"
+ return "1.40.0"
}
diff --git a/vendor/go.opentelemetry.io/otel/internal/errorhandler/errorhandler.go b/vendor/go.opentelemetry.io/otel/internal/errorhandler/errorhandler.go
new file mode 100644
index 0000000000..3f0ab31312
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/internal/errorhandler/errorhandler.go
@@ -0,0 +1,96 @@
+// Copyright The OpenTelemetry Authors
+// SPDX-License-Identifier: Apache-2.0
+
+// Package errorhandler provides the global error handler for OpenTelemetry.
+//
+// This package has no OTel dependencies, allowing it to be imported by any
+// package in the module without creating import cycles.
+package errorhandler // import "go.opentelemetry.io/otel/internal/errorhandler"
+
+import (
+ "errors"
+ "log"
+ "sync"
+ "sync/atomic"
+)
+
+// ErrorHandler handles irremediable events.
+type ErrorHandler interface {
+ // Handle handles any error deemed irremediable by an OpenTelemetry
+ // component.
+ Handle(error)
+}
+
+type ErrDelegator struct {
+ delegate atomic.Pointer[ErrorHandler]
+}
+
+// Compile-time check that delegator implements ErrorHandler.
+var _ ErrorHandler = (*ErrDelegator)(nil)
+
+func (d *ErrDelegator) Handle(err error) {
+ if eh := d.delegate.Load(); eh != nil {
+ (*eh).Handle(err)
+ return
+ }
+ log.Print(err)
+}
+
+// setDelegate sets the ErrorHandler delegate.
+func (d *ErrDelegator) setDelegate(eh ErrorHandler) {
+ d.delegate.Store(&eh)
+}
+
+type errorHandlerHolder struct {
+ eh ErrorHandler
+}
+
+var (
+ globalErrorHandler = defaultErrorHandler()
+ delegateErrorHandlerOnce sync.Once
+)
+
+// GetErrorHandler returns the global ErrorHandler instance.
+//
+// The default ErrorHandler instance returned will log all errors to STDERR
+// until an override ErrorHandler is set with SetErrorHandler. All
+// ErrorHandler returned prior to this will automatically forward errors to
+// the set instance instead of logging.
+//
+// Subsequent calls to SetErrorHandler after the first will not forward errors
+// to the new ErrorHandler for prior returned instances.
+func GetErrorHandler() ErrorHandler {
+ return globalErrorHandler.Load().(errorHandlerHolder).eh
+}
+
+// SetErrorHandler sets the global ErrorHandler to h.
+//
+// The first time this is called all ErrorHandler previously returned from
+// GetErrorHandler will send errors to h instead of the default logging
+// ErrorHandler. Subsequent calls will set the global ErrorHandler, but not
+// delegate errors to h.
+func SetErrorHandler(h ErrorHandler) {
+ current := GetErrorHandler()
+
+ if _, cOk := current.(*ErrDelegator); cOk {
+ if _, ehOk := h.(*ErrDelegator); ehOk && current == h {
+ // Do not assign to the delegate of the default ErrDelegator to be
+ // itself.
+ log.Print(errors.New("no ErrorHandler delegate configured"), " ErrorHandler remains its current value.")
+ return
+ }
+ }
+
+ delegateErrorHandlerOnce.Do(func() {
+ if def, ok := current.(*ErrDelegator); ok {
+ def.setDelegate(h)
+ }
+ })
+ globalErrorHandler.Store(errorHandlerHolder{eh: h})
+}
+
+func defaultErrorHandler() *atomic.Value {
+ v := &atomic.Value{}
+ v.Store(errorHandlerHolder{eh: &ErrDelegator{}})
+ return v
+}
diff --git a/vendor/go.opentelemetry.io/otel/internal/global/handler.go b/vendor/go.opentelemetry.io/otel/internal/global/handler.go
index 2e47b2964c..77d0425f54 100644
--- a/vendor/go.opentelemetry.io/otel/internal/global/handler.go
+++ b/vendor/go.opentelemetry.io/otel/internal/global/handler.go
@@ -5,33 +5,13 @@
package global // import "go.opentelemetry.io/otel/internal/global"
import (
- "log"
- "sync/atomic"
+ "go.opentelemetry.io/otel/internal/errorhandler"
)
-// ErrorHandler handles irremediable events.
-type ErrorHandler interface {
- // Handle handles any error deemed irremediable by an OpenTelemetry
- // component.
- Handle(error)
-}
+// ErrorHandler is an alias for errorhandler.ErrorHandler, kept for backward
+// compatibility with existing callers of internal/global.
+type ErrorHandler = errorhandler.ErrorHandler
-type ErrDelegator struct {
- delegate atomic.Pointer[ErrorHandler]
-}
-
-// Compile-time check that delegator implements ErrorHandler.
-var _ ErrorHandler = (*ErrDelegator)(nil)
-
-func (d *ErrDelegator) Handle(err error) {
- if eh := d.delegate.Load(); eh != nil {
- (*eh).Handle(err)
- return
- }
- log.Print(err)
-}
-
-// setDelegate sets the ErrorHandler delegate.
-func (d *ErrDelegator) setDelegate(eh ErrorHandler) {
- d.delegate.Store(&eh)
-}
+// ErrDelegator is an alias for errorhandler.ErrDelegator, kept for backward
+// compatibility with existing callers of internal/global.
+type ErrDelegator = errorhandler.ErrDelegator
diff --git a/vendor/go.opentelemetry.io/otel/internal/global/instruments.go b/vendor/go.opentelemetry.io/otel/internal/global/instruments.go
index ae92a42516..55255cddfc 100644
--- a/vendor/go.opentelemetry.io/otel/internal/global/instruments.go
+++ b/vendor/go.opentelemetry.io/otel/internal/global/instruments.go
@@ -229,6 +229,13 @@ func (i *sfCounter) Add(ctx context.Context, incr float64, opts ...metric.AddOpt
}
}
+func (i *sfCounter) Enabled(ctx context.Context) bool {
+ if ctr := i.delegate.Load(); ctr != nil {
+ return ctr.(metric.Float64Counter).Enabled(ctx)
+ }
+ return false
+}
+
type sfUpDownCounter struct {
embedded.Float64UpDownCounter
@@ -255,6 +262,13 @@ func (i *sfUpDownCounter) Add(ctx context.Context, incr float64, opts ...metric.
}
}
+func (i *sfUpDownCounter) Enabled(ctx context.Context) bool {
+ if ctr := i.delegate.Load(); ctr != nil {
+ return ctr.(metric.Float64UpDownCounter).Enabled(ctx)
+ }
+ return false
+}
+
type sfHistogram struct {
embedded.Float64Histogram
@@ -281,6 +295,13 @@ func (i *sfHistogram) Record(ctx context.Context, x float64, opts ...metric.Reco
}
}
+func (i *sfHistogram) Enabled(ctx context.Context) bool {
+ if ctr := i.delegate.Load(); ctr != nil {
+ return ctr.(metric.Float64Histogram).Enabled(ctx)
+ }
+ return false
+}
+
type sfGauge struct {
embedded.Float64Gauge
@@ -307,6 +328,13 @@ func (i *sfGauge) Record(ctx context.Context, x float64, opts ...metric.RecordOp
}
}
+func (i *sfGauge) Enabled(ctx context.Context) bool {
+ if ctr := i.delegate.Load(); ctr != nil {
+ return ctr.(metric.Float64Gauge).Enabled(ctx)
+ }
+ return false
+}
+
type siCounter struct {
embedded.Int64Counter
@@ -333,6 +361,13 @@ func (i *siCounter) Add(ctx context.Context, x int64, opts ...metric.AddOption)
}
}
+func (i *siCounter) Enabled(ctx context.Context) bool {
+ if ctr := i.delegate.Load(); ctr != nil {
+ return ctr.(metric.Int64Counter).Enabled(ctx)
+ }
+ return false
+}
+
type siUpDownCounter struct {
embedded.Int64UpDownCounter
@@ -359,6 +394,13 @@ func (i *siUpDownCounter) Add(ctx context.Context, x int64, opts ...metric.AddOp
}
}
+func (i *siUpDownCounter) Enabled(ctx context.Context) bool {
+ if ctr := i.delegate.Load(); ctr != nil {
+ return ctr.(metric.Int64UpDownCounter).Enabled(ctx)
+ }
+ return false
+}
+
type siHistogram struct {
embedded.Int64Histogram
@@ -385,6 +427,13 @@ func (i *siHistogram) Record(ctx context.Context, x int64, opts ...metric.Record
}
}
+func (i *siHistogram) Enabled(ctx context.Context) bool {
+ if ctr := i.delegate.Load(); ctr != nil {
+ return ctr.(metric.Int64Histogram).Enabled(ctx)
+ }
+ return false
+}
+
type siGauge struct {
embedded.Int64Gauge
@@ -410,3 +459,10 @@ func (i *siGauge) Record(ctx context.Context, x int64, opts ...metric.RecordOpti
ctr.(metric.Int64Gauge).Record(ctx, x, opts...)
}
}
+
+func (i *siGauge) Enabled(ctx context.Context) bool {
+ if ctr := i.delegate.Load(); ctr != nil {
+ return ctr.(metric.Int64Gauge).Enabled(ctx)
+ }
+ return false
+}
diff --git a/vendor/go.opentelemetry.io/otel/internal/global/internal_logging.go b/vendor/go.opentelemetry.io/otel/internal/global/internal_logging.go
index adbca7d347..86d7f4ba08 100644
--- a/vendor/go.opentelemetry.io/otel/internal/global/internal_logging.go
+++ b/vendor/go.opentelemetry.io/otel/internal/global/internal_logging.go
@@ -41,22 +41,22 @@ func GetLogger() logr.Logger {
// Info prints messages about the general state of the API or SDK.
// This should usually be less than 5 messages a minute.
-func Info(msg string, keysAndValues ...interface{}) {
+func Info(msg string, keysAndValues ...any) {
GetLogger().V(4).Info(msg, keysAndValues...)
}
// Error prints messages about exceptional states of the API or SDK.
-func Error(err error, msg string, keysAndValues ...interface{}) {
+func Error(err error, msg string, keysAndValues ...any) {
GetLogger().Error(err, msg, keysAndValues...)
}
// Debug prints messages about all internal changes in the API or SDK.
-func Debug(msg string, keysAndValues ...interface{}) {
+func Debug(msg string, keysAndValues ...any) {
GetLogger().V(8).Info(msg, keysAndValues...)
}
// Warn prints messages about warnings in the API or SDK.
// Not an error but is likely more important than an informational event.
-func Warn(msg string, keysAndValues ...interface{}) {
+func Warn(msg string, keysAndValues ...any) {
GetLogger().V(1).Info(msg, keysAndValues...)
}
diff --git a/vendor/go.opentelemetry.io/otel/internal/global/meter.go b/vendor/go.opentelemetry.io/otel/internal/global/meter.go
index adb37b5b0e..50043d669b 100644
--- a/vendor/go.opentelemetry.io/otel/internal/global/meter.go
+++ b/vendor/go.opentelemetry.io/otel/internal/global/meter.go
@@ -105,7 +105,7 @@ type delegatedInstrument interface {
setDelegate(metric.Meter)
}
-// instID are the identifying properties of a instrument.
+// instID are the identifying properties of an instrument.
type instID struct {
// name is the name of the stream.
name string
@@ -157,7 +157,7 @@ func (m *meter) Int64Counter(name string, options ...metric.Int64CounterOption)
cfg := metric.NewInt64CounterConfig(options...)
id := instID{
name: name,
- kind: reflect.TypeOf((*siCounter)(nil)),
+ kind: reflect.TypeFor[*siCounter](),
description: cfg.Description(),
unit: cfg.Unit(),
}
@@ -183,7 +183,7 @@ func (m *meter) Int64UpDownCounter(
cfg := metric.NewInt64UpDownCounterConfig(options...)
id := instID{
name: name,
- kind: reflect.TypeOf((*siUpDownCounter)(nil)),
+ kind: reflect.TypeFor[*siUpDownCounter](),
description: cfg.Description(),
unit: cfg.Unit(),
}
@@ -206,7 +206,7 @@ func (m *meter) Int64Histogram(name string, options ...metric.Int64HistogramOpti
cfg := metric.NewInt64HistogramConfig(options...)
id := instID{
name: name,
- kind: reflect.TypeOf((*siHistogram)(nil)),
+ kind: reflect.TypeFor[*siHistogram](),
description: cfg.Description(),
unit: cfg.Unit(),
}
@@ -229,7 +229,7 @@ func (m *meter) Int64Gauge(name string, options ...metric.Int64GaugeOption) (met
cfg := metric.NewInt64GaugeConfig(options...)
id := instID{
name: name,
- kind: reflect.TypeOf((*siGauge)(nil)),
+ kind: reflect.TypeFor[*siGauge](),
description: cfg.Description(),
unit: cfg.Unit(),
}
@@ -255,7 +255,7 @@ func (m *meter) Int64ObservableCounter(
cfg := metric.NewInt64ObservableCounterConfig(options...)
id := instID{
name: name,
- kind: reflect.TypeOf((*aiCounter)(nil)),
+ kind: reflect.TypeFor[*aiCounter](),
description: cfg.Description(),
unit: cfg.Unit(),
}
@@ -281,7 +281,7 @@ func (m *meter) Int64ObservableUpDownCounter(
cfg := metric.NewInt64ObservableUpDownCounterConfig(options...)
id := instID{
name: name,
- kind: reflect.TypeOf((*aiUpDownCounter)(nil)),
+ kind: reflect.TypeFor[*aiUpDownCounter](),
description: cfg.Description(),
unit: cfg.Unit(),
}
@@ -307,7 +307,7 @@ func (m *meter) Int64ObservableGauge(
cfg := metric.NewInt64ObservableGaugeConfig(options...)
id := instID{
name: name,
- kind: reflect.TypeOf((*aiGauge)(nil)),
+ kind: reflect.TypeFor[*aiGauge](),
description: cfg.Description(),
unit: cfg.Unit(),
}
@@ -330,7 +330,7 @@ func (m *meter) Float64Counter(name string, options ...metric.Float64CounterOpti
cfg := metric.NewFloat64CounterConfig(options...)
id := instID{
name: name,
- kind: reflect.TypeOf((*sfCounter)(nil)),
+ kind: reflect.TypeFor[*sfCounter](),
description: cfg.Description(),
unit: cfg.Unit(),
}
@@ -356,7 +356,7 @@ func (m *meter) Float64UpDownCounter(
cfg := metric.NewFloat64UpDownCounterConfig(options...)
id := instID{
name: name,
- kind: reflect.TypeOf((*sfUpDownCounter)(nil)),
+ kind: reflect.TypeFor[*sfUpDownCounter](),
description: cfg.Description(),
unit: cfg.Unit(),
}
@@ -382,7 +382,7 @@ func (m *meter) Float64Histogram(
cfg := metric.NewFloat64HistogramConfig(options...)
id := instID{
name: name,
- kind: reflect.TypeOf((*sfHistogram)(nil)),
+ kind: reflect.TypeFor[*sfHistogram](),
description: cfg.Description(),
unit: cfg.Unit(),
}
@@ -405,7 +405,7 @@ func (m *meter) Float64Gauge(name string, options ...metric.Float64GaugeOption)
cfg := metric.NewFloat64GaugeConfig(options...)
id := instID{
name: name,
- kind: reflect.TypeOf((*sfGauge)(nil)),
+ kind: reflect.TypeFor[*sfGauge](),
description: cfg.Description(),
unit: cfg.Unit(),
}
@@ -431,7 +431,7 @@ func (m *meter) Float64ObservableCounter(
cfg := metric.NewFloat64ObservableCounterConfig(options...)
id := instID{
name: name,
- kind: reflect.TypeOf((*afCounter)(nil)),
+ kind: reflect.TypeFor[*afCounter](),
description: cfg.Description(),
unit: cfg.Unit(),
}
@@ -457,7 +457,7 @@ func (m *meter) Float64ObservableUpDownCounter(
cfg := metric.NewFloat64ObservableUpDownCounterConfig(options...)
id := instID{
name: name,
- kind: reflect.TypeOf((*afUpDownCounter)(nil)),
+ kind: reflect.TypeFor[*afUpDownCounter](),
description: cfg.Description(),
unit: cfg.Unit(),
}
@@ -483,7 +483,7 @@ func (m *meter) Float64ObservableGauge(
cfg := metric.NewFloat64ObservableGaugeConfig(options...)
id := instID{
name: name,
- kind: reflect.TypeOf((*afGauge)(nil)),
+ kind: reflect.TypeFor[*afGauge](),
description: cfg.Description(),
unit: cfg.Unit(),
}
diff --git a/vendor/go.opentelemetry.io/otel/internal/global/state.go b/vendor/go.opentelemetry.io/otel/internal/global/state.go
index 204ea142a5..225c9e5015 100644
--- a/vendor/go.opentelemetry.io/otel/internal/global/state.go
+++ b/vendor/go.opentelemetry.io/otel/internal/global/state.go
@@ -8,16 +8,13 @@ import (
"sync"
"sync/atomic"
+ "go.opentelemetry.io/otel/internal/errorhandler"
"go.opentelemetry.io/otel/metric"
"go.opentelemetry.io/otel/propagation"
"go.opentelemetry.io/otel/trace"
)
type (
- errorHandlerHolder struct {
- eh ErrorHandler
- }
-
tracerProviderHolder struct {
tp trace.TracerProvider
}
@@ -32,12 +29,10 @@ type (
)
var (
- globalErrorHandler = defaultErrorHandler()
globalTracer = defaultTracerValue()
globalPropagators = defaultPropagatorsValue()
globalMeterProvider = defaultMeterProvider()
- delegateErrorHandlerOnce sync.Once
delegateTraceOnce sync.Once
delegateTextMapPropagatorOnce sync.Once
delegateMeterOnce sync.Once
@@ -53,7 +48,7 @@ var (
// Subsequent calls to SetErrorHandler after the first will not forward errors
// to the new ErrorHandler for prior returned instances.
func GetErrorHandler() ErrorHandler {
- return globalErrorHandler.Load().(errorHandlerHolder).eh
+ return errorhandler.GetErrorHandler()
}
// SetErrorHandler sets the global ErrorHandler to h.
@@ -63,26 +58,7 @@ func GetErrorHandler() ErrorHandler {
// ErrorHandler. Subsequent calls will set the global ErrorHandler, but not
// delegate errors to h.
func SetErrorHandler(h ErrorHandler) {
- current := GetErrorHandler()
-
- if _, cOk := current.(*ErrDelegator); cOk {
- if _, ehOk := h.(*ErrDelegator); ehOk && current == h {
- // Do not assign to the delegate of the default ErrDelegator to be
- // itself.
- Error(
- errors.New("no ErrorHandler delegate configured"),
- "ErrorHandler remains its current value.",
- )
- return
- }
- }
-
- delegateErrorHandlerOnce.Do(func() {
- if def, ok := current.(*ErrDelegator); ok {
- def.setDelegate(h)
- }
- })
- globalErrorHandler.Store(errorHandlerHolder{eh: h})
+ errorhandler.SetErrorHandler(h)
}
// TracerProvider is the internal implementation for global.TracerProvider.
@@ -174,12 +150,6 @@ func SetMeterProvider(mp metric.MeterProvider) {
globalMeterProvider.Store(meterProviderHolder{mp: mp})
}
-func defaultErrorHandler() *atomic.Value {
- v := &atomic.Value{}
- v.Store(errorHandlerHolder{eh: &ErrDelegator{}})
- return v
-}
-
func defaultTracerValue() *atomic.Value {
v := &atomic.Value{}
v.Store(tracerProviderHolder{tp: &tracerProvider{}})
diff --git a/vendor/go.opentelemetry.io/otel/internal/global/trace.go b/vendor/go.opentelemetry.io/otel/internal/global/trace.go
index 49e4ac4faa..bf5cf3119b 100644
--- a/vendor/go.opentelemetry.io/otel/internal/global/trace.go
+++ b/vendor/go.opentelemetry.io/otel/internal/global/trace.go
@@ -26,6 +26,7 @@ import (
"sync/atomic"
"go.opentelemetry.io/auto/sdk"
+
"go.opentelemetry.io/otel/attribute"
"go.opentelemetry.io/otel/codes"
"go.opentelemetry.io/otel/trace"
diff --git a/vendor/go.opentelemetry.io/otel/metric.go b/vendor/go.opentelemetry.io/otel/metric.go
index 1e6473b32f..527d9aec86 100644
--- a/vendor/go.opentelemetry.io/otel/metric.go
+++ b/vendor/go.opentelemetry.io/otel/metric.go
@@ -11,7 +11,7 @@ import (
// Meter returns a Meter from the global MeterProvider. The name must be the
// name of the library providing instrumentation. This name may be the same as
// the instrumented code only if that code provides built-in instrumentation.
-// If the name is empty, then a implementation defined default name will be
+// If the name is empty, then an implementation defined default name will be
// used instead.
//
// If this is called before a global MeterProvider is registered the returned
diff --git a/vendor/go.opentelemetry.io/otel/metric/LICENSE b/vendor/go.opentelemetry.io/otel/metric/LICENSE
index 261eeb9e9f..f1aee0f110 100644
--- a/vendor/go.opentelemetry.io/otel/metric/LICENSE
+++ b/vendor/go.opentelemetry.io/otel/metric/LICENSE
@@ -199,3 +199,33 @@
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
+
+--------------------------------------------------------------------------------
+
+Copyright 2009 The Go Authors.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are
+met:
+
+ * Redistributions of source code must retain the above copyright
+notice, this list of conditions and the following disclaimer.
+ * Redistributions in binary form must reproduce the above
+copyright notice, this list of conditions and the following disclaimer
+in the documentation and/or other materials provided with the
+distribution.
+ * Neither the name of Google LLC nor the names of its
+contributors may be used to endorse or promote products derived from
+this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
\ No newline at end of file
diff --git a/vendor/go.opentelemetry.io/otel/metric/asyncfloat64.go b/vendor/go.opentelemetry.io/otel/metric/asyncfloat64.go
index b7fc973a66..466812d343 100644
--- a/vendor/go.opentelemetry.io/otel/metric/asyncfloat64.go
+++ b/vendor/go.opentelemetry.io/otel/metric/asyncfloat64.go
@@ -211,6 +211,9 @@ type Float64Observer interface {
//
// Use the WithAttributeSet (or, if performance is not a concern,
// the WithAttributes) option to include measurement attributes.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
Observe(value float64, options ...ObserveOption)
}
@@ -227,7 +230,11 @@ type Float64Observer interface {
// attributes as another Float64Callbacks also registered for the same
// instrument.
//
-// The function needs to be concurrent safe.
+// The function needs to be reentrant and concurrent safe.
+//
+// Note that Go's mutexes are not reentrant, and locking a mutex takes
+// an indefinite amount of time. It is therefore advised to avoid
+// using mutexes inside callbacks.
type Float64Callback func(context.Context, Float64Observer) error
// Float64ObservableOption applies options to float64 Observer instruments.
diff --git a/vendor/go.opentelemetry.io/otel/metric/asyncint64.go b/vendor/go.opentelemetry.io/otel/metric/asyncint64.go
index 4404b71a22..66c971bd8a 100644
--- a/vendor/go.opentelemetry.io/otel/metric/asyncint64.go
+++ b/vendor/go.opentelemetry.io/otel/metric/asyncint64.go
@@ -210,6 +210,9 @@ type Int64Observer interface {
//
// Use the WithAttributeSet (or, if performance is not a concern,
// the WithAttributes) option to include measurement attributes.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
Observe(value int64, options ...ObserveOption)
}
@@ -225,7 +228,11 @@ type Int64Observer interface {
// attributes as another Int64Callbacks also registered for the same
// instrument.
//
-// The function needs to be concurrent safe.
+// The function needs to be reentrant and concurrent safe.
+//
+// Note that Go's mutexes are not reentrant, and locking a mutex takes
+// an indefinite amount of time. It is therefore advised to avoid
+// using mutexes inside callbacks.
type Int64Callback func(context.Context, Int64Observer) error
// Int64ObservableOption applies options to int64 Observer instruments.
diff --git a/vendor/go.opentelemetry.io/otel/metric/config.go b/vendor/go.opentelemetry.io/otel/metric/config.go
index d9e3b13e4d..e42dd6e70a 100644
--- a/vendor/go.opentelemetry.io/otel/metric/config.go
+++ b/vendor/go.opentelemetry.io/otel/metric/config.go
@@ -3,7 +3,11 @@
package metric // import "go.opentelemetry.io/otel/metric"
-import "go.opentelemetry.io/otel/attribute"
+import (
+ "slices"
+
+ "go.opentelemetry.io/otel/attribute"
+)
// MeterConfig contains options for Meters.
type MeterConfig struct {
@@ -62,12 +66,38 @@ func WithInstrumentationVersion(version string) MeterOption {
})
}
-// WithInstrumentationAttributes sets the instrumentation attributes.
+// WithInstrumentationAttributes adds the instrumentation attributes.
+//
+// This is equivalent to calling [WithInstrumentationAttributeSet] with an
+// [attribute.Set] created from a clone of the passed attributes.
+// [WithInstrumentationAttributeSet] is recommended for more control.
//
-// The passed attributes will be de-duplicated.
+// If multiple [WithInstrumentationAttributes] or [WithInstrumentationAttributeSet]
+// options are passed, the attributes will be merged together in the order
+// they are passed. Attributes with duplicate keys will use the last value passed.
func WithInstrumentationAttributes(attr ...attribute.KeyValue) MeterOption {
+ set := attribute.NewSet(slices.Clone(attr)...)
+ return WithInstrumentationAttributeSet(set)
+}
+
+// WithInstrumentationAttributeSet adds the instrumentation attributes.
+//
+// If multiple [WithInstrumentationAttributes] or [WithInstrumentationAttributeSet]
+// options are passed, the attributes will be merged together in the order
+// they are passed. Attributes with duplicate keys will use the last value passed.
+func WithInstrumentationAttributeSet(set attribute.Set) MeterOption {
+ if set.Len() == 0 {
+ return meterOptionFunc(func(config MeterConfig) MeterConfig {
+ return config
+ })
+ }
+
return meterOptionFunc(func(config MeterConfig) MeterConfig {
- config.attrs = attribute.NewSet(attr...)
+ if config.attrs.Len() == 0 {
+ config.attrs = set
+ } else {
+ config.attrs = mergeSets(config.attrs, set)
+ }
return config
})
}
diff --git a/vendor/go.opentelemetry.io/otel/metric/meter.go b/vendor/go.opentelemetry.io/otel/metric/meter.go
index fdd2a7011c..5606ec4bd9 100644
--- a/vendor/go.opentelemetry.io/otel/metric/meter.go
+++ b/vendor/go.opentelemetry.io/otel/metric/meter.go
@@ -30,6 +30,9 @@ type MeterProvider interface {
//
// If the name is empty, then an implementation defined default name will
// be used instead.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
Meter(name string, opts ...MeterOption) Meter
}
@@ -51,6 +54,9 @@ type Meter interface {
// The name needs to conform to the OpenTelemetry instrument name syntax.
// See the Instrument Name section of the package documentation for more
// information.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
Int64Counter(name string, options ...Int64CounterOption) (Int64Counter, error)
// Int64UpDownCounter returns a new Int64UpDownCounter instrument
@@ -61,6 +67,9 @@ type Meter interface {
// The name needs to conform to the OpenTelemetry instrument name syntax.
// See the Instrument Name section of the package documentation for more
// information.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
Int64UpDownCounter(name string, options ...Int64UpDownCounterOption) (Int64UpDownCounter, error)
// Int64Histogram returns a new Int64Histogram instrument identified by
@@ -71,6 +80,9 @@ type Meter interface {
// The name needs to conform to the OpenTelemetry instrument name syntax.
// See the Instrument Name section of the package documentation for more
// information.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
Int64Histogram(name string, options ...Int64HistogramOption) (Int64Histogram, error)
// Int64Gauge returns a new Int64Gauge instrument identified by name and
@@ -80,6 +92,9 @@ type Meter interface {
// The name needs to conform to the OpenTelemetry instrument name syntax.
// See the Instrument Name section of the package documentation for more
// information.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
Int64Gauge(name string, options ...Int64GaugeOption) (Int64Gauge, error)
// Int64ObservableCounter returns a new Int64ObservableCounter identified
@@ -95,6 +110,9 @@ type Meter interface {
// The name needs to conform to the OpenTelemetry instrument name syntax.
// See the Instrument Name section of the package documentation for more
// information.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
Int64ObservableCounter(name string, options ...Int64ObservableCounterOption) (Int64ObservableCounter, error)
// Int64ObservableUpDownCounter returns a new Int64ObservableUpDownCounter
@@ -110,6 +128,9 @@ type Meter interface {
// The name needs to conform to the OpenTelemetry instrument name syntax.
// See the Instrument Name section of the package documentation for more
// information.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
Int64ObservableUpDownCounter(
name string,
options ...Int64ObservableUpDownCounterOption,
@@ -128,6 +149,9 @@ type Meter interface {
// The name needs to conform to the OpenTelemetry instrument name syntax.
// See the Instrument Name section of the package documentation for more
// information.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
Int64ObservableGauge(name string, options ...Int64ObservableGaugeOption) (Int64ObservableGauge, error)
// Float64Counter returns a new Float64Counter instrument identified by
@@ -148,6 +172,9 @@ type Meter interface {
// The name needs to conform to the OpenTelemetry instrument name syntax.
// See the Instrument Name section of the package documentation for more
// information.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
Float64UpDownCounter(name string, options ...Float64UpDownCounterOption) (Float64UpDownCounter, error)
// Float64Histogram returns a new Float64Histogram instrument identified by
@@ -158,6 +185,9 @@ type Meter interface {
// The name needs to conform to the OpenTelemetry instrument name syntax.
// See the Instrument Name section of the package documentation for more
// information.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
Float64Histogram(name string, options ...Float64HistogramOption) (Float64Histogram, error)
// Float64Gauge returns a new Float64Gauge instrument identified by name and
@@ -167,6 +197,9 @@ type Meter interface {
// The name needs to conform to the OpenTelemetry instrument name syntax.
// See the Instrument Name section of the package documentation for more
// information.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
Float64Gauge(name string, options ...Float64GaugeOption) (Float64Gauge, error)
// Float64ObservableCounter returns a new Float64ObservableCounter
@@ -182,6 +215,9 @@ type Meter interface {
// The name needs to conform to the OpenTelemetry instrument name syntax.
// See the Instrument Name section of the package documentation for more
// information.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
Float64ObservableCounter(name string, options ...Float64ObservableCounterOption) (Float64ObservableCounter, error)
// Float64ObservableUpDownCounter returns a new
@@ -197,6 +233,9 @@ type Meter interface {
// The name needs to conform to the OpenTelemetry instrument name syntax.
// See the Instrument Name section of the package documentation for more
// information.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
Float64ObservableUpDownCounter(
name string,
options ...Float64ObservableUpDownCounterOption,
@@ -215,6 +254,9 @@ type Meter interface {
// The name needs to conform to the OpenTelemetry instrument name syntax.
// See the Instrument Name section of the package documentation for more
// information.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
Float64ObservableGauge(name string, options ...Float64ObservableGaugeOption) (Float64ObservableGauge, error)
// RegisterCallback registers f to be called during the collection of a
@@ -229,6 +271,9 @@ type Meter interface {
// If no instruments are passed, f should not be registered nor called
// during collection.
//
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
+ //
// The function f needs to be concurrent safe.
RegisterCallback(f Callback, instruments ...Observable) (Registration, error)
}
@@ -244,7 +289,11 @@ type Meter interface {
// Callbacks. Meaning, it should not report measurements for an instrument with
// the same attributes as another Callback will report.
//
-// The function needs to be concurrent safe.
+// The function needs to be reentrant and concurrent safe.
+//
+// Note that Go's mutexes are not reentrant, and locking a mutex takes
+// an indefinite amount of time. It is therefore advised to avoid
+// using mutexes inside callbacks.
type Callback func(context.Context, Observer) error
// Observer records measurements for multiple instruments in a Callback.
@@ -259,9 +308,15 @@ type Observer interface {
embedded.Observer
// ObserveFloat64 records the float64 value for obsrv.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
ObserveFloat64(obsrv Float64Observable, value float64, opts ...ObserveOption)
// ObserveInt64 records the int64 value for obsrv.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
ObserveInt64(obsrv Int64Observable, value int64, opts ...ObserveOption)
}
@@ -279,6 +334,7 @@ type Registration interface {
// Unregister removes the callback registration from a Meter.
//
- // This method needs to be idempotent and concurrent safe.
+ // Implementations of this method need to be idempotent and safe for a user
+ // to call concurrently.
Unregister() error
}
diff --git a/vendor/go.opentelemetry.io/otel/metric/noop/noop.go b/vendor/go.opentelemetry.io/otel/metric/noop/noop.go
index 9afb69e583..634e73aee0 100644
--- a/vendor/go.opentelemetry.io/otel/metric/noop/noop.go
+++ b/vendor/go.opentelemetry.io/otel/metric/noop/noop.go
@@ -191,6 +191,9 @@ type Int64Counter struct{ embedded.Int64Counter }
// Add performs no operation.
func (Int64Counter) Add(context.Context, int64, ...metric.AddOption) {}
+// Enabled performs no operation.
+func (Int64Counter) Enabled(context.Context) bool { return false }
+
// Float64Counter is an OpenTelemetry Counter used to record float64
// measurements. It produces no telemetry.
type Float64Counter struct{ embedded.Float64Counter }
@@ -198,6 +201,9 @@ type Float64Counter struct{ embedded.Float64Counter }
// Add performs no operation.
func (Float64Counter) Add(context.Context, float64, ...metric.AddOption) {}
+// Enabled performs no operation.
+func (Float64Counter) Enabled(context.Context) bool { return false }
+
// Int64UpDownCounter is an OpenTelemetry UpDownCounter used to record int64
// measurements. It produces no telemetry.
type Int64UpDownCounter struct{ embedded.Int64UpDownCounter }
@@ -205,6 +211,9 @@ type Int64UpDownCounter struct{ embedded.Int64UpDownCounter }
// Add performs no operation.
func (Int64UpDownCounter) Add(context.Context, int64, ...metric.AddOption) {}
+// Enabled performs no operation.
+func (Int64UpDownCounter) Enabled(context.Context) bool { return false }
+
// Float64UpDownCounter is an OpenTelemetry UpDownCounter used to record
// float64 measurements. It produces no telemetry.
type Float64UpDownCounter struct{ embedded.Float64UpDownCounter }
@@ -212,6 +221,9 @@ type Float64UpDownCounter struct{ embedded.Float64UpDownCounter }
// Add performs no operation.
func (Float64UpDownCounter) Add(context.Context, float64, ...metric.AddOption) {}
+// Enabled performs no operation.
+func (Float64UpDownCounter) Enabled(context.Context) bool { return false }
+
// Int64Histogram is an OpenTelemetry Histogram used to record int64
// measurements. It produces no telemetry.
type Int64Histogram struct{ embedded.Int64Histogram }
@@ -219,6 +231,9 @@ type Int64Histogram struct{ embedded.Int64Histogram }
// Record performs no operation.
func (Int64Histogram) Record(context.Context, int64, ...metric.RecordOption) {}
+// Enabled performs no operation.
+func (Int64Histogram) Enabled(context.Context) bool { return false }
+
// Float64Histogram is an OpenTelemetry Histogram used to record float64
// measurements. It produces no telemetry.
type Float64Histogram struct{ embedded.Float64Histogram }
@@ -226,6 +241,9 @@ type Float64Histogram struct{ embedded.Float64Histogram }
// Record performs no operation.
func (Float64Histogram) Record(context.Context, float64, ...metric.RecordOption) {}
+// Enabled performs no operation.
+func (Float64Histogram) Enabled(context.Context) bool { return false }
+
// Int64Gauge is an OpenTelemetry Gauge used to record instantaneous int64
// measurements. It produces no telemetry.
type Int64Gauge struct{ embedded.Int64Gauge }
@@ -233,6 +251,9 @@ type Int64Gauge struct{ embedded.Int64Gauge }
// Record performs no operation.
func (Int64Gauge) Record(context.Context, int64, ...metric.RecordOption) {}
+// Enabled performs no operation.
+func (Int64Gauge) Enabled(context.Context) bool { return false }
+
// Float64Gauge is an OpenTelemetry Gauge used to record instantaneous float64
// measurements. It produces no telemetry.
type Float64Gauge struct{ embedded.Float64Gauge }
@@ -240,6 +261,9 @@ type Float64Gauge struct{ embedded.Float64Gauge }
// Record performs no operation.
func (Float64Gauge) Record(context.Context, float64, ...metric.RecordOption) {}
+// Enabled performs no operation.
+func (Float64Gauge) Enabled(context.Context) bool { return false }
+
// Int64ObservableCounter is an OpenTelemetry ObservableCounter used to record
// int64 measurements. It produces no telemetry.
type Int64ObservableCounter struct {
diff --git a/vendor/go.opentelemetry.io/otel/metric/syncfloat64.go b/vendor/go.opentelemetry.io/otel/metric/syncfloat64.go
index 8403a4bad2..abb3051d7f 100644
--- a/vendor/go.opentelemetry.io/otel/metric/syncfloat64.go
+++ b/vendor/go.opentelemetry.io/otel/metric/syncfloat64.go
@@ -24,7 +24,19 @@ type Float64Counter interface {
//
// Use the WithAttributeSet (or, if performance is not a concern,
// the WithAttributes) option to include measurement attributes.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
Add(ctx context.Context, incr float64, options ...AddOption)
+
+ // Enabled reports whether the instrument will process measurements for the given context.
+ //
+ // This function can be used in places where measuring an instrument
+ // would result in computationally expensive operations.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
+ Enabled(context.Context) bool
}
// Float64CounterConfig contains options for synchronous counter instruments that
@@ -77,7 +89,19 @@ type Float64UpDownCounter interface {
//
// Use the WithAttributeSet (or, if performance is not a concern,
// the WithAttributes) option to include measurement attributes.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
Add(ctx context.Context, incr float64, options ...AddOption)
+
+ // Enabled reports whether the instrument will process measurements for the given context.
+ //
+ // This function can be used in places where measuring an instrument
+ // would result in computationally expensive operations.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
+ Enabled(context.Context) bool
}
// Float64UpDownCounterConfig contains options for synchronous counter
@@ -130,7 +154,19 @@ type Float64Histogram interface {
//
// Use the WithAttributeSet (or, if performance is not a concern,
// the WithAttributes) option to include measurement attributes.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
Record(ctx context.Context, incr float64, options ...RecordOption)
+
+ // Enabled reports whether the instrument will process measurements for the given context.
+ //
+ // This function can be used in places where measuring an instrument
+ // would result in computationally expensive operations.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
+ Enabled(context.Context) bool
}
// Float64HistogramConfig contains options for synchronous histogram
@@ -188,7 +224,19 @@ type Float64Gauge interface {
//
// Use the WithAttributeSet (or, if performance is not a concern,
// the WithAttributes) option to include measurement attributes.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
Record(ctx context.Context, value float64, options ...RecordOption)
+
+ // Enabled reports whether the instrument will process measurements for the given context.
+ //
+ // This function can be used in places where measuring an instrument
+ // would result in computationally expensive operations.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
+ Enabled(context.Context) bool
}
// Float64GaugeConfig contains options for synchronous gauge instruments that
diff --git a/vendor/go.opentelemetry.io/otel/metric/syncint64.go b/vendor/go.opentelemetry.io/otel/metric/syncint64.go
index 783fdfba77..5bbfaf0397 100644
--- a/vendor/go.opentelemetry.io/otel/metric/syncint64.go
+++ b/vendor/go.opentelemetry.io/otel/metric/syncint64.go
@@ -24,7 +24,19 @@ type Int64Counter interface {
//
// Use the WithAttributeSet (or, if performance is not a concern,
// the WithAttributes) option to include measurement attributes.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
Add(ctx context.Context, incr int64, options ...AddOption)
+
+ // Enabled reports whether the instrument will process measurements for the given context.
+ //
+ // This function can be used in places where measuring an instrument
+ // would result in computationally expensive operations.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
+ Enabled(context.Context) bool
}
// Int64CounterConfig contains options for synchronous counter instruments that
@@ -77,7 +89,19 @@ type Int64UpDownCounter interface {
//
// Use the WithAttributeSet (or, if performance is not a concern,
// the WithAttributes) option to include measurement attributes.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
Add(ctx context.Context, incr int64, options ...AddOption)
+
+ // Enabled reports whether the instrument will process measurements for the given context.
+ //
+ // This function can be used in places where measuring an instrument
+ // would result in computationally expensive operations.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
+ Enabled(context.Context) bool
}
// Int64UpDownCounterConfig contains options for synchronous counter
@@ -130,7 +154,19 @@ type Int64Histogram interface {
//
// Use the WithAttributeSet (or, if performance is not a concern,
// the WithAttributes) option to include measurement attributes.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
Record(ctx context.Context, incr int64, options ...RecordOption)
+
+ // Enabled reports whether the instrument will process measurements for the given context.
+ //
+ // This function can be used in places where measuring an instrument
+ // would result in computationally expensive operations.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
+ Enabled(context.Context) bool
}
// Int64HistogramConfig contains options for synchronous histogram instruments
@@ -188,7 +224,19 @@ type Int64Gauge interface {
//
// Use the WithAttributeSet (or, if performance is not a concern,
// the WithAttributes) option to include measurement attributes.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
Record(ctx context.Context, value int64, options ...RecordOption)
+
+ // Enabled reports whether the instrument will process measurements for the given context.
+ //
+ // This function can be used in places where measuring an instrument
+ // would result in computationally expensive operations.
+ //
+ // Implementations of this method need to be safe for a user to call
+ // concurrently.
+ Enabled(context.Context) bool
}
// Int64GaugeConfig contains options for synchronous gauge instruments that
diff --git a/vendor/go.opentelemetry.io/otel/propagation/baggage.go b/vendor/go.opentelemetry.io/otel/propagation/baggage.go
index ebda5026d6..2ecca3fed1 100644
--- a/vendor/go.opentelemetry.io/otel/propagation/baggage.go
+++ b/vendor/go.opentelemetry.io/otel/propagation/baggage.go
@@ -7,9 +7,16 @@ import (
"context"
"go.opentelemetry.io/otel/baggage"
+ "go.opentelemetry.io/otel/internal/errorhandler"
)
-const baggageHeader = "baggage"
+const (
+ baggageHeader = "baggage"
+
+ // W3C Baggage specification limits.
+ // https://www.w3.org/TR/baggage/#limits
+ maxMembers = 64
+)
// Baggage is a propagator that supports the W3C Baggage format.
//
@@ -20,7 +27,7 @@ type Baggage struct{}
var _ TextMapPropagator = Baggage{}
// Inject sets baggage key-values from ctx into the carrier.
-func (b Baggage) Inject(ctx context.Context, carrier TextMapCarrier) {
+func (Baggage) Inject(ctx context.Context, carrier TextMapCarrier) {
bStr := baggage.FromContext(ctx).String()
if bStr != "" {
carrier.Set(baggageHeader, bStr)
@@ -30,7 +37,7 @@ func (b Baggage) Inject(ctx context.Context, carrier TextMapCarrier) {
// Extract returns a copy of parent with the baggage from the carrier added.
// If carrier implements [ValuesGetter] (e.g. [HeaderCarrier]), Values is invoked
// for multiple values extraction. Otherwise, Get is called.
-func (b Baggage) Extract(parent context.Context, carrier TextMapCarrier) context.Context {
+func (Baggage) Extract(parent context.Context, carrier TextMapCarrier) context.Context {
if multiCarrier, ok := carrier.(ValuesGetter); ok {
return extractMultiBaggage(parent, multiCarrier)
}
@@ -38,7 +45,7 @@ func (b Baggage) Extract(parent context.Context, carrier TextMapCarrier) context
}
// Fields returns the keys who's values are set with Inject.
-func (b Baggage) Fields() []string {
+func (Baggage) Fields() []string {
return []string{baggageHeader}
}
@@ -50,6 +57,9 @@ func extractSingleBaggage(parent context.Context, carrier TextMapCarrier) contex
bag, err := baggage.Parse(bStr)
if err != nil {
+ errorhandler.GetErrorHandler().Handle(err)
+ }
+ if bag.Len() == 0 {
return parent
}
return baggage.ContextWithBaggage(parent, bag)
@@ -60,17 +70,27 @@ func extractMultiBaggage(parent context.Context, carrier ValuesGetter) context.C
if len(bVals) == 0 {
return parent
}
+
var members []baggage.Member
for _, bStr := range bVals {
currBag, err := baggage.Parse(bStr)
if err != nil {
+ errorhandler.GetErrorHandler().Handle(err)
+ }
+ if currBag.Len() == 0 {
continue
}
members = append(members, currBag.Members()...)
+ if len(members) >= maxMembers {
+ break
+ }
}
b, err := baggage.New(members...)
- if err != nil || b.Len() == 0 {
+ if err != nil {
+ errorhandler.GetErrorHandler().Handle(err)
+ }
+ if b.Len() == 0 {
return parent
}
return baggage.ContextWithBaggage(parent, b)
diff --git a/vendor/go.opentelemetry.io/otel/propagation/propagation.go b/vendor/go.opentelemetry.io/otel/propagation/propagation.go
index 5c8c26ea2e..0a32c59aa3 100644
--- a/vendor/go.opentelemetry.io/otel/propagation/propagation.go
+++ b/vendor/go.opentelemetry.io/otel/propagation/propagation.go
@@ -20,7 +20,7 @@ type TextMapCarrier interface {
// must never be done outside of a new major release.
// Set stores the key-value pair.
- Set(key string, value string)
+ Set(key, value string)
// DO NOT CHANGE: any modification will not be backwards compatible and
// must never be done outside of a new major release.
@@ -88,7 +88,7 @@ func (hc HeaderCarrier) Values(key string) []string {
}
// Set stores the key-value pair.
-func (hc HeaderCarrier) Set(key string, value string) {
+func (hc HeaderCarrier) Set(key, value string) {
http.Header(hc).Set(key, value)
}
diff --git a/vendor/go.opentelemetry.io/otel/propagation/trace_context.go b/vendor/go.opentelemetry.io/otel/propagation/trace_context.go
index 6870e316dc..271ab71f1a 100644
--- a/vendor/go.opentelemetry.io/otel/propagation/trace_context.go
+++ b/vendor/go.opentelemetry.io/otel/propagation/trace_context.go
@@ -36,7 +36,7 @@ var (
)
// Inject injects the trace context from ctx into carrier.
-func (tc TraceContext) Inject(ctx context.Context, carrier TextMapCarrier) {
+func (TraceContext) Inject(ctx context.Context, carrier TextMapCarrier) {
sc := trace.SpanContextFromContext(ctx)
if !sc.IsValid() {
return
@@ -77,7 +77,7 @@ func (tc TraceContext) Extract(ctx context.Context, carrier TextMapCarrier) cont
return trace.ContextWithRemoteSpanContext(ctx, sc)
}
-func (tc TraceContext) extract(carrier TextMapCarrier) trace.SpanContext {
+func (TraceContext) extract(carrier TextMapCarrier) trace.SpanContext {
h := carrier.Get(traceparentHeader)
if h == "" {
return trace.SpanContext{}
@@ -111,7 +111,7 @@ func (tc TraceContext) extract(carrier TextMapCarrier) trace.SpanContext {
}
// Clear all flags other than the trace-context supported sampling bit.
- scc.TraceFlags = trace.TraceFlags(opts[0]) & trace.FlagsSampled
+ scc.TraceFlags = trace.TraceFlags(opts[0]) & trace.FlagsSampled // nolint:gosec // slice size already checked.
// Ignore the error returned here. Failure to parse tracestate MUST NOT
// affect the parsing of traceparent according to the W3C tracecontext
@@ -151,6 +151,6 @@ func extractPart(dst []byte, h *string, n int) bool {
}
// Fields returns the keys who's values are set with Inject.
-func (tc TraceContext) Fields() []string {
+func (TraceContext) Fields() []string {
return []string{traceparentHeader, tracestateHeader}
}
diff --git a/vendor/go.opentelemetry.io/otel/sdk/LICENSE b/vendor/go.opentelemetry.io/otel/sdk/LICENSE
index 261eeb9e9f..f1aee0f110 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/LICENSE
+++ b/vendor/go.opentelemetry.io/otel/sdk/LICENSE
@@ -199,3 +199,33 @@
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
+
+--------------------------------------------------------------------------------
+
+Copyright 2009 The Go Authors.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are
+met:
+
+ * Redistributions of source code must retain the above copyright
+notice, this list of conditions and the following disclaimer.
+ * Redistributions in binary form must reproduce the above
+copyright notice, this list of conditions and the following disclaimer
+in the documentation and/or other materials provided with the
+distribution.
+ * Neither the name of Google LLC nor the names of its
+contributors may be used to endorse or promote products derived from
+this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
\ No newline at end of file
diff --git a/vendor/go.opentelemetry.io/otel/sdk/internal/env/env.go b/vendor/go.opentelemetry.io/otel/sdk/internal/env/env.go
deleted file mode 100644
index e3309231d4..0000000000
--- a/vendor/go.opentelemetry.io/otel/sdk/internal/env/env.go
+++ /dev/null
@@ -1,168 +0,0 @@
-// Copyright The OpenTelemetry Authors
-// SPDX-License-Identifier: Apache-2.0
-
-// Package env provides types and functionality for environment variable support
-// in the OpenTelemetry SDK.
-package env // import "go.opentelemetry.io/otel/sdk/internal/env"
-
-import (
- "os"
- "strconv"
-
- "go.opentelemetry.io/otel/internal/global"
-)
-
-// Environment variable names.
-const (
- // BatchSpanProcessorScheduleDelayKey is the delay interval between two
- // consecutive exports (i.e. 5000).
- BatchSpanProcessorScheduleDelayKey = "OTEL_BSP_SCHEDULE_DELAY"
- // BatchSpanProcessorExportTimeoutKey is the maximum allowed time to
- // export data (i.e. 3000).
- BatchSpanProcessorExportTimeoutKey = "OTEL_BSP_EXPORT_TIMEOUT"
- // BatchSpanProcessorMaxQueueSizeKey is the maximum queue size (i.e. 2048).
- BatchSpanProcessorMaxQueueSizeKey = "OTEL_BSP_MAX_QUEUE_SIZE"
- // BatchSpanProcessorMaxExportBatchSizeKey is the maximum batch size (i.e.
- // 512). Note: it must be less than or equal to
- // BatchSpanProcessorMaxQueueSize.
- BatchSpanProcessorMaxExportBatchSizeKey = "OTEL_BSP_MAX_EXPORT_BATCH_SIZE"
-
- // AttributeValueLengthKey is the maximum allowed attribute value size.
- AttributeValueLengthKey = "OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT"
-
- // AttributeCountKey is the maximum allowed span attribute count.
- AttributeCountKey = "OTEL_ATTRIBUTE_COUNT_LIMIT"
-
- // SpanAttributeValueLengthKey is the maximum allowed attribute value size
- // for a span.
- SpanAttributeValueLengthKey = "OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT"
-
- // SpanAttributeCountKey is the maximum allowed span attribute count for a
- // span.
- SpanAttributeCountKey = "OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT"
-
- // SpanEventCountKey is the maximum allowed span event count.
- SpanEventCountKey = "OTEL_SPAN_EVENT_COUNT_LIMIT"
-
- // SpanEventAttributeCountKey is the maximum allowed attribute per span
- // event count.
- SpanEventAttributeCountKey = "OTEL_EVENT_ATTRIBUTE_COUNT_LIMIT"
-
- // SpanLinkCountKey is the maximum allowed span link count.
- SpanLinkCountKey = "OTEL_SPAN_LINK_COUNT_LIMIT"
-
- // SpanLinkAttributeCountKey is the maximum allowed attribute per span
- // link count.
- SpanLinkAttributeCountKey = "OTEL_LINK_ATTRIBUTE_COUNT_LIMIT"
-)
-
-// firstInt returns the value of the first matching environment variable from
-// keys. If the value is not an integer or no match is found, defaultValue is
-// returned.
-func firstInt(defaultValue int, keys ...string) int {
- for _, key := range keys {
- value := os.Getenv(key)
- if value == "" {
- continue
- }
-
- intValue, err := strconv.Atoi(value)
- if err != nil {
- global.Info("Got invalid value, number value expected.", key, value)
- return defaultValue
- }
-
- return intValue
- }
-
- return defaultValue
-}
-
-// IntEnvOr returns the int value of the environment variable with name key if
-// it exists, it is not empty, and the value is an int. Otherwise, defaultValue is returned.
-func IntEnvOr(key string, defaultValue int) int {
- value := os.Getenv(key)
- if value == "" {
- return defaultValue
- }
-
- intValue, err := strconv.Atoi(value)
- if err != nil {
- global.Info("Got invalid value, number value expected.", key, value)
- return defaultValue
- }
-
- return intValue
-}
-
-// BatchSpanProcessorScheduleDelay returns the environment variable value for
-// the OTEL_BSP_SCHEDULE_DELAY key if it exists, otherwise defaultValue is
-// returned.
-func BatchSpanProcessorScheduleDelay(defaultValue int) int {
- return IntEnvOr(BatchSpanProcessorScheduleDelayKey, defaultValue)
-}
-
-// BatchSpanProcessorExportTimeout returns the environment variable value for
-// the OTEL_BSP_EXPORT_TIMEOUT key if it exists, otherwise defaultValue is
-// returned.
-func BatchSpanProcessorExportTimeout(defaultValue int) int {
- return IntEnvOr(BatchSpanProcessorExportTimeoutKey, defaultValue)
-}
-
-// BatchSpanProcessorMaxQueueSize returns the environment variable value for
-// the OTEL_BSP_MAX_QUEUE_SIZE key if it exists, otherwise defaultValue is
-// returned.
-func BatchSpanProcessorMaxQueueSize(defaultValue int) int {
- return IntEnvOr(BatchSpanProcessorMaxQueueSizeKey, defaultValue)
-}
-
-// BatchSpanProcessorMaxExportBatchSize returns the environment variable value for
-// the OTEL_BSP_MAX_EXPORT_BATCH_SIZE key if it exists, otherwise defaultValue
-// is returned.
-func BatchSpanProcessorMaxExportBatchSize(defaultValue int) int {
- return IntEnvOr(BatchSpanProcessorMaxExportBatchSizeKey, defaultValue)
-}
-
-// SpanAttributeValueLength returns the environment variable value for the
-// OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT key if it exists. Otherwise, the
-// environment variable value for OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT is
-// returned or defaultValue if that is not set.
-func SpanAttributeValueLength(defaultValue int) int {
- return firstInt(defaultValue, SpanAttributeValueLengthKey, AttributeValueLengthKey)
-}
-
-// SpanAttributeCount returns the environment variable value for the
-// OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT key if it exists. Otherwise, the
-// environment variable value for OTEL_ATTRIBUTE_COUNT_LIMIT is returned or
-// defaultValue if that is not set.
-func SpanAttributeCount(defaultValue int) int {
- return firstInt(defaultValue, SpanAttributeCountKey, AttributeCountKey)
-}
-
-// SpanEventCount returns the environment variable value for the
-// OTEL_SPAN_EVENT_COUNT_LIMIT key if it exists, otherwise defaultValue is
-// returned.
-func SpanEventCount(defaultValue int) int {
- return IntEnvOr(SpanEventCountKey, defaultValue)
-}
-
-// SpanEventAttributeCount returns the environment variable value for the
-// OTEL_EVENT_ATTRIBUTE_COUNT_LIMIT key if it exists, otherwise defaultValue
-// is returned.
-func SpanEventAttributeCount(defaultValue int) int {
- return IntEnvOr(SpanEventAttributeCountKey, defaultValue)
-}
-
-// SpanLinkCount returns the environment variable value for the
-// OTEL_SPAN_LINK_COUNT_LIMIT key if it exists, otherwise defaultValue is
-// returned.
-func SpanLinkCount(defaultValue int) int {
- return IntEnvOr(SpanLinkCountKey, defaultValue)
-}
-
-// SpanLinkAttributeCount returns the environment variable value for the
-// OTEL_LINK_ATTRIBUTE_COUNT_LIMIT key if it exists, otherwise defaultValue is
-// returned.
-func SpanLinkAttributeCount(defaultValue int) int {
- return IntEnvOr(SpanLinkAttributeCountKey, defaultValue)
-}
diff --git a/vendor/go.opentelemetry.io/otel/sdk/internal/x/features.go b/vendor/go.opentelemetry.io/otel/sdk/internal/x/features.go
new file mode 100644
index 0000000000..bfeb73e811
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/sdk/internal/x/features.go
@@ -0,0 +1,39 @@
+// Copyright The OpenTelemetry Authors
+// SPDX-License-Identifier: Apache-2.0
+
+// Package x documents experimental features for [go.opentelemetry.io/otel/sdk].
+package x // import "go.opentelemetry.io/otel/sdk/internal/x"
+
+import "strings"
+
+// Resource is an experimental feature flag that defines if resource detectors
+// should be included experimental semantic conventions.
+//
+// To enable this feature set the OTEL_GO_X_RESOURCE environment variable
+// to the case-insensitive string value of "true" (i.e. "True" and "TRUE"
+// will also enable this).
+var Resource = newFeature(
+ []string{"RESOURCE"},
+ func(v string) (string, bool) {
+ if strings.EqualFold(v, "true") {
+ return v, true
+ }
+ return "", false
+ },
+)
+
+// Observability is an experimental feature flag that determines if SDK
+// observability metrics are enabled.
+//
+// To enable this feature set the OTEL_GO_X_OBSERVABILITY environment variable
+// to the case-insensitive string value of "true" (i.e. "True" and "TRUE"
+// will also enable this).
+var Observability = newFeature(
+ []string{"OBSERVABILITY", "SELF_OBSERVABILITY"},
+ func(v string) (string, bool) {
+ if strings.EqualFold(v, "true") {
+ return v, true
+ }
+ return "", false
+ },
+)
diff --git a/vendor/go.opentelemetry.io/otel/sdk/internal/x/x.go b/vendor/go.opentelemetry.io/otel/sdk/internal/x/x.go
index 68d296cbed..13347e5605 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/internal/x/x.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/internal/x/x.go
@@ -1,48 +1,38 @@
+// Code generated by gotmpl. DO NOT MODIFY.
+// source: internal/shared/x/x.go.tmpl
+
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0
-// Package x contains support for OTel SDK experimental features.
-//
-// This package should only be used for features defined in the specification.
-// It should not be used for experiments or new project ideas.
+// Package x documents experimental features for [go.opentelemetry.io/otel/sdk].
package x // import "go.opentelemetry.io/otel/sdk/internal/x"
import (
"os"
- "strings"
)
-// Resource is an experimental feature flag that defines if resource detectors
-// should be included experimental semantic conventions.
-//
-// To enable this feature set the OTEL_GO_X_RESOURCE environment variable
-// to the case-insensitive string value of "true" (i.e. "True" and "TRUE"
-// will also enable this).
-var Resource = newFeature("RESOURCE", func(v string) (string, bool) {
- if strings.ToLower(v) == "true" {
- return v, true
- }
- return "", false
-})
-
// Feature is an experimental feature control flag. It provides a uniform way
// to interact with these feature flags and parse their values.
type Feature[T any] struct {
- key string
+ keys []string
parse func(v string) (T, bool)
}
-func newFeature[T any](suffix string, parse func(string) (T, bool)) Feature[T] {
+func newFeature[T any](suffix []string, parse func(string) (T, bool)) Feature[T] {
const envKeyRoot = "OTEL_GO_X_"
+ keys := make([]string, 0, len(suffix))
+ for _, s := range suffix {
+ keys = append(keys, envKeyRoot+s)
+ }
return Feature[T]{
- key: envKeyRoot + suffix,
+ keys: keys,
parse: parse,
}
}
-// Key returns the environment variable key that needs to be set to enable the
+// Keys returns the environment variable keys that can be set to enable the
// feature.
-func (f Feature[T]) Key() string { return f.key }
+func (f Feature[T]) Keys() []string { return f.keys }
// Lookup returns the user configured value for the feature and true if the
// user has enabled the feature. Otherwise, if the feature is not enabled, a
@@ -52,14 +42,16 @@ func (f Feature[T]) Lookup() (v T, ok bool) {
//
// > The SDK MUST interpret an empty value of an environment variable the
// > same way as when the variable is unset.
- vRaw := os.Getenv(f.key)
- if vRaw == "" {
- return v, ok
+ for _, key := range f.keys {
+ vRaw := os.Getenv(key)
+ if vRaw != "" {
+ return f.parse(vRaw)
+ }
}
- return f.parse(vRaw)
+ return v, ok
}
-// Enabled returns if the feature is enabled.
+// Enabled reports whether the feature is enabled.
func (f Feature[T]) Enabled() bool {
_, ok := f.Lookup()
return ok
diff --git a/vendor/go.opentelemetry.io/otel/sdk/resource/builtin.go b/vendor/go.opentelemetry.io/otel/sdk/resource/builtin.go
index cf3c88e15c..8a7bb330bf 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/resource/builtin.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/resource/builtin.go
@@ -13,7 +13,7 @@ import (
"go.opentelemetry.io/otel/attribute"
"go.opentelemetry.io/otel/sdk"
- semconv "go.opentelemetry.io/otel/semconv/v1.26.0"
+ semconv "go.opentelemetry.io/otel/semconv/v1.39.0"
)
type (
@@ -72,7 +72,7 @@ func StringDetector(schemaURL string, k attribute.Key, f func() (string, error))
// Detect returns a *Resource that describes the string as a value
// corresponding to attribute.Key as well as the specific schemaURL.
-func (sd stringDetector) Detect(ctx context.Context) (*Resource, error) {
+func (sd stringDetector) Detect(context.Context) (*Resource, error) {
value, err := sd.F()
if err != nil {
return nil, fmt.Errorf("%s: %w", string(sd.K), err)
diff --git a/vendor/go.opentelemetry.io/otel/sdk/resource/container.go b/vendor/go.opentelemetry.io/otel/sdk/resource/container.go
index 5ecd859a52..a19b39def8 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/resource/container.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/resource/container.go
@@ -11,7 +11,7 @@ import (
"os"
"regexp"
- semconv "go.opentelemetry.io/otel/semconv/v1.26.0"
+ semconv "go.opentelemetry.io/otel/semconv/v1.39.0"
)
type containerIDProvider func() (string, error)
@@ -27,7 +27,7 @@ const cgroupPath = "/proc/self/cgroup"
// Detect returns a *Resource that describes the id of the container.
// If no container id found, an empty resource will be returned.
-func (cgroupContainerIDDetector) Detect(ctx context.Context) (*Resource, error) {
+func (cgroupContainerIDDetector) Detect(context.Context) (*Resource, error) {
containerID, err := containerID()
if err != nil {
return nil, err
diff --git a/vendor/go.opentelemetry.io/otel/sdk/resource/env.go b/vendor/go.opentelemetry.io/otel/sdk/resource/env.go
index 813f056242..c49157224e 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/resource/env.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/resource/env.go
@@ -12,7 +12,7 @@ import (
"go.opentelemetry.io/otel"
"go.opentelemetry.io/otel/attribute"
- semconv "go.opentelemetry.io/otel/semconv/v1.26.0"
+ semconv "go.opentelemetry.io/otel/semconv/v1.39.0"
)
const (
diff --git a/vendor/go.opentelemetry.io/otel/sdk/resource/host_id.go b/vendor/go.opentelemetry.io/otel/sdk/resource/host_id.go
index 2d0f65498a..023621ba76 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/resource/host_id.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/resource/host_id.go
@@ -8,7 +8,7 @@ import (
"errors"
"strings"
- semconv "go.opentelemetry.io/otel/semconv/v1.26.0"
+ semconv "go.opentelemetry.io/otel/semconv/v1.39.0"
)
type hostIDProvider func() (string, error)
@@ -51,17 +51,16 @@ type hostIDReaderDarwin struct {
execCommand commandExecutor
}
-// read executes `ioreg -rd1 -c "IOPlatformExpertDevice"` and parses host id
+// read executes `/usr/sbin/ioreg -rd1 -c "IOPlatformExpertDevice"` and parses host id
// from the IOPlatformUUID line. If the command fails or the uuid cannot be
// parsed an error will be returned.
func (r *hostIDReaderDarwin) read() (string, error) {
- result, err := r.execCommand("ioreg", "-rd1", "-c", "IOPlatformExpertDevice")
+ result, err := r.execCommand("/usr/sbin/ioreg", "-rd1", "-c", "IOPlatformExpertDevice")
if err != nil {
return "", err
}
- lines := strings.Split(result, "\n")
- for _, line := range lines {
+ for line := range strings.SplitSeq(result, "\n") {
if strings.Contains(line, "IOPlatformUUID") {
parts := strings.Split(line, " = ")
if len(parts) == 2 {
@@ -96,7 +95,7 @@ func (r *hostIDReaderLinux) read() (string, error) {
type hostIDDetector struct{}
// Detect returns a *Resource containing the platform specific host id.
-func (hostIDDetector) Detect(ctx context.Context) (*Resource, error) {
+func (hostIDDetector) Detect(context.Context) (*Resource, error) {
hostID, err := hostID()
if err != nil {
return nil, err
diff --git a/vendor/go.opentelemetry.io/otel/sdk/resource/host_id_bsd.go b/vendor/go.opentelemetry.io/otel/sdk/resource/host_id_bsd.go
index cc8b8938ed..4c1c30f256 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/resource/host_id_bsd.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/resource/host_id_bsd.go
@@ -2,7 +2,6 @@
// SPDX-License-Identifier: Apache-2.0
//go:build dragonfly || freebsd || netbsd || openbsd || solaris
-// +build dragonfly freebsd netbsd openbsd solaris
package resource // import "go.opentelemetry.io/otel/sdk/resource"
diff --git a/vendor/go.opentelemetry.io/otel/sdk/resource/host_id_linux.go b/vendor/go.opentelemetry.io/otel/sdk/resource/host_id_linux.go
index f84f173240..4a26096c8d 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/resource/host_id_linux.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/resource/host_id_linux.go
@@ -2,7 +2,6 @@
// SPDX-License-Identifier: Apache-2.0
//go:build linux
-// +build linux
package resource // import "go.opentelemetry.io/otel/sdk/resource"
diff --git a/vendor/go.opentelemetry.io/otel/sdk/resource/host_id_unsupported.go b/vendor/go.opentelemetry.io/otel/sdk/resource/host_id_unsupported.go
index df12c44c56..63ad2fa4e0 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/resource/host_id_unsupported.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/resource/host_id_unsupported.go
@@ -2,7 +2,6 @@
// SPDX-License-Identifier: Apache-2.0
//go:build !darwin && !dragonfly && !freebsd && !linux && !netbsd && !openbsd && !solaris && !windows
-// +build !darwin,!dragonfly,!freebsd,!linux,!netbsd,!openbsd,!solaris,!windows
package resource // import "go.opentelemetry.io/otel/sdk/resource"
diff --git a/vendor/go.opentelemetry.io/otel/sdk/resource/host_id_windows.go b/vendor/go.opentelemetry.io/otel/sdk/resource/host_id_windows.go
index 3677c83d7d..2b8ca20b38 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/resource/host_id_windows.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/resource/host_id_windows.go
@@ -2,7 +2,6 @@
// SPDX-License-Identifier: Apache-2.0
//go:build windows
-// +build windows
package resource // import "go.opentelemetry.io/otel/sdk/resource"
diff --git a/vendor/go.opentelemetry.io/otel/sdk/resource/os.go b/vendor/go.opentelemetry.io/otel/sdk/resource/os.go
index 8a48ab4fa3..534809e217 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/resource/os.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/resource/os.go
@@ -8,7 +8,7 @@ import (
"strings"
"go.opentelemetry.io/otel/attribute"
- semconv "go.opentelemetry.io/otel/semconv/v1.26.0"
+ semconv "go.opentelemetry.io/otel/semconv/v1.39.0"
)
type osDescriptionProvider func() (string, error)
@@ -32,7 +32,7 @@ type (
// Detect returns a *Resource that describes the operating system type the
// service is running on.
-func (osTypeDetector) Detect(ctx context.Context) (*Resource, error) {
+func (osTypeDetector) Detect(context.Context) (*Resource, error) {
osType := runtimeOS()
osTypeAttribute := mapRuntimeOSToSemconvOSType(osType)
@@ -45,7 +45,7 @@ func (osTypeDetector) Detect(ctx context.Context) (*Resource, error) {
// Detect returns a *Resource that describes the operating system the
// service is running on.
-func (osDescriptionDetector) Detect(ctx context.Context) (*Resource, error) {
+func (osDescriptionDetector) Detect(context.Context) (*Resource, error) {
description, err := osDescription()
if err != nil {
return nil, err
diff --git a/vendor/go.opentelemetry.io/otel/sdk/resource/os_release_unix.go b/vendor/go.opentelemetry.io/otel/sdk/resource/os_release_unix.go
index f537e5ca5c..a1763267c2 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/resource/os_release_unix.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/resource/os_release_unix.go
@@ -2,7 +2,6 @@
// SPDX-License-Identifier: Apache-2.0
//go:build aix || dragonfly || freebsd || linux || netbsd || openbsd || solaris || zos
-// +build aix dragonfly freebsd linux netbsd openbsd solaris zos
package resource // import "go.opentelemetry.io/otel/sdk/resource"
@@ -63,12 +62,12 @@ func parseOSReleaseFile(file io.Reader) map[string]string {
return values
}
-// skip returns true if the line is blank or starts with a '#' character, and
+// skip reports whether the line is blank or starts with a '#' character, and
// therefore should be skipped from processing.
func skip(line string) bool {
line = strings.TrimSpace(line)
- return len(line) == 0 || strings.HasPrefix(line, "#")
+ return line == "" || strings.HasPrefix(line, "#")
}
// parse attempts to split the provided line on the first '=' character, and then
@@ -76,7 +75,7 @@ func skip(line string) bool {
func parse(line string) (string, string, bool) {
k, v, found := strings.Cut(line, "=")
- if !found || len(k) == 0 {
+ if !found || k == "" {
return "", "", false
}
diff --git a/vendor/go.opentelemetry.io/otel/sdk/resource/os_unix.go b/vendor/go.opentelemetry.io/otel/sdk/resource/os_unix.go
index a6ff26a4d2..6c50ab6867 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/resource/os_unix.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/resource/os_unix.go
@@ -2,7 +2,6 @@
// SPDX-License-Identifier: Apache-2.0
//go:build aix || darwin || dragonfly || freebsd || linux || netbsd || openbsd || solaris || zos
-// +build aix darwin dragonfly freebsd linux netbsd openbsd solaris zos
package resource // import "go.opentelemetry.io/otel/sdk/resource"
diff --git a/vendor/go.opentelemetry.io/otel/sdk/resource/os_unsupported.go b/vendor/go.opentelemetry.io/otel/sdk/resource/os_unsupported.go
index a77742b077..25f629532a 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/resource/os_unsupported.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/resource/os_unsupported.go
@@ -2,7 +2,6 @@
// SPDX-License-Identifier: Apache-2.0
//go:build !aix && !darwin && !dragonfly && !freebsd && !linux && !netbsd && !openbsd && !solaris && !windows && !zos
-// +build !aix,!darwin,!dragonfly,!freebsd,!linux,!netbsd,!openbsd,!solaris,!windows,!zos
package resource // import "go.opentelemetry.io/otel/sdk/resource"
diff --git a/vendor/go.opentelemetry.io/otel/sdk/resource/process.go b/vendor/go.opentelemetry.io/otel/sdk/resource/process.go
index 085fe68fd7..a1189553c7 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/resource/process.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/resource/process.go
@@ -11,7 +11,7 @@ import (
"path/filepath"
"runtime"
- semconv "go.opentelemetry.io/otel/semconv/v1.26.0"
+ semconv "go.opentelemetry.io/otel/semconv/v1.39.0"
)
type (
@@ -112,19 +112,19 @@ type (
// Detect returns a *Resource that describes the process identifier (PID) of the
// executing process.
-func (processPIDDetector) Detect(ctx context.Context) (*Resource, error) {
+func (processPIDDetector) Detect(context.Context) (*Resource, error) {
return NewWithAttributes(semconv.SchemaURL, semconv.ProcessPID(pid())), nil
}
// Detect returns a *Resource that describes the name of the process executable.
-func (processExecutableNameDetector) Detect(ctx context.Context) (*Resource, error) {
+func (processExecutableNameDetector) Detect(context.Context) (*Resource, error) {
executableName := filepath.Base(commandArgs()[0])
return NewWithAttributes(semconv.SchemaURL, semconv.ProcessExecutableName(executableName)), nil
}
// Detect returns a *Resource that describes the full path of the process executable.
-func (processExecutablePathDetector) Detect(ctx context.Context) (*Resource, error) {
+func (processExecutablePathDetector) Detect(context.Context) (*Resource, error) {
executablePath, err := executablePath()
if err != nil {
return nil, err
@@ -135,13 +135,13 @@ func (processExecutablePathDetector) Detect(ctx context.Context) (*Resource, err
// Detect returns a *Resource that describes all the command arguments as received
// by the process.
-func (processCommandArgsDetector) Detect(ctx context.Context) (*Resource, error) {
+func (processCommandArgsDetector) Detect(context.Context) (*Resource, error) {
return NewWithAttributes(semconv.SchemaURL, semconv.ProcessCommandArgs(commandArgs()...)), nil
}
// Detect returns a *Resource that describes the username of the user that owns the
// process.
-func (processOwnerDetector) Detect(ctx context.Context) (*Resource, error) {
+func (processOwnerDetector) Detect(context.Context) (*Resource, error) {
owner, err := owner()
if err != nil {
return nil, err
@@ -152,17 +152,17 @@ func (processOwnerDetector) Detect(ctx context.Context) (*Resource, error) {
// Detect returns a *Resource that describes the name of the compiler used to compile
// this process image.
-func (processRuntimeNameDetector) Detect(ctx context.Context) (*Resource, error) {
+func (processRuntimeNameDetector) Detect(context.Context) (*Resource, error) {
return NewWithAttributes(semconv.SchemaURL, semconv.ProcessRuntimeName(runtimeName())), nil
}
// Detect returns a *Resource that describes the version of the runtime of this process.
-func (processRuntimeVersionDetector) Detect(ctx context.Context) (*Resource, error) {
+func (processRuntimeVersionDetector) Detect(context.Context) (*Resource, error) {
return NewWithAttributes(semconv.SchemaURL, semconv.ProcessRuntimeVersion(runtimeVersion())), nil
}
// Detect returns a *Resource that describes the runtime of this process.
-func (processRuntimeDescriptionDetector) Detect(ctx context.Context) (*Resource, error) {
+func (processRuntimeDescriptionDetector) Detect(context.Context) (*Resource, error) {
runtimeDescription := fmt.Sprintf(
"go version %s %s/%s", runtimeVersion(), runtimeOS(), runtimeArch())
diff --git a/vendor/go.opentelemetry.io/otel/sdk/resource/resource.go b/vendor/go.opentelemetry.io/otel/sdk/resource/resource.go
index 09b91e1e1b..28e1e4f7eb 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/resource/resource.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/resource/resource.go
@@ -112,7 +112,7 @@ func (r *Resource) String() string {
}
// MarshalLog is the marshaling function used by the logging system to represent this Resource.
-func (r *Resource) MarshalLog() interface{} {
+func (r *Resource) MarshalLog() any {
return struct {
Attributes attribute.Set
SchemaURL string
@@ -148,7 +148,7 @@ func (r *Resource) Iter() attribute.Iterator {
return r.attrs.Iter()
}
-// Equal returns whether r and o represent the same resource. Two resources can
+// Equal reports whether r and o represent the same resource. Two resources can
// be equal even if they have different schema URLs.
//
// See the documentation on the [Resource] type for the pitfalls of using ==
diff --git a/vendor/go.opentelemetry.io/otel/sdk/trace/batch_span_processor.go b/vendor/go.opentelemetry.io/otel/sdk/trace/batch_span_processor.go
index 6872cbb4e7..7d15cbb9c0 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/trace/batch_span_processor.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/trace/batch_span_processor.go
@@ -5,20 +5,24 @@ package trace // import "go.opentelemetry.io/otel/sdk/trace"
import (
"context"
+ "errors"
"sync"
"sync/atomic"
"time"
"go.opentelemetry.io/otel"
"go.opentelemetry.io/otel/internal/global"
- "go.opentelemetry.io/otel/sdk/internal/env"
+ "go.opentelemetry.io/otel/sdk/trace/internal/env"
+ "go.opentelemetry.io/otel/sdk/trace/internal/observ"
"go.opentelemetry.io/otel/trace"
)
// Defaults for BatchSpanProcessorOptions.
const (
- DefaultMaxQueueSize = 2048
- DefaultScheduleDelay = 5000
+ DefaultMaxQueueSize = 2048
+ // DefaultScheduleDelay is the delay interval between two consecutive exports, in milliseconds.
+ DefaultScheduleDelay = 5000
+ // DefaultExportTimeout is the duration after which an export is cancelled, in milliseconds.
DefaultExportTimeout = 30000
DefaultMaxExportBatchSize = 512
)
@@ -66,6 +70,8 @@ type batchSpanProcessor struct {
queue chan ReadOnlySpan
dropped uint32
+ inst *observ.BSP
+
batch []ReadOnlySpan
batchMutex sync.Mutex
timer *time.Timer
@@ -86,11 +92,7 @@ func NewBatchSpanProcessor(exporter SpanExporter, options ...BatchSpanProcessorO
maxExportBatchSize := env.BatchSpanProcessorMaxExportBatchSize(DefaultMaxExportBatchSize)
if maxExportBatchSize > maxQueueSize {
- if DefaultMaxExportBatchSize > maxQueueSize {
- maxExportBatchSize = maxQueueSize
- } else {
- maxExportBatchSize = DefaultMaxExportBatchSize
- }
+ maxExportBatchSize = min(DefaultMaxExportBatchSize, maxQueueSize)
}
o := BatchSpanProcessorOptions{
@@ -111,6 +113,16 @@ func NewBatchSpanProcessor(exporter SpanExporter, options ...BatchSpanProcessorO
stopCh: make(chan struct{}),
}
+ var err error
+ bsp.inst, err = observ.NewBSP(
+ nextProcessorID(),
+ func() int64 { return int64(len(bsp.queue)) },
+ int64(bsp.o.MaxQueueSize),
+ )
+ if err != nil {
+ otel.Handle(err)
+ }
+
bsp.stopWait.Add(1)
go func() {
defer bsp.stopWait.Done()
@@ -121,8 +133,16 @@ func NewBatchSpanProcessor(exporter SpanExporter, options ...BatchSpanProcessorO
return bsp
}
+var processorIDCounter atomic.Int64
+
+// nextProcessorID returns an identifier for this batch span processor,
+// starting with 0 and incrementing by 1 each time it is called.
+func nextProcessorID() int64 {
+ return processorIDCounter.Add(1) - 1
+}
+
// OnStart method does nothing.
-func (bsp *batchSpanProcessor) OnStart(parent context.Context, s ReadWriteSpan) {}
+func (*batchSpanProcessor) OnStart(context.Context, ReadWriteSpan) {}
// OnEnd method enqueues a ReadOnlySpan for later processing.
func (bsp *batchSpanProcessor) OnEnd(s ReadOnlySpan) {
@@ -161,6 +181,9 @@ func (bsp *batchSpanProcessor) Shutdown(ctx context.Context) error {
case <-ctx.Done():
err = ctx.Err()
}
+ if bsp.inst != nil {
+ err = errors.Join(err, bsp.inst.Shutdown())
+ }
})
return err
}
@@ -170,7 +193,7 @@ type forceFlushSpan struct {
flushed chan struct{}
}
-func (f forceFlushSpan) SpanContext() trace.SpanContext {
+func (forceFlushSpan) SpanContext() trace.SpanContext {
return trace.NewSpanContext(trace.SpanContextConfig{TraceFlags: trace.FlagsSampled})
}
@@ -267,12 +290,15 @@ func (bsp *batchSpanProcessor) exportSpans(ctx context.Context) error {
if bsp.o.ExportTimeout > 0 {
var cancel context.CancelFunc
- ctx, cancel = context.WithTimeout(ctx, bsp.o.ExportTimeout)
+ ctx, cancel = context.WithTimeoutCause(ctx, bsp.o.ExportTimeout, errors.New("processor export timeout"))
defer cancel()
}
if l := len(bsp.batch); l > 0 {
global.Debug("exporting spans", "count", len(bsp.batch), "total_dropped", atomic.LoadUint32(&bsp.dropped))
+ if bsp.inst != nil {
+ bsp.inst.Processed(ctx, int64(l))
+ }
err := bsp.e.ExportSpans(ctx, bsp.batch)
// A new batch is always created after exporting, even if the batch failed to be exported.
@@ -381,11 +407,14 @@ func (bsp *batchSpanProcessor) enqueueBlockOnQueueFull(ctx context.Context, sd R
case bsp.queue <- sd:
return true
case <-ctx.Done():
+ if bsp.inst != nil {
+ bsp.inst.ProcessedQueueFull(ctx, 1)
+ }
return false
}
}
-func (bsp *batchSpanProcessor) enqueueDrop(_ context.Context, sd ReadOnlySpan) bool {
+func (bsp *batchSpanProcessor) enqueueDrop(ctx context.Context, sd ReadOnlySpan) bool {
if !sd.SpanContext().IsSampled() {
return false
}
@@ -395,12 +424,15 @@ func (bsp *batchSpanProcessor) enqueueDrop(_ context.Context, sd ReadOnlySpan) b
return true
default:
atomic.AddUint32(&bsp.dropped, 1)
+ if bsp.inst != nil {
+ bsp.inst.ProcessedQueueFull(ctx, 1)
+ }
}
return false
}
// MarshalLog is the marshaling function used by the logging system to represent this Span Processor.
-func (bsp *batchSpanProcessor) MarshalLog() interface{} {
+func (bsp *batchSpanProcessor) MarshalLog() any {
return struct {
Type string
SpanExporter SpanExporter
diff --git a/vendor/go.opentelemetry.io/otel/sdk/trace/doc.go b/vendor/go.opentelemetry.io/otel/sdk/trace/doc.go
index 1f60524e3e..b502c7d479 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/trace/doc.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/trace/doc.go
@@ -6,5 +6,8 @@ Package trace contains support for OpenTelemetry distributed tracing.
The following assumes a basic familiarity with OpenTelemetry concepts.
See https://opentelemetry.io.
+
+See [go.opentelemetry.io/otel/sdk/internal/x] for information about
+the experimental features.
*/
package trace // import "go.opentelemetry.io/otel/sdk/trace"
diff --git a/vendor/go.opentelemetry.io/otel/sdk/trace/id_generator.go b/vendor/go.opentelemetry.io/otel/sdk/trace/id_generator.go
index c8d3fb7e3c..3649322a6e 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/trace/id_generator.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/trace/id_generator.go
@@ -32,7 +32,7 @@ type randomIDGenerator struct{}
var _ IDGenerator = &randomIDGenerator{}
// NewSpanID returns a non-zero span ID from a randomly-chosen sequence.
-func (gen *randomIDGenerator) NewSpanID(ctx context.Context, traceID trace.TraceID) trace.SpanID {
+func (*randomIDGenerator) NewSpanID(context.Context, trace.TraceID) trace.SpanID {
sid := trace.SpanID{}
for {
binary.NativeEndian.PutUint64(sid[:], rand.Uint64())
@@ -45,7 +45,7 @@ func (gen *randomIDGenerator) NewSpanID(ctx context.Context, traceID trace.Trace
// NewIDs returns a non-zero trace ID and a non-zero span ID from a
// randomly-chosen sequence.
-func (gen *randomIDGenerator) NewIDs(ctx context.Context) (trace.TraceID, trace.SpanID) {
+func (*randomIDGenerator) NewIDs(context.Context) (trace.TraceID, trace.SpanID) {
tid := trace.TraceID{}
sid := trace.SpanID{}
for {
diff --git a/vendor/go.opentelemetry.io/otel/sdk/trace/internal/env/env.go b/vendor/go.opentelemetry.io/otel/sdk/trace/internal/env/env.go
new file mode 100644
index 0000000000..58f68df441
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/sdk/trace/internal/env/env.go
@@ -0,0 +1,168 @@
+// Copyright The OpenTelemetry Authors
+// SPDX-License-Identifier: Apache-2.0
+
+// Package env provides types and functionality for environment variable support
+// in the OpenTelemetry SDK.
+package env // import "go.opentelemetry.io/otel/sdk/trace/internal/env"
+
+import (
+ "os"
+ "strconv"
+
+ "go.opentelemetry.io/otel/internal/global"
+)
+
+// Environment variable names.
+const (
+ // BatchSpanProcessorScheduleDelayKey is the delay interval between two
+ // consecutive exports (i.e. 5000).
+ BatchSpanProcessorScheduleDelayKey = "OTEL_BSP_SCHEDULE_DELAY"
+ // BatchSpanProcessorExportTimeoutKey is the maximum allowed time to
+ // export data (i.e. 3000).
+ BatchSpanProcessorExportTimeoutKey = "OTEL_BSP_EXPORT_TIMEOUT"
+ // BatchSpanProcessorMaxQueueSizeKey is the maximum queue size (i.e. 2048).
+ BatchSpanProcessorMaxQueueSizeKey = "OTEL_BSP_MAX_QUEUE_SIZE"
+ // BatchSpanProcessorMaxExportBatchSizeKey is the maximum batch size (i.e.
+ // 512). Note: it must be less than or equal to
+ // BatchSpanProcessorMaxQueueSize.
+ BatchSpanProcessorMaxExportBatchSizeKey = "OTEL_BSP_MAX_EXPORT_BATCH_SIZE"
+
+ // AttributeValueLengthKey is the maximum allowed attribute value size.
+ AttributeValueLengthKey = "OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT"
+
+ // AttributeCountKey is the maximum allowed span attribute count.
+ AttributeCountKey = "OTEL_ATTRIBUTE_COUNT_LIMIT"
+
+ // SpanAttributeValueLengthKey is the maximum allowed attribute value size
+ // for a span.
+ SpanAttributeValueLengthKey = "OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT"
+
+ // SpanAttributeCountKey is the maximum allowed span attribute count for a
+ // span.
+ SpanAttributeCountKey = "OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT"
+
+ // SpanEventCountKey is the maximum allowed span event count.
+ SpanEventCountKey = "OTEL_SPAN_EVENT_COUNT_LIMIT"
+
+ // SpanEventAttributeCountKey is the maximum allowed attribute per span
+ // event count.
+ SpanEventAttributeCountKey = "OTEL_EVENT_ATTRIBUTE_COUNT_LIMIT"
+
+ // SpanLinkCountKey is the maximum allowed span link count.
+ SpanLinkCountKey = "OTEL_SPAN_LINK_COUNT_LIMIT"
+
+ // SpanLinkAttributeCountKey is the maximum allowed attribute per span
+ // link count.
+ SpanLinkAttributeCountKey = "OTEL_LINK_ATTRIBUTE_COUNT_LIMIT"
+)
+
+// firstInt returns the value of the first matching environment variable from
+// keys. If the value is not an integer or no match is found, defaultValue is
+// returned.
+func firstInt(defaultValue int, keys ...string) int {
+ for _, key := range keys {
+ value := os.Getenv(key)
+ if value == "" {
+ continue
+ }
+
+ intValue, err := strconv.Atoi(value)
+ if err != nil {
+ global.Info("Got invalid value, number value expected.", key, value)
+ return defaultValue
+ }
+
+ return intValue
+ }
+
+ return defaultValue
+}
+
+// IntEnvOr returns the int value of the environment variable with name key if
+// it exists, it is not empty, and the value is an int. Otherwise, defaultValue is returned.
+func IntEnvOr(key string, defaultValue int) int {
+ value := os.Getenv(key)
+ if value == "" {
+ return defaultValue
+ }
+
+ intValue, err := strconv.Atoi(value)
+ if err != nil {
+ global.Info("Got invalid value, number value expected.", key, value)
+ return defaultValue
+ }
+
+ return intValue
+}
+
+// BatchSpanProcessorScheduleDelay returns the environment variable value for
+// the OTEL_BSP_SCHEDULE_DELAY key if it exists, otherwise defaultValue is
+// returned.
+func BatchSpanProcessorScheduleDelay(defaultValue int) int {
+ return IntEnvOr(BatchSpanProcessorScheduleDelayKey, defaultValue)
+}
+
+// BatchSpanProcessorExportTimeout returns the environment variable value for
+// the OTEL_BSP_EXPORT_TIMEOUT key if it exists, otherwise defaultValue is
+// returned.
+func BatchSpanProcessorExportTimeout(defaultValue int) int {
+ return IntEnvOr(BatchSpanProcessorExportTimeoutKey, defaultValue)
+}
+
+// BatchSpanProcessorMaxQueueSize returns the environment variable value for
+// the OTEL_BSP_MAX_QUEUE_SIZE key if it exists, otherwise defaultValue is
+// returned.
+func BatchSpanProcessorMaxQueueSize(defaultValue int) int {
+ return IntEnvOr(BatchSpanProcessorMaxQueueSizeKey, defaultValue)
+}
+
+// BatchSpanProcessorMaxExportBatchSize returns the environment variable value for
+// the OTEL_BSP_MAX_EXPORT_BATCH_SIZE key if it exists, otherwise defaultValue
+// is returned.
+func BatchSpanProcessorMaxExportBatchSize(defaultValue int) int {
+ return IntEnvOr(BatchSpanProcessorMaxExportBatchSizeKey, defaultValue)
+}
+
+// SpanAttributeValueLength returns the environment variable value for the
+// OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT key if it exists. Otherwise, the
+// environment variable value for OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT is
+// returned or defaultValue if that is not set.
+func SpanAttributeValueLength(defaultValue int) int {
+ return firstInt(defaultValue, SpanAttributeValueLengthKey, AttributeValueLengthKey)
+}
+
+// SpanAttributeCount returns the environment variable value for the
+// OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT key if it exists. Otherwise, the
+// environment variable value for OTEL_ATTRIBUTE_COUNT_LIMIT is returned or
+// defaultValue if that is not set.
+func SpanAttributeCount(defaultValue int) int {
+ return firstInt(defaultValue, SpanAttributeCountKey, AttributeCountKey)
+}
+
+// SpanEventCount returns the environment variable value for the
+// OTEL_SPAN_EVENT_COUNT_LIMIT key if it exists, otherwise defaultValue is
+// returned.
+func SpanEventCount(defaultValue int) int {
+ return IntEnvOr(SpanEventCountKey, defaultValue)
+}
+
+// SpanEventAttributeCount returns the environment variable value for the
+// OTEL_EVENT_ATTRIBUTE_COUNT_LIMIT key if it exists, otherwise defaultValue
+// is returned.
+func SpanEventAttributeCount(defaultValue int) int {
+ return IntEnvOr(SpanEventAttributeCountKey, defaultValue)
+}
+
+// SpanLinkCount returns the environment variable value for the
+// OTEL_SPAN_LINK_COUNT_LIMIT key if it exists, otherwise defaultValue is
+// returned.
+func SpanLinkCount(defaultValue int) int {
+ return IntEnvOr(SpanLinkCountKey, defaultValue)
+}
+
+// SpanLinkAttributeCount returns the environment variable value for the
+// OTEL_LINK_ATTRIBUTE_COUNT_LIMIT key if it exists, otherwise defaultValue is
+// returned.
+func SpanLinkAttributeCount(defaultValue int) int {
+ return IntEnvOr(SpanLinkAttributeCountKey, defaultValue)
+}
diff --git a/vendor/go.opentelemetry.io/otel/sdk/trace/internal/observ/batch_span_processor.go b/vendor/go.opentelemetry.io/otel/sdk/trace/internal/observ/batch_span_processor.go
new file mode 100644
index 0000000000..d9cfba0b45
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/sdk/trace/internal/observ/batch_span_processor.go
@@ -0,0 +1,119 @@
+// Copyright The OpenTelemetry Authors
+// SPDX-License-Identifier: Apache-2.0
+
+package observ // import "go.opentelemetry.io/otel/sdk/trace/internal/observ"
+
+import (
+ "context"
+ "errors"
+ "fmt"
+
+ "go.opentelemetry.io/otel"
+ "go.opentelemetry.io/otel/attribute"
+ "go.opentelemetry.io/otel/metric"
+ "go.opentelemetry.io/otel/sdk"
+ "go.opentelemetry.io/otel/sdk/internal/x"
+ semconv "go.opentelemetry.io/otel/semconv/v1.39.0"
+ "go.opentelemetry.io/otel/semconv/v1.39.0/otelconv"
+)
+
+const (
+ // ScopeName is the name of the instrumentation scope.
+ ScopeName = "go.opentelemetry.io/otel/sdk/trace/internal/observ"
+
+ // SchemaURL is the schema URL of the instrumentation.
+ SchemaURL = semconv.SchemaURL
+)
+
+// ErrQueueFull is the attribute value for the "queue_full" error type.
+var ErrQueueFull = otelconv.SDKProcessorSpanProcessed{}.AttrErrorType(
+ otelconv.ErrorTypeAttr("queue_full"),
+)
+
+// BSPComponentName returns the component name attribute for a
+// BatchSpanProcessor with the given ID.
+func BSPComponentName(id int64) attribute.KeyValue {
+ t := otelconv.ComponentTypeBatchingSpanProcessor
+ name := fmt.Sprintf("%s/%d", t, id)
+ return semconv.OTelComponentName(name)
+}
+
+// BSP is the instrumentation for an OTel SDK BatchSpanProcessor.
+type BSP struct {
+ reg metric.Registration
+
+ processed metric.Int64Counter
+ processedOpts []metric.AddOption
+ processedQueueFullOpts []metric.AddOption
+}
+
+func NewBSP(id int64, qLen func() int64, qMax int64) (*BSP, error) {
+ if !x.Observability.Enabled() {
+ return nil, nil
+ }
+
+ meter := otel.GetMeterProvider().Meter(
+ ScopeName,
+ metric.WithInstrumentationVersion(sdk.Version()),
+ metric.WithSchemaURL(SchemaURL),
+ )
+
+ qCap, err := otelconv.NewSDKProcessorSpanQueueCapacity(meter)
+ if err != nil {
+ err = fmt.Errorf("failed to create BSP queue capacity metric: %w", err)
+ }
+ qCapInst := qCap.Inst()
+
+ qSize, e := otelconv.NewSDKProcessorSpanQueueSize(meter)
+ if e != nil {
+ e := fmt.Errorf("failed to create BSP queue size metric: %w", e)
+ err = errors.Join(err, e)
+ }
+ qSizeInst := qSize.Inst()
+
+ cmpntT := semconv.OTelComponentTypeBatchingSpanProcessor
+ cmpnt := BSPComponentName(id)
+ set := attribute.NewSet(cmpnt, cmpntT)
+
+ obsOpts := []metric.ObserveOption{metric.WithAttributeSet(set)}
+ reg, e := meter.RegisterCallback(
+ func(_ context.Context, o metric.Observer) error {
+ o.ObserveInt64(qSizeInst, qLen(), obsOpts...)
+ o.ObserveInt64(qCapInst, qMax, obsOpts...)
+ return nil
+ },
+ qSizeInst,
+ qCapInst,
+ )
+ if e != nil {
+ e := fmt.Errorf("failed to register BSP queue size/capacity callback: %w", e)
+ err = errors.Join(err, e)
+ }
+
+ processed, e := otelconv.NewSDKProcessorSpanProcessed(meter)
+ if e != nil {
+ e := fmt.Errorf("failed to create BSP processed spans metric: %w", e)
+ err = errors.Join(err, e)
+ }
+ processedOpts := []metric.AddOption{metric.WithAttributeSet(set)}
+
+ set = attribute.NewSet(cmpnt, cmpntT, ErrQueueFull)
+ processedQueueFullOpts := []metric.AddOption{metric.WithAttributeSet(set)}
+
+ return &BSP{
+ reg: reg,
+ processed: processed.Inst(),
+ processedOpts: processedOpts,
+ processedQueueFullOpts: processedQueueFullOpts,
+ }, err
+}
+
+func (b *BSP) Shutdown() error { return b.reg.Unregister() }
+
+func (b *BSP) Processed(ctx context.Context, n int64) {
+ b.processed.Add(ctx, n, b.processedOpts...)
+}
+
+func (b *BSP) ProcessedQueueFull(ctx context.Context, n int64) {
+ b.processed.Add(ctx, n, b.processedQueueFullOpts...)
+}
diff --git a/vendor/go.opentelemetry.io/otel/sdk/trace/internal/observ/doc.go b/vendor/go.opentelemetry.io/otel/sdk/trace/internal/observ/doc.go
new file mode 100644
index 0000000000..b542121e6a
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/sdk/trace/internal/observ/doc.go
@@ -0,0 +1,6 @@
+// Copyright The OpenTelemetry Authors
+// SPDX-License-Identifier: Apache-2.0
+
+// Package observ provides observability instrumentation for the OTel trace SDK
+// package.
+package observ // import "go.opentelemetry.io/otel/sdk/trace/internal/observ"
diff --git a/vendor/go.opentelemetry.io/otel/sdk/trace/internal/observ/simple_span_processor.go b/vendor/go.opentelemetry.io/otel/sdk/trace/internal/observ/simple_span_processor.go
new file mode 100644
index 0000000000..8afd052679
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/sdk/trace/internal/observ/simple_span_processor.go
@@ -0,0 +1,97 @@
+// Copyright The OpenTelemetry Authors
+// SPDX-License-Identifier: Apache-2.0
+
+package observ // import "go.opentelemetry.io/otel/sdk/trace/internal/observ"
+
+import (
+ "context"
+ "fmt"
+ "sync"
+
+ "go.opentelemetry.io/otel"
+ "go.opentelemetry.io/otel/attribute"
+ "go.opentelemetry.io/otel/metric"
+ "go.opentelemetry.io/otel/sdk"
+ "go.opentelemetry.io/otel/sdk/internal/x"
+ semconv "go.opentelemetry.io/otel/semconv/v1.39.0"
+ "go.opentelemetry.io/otel/semconv/v1.39.0/otelconv"
+)
+
+var measureAttrsPool = sync.Pool{
+ New: func() any {
+ // "component.name" + "component.type" + "error.type"
+ const n = 1 + 1 + 1
+ s := make([]attribute.KeyValue, 0, n)
+ // Return a pointer to a slice instead of a slice itself
+ // to avoid allocations on every call.
+ return &s
+ },
+}
+
+// SSP is the instrumentation for an OTel SDK SimpleSpanProcessor.
+type SSP struct {
+ spansProcessedCounter metric.Int64Counter
+ addOpts []metric.AddOption
+ attrs []attribute.KeyValue
+}
+
+// SSPComponentName returns the component name attribute for a
+// SimpleSpanProcessor with the given ID.
+func SSPComponentName(id int64) attribute.KeyValue {
+ t := otelconv.ComponentTypeSimpleSpanProcessor
+ name := fmt.Sprintf("%s/%d", t, id)
+ return semconv.OTelComponentName(name)
+}
+
+// NewSSP returns instrumentation for an OTel SDK SimpleSpanProcessor with the
+// provided ID.
+//
+// If the experimental observability is disabled, nil is returned.
+func NewSSP(id int64) (*SSP, error) {
+ if !x.Observability.Enabled() {
+ return nil, nil
+ }
+
+ meter := otel.GetMeterProvider().Meter(
+ ScopeName,
+ metric.WithInstrumentationVersion(sdk.Version()),
+ metric.WithSchemaURL(SchemaURL),
+ )
+ spansProcessedCounter, err := otelconv.NewSDKProcessorSpanProcessed(meter)
+ if err != nil {
+ err = fmt.Errorf("failed to create SSP processed spans metric: %w", err)
+ }
+
+ componentName := SSPComponentName(id)
+ componentType := spansProcessedCounter.AttrComponentType(otelconv.ComponentTypeSimpleSpanProcessor)
+ attrs := []attribute.KeyValue{componentName, componentType}
+ addOpts := []metric.AddOption{metric.WithAttributeSet(attribute.NewSet(attrs...))}
+
+ return &SSP{
+ spansProcessedCounter: spansProcessedCounter.Inst(),
+ addOpts: addOpts,
+ attrs: attrs,
+ }, err
+}
+
+// SpanProcessed records that a span has been processed by the SimpleSpanProcessor.
+// If err is non-nil, it records the processing error as an attribute.
+func (ssp *SSP) SpanProcessed(ctx context.Context, err error) {
+ ssp.spansProcessedCounter.Add(ctx, 1, ssp.addOption(err)...)
+}
+
+func (ssp *SSP) addOption(err error) []metric.AddOption {
+ if err == nil {
+ return ssp.addOpts
+ }
+ attrs := measureAttrsPool.Get().(*[]attribute.KeyValue)
+ defer func() {
+ *attrs = (*attrs)[:0] // reset the slice for reuse
+ measureAttrsPool.Put(attrs)
+ }()
+ *attrs = append(*attrs, ssp.attrs...)
+ *attrs = append(*attrs, semconv.ErrorType(err))
+ // Do not inefficiently make a copy of attrs by using
+ // WithAttributes instead of WithAttributeSet.
+ return []metric.AddOption{metric.WithAttributeSet(attribute.NewSet(*attrs...))}
+}
diff --git a/vendor/go.opentelemetry.io/otel/sdk/trace/internal/observ/tracer.go b/vendor/go.opentelemetry.io/otel/sdk/trace/internal/observ/tracer.go
new file mode 100644
index 0000000000..13a2db2969
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/sdk/trace/internal/observ/tracer.go
@@ -0,0 +1,223 @@
+// Copyright The OpenTelemetry Authors
+// SPDX-License-Identifier: Apache-2.0
+
+package observ // import "go.opentelemetry.io/otel/sdk/trace/internal/observ"
+
+import (
+ "context"
+ "errors"
+ "fmt"
+
+ "go.opentelemetry.io/otel"
+ "go.opentelemetry.io/otel/attribute"
+ "go.opentelemetry.io/otel/metric"
+ "go.opentelemetry.io/otel/sdk"
+ "go.opentelemetry.io/otel/sdk/internal/x"
+ "go.opentelemetry.io/otel/semconv/v1.39.0/otelconv"
+ "go.opentelemetry.io/otel/trace"
+)
+
+var meterOpts = []metric.MeterOption{
+ metric.WithInstrumentationVersion(sdk.Version()),
+ metric.WithSchemaURL(SchemaURL),
+}
+
+// Tracer is instrumentation for an OTel SDK Tracer.
+type Tracer struct {
+ enabled bool
+
+ live metric.Int64UpDownCounter
+ started metric.Int64Counter
+}
+
+func NewTracer() (Tracer, error) {
+ if !x.Observability.Enabled() {
+ return Tracer{}, nil
+ }
+ meter := otel.GetMeterProvider().Meter(ScopeName, meterOpts...)
+
+ var err error
+ l, e := otelconv.NewSDKSpanLive(meter)
+ if e != nil {
+ e = fmt.Errorf("failed to create span live metric: %w", e)
+ err = errors.Join(err, e)
+ }
+
+ s, e := otelconv.NewSDKSpanStarted(meter)
+ if e != nil {
+ e = fmt.Errorf("failed to create span started metric: %w", e)
+ err = errors.Join(err, e)
+ }
+
+ return Tracer{enabled: true, live: l.Inst(), started: s.Inst()}, err
+}
+
+func (t Tracer) Enabled() bool { return t.enabled }
+
+func (t Tracer) SpanStarted(ctx context.Context, psc trace.SpanContext, span trace.Span) {
+ key := spanStartedKey{
+ parent: parentStateNoParent,
+ sampling: samplingStateDrop,
+ }
+
+ if psc.IsValid() {
+ if psc.IsRemote() {
+ key.parent = parentStateRemoteParent
+ } else {
+ key.parent = parentStateLocalParent
+ }
+ }
+
+ if span.IsRecording() {
+ if span.SpanContext().IsSampled() {
+ key.sampling = samplingStateRecordAndSample
+ } else {
+ key.sampling = samplingStateRecordOnly
+ }
+ }
+
+ opts := spanStartedOpts[key]
+ t.started.Add(ctx, 1, opts...)
+}
+
+func (t Tracer) SpanLive(ctx context.Context, span trace.Span) {
+ t.spanLive(ctx, 1, span)
+}
+
+func (t Tracer) SpanEnded(ctx context.Context, span trace.Span) {
+ t.spanLive(ctx, -1, span)
+}
+
+func (t Tracer) spanLive(ctx context.Context, value int64, span trace.Span) {
+ key := spanLiveKey{sampled: span.SpanContext().IsSampled()}
+ opts := spanLiveOpts[key]
+ t.live.Add(ctx, value, opts...)
+}
+
+type parentState int
+
+const (
+ parentStateNoParent parentState = iota
+ parentStateLocalParent
+ parentStateRemoteParent
+)
+
+type samplingState int
+
+const (
+ samplingStateDrop samplingState = iota
+ samplingStateRecordOnly
+ samplingStateRecordAndSample
+)
+
+type spanStartedKey struct {
+ parent parentState
+ sampling samplingState
+}
+
+var spanStartedOpts = map[spanStartedKey][]metric.AddOption{
+ {
+ parentStateNoParent,
+ samplingStateDrop,
+ }: {
+ metric.WithAttributeSet(attribute.NewSet(
+ otelconv.SDKSpanStarted{}.AttrSpanParentOrigin(otelconv.SpanParentOriginNone),
+ otelconv.SDKSpanStarted{}.AttrSpanSamplingResult(otelconv.SpanSamplingResultDrop),
+ )),
+ },
+ {
+ parentStateLocalParent,
+ samplingStateDrop,
+ }: {
+ metric.WithAttributeSet(attribute.NewSet(
+ otelconv.SDKSpanStarted{}.AttrSpanParentOrigin(otelconv.SpanParentOriginLocal),
+ otelconv.SDKSpanStarted{}.AttrSpanSamplingResult(otelconv.SpanSamplingResultDrop),
+ )),
+ },
+ {
+ parentStateRemoteParent,
+ samplingStateDrop,
+ }: {
+ metric.WithAttributeSet(attribute.NewSet(
+ otelconv.SDKSpanStarted{}.AttrSpanParentOrigin(otelconv.SpanParentOriginRemote),
+ otelconv.SDKSpanStarted{}.AttrSpanSamplingResult(otelconv.SpanSamplingResultDrop),
+ )),
+ },
+
+ {
+ parentStateNoParent,
+ samplingStateRecordOnly,
+ }: {
+ metric.WithAttributeSet(attribute.NewSet(
+ otelconv.SDKSpanStarted{}.AttrSpanParentOrigin(otelconv.SpanParentOriginNone),
+ otelconv.SDKSpanStarted{}.AttrSpanSamplingResult(otelconv.SpanSamplingResultRecordOnly),
+ )),
+ },
+ {
+ parentStateLocalParent,
+ samplingStateRecordOnly,
+ }: {
+ metric.WithAttributeSet(attribute.NewSet(
+ otelconv.SDKSpanStarted{}.AttrSpanParentOrigin(otelconv.SpanParentOriginLocal),
+ otelconv.SDKSpanStarted{}.AttrSpanSamplingResult(otelconv.SpanSamplingResultRecordOnly),
+ )),
+ },
+ {
+ parentStateRemoteParent,
+ samplingStateRecordOnly,
+ }: {
+ metric.WithAttributeSet(attribute.NewSet(
+ otelconv.SDKSpanStarted{}.AttrSpanParentOrigin(otelconv.SpanParentOriginRemote),
+ otelconv.SDKSpanStarted{}.AttrSpanSamplingResult(otelconv.SpanSamplingResultRecordOnly),
+ )),
+ },
+
+ {
+ parentStateNoParent,
+ samplingStateRecordAndSample,
+ }: {
+ metric.WithAttributeSet(attribute.NewSet(
+ otelconv.SDKSpanStarted{}.AttrSpanParentOrigin(otelconv.SpanParentOriginNone),
+ otelconv.SDKSpanStarted{}.AttrSpanSamplingResult(otelconv.SpanSamplingResultRecordAndSample),
+ )),
+ },
+ {
+ parentStateLocalParent,
+ samplingStateRecordAndSample,
+ }: {
+ metric.WithAttributeSet(attribute.NewSet(
+ otelconv.SDKSpanStarted{}.AttrSpanParentOrigin(otelconv.SpanParentOriginLocal),
+ otelconv.SDKSpanStarted{}.AttrSpanSamplingResult(otelconv.SpanSamplingResultRecordAndSample),
+ )),
+ },
+ {
+ parentStateRemoteParent,
+ samplingStateRecordAndSample,
+ }: {
+ metric.WithAttributeSet(attribute.NewSet(
+ otelconv.SDKSpanStarted{}.AttrSpanParentOrigin(otelconv.SpanParentOriginRemote),
+ otelconv.SDKSpanStarted{}.AttrSpanSamplingResult(otelconv.SpanSamplingResultRecordAndSample),
+ )),
+ },
+}
+
+type spanLiveKey struct {
+ sampled bool
+}
+
+var spanLiveOpts = map[spanLiveKey][]metric.AddOption{
+ {true}: {
+ metric.WithAttributeSet(attribute.NewSet(
+ otelconv.SDKSpanLive{}.AttrSpanSamplingResult(
+ otelconv.SpanSamplingResultRecordAndSample,
+ ),
+ )),
+ },
+ {false}: {
+ metric.WithAttributeSet(attribute.NewSet(
+ otelconv.SDKSpanLive{}.AttrSpanSamplingResult(
+ otelconv.SpanSamplingResultRecordOnly,
+ ),
+ )),
+ },
+}
diff --git a/vendor/go.opentelemetry.io/otel/sdk/trace/provider.go b/vendor/go.opentelemetry.io/otel/sdk/trace/provider.go
index 0e2a2e7c60..d2cf4ebd3e 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/trace/provider.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/trace/provider.go
@@ -13,14 +13,13 @@ import (
"go.opentelemetry.io/otel/internal/global"
"go.opentelemetry.io/otel/sdk/instrumentation"
"go.opentelemetry.io/otel/sdk/resource"
+ "go.opentelemetry.io/otel/sdk/trace/internal/observ"
"go.opentelemetry.io/otel/trace"
"go.opentelemetry.io/otel/trace/embedded"
"go.opentelemetry.io/otel/trace/noop"
)
-const (
- defaultTracerName = "go.opentelemetry.io/otel/sdk/tracer"
-)
+const defaultTracerName = "go.opentelemetry.io/otel/sdk/tracer"
// tracerProviderConfig.
type tracerProviderConfig struct {
@@ -45,7 +44,7 @@ type tracerProviderConfig struct {
}
// MarshalLog is the marshaling function used by the logging system to represent this Provider.
-func (cfg tracerProviderConfig) MarshalLog() interface{} {
+func (cfg tracerProviderConfig) MarshalLog() any {
return struct {
SpanProcessors []SpanProcessor
SamplerType string
@@ -159,6 +158,13 @@ func (p *TracerProvider) Tracer(name string, opts ...trace.TracerOption) trace.T
provider: p,
instrumentationScope: is,
}
+
+ var err error
+ t.inst, err = observ.NewTracer()
+ if err != nil {
+ otel.Handle(err)
+ }
+
p.namedTracer[is] = t
}
return t, ok
diff --git a/vendor/go.opentelemetry.io/otel/sdk/trace/sampling.go b/vendor/go.opentelemetry.io/otel/sdk/trace/sampling.go
index aa7b262d0d..81c5060ad6 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/trace/sampling.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/trace/sampling.go
@@ -110,14 +110,14 @@ func TraceIDRatioBased(fraction float64) Sampler {
type alwaysOnSampler struct{}
-func (as alwaysOnSampler) ShouldSample(p SamplingParameters) SamplingResult {
+func (alwaysOnSampler) ShouldSample(p SamplingParameters) SamplingResult {
return SamplingResult{
Decision: RecordAndSample,
Tracestate: trace.SpanContextFromContext(p.ParentContext).TraceState(),
}
}
-func (as alwaysOnSampler) Description() string {
+func (alwaysOnSampler) Description() string {
return "AlwaysOnSampler"
}
@@ -131,14 +131,14 @@ func AlwaysSample() Sampler {
type alwaysOffSampler struct{}
-func (as alwaysOffSampler) ShouldSample(p SamplingParameters) SamplingResult {
+func (alwaysOffSampler) ShouldSample(p SamplingParameters) SamplingResult {
return SamplingResult{
Decision: Drop,
Tracestate: trace.SpanContextFromContext(p.ParentContext).TraceState(),
}
}
-func (as alwaysOffSampler) Description() string {
+func (alwaysOffSampler) Description() string {
return "AlwaysOffSampler"
}
@@ -280,3 +280,31 @@ func (pb parentBased) Description() string {
pb.config.localParentNotSampled.Description(),
)
}
+
+// AlwaysRecord returns a sampler decorator which ensures that every span
+// is passed to the SpanProcessor, even those that would be normally dropped.
+// It converts `Drop` decisions from the root sampler into `RecordOnly` decisions,
+// allowing processors to see all spans without sending them to exporters. This is
+// typically used to enable accurate span-to-metrics processing.
+func AlwaysRecord(root Sampler) Sampler {
+ return alwaysRecord{root}
+}
+
+type alwaysRecord struct {
+ root Sampler
+}
+
+func (ar alwaysRecord) ShouldSample(p SamplingParameters) SamplingResult {
+ rootSamplerSamplingResult := ar.root.ShouldSample(p)
+ if rootSamplerSamplingResult.Decision == Drop {
+ return SamplingResult{
+ Decision: RecordOnly,
+ Tracestate: trace.SpanContextFromContext(p.ParentContext).TraceState(),
+ }
+ }
+ return rootSamplerSamplingResult
+}
+
+func (ar alwaysRecord) Description() string {
+ return "AlwaysRecord{root:" + ar.root.Description() + "}"
+}
diff --git a/vendor/go.opentelemetry.io/otel/sdk/trace/simple_span_processor.go b/vendor/go.opentelemetry.io/otel/sdk/trace/simple_span_processor.go
index 664e13e03f..771e427a4c 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/trace/simple_span_processor.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/trace/simple_span_processor.go
@@ -6,9 +6,12 @@ package trace // import "go.opentelemetry.io/otel/sdk/trace"
import (
"context"
"sync"
+ "sync/atomic"
"go.opentelemetry.io/otel"
"go.opentelemetry.io/otel/internal/global"
+ "go.opentelemetry.io/otel/sdk/trace/internal/observ"
+ "go.opentelemetry.io/otel/trace"
)
// simpleSpanProcessor is a SpanProcessor that synchronously sends all
@@ -17,6 +20,8 @@ type simpleSpanProcessor struct {
exporterMu sync.Mutex
exporter SpanExporter
stopOnce sync.Once
+
+ inst *observ.SSP
}
var _ SpanProcessor = (*simpleSpanProcessor)(nil)
@@ -33,24 +38,48 @@ func NewSimpleSpanProcessor(exporter SpanExporter) SpanProcessor {
ssp := &simpleSpanProcessor{
exporter: exporter,
}
+
+ var err error
+ ssp.inst, err = observ.NewSSP(nextSimpleProcessorID())
+ if err != nil {
+ otel.Handle(err)
+ }
+
global.Warn("SimpleSpanProcessor is not recommended for production use, consider using BatchSpanProcessor instead.")
return ssp
}
+var simpleProcessorIDCounter atomic.Int64
+
+// nextSimpleProcessorID returns an identifier for this simple span processor,
+// starting with 0 and incrementing by 1 each time it is called.
+func nextSimpleProcessorID() int64 {
+ return simpleProcessorIDCounter.Add(1) - 1
+}
+
// OnStart does nothing.
-func (ssp *simpleSpanProcessor) OnStart(context.Context, ReadWriteSpan) {}
+func (*simpleSpanProcessor) OnStart(context.Context, ReadWriteSpan) {}
// OnEnd immediately exports a ReadOnlySpan.
func (ssp *simpleSpanProcessor) OnEnd(s ReadOnlySpan) {
ssp.exporterMu.Lock()
defer ssp.exporterMu.Unlock()
+ var err error
if ssp.exporter != nil && s.SpanContext().TraceFlags().IsSampled() {
- if err := ssp.exporter.ExportSpans(context.Background(), []ReadOnlySpan{s}); err != nil {
+ err = ssp.exporter.ExportSpans(context.Background(), []ReadOnlySpan{s})
+ if err != nil {
otel.Handle(err)
}
}
+
+ if ssp.inst != nil {
+ // Add the span to the context to ensure the metric is recorded
+ // with the correct span context.
+ ctx := trace.ContextWithSpanContext(context.Background(), s.SpanContext())
+ ssp.inst.SpanProcessed(ctx, err)
+ }
}
// Shutdown shuts down the exporter this SimpleSpanProcessor exports to.
@@ -104,13 +133,13 @@ func (ssp *simpleSpanProcessor) Shutdown(ctx context.Context) error {
}
// ForceFlush does nothing as there is no data to flush.
-func (ssp *simpleSpanProcessor) ForceFlush(context.Context) error {
+func (*simpleSpanProcessor) ForceFlush(context.Context) error {
return nil
}
// MarshalLog is the marshaling function used by the logging system to represent
// this Span Processor.
-func (ssp *simpleSpanProcessor) MarshalLog() interface{} {
+func (ssp *simpleSpanProcessor) MarshalLog() any {
return struct {
Type string
Exporter SpanExporter
diff --git a/vendor/go.opentelemetry.io/otel/sdk/trace/snapshot.go b/vendor/go.opentelemetry.io/otel/sdk/trace/snapshot.go
index d511d0f271..63aa337800 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/trace/snapshot.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/trace/snapshot.go
@@ -35,7 +35,7 @@ type snapshot struct {
var _ ReadOnlySpan = snapshot{}
-func (s snapshot) private() {}
+func (snapshot) private() {}
// Name returns the name of the span.
func (s snapshot) Name() string {
diff --git a/vendor/go.opentelemetry.io/otel/sdk/trace/span.go b/vendor/go.opentelemetry.io/otel/sdk/trace/span.go
index 8f4fc38508..d466610591 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/trace/span.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/trace/span.go
@@ -20,7 +20,7 @@ import (
"go.opentelemetry.io/otel/internal/global"
"go.opentelemetry.io/otel/sdk/instrumentation"
"go.opentelemetry.io/otel/sdk/resource"
- semconv "go.opentelemetry.io/otel/semconv/v1.26.0"
+ semconv "go.opentelemetry.io/otel/semconv/v1.39.0"
"go.opentelemetry.io/otel/trace"
"go.opentelemetry.io/otel/trace/embedded"
)
@@ -61,6 +61,7 @@ type ReadOnlySpan interface {
InstrumentationScope() instrumentation.Scope
// InstrumentationLibrary returns information about the instrumentation
// library that created the span.
+ //
// Deprecated: please use InstrumentationScope instead.
InstrumentationLibrary() instrumentation.Library //nolint:staticcheck // This method needs to be define for backwards compatibility
// Resource returns information about the entity that produced the span.
@@ -150,6 +151,12 @@ type recordingSpan struct {
// tracer is the SDK tracer that created this span.
tracer *tracer
+
+ // origCtx is the context used when starting this span that has the
+ // recordingSpan instance set as the active span. If not nil, it is used
+ // when ending the span to ensure any metrics are recorded with a context
+ // containing this span without requiring an additional allocation.
+ origCtx context.Context
}
var (
@@ -157,6 +164,10 @@ var (
_ runtimeTracer = (*recordingSpan)(nil)
)
+func (s *recordingSpan) setOrigCtx(ctx context.Context) {
+ s.origCtx = ctx
+}
+
// SpanContext returns the SpanContext of this span.
func (s *recordingSpan) SpanContext() trace.SpanContext {
if s == nil {
@@ -165,7 +176,7 @@ func (s *recordingSpan) SpanContext() trace.SpanContext {
return s.spanContext
}
-// IsRecording returns if this span is being recorded. If this span has ended
+// IsRecording reports whether this span is being recorded. If this span has ended
// this will return false.
func (s *recordingSpan) IsRecording() bool {
if s == nil {
@@ -177,7 +188,7 @@ func (s *recordingSpan) IsRecording() bool {
return s.isRecording()
}
-// isRecording returns if this span is being recorded. If this span has ended
+// isRecording reports whether this span is being recorded. If this span has ended
// this will return false.
//
// This method assumes s.mu.Lock is held by the caller.
@@ -495,6 +506,17 @@ func (s *recordingSpan) End(options ...trace.SpanEndOption) {
}
s.mu.Unlock()
+ if s.tracer.inst.Enabled() {
+ ctx := s.origCtx
+ if ctx == nil {
+ // This should not happen as the origCtx should be set, but
+ // ensure trace information is propagated in the case of an
+ // error.
+ ctx = trace.ContextWithSpan(context.Background(), s)
+ }
+ defer s.tracer.inst.SpanEnded(ctx, s)
+ }
+
sps := s.tracer.provider.getSpanProcessors()
if len(sps) == 0 {
return
@@ -545,7 +567,7 @@ func (s *recordingSpan) RecordError(err error, opts ...trace.EventOption) {
s.addEvent(semconv.ExceptionEventName, opts...)
}
-func typeStr(i interface{}) string {
+func typeStr(i any) string {
t := reflect.TypeOf(i)
if t.PkgPath() == "" && t.Name() == "" {
// Likely a builtin type.
diff --git a/vendor/go.opentelemetry.io/otel/sdk/trace/span_limits.go b/vendor/go.opentelemetry.io/otel/sdk/trace/span_limits.go
index bec5e20978..321d974305 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/trace/span_limits.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/trace/span_limits.go
@@ -3,7 +3,7 @@
package trace // import "go.opentelemetry.io/otel/sdk/trace"
-import "go.opentelemetry.io/otel/sdk/internal/env"
+import "go.opentelemetry.io/otel/sdk/trace/internal/env"
const (
// DefaultAttributeValueLengthLimit is the default maximum allowed
diff --git a/vendor/go.opentelemetry.io/otel/sdk/trace/tracer.go b/vendor/go.opentelemetry.io/otel/sdk/trace/tracer.go
index 0b65ae9ab7..e1d08fd4d8 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/trace/tracer.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/trace/tracer.go
@@ -8,6 +8,7 @@ import (
"time"
"go.opentelemetry.io/otel/sdk/instrumentation"
+ "go.opentelemetry.io/otel/sdk/trace/internal/observ"
"go.opentelemetry.io/otel/trace"
"go.opentelemetry.io/otel/trace/embedded"
)
@@ -17,6 +18,8 @@ type tracer struct {
provider *TracerProvider
instrumentationScope instrumentation.Scope
+
+ inst observ.Tracer
}
var _ trace.Tracer = &tracer{}
@@ -46,17 +49,32 @@ func (tr *tracer) Start(
}
s := tr.newSpan(ctx, name, &config)
+ newCtx := trace.ContextWithSpan(ctx, s)
+ if tr.inst.Enabled() {
+ if o, ok := s.(interface{ setOrigCtx(context.Context) }); ok {
+ // If this is a recording span, store the original context.
+ // This allows later retrieval of baggage and other information
+ // that may have been stored in the context at span start time and
+ // to avoid the allocation of repeatedly calling
+ // trace.ContextWithSpan.
+ o.setOrigCtx(newCtx)
+ }
+ psc := trace.SpanContextFromContext(ctx)
+ tr.inst.SpanStarted(newCtx, psc, s)
+ }
+
if rw, ok := s.(ReadWriteSpan); ok && s.IsRecording() {
sps := tr.provider.getSpanProcessors()
for _, sp := range sps {
+ // Use original context.
sp.sp.OnStart(ctx, rw)
}
}
if rtt, ok := s.(runtimeTracer); ok {
- ctx = rtt.runtimeTrace(ctx)
+ newCtx = rtt.runtimeTrace(newCtx)
}
- return trace.ContextWithSpan(ctx, s), s
+ return newCtx, s
}
type runtimeTracer interface {
@@ -112,11 +130,12 @@ func (tr *tracer) newSpan(ctx context.Context, name string, config *trace.SpanCo
if !isRecording(samplingResult) {
return tr.newNonRecordingSpan(sc)
}
- return tr.newRecordingSpan(psc, sc, name, samplingResult, config)
+ return tr.newRecordingSpan(ctx, psc, sc, name, samplingResult, config)
}
// newRecordingSpan returns a new configured recordingSpan.
func (tr *tracer) newRecordingSpan(
+ ctx context.Context,
psc, sc trace.SpanContext,
name string,
sr SamplingResult,
@@ -153,6 +172,13 @@ func (tr *tracer) newRecordingSpan(
s.SetAttributes(sr.Attributes...)
s.SetAttributes(config.Attributes()...)
+ if tr.inst.Enabled() {
+ // Propagate any existing values from the context with the new span to
+ // the measurement context.
+ ctx = trace.ContextWithSpan(ctx, s)
+ tr.inst.SpanLive(ctx, s)
+ }
+
return s
}
diff --git a/vendor/go.opentelemetry.io/otel/sdk/trace/version.go b/vendor/go.opentelemetry.io/otel/sdk/trace/version.go
deleted file mode 100644
index b84dd2c5ee..0000000000
--- a/vendor/go.opentelemetry.io/otel/sdk/trace/version.go
+++ /dev/null
@@ -1,9 +0,0 @@
-// Copyright The OpenTelemetry Authors
-// SPDX-License-Identifier: Apache-2.0
-
-package trace // import "go.opentelemetry.io/otel/sdk/trace"
-
-// version is the current release version of the metric SDK in use.
-func version() string {
- return "1.16.0-rc.1"
-}
diff --git a/vendor/go.opentelemetry.io/otel/sdk/version.go b/vendor/go.opentelemetry.io/otel/sdk/version.go
index 1af257449a..b5497c2816 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/version.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/version.go
@@ -6,5 +6,5 @@ package sdk // import "go.opentelemetry.io/otel/sdk"
// Version is the current release version of the OpenTelemetry SDK in use.
func Version() string {
- return "1.36.0"
+ return "1.40.0"
}
diff --git a/vendor/go.opentelemetry.io/otel/semconv/internal/http.go b/vendor/go.opentelemetry.io/otel/semconv/internal/http.go
index e9eb577345..f18d6e3f22 100644
--- a/vendor/go.opentelemetry.io/otel/semconv/internal/http.go
+++ b/vendor/go.opentelemetry.io/otel/semconv/internal/http.go
@@ -104,7 +104,7 @@ func (sc *SemanticConventions) NetAttributesFromHTTPRequest(
// It handles both IPv4 and IPv6 addresses. If the host portion is not recognized
// as a valid IPv4 or IPv6 address, the `ip` result will be empty and the
// host portion will instead be returned in `name`.
-func hostIPNamePort(hostWithPort string) (ip string, name string, port int) {
+func hostIPNamePort(hostWithPort string) (ip, name string, port int) {
var (
hostPart, portPart string
parsedPort uint64
@@ -121,7 +121,7 @@ func hostIPNamePort(hostWithPort string) (ip string, name string, port int) {
if parsedPort, err = strconv.ParseUint(portPart, 10, 16); err == nil {
port = int(parsedPort) // nolint: gosec // Bit size of 16 checked above.
}
- return
+ return ip, name, port
}
// EndUserAttributesFromHTTPRequest generates attributes of the
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.20.0/README.md b/vendor/go.opentelemetry.io/otel/semconv/v1.20.0/README.md
deleted file mode 100644
index 82e1f46b4e..0000000000
--- a/vendor/go.opentelemetry.io/otel/semconv/v1.20.0/README.md
+++ /dev/null
@@ -1,3 +0,0 @@
-# Semconv v1.20.0
-
-[](https://pkg.go.dev/go.opentelemetry.io/otel/semconv/v1.20.0)
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.20.0/attribute_group.go b/vendor/go.opentelemetry.io/otel/semconv/v1.20.0/attribute_group.go
deleted file mode 100644
index 6685c392b5..0000000000
--- a/vendor/go.opentelemetry.io/otel/semconv/v1.20.0/attribute_group.go
+++ /dev/null
@@ -1,1198 +0,0 @@
-// Copyright The OpenTelemetry Authors
-// SPDX-License-Identifier: Apache-2.0
-
-// Code generated from semantic convention specification. DO NOT EDIT.
-
-package semconv // import "go.opentelemetry.io/otel/semconv/v1.20.0"
-
-import "go.opentelemetry.io/otel/attribute"
-
-// Describes HTTP attributes.
-const (
- // HTTPMethodKey is the attribute Key conforming to the "http.method"
- // semantic conventions. It represents the hTTP request method.
- //
- // Type: string
- // RequirementLevel: Required
- // Stability: stable
- // Examples: 'GET', 'POST', 'HEAD'
- HTTPMethodKey = attribute.Key("http.method")
-
- // HTTPStatusCodeKey is the attribute Key conforming to the
- // "http.status_code" semantic conventions. It represents the [HTTP
- // response status code](https://tools.ietf.org/html/rfc7231#section-6).
- //
- // Type: int
- // RequirementLevel: ConditionallyRequired (If and only if one was
- // received/sent.)
- // Stability: stable
- // Examples: 200
- HTTPStatusCodeKey = attribute.Key("http.status_code")
-)
-
-// HTTPMethod returns an attribute KeyValue conforming to the "http.method"
-// semantic conventions. It represents the hTTP request method.
-func HTTPMethod(val string) attribute.KeyValue {
- return HTTPMethodKey.String(val)
-}
-
-// HTTPStatusCode returns an attribute KeyValue conforming to the
-// "http.status_code" semantic conventions. It represents the [HTTP response
-// status code](https://tools.ietf.org/html/rfc7231#section-6).
-func HTTPStatusCode(val int) attribute.KeyValue {
- return HTTPStatusCodeKey.Int(val)
-}
-
-// HTTP Server spans attributes
-const (
- // HTTPSchemeKey is the attribute Key conforming to the "http.scheme"
- // semantic conventions. It represents the URI scheme identifying the used
- // protocol.
- //
- // Type: string
- // RequirementLevel: Required
- // Stability: stable
- // Examples: 'http', 'https'
- HTTPSchemeKey = attribute.Key("http.scheme")
-
- // HTTPRouteKey is the attribute Key conforming to the "http.route"
- // semantic conventions. It represents the matched route (path template in
- // the format used by the respective server framework). See note below
- //
- // Type: string
- // RequirementLevel: ConditionallyRequired (If and only if it's available)
- // Stability: stable
- // Examples: '/users/:userID?', '{controller}/{action}/{id?}'
- // Note: MUST NOT be populated when this is not supported by the HTTP
- // server framework as the route attribute should have low-cardinality and
- // the URI path can NOT substitute it.
- // SHOULD include the [application
- // root](/specification/trace/semantic_conventions/http.md#http-server-definitions)
- // if there is one.
- HTTPRouteKey = attribute.Key("http.route")
-)
-
-// HTTPScheme returns an attribute KeyValue conforming to the "http.scheme"
-// semantic conventions. It represents the URI scheme identifying the used
-// protocol.
-func HTTPScheme(val string) attribute.KeyValue {
- return HTTPSchemeKey.String(val)
-}
-
-// HTTPRoute returns an attribute KeyValue conforming to the "http.route"
-// semantic conventions. It represents the matched route (path template in the
-// format used by the respective server framework). See note below
-func HTTPRoute(val string) attribute.KeyValue {
- return HTTPRouteKey.String(val)
-}
-
-// Attributes for Events represented using Log Records.
-const (
- // EventNameKey is the attribute Key conforming to the "event.name"
- // semantic conventions. It represents the name identifies the event.
- //
- // Type: string
- // RequirementLevel: Required
- // Stability: stable
- // Examples: 'click', 'exception'
- EventNameKey = attribute.Key("event.name")
-
- // EventDomainKey is the attribute Key conforming to the "event.domain"
- // semantic conventions. It represents the domain identifies the business
- // context for the events.
- //
- // Type: Enum
- // RequirementLevel: Required
- // Stability: stable
- // Note: Events across different domains may have same `event.name`, yet be
- // unrelated events.
- EventDomainKey = attribute.Key("event.domain")
-)
-
-var (
- // Events from browser apps
- EventDomainBrowser = EventDomainKey.String("browser")
- // Events from mobile apps
- EventDomainDevice = EventDomainKey.String("device")
- // Events from Kubernetes
- EventDomainK8S = EventDomainKey.String("k8s")
-)
-
-// EventName returns an attribute KeyValue conforming to the "event.name"
-// semantic conventions. It represents the name identifies the event.
-func EventName(val string) attribute.KeyValue {
- return EventNameKey.String(val)
-}
-
-// These attributes may be used for any network related operation.
-const (
- // NetTransportKey is the attribute Key conforming to the "net.transport"
- // semantic conventions. It represents the transport protocol used. See
- // note below.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: stable
- NetTransportKey = attribute.Key("net.transport")
-
- // NetProtocolNameKey is the attribute Key conforming to the
- // "net.protocol.name" semantic conventions. It represents the application
- // layer protocol used. The value SHOULD be normalized to lowercase.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'amqp', 'http', 'mqtt'
- NetProtocolNameKey = attribute.Key("net.protocol.name")
-
- // NetProtocolVersionKey is the attribute Key conforming to the
- // "net.protocol.version" semantic conventions. It represents the version
- // of the application layer protocol used. See note below.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '3.1.1'
- // Note: `net.protocol.version` refers to the version of the protocol used
- // and might be different from the protocol client's version. If the HTTP
- // client used has a version of `0.27.2`, but sends HTTP version `1.1`,
- // this attribute should be set to `1.1`.
- NetProtocolVersionKey = attribute.Key("net.protocol.version")
-
- // NetSockPeerNameKey is the attribute Key conforming to the
- // "net.sock.peer.name" semantic conventions. It represents the remote
- // socket peer name.
- //
- // Type: string
- // RequirementLevel: Recommended (If available and different from
- // `net.peer.name` and if `net.sock.peer.addr` is set.)
- // Stability: stable
- // Examples: 'proxy.example.com'
- NetSockPeerNameKey = attribute.Key("net.sock.peer.name")
-
- // NetSockPeerAddrKey is the attribute Key conforming to the
- // "net.sock.peer.addr" semantic conventions. It represents the remote
- // socket peer address: IPv4 or IPv6 for internet protocols, path for local
- // communication,
- // [etc](https://man7.org/linux/man-pages/man7/address_families.7.html).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '127.0.0.1', '/tmp/mysql.sock'
- NetSockPeerAddrKey = attribute.Key("net.sock.peer.addr")
-
- // NetSockPeerPortKey is the attribute Key conforming to the
- // "net.sock.peer.port" semantic conventions. It represents the remote
- // socket peer port.
- //
- // Type: int
- // RequirementLevel: Recommended (If defined for the address family and if
- // different than `net.peer.port` and if `net.sock.peer.addr` is set.)
- // Stability: stable
- // Examples: 16456
- NetSockPeerPortKey = attribute.Key("net.sock.peer.port")
-
- // NetSockFamilyKey is the attribute Key conforming to the
- // "net.sock.family" semantic conventions. It represents the protocol
- // [address
- // family](https://man7.org/linux/man-pages/man7/address_families.7.html)
- // which is used for communication.
- //
- // Type: Enum
- // RequirementLevel: ConditionallyRequired (If different than `inet` and if
- // any of `net.sock.peer.addr` or `net.sock.host.addr` are set. Consumers
- // of telemetry SHOULD accept both IPv4 and IPv6 formats for the address in
- // `net.sock.peer.addr` if `net.sock.family` is not set. This is to support
- // instrumentations that follow previous versions of this document.)
- // Stability: stable
- // Examples: 'inet6', 'bluetooth'
- NetSockFamilyKey = attribute.Key("net.sock.family")
-
- // NetPeerNameKey is the attribute Key conforming to the "net.peer.name"
- // semantic conventions. It represents the logical remote hostname, see
- // note below.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'example.com'
- // Note: `net.peer.name` SHOULD NOT be set if capturing it would require an
- // extra DNS lookup.
- NetPeerNameKey = attribute.Key("net.peer.name")
-
- // NetPeerPortKey is the attribute Key conforming to the "net.peer.port"
- // semantic conventions. It represents the logical remote port number
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 80, 8080, 443
- NetPeerPortKey = attribute.Key("net.peer.port")
-
- // NetHostNameKey is the attribute Key conforming to the "net.host.name"
- // semantic conventions. It represents the logical local hostname or
- // similar, see note below.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'localhost'
- NetHostNameKey = attribute.Key("net.host.name")
-
- // NetHostPortKey is the attribute Key conforming to the "net.host.port"
- // semantic conventions. It represents the logical local port number,
- // preferably the one that the peer used to connect
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 8080
- NetHostPortKey = attribute.Key("net.host.port")
-
- // NetSockHostAddrKey is the attribute Key conforming to the
- // "net.sock.host.addr" semantic conventions. It represents the local
- // socket address. Useful in case of a multi-IP host.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '192.168.0.1'
- NetSockHostAddrKey = attribute.Key("net.sock.host.addr")
-
- // NetSockHostPortKey is the attribute Key conforming to the
- // "net.sock.host.port" semantic conventions. It represents the local
- // socket port number.
- //
- // Type: int
- // RequirementLevel: ConditionallyRequired (If defined for the address
- // family and if different than `net.host.port` and if `net.sock.host.addr`
- // is set. In other cases, it is still recommended to set this.)
- // Stability: stable
- // Examples: 35555
- NetSockHostPortKey = attribute.Key("net.sock.host.port")
-)
-
-var (
- // ip_tcp
- NetTransportTCP = NetTransportKey.String("ip_tcp")
- // ip_udp
- NetTransportUDP = NetTransportKey.String("ip_udp")
- // Named or anonymous pipe. See note below
- NetTransportPipe = NetTransportKey.String("pipe")
- // In-process communication
- NetTransportInProc = NetTransportKey.String("inproc")
- // Something else (non IP-based)
- NetTransportOther = NetTransportKey.String("other")
-)
-
-var (
- // IPv4 address
- NetSockFamilyInet = NetSockFamilyKey.String("inet")
- // IPv6 address
- NetSockFamilyInet6 = NetSockFamilyKey.String("inet6")
- // Unix domain socket path
- NetSockFamilyUnix = NetSockFamilyKey.String("unix")
-)
-
-// NetProtocolName returns an attribute KeyValue conforming to the
-// "net.protocol.name" semantic conventions. It represents the application
-// layer protocol used. The value SHOULD be normalized to lowercase.
-func NetProtocolName(val string) attribute.KeyValue {
- return NetProtocolNameKey.String(val)
-}
-
-// NetProtocolVersion returns an attribute KeyValue conforming to the
-// "net.protocol.version" semantic conventions. It represents the version of
-// the application layer protocol used. See note below.
-func NetProtocolVersion(val string) attribute.KeyValue {
- return NetProtocolVersionKey.String(val)
-}
-
-// NetSockPeerName returns an attribute KeyValue conforming to the
-// "net.sock.peer.name" semantic conventions. It represents the remote socket
-// peer name.
-func NetSockPeerName(val string) attribute.KeyValue {
- return NetSockPeerNameKey.String(val)
-}
-
-// NetSockPeerAddr returns an attribute KeyValue conforming to the
-// "net.sock.peer.addr" semantic conventions. It represents the remote socket
-// peer address: IPv4 or IPv6 for internet protocols, path for local
-// communication,
-// [etc](https://man7.org/linux/man-pages/man7/address_families.7.html).
-func NetSockPeerAddr(val string) attribute.KeyValue {
- return NetSockPeerAddrKey.String(val)
-}
-
-// NetSockPeerPort returns an attribute KeyValue conforming to the
-// "net.sock.peer.port" semantic conventions. It represents the remote socket
-// peer port.
-func NetSockPeerPort(val int) attribute.KeyValue {
- return NetSockPeerPortKey.Int(val)
-}
-
-// NetPeerName returns an attribute KeyValue conforming to the
-// "net.peer.name" semantic conventions. It represents the logical remote
-// hostname, see note below.
-func NetPeerName(val string) attribute.KeyValue {
- return NetPeerNameKey.String(val)
-}
-
-// NetPeerPort returns an attribute KeyValue conforming to the
-// "net.peer.port" semantic conventions. It represents the logical remote port
-// number
-func NetPeerPort(val int) attribute.KeyValue {
- return NetPeerPortKey.Int(val)
-}
-
-// NetHostName returns an attribute KeyValue conforming to the
-// "net.host.name" semantic conventions. It represents the logical local
-// hostname or similar, see note below.
-func NetHostName(val string) attribute.KeyValue {
- return NetHostNameKey.String(val)
-}
-
-// NetHostPort returns an attribute KeyValue conforming to the
-// "net.host.port" semantic conventions. It represents the logical local port
-// number, preferably the one that the peer used to connect
-func NetHostPort(val int) attribute.KeyValue {
- return NetHostPortKey.Int(val)
-}
-
-// NetSockHostAddr returns an attribute KeyValue conforming to the
-// "net.sock.host.addr" semantic conventions. It represents the local socket
-// address. Useful in case of a multi-IP host.
-func NetSockHostAddr(val string) attribute.KeyValue {
- return NetSockHostAddrKey.String(val)
-}
-
-// NetSockHostPort returns an attribute KeyValue conforming to the
-// "net.sock.host.port" semantic conventions. It represents the local socket
-// port number.
-func NetSockHostPort(val int) attribute.KeyValue {
- return NetSockHostPortKey.Int(val)
-}
-
-// These attributes may be used for any network related operation.
-const (
- // NetHostConnectionTypeKey is the attribute Key conforming to the
- // "net.host.connection.type" semantic conventions. It represents the
- // internet connection type currently being used by the host.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'wifi'
- NetHostConnectionTypeKey = attribute.Key("net.host.connection.type")
-
- // NetHostConnectionSubtypeKey is the attribute Key conforming to the
- // "net.host.connection.subtype" semantic conventions. It represents the
- // this describes more details regarding the connection.type. It may be the
- // type of cell technology connection, but it could be used for describing
- // details about a wifi connection.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'LTE'
- NetHostConnectionSubtypeKey = attribute.Key("net.host.connection.subtype")
-
- // NetHostCarrierNameKey is the attribute Key conforming to the
- // "net.host.carrier.name" semantic conventions. It represents the name of
- // the mobile carrier.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'sprint'
- NetHostCarrierNameKey = attribute.Key("net.host.carrier.name")
-
- // NetHostCarrierMccKey is the attribute Key conforming to the
- // "net.host.carrier.mcc" semantic conventions. It represents the mobile
- // carrier country code.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '310'
- NetHostCarrierMccKey = attribute.Key("net.host.carrier.mcc")
-
- // NetHostCarrierMncKey is the attribute Key conforming to the
- // "net.host.carrier.mnc" semantic conventions. It represents the mobile
- // carrier network code.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '001'
- NetHostCarrierMncKey = attribute.Key("net.host.carrier.mnc")
-
- // NetHostCarrierIccKey is the attribute Key conforming to the
- // "net.host.carrier.icc" semantic conventions. It represents the ISO
- // 3166-1 alpha-2 2-character country code associated with the mobile
- // carrier network.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'DE'
- NetHostCarrierIccKey = attribute.Key("net.host.carrier.icc")
-)
-
-var (
- // wifi
- NetHostConnectionTypeWifi = NetHostConnectionTypeKey.String("wifi")
- // wired
- NetHostConnectionTypeWired = NetHostConnectionTypeKey.String("wired")
- // cell
- NetHostConnectionTypeCell = NetHostConnectionTypeKey.String("cell")
- // unavailable
- NetHostConnectionTypeUnavailable = NetHostConnectionTypeKey.String("unavailable")
- // unknown
- NetHostConnectionTypeUnknown = NetHostConnectionTypeKey.String("unknown")
-)
-
-var (
- // GPRS
- NetHostConnectionSubtypeGprs = NetHostConnectionSubtypeKey.String("gprs")
- // EDGE
- NetHostConnectionSubtypeEdge = NetHostConnectionSubtypeKey.String("edge")
- // UMTS
- NetHostConnectionSubtypeUmts = NetHostConnectionSubtypeKey.String("umts")
- // CDMA
- NetHostConnectionSubtypeCdma = NetHostConnectionSubtypeKey.String("cdma")
- // EVDO Rel. 0
- NetHostConnectionSubtypeEvdo0 = NetHostConnectionSubtypeKey.String("evdo_0")
- // EVDO Rev. A
- NetHostConnectionSubtypeEvdoA = NetHostConnectionSubtypeKey.String("evdo_a")
- // CDMA2000 1XRTT
- NetHostConnectionSubtypeCdma20001xrtt = NetHostConnectionSubtypeKey.String("cdma2000_1xrtt")
- // HSDPA
- NetHostConnectionSubtypeHsdpa = NetHostConnectionSubtypeKey.String("hsdpa")
- // HSUPA
- NetHostConnectionSubtypeHsupa = NetHostConnectionSubtypeKey.String("hsupa")
- // HSPA
- NetHostConnectionSubtypeHspa = NetHostConnectionSubtypeKey.String("hspa")
- // IDEN
- NetHostConnectionSubtypeIden = NetHostConnectionSubtypeKey.String("iden")
- // EVDO Rev. B
- NetHostConnectionSubtypeEvdoB = NetHostConnectionSubtypeKey.String("evdo_b")
- // LTE
- NetHostConnectionSubtypeLte = NetHostConnectionSubtypeKey.String("lte")
- // EHRPD
- NetHostConnectionSubtypeEhrpd = NetHostConnectionSubtypeKey.String("ehrpd")
- // HSPAP
- NetHostConnectionSubtypeHspap = NetHostConnectionSubtypeKey.String("hspap")
- // GSM
- NetHostConnectionSubtypeGsm = NetHostConnectionSubtypeKey.String("gsm")
- // TD-SCDMA
- NetHostConnectionSubtypeTdScdma = NetHostConnectionSubtypeKey.String("td_scdma")
- // IWLAN
- NetHostConnectionSubtypeIwlan = NetHostConnectionSubtypeKey.String("iwlan")
- // 5G NR (New Radio)
- NetHostConnectionSubtypeNr = NetHostConnectionSubtypeKey.String("nr")
- // 5G NRNSA (New Radio Non-Standalone)
- NetHostConnectionSubtypeNrnsa = NetHostConnectionSubtypeKey.String("nrnsa")
- // LTE CA
- NetHostConnectionSubtypeLteCa = NetHostConnectionSubtypeKey.String("lte_ca")
-)
-
-// NetHostCarrierName returns an attribute KeyValue conforming to the
-// "net.host.carrier.name" semantic conventions. It represents the name of the
-// mobile carrier.
-func NetHostCarrierName(val string) attribute.KeyValue {
- return NetHostCarrierNameKey.String(val)
-}
-
-// NetHostCarrierMcc returns an attribute KeyValue conforming to the
-// "net.host.carrier.mcc" semantic conventions. It represents the mobile
-// carrier country code.
-func NetHostCarrierMcc(val string) attribute.KeyValue {
- return NetHostCarrierMccKey.String(val)
-}
-
-// NetHostCarrierMnc returns an attribute KeyValue conforming to the
-// "net.host.carrier.mnc" semantic conventions. It represents the mobile
-// carrier network code.
-func NetHostCarrierMnc(val string) attribute.KeyValue {
- return NetHostCarrierMncKey.String(val)
-}
-
-// NetHostCarrierIcc returns an attribute KeyValue conforming to the
-// "net.host.carrier.icc" semantic conventions. It represents the ISO 3166-1
-// alpha-2 2-character country code associated with the mobile carrier network.
-func NetHostCarrierIcc(val string) attribute.KeyValue {
- return NetHostCarrierIccKey.String(val)
-}
-
-// Semantic conventions for HTTP client and server Spans.
-const (
- // HTTPRequestContentLengthKey is the attribute Key conforming to the
- // "http.request_content_length" semantic conventions. It represents the
- // size of the request payload body in bytes. This is the number of bytes
- // transferred excluding headers and is often, but not always, present as
- // the
- // [Content-Length](https://www.rfc-editor.org/rfc/rfc9110.html#field.content-length)
- // header. For requests using transport encoding, this should be the
- // compressed size.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 3495
- HTTPRequestContentLengthKey = attribute.Key("http.request_content_length")
-
- // HTTPResponseContentLengthKey is the attribute Key conforming to the
- // "http.response_content_length" semantic conventions. It represents the
- // size of the response payload body in bytes. This is the number of bytes
- // transferred excluding headers and is often, but not always, present as
- // the
- // [Content-Length](https://www.rfc-editor.org/rfc/rfc9110.html#field.content-length)
- // header. For requests using transport encoding, this should be the
- // compressed size.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 3495
- HTTPResponseContentLengthKey = attribute.Key("http.response_content_length")
-)
-
-// HTTPRequestContentLength returns an attribute KeyValue conforming to the
-// "http.request_content_length" semantic conventions. It represents the size
-// of the request payload body in bytes. This is the number of bytes
-// transferred excluding headers and is often, but not always, present as the
-// [Content-Length](https://www.rfc-editor.org/rfc/rfc9110.html#field.content-length)
-// header. For requests using transport encoding, this should be the compressed
-// size.
-func HTTPRequestContentLength(val int) attribute.KeyValue {
- return HTTPRequestContentLengthKey.Int(val)
-}
-
-// HTTPResponseContentLength returns an attribute KeyValue conforming to the
-// "http.response_content_length" semantic conventions. It represents the size
-// of the response payload body in bytes. This is the number of bytes
-// transferred excluding headers and is often, but not always, present as the
-// [Content-Length](https://www.rfc-editor.org/rfc/rfc9110.html#field.content-length)
-// header. For requests using transport encoding, this should be the compressed
-// size.
-func HTTPResponseContentLength(val int) attribute.KeyValue {
- return HTTPResponseContentLengthKey.Int(val)
-}
-
-// Semantic convention describing per-message attributes populated on messaging
-// spans or links.
-const (
- // MessagingMessageIDKey is the attribute Key conforming to the
- // "messaging.message.id" semantic conventions. It represents a value used
- // by the messaging system as an identifier for the message, represented as
- // a string.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '452a7c7c7c7048c2f887f61572b18fc2'
- MessagingMessageIDKey = attribute.Key("messaging.message.id")
-
- // MessagingMessageConversationIDKey is the attribute Key conforming to the
- // "messaging.message.conversation_id" semantic conventions. It represents
- // the [conversation ID](#conversations) identifying the conversation to
- // which the message belongs, represented as a string. Sometimes called
- // "Correlation ID".
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'MyConversationID'
- MessagingMessageConversationIDKey = attribute.Key("messaging.message.conversation_id")
-
- // MessagingMessagePayloadSizeBytesKey is the attribute Key conforming to
- // the "messaging.message.payload_size_bytes" semantic conventions. It
- // represents the (uncompressed) size of the message payload in bytes. Also
- // use this attribute if it is unknown whether the compressed or
- // uncompressed payload size is reported.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 2738
- MessagingMessagePayloadSizeBytesKey = attribute.Key("messaging.message.payload_size_bytes")
-
- // MessagingMessagePayloadCompressedSizeBytesKey is the attribute Key
- // conforming to the "messaging.message.payload_compressed_size_bytes"
- // semantic conventions. It represents the compressed size of the message
- // payload in bytes.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 2048
- MessagingMessagePayloadCompressedSizeBytesKey = attribute.Key("messaging.message.payload_compressed_size_bytes")
-)
-
-// MessagingMessageID returns an attribute KeyValue conforming to the
-// "messaging.message.id" semantic conventions. It represents a value used by
-// the messaging system as an identifier for the message, represented as a
-// string.
-func MessagingMessageID(val string) attribute.KeyValue {
- return MessagingMessageIDKey.String(val)
-}
-
-// MessagingMessageConversationID returns an attribute KeyValue conforming
-// to the "messaging.message.conversation_id" semantic conventions. It
-// represents the [conversation ID](#conversations) identifying the
-// conversation to which the message belongs, represented as a string.
-// Sometimes called "Correlation ID".
-func MessagingMessageConversationID(val string) attribute.KeyValue {
- return MessagingMessageConversationIDKey.String(val)
-}
-
-// MessagingMessagePayloadSizeBytes returns an attribute KeyValue conforming
-// to the "messaging.message.payload_size_bytes" semantic conventions. It
-// represents the (uncompressed) size of the message payload in bytes. Also use
-// this attribute if it is unknown whether the compressed or uncompressed
-// payload size is reported.
-func MessagingMessagePayloadSizeBytes(val int) attribute.KeyValue {
- return MessagingMessagePayloadSizeBytesKey.Int(val)
-}
-
-// MessagingMessagePayloadCompressedSizeBytes returns an attribute KeyValue
-// conforming to the "messaging.message.payload_compressed_size_bytes" semantic
-// conventions. It represents the compressed size of the message payload in
-// bytes.
-func MessagingMessagePayloadCompressedSizeBytes(val int) attribute.KeyValue {
- return MessagingMessagePayloadCompressedSizeBytesKey.Int(val)
-}
-
-// Semantic convention for attributes that describe messaging destination on
-// broker
-const (
- // MessagingDestinationNameKey is the attribute Key conforming to the
- // "messaging.destination.name" semantic conventions. It represents the
- // message destination name
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'MyQueue', 'MyTopic'
- // Note: Destination name SHOULD uniquely identify a specific queue, topic
- // or other entity within the broker. If
- // the broker does not have such notion, the destination name SHOULD
- // uniquely identify the broker.
- MessagingDestinationNameKey = attribute.Key("messaging.destination.name")
-
- // MessagingDestinationTemplateKey is the attribute Key conforming to the
- // "messaging.destination.template" semantic conventions. It represents the
- // low cardinality representation of the messaging destination name
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '/customers/{customerID}'
- // Note: Destination names could be constructed from templates. An example
- // would be a destination name involving a user name or product id.
- // Although the destination name in this case is of high cardinality, the
- // underlying template is of low cardinality and can be effectively used
- // for grouping and aggregation.
- MessagingDestinationTemplateKey = attribute.Key("messaging.destination.template")
-
- // MessagingDestinationTemporaryKey is the attribute Key conforming to the
- // "messaging.destination.temporary" semantic conventions. It represents a
- // boolean that is true if the message destination is temporary and might
- // not exist anymore after messages are processed.
- //
- // Type: boolean
- // RequirementLevel: Optional
- // Stability: stable
- MessagingDestinationTemporaryKey = attribute.Key("messaging.destination.temporary")
-
- // MessagingDestinationAnonymousKey is the attribute Key conforming to the
- // "messaging.destination.anonymous" semantic conventions. It represents a
- // boolean that is true if the message destination is anonymous (could be
- // unnamed or have auto-generated name).
- //
- // Type: boolean
- // RequirementLevel: Optional
- // Stability: stable
- MessagingDestinationAnonymousKey = attribute.Key("messaging.destination.anonymous")
-)
-
-// MessagingDestinationName returns an attribute KeyValue conforming to the
-// "messaging.destination.name" semantic conventions. It represents the message
-// destination name
-func MessagingDestinationName(val string) attribute.KeyValue {
- return MessagingDestinationNameKey.String(val)
-}
-
-// MessagingDestinationTemplate returns an attribute KeyValue conforming to
-// the "messaging.destination.template" semantic conventions. It represents the
-// low cardinality representation of the messaging destination name
-func MessagingDestinationTemplate(val string) attribute.KeyValue {
- return MessagingDestinationTemplateKey.String(val)
-}
-
-// MessagingDestinationTemporary returns an attribute KeyValue conforming to
-// the "messaging.destination.temporary" semantic conventions. It represents a
-// boolean that is true if the message destination is temporary and might not
-// exist anymore after messages are processed.
-func MessagingDestinationTemporary(val bool) attribute.KeyValue {
- return MessagingDestinationTemporaryKey.Bool(val)
-}
-
-// MessagingDestinationAnonymous returns an attribute KeyValue conforming to
-// the "messaging.destination.anonymous" semantic conventions. It represents a
-// boolean that is true if the message destination is anonymous (could be
-// unnamed or have auto-generated name).
-func MessagingDestinationAnonymous(val bool) attribute.KeyValue {
- return MessagingDestinationAnonymousKey.Bool(val)
-}
-
-// Semantic convention for attributes that describe messaging source on broker
-const (
- // MessagingSourceNameKey is the attribute Key conforming to the
- // "messaging.source.name" semantic conventions. It represents the message
- // source name
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'MyQueue', 'MyTopic'
- // Note: Source name SHOULD uniquely identify a specific queue, topic, or
- // other entity within the broker. If
- // the broker does not have such notion, the source name SHOULD uniquely
- // identify the broker.
- MessagingSourceNameKey = attribute.Key("messaging.source.name")
-
- // MessagingSourceTemplateKey is the attribute Key conforming to the
- // "messaging.source.template" semantic conventions. It represents the low
- // cardinality representation of the messaging source name
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '/customers/{customerID}'
- // Note: Source names could be constructed from templates. An example would
- // be a source name involving a user name or product id. Although the
- // source name in this case is of high cardinality, the underlying template
- // is of low cardinality and can be effectively used for grouping and
- // aggregation.
- MessagingSourceTemplateKey = attribute.Key("messaging.source.template")
-
- // MessagingSourceTemporaryKey is the attribute Key conforming to the
- // "messaging.source.temporary" semantic conventions. It represents a
- // boolean that is true if the message source is temporary and might not
- // exist anymore after messages are processed.
- //
- // Type: boolean
- // RequirementLevel: Optional
- // Stability: stable
- MessagingSourceTemporaryKey = attribute.Key("messaging.source.temporary")
-
- // MessagingSourceAnonymousKey is the attribute Key conforming to the
- // "messaging.source.anonymous" semantic conventions. It represents a
- // boolean that is true if the message source is anonymous (could be
- // unnamed or have auto-generated name).
- //
- // Type: boolean
- // RequirementLevel: Optional
- // Stability: stable
- MessagingSourceAnonymousKey = attribute.Key("messaging.source.anonymous")
-)
-
-// MessagingSourceName returns an attribute KeyValue conforming to the
-// "messaging.source.name" semantic conventions. It represents the message
-// source name
-func MessagingSourceName(val string) attribute.KeyValue {
- return MessagingSourceNameKey.String(val)
-}
-
-// MessagingSourceTemplate returns an attribute KeyValue conforming to the
-// "messaging.source.template" semantic conventions. It represents the low
-// cardinality representation of the messaging source name
-func MessagingSourceTemplate(val string) attribute.KeyValue {
- return MessagingSourceTemplateKey.String(val)
-}
-
-// MessagingSourceTemporary returns an attribute KeyValue conforming to the
-// "messaging.source.temporary" semantic conventions. It represents a boolean
-// that is true if the message source is temporary and might not exist anymore
-// after messages are processed.
-func MessagingSourceTemporary(val bool) attribute.KeyValue {
- return MessagingSourceTemporaryKey.Bool(val)
-}
-
-// MessagingSourceAnonymous returns an attribute KeyValue conforming to the
-// "messaging.source.anonymous" semantic conventions. It represents a boolean
-// that is true if the message source is anonymous (could be unnamed or have
-// auto-generated name).
-func MessagingSourceAnonymous(val bool) attribute.KeyValue {
- return MessagingSourceAnonymousKey.Bool(val)
-}
-
-// Attributes for RabbitMQ
-const (
- // MessagingRabbitmqDestinationRoutingKeyKey is the attribute Key
- // conforming to the "messaging.rabbitmq.destination.routing_key" semantic
- // conventions. It represents the rabbitMQ message routing key.
- //
- // Type: string
- // RequirementLevel: ConditionallyRequired (If not empty.)
- // Stability: stable
- // Examples: 'myKey'
- MessagingRabbitmqDestinationRoutingKeyKey = attribute.Key("messaging.rabbitmq.destination.routing_key")
-)
-
-// MessagingRabbitmqDestinationRoutingKey returns an attribute KeyValue
-// conforming to the "messaging.rabbitmq.destination.routing_key" semantic
-// conventions. It represents the rabbitMQ message routing key.
-func MessagingRabbitmqDestinationRoutingKey(val string) attribute.KeyValue {
- return MessagingRabbitmqDestinationRoutingKeyKey.String(val)
-}
-
-// Attributes for Apache Kafka
-const (
- // MessagingKafkaMessageKeyKey is the attribute Key conforming to the
- // "messaging.kafka.message.key" semantic conventions. It represents the
- // message keys in Kafka are used for grouping alike messages to ensure
- // they're processed on the same partition. They differ from
- // `messaging.message.id` in that they're not unique. If the key is `null`,
- // the attribute MUST NOT be set.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'myKey'
- // Note: If the key type is not string, it's string representation has to
- // be supplied for the attribute. If the key has no unambiguous, canonical
- // string form, don't include its value.
- MessagingKafkaMessageKeyKey = attribute.Key("messaging.kafka.message.key")
-
- // MessagingKafkaConsumerGroupKey is the attribute Key conforming to the
- // "messaging.kafka.consumer.group" semantic conventions. It represents the
- // name of the Kafka Consumer Group that is handling the message. Only
- // applies to consumers, not producers.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'my-group'
- MessagingKafkaConsumerGroupKey = attribute.Key("messaging.kafka.consumer.group")
-
- // MessagingKafkaClientIDKey is the attribute Key conforming to the
- // "messaging.kafka.client_id" semantic conventions. It represents the
- // client ID for the Consumer or Producer that is handling the message.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'client-5'
- MessagingKafkaClientIDKey = attribute.Key("messaging.kafka.client_id")
-
- // MessagingKafkaDestinationPartitionKey is the attribute Key conforming to
- // the "messaging.kafka.destination.partition" semantic conventions. It
- // represents the partition the message is sent to.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 2
- MessagingKafkaDestinationPartitionKey = attribute.Key("messaging.kafka.destination.partition")
-
- // MessagingKafkaSourcePartitionKey is the attribute Key conforming to the
- // "messaging.kafka.source.partition" semantic conventions. It represents
- // the partition the message is received from.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 2
- MessagingKafkaSourcePartitionKey = attribute.Key("messaging.kafka.source.partition")
-
- // MessagingKafkaMessageOffsetKey is the attribute Key conforming to the
- // "messaging.kafka.message.offset" semantic conventions. It represents the
- // offset of a record in the corresponding Kafka partition.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 42
- MessagingKafkaMessageOffsetKey = attribute.Key("messaging.kafka.message.offset")
-
- // MessagingKafkaMessageTombstoneKey is the attribute Key conforming to the
- // "messaging.kafka.message.tombstone" semantic conventions. It represents
- // a boolean that is true if the message is a tombstone.
- //
- // Type: boolean
- // RequirementLevel: ConditionallyRequired (If value is `true`. When
- // missing, the value is assumed to be `false`.)
- // Stability: stable
- MessagingKafkaMessageTombstoneKey = attribute.Key("messaging.kafka.message.tombstone")
-)
-
-// MessagingKafkaMessageKey returns an attribute KeyValue conforming to the
-// "messaging.kafka.message.key" semantic conventions. It represents the
-// message keys in Kafka are used for grouping alike messages to ensure they're
-// processed on the same partition. They differ from `messaging.message.id` in
-// that they're not unique. If the key is `null`, the attribute MUST NOT be
-// set.
-func MessagingKafkaMessageKey(val string) attribute.KeyValue {
- return MessagingKafkaMessageKeyKey.String(val)
-}
-
-// MessagingKafkaConsumerGroup returns an attribute KeyValue conforming to
-// the "messaging.kafka.consumer.group" semantic conventions. It represents the
-// name of the Kafka Consumer Group that is handling the message. Only applies
-// to consumers, not producers.
-func MessagingKafkaConsumerGroup(val string) attribute.KeyValue {
- return MessagingKafkaConsumerGroupKey.String(val)
-}
-
-// MessagingKafkaClientID returns an attribute KeyValue conforming to the
-// "messaging.kafka.client_id" semantic conventions. It represents the client
-// ID for the Consumer or Producer that is handling the message.
-func MessagingKafkaClientID(val string) attribute.KeyValue {
- return MessagingKafkaClientIDKey.String(val)
-}
-
-// MessagingKafkaDestinationPartition returns an attribute KeyValue
-// conforming to the "messaging.kafka.destination.partition" semantic
-// conventions. It represents the partition the message is sent to.
-func MessagingKafkaDestinationPartition(val int) attribute.KeyValue {
- return MessagingKafkaDestinationPartitionKey.Int(val)
-}
-
-// MessagingKafkaSourcePartition returns an attribute KeyValue conforming to
-// the "messaging.kafka.source.partition" semantic conventions. It represents
-// the partition the message is received from.
-func MessagingKafkaSourcePartition(val int) attribute.KeyValue {
- return MessagingKafkaSourcePartitionKey.Int(val)
-}
-
-// MessagingKafkaMessageOffset returns an attribute KeyValue conforming to
-// the "messaging.kafka.message.offset" semantic conventions. It represents the
-// offset of a record in the corresponding Kafka partition.
-func MessagingKafkaMessageOffset(val int) attribute.KeyValue {
- return MessagingKafkaMessageOffsetKey.Int(val)
-}
-
-// MessagingKafkaMessageTombstone returns an attribute KeyValue conforming
-// to the "messaging.kafka.message.tombstone" semantic conventions. It
-// represents a boolean that is true if the message is a tombstone.
-func MessagingKafkaMessageTombstone(val bool) attribute.KeyValue {
- return MessagingKafkaMessageTombstoneKey.Bool(val)
-}
-
-// Attributes for Apache RocketMQ
-const (
- // MessagingRocketmqNamespaceKey is the attribute Key conforming to the
- // "messaging.rocketmq.namespace" semantic conventions. It represents the
- // namespace of RocketMQ resources, resources in different namespaces are
- // individual.
- //
- // Type: string
- // RequirementLevel: Required
- // Stability: stable
- // Examples: 'myNamespace'
- MessagingRocketmqNamespaceKey = attribute.Key("messaging.rocketmq.namespace")
-
- // MessagingRocketmqClientGroupKey is the attribute Key conforming to the
- // "messaging.rocketmq.client_group" semantic conventions. It represents
- // the name of the RocketMQ producer/consumer group that is handling the
- // message. The client type is identified by the SpanKind.
- //
- // Type: string
- // RequirementLevel: Required
- // Stability: stable
- // Examples: 'myConsumerGroup'
- MessagingRocketmqClientGroupKey = attribute.Key("messaging.rocketmq.client_group")
-
- // MessagingRocketmqClientIDKey is the attribute Key conforming to the
- // "messaging.rocketmq.client_id" semantic conventions. It represents the
- // unique identifier for each client.
- //
- // Type: string
- // RequirementLevel: Required
- // Stability: stable
- // Examples: 'myhost@8742@s8083jm'
- MessagingRocketmqClientIDKey = attribute.Key("messaging.rocketmq.client_id")
-
- // MessagingRocketmqMessageDeliveryTimestampKey is the attribute Key
- // conforming to the "messaging.rocketmq.message.delivery_timestamp"
- // semantic conventions. It represents the timestamp in milliseconds that
- // the delay message is expected to be delivered to consumer.
- //
- // Type: int
- // RequirementLevel: ConditionallyRequired (If the message type is delay
- // and delay time level is not specified.)
- // Stability: stable
- // Examples: 1665987217045
- MessagingRocketmqMessageDeliveryTimestampKey = attribute.Key("messaging.rocketmq.message.delivery_timestamp")
-
- // MessagingRocketmqMessageDelayTimeLevelKey is the attribute Key
- // conforming to the "messaging.rocketmq.message.delay_time_level" semantic
- // conventions. It represents the delay time level for delay message, which
- // determines the message delay time.
- //
- // Type: int
- // RequirementLevel: ConditionallyRequired (If the message type is delay
- // and delivery timestamp is not specified.)
- // Stability: stable
- // Examples: 3
- MessagingRocketmqMessageDelayTimeLevelKey = attribute.Key("messaging.rocketmq.message.delay_time_level")
-
- // MessagingRocketmqMessageGroupKey is the attribute Key conforming to the
- // "messaging.rocketmq.message.group" semantic conventions. It represents
- // the it is essential for FIFO message. Messages that belong to the same
- // message group are always processed one by one within the same consumer
- // group.
- //
- // Type: string
- // RequirementLevel: ConditionallyRequired (If the message type is FIFO.)
- // Stability: stable
- // Examples: 'myMessageGroup'
- MessagingRocketmqMessageGroupKey = attribute.Key("messaging.rocketmq.message.group")
-
- // MessagingRocketmqMessageTypeKey is the attribute Key conforming to the
- // "messaging.rocketmq.message.type" semantic conventions. It represents
- // the type of message.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: stable
- MessagingRocketmqMessageTypeKey = attribute.Key("messaging.rocketmq.message.type")
-
- // MessagingRocketmqMessageTagKey is the attribute Key conforming to the
- // "messaging.rocketmq.message.tag" semantic conventions. It represents the
- // secondary classifier of message besides topic.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'tagA'
- MessagingRocketmqMessageTagKey = attribute.Key("messaging.rocketmq.message.tag")
-
- // MessagingRocketmqMessageKeysKey is the attribute Key conforming to the
- // "messaging.rocketmq.message.keys" semantic conventions. It represents
- // the key(s) of message, another way to mark message besides message id.
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'keyA', 'keyB'
- MessagingRocketmqMessageKeysKey = attribute.Key("messaging.rocketmq.message.keys")
-
- // MessagingRocketmqConsumptionModelKey is the attribute Key conforming to
- // the "messaging.rocketmq.consumption_model" semantic conventions. It
- // represents the model of message consumption. This only applies to
- // consumer spans.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: stable
- MessagingRocketmqConsumptionModelKey = attribute.Key("messaging.rocketmq.consumption_model")
-)
-
-var (
- // Normal message
- MessagingRocketmqMessageTypeNormal = MessagingRocketmqMessageTypeKey.String("normal")
- // FIFO message
- MessagingRocketmqMessageTypeFifo = MessagingRocketmqMessageTypeKey.String("fifo")
- // Delay message
- MessagingRocketmqMessageTypeDelay = MessagingRocketmqMessageTypeKey.String("delay")
- // Transaction message
- MessagingRocketmqMessageTypeTransaction = MessagingRocketmqMessageTypeKey.String("transaction")
-)
-
-var (
- // Clustering consumption model
- MessagingRocketmqConsumptionModelClustering = MessagingRocketmqConsumptionModelKey.String("clustering")
- // Broadcasting consumption model
- MessagingRocketmqConsumptionModelBroadcasting = MessagingRocketmqConsumptionModelKey.String("broadcasting")
-)
-
-// MessagingRocketmqNamespace returns an attribute KeyValue conforming to
-// the "messaging.rocketmq.namespace" semantic conventions. It represents the
-// namespace of RocketMQ resources, resources in different namespaces are
-// individual.
-func MessagingRocketmqNamespace(val string) attribute.KeyValue {
- return MessagingRocketmqNamespaceKey.String(val)
-}
-
-// MessagingRocketmqClientGroup returns an attribute KeyValue conforming to
-// the "messaging.rocketmq.client_group" semantic conventions. It represents
-// the name of the RocketMQ producer/consumer group that is handling the
-// message. The client type is identified by the SpanKind.
-func MessagingRocketmqClientGroup(val string) attribute.KeyValue {
- return MessagingRocketmqClientGroupKey.String(val)
-}
-
-// MessagingRocketmqClientID returns an attribute KeyValue conforming to the
-// "messaging.rocketmq.client_id" semantic conventions. It represents the
-// unique identifier for each client.
-func MessagingRocketmqClientID(val string) attribute.KeyValue {
- return MessagingRocketmqClientIDKey.String(val)
-}
-
-// MessagingRocketmqMessageDeliveryTimestamp returns an attribute KeyValue
-// conforming to the "messaging.rocketmq.message.delivery_timestamp" semantic
-// conventions. It represents the timestamp in milliseconds that the delay
-// message is expected to be delivered to consumer.
-func MessagingRocketmqMessageDeliveryTimestamp(val int) attribute.KeyValue {
- return MessagingRocketmqMessageDeliveryTimestampKey.Int(val)
-}
-
-// MessagingRocketmqMessageDelayTimeLevel returns an attribute KeyValue
-// conforming to the "messaging.rocketmq.message.delay_time_level" semantic
-// conventions. It represents the delay time level for delay message, which
-// determines the message delay time.
-func MessagingRocketmqMessageDelayTimeLevel(val int) attribute.KeyValue {
- return MessagingRocketmqMessageDelayTimeLevelKey.Int(val)
-}
-
-// MessagingRocketmqMessageGroup returns an attribute KeyValue conforming to
-// the "messaging.rocketmq.message.group" semantic conventions. It represents
-// the it is essential for FIFO message. Messages that belong to the same
-// message group are always processed one by one within the same consumer
-// group.
-func MessagingRocketmqMessageGroup(val string) attribute.KeyValue {
- return MessagingRocketmqMessageGroupKey.String(val)
-}
-
-// MessagingRocketmqMessageTag returns an attribute KeyValue conforming to
-// the "messaging.rocketmq.message.tag" semantic conventions. It represents the
-// secondary classifier of message besides topic.
-func MessagingRocketmqMessageTag(val string) attribute.KeyValue {
- return MessagingRocketmqMessageTagKey.String(val)
-}
-
-// MessagingRocketmqMessageKeys returns an attribute KeyValue conforming to
-// the "messaging.rocketmq.message.keys" semantic conventions. It represents
-// the key(s) of message, another way to mark message besides message id.
-func MessagingRocketmqMessageKeys(val ...string) attribute.KeyValue {
- return MessagingRocketmqMessageKeysKey.StringSlice(val)
-}
-
-// Describes user-agent attributes.
-const (
- // UserAgentOriginalKey is the attribute Key conforming to the
- // "user_agent.original" semantic conventions. It represents the value of
- // the [HTTP
- // User-Agent](https://www.rfc-editor.org/rfc/rfc9110.html#field.user-agent)
- // header sent by the client.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'CERN-LineMode/2.15 libwww/2.17b3'
- UserAgentOriginalKey = attribute.Key("user_agent.original")
-)
-
-// UserAgentOriginal returns an attribute KeyValue conforming to the
-// "user_agent.original" semantic conventions. It represents the value of the
-// [HTTP
-// User-Agent](https://www.rfc-editor.org/rfc/rfc9110.html#field.user-agent)
-// header sent by the client.
-func UserAgentOriginal(val string) attribute.KeyValue {
- return UserAgentOriginalKey.String(val)
-}
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.20.0/doc.go b/vendor/go.opentelemetry.io/otel/semconv/v1.20.0/doc.go
deleted file mode 100644
index 0d1f55a8fe..0000000000
--- a/vendor/go.opentelemetry.io/otel/semconv/v1.20.0/doc.go
+++ /dev/null
@@ -1,9 +0,0 @@
-// Copyright The OpenTelemetry Authors
-// SPDX-License-Identifier: Apache-2.0
-
-// Package semconv implements OpenTelemetry semantic conventions.
-//
-// OpenTelemetry semantic conventions are agreed standardized naming
-// patterns for OpenTelemetry things. This package represents the conventions
-// as of the v1.20.0 version of the OpenTelemetry specification.
-package semconv // import "go.opentelemetry.io/otel/semconv/v1.20.0"
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.20.0/event.go b/vendor/go.opentelemetry.io/otel/semconv/v1.20.0/event.go
deleted file mode 100644
index 6377639321..0000000000
--- a/vendor/go.opentelemetry.io/otel/semconv/v1.20.0/event.go
+++ /dev/null
@@ -1,188 +0,0 @@
-// Copyright The OpenTelemetry Authors
-// SPDX-License-Identifier: Apache-2.0
-
-// Code generated from semantic convention specification. DO NOT EDIT.
-
-package semconv // import "go.opentelemetry.io/otel/semconv/v1.20.0"
-
-import "go.opentelemetry.io/otel/attribute"
-
-// This semantic convention defines the attributes used to represent a feature
-// flag evaluation as an event.
-const (
- // FeatureFlagKeyKey is the attribute Key conforming to the
- // "feature_flag.key" semantic conventions. It represents the unique
- // identifier of the feature flag.
- //
- // Type: string
- // RequirementLevel: Required
- // Stability: stable
- // Examples: 'logo-color'
- FeatureFlagKeyKey = attribute.Key("feature_flag.key")
-
- // FeatureFlagProviderNameKey is the attribute Key conforming to the
- // "feature_flag.provider_name" semantic conventions. It represents the
- // name of the service provider that performs the flag evaluation.
- //
- // Type: string
- // RequirementLevel: Recommended
- // Stability: stable
- // Examples: 'Flag Manager'
- FeatureFlagProviderNameKey = attribute.Key("feature_flag.provider_name")
-
- // FeatureFlagVariantKey is the attribute Key conforming to the
- // "feature_flag.variant" semantic conventions. It represents the sHOULD be
- // a semantic identifier for a value. If one is unavailable, a stringified
- // version of the value can be used.
- //
- // Type: string
- // RequirementLevel: Recommended
- // Stability: stable
- // Examples: 'red', 'true', 'on'
- // Note: A semantic identifier, commonly referred to as a variant, provides
- // a means
- // for referring to a value without including the value itself. This can
- // provide additional context for understanding the meaning behind a value.
- // For example, the variant `red` maybe be used for the value `#c05543`.
- //
- // A stringified version of the value can be used in situations where a
- // semantic identifier is unavailable. String representation of the value
- // should be determined by the implementer.
- FeatureFlagVariantKey = attribute.Key("feature_flag.variant")
-)
-
-// FeatureFlagKey returns an attribute KeyValue conforming to the
-// "feature_flag.key" semantic conventions. It represents the unique identifier
-// of the feature flag.
-func FeatureFlagKey(val string) attribute.KeyValue {
- return FeatureFlagKeyKey.String(val)
-}
-
-// FeatureFlagProviderName returns an attribute KeyValue conforming to the
-// "feature_flag.provider_name" semantic conventions. It represents the name of
-// the service provider that performs the flag evaluation.
-func FeatureFlagProviderName(val string) attribute.KeyValue {
- return FeatureFlagProviderNameKey.String(val)
-}
-
-// FeatureFlagVariant returns an attribute KeyValue conforming to the
-// "feature_flag.variant" semantic conventions. It represents the sHOULD be a
-// semantic identifier for a value. If one is unavailable, a stringified
-// version of the value can be used.
-func FeatureFlagVariant(val string) attribute.KeyValue {
- return FeatureFlagVariantKey.String(val)
-}
-
-// RPC received/sent message.
-const (
- // MessageTypeKey is the attribute Key conforming to the "message.type"
- // semantic conventions. It represents the whether this is a received or
- // sent message.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: stable
- MessageTypeKey = attribute.Key("message.type")
-
- // MessageIDKey is the attribute Key conforming to the "message.id"
- // semantic conventions. It represents the mUST be calculated as two
- // different counters starting from `1` one for sent messages and one for
- // received message.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Note: This way we guarantee that the values will be consistent between
- // different implementations.
- MessageIDKey = attribute.Key("message.id")
-
- // MessageCompressedSizeKey is the attribute Key conforming to the
- // "message.compressed_size" semantic conventions. It represents the
- // compressed size of the message in bytes.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- MessageCompressedSizeKey = attribute.Key("message.compressed_size")
-
- // MessageUncompressedSizeKey is the attribute Key conforming to the
- // "message.uncompressed_size" semantic conventions. It represents the
- // uncompressed size of the message in bytes.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- MessageUncompressedSizeKey = attribute.Key("message.uncompressed_size")
-)
-
-var (
- // sent
- MessageTypeSent = MessageTypeKey.String("SENT")
- // received
- MessageTypeReceived = MessageTypeKey.String("RECEIVED")
-)
-
-// MessageID returns an attribute KeyValue conforming to the "message.id"
-// semantic conventions. It represents the mUST be calculated as two different
-// counters starting from `1` one for sent messages and one for received
-// message.
-func MessageID(val int) attribute.KeyValue {
- return MessageIDKey.Int(val)
-}
-
-// MessageCompressedSize returns an attribute KeyValue conforming to the
-// "message.compressed_size" semantic conventions. It represents the compressed
-// size of the message in bytes.
-func MessageCompressedSize(val int) attribute.KeyValue {
- return MessageCompressedSizeKey.Int(val)
-}
-
-// MessageUncompressedSize returns an attribute KeyValue conforming to the
-// "message.uncompressed_size" semantic conventions. It represents the
-// uncompressed size of the message in bytes.
-func MessageUncompressedSize(val int) attribute.KeyValue {
- return MessageUncompressedSizeKey.Int(val)
-}
-
-// The attributes used to report a single exception associated with a span.
-const (
- // ExceptionEscapedKey is the attribute Key conforming to the
- // "exception.escaped" semantic conventions. It represents the sHOULD be
- // set to true if the exception event is recorded at a point where it is
- // known that the exception is escaping the scope of the span.
- //
- // Type: boolean
- // RequirementLevel: Optional
- // Stability: stable
- // Note: An exception is considered to have escaped (or left) the scope of
- // a span,
- // if that span is ended while the exception is still logically "in
- // flight".
- // This may be actually "in flight" in some languages (e.g. if the
- // exception
- // is passed to a Context manager's `__exit__` method in Python) but will
- // usually be caught at the point of recording the exception in most
- // languages.
- //
- // It is usually not possible to determine at the point where an exception
- // is thrown
- // whether it will escape the scope of a span.
- // However, it is trivial to know that an exception
- // will escape, if one checks for an active exception just before ending
- // the span,
- // as done in the [example above](#recording-an-exception).
- //
- // It follows that an exception may still escape the scope of the span
- // even if the `exception.escaped` attribute was not set or set to false,
- // since the event might have been recorded at a time where it was not
- // clear whether the exception will escape.
- ExceptionEscapedKey = attribute.Key("exception.escaped")
-)
-
-// ExceptionEscaped returns an attribute KeyValue conforming to the
-// "exception.escaped" semantic conventions. It represents the sHOULD be set to
-// true if the exception event is recorded at a point where it is known that
-// the exception is escaping the scope of the span.
-func ExceptionEscaped(val bool) attribute.KeyValue {
- return ExceptionEscapedKey.Bool(val)
-}
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.20.0/exception.go b/vendor/go.opentelemetry.io/otel/semconv/v1.20.0/exception.go
deleted file mode 100644
index f40c97825a..0000000000
--- a/vendor/go.opentelemetry.io/otel/semconv/v1.20.0/exception.go
+++ /dev/null
@@ -1,9 +0,0 @@
-// Copyright The OpenTelemetry Authors
-// SPDX-License-Identifier: Apache-2.0
-
-package semconv // import "go.opentelemetry.io/otel/semconv/v1.20.0"
-
-const (
- // ExceptionEventName is the name of the Span event representing an exception.
- ExceptionEventName = "exception"
-)
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.20.0/http.go b/vendor/go.opentelemetry.io/otel/semconv/v1.20.0/http.go
deleted file mode 100644
index 9c1840631b..0000000000
--- a/vendor/go.opentelemetry.io/otel/semconv/v1.20.0/http.go
+++ /dev/null
@@ -1,10 +0,0 @@
-// Copyright The OpenTelemetry Authors
-// SPDX-License-Identifier: Apache-2.0
-
-package semconv // import "go.opentelemetry.io/otel/semconv/v1.20.0"
-
-// HTTP scheme attributes.
-var (
- HTTPSchemeHTTP = HTTPSchemeKey.String("http")
- HTTPSchemeHTTPS = HTTPSchemeKey.String("https")
-)
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.20.0/resource.go b/vendor/go.opentelemetry.io/otel/semconv/v1.20.0/resource.go
deleted file mode 100644
index 3d44dae275..0000000000
--- a/vendor/go.opentelemetry.io/otel/semconv/v1.20.0/resource.go
+++ /dev/null
@@ -1,2060 +0,0 @@
-// Copyright The OpenTelemetry Authors
-// SPDX-License-Identifier: Apache-2.0
-
-// Code generated from semantic convention specification. DO NOT EDIT.
-
-package semconv // import "go.opentelemetry.io/otel/semconv/v1.20.0"
-
-import "go.opentelemetry.io/otel/attribute"
-
-// The web browser in which the application represented by the resource is
-// running. The `browser.*` attributes MUST be used only for resources that
-// represent applications running in a web browser (regardless of whether
-// running on a mobile or desktop device).
-const (
- // BrowserBrandsKey is the attribute Key conforming to the "browser.brands"
- // semantic conventions. It represents the array of brand name and version
- // separated by a space
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: ' Not A;Brand 99', 'Chromium 99', 'Chrome 99'
- // Note: This value is intended to be taken from the [UA client hints
- // API](https://wicg.github.io/ua-client-hints/#interface)
- // (`navigator.userAgentData.brands`).
- BrowserBrandsKey = attribute.Key("browser.brands")
-
- // BrowserPlatformKey is the attribute Key conforming to the
- // "browser.platform" semantic conventions. It represents the platform on
- // which the browser is running
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'Windows', 'macOS', 'Android'
- // Note: This value is intended to be taken from the [UA client hints
- // API](https://wicg.github.io/ua-client-hints/#interface)
- // (`navigator.userAgentData.platform`). If unavailable, the legacy
- // `navigator.platform` API SHOULD NOT be used instead and this attribute
- // SHOULD be left unset in order for the values to be consistent.
- // The list of possible values is defined in the [W3C User-Agent Client
- // Hints
- // specification](https://wicg.github.io/ua-client-hints/#sec-ch-ua-platform).
- // Note that some (but not all) of these values can overlap with values in
- // the [`os.type` and `os.name` attributes](./os.md). However, for
- // consistency, the values in the `browser.platform` attribute should
- // capture the exact value that the user agent provides.
- BrowserPlatformKey = attribute.Key("browser.platform")
-
- // BrowserMobileKey is the attribute Key conforming to the "browser.mobile"
- // semantic conventions. It represents a boolean that is true if the
- // browser is running on a mobile device
- //
- // Type: boolean
- // RequirementLevel: Optional
- // Stability: stable
- // Note: This value is intended to be taken from the [UA client hints
- // API](https://wicg.github.io/ua-client-hints/#interface)
- // (`navigator.userAgentData.mobile`). If unavailable, this attribute
- // SHOULD be left unset.
- BrowserMobileKey = attribute.Key("browser.mobile")
-
- // BrowserLanguageKey is the attribute Key conforming to the
- // "browser.language" semantic conventions. It represents the preferred
- // language of the user using the browser
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'en', 'en-US', 'fr', 'fr-FR'
- // Note: This value is intended to be taken from the Navigator API
- // `navigator.language`.
- BrowserLanguageKey = attribute.Key("browser.language")
-)
-
-// BrowserBrands returns an attribute KeyValue conforming to the
-// "browser.brands" semantic conventions. It represents the array of brand name
-// and version separated by a space
-func BrowserBrands(val ...string) attribute.KeyValue {
- return BrowserBrandsKey.StringSlice(val)
-}
-
-// BrowserPlatform returns an attribute KeyValue conforming to the
-// "browser.platform" semantic conventions. It represents the platform on which
-// the browser is running
-func BrowserPlatform(val string) attribute.KeyValue {
- return BrowserPlatformKey.String(val)
-}
-
-// BrowserMobile returns an attribute KeyValue conforming to the
-// "browser.mobile" semantic conventions. It represents a boolean that is true
-// if the browser is running on a mobile device
-func BrowserMobile(val bool) attribute.KeyValue {
- return BrowserMobileKey.Bool(val)
-}
-
-// BrowserLanguage returns an attribute KeyValue conforming to the
-// "browser.language" semantic conventions. It represents the preferred
-// language of the user using the browser
-func BrowserLanguage(val string) attribute.KeyValue {
- return BrowserLanguageKey.String(val)
-}
-
-// A cloud environment (e.g. GCP, Azure, AWS)
-const (
- // CloudProviderKey is the attribute Key conforming to the "cloud.provider"
- // semantic conventions. It represents the name of the cloud provider.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: stable
- CloudProviderKey = attribute.Key("cloud.provider")
-
- // CloudAccountIDKey is the attribute Key conforming to the
- // "cloud.account.id" semantic conventions. It represents the cloud account
- // ID the resource is assigned to.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '111111111111', 'opentelemetry'
- CloudAccountIDKey = attribute.Key("cloud.account.id")
-
- // CloudRegionKey is the attribute Key conforming to the "cloud.region"
- // semantic conventions. It represents the geographical region the resource
- // is running.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'us-central1', 'us-east-1'
- // Note: Refer to your provider's docs to see the available regions, for
- // example [Alibaba Cloud
- // regions](https://www.alibabacloud.com/help/doc-detail/40654.htm), [AWS
- // regions](https://aws.amazon.com/about-aws/global-infrastructure/regions_az/),
- // [Azure
- // regions](https://azure.microsoft.com/en-us/global-infrastructure/geographies/),
- // [Google Cloud regions](https://cloud.google.com/about/locations), or
- // [Tencent Cloud
- // regions](https://www.tencentcloud.com/document/product/213/6091).
- CloudRegionKey = attribute.Key("cloud.region")
-
- // CloudResourceIDKey is the attribute Key conforming to the
- // "cloud.resource_id" semantic conventions. It represents the cloud
- // provider-specific native identifier of the monitored cloud resource
- // (e.g. an
- // [ARN](https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html)
- // on AWS, a [fully qualified resource
- // ID](https://learn.microsoft.com/en-us/rest/api/resources/resources/get-by-id)
- // on Azure, a [full resource
- // name](https://cloud.google.com/apis/design/resource_names#full_resource_name)
- // on GCP)
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'arn:aws:lambda:REGION:ACCOUNT_ID:function:my-function',
- // '//run.googleapis.com/projects/PROJECT_ID/locations/LOCATION_ID/services/SERVICE_ID',
- // '/subscriptions//resourceGroups//providers/Microsoft.Web/sites//functions/'
- // Note: On some cloud providers, it may not be possible to determine the
- // full ID at startup,
- // so it may be necessary to set `cloud.resource_id` as a span attribute
- // instead.
- //
- // The exact value to use for `cloud.resource_id` depends on the cloud
- // provider.
- // The following well-known definitions MUST be used if you set this
- // attribute and they apply:
- //
- // * **AWS Lambda:** The function
- // [ARN](https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html).
- // Take care not to use the "invoked ARN" directly but replace any
- // [alias
- // suffix](https://docs.aws.amazon.com/lambda/latest/dg/configuration-aliases.html)
- // with the resolved function version, as the same runtime instance may
- // be invokable with
- // multiple different aliases.
- // * **GCP:** The [URI of the
- // resource](https://cloud.google.com/iam/docs/full-resource-names)
- // * **Azure:** The [Fully Qualified Resource
- // ID](https://docs.microsoft.com/en-us/rest/api/resources/resources/get-by-id)
- // of the invoked function,
- // *not* the function app, having the form
- // `/subscriptions//resourceGroups//providers/Microsoft.Web/sites//functions/`.
- // This means that a span attribute MUST be used, as an Azure function
- // app can host multiple functions that would usually share
- // a TracerProvider.
- CloudResourceIDKey = attribute.Key("cloud.resource_id")
-
- // CloudAvailabilityZoneKey is the attribute Key conforming to the
- // "cloud.availability_zone" semantic conventions. It represents the cloud
- // regions often have multiple, isolated locations known as zones to
- // increase availability. Availability zone represents the zone where the
- // resource is running.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'us-east-1c'
- // Note: Availability zones are called "zones" on Alibaba Cloud and Google
- // Cloud.
- CloudAvailabilityZoneKey = attribute.Key("cloud.availability_zone")
-
- // CloudPlatformKey is the attribute Key conforming to the "cloud.platform"
- // semantic conventions. It represents the cloud platform in use.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: stable
- // Note: The prefix of the service SHOULD match the one specified in
- // `cloud.provider`.
- CloudPlatformKey = attribute.Key("cloud.platform")
-)
-
-var (
- // Alibaba Cloud
- CloudProviderAlibabaCloud = CloudProviderKey.String("alibaba_cloud")
- // Amazon Web Services
- CloudProviderAWS = CloudProviderKey.String("aws")
- // Microsoft Azure
- CloudProviderAzure = CloudProviderKey.String("azure")
- // Google Cloud Platform
- CloudProviderGCP = CloudProviderKey.String("gcp")
- // Heroku Platform as a Service
- CloudProviderHeroku = CloudProviderKey.String("heroku")
- // IBM Cloud
- CloudProviderIbmCloud = CloudProviderKey.String("ibm_cloud")
- // Tencent Cloud
- CloudProviderTencentCloud = CloudProviderKey.String("tencent_cloud")
-)
-
-var (
- // Alibaba Cloud Elastic Compute Service
- CloudPlatformAlibabaCloudECS = CloudPlatformKey.String("alibaba_cloud_ecs")
- // Alibaba Cloud Function Compute
- CloudPlatformAlibabaCloudFc = CloudPlatformKey.String("alibaba_cloud_fc")
- // Red Hat OpenShift on Alibaba Cloud
- CloudPlatformAlibabaCloudOpenshift = CloudPlatformKey.String("alibaba_cloud_openshift")
- // AWS Elastic Compute Cloud
- CloudPlatformAWSEC2 = CloudPlatformKey.String("aws_ec2")
- // AWS Elastic Container Service
- CloudPlatformAWSECS = CloudPlatformKey.String("aws_ecs")
- // AWS Elastic Kubernetes Service
- CloudPlatformAWSEKS = CloudPlatformKey.String("aws_eks")
- // AWS Lambda
- CloudPlatformAWSLambda = CloudPlatformKey.String("aws_lambda")
- // AWS Elastic Beanstalk
- CloudPlatformAWSElasticBeanstalk = CloudPlatformKey.String("aws_elastic_beanstalk")
- // AWS App Runner
- CloudPlatformAWSAppRunner = CloudPlatformKey.String("aws_app_runner")
- // Red Hat OpenShift on AWS (ROSA)
- CloudPlatformAWSOpenshift = CloudPlatformKey.String("aws_openshift")
- // Azure Virtual Machines
- CloudPlatformAzureVM = CloudPlatformKey.String("azure_vm")
- // Azure Container Instances
- CloudPlatformAzureContainerInstances = CloudPlatformKey.String("azure_container_instances")
- // Azure Kubernetes Service
- CloudPlatformAzureAKS = CloudPlatformKey.String("azure_aks")
- // Azure Functions
- CloudPlatformAzureFunctions = CloudPlatformKey.String("azure_functions")
- // Azure App Service
- CloudPlatformAzureAppService = CloudPlatformKey.String("azure_app_service")
- // Azure Red Hat OpenShift
- CloudPlatformAzureOpenshift = CloudPlatformKey.String("azure_openshift")
- // Google Cloud Compute Engine (GCE)
- CloudPlatformGCPComputeEngine = CloudPlatformKey.String("gcp_compute_engine")
- // Google Cloud Run
- CloudPlatformGCPCloudRun = CloudPlatformKey.String("gcp_cloud_run")
- // Google Cloud Kubernetes Engine (GKE)
- CloudPlatformGCPKubernetesEngine = CloudPlatformKey.String("gcp_kubernetes_engine")
- // Google Cloud Functions (GCF)
- CloudPlatformGCPCloudFunctions = CloudPlatformKey.String("gcp_cloud_functions")
- // Google Cloud App Engine (GAE)
- CloudPlatformGCPAppEngine = CloudPlatformKey.String("gcp_app_engine")
- // Red Hat OpenShift on Google Cloud
- CloudPlatformGCPOpenshift = CloudPlatformKey.String("gcp_openshift")
- // Red Hat OpenShift on IBM Cloud
- CloudPlatformIbmCloudOpenshift = CloudPlatformKey.String("ibm_cloud_openshift")
- // Tencent Cloud Cloud Virtual Machine (CVM)
- CloudPlatformTencentCloudCvm = CloudPlatformKey.String("tencent_cloud_cvm")
- // Tencent Cloud Elastic Kubernetes Service (EKS)
- CloudPlatformTencentCloudEKS = CloudPlatformKey.String("tencent_cloud_eks")
- // Tencent Cloud Serverless Cloud Function (SCF)
- CloudPlatformTencentCloudScf = CloudPlatformKey.String("tencent_cloud_scf")
-)
-
-// CloudAccountID returns an attribute KeyValue conforming to the
-// "cloud.account.id" semantic conventions. It represents the cloud account ID
-// the resource is assigned to.
-func CloudAccountID(val string) attribute.KeyValue {
- return CloudAccountIDKey.String(val)
-}
-
-// CloudRegion returns an attribute KeyValue conforming to the
-// "cloud.region" semantic conventions. It represents the geographical region
-// the resource is running.
-func CloudRegion(val string) attribute.KeyValue {
- return CloudRegionKey.String(val)
-}
-
-// CloudResourceID returns an attribute KeyValue conforming to the
-// "cloud.resource_id" semantic conventions. It represents the cloud
-// provider-specific native identifier of the monitored cloud resource (e.g. an
-// [ARN](https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html)
-// on AWS, a [fully qualified resource
-// ID](https://learn.microsoft.com/en-us/rest/api/resources/resources/get-by-id)
-// on Azure, a [full resource
-// name](https://cloud.google.com/apis/design/resource_names#full_resource_name)
-// on GCP)
-func CloudResourceID(val string) attribute.KeyValue {
- return CloudResourceIDKey.String(val)
-}
-
-// CloudAvailabilityZone returns an attribute KeyValue conforming to the
-// "cloud.availability_zone" semantic conventions. It represents the cloud
-// regions often have multiple, isolated locations known as zones to increase
-// availability. Availability zone represents the zone where the resource is
-// running.
-func CloudAvailabilityZone(val string) attribute.KeyValue {
- return CloudAvailabilityZoneKey.String(val)
-}
-
-// Resources used by AWS Elastic Container Service (ECS).
-const (
- // AWSECSContainerARNKey is the attribute Key conforming to the
- // "aws.ecs.container.arn" semantic conventions. It represents the Amazon
- // Resource Name (ARN) of an [ECS container
- // instance](https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ECS_instances.html).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples:
- // 'arn:aws:ecs:us-west-1:123456789123:container/32624152-9086-4f0e-acae-1a75b14fe4d9'
- AWSECSContainerARNKey = attribute.Key("aws.ecs.container.arn")
-
- // AWSECSClusterARNKey is the attribute Key conforming to the
- // "aws.ecs.cluster.arn" semantic conventions. It represents the ARN of an
- // [ECS
- // cluster](https://docs.aws.amazon.com/AmazonECS/latest/developerguide/clusters.html).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'arn:aws:ecs:us-west-2:123456789123:cluster/my-cluster'
- AWSECSClusterARNKey = attribute.Key("aws.ecs.cluster.arn")
-
- // AWSECSLaunchtypeKey is the attribute Key conforming to the
- // "aws.ecs.launchtype" semantic conventions. It represents the [launch
- // type](https://docs.aws.amazon.com/AmazonECS/latest/developerguide/launch_types.html)
- // for an ECS task.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: stable
- AWSECSLaunchtypeKey = attribute.Key("aws.ecs.launchtype")
-
- // AWSECSTaskARNKey is the attribute Key conforming to the
- // "aws.ecs.task.arn" semantic conventions. It represents the ARN of an
- // [ECS task
- // definition](https://docs.aws.amazon.com/AmazonECS/latest/developerguide/task_definitions.html).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples:
- // 'arn:aws:ecs:us-west-1:123456789123:task/10838bed-421f-43ef-870a-f43feacbbb5b'
- AWSECSTaskARNKey = attribute.Key("aws.ecs.task.arn")
-
- // AWSECSTaskFamilyKey is the attribute Key conforming to the
- // "aws.ecs.task.family" semantic conventions. It represents the task
- // definition family this task definition is a member of.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'opentelemetry-family'
- AWSECSTaskFamilyKey = attribute.Key("aws.ecs.task.family")
-
- // AWSECSTaskRevisionKey is the attribute Key conforming to the
- // "aws.ecs.task.revision" semantic conventions. It represents the revision
- // for this task definition.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '8', '26'
- AWSECSTaskRevisionKey = attribute.Key("aws.ecs.task.revision")
-)
-
-var (
- // ec2
- AWSECSLaunchtypeEC2 = AWSECSLaunchtypeKey.String("ec2")
- // fargate
- AWSECSLaunchtypeFargate = AWSECSLaunchtypeKey.String("fargate")
-)
-
-// AWSECSContainerARN returns an attribute KeyValue conforming to the
-// "aws.ecs.container.arn" semantic conventions. It represents the Amazon
-// Resource Name (ARN) of an [ECS container
-// instance](https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ECS_instances.html).
-func AWSECSContainerARN(val string) attribute.KeyValue {
- return AWSECSContainerARNKey.String(val)
-}
-
-// AWSECSClusterARN returns an attribute KeyValue conforming to the
-// "aws.ecs.cluster.arn" semantic conventions. It represents the ARN of an [ECS
-// cluster](https://docs.aws.amazon.com/AmazonECS/latest/developerguide/clusters.html).
-func AWSECSClusterARN(val string) attribute.KeyValue {
- return AWSECSClusterARNKey.String(val)
-}
-
-// AWSECSTaskARN returns an attribute KeyValue conforming to the
-// "aws.ecs.task.arn" semantic conventions. It represents the ARN of an [ECS
-// task
-// definition](https://docs.aws.amazon.com/AmazonECS/latest/developerguide/task_definitions.html).
-func AWSECSTaskARN(val string) attribute.KeyValue {
- return AWSECSTaskARNKey.String(val)
-}
-
-// AWSECSTaskFamily returns an attribute KeyValue conforming to the
-// "aws.ecs.task.family" semantic conventions. It represents the task
-// definition family this task definition is a member of.
-func AWSECSTaskFamily(val string) attribute.KeyValue {
- return AWSECSTaskFamilyKey.String(val)
-}
-
-// AWSECSTaskRevision returns an attribute KeyValue conforming to the
-// "aws.ecs.task.revision" semantic conventions. It represents the revision for
-// this task definition.
-func AWSECSTaskRevision(val string) attribute.KeyValue {
- return AWSECSTaskRevisionKey.String(val)
-}
-
-// Resources used by AWS Elastic Kubernetes Service (EKS).
-const (
- // AWSEKSClusterARNKey is the attribute Key conforming to the
- // "aws.eks.cluster.arn" semantic conventions. It represents the ARN of an
- // EKS cluster.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'arn:aws:ecs:us-west-2:123456789123:cluster/my-cluster'
- AWSEKSClusterARNKey = attribute.Key("aws.eks.cluster.arn")
-)
-
-// AWSEKSClusterARN returns an attribute KeyValue conforming to the
-// "aws.eks.cluster.arn" semantic conventions. It represents the ARN of an EKS
-// cluster.
-func AWSEKSClusterARN(val string) attribute.KeyValue {
- return AWSEKSClusterARNKey.String(val)
-}
-
-// Resources specific to Amazon Web Services.
-const (
- // AWSLogGroupNamesKey is the attribute Key conforming to the
- // "aws.log.group.names" semantic conventions. It represents the name(s) of
- // the AWS log group(s) an application is writing to.
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '/aws/lambda/my-function', 'opentelemetry-service'
- // Note: Multiple log groups must be supported for cases like
- // multi-container applications, where a single application has sidecar
- // containers, and each write to their own log group.
- AWSLogGroupNamesKey = attribute.Key("aws.log.group.names")
-
- // AWSLogGroupARNsKey is the attribute Key conforming to the
- // "aws.log.group.arns" semantic conventions. It represents the Amazon
- // Resource Name(s) (ARN) of the AWS log group(s).
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: stable
- // Examples:
- // 'arn:aws:logs:us-west-1:123456789012:log-group:/aws/my/group:*'
- // Note: See the [log group ARN format
- // documentation](https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/iam-access-control-overview-cwl.html#CWL_ARN_Format).
- AWSLogGroupARNsKey = attribute.Key("aws.log.group.arns")
-
- // AWSLogStreamNamesKey is the attribute Key conforming to the
- // "aws.log.stream.names" semantic conventions. It represents the name(s)
- // of the AWS log stream(s) an application is writing to.
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'logs/main/10838bed-421f-43ef-870a-f43feacbbb5b'
- AWSLogStreamNamesKey = attribute.Key("aws.log.stream.names")
-
- // AWSLogStreamARNsKey is the attribute Key conforming to the
- // "aws.log.stream.arns" semantic conventions. It represents the ARN(s) of
- // the AWS log stream(s).
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: stable
- // Examples:
- // 'arn:aws:logs:us-west-1:123456789012:log-group:/aws/my/group:log-stream:logs/main/10838bed-421f-43ef-870a-f43feacbbb5b'
- // Note: See the [log stream ARN format
- // documentation](https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/iam-access-control-overview-cwl.html#CWL_ARN_Format).
- // One log group can contain several log streams, so these ARNs necessarily
- // identify both a log group and a log stream.
- AWSLogStreamARNsKey = attribute.Key("aws.log.stream.arns")
-)
-
-// AWSLogGroupNames returns an attribute KeyValue conforming to the
-// "aws.log.group.names" semantic conventions. It represents the name(s) of the
-// AWS log group(s) an application is writing to.
-func AWSLogGroupNames(val ...string) attribute.KeyValue {
- return AWSLogGroupNamesKey.StringSlice(val)
-}
-
-// AWSLogGroupARNs returns an attribute KeyValue conforming to the
-// "aws.log.group.arns" semantic conventions. It represents the Amazon Resource
-// Name(s) (ARN) of the AWS log group(s).
-func AWSLogGroupARNs(val ...string) attribute.KeyValue {
- return AWSLogGroupARNsKey.StringSlice(val)
-}
-
-// AWSLogStreamNames returns an attribute KeyValue conforming to the
-// "aws.log.stream.names" semantic conventions. It represents the name(s) of
-// the AWS log stream(s) an application is writing to.
-func AWSLogStreamNames(val ...string) attribute.KeyValue {
- return AWSLogStreamNamesKey.StringSlice(val)
-}
-
-// AWSLogStreamARNs returns an attribute KeyValue conforming to the
-// "aws.log.stream.arns" semantic conventions. It represents the ARN(s) of the
-// AWS log stream(s).
-func AWSLogStreamARNs(val ...string) attribute.KeyValue {
- return AWSLogStreamARNsKey.StringSlice(val)
-}
-
-// Heroku dyno metadata
-const (
- // HerokuReleaseCreationTimestampKey is the attribute Key conforming to the
- // "heroku.release.creation_timestamp" semantic conventions. It represents
- // the time and date the release was created
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '2022-10-23T18:00:42Z'
- HerokuReleaseCreationTimestampKey = attribute.Key("heroku.release.creation_timestamp")
-
- // HerokuReleaseCommitKey is the attribute Key conforming to the
- // "heroku.release.commit" semantic conventions. It represents the commit
- // hash for the current release
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'e6134959463efd8966b20e75b913cafe3f5ec'
- HerokuReleaseCommitKey = attribute.Key("heroku.release.commit")
-
- // HerokuAppIDKey is the attribute Key conforming to the "heroku.app.id"
- // semantic conventions. It represents the unique identifier for the
- // application
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '2daa2797-e42b-4624-9322-ec3f968df4da'
- HerokuAppIDKey = attribute.Key("heroku.app.id")
-)
-
-// HerokuReleaseCreationTimestamp returns an attribute KeyValue conforming
-// to the "heroku.release.creation_timestamp" semantic conventions. It
-// represents the time and date the release was created
-func HerokuReleaseCreationTimestamp(val string) attribute.KeyValue {
- return HerokuReleaseCreationTimestampKey.String(val)
-}
-
-// HerokuReleaseCommit returns an attribute KeyValue conforming to the
-// "heroku.release.commit" semantic conventions. It represents the commit hash
-// for the current release
-func HerokuReleaseCommit(val string) attribute.KeyValue {
- return HerokuReleaseCommitKey.String(val)
-}
-
-// HerokuAppID returns an attribute KeyValue conforming to the
-// "heroku.app.id" semantic conventions. It represents the unique identifier
-// for the application
-func HerokuAppID(val string) attribute.KeyValue {
- return HerokuAppIDKey.String(val)
-}
-
-// A container instance.
-const (
- // ContainerNameKey is the attribute Key conforming to the "container.name"
- // semantic conventions. It represents the container name used by container
- // runtime.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'opentelemetry-autoconf'
- ContainerNameKey = attribute.Key("container.name")
-
- // ContainerIDKey is the attribute Key conforming to the "container.id"
- // semantic conventions. It represents the container ID. Usually a UUID, as
- // for example used to [identify Docker
- // containers](https://docs.docker.com/engine/reference/run/#container-identification).
- // The UUID might be abbreviated.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'a3bf90e006b2'
- ContainerIDKey = attribute.Key("container.id")
-
- // ContainerRuntimeKey is the attribute Key conforming to the
- // "container.runtime" semantic conventions. It represents the container
- // runtime managing this container.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'docker', 'containerd', 'rkt'
- ContainerRuntimeKey = attribute.Key("container.runtime")
-
- // ContainerImageNameKey is the attribute Key conforming to the
- // "container.image.name" semantic conventions. It represents the name of
- // the image the container was built on.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'gcr.io/opentelemetry/operator'
- ContainerImageNameKey = attribute.Key("container.image.name")
-
- // ContainerImageTagKey is the attribute Key conforming to the
- // "container.image.tag" semantic conventions. It represents the container
- // image tag.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '0.1'
- ContainerImageTagKey = attribute.Key("container.image.tag")
-)
-
-// ContainerName returns an attribute KeyValue conforming to the
-// "container.name" semantic conventions. It represents the container name used
-// by container runtime.
-func ContainerName(val string) attribute.KeyValue {
- return ContainerNameKey.String(val)
-}
-
-// ContainerID returns an attribute KeyValue conforming to the
-// "container.id" semantic conventions. It represents the container ID. Usually
-// a UUID, as for example used to [identify Docker
-// containers](https://docs.docker.com/engine/reference/run/#container-identification).
-// The UUID might be abbreviated.
-func ContainerID(val string) attribute.KeyValue {
- return ContainerIDKey.String(val)
-}
-
-// ContainerRuntime returns an attribute KeyValue conforming to the
-// "container.runtime" semantic conventions. It represents the container
-// runtime managing this container.
-func ContainerRuntime(val string) attribute.KeyValue {
- return ContainerRuntimeKey.String(val)
-}
-
-// ContainerImageName returns an attribute KeyValue conforming to the
-// "container.image.name" semantic conventions. It represents the name of the
-// image the container was built on.
-func ContainerImageName(val string) attribute.KeyValue {
- return ContainerImageNameKey.String(val)
-}
-
-// ContainerImageTag returns an attribute KeyValue conforming to the
-// "container.image.tag" semantic conventions. It represents the container
-// image tag.
-func ContainerImageTag(val string) attribute.KeyValue {
- return ContainerImageTagKey.String(val)
-}
-
-// The software deployment.
-const (
- // DeploymentEnvironmentKey is the attribute Key conforming to the
- // "deployment.environment" semantic conventions. It represents the name of
- // the [deployment
- // environment](https://en.wikipedia.org/wiki/Deployment_environment) (aka
- // deployment tier).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'staging', 'production'
- DeploymentEnvironmentKey = attribute.Key("deployment.environment")
-)
-
-// DeploymentEnvironment returns an attribute KeyValue conforming to the
-// "deployment.environment" semantic conventions. It represents the name of the
-// [deployment
-// environment](https://en.wikipedia.org/wiki/Deployment_environment) (aka
-// deployment tier).
-func DeploymentEnvironment(val string) attribute.KeyValue {
- return DeploymentEnvironmentKey.String(val)
-}
-
-// The device on which the process represented by this resource is running.
-const (
- // DeviceIDKey is the attribute Key conforming to the "device.id" semantic
- // conventions. It represents a unique identifier representing the device
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '2ab2916d-a51f-4ac8-80ee-45ac31a28092'
- // Note: The device identifier MUST only be defined using the values
- // outlined below. This value is not an advertising identifier and MUST NOT
- // be used as such. On iOS (Swift or Objective-C), this value MUST be equal
- // to the [vendor
- // identifier](https://developer.apple.com/documentation/uikit/uidevice/1620059-identifierforvendor).
- // On Android (Java or Kotlin), this value MUST be equal to the Firebase
- // Installation ID or a globally unique UUID which is persisted across
- // sessions in your application. More information can be found
- // [here](https://developer.android.com/training/articles/user-data-ids) on
- // best practices and exact implementation details. Caution should be taken
- // when storing personal data or anything which can identify a user. GDPR
- // and data protection laws may apply, ensure you do your own due
- // diligence.
- DeviceIDKey = attribute.Key("device.id")
-
- // DeviceModelIdentifierKey is the attribute Key conforming to the
- // "device.model.identifier" semantic conventions. It represents the model
- // identifier for the device
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'iPhone3,4', 'SM-G920F'
- // Note: It's recommended this value represents a machine readable version
- // of the model identifier rather than the market or consumer-friendly name
- // of the device.
- DeviceModelIdentifierKey = attribute.Key("device.model.identifier")
-
- // DeviceModelNameKey is the attribute Key conforming to the
- // "device.model.name" semantic conventions. It represents the marketing
- // name for the device model
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'iPhone 6s Plus', 'Samsung Galaxy S6'
- // Note: It's recommended this value represents a human readable version of
- // the device model rather than a machine readable alternative.
- DeviceModelNameKey = attribute.Key("device.model.name")
-
- // DeviceManufacturerKey is the attribute Key conforming to the
- // "device.manufacturer" semantic conventions. It represents the name of
- // the device manufacturer
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'Apple', 'Samsung'
- // Note: The Android OS provides this field via
- // [Build](https://developer.android.com/reference/android/os/Build#MANUFACTURER).
- // iOS apps SHOULD hardcode the value `Apple`.
- DeviceManufacturerKey = attribute.Key("device.manufacturer")
-)
-
-// DeviceID returns an attribute KeyValue conforming to the "device.id"
-// semantic conventions. It represents a unique identifier representing the
-// device
-func DeviceID(val string) attribute.KeyValue {
- return DeviceIDKey.String(val)
-}
-
-// DeviceModelIdentifier returns an attribute KeyValue conforming to the
-// "device.model.identifier" semantic conventions. It represents the model
-// identifier for the device
-func DeviceModelIdentifier(val string) attribute.KeyValue {
- return DeviceModelIdentifierKey.String(val)
-}
-
-// DeviceModelName returns an attribute KeyValue conforming to the
-// "device.model.name" semantic conventions. It represents the marketing name
-// for the device model
-func DeviceModelName(val string) attribute.KeyValue {
- return DeviceModelNameKey.String(val)
-}
-
-// DeviceManufacturer returns an attribute KeyValue conforming to the
-// "device.manufacturer" semantic conventions. It represents the name of the
-// device manufacturer
-func DeviceManufacturer(val string) attribute.KeyValue {
- return DeviceManufacturerKey.String(val)
-}
-
-// A serverless instance.
-const (
- // FaaSNameKey is the attribute Key conforming to the "faas.name" semantic
- // conventions. It represents the name of the single function that this
- // runtime instance executes.
- //
- // Type: string
- // RequirementLevel: Required
- // Stability: stable
- // Examples: 'my-function', 'myazurefunctionapp/some-function-name'
- // Note: This is the name of the function as configured/deployed on the
- // FaaS
- // platform and is usually different from the name of the callback
- // function (which may be stored in the
- // [`code.namespace`/`code.function`](../../trace/semantic_conventions/span-general.md#source-code-attributes)
- // span attributes).
- //
- // For some cloud providers, the above definition is ambiguous. The
- // following
- // definition of function name MUST be used for this attribute
- // (and consequently the span name) for the listed cloud
- // providers/products:
- //
- // * **Azure:** The full name `/`, i.e., function app name
- // followed by a forward slash followed by the function name (this form
- // can also be seen in the resource JSON for the function).
- // This means that a span attribute MUST be used, as an Azure function
- // app can host multiple functions that would usually share
- // a TracerProvider (see also the `cloud.resource_id` attribute).
- FaaSNameKey = attribute.Key("faas.name")
-
- // FaaSVersionKey is the attribute Key conforming to the "faas.version"
- // semantic conventions. It represents the immutable version of the
- // function being executed.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '26', 'pinkfroid-00002'
- // Note: Depending on the cloud provider and platform, use:
- //
- // * **AWS Lambda:** The [function
- // version](https://docs.aws.amazon.com/lambda/latest/dg/configuration-versions.html)
- // (an integer represented as a decimal string).
- // * **Google Cloud Run:** The
- // [revision](https://cloud.google.com/run/docs/managing/revisions)
- // (i.e., the function name plus the revision suffix).
- // * **Google Cloud Functions:** The value of the
- // [`K_REVISION` environment
- // variable](https://cloud.google.com/functions/docs/env-var#runtime_environment_variables_set_automatically).
- // * **Azure Functions:** Not applicable. Do not set this attribute.
- FaaSVersionKey = attribute.Key("faas.version")
-
- // FaaSInstanceKey is the attribute Key conforming to the "faas.instance"
- // semantic conventions. It represents the execution environment ID as a
- // string, that will be potentially reused for other invocations to the
- // same function/function version.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '2021/06/28/[$LATEST]2f399eb14537447da05ab2a2e39309de'
- // Note: * **AWS Lambda:** Use the (full) log stream name.
- FaaSInstanceKey = attribute.Key("faas.instance")
-
- // FaaSMaxMemoryKey is the attribute Key conforming to the
- // "faas.max_memory" semantic conventions. It represents the amount of
- // memory available to the serverless function converted to Bytes.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 134217728
- // Note: It's recommended to set this attribute since e.g. too little
- // memory can easily stop a Java AWS Lambda function from working
- // correctly. On AWS Lambda, the environment variable
- // `AWS_LAMBDA_FUNCTION_MEMORY_SIZE` provides this information (which must
- // be multiplied by 1,048,576).
- FaaSMaxMemoryKey = attribute.Key("faas.max_memory")
-)
-
-// FaaSName returns an attribute KeyValue conforming to the "faas.name"
-// semantic conventions. It represents the name of the single function that
-// this runtime instance executes.
-func FaaSName(val string) attribute.KeyValue {
- return FaaSNameKey.String(val)
-}
-
-// FaaSVersion returns an attribute KeyValue conforming to the
-// "faas.version" semantic conventions. It represents the immutable version of
-// the function being executed.
-func FaaSVersion(val string) attribute.KeyValue {
- return FaaSVersionKey.String(val)
-}
-
-// FaaSInstance returns an attribute KeyValue conforming to the
-// "faas.instance" semantic conventions. It represents the execution
-// environment ID as a string, that will be potentially reused for other
-// invocations to the same function/function version.
-func FaaSInstance(val string) attribute.KeyValue {
- return FaaSInstanceKey.String(val)
-}
-
-// FaaSMaxMemory returns an attribute KeyValue conforming to the
-// "faas.max_memory" semantic conventions. It represents the amount of memory
-// available to the serverless function converted to Bytes.
-func FaaSMaxMemory(val int) attribute.KeyValue {
- return FaaSMaxMemoryKey.Int(val)
-}
-
-// A host is defined as a general computing instance.
-const (
- // HostIDKey is the attribute Key conforming to the "host.id" semantic
- // conventions. It represents the unique host ID. For Cloud, this must be
- // the instance_id assigned by the cloud provider. For non-containerized
- // systems, this should be the `machine-id`. See the table below for the
- // sources to use to determine the `machine-id` based on operating system.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'fdbf79e8af94cb7f9e8df36789187052'
- HostIDKey = attribute.Key("host.id")
-
- // HostNameKey is the attribute Key conforming to the "host.name" semantic
- // conventions. It represents the name of the host. On Unix systems, it may
- // contain what the hostname command returns, or the fully qualified
- // hostname, or another name specified by the user.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'opentelemetry-test'
- HostNameKey = attribute.Key("host.name")
-
- // HostTypeKey is the attribute Key conforming to the "host.type" semantic
- // conventions. It represents the type of host. For Cloud, this must be the
- // machine type.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'n1-standard-1'
- HostTypeKey = attribute.Key("host.type")
-
- // HostArchKey is the attribute Key conforming to the "host.arch" semantic
- // conventions. It represents the CPU architecture the host system is
- // running on.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: stable
- HostArchKey = attribute.Key("host.arch")
-
- // HostImageNameKey is the attribute Key conforming to the
- // "host.image.name" semantic conventions. It represents the name of the VM
- // image or OS install the host was instantiated from.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'infra-ami-eks-worker-node-7d4ec78312', 'CentOS-8-x86_64-1905'
- HostImageNameKey = attribute.Key("host.image.name")
-
- // HostImageIDKey is the attribute Key conforming to the "host.image.id"
- // semantic conventions. It represents the vM image ID. For Cloud, this
- // value is from the provider.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'ami-07b06b442921831e5'
- HostImageIDKey = attribute.Key("host.image.id")
-
- // HostImageVersionKey is the attribute Key conforming to the
- // "host.image.version" semantic conventions. It represents the version
- // string of the VM image as defined in [Version
- // Attributes](README.md#version-attributes).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '0.1'
- HostImageVersionKey = attribute.Key("host.image.version")
-)
-
-var (
- // AMD64
- HostArchAMD64 = HostArchKey.String("amd64")
- // ARM32
- HostArchARM32 = HostArchKey.String("arm32")
- // ARM64
- HostArchARM64 = HostArchKey.String("arm64")
- // Itanium
- HostArchIA64 = HostArchKey.String("ia64")
- // 32-bit PowerPC
- HostArchPPC32 = HostArchKey.String("ppc32")
- // 64-bit PowerPC
- HostArchPPC64 = HostArchKey.String("ppc64")
- // IBM z/Architecture
- HostArchS390x = HostArchKey.String("s390x")
- // 32-bit x86
- HostArchX86 = HostArchKey.String("x86")
-)
-
-// HostID returns an attribute KeyValue conforming to the "host.id" semantic
-// conventions. It represents the unique host ID. For Cloud, this must be the
-// instance_id assigned by the cloud provider. For non-containerized systems,
-// this should be the `machine-id`. See the table below for the sources to use
-// to determine the `machine-id` based on operating system.
-func HostID(val string) attribute.KeyValue {
- return HostIDKey.String(val)
-}
-
-// HostName returns an attribute KeyValue conforming to the "host.name"
-// semantic conventions. It represents the name of the host. On Unix systems,
-// it may contain what the hostname command returns, or the fully qualified
-// hostname, or another name specified by the user.
-func HostName(val string) attribute.KeyValue {
- return HostNameKey.String(val)
-}
-
-// HostType returns an attribute KeyValue conforming to the "host.type"
-// semantic conventions. It represents the type of host. For Cloud, this must
-// be the machine type.
-func HostType(val string) attribute.KeyValue {
- return HostTypeKey.String(val)
-}
-
-// HostImageName returns an attribute KeyValue conforming to the
-// "host.image.name" semantic conventions. It represents the name of the VM
-// image or OS install the host was instantiated from.
-func HostImageName(val string) attribute.KeyValue {
- return HostImageNameKey.String(val)
-}
-
-// HostImageID returns an attribute KeyValue conforming to the
-// "host.image.id" semantic conventions. It represents the vM image ID. For
-// Cloud, this value is from the provider.
-func HostImageID(val string) attribute.KeyValue {
- return HostImageIDKey.String(val)
-}
-
-// HostImageVersion returns an attribute KeyValue conforming to the
-// "host.image.version" semantic conventions. It represents the version string
-// of the VM image as defined in [Version
-// Attributes](README.md#version-attributes).
-func HostImageVersion(val string) attribute.KeyValue {
- return HostImageVersionKey.String(val)
-}
-
-// A Kubernetes Cluster.
-const (
- // K8SClusterNameKey is the attribute Key conforming to the
- // "k8s.cluster.name" semantic conventions. It represents the name of the
- // cluster.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'opentelemetry-cluster'
- K8SClusterNameKey = attribute.Key("k8s.cluster.name")
-)
-
-// K8SClusterName returns an attribute KeyValue conforming to the
-// "k8s.cluster.name" semantic conventions. It represents the name of the
-// cluster.
-func K8SClusterName(val string) attribute.KeyValue {
- return K8SClusterNameKey.String(val)
-}
-
-// A Kubernetes Node object.
-const (
- // K8SNodeNameKey is the attribute Key conforming to the "k8s.node.name"
- // semantic conventions. It represents the name of the Node.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'node-1'
- K8SNodeNameKey = attribute.Key("k8s.node.name")
-
- // K8SNodeUIDKey is the attribute Key conforming to the "k8s.node.uid"
- // semantic conventions. It represents the UID of the Node.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '1eb3a0c6-0477-4080-a9cb-0cb7db65c6a2'
- K8SNodeUIDKey = attribute.Key("k8s.node.uid")
-)
-
-// K8SNodeName returns an attribute KeyValue conforming to the
-// "k8s.node.name" semantic conventions. It represents the name of the Node.
-func K8SNodeName(val string) attribute.KeyValue {
- return K8SNodeNameKey.String(val)
-}
-
-// K8SNodeUID returns an attribute KeyValue conforming to the "k8s.node.uid"
-// semantic conventions. It represents the UID of the Node.
-func K8SNodeUID(val string) attribute.KeyValue {
- return K8SNodeUIDKey.String(val)
-}
-
-// A Kubernetes Namespace.
-const (
- // K8SNamespaceNameKey is the attribute Key conforming to the
- // "k8s.namespace.name" semantic conventions. It represents the name of the
- // namespace that the pod is running in.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'default'
- K8SNamespaceNameKey = attribute.Key("k8s.namespace.name")
-)
-
-// K8SNamespaceName returns an attribute KeyValue conforming to the
-// "k8s.namespace.name" semantic conventions. It represents the name of the
-// namespace that the pod is running in.
-func K8SNamespaceName(val string) attribute.KeyValue {
- return K8SNamespaceNameKey.String(val)
-}
-
-// A Kubernetes Pod object.
-const (
- // K8SPodUIDKey is the attribute Key conforming to the "k8s.pod.uid"
- // semantic conventions. It represents the UID of the Pod.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '275ecb36-5aa8-4c2a-9c47-d8bb681b9aff'
- K8SPodUIDKey = attribute.Key("k8s.pod.uid")
-
- // K8SPodNameKey is the attribute Key conforming to the "k8s.pod.name"
- // semantic conventions. It represents the name of the Pod.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'opentelemetry-pod-autoconf'
- K8SPodNameKey = attribute.Key("k8s.pod.name")
-)
-
-// K8SPodUID returns an attribute KeyValue conforming to the "k8s.pod.uid"
-// semantic conventions. It represents the UID of the Pod.
-func K8SPodUID(val string) attribute.KeyValue {
- return K8SPodUIDKey.String(val)
-}
-
-// K8SPodName returns an attribute KeyValue conforming to the "k8s.pod.name"
-// semantic conventions. It represents the name of the Pod.
-func K8SPodName(val string) attribute.KeyValue {
- return K8SPodNameKey.String(val)
-}
-
-// A container in a
-// [PodTemplate](https://kubernetes.io/docs/concepts/workloads/pods/#pod-templates).
-const (
- // K8SContainerNameKey is the attribute Key conforming to the
- // "k8s.container.name" semantic conventions. It represents the name of the
- // Container from Pod specification, must be unique within a Pod. Container
- // runtime usually uses different globally unique name (`container.name`).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'redis'
- K8SContainerNameKey = attribute.Key("k8s.container.name")
-
- // K8SContainerRestartCountKey is the attribute Key conforming to the
- // "k8s.container.restart_count" semantic conventions. It represents the
- // number of times the container was restarted. This attribute can be used
- // to identify a particular container (running or stopped) within a
- // container spec.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 0, 2
- K8SContainerRestartCountKey = attribute.Key("k8s.container.restart_count")
-)
-
-// K8SContainerName returns an attribute KeyValue conforming to the
-// "k8s.container.name" semantic conventions. It represents the name of the
-// Container from Pod specification, must be unique within a Pod. Container
-// runtime usually uses different globally unique name (`container.name`).
-func K8SContainerName(val string) attribute.KeyValue {
- return K8SContainerNameKey.String(val)
-}
-
-// K8SContainerRestartCount returns an attribute KeyValue conforming to the
-// "k8s.container.restart_count" semantic conventions. It represents the number
-// of times the container was restarted. This attribute can be used to identify
-// a particular container (running or stopped) within a container spec.
-func K8SContainerRestartCount(val int) attribute.KeyValue {
- return K8SContainerRestartCountKey.Int(val)
-}
-
-// A Kubernetes ReplicaSet object.
-const (
- // K8SReplicaSetUIDKey is the attribute Key conforming to the
- // "k8s.replicaset.uid" semantic conventions. It represents the UID of the
- // ReplicaSet.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '275ecb36-5aa8-4c2a-9c47-d8bb681b9aff'
- K8SReplicaSetUIDKey = attribute.Key("k8s.replicaset.uid")
-
- // K8SReplicaSetNameKey is the attribute Key conforming to the
- // "k8s.replicaset.name" semantic conventions. It represents the name of
- // the ReplicaSet.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'opentelemetry'
- K8SReplicaSetNameKey = attribute.Key("k8s.replicaset.name")
-)
-
-// K8SReplicaSetUID returns an attribute KeyValue conforming to the
-// "k8s.replicaset.uid" semantic conventions. It represents the UID of the
-// ReplicaSet.
-func K8SReplicaSetUID(val string) attribute.KeyValue {
- return K8SReplicaSetUIDKey.String(val)
-}
-
-// K8SReplicaSetName returns an attribute KeyValue conforming to the
-// "k8s.replicaset.name" semantic conventions. It represents the name of the
-// ReplicaSet.
-func K8SReplicaSetName(val string) attribute.KeyValue {
- return K8SReplicaSetNameKey.String(val)
-}
-
-// A Kubernetes Deployment object.
-const (
- // K8SDeploymentUIDKey is the attribute Key conforming to the
- // "k8s.deployment.uid" semantic conventions. It represents the UID of the
- // Deployment.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '275ecb36-5aa8-4c2a-9c47-d8bb681b9aff'
- K8SDeploymentUIDKey = attribute.Key("k8s.deployment.uid")
-
- // K8SDeploymentNameKey is the attribute Key conforming to the
- // "k8s.deployment.name" semantic conventions. It represents the name of
- // the Deployment.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'opentelemetry'
- K8SDeploymentNameKey = attribute.Key("k8s.deployment.name")
-)
-
-// K8SDeploymentUID returns an attribute KeyValue conforming to the
-// "k8s.deployment.uid" semantic conventions. It represents the UID of the
-// Deployment.
-func K8SDeploymentUID(val string) attribute.KeyValue {
- return K8SDeploymentUIDKey.String(val)
-}
-
-// K8SDeploymentName returns an attribute KeyValue conforming to the
-// "k8s.deployment.name" semantic conventions. It represents the name of the
-// Deployment.
-func K8SDeploymentName(val string) attribute.KeyValue {
- return K8SDeploymentNameKey.String(val)
-}
-
-// A Kubernetes StatefulSet object.
-const (
- // K8SStatefulSetUIDKey is the attribute Key conforming to the
- // "k8s.statefulset.uid" semantic conventions. It represents the UID of the
- // StatefulSet.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '275ecb36-5aa8-4c2a-9c47-d8bb681b9aff'
- K8SStatefulSetUIDKey = attribute.Key("k8s.statefulset.uid")
-
- // K8SStatefulSetNameKey is the attribute Key conforming to the
- // "k8s.statefulset.name" semantic conventions. It represents the name of
- // the StatefulSet.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'opentelemetry'
- K8SStatefulSetNameKey = attribute.Key("k8s.statefulset.name")
-)
-
-// K8SStatefulSetUID returns an attribute KeyValue conforming to the
-// "k8s.statefulset.uid" semantic conventions. It represents the UID of the
-// StatefulSet.
-func K8SStatefulSetUID(val string) attribute.KeyValue {
- return K8SStatefulSetUIDKey.String(val)
-}
-
-// K8SStatefulSetName returns an attribute KeyValue conforming to the
-// "k8s.statefulset.name" semantic conventions. It represents the name of the
-// StatefulSet.
-func K8SStatefulSetName(val string) attribute.KeyValue {
- return K8SStatefulSetNameKey.String(val)
-}
-
-// A Kubernetes DaemonSet object.
-const (
- // K8SDaemonSetUIDKey is the attribute Key conforming to the
- // "k8s.daemonset.uid" semantic conventions. It represents the UID of the
- // DaemonSet.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '275ecb36-5aa8-4c2a-9c47-d8bb681b9aff'
- K8SDaemonSetUIDKey = attribute.Key("k8s.daemonset.uid")
-
- // K8SDaemonSetNameKey is the attribute Key conforming to the
- // "k8s.daemonset.name" semantic conventions. It represents the name of the
- // DaemonSet.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'opentelemetry'
- K8SDaemonSetNameKey = attribute.Key("k8s.daemonset.name")
-)
-
-// K8SDaemonSetUID returns an attribute KeyValue conforming to the
-// "k8s.daemonset.uid" semantic conventions. It represents the UID of the
-// DaemonSet.
-func K8SDaemonSetUID(val string) attribute.KeyValue {
- return K8SDaemonSetUIDKey.String(val)
-}
-
-// K8SDaemonSetName returns an attribute KeyValue conforming to the
-// "k8s.daemonset.name" semantic conventions. It represents the name of the
-// DaemonSet.
-func K8SDaemonSetName(val string) attribute.KeyValue {
- return K8SDaemonSetNameKey.String(val)
-}
-
-// A Kubernetes Job object.
-const (
- // K8SJobUIDKey is the attribute Key conforming to the "k8s.job.uid"
- // semantic conventions. It represents the UID of the Job.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '275ecb36-5aa8-4c2a-9c47-d8bb681b9aff'
- K8SJobUIDKey = attribute.Key("k8s.job.uid")
-
- // K8SJobNameKey is the attribute Key conforming to the "k8s.job.name"
- // semantic conventions. It represents the name of the Job.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'opentelemetry'
- K8SJobNameKey = attribute.Key("k8s.job.name")
-)
-
-// K8SJobUID returns an attribute KeyValue conforming to the "k8s.job.uid"
-// semantic conventions. It represents the UID of the Job.
-func K8SJobUID(val string) attribute.KeyValue {
- return K8SJobUIDKey.String(val)
-}
-
-// K8SJobName returns an attribute KeyValue conforming to the "k8s.job.name"
-// semantic conventions. It represents the name of the Job.
-func K8SJobName(val string) attribute.KeyValue {
- return K8SJobNameKey.String(val)
-}
-
-// A Kubernetes CronJob object.
-const (
- // K8SCronJobUIDKey is the attribute Key conforming to the
- // "k8s.cronjob.uid" semantic conventions. It represents the UID of the
- // CronJob.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '275ecb36-5aa8-4c2a-9c47-d8bb681b9aff'
- K8SCronJobUIDKey = attribute.Key("k8s.cronjob.uid")
-
- // K8SCronJobNameKey is the attribute Key conforming to the
- // "k8s.cronjob.name" semantic conventions. It represents the name of the
- // CronJob.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'opentelemetry'
- K8SCronJobNameKey = attribute.Key("k8s.cronjob.name")
-)
-
-// K8SCronJobUID returns an attribute KeyValue conforming to the
-// "k8s.cronjob.uid" semantic conventions. It represents the UID of the
-// CronJob.
-func K8SCronJobUID(val string) attribute.KeyValue {
- return K8SCronJobUIDKey.String(val)
-}
-
-// K8SCronJobName returns an attribute KeyValue conforming to the
-// "k8s.cronjob.name" semantic conventions. It represents the name of the
-// CronJob.
-func K8SCronJobName(val string) attribute.KeyValue {
- return K8SCronJobNameKey.String(val)
-}
-
-// The operating system (OS) on which the process represented by this resource
-// is running.
-const (
- // OSTypeKey is the attribute Key conforming to the "os.type" semantic
- // conventions. It represents the operating system type.
- //
- // Type: Enum
- // RequirementLevel: Required
- // Stability: stable
- OSTypeKey = attribute.Key("os.type")
-
- // OSDescriptionKey is the attribute Key conforming to the "os.description"
- // semantic conventions. It represents the human readable (not intended to
- // be parsed) OS version information, like e.g. reported by `ver` or
- // `lsb_release -a` commands.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'Microsoft Windows [Version 10.0.18363.778]', 'Ubuntu 18.04.1
- // LTS'
- OSDescriptionKey = attribute.Key("os.description")
-
- // OSNameKey is the attribute Key conforming to the "os.name" semantic
- // conventions. It represents the human readable operating system name.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'iOS', 'Android', 'Ubuntu'
- OSNameKey = attribute.Key("os.name")
-
- // OSVersionKey is the attribute Key conforming to the "os.version"
- // semantic conventions. It represents the version string of the operating
- // system as defined in [Version
- // Attributes](../../resource/semantic_conventions/README.md#version-attributes).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '14.2.1', '18.04.1'
- OSVersionKey = attribute.Key("os.version")
-)
-
-var (
- // Microsoft Windows
- OSTypeWindows = OSTypeKey.String("windows")
- // Linux
- OSTypeLinux = OSTypeKey.String("linux")
- // Apple Darwin
- OSTypeDarwin = OSTypeKey.String("darwin")
- // FreeBSD
- OSTypeFreeBSD = OSTypeKey.String("freebsd")
- // NetBSD
- OSTypeNetBSD = OSTypeKey.String("netbsd")
- // OpenBSD
- OSTypeOpenBSD = OSTypeKey.String("openbsd")
- // DragonFly BSD
- OSTypeDragonflyBSD = OSTypeKey.String("dragonflybsd")
- // HP-UX (Hewlett Packard Unix)
- OSTypeHPUX = OSTypeKey.String("hpux")
- // AIX (Advanced Interactive eXecutive)
- OSTypeAIX = OSTypeKey.String("aix")
- // SunOS, Oracle Solaris
- OSTypeSolaris = OSTypeKey.String("solaris")
- // IBM z/OS
- OSTypeZOS = OSTypeKey.String("z_os")
-)
-
-// OSDescription returns an attribute KeyValue conforming to the
-// "os.description" semantic conventions. It represents the human readable (not
-// intended to be parsed) OS version information, like e.g. reported by `ver`
-// or `lsb_release -a` commands.
-func OSDescription(val string) attribute.KeyValue {
- return OSDescriptionKey.String(val)
-}
-
-// OSName returns an attribute KeyValue conforming to the "os.name" semantic
-// conventions. It represents the human readable operating system name.
-func OSName(val string) attribute.KeyValue {
- return OSNameKey.String(val)
-}
-
-// OSVersion returns an attribute KeyValue conforming to the "os.version"
-// semantic conventions. It represents the version string of the operating
-// system as defined in [Version
-// Attributes](../../resource/semantic_conventions/README.md#version-attributes).
-func OSVersion(val string) attribute.KeyValue {
- return OSVersionKey.String(val)
-}
-
-// An operating system process.
-const (
- // ProcessPIDKey is the attribute Key conforming to the "process.pid"
- // semantic conventions. It represents the process identifier (PID).
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 1234
- ProcessPIDKey = attribute.Key("process.pid")
-
- // ProcessParentPIDKey is the attribute Key conforming to the
- // "process.parent_pid" semantic conventions. It represents the parent
- // Process identifier (PID).
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 111
- ProcessParentPIDKey = attribute.Key("process.parent_pid")
-
- // ProcessExecutableNameKey is the attribute Key conforming to the
- // "process.executable.name" semantic conventions. It represents the name
- // of the process executable. On Linux based systems, can be set to the
- // `Name` in `proc/[pid]/status`. On Windows, can be set to the base name
- // of `GetProcessImageFileNameW`.
- //
- // Type: string
- // RequirementLevel: ConditionallyRequired (See alternative attributes
- // below.)
- // Stability: stable
- // Examples: 'otelcol'
- ProcessExecutableNameKey = attribute.Key("process.executable.name")
-
- // ProcessExecutablePathKey is the attribute Key conforming to the
- // "process.executable.path" semantic conventions. It represents the full
- // path to the process executable. On Linux based systems, can be set to
- // the target of `proc/[pid]/exe`. On Windows, can be set to the result of
- // `GetProcessImageFileNameW`.
- //
- // Type: string
- // RequirementLevel: ConditionallyRequired (See alternative attributes
- // below.)
- // Stability: stable
- // Examples: '/usr/bin/cmd/otelcol'
- ProcessExecutablePathKey = attribute.Key("process.executable.path")
-
- // ProcessCommandKey is the attribute Key conforming to the
- // "process.command" semantic conventions. It represents the command used
- // to launch the process (i.e. the command name). On Linux based systems,
- // can be set to the zeroth string in `proc/[pid]/cmdline`. On Windows, can
- // be set to the first parameter extracted from `GetCommandLineW`.
- //
- // Type: string
- // RequirementLevel: ConditionallyRequired (See alternative attributes
- // below.)
- // Stability: stable
- // Examples: 'cmd/otelcol'
- ProcessCommandKey = attribute.Key("process.command")
-
- // ProcessCommandLineKey is the attribute Key conforming to the
- // "process.command_line" semantic conventions. It represents the full
- // command used to launch the process as a single string representing the
- // full command. On Windows, can be set to the result of `GetCommandLineW`.
- // Do not set this if you have to assemble it just for monitoring; use
- // `process.command_args` instead.
- //
- // Type: string
- // RequirementLevel: ConditionallyRequired (See alternative attributes
- // below.)
- // Stability: stable
- // Examples: 'C:\\cmd\\otecol --config="my directory\\config.yaml"'
- ProcessCommandLineKey = attribute.Key("process.command_line")
-
- // ProcessCommandArgsKey is the attribute Key conforming to the
- // "process.command_args" semantic conventions. It represents the all the
- // command arguments (including the command/executable itself) as received
- // by the process. On Linux-based systems (and some other Unixoid systems
- // supporting procfs), can be set according to the list of null-delimited
- // strings extracted from `proc/[pid]/cmdline`. For libc-based executables,
- // this would be the full argv vector passed to `main`.
- //
- // Type: string[]
- // RequirementLevel: ConditionallyRequired (See alternative attributes
- // below.)
- // Stability: stable
- // Examples: 'cmd/otecol', '--config=config.yaml'
- ProcessCommandArgsKey = attribute.Key("process.command_args")
-
- // ProcessOwnerKey is the attribute Key conforming to the "process.owner"
- // semantic conventions. It represents the username of the user that owns
- // the process.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'root'
- ProcessOwnerKey = attribute.Key("process.owner")
-)
-
-// ProcessPID returns an attribute KeyValue conforming to the "process.pid"
-// semantic conventions. It represents the process identifier (PID).
-func ProcessPID(val int) attribute.KeyValue {
- return ProcessPIDKey.Int(val)
-}
-
-// ProcessParentPID returns an attribute KeyValue conforming to the
-// "process.parent_pid" semantic conventions. It represents the parent Process
-// identifier (PID).
-func ProcessParentPID(val int) attribute.KeyValue {
- return ProcessParentPIDKey.Int(val)
-}
-
-// ProcessExecutableName returns an attribute KeyValue conforming to the
-// "process.executable.name" semantic conventions. It represents the name of
-// the process executable. On Linux based systems, can be set to the `Name` in
-// `proc/[pid]/status`. On Windows, can be set to the base name of
-// `GetProcessImageFileNameW`.
-func ProcessExecutableName(val string) attribute.KeyValue {
- return ProcessExecutableNameKey.String(val)
-}
-
-// ProcessExecutablePath returns an attribute KeyValue conforming to the
-// "process.executable.path" semantic conventions. It represents the full path
-// to the process executable. On Linux based systems, can be set to the target
-// of `proc/[pid]/exe`. On Windows, can be set to the result of
-// `GetProcessImageFileNameW`.
-func ProcessExecutablePath(val string) attribute.KeyValue {
- return ProcessExecutablePathKey.String(val)
-}
-
-// ProcessCommand returns an attribute KeyValue conforming to the
-// "process.command" semantic conventions. It represents the command used to
-// launch the process (i.e. the command name). On Linux based systems, can be
-// set to the zeroth string in `proc/[pid]/cmdline`. On Windows, can be set to
-// the first parameter extracted from `GetCommandLineW`.
-func ProcessCommand(val string) attribute.KeyValue {
- return ProcessCommandKey.String(val)
-}
-
-// ProcessCommandLine returns an attribute KeyValue conforming to the
-// "process.command_line" semantic conventions. It represents the full command
-// used to launch the process as a single string representing the full command.
-// On Windows, can be set to the result of `GetCommandLineW`. Do not set this
-// if you have to assemble it just for monitoring; use `process.command_args`
-// instead.
-func ProcessCommandLine(val string) attribute.KeyValue {
- return ProcessCommandLineKey.String(val)
-}
-
-// ProcessCommandArgs returns an attribute KeyValue conforming to the
-// "process.command_args" semantic conventions. It represents the all the
-// command arguments (including the command/executable itself) as received by
-// the process. On Linux-based systems (and some other Unixoid systems
-// supporting procfs), can be set according to the list of null-delimited
-// strings extracted from `proc/[pid]/cmdline`. For libc-based executables,
-// this would be the full argv vector passed to `main`.
-func ProcessCommandArgs(val ...string) attribute.KeyValue {
- return ProcessCommandArgsKey.StringSlice(val)
-}
-
-// ProcessOwner returns an attribute KeyValue conforming to the
-// "process.owner" semantic conventions. It represents the username of the user
-// that owns the process.
-func ProcessOwner(val string) attribute.KeyValue {
- return ProcessOwnerKey.String(val)
-}
-
-// The single (language) runtime instance which is monitored.
-const (
- // ProcessRuntimeNameKey is the attribute Key conforming to the
- // "process.runtime.name" semantic conventions. It represents the name of
- // the runtime of this process. For compiled native binaries, this SHOULD
- // be the name of the compiler.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'OpenJDK Runtime Environment'
- ProcessRuntimeNameKey = attribute.Key("process.runtime.name")
-
- // ProcessRuntimeVersionKey is the attribute Key conforming to the
- // "process.runtime.version" semantic conventions. It represents the
- // version of the runtime of this process, as returned by the runtime
- // without modification.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '14.0.2'
- ProcessRuntimeVersionKey = attribute.Key("process.runtime.version")
-
- // ProcessRuntimeDescriptionKey is the attribute Key conforming to the
- // "process.runtime.description" semantic conventions. It represents an
- // additional description about the runtime of the process, for example a
- // specific vendor customization of the runtime environment.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'Eclipse OpenJ9 Eclipse OpenJ9 VM openj9-0.21.0'
- ProcessRuntimeDescriptionKey = attribute.Key("process.runtime.description")
-)
-
-// ProcessRuntimeName returns an attribute KeyValue conforming to the
-// "process.runtime.name" semantic conventions. It represents the name of the
-// runtime of this process. For compiled native binaries, this SHOULD be the
-// name of the compiler.
-func ProcessRuntimeName(val string) attribute.KeyValue {
- return ProcessRuntimeNameKey.String(val)
-}
-
-// ProcessRuntimeVersion returns an attribute KeyValue conforming to the
-// "process.runtime.version" semantic conventions. It represents the version of
-// the runtime of this process, as returned by the runtime without
-// modification.
-func ProcessRuntimeVersion(val string) attribute.KeyValue {
- return ProcessRuntimeVersionKey.String(val)
-}
-
-// ProcessRuntimeDescription returns an attribute KeyValue conforming to the
-// "process.runtime.description" semantic conventions. It represents an
-// additional description about the runtime of the process, for example a
-// specific vendor customization of the runtime environment.
-func ProcessRuntimeDescription(val string) attribute.KeyValue {
- return ProcessRuntimeDescriptionKey.String(val)
-}
-
-// A service instance.
-const (
- // ServiceNameKey is the attribute Key conforming to the "service.name"
- // semantic conventions. It represents the logical name of the service.
- //
- // Type: string
- // RequirementLevel: Required
- // Stability: stable
- // Examples: 'shoppingcart'
- // Note: MUST be the same for all instances of horizontally scaled
- // services. If the value was not specified, SDKs MUST fallback to
- // `unknown_service:` concatenated with
- // [`process.executable.name`](process.md#process), e.g.
- // `unknown_service:bash`. If `process.executable.name` is not available,
- // the value MUST be set to `unknown_service`.
- ServiceNameKey = attribute.Key("service.name")
-)
-
-// ServiceName returns an attribute KeyValue conforming to the
-// "service.name" semantic conventions. It represents the logical name of the
-// service.
-func ServiceName(val string) attribute.KeyValue {
- return ServiceNameKey.String(val)
-}
-
-// A service instance.
-const (
- // ServiceNamespaceKey is the attribute Key conforming to the
- // "service.namespace" semantic conventions. It represents a namespace for
- // `service.name`.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'Shop'
- // Note: A string value having a meaning that helps to distinguish a group
- // of services, for example the team name that owns a group of services.
- // `service.name` is expected to be unique within the same namespace. If
- // `service.namespace` is not specified in the Resource then `service.name`
- // is expected to be unique for all services that have no explicit
- // namespace defined (so the empty/unspecified namespace is simply one more
- // valid namespace). Zero-length namespace string is assumed equal to
- // unspecified namespace.
- ServiceNamespaceKey = attribute.Key("service.namespace")
-
- // ServiceInstanceIDKey is the attribute Key conforming to the
- // "service.instance.id" semantic conventions. It represents the string ID
- // of the service instance.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'my-k8s-pod-deployment-1',
- // '627cc493-f310-47de-96bd-71410b7dec09'
- // Note: MUST be unique for each instance of the same
- // `service.namespace,service.name` pair (in other words
- // `service.namespace,service.name,service.instance.id` triplet MUST be
- // globally unique). The ID helps to distinguish instances of the same
- // service that exist at the same time (e.g. instances of a horizontally
- // scaled service). It is preferable for the ID to be persistent and stay
- // the same for the lifetime of the service instance, however it is
- // acceptable that the ID is ephemeral and changes during important
- // lifetime events for the service (e.g. service restarts). If the service
- // has no inherent unique ID that can be used as the value of this
- // attribute it is recommended to generate a random Version 1 or Version 4
- // RFC 4122 UUID (services aiming for reproducible UUIDs may also use
- // Version 5, see RFC 4122 for more recommendations).
- ServiceInstanceIDKey = attribute.Key("service.instance.id")
-
- // ServiceVersionKey is the attribute Key conforming to the
- // "service.version" semantic conventions. It represents the version string
- // of the service API or implementation.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '2.0.0'
- ServiceVersionKey = attribute.Key("service.version")
-)
-
-// ServiceNamespace returns an attribute KeyValue conforming to the
-// "service.namespace" semantic conventions. It represents a namespace for
-// `service.name`.
-func ServiceNamespace(val string) attribute.KeyValue {
- return ServiceNamespaceKey.String(val)
-}
-
-// ServiceInstanceID returns an attribute KeyValue conforming to the
-// "service.instance.id" semantic conventions. It represents the string ID of
-// the service instance.
-func ServiceInstanceID(val string) attribute.KeyValue {
- return ServiceInstanceIDKey.String(val)
-}
-
-// ServiceVersion returns an attribute KeyValue conforming to the
-// "service.version" semantic conventions. It represents the version string of
-// the service API or implementation.
-func ServiceVersion(val string) attribute.KeyValue {
- return ServiceVersionKey.String(val)
-}
-
-// The telemetry SDK used to capture data recorded by the instrumentation
-// libraries.
-const (
- // TelemetrySDKNameKey is the attribute Key conforming to the
- // "telemetry.sdk.name" semantic conventions. It represents the name of the
- // telemetry SDK as defined above.
- //
- // Type: string
- // RequirementLevel: Required
- // Stability: stable
- // Examples: 'opentelemetry'
- TelemetrySDKNameKey = attribute.Key("telemetry.sdk.name")
-
- // TelemetrySDKLanguageKey is the attribute Key conforming to the
- // "telemetry.sdk.language" semantic conventions. It represents the
- // language of the telemetry SDK.
- //
- // Type: Enum
- // RequirementLevel: Required
- // Stability: stable
- TelemetrySDKLanguageKey = attribute.Key("telemetry.sdk.language")
-
- // TelemetrySDKVersionKey is the attribute Key conforming to the
- // "telemetry.sdk.version" semantic conventions. It represents the version
- // string of the telemetry SDK.
- //
- // Type: string
- // RequirementLevel: Required
- // Stability: stable
- // Examples: '1.2.3'
- TelemetrySDKVersionKey = attribute.Key("telemetry.sdk.version")
-)
-
-var (
- // cpp
- TelemetrySDKLanguageCPP = TelemetrySDKLanguageKey.String("cpp")
- // dotnet
- TelemetrySDKLanguageDotnet = TelemetrySDKLanguageKey.String("dotnet")
- // erlang
- TelemetrySDKLanguageErlang = TelemetrySDKLanguageKey.String("erlang")
- // go
- TelemetrySDKLanguageGo = TelemetrySDKLanguageKey.String("go")
- // java
- TelemetrySDKLanguageJava = TelemetrySDKLanguageKey.String("java")
- // nodejs
- TelemetrySDKLanguageNodejs = TelemetrySDKLanguageKey.String("nodejs")
- // php
- TelemetrySDKLanguagePHP = TelemetrySDKLanguageKey.String("php")
- // python
- TelemetrySDKLanguagePython = TelemetrySDKLanguageKey.String("python")
- // ruby
- TelemetrySDKLanguageRuby = TelemetrySDKLanguageKey.String("ruby")
- // webjs
- TelemetrySDKLanguageWebjs = TelemetrySDKLanguageKey.String("webjs")
- // swift
- TelemetrySDKLanguageSwift = TelemetrySDKLanguageKey.String("swift")
-)
-
-// TelemetrySDKName returns an attribute KeyValue conforming to the
-// "telemetry.sdk.name" semantic conventions. It represents the name of the
-// telemetry SDK as defined above.
-func TelemetrySDKName(val string) attribute.KeyValue {
- return TelemetrySDKNameKey.String(val)
-}
-
-// TelemetrySDKVersion returns an attribute KeyValue conforming to the
-// "telemetry.sdk.version" semantic conventions. It represents the version
-// string of the telemetry SDK.
-func TelemetrySDKVersion(val string) attribute.KeyValue {
- return TelemetrySDKVersionKey.String(val)
-}
-
-// The telemetry SDK used to capture data recorded by the instrumentation
-// libraries.
-const (
- // TelemetryAutoVersionKey is the attribute Key conforming to the
- // "telemetry.auto.version" semantic conventions. It represents the version
- // string of the auto instrumentation agent, if used.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '1.2.3'
- TelemetryAutoVersionKey = attribute.Key("telemetry.auto.version")
-)
-
-// TelemetryAutoVersion returns an attribute KeyValue conforming to the
-// "telemetry.auto.version" semantic conventions. It represents the version
-// string of the auto instrumentation agent, if used.
-func TelemetryAutoVersion(val string) attribute.KeyValue {
- return TelemetryAutoVersionKey.String(val)
-}
-
-// Resource describing the packaged software running the application code. Web
-// engines are typically executed using process.runtime.
-const (
- // WebEngineNameKey is the attribute Key conforming to the "webengine.name"
- // semantic conventions. It represents the name of the web engine.
- //
- // Type: string
- // RequirementLevel: Required
- // Stability: stable
- // Examples: 'WildFly'
- WebEngineNameKey = attribute.Key("webengine.name")
-
- // WebEngineVersionKey is the attribute Key conforming to the
- // "webengine.version" semantic conventions. It represents the version of
- // the web engine.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '21.0.0'
- WebEngineVersionKey = attribute.Key("webengine.version")
-
- // WebEngineDescriptionKey is the attribute Key conforming to the
- // "webengine.description" semantic conventions. It represents the
- // additional description of the web engine (e.g. detailed version and
- // edition information).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'WildFly Full 21.0.0.Final (WildFly Core 13.0.1.Final) -
- // 2.2.2.Final'
- WebEngineDescriptionKey = attribute.Key("webengine.description")
-)
-
-// WebEngineName returns an attribute KeyValue conforming to the
-// "webengine.name" semantic conventions. It represents the name of the web
-// engine.
-func WebEngineName(val string) attribute.KeyValue {
- return WebEngineNameKey.String(val)
-}
-
-// WebEngineVersion returns an attribute KeyValue conforming to the
-// "webengine.version" semantic conventions. It represents the version of the
-// web engine.
-func WebEngineVersion(val string) attribute.KeyValue {
- return WebEngineVersionKey.String(val)
-}
-
-// WebEngineDescription returns an attribute KeyValue conforming to the
-// "webengine.description" semantic conventions. It represents the additional
-// description of the web engine (e.g. detailed version and edition
-// information).
-func WebEngineDescription(val string) attribute.KeyValue {
- return WebEngineDescriptionKey.String(val)
-}
-
-// Attributes used by non-OTLP exporters to represent OpenTelemetry Scope's
-// concepts.
-const (
- // OTelScopeNameKey is the attribute Key conforming to the
- // "otel.scope.name" semantic conventions. It represents the name of the
- // instrumentation scope - (`InstrumentationScope.Name` in OTLP).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'io.opentelemetry.contrib.mongodb'
- OTelScopeNameKey = attribute.Key("otel.scope.name")
-
- // OTelScopeVersionKey is the attribute Key conforming to the
- // "otel.scope.version" semantic conventions. It represents the version of
- // the instrumentation scope - (`InstrumentationScope.Version` in OTLP).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '1.0.0'
- OTelScopeVersionKey = attribute.Key("otel.scope.version")
-)
-
-// OTelScopeName returns an attribute KeyValue conforming to the
-// "otel.scope.name" semantic conventions. It represents the name of the
-// instrumentation scope - (`InstrumentationScope.Name` in OTLP).
-func OTelScopeName(val string) attribute.KeyValue {
- return OTelScopeNameKey.String(val)
-}
-
-// OTelScopeVersion returns an attribute KeyValue conforming to the
-// "otel.scope.version" semantic conventions. It represents the version of the
-// instrumentation scope - (`InstrumentationScope.Version` in OTLP).
-func OTelScopeVersion(val string) attribute.KeyValue {
- return OTelScopeVersionKey.String(val)
-}
-
-// Span attributes used by non-OTLP exporters to represent OpenTelemetry
-// Scope's concepts.
-const (
- // OTelLibraryNameKey is the attribute Key conforming to the
- // "otel.library.name" semantic conventions. It represents the deprecated,
- // use the `otel.scope.name` attribute.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: deprecated
- // Examples: 'io.opentelemetry.contrib.mongodb'
- OTelLibraryNameKey = attribute.Key("otel.library.name")
-
- // OTelLibraryVersionKey is the attribute Key conforming to the
- // "otel.library.version" semantic conventions. It represents the
- // deprecated, use the `otel.scope.version` attribute.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: deprecated
- // Examples: '1.0.0'
- OTelLibraryVersionKey = attribute.Key("otel.library.version")
-)
-
-// OTelLibraryName returns an attribute KeyValue conforming to the
-// "otel.library.name" semantic conventions. It represents the deprecated, use
-// the `otel.scope.name` attribute.
-func OTelLibraryName(val string) attribute.KeyValue {
- return OTelLibraryNameKey.String(val)
-}
-
-// OTelLibraryVersion returns an attribute KeyValue conforming to the
-// "otel.library.version" semantic conventions. It represents the deprecated,
-// use the `otel.scope.version` attribute.
-func OTelLibraryVersion(val string) attribute.KeyValue {
- return OTelLibraryVersionKey.String(val)
-}
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.20.0/schema.go b/vendor/go.opentelemetry.io/otel/semconv/v1.20.0/schema.go
deleted file mode 100644
index 95d0210e38..0000000000
--- a/vendor/go.opentelemetry.io/otel/semconv/v1.20.0/schema.go
+++ /dev/null
@@ -1,9 +0,0 @@
-// Copyright The OpenTelemetry Authors
-// SPDX-License-Identifier: Apache-2.0
-
-package semconv // import "go.opentelemetry.io/otel/semconv/v1.20.0"
-
-// SchemaURL is the schema URL that matches the version of the semantic conventions
-// that this package defines. Semconv packages starting from v1.4.0 must declare
-// non-empty schema URL in the form https://opentelemetry.io/schemas/
-const SchemaURL = "https://opentelemetry.io/schemas/1.20.0"
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.20.0/trace.go b/vendor/go.opentelemetry.io/otel/semconv/v1.20.0/trace.go
deleted file mode 100644
index 90b1b0452c..0000000000
--- a/vendor/go.opentelemetry.io/otel/semconv/v1.20.0/trace.go
+++ /dev/null
@@ -1,2599 +0,0 @@
-// Copyright The OpenTelemetry Authors
-// SPDX-License-Identifier: Apache-2.0
-
-// Code generated from semantic convention specification. DO NOT EDIT.
-
-package semconv // import "go.opentelemetry.io/otel/semconv/v1.20.0"
-
-import "go.opentelemetry.io/otel/attribute"
-
-// The shared attributes used to report a single exception associated with a
-// span or log.
-const (
- // ExceptionTypeKey is the attribute Key conforming to the "exception.type"
- // semantic conventions. It represents the type of the exception (its
- // fully-qualified class name, if applicable). The dynamic type of the
- // exception should be preferred over the static type in languages that
- // support it.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'java.net.ConnectException', 'OSError'
- ExceptionTypeKey = attribute.Key("exception.type")
-
- // ExceptionMessageKey is the attribute Key conforming to the
- // "exception.message" semantic conventions. It represents the exception
- // message.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'Division by zero', "Can't convert 'int' object to str
- // implicitly"
- ExceptionMessageKey = attribute.Key("exception.message")
-
- // ExceptionStacktraceKey is the attribute Key conforming to the
- // "exception.stacktrace" semantic conventions. It represents a stacktrace
- // as a string in the natural representation for the language runtime. The
- // representation is to be determined and documented by each language SIG.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'Exception in thread "main" java.lang.RuntimeException: Test
- // exception\\n at '
- // 'com.example.GenerateTrace.methodB(GenerateTrace.java:13)\\n at '
- // 'com.example.GenerateTrace.methodA(GenerateTrace.java:9)\\n at '
- // 'com.example.GenerateTrace.main(GenerateTrace.java:5)'
- ExceptionStacktraceKey = attribute.Key("exception.stacktrace")
-)
-
-// ExceptionType returns an attribute KeyValue conforming to the
-// "exception.type" semantic conventions. It represents the type of the
-// exception (its fully-qualified class name, if applicable). The dynamic type
-// of the exception should be preferred over the static type in languages that
-// support it.
-func ExceptionType(val string) attribute.KeyValue {
- return ExceptionTypeKey.String(val)
-}
-
-// ExceptionMessage returns an attribute KeyValue conforming to the
-// "exception.message" semantic conventions. It represents the exception
-// message.
-func ExceptionMessage(val string) attribute.KeyValue {
- return ExceptionMessageKey.String(val)
-}
-
-// ExceptionStacktrace returns an attribute KeyValue conforming to the
-// "exception.stacktrace" semantic conventions. It represents a stacktrace as a
-// string in the natural representation for the language runtime. The
-// representation is to be determined and documented by each language SIG.
-func ExceptionStacktrace(val string) attribute.KeyValue {
- return ExceptionStacktraceKey.String(val)
-}
-
-// The attributes described in this section are rather generic. They may be
-// used in any Log Record they apply to.
-const (
- // LogRecordUIDKey is the attribute Key conforming to the "log.record.uid"
- // semantic conventions. It represents a unique identifier for the Log
- // Record.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '01ARZ3NDEKTSV4RRFFQ69G5FAV'
- // Note: If an id is provided, other log records with the same id will be
- // considered duplicates and can be removed safely. This means, that two
- // distinguishable log records MUST have different values.
- // The id MAY be an [Universally Unique Lexicographically Sortable
- // Identifier (ULID)](https://github.com/ulid/spec), but other identifiers
- // (e.g. UUID) may be used as needed.
- LogRecordUIDKey = attribute.Key("log.record.uid")
-)
-
-// LogRecordUID returns an attribute KeyValue conforming to the
-// "log.record.uid" semantic conventions. It represents a unique identifier for
-// the Log Record.
-func LogRecordUID(val string) attribute.KeyValue {
- return LogRecordUIDKey.String(val)
-}
-
-// Span attributes used by AWS Lambda (in addition to general `faas`
-// attributes).
-const (
- // AWSLambdaInvokedARNKey is the attribute Key conforming to the
- // "aws.lambda.invoked_arn" semantic conventions. It represents the full
- // invoked ARN as provided on the `Context` passed to the function
- // (`Lambda-Runtime-Invoked-Function-ARN` header on the
- // `/runtime/invocation/next` applicable).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'arn:aws:lambda:us-east-1:123456:function:myfunction:myalias'
- // Note: This may be different from `cloud.resource_id` if an alias is
- // involved.
- AWSLambdaInvokedARNKey = attribute.Key("aws.lambda.invoked_arn")
-)
-
-// AWSLambdaInvokedARN returns an attribute KeyValue conforming to the
-// "aws.lambda.invoked_arn" semantic conventions. It represents the full
-// invoked ARN as provided on the `Context` passed to the function
-// (`Lambda-Runtime-Invoked-Function-ARN` header on the
-// `/runtime/invocation/next` applicable).
-func AWSLambdaInvokedARN(val string) attribute.KeyValue {
- return AWSLambdaInvokedARNKey.String(val)
-}
-
-// Attributes for CloudEvents. CloudEvents is a specification on how to define
-// event data in a standard way. These attributes can be attached to spans when
-// performing operations with CloudEvents, regardless of the protocol being
-// used.
-const (
- // CloudeventsEventIDKey is the attribute Key conforming to the
- // "cloudevents.event_id" semantic conventions. It represents the
- // [event_id](https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#id)
- // uniquely identifies the event.
- //
- // Type: string
- // RequirementLevel: Required
- // Stability: stable
- // Examples: '123e4567-e89b-12d3-a456-426614174000', '0001'
- CloudeventsEventIDKey = attribute.Key("cloudevents.event_id")
-
- // CloudeventsEventSourceKey is the attribute Key conforming to the
- // "cloudevents.event_source" semantic conventions. It represents the
- // [source](https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#source-1)
- // identifies the context in which an event happened.
- //
- // Type: string
- // RequirementLevel: Required
- // Stability: stable
- // Examples: 'https://github.com/cloudevents',
- // '/cloudevents/spec/pull/123', 'my-service'
- CloudeventsEventSourceKey = attribute.Key("cloudevents.event_source")
-
- // CloudeventsEventSpecVersionKey is the attribute Key conforming to the
- // "cloudevents.event_spec_version" semantic conventions. It represents the
- // [version of the CloudEvents
- // specification](https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#specversion)
- // which the event uses.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '1.0'
- CloudeventsEventSpecVersionKey = attribute.Key("cloudevents.event_spec_version")
-
- // CloudeventsEventTypeKey is the attribute Key conforming to the
- // "cloudevents.event_type" semantic conventions. It represents the
- // [event_type](https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#type)
- // contains a value describing the type of event related to the originating
- // occurrence.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'com.github.pull_request.opened',
- // 'com.example.object.deleted.v2'
- CloudeventsEventTypeKey = attribute.Key("cloudevents.event_type")
-
- // CloudeventsEventSubjectKey is the attribute Key conforming to the
- // "cloudevents.event_subject" semantic conventions. It represents the
- // [subject](https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#subject)
- // of the event in the context of the event producer (identified by
- // source).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'mynewfile.jpg'
- CloudeventsEventSubjectKey = attribute.Key("cloudevents.event_subject")
-)
-
-// CloudeventsEventID returns an attribute KeyValue conforming to the
-// "cloudevents.event_id" semantic conventions. It represents the
-// [event_id](https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#id)
-// uniquely identifies the event.
-func CloudeventsEventID(val string) attribute.KeyValue {
- return CloudeventsEventIDKey.String(val)
-}
-
-// CloudeventsEventSource returns an attribute KeyValue conforming to the
-// "cloudevents.event_source" semantic conventions. It represents the
-// [source](https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#source-1)
-// identifies the context in which an event happened.
-func CloudeventsEventSource(val string) attribute.KeyValue {
- return CloudeventsEventSourceKey.String(val)
-}
-
-// CloudeventsEventSpecVersion returns an attribute KeyValue conforming to
-// the "cloudevents.event_spec_version" semantic conventions. It represents the
-// [version of the CloudEvents
-// specification](https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#specversion)
-// which the event uses.
-func CloudeventsEventSpecVersion(val string) attribute.KeyValue {
- return CloudeventsEventSpecVersionKey.String(val)
-}
-
-// CloudeventsEventType returns an attribute KeyValue conforming to the
-// "cloudevents.event_type" semantic conventions. It represents the
-// [event_type](https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#type)
-// contains a value describing the type of event related to the originating
-// occurrence.
-func CloudeventsEventType(val string) attribute.KeyValue {
- return CloudeventsEventTypeKey.String(val)
-}
-
-// CloudeventsEventSubject returns an attribute KeyValue conforming to the
-// "cloudevents.event_subject" semantic conventions. It represents the
-// [subject](https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#subject)
-// of the event in the context of the event producer (identified by source).
-func CloudeventsEventSubject(val string) attribute.KeyValue {
- return CloudeventsEventSubjectKey.String(val)
-}
-
-// Semantic conventions for the OpenTracing Shim
-const (
- // OpentracingRefTypeKey is the attribute Key conforming to the
- // "opentracing.ref_type" semantic conventions. It represents the
- // parent-child Reference type
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: stable
- // Note: The causal relationship between a child Span and a parent Span.
- OpentracingRefTypeKey = attribute.Key("opentracing.ref_type")
-)
-
-var (
- // The parent Span depends on the child Span in some capacity
- OpentracingRefTypeChildOf = OpentracingRefTypeKey.String("child_of")
- // The parent Span does not depend in any way on the result of the child Span
- OpentracingRefTypeFollowsFrom = OpentracingRefTypeKey.String("follows_from")
-)
-
-// The attributes used to perform database client calls.
-const (
- // DBSystemKey is the attribute Key conforming to the "db.system" semantic
- // conventions. It represents an identifier for the database management
- // system (DBMS) product being used. See below for a list of well-known
- // identifiers.
- //
- // Type: Enum
- // RequirementLevel: Required
- // Stability: stable
- DBSystemKey = attribute.Key("db.system")
-
- // DBConnectionStringKey is the attribute Key conforming to the
- // "db.connection_string" semantic conventions. It represents the
- // connection string used to connect to the database. It is recommended to
- // remove embedded credentials.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'Server=(localdb)\\v11.0;Integrated Security=true;'
- DBConnectionStringKey = attribute.Key("db.connection_string")
-
- // DBUserKey is the attribute Key conforming to the "db.user" semantic
- // conventions. It represents the username for accessing the database.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'readonly_user', 'reporting_user'
- DBUserKey = attribute.Key("db.user")
-
- // DBJDBCDriverClassnameKey is the attribute Key conforming to the
- // "db.jdbc.driver_classname" semantic conventions. It represents the
- // fully-qualified class name of the [Java Database Connectivity
- // (JDBC)](https://docs.oracle.com/javase/8/docs/technotes/guides/jdbc/)
- // driver used to connect.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'org.postgresql.Driver',
- // 'com.microsoft.sqlserver.jdbc.SQLServerDriver'
- DBJDBCDriverClassnameKey = attribute.Key("db.jdbc.driver_classname")
-
- // DBNameKey is the attribute Key conforming to the "db.name" semantic
- // conventions. It represents the this attribute is used to report the name
- // of the database being accessed. For commands that switch the database,
- // this should be set to the target database (even if the command fails).
- //
- // Type: string
- // RequirementLevel: ConditionallyRequired (If applicable.)
- // Stability: stable
- // Examples: 'customers', 'main'
- // Note: In some SQL databases, the database name to be used is called
- // "schema name". In case there are multiple layers that could be
- // considered for database name (e.g. Oracle instance name and schema
- // name), the database name to be used is the more specific layer (e.g.
- // Oracle schema name).
- DBNameKey = attribute.Key("db.name")
-
- // DBStatementKey is the attribute Key conforming to the "db.statement"
- // semantic conventions. It represents the database statement being
- // executed.
- //
- // Type: string
- // RequirementLevel: Recommended (Should be collected by default only if
- // there is sanitization that excludes sensitive information.)
- // Stability: stable
- // Examples: 'SELECT * FROM wuser_table', 'SET mykey "WuValue"'
- DBStatementKey = attribute.Key("db.statement")
-
- // DBOperationKey is the attribute Key conforming to the "db.operation"
- // semantic conventions. It represents the name of the operation being
- // executed, e.g. the [MongoDB command
- // name](https://docs.mongodb.com/manual/reference/command/#database-operations)
- // such as `findAndModify`, or the SQL keyword.
- //
- // Type: string
- // RequirementLevel: ConditionallyRequired (If `db.statement` is not
- // applicable.)
- // Stability: stable
- // Examples: 'findAndModify', 'HMSET', 'SELECT'
- // Note: When setting this to an SQL keyword, it is not recommended to
- // attempt any client-side parsing of `db.statement` just to get this
- // property, but it should be set if the operation name is provided by the
- // library being instrumented. If the SQL statement has an ambiguous
- // operation, or performs more than one operation, this value may be
- // omitted.
- DBOperationKey = attribute.Key("db.operation")
-)
-
-var (
- // Some other SQL database. Fallback only. See notes
- DBSystemOtherSQL = DBSystemKey.String("other_sql")
- // Microsoft SQL Server
- DBSystemMSSQL = DBSystemKey.String("mssql")
- // Microsoft SQL Server Compact
- DBSystemMssqlcompact = DBSystemKey.String("mssqlcompact")
- // MySQL
- DBSystemMySQL = DBSystemKey.String("mysql")
- // Oracle Database
- DBSystemOracle = DBSystemKey.String("oracle")
- // IBM DB2
- DBSystemDB2 = DBSystemKey.String("db2")
- // PostgreSQL
- DBSystemPostgreSQL = DBSystemKey.String("postgresql")
- // Amazon Redshift
- DBSystemRedshift = DBSystemKey.String("redshift")
- // Apache Hive
- DBSystemHive = DBSystemKey.String("hive")
- // Cloudscape
- DBSystemCloudscape = DBSystemKey.String("cloudscape")
- // HyperSQL DataBase
- DBSystemHSQLDB = DBSystemKey.String("hsqldb")
- // Progress Database
- DBSystemProgress = DBSystemKey.String("progress")
- // SAP MaxDB
- DBSystemMaxDB = DBSystemKey.String("maxdb")
- // SAP HANA
- DBSystemHanaDB = DBSystemKey.String("hanadb")
- // Ingres
- DBSystemIngres = DBSystemKey.String("ingres")
- // FirstSQL
- DBSystemFirstSQL = DBSystemKey.String("firstsql")
- // EnterpriseDB
- DBSystemEDB = DBSystemKey.String("edb")
- // InterSystems Caché
- DBSystemCache = DBSystemKey.String("cache")
- // Adabas (Adaptable Database System)
- DBSystemAdabas = DBSystemKey.String("adabas")
- // Firebird
- DBSystemFirebird = DBSystemKey.String("firebird")
- // Apache Derby
- DBSystemDerby = DBSystemKey.String("derby")
- // FileMaker
- DBSystemFilemaker = DBSystemKey.String("filemaker")
- // Informix
- DBSystemInformix = DBSystemKey.String("informix")
- // InstantDB
- DBSystemInstantDB = DBSystemKey.String("instantdb")
- // InterBase
- DBSystemInterbase = DBSystemKey.String("interbase")
- // MariaDB
- DBSystemMariaDB = DBSystemKey.String("mariadb")
- // Netezza
- DBSystemNetezza = DBSystemKey.String("netezza")
- // Pervasive PSQL
- DBSystemPervasive = DBSystemKey.String("pervasive")
- // PointBase
- DBSystemPointbase = DBSystemKey.String("pointbase")
- // SQLite
- DBSystemSqlite = DBSystemKey.String("sqlite")
- // Sybase
- DBSystemSybase = DBSystemKey.String("sybase")
- // Teradata
- DBSystemTeradata = DBSystemKey.String("teradata")
- // Vertica
- DBSystemVertica = DBSystemKey.String("vertica")
- // H2
- DBSystemH2 = DBSystemKey.String("h2")
- // ColdFusion IMQ
- DBSystemColdfusion = DBSystemKey.String("coldfusion")
- // Apache Cassandra
- DBSystemCassandra = DBSystemKey.String("cassandra")
- // Apache HBase
- DBSystemHBase = DBSystemKey.String("hbase")
- // MongoDB
- DBSystemMongoDB = DBSystemKey.String("mongodb")
- // Redis
- DBSystemRedis = DBSystemKey.String("redis")
- // Couchbase
- DBSystemCouchbase = DBSystemKey.String("couchbase")
- // CouchDB
- DBSystemCouchDB = DBSystemKey.String("couchdb")
- // Microsoft Azure Cosmos DB
- DBSystemCosmosDB = DBSystemKey.String("cosmosdb")
- // Amazon DynamoDB
- DBSystemDynamoDB = DBSystemKey.String("dynamodb")
- // Neo4j
- DBSystemNeo4j = DBSystemKey.String("neo4j")
- // Apache Geode
- DBSystemGeode = DBSystemKey.String("geode")
- // Elasticsearch
- DBSystemElasticsearch = DBSystemKey.String("elasticsearch")
- // Memcached
- DBSystemMemcached = DBSystemKey.String("memcached")
- // CockroachDB
- DBSystemCockroachdb = DBSystemKey.String("cockroachdb")
- // OpenSearch
- DBSystemOpensearch = DBSystemKey.String("opensearch")
- // ClickHouse
- DBSystemClickhouse = DBSystemKey.String("clickhouse")
- // Cloud Spanner
- DBSystemSpanner = DBSystemKey.String("spanner")
- // Trino
- DBSystemTrino = DBSystemKey.String("trino")
-)
-
-// DBConnectionString returns an attribute KeyValue conforming to the
-// "db.connection_string" semantic conventions. It represents the connection
-// string used to connect to the database. It is recommended to remove embedded
-// credentials.
-func DBConnectionString(val string) attribute.KeyValue {
- return DBConnectionStringKey.String(val)
-}
-
-// DBUser returns an attribute KeyValue conforming to the "db.user" semantic
-// conventions. It represents the username for accessing the database.
-func DBUser(val string) attribute.KeyValue {
- return DBUserKey.String(val)
-}
-
-// DBJDBCDriverClassname returns an attribute KeyValue conforming to the
-// "db.jdbc.driver_classname" semantic conventions. It represents the
-// fully-qualified class name of the [Java Database Connectivity
-// (JDBC)](https://docs.oracle.com/javase/8/docs/technotes/guides/jdbc/) driver
-// used to connect.
-func DBJDBCDriverClassname(val string) attribute.KeyValue {
- return DBJDBCDriverClassnameKey.String(val)
-}
-
-// DBName returns an attribute KeyValue conforming to the "db.name" semantic
-// conventions. It represents the this attribute is used to report the name of
-// the database being accessed. For commands that switch the database, this
-// should be set to the target database (even if the command fails).
-func DBName(val string) attribute.KeyValue {
- return DBNameKey.String(val)
-}
-
-// DBStatement returns an attribute KeyValue conforming to the
-// "db.statement" semantic conventions. It represents the database statement
-// being executed.
-func DBStatement(val string) attribute.KeyValue {
- return DBStatementKey.String(val)
-}
-
-// DBOperation returns an attribute KeyValue conforming to the
-// "db.operation" semantic conventions. It represents the name of the operation
-// being executed, e.g. the [MongoDB command
-// name](https://docs.mongodb.com/manual/reference/command/#database-operations)
-// such as `findAndModify`, or the SQL keyword.
-func DBOperation(val string) attribute.KeyValue {
- return DBOperationKey.String(val)
-}
-
-// Connection-level attributes for Microsoft SQL Server
-const (
- // DBMSSQLInstanceNameKey is the attribute Key conforming to the
- // "db.mssql.instance_name" semantic conventions. It represents the
- // Microsoft SQL Server [instance
- // name](https://docs.microsoft.com/en-us/sql/connect/jdbc/building-the-connection-url?view=sql-server-ver15)
- // connecting to. This name is used to determine the port of a named
- // instance.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'MSSQLSERVER'
- // Note: If setting a `db.mssql.instance_name`, `net.peer.port` is no
- // longer required (but still recommended if non-standard).
- DBMSSQLInstanceNameKey = attribute.Key("db.mssql.instance_name")
-)
-
-// DBMSSQLInstanceName returns an attribute KeyValue conforming to the
-// "db.mssql.instance_name" semantic conventions. It represents the Microsoft
-// SQL Server [instance
-// name](https://docs.microsoft.com/en-us/sql/connect/jdbc/building-the-connection-url?view=sql-server-ver15)
-// connecting to. This name is used to determine the port of a named instance.
-func DBMSSQLInstanceName(val string) attribute.KeyValue {
- return DBMSSQLInstanceNameKey.String(val)
-}
-
-// Call-level attributes for Cassandra
-const (
- // DBCassandraPageSizeKey is the attribute Key conforming to the
- // "db.cassandra.page_size" semantic conventions. It represents the fetch
- // size used for paging, i.e. how many rows will be returned at once.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 5000
- DBCassandraPageSizeKey = attribute.Key("db.cassandra.page_size")
-
- // DBCassandraConsistencyLevelKey is the attribute Key conforming to the
- // "db.cassandra.consistency_level" semantic conventions. It represents the
- // consistency level of the query. Based on consistency values from
- // [CQL](https://docs.datastax.com/en/cassandra-oss/3.0/cassandra/dml/dmlConfigConsistency.html).
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: stable
- DBCassandraConsistencyLevelKey = attribute.Key("db.cassandra.consistency_level")
-
- // DBCassandraTableKey is the attribute Key conforming to the
- // "db.cassandra.table" semantic conventions. It represents the name of the
- // primary table that the operation is acting upon, including the keyspace
- // name (if applicable).
- //
- // Type: string
- // RequirementLevel: Recommended
- // Stability: stable
- // Examples: 'mytable'
- // Note: This mirrors the db.sql.table attribute but references cassandra
- // rather than sql. It is not recommended to attempt any client-side
- // parsing of `db.statement` just to get this property, but it should be
- // set if it is provided by the library being instrumented. If the
- // operation is acting upon an anonymous table, or more than one table,
- // this value MUST NOT be set.
- DBCassandraTableKey = attribute.Key("db.cassandra.table")
-
- // DBCassandraIdempotenceKey is the attribute Key conforming to the
- // "db.cassandra.idempotence" semantic conventions. It represents the
- // whether or not the query is idempotent.
- //
- // Type: boolean
- // RequirementLevel: Optional
- // Stability: stable
- DBCassandraIdempotenceKey = attribute.Key("db.cassandra.idempotence")
-
- // DBCassandraSpeculativeExecutionCountKey is the attribute Key conforming
- // to the "db.cassandra.speculative_execution_count" semantic conventions.
- // It represents the number of times a query was speculatively executed.
- // Not set or `0` if the query was not executed speculatively.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 0, 2
- DBCassandraSpeculativeExecutionCountKey = attribute.Key("db.cassandra.speculative_execution_count")
-
- // DBCassandraCoordinatorIDKey is the attribute Key conforming to the
- // "db.cassandra.coordinator.id" semantic conventions. It represents the ID
- // of the coordinating node for a query.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'be13faa2-8574-4d71-926d-27f16cf8a7af'
- DBCassandraCoordinatorIDKey = attribute.Key("db.cassandra.coordinator.id")
-
- // DBCassandraCoordinatorDCKey is the attribute Key conforming to the
- // "db.cassandra.coordinator.dc" semantic conventions. It represents the
- // data center of the coordinating node for a query.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'us-west-2'
- DBCassandraCoordinatorDCKey = attribute.Key("db.cassandra.coordinator.dc")
-)
-
-var (
- // all
- DBCassandraConsistencyLevelAll = DBCassandraConsistencyLevelKey.String("all")
- // each_quorum
- DBCassandraConsistencyLevelEachQuorum = DBCassandraConsistencyLevelKey.String("each_quorum")
- // quorum
- DBCassandraConsistencyLevelQuorum = DBCassandraConsistencyLevelKey.String("quorum")
- // local_quorum
- DBCassandraConsistencyLevelLocalQuorum = DBCassandraConsistencyLevelKey.String("local_quorum")
- // one
- DBCassandraConsistencyLevelOne = DBCassandraConsistencyLevelKey.String("one")
- // two
- DBCassandraConsistencyLevelTwo = DBCassandraConsistencyLevelKey.String("two")
- // three
- DBCassandraConsistencyLevelThree = DBCassandraConsistencyLevelKey.String("three")
- // local_one
- DBCassandraConsistencyLevelLocalOne = DBCassandraConsistencyLevelKey.String("local_one")
- // any
- DBCassandraConsistencyLevelAny = DBCassandraConsistencyLevelKey.String("any")
- // serial
- DBCassandraConsistencyLevelSerial = DBCassandraConsistencyLevelKey.String("serial")
- // local_serial
- DBCassandraConsistencyLevelLocalSerial = DBCassandraConsistencyLevelKey.String("local_serial")
-)
-
-// DBCassandraPageSize returns an attribute KeyValue conforming to the
-// "db.cassandra.page_size" semantic conventions. It represents the fetch size
-// used for paging, i.e. how many rows will be returned at once.
-func DBCassandraPageSize(val int) attribute.KeyValue {
- return DBCassandraPageSizeKey.Int(val)
-}
-
-// DBCassandraTable returns an attribute KeyValue conforming to the
-// "db.cassandra.table" semantic conventions. It represents the name of the
-// primary table that the operation is acting upon, including the keyspace name
-// (if applicable).
-func DBCassandraTable(val string) attribute.KeyValue {
- return DBCassandraTableKey.String(val)
-}
-
-// DBCassandraIdempotence returns an attribute KeyValue conforming to the
-// "db.cassandra.idempotence" semantic conventions. It represents the whether
-// or not the query is idempotent.
-func DBCassandraIdempotence(val bool) attribute.KeyValue {
- return DBCassandraIdempotenceKey.Bool(val)
-}
-
-// DBCassandraSpeculativeExecutionCount returns an attribute KeyValue
-// conforming to the "db.cassandra.speculative_execution_count" semantic
-// conventions. It represents the number of times a query was speculatively
-// executed. Not set or `0` if the query was not executed speculatively.
-func DBCassandraSpeculativeExecutionCount(val int) attribute.KeyValue {
- return DBCassandraSpeculativeExecutionCountKey.Int(val)
-}
-
-// DBCassandraCoordinatorID returns an attribute KeyValue conforming to the
-// "db.cassandra.coordinator.id" semantic conventions. It represents the ID of
-// the coordinating node for a query.
-func DBCassandraCoordinatorID(val string) attribute.KeyValue {
- return DBCassandraCoordinatorIDKey.String(val)
-}
-
-// DBCassandraCoordinatorDC returns an attribute KeyValue conforming to the
-// "db.cassandra.coordinator.dc" semantic conventions. It represents the data
-// center of the coordinating node for a query.
-func DBCassandraCoordinatorDC(val string) attribute.KeyValue {
- return DBCassandraCoordinatorDCKey.String(val)
-}
-
-// Call-level attributes for Redis
-const (
- // DBRedisDBIndexKey is the attribute Key conforming to the
- // "db.redis.database_index" semantic conventions. It represents the index
- // of the database being accessed as used in the [`SELECT`
- // command](https://redis.io/commands/select), provided as an integer. To
- // be used instead of the generic `db.name` attribute.
- //
- // Type: int
- // RequirementLevel: ConditionallyRequired (If other than the default
- // database (`0`).)
- // Stability: stable
- // Examples: 0, 1, 15
- DBRedisDBIndexKey = attribute.Key("db.redis.database_index")
-)
-
-// DBRedisDBIndex returns an attribute KeyValue conforming to the
-// "db.redis.database_index" semantic conventions. It represents the index of
-// the database being accessed as used in the [`SELECT`
-// command](https://redis.io/commands/select), provided as an integer. To be
-// used instead of the generic `db.name` attribute.
-func DBRedisDBIndex(val int) attribute.KeyValue {
- return DBRedisDBIndexKey.Int(val)
-}
-
-// Call-level attributes for MongoDB
-const (
- // DBMongoDBCollectionKey is the attribute Key conforming to the
- // "db.mongodb.collection" semantic conventions. It represents the
- // collection being accessed within the database stated in `db.name`.
- //
- // Type: string
- // RequirementLevel: Required
- // Stability: stable
- // Examples: 'customers', 'products'
- DBMongoDBCollectionKey = attribute.Key("db.mongodb.collection")
-)
-
-// DBMongoDBCollection returns an attribute KeyValue conforming to the
-// "db.mongodb.collection" semantic conventions. It represents the collection
-// being accessed within the database stated in `db.name`.
-func DBMongoDBCollection(val string) attribute.KeyValue {
- return DBMongoDBCollectionKey.String(val)
-}
-
-// Call-level attributes for SQL databases
-const (
- // DBSQLTableKey is the attribute Key conforming to the "db.sql.table"
- // semantic conventions. It represents the name of the primary table that
- // the operation is acting upon, including the database name (if
- // applicable).
- //
- // Type: string
- // RequirementLevel: Recommended
- // Stability: stable
- // Examples: 'public.users', 'customers'
- // Note: It is not recommended to attempt any client-side parsing of
- // `db.statement` just to get this property, but it should be set if it is
- // provided by the library being instrumented. If the operation is acting
- // upon an anonymous table, or more than one table, this value MUST NOT be
- // set.
- DBSQLTableKey = attribute.Key("db.sql.table")
-)
-
-// DBSQLTable returns an attribute KeyValue conforming to the "db.sql.table"
-// semantic conventions. It represents the name of the primary table that the
-// operation is acting upon, including the database name (if applicable).
-func DBSQLTable(val string) attribute.KeyValue {
- return DBSQLTableKey.String(val)
-}
-
-// Call-level attributes for Cosmos DB.
-const (
- // DBCosmosDBClientIDKey is the attribute Key conforming to the
- // "db.cosmosdb.client_id" semantic conventions. It represents the unique
- // Cosmos client instance id.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '3ba4827d-4422-483f-b59f-85b74211c11d'
- DBCosmosDBClientIDKey = attribute.Key("db.cosmosdb.client_id")
-
- // DBCosmosDBOperationTypeKey is the attribute Key conforming to the
- // "db.cosmosdb.operation_type" semantic conventions. It represents the
- // cosmosDB Operation Type.
- //
- // Type: Enum
- // RequirementLevel: ConditionallyRequired (when performing one of the
- // operations in this list)
- // Stability: stable
- DBCosmosDBOperationTypeKey = attribute.Key("db.cosmosdb.operation_type")
-
- // DBCosmosDBConnectionModeKey is the attribute Key conforming to the
- // "db.cosmosdb.connection_mode" semantic conventions. It represents the
- // cosmos client connection mode.
- //
- // Type: Enum
- // RequirementLevel: ConditionallyRequired (if not `direct` (or pick gw as
- // default))
- // Stability: stable
- DBCosmosDBConnectionModeKey = attribute.Key("db.cosmosdb.connection_mode")
-
- // DBCosmosDBContainerKey is the attribute Key conforming to the
- // "db.cosmosdb.container" semantic conventions. It represents the cosmos
- // DB container name.
- //
- // Type: string
- // RequirementLevel: ConditionallyRequired (if available)
- // Stability: stable
- // Examples: 'anystring'
- DBCosmosDBContainerKey = attribute.Key("db.cosmosdb.container")
-
- // DBCosmosDBRequestContentLengthKey is the attribute Key conforming to the
- // "db.cosmosdb.request_content_length" semantic conventions. It represents
- // the request payload size in bytes
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- DBCosmosDBRequestContentLengthKey = attribute.Key("db.cosmosdb.request_content_length")
-
- // DBCosmosDBStatusCodeKey is the attribute Key conforming to the
- // "db.cosmosdb.status_code" semantic conventions. It represents the cosmos
- // DB status code.
- //
- // Type: int
- // RequirementLevel: ConditionallyRequired (if response was received)
- // Stability: stable
- // Examples: 200, 201
- DBCosmosDBStatusCodeKey = attribute.Key("db.cosmosdb.status_code")
-
- // DBCosmosDBSubStatusCodeKey is the attribute Key conforming to the
- // "db.cosmosdb.sub_status_code" semantic conventions. It represents the
- // cosmos DB sub status code.
- //
- // Type: int
- // RequirementLevel: ConditionallyRequired (when response was received and
- // contained sub-code.)
- // Stability: stable
- // Examples: 1000, 1002
- DBCosmosDBSubStatusCodeKey = attribute.Key("db.cosmosdb.sub_status_code")
-
- // DBCosmosDBRequestChargeKey is the attribute Key conforming to the
- // "db.cosmosdb.request_charge" semantic conventions. It represents the rU
- // consumed for that operation
- //
- // Type: double
- // RequirementLevel: ConditionallyRequired (when available)
- // Stability: stable
- // Examples: 46.18, 1.0
- DBCosmosDBRequestChargeKey = attribute.Key("db.cosmosdb.request_charge")
-)
-
-var (
- // invalid
- DBCosmosDBOperationTypeInvalid = DBCosmosDBOperationTypeKey.String("Invalid")
- // create
- DBCosmosDBOperationTypeCreate = DBCosmosDBOperationTypeKey.String("Create")
- // patch
- DBCosmosDBOperationTypePatch = DBCosmosDBOperationTypeKey.String("Patch")
- // read
- DBCosmosDBOperationTypeRead = DBCosmosDBOperationTypeKey.String("Read")
- // read_feed
- DBCosmosDBOperationTypeReadFeed = DBCosmosDBOperationTypeKey.String("ReadFeed")
- // delete
- DBCosmosDBOperationTypeDelete = DBCosmosDBOperationTypeKey.String("Delete")
- // replace
- DBCosmosDBOperationTypeReplace = DBCosmosDBOperationTypeKey.String("Replace")
- // execute
- DBCosmosDBOperationTypeExecute = DBCosmosDBOperationTypeKey.String("Execute")
- // query
- DBCosmosDBOperationTypeQuery = DBCosmosDBOperationTypeKey.String("Query")
- // head
- DBCosmosDBOperationTypeHead = DBCosmosDBOperationTypeKey.String("Head")
- // head_feed
- DBCosmosDBOperationTypeHeadFeed = DBCosmosDBOperationTypeKey.String("HeadFeed")
- // upsert
- DBCosmosDBOperationTypeUpsert = DBCosmosDBOperationTypeKey.String("Upsert")
- // batch
- DBCosmosDBOperationTypeBatch = DBCosmosDBOperationTypeKey.String("Batch")
- // query_plan
- DBCosmosDBOperationTypeQueryPlan = DBCosmosDBOperationTypeKey.String("QueryPlan")
- // execute_javascript
- DBCosmosDBOperationTypeExecuteJavascript = DBCosmosDBOperationTypeKey.String("ExecuteJavaScript")
-)
-
-var (
- // Gateway (HTTP) connections mode
- DBCosmosDBConnectionModeGateway = DBCosmosDBConnectionModeKey.String("gateway")
- // Direct connection
- DBCosmosDBConnectionModeDirect = DBCosmosDBConnectionModeKey.String("direct")
-)
-
-// DBCosmosDBClientID returns an attribute KeyValue conforming to the
-// "db.cosmosdb.client_id" semantic conventions. It represents the unique
-// Cosmos client instance id.
-func DBCosmosDBClientID(val string) attribute.KeyValue {
- return DBCosmosDBClientIDKey.String(val)
-}
-
-// DBCosmosDBContainer returns an attribute KeyValue conforming to the
-// "db.cosmosdb.container" semantic conventions. It represents the cosmos DB
-// container name.
-func DBCosmosDBContainer(val string) attribute.KeyValue {
- return DBCosmosDBContainerKey.String(val)
-}
-
-// DBCosmosDBRequestContentLength returns an attribute KeyValue conforming
-// to the "db.cosmosdb.request_content_length" semantic conventions. It
-// represents the request payload size in bytes
-func DBCosmosDBRequestContentLength(val int) attribute.KeyValue {
- return DBCosmosDBRequestContentLengthKey.Int(val)
-}
-
-// DBCosmosDBStatusCode returns an attribute KeyValue conforming to the
-// "db.cosmosdb.status_code" semantic conventions. It represents the cosmos DB
-// status code.
-func DBCosmosDBStatusCode(val int) attribute.KeyValue {
- return DBCosmosDBStatusCodeKey.Int(val)
-}
-
-// DBCosmosDBSubStatusCode returns an attribute KeyValue conforming to the
-// "db.cosmosdb.sub_status_code" semantic conventions. It represents the cosmos
-// DB sub status code.
-func DBCosmosDBSubStatusCode(val int) attribute.KeyValue {
- return DBCosmosDBSubStatusCodeKey.Int(val)
-}
-
-// DBCosmosDBRequestCharge returns an attribute KeyValue conforming to the
-// "db.cosmosdb.request_charge" semantic conventions. It represents the rU
-// consumed for that operation
-func DBCosmosDBRequestCharge(val float64) attribute.KeyValue {
- return DBCosmosDBRequestChargeKey.Float64(val)
-}
-
-// Span attributes used by non-OTLP exporters to represent OpenTelemetry Span's
-// concepts.
-const (
- // OTelStatusCodeKey is the attribute Key conforming to the
- // "otel.status_code" semantic conventions. It represents the name of the
- // code, either "OK" or "ERROR". MUST NOT be set if the status code is
- // UNSET.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: stable
- OTelStatusCodeKey = attribute.Key("otel.status_code")
-
- // OTelStatusDescriptionKey is the attribute Key conforming to the
- // "otel.status_description" semantic conventions. It represents the
- // description of the Status if it has a value, otherwise not set.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'resource not found'
- OTelStatusDescriptionKey = attribute.Key("otel.status_description")
-)
-
-var (
- // The operation has been validated by an Application developer or Operator to have completed successfully
- OTelStatusCodeOk = OTelStatusCodeKey.String("OK")
- // The operation contains an error
- OTelStatusCodeError = OTelStatusCodeKey.String("ERROR")
-)
-
-// OTelStatusDescription returns an attribute KeyValue conforming to the
-// "otel.status_description" semantic conventions. It represents the
-// description of the Status if it has a value, otherwise not set.
-func OTelStatusDescription(val string) attribute.KeyValue {
- return OTelStatusDescriptionKey.String(val)
-}
-
-// This semantic convention describes an instance of a function that runs
-// without provisioning or managing of servers (also known as serverless
-// functions or Function as a Service (FaaS)) with spans.
-const (
- // FaaSTriggerKey is the attribute Key conforming to the "faas.trigger"
- // semantic conventions. It represents the type of the trigger which caused
- // this function invocation.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: stable
- // Note: For the server/consumer span on the incoming side,
- // `faas.trigger` MUST be set.
- //
- // Clients invoking FaaS instances usually cannot set `faas.trigger`,
- // since they would typically need to look in the payload to determine
- // the event type. If clients set it, it should be the same as the
- // trigger that corresponding incoming would have (i.e., this has
- // nothing to do with the underlying transport used to make the API
- // call to invoke the lambda, which is often HTTP).
- FaaSTriggerKey = attribute.Key("faas.trigger")
-
- // FaaSInvocationIDKey is the attribute Key conforming to the
- // "faas.invocation_id" semantic conventions. It represents the invocation
- // ID of the current function invocation.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'af9d5aa4-a685-4c5f-a22b-444f80b3cc28'
- FaaSInvocationIDKey = attribute.Key("faas.invocation_id")
-)
-
-var (
- // A response to some data source operation such as a database or filesystem read/write
- FaaSTriggerDatasource = FaaSTriggerKey.String("datasource")
- // To provide an answer to an inbound HTTP request
- FaaSTriggerHTTP = FaaSTriggerKey.String("http")
- // A function is set to be executed when messages are sent to a messaging system
- FaaSTriggerPubsub = FaaSTriggerKey.String("pubsub")
- // A function is scheduled to be executed regularly
- FaaSTriggerTimer = FaaSTriggerKey.String("timer")
- // If none of the others apply
- FaaSTriggerOther = FaaSTriggerKey.String("other")
-)
-
-// FaaSInvocationID returns an attribute KeyValue conforming to the
-// "faas.invocation_id" semantic conventions. It represents the invocation ID
-// of the current function invocation.
-func FaaSInvocationID(val string) attribute.KeyValue {
- return FaaSInvocationIDKey.String(val)
-}
-
-// Semantic Convention for FaaS triggered as a response to some data source
-// operation such as a database or filesystem read/write.
-const (
- // FaaSDocumentCollectionKey is the attribute Key conforming to the
- // "faas.document.collection" semantic conventions. It represents the name
- // of the source on which the triggering operation was performed. For
- // example, in Cloud Storage or S3 corresponds to the bucket name, and in
- // Cosmos DB to the database name.
- //
- // Type: string
- // RequirementLevel: Required
- // Stability: stable
- // Examples: 'myBucketName', 'myDBName'
- FaaSDocumentCollectionKey = attribute.Key("faas.document.collection")
-
- // FaaSDocumentOperationKey is the attribute Key conforming to the
- // "faas.document.operation" semantic conventions. It represents the
- // describes the type of the operation that was performed on the data.
- //
- // Type: Enum
- // RequirementLevel: Required
- // Stability: stable
- FaaSDocumentOperationKey = attribute.Key("faas.document.operation")
-
- // FaaSDocumentTimeKey is the attribute Key conforming to the
- // "faas.document.time" semantic conventions. It represents a string
- // containing the time when the data was accessed in the [ISO
- // 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format
- // expressed in [UTC](https://www.w3.org/TR/NOTE-datetime).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '2020-01-23T13:47:06Z'
- FaaSDocumentTimeKey = attribute.Key("faas.document.time")
-
- // FaaSDocumentNameKey is the attribute Key conforming to the
- // "faas.document.name" semantic conventions. It represents the document
- // name/table subjected to the operation. For example, in Cloud Storage or
- // S3 is the name of the file, and in Cosmos DB the table name.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'myFile.txt', 'myTableName'
- FaaSDocumentNameKey = attribute.Key("faas.document.name")
-)
-
-var (
- // When a new object is created
- FaaSDocumentOperationInsert = FaaSDocumentOperationKey.String("insert")
- // When an object is modified
- FaaSDocumentOperationEdit = FaaSDocumentOperationKey.String("edit")
- // When an object is deleted
- FaaSDocumentOperationDelete = FaaSDocumentOperationKey.String("delete")
-)
-
-// FaaSDocumentCollection returns an attribute KeyValue conforming to the
-// "faas.document.collection" semantic conventions. It represents the name of
-// the source on which the triggering operation was performed. For example, in
-// Cloud Storage or S3 corresponds to the bucket name, and in Cosmos DB to the
-// database name.
-func FaaSDocumentCollection(val string) attribute.KeyValue {
- return FaaSDocumentCollectionKey.String(val)
-}
-
-// FaaSDocumentTime returns an attribute KeyValue conforming to the
-// "faas.document.time" semantic conventions. It represents a string containing
-// the time when the data was accessed in the [ISO
-// 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format
-// expressed in [UTC](https://www.w3.org/TR/NOTE-datetime).
-func FaaSDocumentTime(val string) attribute.KeyValue {
- return FaaSDocumentTimeKey.String(val)
-}
-
-// FaaSDocumentName returns an attribute KeyValue conforming to the
-// "faas.document.name" semantic conventions. It represents the document
-// name/table subjected to the operation. For example, in Cloud Storage or S3
-// is the name of the file, and in Cosmos DB the table name.
-func FaaSDocumentName(val string) attribute.KeyValue {
- return FaaSDocumentNameKey.String(val)
-}
-
-// Semantic Convention for FaaS scheduled to be executed regularly.
-const (
- // FaaSTimeKey is the attribute Key conforming to the "faas.time" semantic
- // conventions. It represents a string containing the function invocation
- // time in the [ISO
- // 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format
- // expressed in [UTC](https://www.w3.org/TR/NOTE-datetime).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '2020-01-23T13:47:06Z'
- FaaSTimeKey = attribute.Key("faas.time")
-
- // FaaSCronKey is the attribute Key conforming to the "faas.cron" semantic
- // conventions. It represents a string containing the schedule period as
- // [Cron
- // Expression](https://docs.oracle.com/cd/E12058_01/doc/doc.1014/e12030/cron_expressions.htm).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '0/5 * * * ? *'
- FaaSCronKey = attribute.Key("faas.cron")
-)
-
-// FaaSTime returns an attribute KeyValue conforming to the "faas.time"
-// semantic conventions. It represents a string containing the function
-// invocation time in the [ISO
-// 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format
-// expressed in [UTC](https://www.w3.org/TR/NOTE-datetime).
-func FaaSTime(val string) attribute.KeyValue {
- return FaaSTimeKey.String(val)
-}
-
-// FaaSCron returns an attribute KeyValue conforming to the "faas.cron"
-// semantic conventions. It represents a string containing the schedule period
-// as [Cron
-// Expression](https://docs.oracle.com/cd/E12058_01/doc/doc.1014/e12030/cron_expressions.htm).
-func FaaSCron(val string) attribute.KeyValue {
- return FaaSCronKey.String(val)
-}
-
-// Contains additional attributes for incoming FaaS spans.
-const (
- // FaaSColdstartKey is the attribute Key conforming to the "faas.coldstart"
- // semantic conventions. It represents a boolean that is true if the
- // serverless function is executed for the first time (aka cold-start).
- //
- // Type: boolean
- // RequirementLevel: Optional
- // Stability: stable
- FaaSColdstartKey = attribute.Key("faas.coldstart")
-)
-
-// FaaSColdstart returns an attribute KeyValue conforming to the
-// "faas.coldstart" semantic conventions. It represents a boolean that is true
-// if the serverless function is executed for the first time (aka cold-start).
-func FaaSColdstart(val bool) attribute.KeyValue {
- return FaaSColdstartKey.Bool(val)
-}
-
-// Contains additional attributes for outgoing FaaS spans.
-const (
- // FaaSInvokedNameKey is the attribute Key conforming to the
- // "faas.invoked_name" semantic conventions. It represents the name of the
- // invoked function.
- //
- // Type: string
- // RequirementLevel: Required
- // Stability: stable
- // Examples: 'my-function'
- // Note: SHOULD be equal to the `faas.name` resource attribute of the
- // invoked function.
- FaaSInvokedNameKey = attribute.Key("faas.invoked_name")
-
- // FaaSInvokedProviderKey is the attribute Key conforming to the
- // "faas.invoked_provider" semantic conventions. It represents the cloud
- // provider of the invoked function.
- //
- // Type: Enum
- // RequirementLevel: Required
- // Stability: stable
- // Note: SHOULD be equal to the `cloud.provider` resource attribute of the
- // invoked function.
- FaaSInvokedProviderKey = attribute.Key("faas.invoked_provider")
-
- // FaaSInvokedRegionKey is the attribute Key conforming to the
- // "faas.invoked_region" semantic conventions. It represents the cloud
- // region of the invoked function.
- //
- // Type: string
- // RequirementLevel: ConditionallyRequired (For some cloud providers, like
- // AWS or GCP, the region in which a function is hosted is essential to
- // uniquely identify the function and also part of its endpoint. Since it's
- // part of the endpoint being called, the region is always known to
- // clients. In these cases, `faas.invoked_region` MUST be set accordingly.
- // If the region is unknown to the client or not required for identifying
- // the invoked function, setting `faas.invoked_region` is optional.)
- // Stability: stable
- // Examples: 'eu-central-1'
- // Note: SHOULD be equal to the `cloud.region` resource attribute of the
- // invoked function.
- FaaSInvokedRegionKey = attribute.Key("faas.invoked_region")
-)
-
-var (
- // Alibaba Cloud
- FaaSInvokedProviderAlibabaCloud = FaaSInvokedProviderKey.String("alibaba_cloud")
- // Amazon Web Services
- FaaSInvokedProviderAWS = FaaSInvokedProviderKey.String("aws")
- // Microsoft Azure
- FaaSInvokedProviderAzure = FaaSInvokedProviderKey.String("azure")
- // Google Cloud Platform
- FaaSInvokedProviderGCP = FaaSInvokedProviderKey.String("gcp")
- // Tencent Cloud
- FaaSInvokedProviderTencentCloud = FaaSInvokedProviderKey.String("tencent_cloud")
-)
-
-// FaaSInvokedName returns an attribute KeyValue conforming to the
-// "faas.invoked_name" semantic conventions. It represents the name of the
-// invoked function.
-func FaaSInvokedName(val string) attribute.KeyValue {
- return FaaSInvokedNameKey.String(val)
-}
-
-// FaaSInvokedRegion returns an attribute KeyValue conforming to the
-// "faas.invoked_region" semantic conventions. It represents the cloud region
-// of the invoked function.
-func FaaSInvokedRegion(val string) attribute.KeyValue {
- return FaaSInvokedRegionKey.String(val)
-}
-
-// Operations that access some remote service.
-const (
- // PeerServiceKey is the attribute Key conforming to the "peer.service"
- // semantic conventions. It represents the
- // [`service.name`](../../resource/semantic_conventions/README.md#service)
- // of the remote service. SHOULD be equal to the actual `service.name`
- // resource attribute of the remote service if any.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'AuthTokenCache'
- PeerServiceKey = attribute.Key("peer.service")
-)
-
-// PeerService returns an attribute KeyValue conforming to the
-// "peer.service" semantic conventions. It represents the
-// [`service.name`](../../resource/semantic_conventions/README.md#service) of
-// the remote service. SHOULD be equal to the actual `service.name` resource
-// attribute of the remote service if any.
-func PeerService(val string) attribute.KeyValue {
- return PeerServiceKey.String(val)
-}
-
-// These attributes may be used for any operation with an authenticated and/or
-// authorized enduser.
-const (
- // EnduserIDKey is the attribute Key conforming to the "enduser.id"
- // semantic conventions. It represents the username or client_id extracted
- // from the access token or
- // [Authorization](https://tools.ietf.org/html/rfc7235#section-4.2) header
- // in the inbound request from outside the system.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'username'
- EnduserIDKey = attribute.Key("enduser.id")
-
- // EnduserRoleKey is the attribute Key conforming to the "enduser.role"
- // semantic conventions. It represents the actual/assumed role the client
- // is making the request under extracted from token or application security
- // context.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'admin'
- EnduserRoleKey = attribute.Key("enduser.role")
-
- // EnduserScopeKey is the attribute Key conforming to the "enduser.scope"
- // semantic conventions. It represents the scopes or granted authorities
- // the client currently possesses extracted from token or application
- // security context. The value would come from the scope associated with an
- // [OAuth 2.0 Access
- // Token](https://tools.ietf.org/html/rfc6749#section-3.3) or an attribute
- // value in a [SAML 2.0
- // Assertion](http://docs.oasis-open.org/security/saml/Post2.0/sstc-saml-tech-overview-2.0.html).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'read:message, write:files'
- EnduserScopeKey = attribute.Key("enduser.scope")
-)
-
-// EnduserID returns an attribute KeyValue conforming to the "enduser.id"
-// semantic conventions. It represents the username or client_id extracted from
-// the access token or
-// [Authorization](https://tools.ietf.org/html/rfc7235#section-4.2) header in
-// the inbound request from outside the system.
-func EnduserID(val string) attribute.KeyValue {
- return EnduserIDKey.String(val)
-}
-
-// EnduserRole returns an attribute KeyValue conforming to the
-// "enduser.role" semantic conventions. It represents the actual/assumed role
-// the client is making the request under extracted from token or application
-// security context.
-func EnduserRole(val string) attribute.KeyValue {
- return EnduserRoleKey.String(val)
-}
-
-// EnduserScope returns an attribute KeyValue conforming to the
-// "enduser.scope" semantic conventions. It represents the scopes or granted
-// authorities the client currently possesses extracted from token or
-// application security context. The value would come from the scope associated
-// with an [OAuth 2.0 Access
-// Token](https://tools.ietf.org/html/rfc6749#section-3.3) or an attribute
-// value in a [SAML 2.0
-// Assertion](http://docs.oasis-open.org/security/saml/Post2.0/sstc-saml-tech-overview-2.0.html).
-func EnduserScope(val string) attribute.KeyValue {
- return EnduserScopeKey.String(val)
-}
-
-// These attributes may be used for any operation to store information about a
-// thread that started a span.
-const (
- // ThreadIDKey is the attribute Key conforming to the "thread.id" semantic
- // conventions. It represents the current "managed" thread ID (as opposed
- // to OS thread ID).
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 42
- ThreadIDKey = attribute.Key("thread.id")
-
- // ThreadNameKey is the attribute Key conforming to the "thread.name"
- // semantic conventions. It represents the current thread name.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'main'
- ThreadNameKey = attribute.Key("thread.name")
-)
-
-// ThreadID returns an attribute KeyValue conforming to the "thread.id"
-// semantic conventions. It represents the current "managed" thread ID (as
-// opposed to OS thread ID).
-func ThreadID(val int) attribute.KeyValue {
- return ThreadIDKey.Int(val)
-}
-
-// ThreadName returns an attribute KeyValue conforming to the "thread.name"
-// semantic conventions. It represents the current thread name.
-func ThreadName(val string) attribute.KeyValue {
- return ThreadNameKey.String(val)
-}
-
-// These attributes allow to report this unit of code and therefore to provide
-// more context about the span.
-const (
- // CodeFunctionKey is the attribute Key conforming to the "code.function"
- // semantic conventions. It represents the method or function name, or
- // equivalent (usually rightmost part of the code unit's name).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'serveRequest'
- CodeFunctionKey = attribute.Key("code.function")
-
- // CodeNamespaceKey is the attribute Key conforming to the "code.namespace"
- // semantic conventions. It represents the "namespace" within which
- // `code.function` is defined. Usually the qualified class or module name,
- // such that `code.namespace` + some separator + `code.function` form a
- // unique identifier for the code unit.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'com.example.MyHTTPService'
- CodeNamespaceKey = attribute.Key("code.namespace")
-
- // CodeFilepathKey is the attribute Key conforming to the "code.filepath"
- // semantic conventions. It represents the source code file name that
- // identifies the code unit as uniquely as possible (preferably an absolute
- // file path).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '/usr/local/MyApplication/content_root/app/index.php'
- CodeFilepathKey = attribute.Key("code.filepath")
-
- // CodeLineNumberKey is the attribute Key conforming to the "code.lineno"
- // semantic conventions. It represents the line number in `code.filepath`
- // best representing the operation. It SHOULD point within the code unit
- // named in `code.function`.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 42
- CodeLineNumberKey = attribute.Key("code.lineno")
-
- // CodeColumnKey is the attribute Key conforming to the "code.column"
- // semantic conventions. It represents the column number in `code.filepath`
- // best representing the operation. It SHOULD point within the code unit
- // named in `code.function`.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 16
- CodeColumnKey = attribute.Key("code.column")
-)
-
-// CodeFunction returns an attribute KeyValue conforming to the
-// "code.function" semantic conventions. It represents the method or function
-// name, or equivalent (usually rightmost part of the code unit's name).
-func CodeFunction(val string) attribute.KeyValue {
- return CodeFunctionKey.String(val)
-}
-
-// CodeNamespace returns an attribute KeyValue conforming to the
-// "code.namespace" semantic conventions. It represents the "namespace" within
-// which `code.function` is defined. Usually the qualified class or module
-// name, such that `code.namespace` + some separator + `code.function` form a
-// unique identifier for the code unit.
-func CodeNamespace(val string) attribute.KeyValue {
- return CodeNamespaceKey.String(val)
-}
-
-// CodeFilepath returns an attribute KeyValue conforming to the
-// "code.filepath" semantic conventions. It represents the source code file
-// name that identifies the code unit as uniquely as possible (preferably an
-// absolute file path).
-func CodeFilepath(val string) attribute.KeyValue {
- return CodeFilepathKey.String(val)
-}
-
-// CodeLineNumber returns an attribute KeyValue conforming to the "code.lineno"
-// semantic conventions. It represents the line number in `code.filepath` best
-// representing the operation. It SHOULD point within the code unit named in
-// `code.function`.
-func CodeLineNumber(val int) attribute.KeyValue {
- return CodeLineNumberKey.Int(val)
-}
-
-// CodeColumn returns an attribute KeyValue conforming to the "code.column"
-// semantic conventions. It represents the column number in `code.filepath`
-// best representing the operation. It SHOULD point within the code unit named
-// in `code.function`.
-func CodeColumn(val int) attribute.KeyValue {
- return CodeColumnKey.Int(val)
-}
-
-// Semantic Convention for HTTP Client
-const (
- // HTTPURLKey is the attribute Key conforming to the "http.url" semantic
- // conventions. It represents the full HTTP request URL in the form
- // `scheme://host[:port]/path?query[#fragment]`. Usually the fragment is
- // not transmitted over HTTP, but if it is known, it should be included
- // nevertheless.
- //
- // Type: string
- // RequirementLevel: Required
- // Stability: stable
- // Examples: 'https://www.foo.bar/search?q=OpenTelemetry#SemConv'
- // Note: `http.url` MUST NOT contain credentials passed via URL in form of
- // `https://username:password@www.example.com/`. In such case the
- // attribute's value should be `https://www.example.com/`.
- HTTPURLKey = attribute.Key("http.url")
-
- // HTTPResendCountKey is the attribute Key conforming to the
- // "http.resend_count" semantic conventions. It represents the ordinal
- // number of request resending attempt (for any reason, including
- // redirects).
- //
- // Type: int
- // RequirementLevel: Recommended (if and only if request was retried.)
- // Stability: stable
- // Examples: 3
- // Note: The resend count SHOULD be updated each time an HTTP request gets
- // resent by the client, regardless of what was the cause of the resending
- // (e.g. redirection, authorization failure, 503 Server Unavailable,
- // network issues, or any other).
- HTTPResendCountKey = attribute.Key("http.resend_count")
-)
-
-// HTTPURL returns an attribute KeyValue conforming to the "http.url"
-// semantic conventions. It represents the full HTTP request URL in the form
-// `scheme://host[:port]/path?query[#fragment]`. Usually the fragment is not
-// transmitted over HTTP, but if it is known, it should be included
-// nevertheless.
-func HTTPURL(val string) attribute.KeyValue {
- return HTTPURLKey.String(val)
-}
-
-// HTTPResendCount returns an attribute KeyValue conforming to the
-// "http.resend_count" semantic conventions. It represents the ordinal number
-// of request resending attempt (for any reason, including redirects).
-func HTTPResendCount(val int) attribute.KeyValue {
- return HTTPResendCountKey.Int(val)
-}
-
-// Semantic Convention for HTTP Server
-const (
- // HTTPTargetKey is the attribute Key conforming to the "http.target"
- // semantic conventions. It represents the full request target as passed in
- // a HTTP request line or equivalent.
- //
- // Type: string
- // RequirementLevel: Required
- // Stability: stable
- // Examples: '/users/12314/?q=ddds'
- HTTPTargetKey = attribute.Key("http.target")
-
- // HTTPClientIPKey is the attribute Key conforming to the "http.client_ip"
- // semantic conventions. It represents the IP address of the original
- // client behind all proxies, if known (e.g. from
- // [X-Forwarded-For](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Forwarded-For)).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '83.164.160.102'
- // Note: This is not necessarily the same as `net.sock.peer.addr`, which
- // would
- // identify the network-level peer, which may be a proxy.
- //
- // This attribute should be set when a source of information different
- // from the one used for `net.sock.peer.addr`, is available even if that
- // other
- // source just confirms the same value as `net.sock.peer.addr`.
- // Rationale: For `net.sock.peer.addr`, one typically does not know if it
- // comes from a proxy, reverse proxy, or the actual client. Setting
- // `http.client_ip` when it's the same as `net.sock.peer.addr` means that
- // one is at least somewhat confident that the address is not that of
- // the closest proxy.
- HTTPClientIPKey = attribute.Key("http.client_ip")
-)
-
-// HTTPTarget returns an attribute KeyValue conforming to the "http.target"
-// semantic conventions. It represents the full request target as passed in a
-// HTTP request line or equivalent.
-func HTTPTarget(val string) attribute.KeyValue {
- return HTTPTargetKey.String(val)
-}
-
-// HTTPClientIP returns an attribute KeyValue conforming to the
-// "http.client_ip" semantic conventions. It represents the IP address of the
-// original client behind all proxies, if known (e.g. from
-// [X-Forwarded-For](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Forwarded-For)).
-func HTTPClientIP(val string) attribute.KeyValue {
- return HTTPClientIPKey.String(val)
-}
-
-// The `aws` conventions apply to operations using the AWS SDK. They map
-// request or response parameters in AWS SDK API calls to attributes on a Span.
-// The conventions have been collected over time based on feedback from AWS
-// users of tracing and will continue to evolve as new interesting conventions
-// are found.
-// Some descriptions are also provided for populating general OpenTelemetry
-// semantic conventions based on these APIs.
-const (
- // AWSRequestIDKey is the attribute Key conforming to the "aws.request_id"
- // semantic conventions. It represents the AWS request ID as returned in
- // the response headers `x-amz-request-id` or `x-amz-requestid`.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '79b9da39-b7ae-508a-a6bc-864b2829c622', 'C9ER4AJX75574TDJ'
- AWSRequestIDKey = attribute.Key("aws.request_id")
-)
-
-// AWSRequestID returns an attribute KeyValue conforming to the
-// "aws.request_id" semantic conventions. It represents the AWS request ID as
-// returned in the response headers `x-amz-request-id` or `x-amz-requestid`.
-func AWSRequestID(val string) attribute.KeyValue {
- return AWSRequestIDKey.String(val)
-}
-
-// Attributes that exist for multiple DynamoDB request types.
-const (
- // AWSDynamoDBTableNamesKey is the attribute Key conforming to the
- // "aws.dynamodb.table_names" semantic conventions. It represents the keys
- // in the `RequestItems` object field.
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'Users', 'Cats'
- AWSDynamoDBTableNamesKey = attribute.Key("aws.dynamodb.table_names")
-
- // AWSDynamoDBConsumedCapacityKey is the attribute Key conforming to the
- // "aws.dynamodb.consumed_capacity" semantic conventions. It represents the
- // JSON-serialized value of each item in the `ConsumedCapacity` response
- // field.
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '{ "CapacityUnits": number, "GlobalSecondaryIndexes": {
- // "string" : { "CapacityUnits": number, "ReadCapacityUnits": number,
- // "WriteCapacityUnits": number } }, "LocalSecondaryIndexes": { "string" :
- // { "CapacityUnits": number, "ReadCapacityUnits": number,
- // "WriteCapacityUnits": number } }, "ReadCapacityUnits": number, "Table":
- // { "CapacityUnits": number, "ReadCapacityUnits": number,
- // "WriteCapacityUnits": number }, "TableName": "string",
- // "WriteCapacityUnits": number }'
- AWSDynamoDBConsumedCapacityKey = attribute.Key("aws.dynamodb.consumed_capacity")
-
- // AWSDynamoDBItemCollectionMetricsKey is the attribute Key conforming to
- // the "aws.dynamodb.item_collection_metrics" semantic conventions. It
- // represents the JSON-serialized value of the `ItemCollectionMetrics`
- // response field.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '{ "string" : [ { "ItemCollectionKey": { "string" : { "B":
- // blob, "BOOL": boolean, "BS": [ blob ], "L": [ "AttributeValue" ], "M": {
- // "string" : "AttributeValue" }, "N": "string", "NS": [ "string" ],
- // "NULL": boolean, "S": "string", "SS": [ "string" ] } },
- // "SizeEstimateRangeGB": [ number ] } ] }'
- AWSDynamoDBItemCollectionMetricsKey = attribute.Key("aws.dynamodb.item_collection_metrics")
-
- // AWSDynamoDBProvisionedReadCapacityKey is the attribute Key conforming to
- // the "aws.dynamodb.provisioned_read_capacity" semantic conventions. It
- // represents the value of the `ProvisionedThroughput.ReadCapacityUnits`
- // request parameter.
- //
- // Type: double
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 1.0, 2.0
- AWSDynamoDBProvisionedReadCapacityKey = attribute.Key("aws.dynamodb.provisioned_read_capacity")
-
- // AWSDynamoDBProvisionedWriteCapacityKey is the attribute Key conforming
- // to the "aws.dynamodb.provisioned_write_capacity" semantic conventions.
- // It represents the value of the
- // `ProvisionedThroughput.WriteCapacityUnits` request parameter.
- //
- // Type: double
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 1.0, 2.0
- AWSDynamoDBProvisionedWriteCapacityKey = attribute.Key("aws.dynamodb.provisioned_write_capacity")
-
- // AWSDynamoDBConsistentReadKey is the attribute Key conforming to the
- // "aws.dynamodb.consistent_read" semantic conventions. It represents the
- // value of the `ConsistentRead` request parameter.
- //
- // Type: boolean
- // RequirementLevel: Optional
- // Stability: stable
- AWSDynamoDBConsistentReadKey = attribute.Key("aws.dynamodb.consistent_read")
-
- // AWSDynamoDBProjectionKey is the attribute Key conforming to the
- // "aws.dynamodb.projection" semantic conventions. It represents the value
- // of the `ProjectionExpression` request parameter.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'Title', 'Title, Price, Color', 'Title, Description,
- // RelatedItems, ProductReviews'
- AWSDynamoDBProjectionKey = attribute.Key("aws.dynamodb.projection")
-
- // AWSDynamoDBLimitKey is the attribute Key conforming to the
- // "aws.dynamodb.limit" semantic conventions. It represents the value of
- // the `Limit` request parameter.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 10
- AWSDynamoDBLimitKey = attribute.Key("aws.dynamodb.limit")
-
- // AWSDynamoDBAttributesToGetKey is the attribute Key conforming to the
- // "aws.dynamodb.attributes_to_get" semantic conventions. It represents the
- // value of the `AttributesToGet` request parameter.
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'lives', 'id'
- AWSDynamoDBAttributesToGetKey = attribute.Key("aws.dynamodb.attributes_to_get")
-
- // AWSDynamoDBIndexNameKey is the attribute Key conforming to the
- // "aws.dynamodb.index_name" semantic conventions. It represents the value
- // of the `IndexName` request parameter.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'name_to_group'
- AWSDynamoDBIndexNameKey = attribute.Key("aws.dynamodb.index_name")
-
- // AWSDynamoDBSelectKey is the attribute Key conforming to the
- // "aws.dynamodb.select" semantic conventions. It represents the value of
- // the `Select` request parameter.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'ALL_ATTRIBUTES', 'COUNT'
- AWSDynamoDBSelectKey = attribute.Key("aws.dynamodb.select")
-)
-
-// AWSDynamoDBTableNames returns an attribute KeyValue conforming to the
-// "aws.dynamodb.table_names" semantic conventions. It represents the keys in
-// the `RequestItems` object field.
-func AWSDynamoDBTableNames(val ...string) attribute.KeyValue {
- return AWSDynamoDBTableNamesKey.StringSlice(val)
-}
-
-// AWSDynamoDBConsumedCapacity returns an attribute KeyValue conforming to
-// the "aws.dynamodb.consumed_capacity" semantic conventions. It represents the
-// JSON-serialized value of each item in the `ConsumedCapacity` response field.
-func AWSDynamoDBConsumedCapacity(val ...string) attribute.KeyValue {
- return AWSDynamoDBConsumedCapacityKey.StringSlice(val)
-}
-
-// AWSDynamoDBItemCollectionMetrics returns an attribute KeyValue conforming
-// to the "aws.dynamodb.item_collection_metrics" semantic conventions. It
-// represents the JSON-serialized value of the `ItemCollectionMetrics` response
-// field.
-func AWSDynamoDBItemCollectionMetrics(val string) attribute.KeyValue {
- return AWSDynamoDBItemCollectionMetricsKey.String(val)
-}
-
-// AWSDynamoDBProvisionedReadCapacity returns an attribute KeyValue
-// conforming to the "aws.dynamodb.provisioned_read_capacity" semantic
-// conventions. It represents the value of the
-// `ProvisionedThroughput.ReadCapacityUnits` request parameter.
-func AWSDynamoDBProvisionedReadCapacity(val float64) attribute.KeyValue {
- return AWSDynamoDBProvisionedReadCapacityKey.Float64(val)
-}
-
-// AWSDynamoDBProvisionedWriteCapacity returns an attribute KeyValue
-// conforming to the "aws.dynamodb.provisioned_write_capacity" semantic
-// conventions. It represents the value of the
-// `ProvisionedThroughput.WriteCapacityUnits` request parameter.
-func AWSDynamoDBProvisionedWriteCapacity(val float64) attribute.KeyValue {
- return AWSDynamoDBProvisionedWriteCapacityKey.Float64(val)
-}
-
-// AWSDynamoDBConsistentRead returns an attribute KeyValue conforming to the
-// "aws.dynamodb.consistent_read" semantic conventions. It represents the value
-// of the `ConsistentRead` request parameter.
-func AWSDynamoDBConsistentRead(val bool) attribute.KeyValue {
- return AWSDynamoDBConsistentReadKey.Bool(val)
-}
-
-// AWSDynamoDBProjection returns an attribute KeyValue conforming to the
-// "aws.dynamodb.projection" semantic conventions. It represents the value of
-// the `ProjectionExpression` request parameter.
-func AWSDynamoDBProjection(val string) attribute.KeyValue {
- return AWSDynamoDBProjectionKey.String(val)
-}
-
-// AWSDynamoDBLimit returns an attribute KeyValue conforming to the
-// "aws.dynamodb.limit" semantic conventions. It represents the value of the
-// `Limit` request parameter.
-func AWSDynamoDBLimit(val int) attribute.KeyValue {
- return AWSDynamoDBLimitKey.Int(val)
-}
-
-// AWSDynamoDBAttributesToGet returns an attribute KeyValue conforming to
-// the "aws.dynamodb.attributes_to_get" semantic conventions. It represents the
-// value of the `AttributesToGet` request parameter.
-func AWSDynamoDBAttributesToGet(val ...string) attribute.KeyValue {
- return AWSDynamoDBAttributesToGetKey.StringSlice(val)
-}
-
-// AWSDynamoDBIndexName returns an attribute KeyValue conforming to the
-// "aws.dynamodb.index_name" semantic conventions. It represents the value of
-// the `IndexName` request parameter.
-func AWSDynamoDBIndexName(val string) attribute.KeyValue {
- return AWSDynamoDBIndexNameKey.String(val)
-}
-
-// AWSDynamoDBSelect returns an attribute KeyValue conforming to the
-// "aws.dynamodb.select" semantic conventions. It represents the value of the
-// `Select` request parameter.
-func AWSDynamoDBSelect(val string) attribute.KeyValue {
- return AWSDynamoDBSelectKey.String(val)
-}
-
-// DynamoDB.CreateTable
-const (
- // AWSDynamoDBGlobalSecondaryIndexesKey is the attribute Key conforming to
- // the "aws.dynamodb.global_secondary_indexes" semantic conventions. It
- // represents the JSON-serialized value of each item of the
- // `GlobalSecondaryIndexes` request field
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '{ "IndexName": "string", "KeySchema": [ { "AttributeName":
- // "string", "KeyType": "string" } ], "Projection": { "NonKeyAttributes": [
- // "string" ], "ProjectionType": "string" }, "ProvisionedThroughput": {
- // "ReadCapacityUnits": number, "WriteCapacityUnits": number } }'
- AWSDynamoDBGlobalSecondaryIndexesKey = attribute.Key("aws.dynamodb.global_secondary_indexes")
-
- // AWSDynamoDBLocalSecondaryIndexesKey is the attribute Key conforming to
- // the "aws.dynamodb.local_secondary_indexes" semantic conventions. It
- // represents the JSON-serialized value of each item of the
- // `LocalSecondaryIndexes` request field.
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '{ "IndexARN": "string", "IndexName": "string",
- // "IndexSizeBytes": number, "ItemCount": number, "KeySchema": [ {
- // "AttributeName": "string", "KeyType": "string" } ], "Projection": {
- // "NonKeyAttributes": [ "string" ], "ProjectionType": "string" } }'
- AWSDynamoDBLocalSecondaryIndexesKey = attribute.Key("aws.dynamodb.local_secondary_indexes")
-)
-
-// AWSDynamoDBGlobalSecondaryIndexes returns an attribute KeyValue
-// conforming to the "aws.dynamodb.global_secondary_indexes" semantic
-// conventions. It represents the JSON-serialized value of each item of the
-// `GlobalSecondaryIndexes` request field
-func AWSDynamoDBGlobalSecondaryIndexes(val ...string) attribute.KeyValue {
- return AWSDynamoDBGlobalSecondaryIndexesKey.StringSlice(val)
-}
-
-// AWSDynamoDBLocalSecondaryIndexes returns an attribute KeyValue conforming
-// to the "aws.dynamodb.local_secondary_indexes" semantic conventions. It
-// represents the JSON-serialized value of each item of the
-// `LocalSecondaryIndexes` request field.
-func AWSDynamoDBLocalSecondaryIndexes(val ...string) attribute.KeyValue {
- return AWSDynamoDBLocalSecondaryIndexesKey.StringSlice(val)
-}
-
-// DynamoDB.ListTables
-const (
- // AWSDynamoDBExclusiveStartTableKey is the attribute Key conforming to the
- // "aws.dynamodb.exclusive_start_table" semantic conventions. It represents
- // the value of the `ExclusiveStartTableName` request parameter.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'Users', 'CatsTable'
- AWSDynamoDBExclusiveStartTableKey = attribute.Key("aws.dynamodb.exclusive_start_table")
-
- // AWSDynamoDBTableCountKey is the attribute Key conforming to the
- // "aws.dynamodb.table_count" semantic conventions. It represents the the
- // number of items in the `TableNames` response parameter.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 20
- AWSDynamoDBTableCountKey = attribute.Key("aws.dynamodb.table_count")
-)
-
-// AWSDynamoDBExclusiveStartTable returns an attribute KeyValue conforming
-// to the "aws.dynamodb.exclusive_start_table" semantic conventions. It
-// represents the value of the `ExclusiveStartTableName` request parameter.
-func AWSDynamoDBExclusiveStartTable(val string) attribute.KeyValue {
- return AWSDynamoDBExclusiveStartTableKey.String(val)
-}
-
-// AWSDynamoDBTableCount returns an attribute KeyValue conforming to the
-// "aws.dynamodb.table_count" semantic conventions. It represents the the
-// number of items in the `TableNames` response parameter.
-func AWSDynamoDBTableCount(val int) attribute.KeyValue {
- return AWSDynamoDBTableCountKey.Int(val)
-}
-
-// DynamoDB.Query
-const (
- // AWSDynamoDBScanForwardKey is the attribute Key conforming to the
- // "aws.dynamodb.scan_forward" semantic conventions. It represents the
- // value of the `ScanIndexForward` request parameter.
- //
- // Type: boolean
- // RequirementLevel: Optional
- // Stability: stable
- AWSDynamoDBScanForwardKey = attribute.Key("aws.dynamodb.scan_forward")
-)
-
-// AWSDynamoDBScanForward returns an attribute KeyValue conforming to the
-// "aws.dynamodb.scan_forward" semantic conventions. It represents the value of
-// the `ScanIndexForward` request parameter.
-func AWSDynamoDBScanForward(val bool) attribute.KeyValue {
- return AWSDynamoDBScanForwardKey.Bool(val)
-}
-
-// DynamoDB.Scan
-const (
- // AWSDynamoDBSegmentKey is the attribute Key conforming to the
- // "aws.dynamodb.segment" semantic conventions. It represents the value of
- // the `Segment` request parameter.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 10
- AWSDynamoDBSegmentKey = attribute.Key("aws.dynamodb.segment")
-
- // AWSDynamoDBTotalSegmentsKey is the attribute Key conforming to the
- // "aws.dynamodb.total_segments" semantic conventions. It represents the
- // value of the `TotalSegments` request parameter.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 100
- AWSDynamoDBTotalSegmentsKey = attribute.Key("aws.dynamodb.total_segments")
-
- // AWSDynamoDBCountKey is the attribute Key conforming to the
- // "aws.dynamodb.count" semantic conventions. It represents the value of
- // the `Count` response parameter.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 10
- AWSDynamoDBCountKey = attribute.Key("aws.dynamodb.count")
-
- // AWSDynamoDBScannedCountKey is the attribute Key conforming to the
- // "aws.dynamodb.scanned_count" semantic conventions. It represents the
- // value of the `ScannedCount` response parameter.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 50
- AWSDynamoDBScannedCountKey = attribute.Key("aws.dynamodb.scanned_count")
-)
-
-// AWSDynamoDBSegment returns an attribute KeyValue conforming to the
-// "aws.dynamodb.segment" semantic conventions. It represents the value of the
-// `Segment` request parameter.
-func AWSDynamoDBSegment(val int) attribute.KeyValue {
- return AWSDynamoDBSegmentKey.Int(val)
-}
-
-// AWSDynamoDBTotalSegments returns an attribute KeyValue conforming to the
-// "aws.dynamodb.total_segments" semantic conventions. It represents the value
-// of the `TotalSegments` request parameter.
-func AWSDynamoDBTotalSegments(val int) attribute.KeyValue {
- return AWSDynamoDBTotalSegmentsKey.Int(val)
-}
-
-// AWSDynamoDBCount returns an attribute KeyValue conforming to the
-// "aws.dynamodb.count" semantic conventions. It represents the value of the
-// `Count` response parameter.
-func AWSDynamoDBCount(val int) attribute.KeyValue {
- return AWSDynamoDBCountKey.Int(val)
-}
-
-// AWSDynamoDBScannedCount returns an attribute KeyValue conforming to the
-// "aws.dynamodb.scanned_count" semantic conventions. It represents the value
-// of the `ScannedCount` response parameter.
-func AWSDynamoDBScannedCount(val int) attribute.KeyValue {
- return AWSDynamoDBScannedCountKey.Int(val)
-}
-
-// DynamoDB.UpdateTable
-const (
- // AWSDynamoDBAttributeDefinitionsKey is the attribute Key conforming to
- // the "aws.dynamodb.attribute_definitions" semantic conventions. It
- // represents the JSON-serialized value of each item in the
- // `AttributeDefinitions` request field.
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '{ "AttributeName": "string", "AttributeType": "string" }'
- AWSDynamoDBAttributeDefinitionsKey = attribute.Key("aws.dynamodb.attribute_definitions")
-
- // AWSDynamoDBGlobalSecondaryIndexUpdatesKey is the attribute Key
- // conforming to the "aws.dynamodb.global_secondary_index_updates" semantic
- // conventions. It represents the JSON-serialized value of each item in the
- // the `GlobalSecondaryIndexUpdates` request field.
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '{ "Create": { "IndexName": "string", "KeySchema": [ {
- // "AttributeName": "string", "KeyType": "string" } ], "Projection": {
- // "NonKeyAttributes": [ "string" ], "ProjectionType": "string" },
- // "ProvisionedThroughput": { "ReadCapacityUnits": number,
- // "WriteCapacityUnits": number } }'
- AWSDynamoDBGlobalSecondaryIndexUpdatesKey = attribute.Key("aws.dynamodb.global_secondary_index_updates")
-)
-
-// AWSDynamoDBAttributeDefinitions returns an attribute KeyValue conforming
-// to the "aws.dynamodb.attribute_definitions" semantic conventions. It
-// represents the JSON-serialized value of each item in the
-// `AttributeDefinitions` request field.
-func AWSDynamoDBAttributeDefinitions(val ...string) attribute.KeyValue {
- return AWSDynamoDBAttributeDefinitionsKey.StringSlice(val)
-}
-
-// AWSDynamoDBGlobalSecondaryIndexUpdates returns an attribute KeyValue
-// conforming to the "aws.dynamodb.global_secondary_index_updates" semantic
-// conventions. It represents the JSON-serialized value of each item in the the
-// `GlobalSecondaryIndexUpdates` request field.
-func AWSDynamoDBGlobalSecondaryIndexUpdates(val ...string) attribute.KeyValue {
- return AWSDynamoDBGlobalSecondaryIndexUpdatesKey.StringSlice(val)
-}
-
-// Attributes that exist for S3 request types.
-const (
- // AWSS3BucketKey is the attribute Key conforming to the "aws.s3.bucket"
- // semantic conventions. It represents the S3 bucket name the request
- // refers to. Corresponds to the `--bucket` parameter of the [S3
- // API](https://docs.aws.amazon.com/cli/latest/reference/s3api/index.html)
- // operations.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'some-bucket-name'
- // Note: The `bucket` attribute is applicable to all S3 operations that
- // reference a bucket, i.e. that require the bucket name as a mandatory
- // parameter.
- // This applies to almost all S3 operations except `list-buckets`.
- AWSS3BucketKey = attribute.Key("aws.s3.bucket")
-
- // AWSS3KeyKey is the attribute Key conforming to the "aws.s3.key" semantic
- // conventions. It represents the S3 object key the request refers to.
- // Corresponds to the `--key` parameter of the [S3
- // API](https://docs.aws.amazon.com/cli/latest/reference/s3api/index.html)
- // operations.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'someFile.yml'
- // Note: The `key` attribute is applicable to all object-related S3
- // operations, i.e. that require the object key as a mandatory parameter.
- // This applies in particular to the following operations:
- //
- // -
- // [copy-object](https://docs.aws.amazon.com/cli/latest/reference/s3api/copy-object.html)
- // -
- // [delete-object](https://docs.aws.amazon.com/cli/latest/reference/s3api/delete-object.html)
- // -
- // [get-object](https://docs.aws.amazon.com/cli/latest/reference/s3api/get-object.html)
- // -
- // [head-object](https://docs.aws.amazon.com/cli/latest/reference/s3api/head-object.html)
- // -
- // [put-object](https://docs.aws.amazon.com/cli/latest/reference/s3api/put-object.html)
- // -
- // [restore-object](https://docs.aws.amazon.com/cli/latest/reference/s3api/restore-object.html)
- // -
- // [select-object-content](https://docs.aws.amazon.com/cli/latest/reference/s3api/select-object-content.html)
- // -
- // [abort-multipart-upload](https://docs.aws.amazon.com/cli/latest/reference/s3api/abort-multipart-upload.html)
- // -
- // [complete-multipart-upload](https://docs.aws.amazon.com/cli/latest/reference/s3api/complete-multipart-upload.html)
- // -
- // [create-multipart-upload](https://docs.aws.amazon.com/cli/latest/reference/s3api/create-multipart-upload.html)
- // -
- // [list-parts](https://docs.aws.amazon.com/cli/latest/reference/s3api/list-parts.html)
- // -
- // [upload-part](https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part.html)
- // -
- // [upload-part-copy](https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part-copy.html)
- AWSS3KeyKey = attribute.Key("aws.s3.key")
-
- // AWSS3CopySourceKey is the attribute Key conforming to the
- // "aws.s3.copy_source" semantic conventions. It represents the source
- // object (in the form `bucket`/`key`) for the copy operation.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'someFile.yml'
- // Note: The `copy_source` attribute applies to S3 copy operations and
- // corresponds to the `--copy-source` parameter
- // of the [copy-object operation within the S3
- // API](https://docs.aws.amazon.com/cli/latest/reference/s3api/copy-object.html).
- // This applies in particular to the following operations:
- //
- // -
- // [copy-object](https://docs.aws.amazon.com/cli/latest/reference/s3api/copy-object.html)
- // -
- // [upload-part-copy](https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part-copy.html)
- AWSS3CopySourceKey = attribute.Key("aws.s3.copy_source")
-
- // AWSS3UploadIDKey is the attribute Key conforming to the
- // "aws.s3.upload_id" semantic conventions. It represents the upload ID
- // that identifies the multipart upload.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'dfRtDYWFbkRONycy.Yxwh66Yjlx.cph0gtNBtJ'
- // Note: The `upload_id` attribute applies to S3 multipart-upload
- // operations and corresponds to the `--upload-id` parameter
- // of the [S3
- // API](https://docs.aws.amazon.com/cli/latest/reference/s3api/index.html)
- // multipart operations.
- // This applies in particular to the following operations:
- //
- // -
- // [abort-multipart-upload](https://docs.aws.amazon.com/cli/latest/reference/s3api/abort-multipart-upload.html)
- // -
- // [complete-multipart-upload](https://docs.aws.amazon.com/cli/latest/reference/s3api/complete-multipart-upload.html)
- // -
- // [list-parts](https://docs.aws.amazon.com/cli/latest/reference/s3api/list-parts.html)
- // -
- // [upload-part](https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part.html)
- // -
- // [upload-part-copy](https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part-copy.html)
- AWSS3UploadIDKey = attribute.Key("aws.s3.upload_id")
-
- // AWSS3DeleteKey is the attribute Key conforming to the "aws.s3.delete"
- // semantic conventions. It represents the delete request container that
- // specifies the objects to be deleted.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples:
- // 'Objects=[{Key=string,VersionID=string},{Key=string,VersionID=string}],Quiet=boolean'
- // Note: The `delete` attribute is only applicable to the
- // [delete-object](https://docs.aws.amazon.com/cli/latest/reference/s3api/delete-object.html)
- // operation.
- // The `delete` attribute corresponds to the `--delete` parameter of the
- // [delete-objects operation within the S3
- // API](https://docs.aws.amazon.com/cli/latest/reference/s3api/delete-objects.html).
- AWSS3DeleteKey = attribute.Key("aws.s3.delete")
-
- // AWSS3PartNumberKey is the attribute Key conforming to the
- // "aws.s3.part_number" semantic conventions. It represents the part number
- // of the part being uploaded in a multipart-upload operation. This is a
- // positive integer between 1 and 10,000.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 3456
- // Note: The `part_number` attribute is only applicable to the
- // [upload-part](https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part.html)
- // and
- // [upload-part-copy](https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part-copy.html)
- // operations.
- // The `part_number` attribute corresponds to the `--part-number` parameter
- // of the
- // [upload-part operation within the S3
- // API](https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part.html).
- AWSS3PartNumberKey = attribute.Key("aws.s3.part_number")
-)
-
-// AWSS3Bucket returns an attribute KeyValue conforming to the
-// "aws.s3.bucket" semantic conventions. It represents the S3 bucket name the
-// request refers to. Corresponds to the `--bucket` parameter of the [S3
-// API](https://docs.aws.amazon.com/cli/latest/reference/s3api/index.html)
-// operations.
-func AWSS3Bucket(val string) attribute.KeyValue {
- return AWSS3BucketKey.String(val)
-}
-
-// AWSS3Key returns an attribute KeyValue conforming to the "aws.s3.key"
-// semantic conventions. It represents the S3 object key the request refers to.
-// Corresponds to the `--key` parameter of the [S3
-// API](https://docs.aws.amazon.com/cli/latest/reference/s3api/index.html)
-// operations.
-func AWSS3Key(val string) attribute.KeyValue {
- return AWSS3KeyKey.String(val)
-}
-
-// AWSS3CopySource returns an attribute KeyValue conforming to the
-// "aws.s3.copy_source" semantic conventions. It represents the source object
-// (in the form `bucket`/`key`) for the copy operation.
-func AWSS3CopySource(val string) attribute.KeyValue {
- return AWSS3CopySourceKey.String(val)
-}
-
-// AWSS3UploadID returns an attribute KeyValue conforming to the
-// "aws.s3.upload_id" semantic conventions. It represents the upload ID that
-// identifies the multipart upload.
-func AWSS3UploadID(val string) attribute.KeyValue {
- return AWSS3UploadIDKey.String(val)
-}
-
-// AWSS3Delete returns an attribute KeyValue conforming to the
-// "aws.s3.delete" semantic conventions. It represents the delete request
-// container that specifies the objects to be deleted.
-func AWSS3Delete(val string) attribute.KeyValue {
- return AWSS3DeleteKey.String(val)
-}
-
-// AWSS3PartNumber returns an attribute KeyValue conforming to the
-// "aws.s3.part_number" semantic conventions. It represents the part number of
-// the part being uploaded in a multipart-upload operation. This is a positive
-// integer between 1 and 10,000.
-func AWSS3PartNumber(val int) attribute.KeyValue {
- return AWSS3PartNumberKey.Int(val)
-}
-
-// Semantic conventions to apply when instrumenting the GraphQL implementation.
-// They map GraphQL operations to attributes on a Span.
-const (
- // GraphqlOperationNameKey is the attribute Key conforming to the
- // "graphql.operation.name" semantic conventions. It represents the name of
- // the operation being executed.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'findBookByID'
- GraphqlOperationNameKey = attribute.Key("graphql.operation.name")
-
- // GraphqlOperationTypeKey is the attribute Key conforming to the
- // "graphql.operation.type" semantic conventions. It represents the type of
- // the operation being executed.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'query', 'mutation', 'subscription'
- GraphqlOperationTypeKey = attribute.Key("graphql.operation.type")
-
- // GraphqlDocumentKey is the attribute Key conforming to the
- // "graphql.document" semantic conventions. It represents the GraphQL
- // document being executed.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'query findBookByID { bookByID(id: ?) { name } }'
- // Note: The value may be sanitized to exclude sensitive information.
- GraphqlDocumentKey = attribute.Key("graphql.document")
-)
-
-var (
- // GraphQL query
- GraphqlOperationTypeQuery = GraphqlOperationTypeKey.String("query")
- // GraphQL mutation
- GraphqlOperationTypeMutation = GraphqlOperationTypeKey.String("mutation")
- // GraphQL subscription
- GraphqlOperationTypeSubscription = GraphqlOperationTypeKey.String("subscription")
-)
-
-// GraphqlOperationName returns an attribute KeyValue conforming to the
-// "graphql.operation.name" semantic conventions. It represents the name of the
-// operation being executed.
-func GraphqlOperationName(val string) attribute.KeyValue {
- return GraphqlOperationNameKey.String(val)
-}
-
-// GraphqlDocument returns an attribute KeyValue conforming to the
-// "graphql.document" semantic conventions. It represents the GraphQL document
-// being executed.
-func GraphqlDocument(val string) attribute.KeyValue {
- return GraphqlDocumentKey.String(val)
-}
-
-// General attributes used in messaging systems.
-const (
- // MessagingSystemKey is the attribute Key conforming to the
- // "messaging.system" semantic conventions. It represents a string
- // identifying the messaging system.
- //
- // Type: string
- // RequirementLevel: Required
- // Stability: stable
- // Examples: 'kafka', 'rabbitmq', 'rocketmq', 'activemq', 'AmazonSQS'
- MessagingSystemKey = attribute.Key("messaging.system")
-
- // MessagingOperationKey is the attribute Key conforming to the
- // "messaging.operation" semantic conventions. It represents a string
- // identifying the kind of messaging operation as defined in the [Operation
- // names](#operation-names) section above.
- //
- // Type: Enum
- // RequirementLevel: Required
- // Stability: stable
- // Note: If a custom value is used, it MUST be of low cardinality.
- MessagingOperationKey = attribute.Key("messaging.operation")
-
- // MessagingBatchMessageCountKey is the attribute Key conforming to the
- // "messaging.batch.message_count" semantic conventions. It represents the
- // number of messages sent, received, or processed in the scope of the
- // batching operation.
- //
- // Type: int
- // RequirementLevel: ConditionallyRequired (If the span describes an
- // operation on a batch of messages.)
- // Stability: stable
- // Examples: 0, 1, 2
- // Note: Instrumentations SHOULD NOT set `messaging.batch.message_count` on
- // spans that operate with a single message. When a messaging client
- // library supports both batch and single-message API for the same
- // operation, instrumentations SHOULD use `messaging.batch.message_count`
- // for batching APIs and SHOULD NOT use it for single-message APIs.
- MessagingBatchMessageCountKey = attribute.Key("messaging.batch.message_count")
-)
-
-var (
- // publish
- MessagingOperationPublish = MessagingOperationKey.String("publish")
- // receive
- MessagingOperationReceive = MessagingOperationKey.String("receive")
- // process
- MessagingOperationProcess = MessagingOperationKey.String("process")
-)
-
-// MessagingSystem returns an attribute KeyValue conforming to the
-// "messaging.system" semantic conventions. It represents a string identifying
-// the messaging system.
-func MessagingSystem(val string) attribute.KeyValue {
- return MessagingSystemKey.String(val)
-}
-
-// MessagingBatchMessageCount returns an attribute KeyValue conforming to
-// the "messaging.batch.message_count" semantic conventions. It represents the
-// number of messages sent, received, or processed in the scope of the batching
-// operation.
-func MessagingBatchMessageCount(val int) attribute.KeyValue {
- return MessagingBatchMessageCountKey.Int(val)
-}
-
-// Semantic convention for a consumer of messages received from a messaging
-// system
-const (
- // MessagingConsumerIDKey is the attribute Key conforming to the
- // "messaging.consumer.id" semantic conventions. It represents the
- // identifier for the consumer receiving a message. For Kafka, set it to
- // `{messaging.kafka.consumer.group} - {messaging.kafka.client_id}`, if
- // both are present, or only `messaging.kafka.consumer.group`. For brokers,
- // such as RabbitMQ and Artemis, set it to the `client_id` of the client
- // consuming the message.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'mygroup - client-6'
- MessagingConsumerIDKey = attribute.Key("messaging.consumer.id")
-)
-
-// MessagingConsumerID returns an attribute KeyValue conforming to the
-// "messaging.consumer.id" semantic conventions. It represents the identifier
-// for the consumer receiving a message. For Kafka, set it to
-// `{messaging.kafka.consumer.group} - {messaging.kafka.client_id}`, if both
-// are present, or only `messaging.kafka.consumer.group`. For brokers, such as
-// RabbitMQ and Artemis, set it to the `client_id` of the client consuming the
-// message.
-func MessagingConsumerID(val string) attribute.KeyValue {
- return MessagingConsumerIDKey.String(val)
-}
-
-// Semantic conventions for remote procedure calls.
-const (
- // RPCSystemKey is the attribute Key conforming to the "rpc.system"
- // semantic conventions. It represents a string identifying the remoting
- // system. See below for a list of well-known identifiers.
- //
- // Type: Enum
- // RequirementLevel: Required
- // Stability: stable
- RPCSystemKey = attribute.Key("rpc.system")
-
- // RPCServiceKey is the attribute Key conforming to the "rpc.service"
- // semantic conventions. It represents the full (logical) name of the
- // service being called, including its package name, if applicable.
- //
- // Type: string
- // RequirementLevel: Recommended
- // Stability: stable
- // Examples: 'myservice.EchoService'
- // Note: This is the logical name of the service from the RPC interface
- // perspective, which can be different from the name of any implementing
- // class. The `code.namespace` attribute may be used to store the latter
- // (despite the attribute name, it may include a class name; e.g., class
- // with method actually executing the call on the server side, RPC client
- // stub class on the client side).
- RPCServiceKey = attribute.Key("rpc.service")
-
- // RPCMethodKey is the attribute Key conforming to the "rpc.method"
- // semantic conventions. It represents the name of the (logical) method
- // being called, must be equal to the $method part in the span name.
- //
- // Type: string
- // RequirementLevel: Recommended
- // Stability: stable
- // Examples: 'exampleMethod'
- // Note: This is the logical name of the method from the RPC interface
- // perspective, which can be different from the name of any implementing
- // method/function. The `code.function` attribute may be used to store the
- // latter (e.g., method actually executing the call on the server side, RPC
- // client stub method on the client side).
- RPCMethodKey = attribute.Key("rpc.method")
-)
-
-var (
- // gRPC
- RPCSystemGRPC = RPCSystemKey.String("grpc")
- // Java RMI
- RPCSystemJavaRmi = RPCSystemKey.String("java_rmi")
- // .NET WCF
- RPCSystemDotnetWcf = RPCSystemKey.String("dotnet_wcf")
- // Apache Dubbo
- RPCSystemApacheDubbo = RPCSystemKey.String("apache_dubbo")
- // Connect RPC
- RPCSystemConnectRPC = RPCSystemKey.String("connect_rpc")
-)
-
-// RPCService returns an attribute KeyValue conforming to the "rpc.service"
-// semantic conventions. It represents the full (logical) name of the service
-// being called, including its package name, if applicable.
-func RPCService(val string) attribute.KeyValue {
- return RPCServiceKey.String(val)
-}
-
-// RPCMethod returns an attribute KeyValue conforming to the "rpc.method"
-// semantic conventions. It represents the name of the (logical) method being
-// called, must be equal to the $method part in the span name.
-func RPCMethod(val string) attribute.KeyValue {
- return RPCMethodKey.String(val)
-}
-
-// Tech-specific attributes for gRPC.
-const (
- // RPCGRPCStatusCodeKey is the attribute Key conforming to the
- // "rpc.grpc.status_code" semantic conventions. It represents the [numeric
- // status
- // code](https://github.com/grpc/grpc/blob/v1.33.2/doc/statuscodes.md) of
- // the gRPC request.
- //
- // Type: Enum
- // RequirementLevel: Required
- // Stability: stable
- RPCGRPCStatusCodeKey = attribute.Key("rpc.grpc.status_code")
-)
-
-var (
- // OK
- RPCGRPCStatusCodeOk = RPCGRPCStatusCodeKey.Int(0)
- // CANCELLED
- RPCGRPCStatusCodeCancelled = RPCGRPCStatusCodeKey.Int(1)
- // UNKNOWN
- RPCGRPCStatusCodeUnknown = RPCGRPCStatusCodeKey.Int(2)
- // INVALID_ARGUMENT
- RPCGRPCStatusCodeInvalidArgument = RPCGRPCStatusCodeKey.Int(3)
- // DEADLINE_EXCEEDED
- RPCGRPCStatusCodeDeadlineExceeded = RPCGRPCStatusCodeKey.Int(4)
- // NOT_FOUND
- RPCGRPCStatusCodeNotFound = RPCGRPCStatusCodeKey.Int(5)
- // ALREADY_EXISTS
- RPCGRPCStatusCodeAlreadyExists = RPCGRPCStatusCodeKey.Int(6)
- // PERMISSION_DENIED
- RPCGRPCStatusCodePermissionDenied = RPCGRPCStatusCodeKey.Int(7)
- // RESOURCE_EXHAUSTED
- RPCGRPCStatusCodeResourceExhausted = RPCGRPCStatusCodeKey.Int(8)
- // FAILED_PRECONDITION
- RPCGRPCStatusCodeFailedPrecondition = RPCGRPCStatusCodeKey.Int(9)
- // ABORTED
- RPCGRPCStatusCodeAborted = RPCGRPCStatusCodeKey.Int(10)
- // OUT_OF_RANGE
- RPCGRPCStatusCodeOutOfRange = RPCGRPCStatusCodeKey.Int(11)
- // UNIMPLEMENTED
- RPCGRPCStatusCodeUnimplemented = RPCGRPCStatusCodeKey.Int(12)
- // INTERNAL
- RPCGRPCStatusCodeInternal = RPCGRPCStatusCodeKey.Int(13)
- // UNAVAILABLE
- RPCGRPCStatusCodeUnavailable = RPCGRPCStatusCodeKey.Int(14)
- // DATA_LOSS
- RPCGRPCStatusCodeDataLoss = RPCGRPCStatusCodeKey.Int(15)
- // UNAUTHENTICATED
- RPCGRPCStatusCodeUnauthenticated = RPCGRPCStatusCodeKey.Int(16)
-)
-
-// Tech-specific attributes for [JSON RPC](https://www.jsonrpc.org/).
-const (
- // RPCJsonrpcVersionKey is the attribute Key conforming to the
- // "rpc.jsonrpc.version" semantic conventions. It represents the protocol
- // version as in `jsonrpc` property of request/response. Since JSON-RPC 1.0
- // does not specify this, the value can be omitted.
- //
- // Type: string
- // RequirementLevel: ConditionallyRequired (If other than the default
- // version (`1.0`))
- // Stability: stable
- // Examples: '2.0', '1.0'
- RPCJsonrpcVersionKey = attribute.Key("rpc.jsonrpc.version")
-
- // RPCJsonrpcRequestIDKey is the attribute Key conforming to the
- // "rpc.jsonrpc.request_id" semantic conventions. It represents the `id`
- // property of request or response. Since protocol allows id to be int,
- // string, `null` or missing (for notifications), value is expected to be
- // cast to string for simplicity. Use empty string in case of `null` value.
- // Omit entirely if this is a notification.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '10', 'request-7', ''
- RPCJsonrpcRequestIDKey = attribute.Key("rpc.jsonrpc.request_id")
-
- // RPCJsonrpcErrorCodeKey is the attribute Key conforming to the
- // "rpc.jsonrpc.error_code" semantic conventions. It represents the
- // `error.code` property of response if it is an error response.
- //
- // Type: int
- // RequirementLevel: ConditionallyRequired (If response is not successful.)
- // Stability: stable
- // Examples: -32700, 100
- RPCJsonrpcErrorCodeKey = attribute.Key("rpc.jsonrpc.error_code")
-
- // RPCJsonrpcErrorMessageKey is the attribute Key conforming to the
- // "rpc.jsonrpc.error_message" semantic conventions. It represents the
- // `error.message` property of response if it is an error response.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'Parse error', 'User already exists'
- RPCJsonrpcErrorMessageKey = attribute.Key("rpc.jsonrpc.error_message")
-)
-
-// RPCJsonrpcVersion returns an attribute KeyValue conforming to the
-// "rpc.jsonrpc.version" semantic conventions. It represents the protocol
-// version as in `jsonrpc` property of request/response. Since JSON-RPC 1.0
-// does not specify this, the value can be omitted.
-func RPCJsonrpcVersion(val string) attribute.KeyValue {
- return RPCJsonrpcVersionKey.String(val)
-}
-
-// RPCJsonrpcRequestID returns an attribute KeyValue conforming to the
-// "rpc.jsonrpc.request_id" semantic conventions. It represents the `id`
-// property of request or response. Since protocol allows id to be int, string,
-// `null` or missing (for notifications), value is expected to be cast to
-// string for simplicity. Use empty string in case of `null` value. Omit
-// entirely if this is a notification.
-func RPCJsonrpcRequestID(val string) attribute.KeyValue {
- return RPCJsonrpcRequestIDKey.String(val)
-}
-
-// RPCJsonrpcErrorCode returns an attribute KeyValue conforming to the
-// "rpc.jsonrpc.error_code" semantic conventions. It represents the
-// `error.code` property of response if it is an error response.
-func RPCJsonrpcErrorCode(val int) attribute.KeyValue {
- return RPCJsonrpcErrorCodeKey.Int(val)
-}
-
-// RPCJsonrpcErrorMessage returns an attribute KeyValue conforming to the
-// "rpc.jsonrpc.error_message" semantic conventions. It represents the
-// `error.message` property of response if it is an error response.
-func RPCJsonrpcErrorMessage(val string) attribute.KeyValue {
- return RPCJsonrpcErrorMessageKey.String(val)
-}
-
-// Tech-specific attributes for Connect RPC.
-const (
- // RPCConnectRPCErrorCodeKey is the attribute Key conforming to the
- // "rpc.connect_rpc.error_code" semantic conventions. It represents the
- // [error codes](https://connect.build/docs/protocol/#error-codes) of the
- // Connect request. Error codes are always string values.
- //
- // Type: Enum
- // RequirementLevel: ConditionallyRequired (If response is not successful
- // and if error code available.)
- // Stability: stable
- RPCConnectRPCErrorCodeKey = attribute.Key("rpc.connect_rpc.error_code")
-)
-
-var (
- // cancelled
- RPCConnectRPCErrorCodeCancelled = RPCConnectRPCErrorCodeKey.String("cancelled")
- // unknown
- RPCConnectRPCErrorCodeUnknown = RPCConnectRPCErrorCodeKey.String("unknown")
- // invalid_argument
- RPCConnectRPCErrorCodeInvalidArgument = RPCConnectRPCErrorCodeKey.String("invalid_argument")
- // deadline_exceeded
- RPCConnectRPCErrorCodeDeadlineExceeded = RPCConnectRPCErrorCodeKey.String("deadline_exceeded")
- // not_found
- RPCConnectRPCErrorCodeNotFound = RPCConnectRPCErrorCodeKey.String("not_found")
- // already_exists
- RPCConnectRPCErrorCodeAlreadyExists = RPCConnectRPCErrorCodeKey.String("already_exists")
- // permission_denied
- RPCConnectRPCErrorCodePermissionDenied = RPCConnectRPCErrorCodeKey.String("permission_denied")
- // resource_exhausted
- RPCConnectRPCErrorCodeResourceExhausted = RPCConnectRPCErrorCodeKey.String("resource_exhausted")
- // failed_precondition
- RPCConnectRPCErrorCodeFailedPrecondition = RPCConnectRPCErrorCodeKey.String("failed_precondition")
- // aborted
- RPCConnectRPCErrorCodeAborted = RPCConnectRPCErrorCodeKey.String("aborted")
- // out_of_range
- RPCConnectRPCErrorCodeOutOfRange = RPCConnectRPCErrorCodeKey.String("out_of_range")
- // unimplemented
- RPCConnectRPCErrorCodeUnimplemented = RPCConnectRPCErrorCodeKey.String("unimplemented")
- // internal
- RPCConnectRPCErrorCodeInternal = RPCConnectRPCErrorCodeKey.String("internal")
- // unavailable
- RPCConnectRPCErrorCodeUnavailable = RPCConnectRPCErrorCodeKey.String("unavailable")
- // data_loss
- RPCConnectRPCErrorCodeDataLoss = RPCConnectRPCErrorCodeKey.String("data_loss")
- // unauthenticated
- RPCConnectRPCErrorCodeUnauthenticated = RPCConnectRPCErrorCodeKey.String("unauthenticated")
-)
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.26.0/README.md b/vendor/go.opentelemetry.io/otel/semconv/v1.26.0/README.md
deleted file mode 100644
index 2de1fc3c6b..0000000000
--- a/vendor/go.opentelemetry.io/otel/semconv/v1.26.0/README.md
+++ /dev/null
@@ -1,3 +0,0 @@
-# Semconv v1.26.0
-
-[](https://pkg.go.dev/go.opentelemetry.io/otel/semconv/v1.26.0)
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.26.0/attribute_group.go b/vendor/go.opentelemetry.io/otel/semconv/v1.26.0/attribute_group.go
deleted file mode 100644
index d8dc822b26..0000000000
--- a/vendor/go.opentelemetry.io/otel/semconv/v1.26.0/attribute_group.go
+++ /dev/null
@@ -1,8996 +0,0 @@
-// Copyright The OpenTelemetry Authors
-// SPDX-License-Identifier: Apache-2.0
-
-// Code generated from semantic convention specification. DO NOT EDIT.
-
-package semconv // import "go.opentelemetry.io/otel/semconv/v1.26.0"
-
-import "go.opentelemetry.io/otel/attribute"
-
-// The Android platform on which the Android application is running.
-const (
- // AndroidOSAPILevelKey is the attribute Key conforming to the
- // "android.os.api_level" semantic conventions. It represents the uniquely
- // identifies the framework API revision offered by a version
- // (`os.version`) of the android operating system. More information can be
- // found
- // [here](https://developer.android.com/guide/topics/manifest/uses-sdk-element#APILevels).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '33', '32'
- AndroidOSAPILevelKey = attribute.Key("android.os.api_level")
-)
-
-// AndroidOSAPILevel returns an attribute KeyValue conforming to the
-// "android.os.api_level" semantic conventions. It represents the uniquely
-// identifies the framework API revision offered by a version (`os.version`) of
-// the android operating system. More information can be found
-// [here](https://developer.android.com/guide/topics/manifest/uses-sdk-element#APILevels).
-func AndroidOSAPILevel(val string) attribute.KeyValue {
- return AndroidOSAPILevelKey.String(val)
-}
-
-// ASP.NET Core attributes
-const (
- // AspnetcoreRateLimitingResultKey is the attribute Key conforming to the
- // "aspnetcore.rate_limiting.result" semantic conventions. It represents
- // the rate-limiting result, shows whether the lease was acquired or
- // contains a rejection reason
- //
- // Type: Enum
- // RequirementLevel: Required
- // Stability: stable
- // Examples: 'acquired', 'request_canceled'
- AspnetcoreRateLimitingResultKey = attribute.Key("aspnetcore.rate_limiting.result")
-
- // AspnetcoreDiagnosticsHandlerTypeKey is the attribute Key conforming to
- // the "aspnetcore.diagnostics.handler.type" semantic conventions. It
- // represents the full type name of the
- // [`IExceptionHandler`](https://learn.microsoft.com/dotnet/api/microsoft.aspnetcore.diagnostics.iexceptionhandler)
- // implementation that handled the exception.
- //
- // Type: string
- // RequirementLevel: ConditionallyRequired (if and only if the exception
- // was handled by this handler.)
- // Stability: stable
- // Examples: 'Contoso.MyHandler'
- AspnetcoreDiagnosticsHandlerTypeKey = attribute.Key("aspnetcore.diagnostics.handler.type")
-
- // AspnetcoreDiagnosticsExceptionResultKey is the attribute Key conforming
- // to the "aspnetcore.diagnostics.exception.result" semantic conventions.
- // It represents the aSP.NET Core exception middleware handling result
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'handled', 'unhandled'
- AspnetcoreDiagnosticsExceptionResultKey = attribute.Key("aspnetcore.diagnostics.exception.result")
-
- // AspnetcoreRateLimitingPolicyKey is the attribute Key conforming to the
- // "aspnetcore.rate_limiting.policy" semantic conventions. It represents
- // the rate limiting policy name.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'fixed', 'sliding', 'token'
- AspnetcoreRateLimitingPolicyKey = attribute.Key("aspnetcore.rate_limiting.policy")
-
- // AspnetcoreRequestIsUnhandledKey is the attribute Key conforming to the
- // "aspnetcore.request.is_unhandled" semantic conventions. It represents
- // the flag indicating if request was handled by the application pipeline.
- //
- // Type: boolean
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: True
- AspnetcoreRequestIsUnhandledKey = attribute.Key("aspnetcore.request.is_unhandled")
-
- // AspnetcoreRoutingIsFallbackKey is the attribute Key conforming to the
- // "aspnetcore.routing.is_fallback" semantic conventions. It represents a
- // value that indicates whether the matched route is a fallback route.
- //
- // Type: boolean
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: True
- AspnetcoreRoutingIsFallbackKey = attribute.Key("aspnetcore.routing.is_fallback")
-
- // AspnetcoreRoutingMatchStatusKey is the attribute Key conforming to the
- // "aspnetcore.routing.match_status" semantic conventions. It represents
- // the match result - success or failure
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'success', 'failure'
- AspnetcoreRoutingMatchStatusKey = attribute.Key("aspnetcore.routing.match_status")
-)
-
-var (
- // Lease was acquired
- AspnetcoreRateLimitingResultAcquired = AspnetcoreRateLimitingResultKey.String("acquired")
- // Lease request was rejected by the endpoint limiter
- AspnetcoreRateLimitingResultEndpointLimiter = AspnetcoreRateLimitingResultKey.String("endpoint_limiter")
- // Lease request was rejected by the global limiter
- AspnetcoreRateLimitingResultGlobalLimiter = AspnetcoreRateLimitingResultKey.String("global_limiter")
- // Lease request was canceled
- AspnetcoreRateLimitingResultRequestCanceled = AspnetcoreRateLimitingResultKey.String("request_canceled")
-)
-
-var (
- // Exception was handled by the exception handling middleware
- AspnetcoreDiagnosticsExceptionResultHandled = AspnetcoreDiagnosticsExceptionResultKey.String("handled")
- // Exception was not handled by the exception handling middleware
- AspnetcoreDiagnosticsExceptionResultUnhandled = AspnetcoreDiagnosticsExceptionResultKey.String("unhandled")
- // Exception handling was skipped because the response had started
- AspnetcoreDiagnosticsExceptionResultSkipped = AspnetcoreDiagnosticsExceptionResultKey.String("skipped")
- // Exception handling didn't run because the request was aborted
- AspnetcoreDiagnosticsExceptionResultAborted = AspnetcoreDiagnosticsExceptionResultKey.String("aborted")
-)
-
-var (
- // Match succeeded
- AspnetcoreRoutingMatchStatusSuccess = AspnetcoreRoutingMatchStatusKey.String("success")
- // Match failed
- AspnetcoreRoutingMatchStatusFailure = AspnetcoreRoutingMatchStatusKey.String("failure")
-)
-
-// AspnetcoreDiagnosticsHandlerType returns an attribute KeyValue conforming
-// to the "aspnetcore.diagnostics.handler.type" semantic conventions. It
-// represents the full type name of the
-// [`IExceptionHandler`](https://learn.microsoft.com/dotnet/api/microsoft.aspnetcore.diagnostics.iexceptionhandler)
-// implementation that handled the exception.
-func AspnetcoreDiagnosticsHandlerType(val string) attribute.KeyValue {
- return AspnetcoreDiagnosticsHandlerTypeKey.String(val)
-}
-
-// AspnetcoreRateLimitingPolicy returns an attribute KeyValue conforming to
-// the "aspnetcore.rate_limiting.policy" semantic conventions. It represents
-// the rate limiting policy name.
-func AspnetcoreRateLimitingPolicy(val string) attribute.KeyValue {
- return AspnetcoreRateLimitingPolicyKey.String(val)
-}
-
-// AspnetcoreRequestIsUnhandled returns an attribute KeyValue conforming to
-// the "aspnetcore.request.is_unhandled" semantic conventions. It represents
-// the flag indicating if request was handled by the application pipeline.
-func AspnetcoreRequestIsUnhandled(val bool) attribute.KeyValue {
- return AspnetcoreRequestIsUnhandledKey.Bool(val)
-}
-
-// AspnetcoreRoutingIsFallback returns an attribute KeyValue conforming to
-// the "aspnetcore.routing.is_fallback" semantic conventions. It represents a
-// value that indicates whether the matched route is a fallback route.
-func AspnetcoreRoutingIsFallback(val bool) attribute.KeyValue {
- return AspnetcoreRoutingIsFallbackKey.Bool(val)
-}
-
-// Generic attributes for AWS services.
-const (
- // AWSRequestIDKey is the attribute Key conforming to the "aws.request_id"
- // semantic conventions. It represents the AWS request ID as returned in
- // the response headers `x-amz-request-id` or `x-amz-requestid`.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '79b9da39-b7ae-508a-a6bc-864b2829c622', 'C9ER4AJX75574TDJ'
- AWSRequestIDKey = attribute.Key("aws.request_id")
-)
-
-// AWSRequestID returns an attribute KeyValue conforming to the
-// "aws.request_id" semantic conventions. It represents the AWS request ID as
-// returned in the response headers `x-amz-request-id` or `x-amz-requestid`.
-func AWSRequestID(val string) attribute.KeyValue {
- return AWSRequestIDKey.String(val)
-}
-
-// Attributes for AWS DynamoDB.
-const (
- // AWSDynamoDBAttributeDefinitionsKey is the attribute Key conforming to
- // the "aws.dynamodb.attribute_definitions" semantic conventions. It
- // represents the JSON-serialized value of each item in the
- // `AttributeDefinitions` request field.
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '{ "AttributeName": "string", "AttributeType": "string" }'
- AWSDynamoDBAttributeDefinitionsKey = attribute.Key("aws.dynamodb.attribute_definitions")
-
- // AWSDynamoDBAttributesToGetKey is the attribute Key conforming to the
- // "aws.dynamodb.attributes_to_get" semantic conventions. It represents the
- // value of the `AttributesToGet` request parameter.
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'lives', 'id'
- AWSDynamoDBAttributesToGetKey = attribute.Key("aws.dynamodb.attributes_to_get")
-
- // AWSDynamoDBConsistentReadKey is the attribute Key conforming to the
- // "aws.dynamodb.consistent_read" semantic conventions. It represents the
- // value of the `ConsistentRead` request parameter.
- //
- // Type: boolean
- // RequirementLevel: Optional
- // Stability: experimental
- AWSDynamoDBConsistentReadKey = attribute.Key("aws.dynamodb.consistent_read")
-
- // AWSDynamoDBConsumedCapacityKey is the attribute Key conforming to the
- // "aws.dynamodb.consumed_capacity" semantic conventions. It represents the
- // JSON-serialized value of each item in the `ConsumedCapacity` response
- // field.
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '{ "CapacityUnits": number, "GlobalSecondaryIndexes": {
- // "string" : { "CapacityUnits": number, "ReadCapacityUnits": number,
- // "WriteCapacityUnits": number } }, "LocalSecondaryIndexes": { "string" :
- // { "CapacityUnits": number, "ReadCapacityUnits": number,
- // "WriteCapacityUnits": number } }, "ReadCapacityUnits": number, "Table":
- // { "CapacityUnits": number, "ReadCapacityUnits": number,
- // "WriteCapacityUnits": number }, "TableName": "string",
- // "WriteCapacityUnits": number }'
- AWSDynamoDBConsumedCapacityKey = attribute.Key("aws.dynamodb.consumed_capacity")
-
- // AWSDynamoDBCountKey is the attribute Key conforming to the
- // "aws.dynamodb.count" semantic conventions. It represents the value of
- // the `Count` response parameter.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 10
- AWSDynamoDBCountKey = attribute.Key("aws.dynamodb.count")
-
- // AWSDynamoDBExclusiveStartTableKey is the attribute Key conforming to the
- // "aws.dynamodb.exclusive_start_table" semantic conventions. It represents
- // the value of the `ExclusiveStartTableName` request parameter.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'Users', 'CatsTable'
- AWSDynamoDBExclusiveStartTableKey = attribute.Key("aws.dynamodb.exclusive_start_table")
-
- // AWSDynamoDBGlobalSecondaryIndexUpdatesKey is the attribute Key
- // conforming to the "aws.dynamodb.global_secondary_index_updates" semantic
- // conventions. It represents the JSON-serialized value of each item in the
- // `GlobalSecondaryIndexUpdates` request field.
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '{ "Create": { "IndexName": "string", "KeySchema": [ {
- // "AttributeName": "string", "KeyType": "string" } ], "Projection": {
- // "NonKeyAttributes": [ "string" ], "ProjectionType": "string" },
- // "ProvisionedThroughput": { "ReadCapacityUnits": number,
- // "WriteCapacityUnits": number } }'
- AWSDynamoDBGlobalSecondaryIndexUpdatesKey = attribute.Key("aws.dynamodb.global_secondary_index_updates")
-
- // AWSDynamoDBGlobalSecondaryIndexesKey is the attribute Key conforming to
- // the "aws.dynamodb.global_secondary_indexes" semantic conventions. It
- // represents the JSON-serialized value of each item of the
- // `GlobalSecondaryIndexes` request field
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '{ "IndexName": "string", "KeySchema": [ { "AttributeName":
- // "string", "KeyType": "string" } ], "Projection": { "NonKeyAttributes": [
- // "string" ], "ProjectionType": "string" }, "ProvisionedThroughput": {
- // "ReadCapacityUnits": number, "WriteCapacityUnits": number } }'
- AWSDynamoDBGlobalSecondaryIndexesKey = attribute.Key("aws.dynamodb.global_secondary_indexes")
-
- // AWSDynamoDBIndexNameKey is the attribute Key conforming to the
- // "aws.dynamodb.index_name" semantic conventions. It represents the value
- // of the `IndexName` request parameter.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'name_to_group'
- AWSDynamoDBIndexNameKey = attribute.Key("aws.dynamodb.index_name")
-
- // AWSDynamoDBItemCollectionMetricsKey is the attribute Key conforming to
- // the "aws.dynamodb.item_collection_metrics" semantic conventions. It
- // represents the JSON-serialized value of the `ItemCollectionMetrics`
- // response field.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '{ "string" : [ { "ItemCollectionKey": { "string" : { "B":
- // blob, "BOOL": boolean, "BS": [ blob ], "L": [ "AttributeValue" ], "M": {
- // "string" : "AttributeValue" }, "N": "string", "NS": [ "string" ],
- // "NULL": boolean, "S": "string", "SS": [ "string" ] } },
- // "SizeEstimateRangeGB": [ number ] } ] }'
- AWSDynamoDBItemCollectionMetricsKey = attribute.Key("aws.dynamodb.item_collection_metrics")
-
- // AWSDynamoDBLimitKey is the attribute Key conforming to the
- // "aws.dynamodb.limit" semantic conventions. It represents the value of
- // the `Limit` request parameter.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 10
- AWSDynamoDBLimitKey = attribute.Key("aws.dynamodb.limit")
-
- // AWSDynamoDBLocalSecondaryIndexesKey is the attribute Key conforming to
- // the "aws.dynamodb.local_secondary_indexes" semantic conventions. It
- // represents the JSON-serialized value of each item of the
- // `LocalSecondaryIndexes` request field.
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '{ "IndexARN": "string", "IndexName": "string",
- // "IndexSizeBytes": number, "ItemCount": number, "KeySchema": [ {
- // "AttributeName": "string", "KeyType": "string" } ], "Projection": {
- // "NonKeyAttributes": [ "string" ], "ProjectionType": "string" } }'
- AWSDynamoDBLocalSecondaryIndexesKey = attribute.Key("aws.dynamodb.local_secondary_indexes")
-
- // AWSDynamoDBProjectionKey is the attribute Key conforming to the
- // "aws.dynamodb.projection" semantic conventions. It represents the value
- // of the `ProjectionExpression` request parameter.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'Title', 'Title, Price, Color', 'Title, Description,
- // RelatedItems, ProductReviews'
- AWSDynamoDBProjectionKey = attribute.Key("aws.dynamodb.projection")
-
- // AWSDynamoDBProvisionedReadCapacityKey is the attribute Key conforming to
- // the "aws.dynamodb.provisioned_read_capacity" semantic conventions. It
- // represents the value of the `ProvisionedThroughput.ReadCapacityUnits`
- // request parameter.
- //
- // Type: double
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 1.0, 2.0
- AWSDynamoDBProvisionedReadCapacityKey = attribute.Key("aws.dynamodb.provisioned_read_capacity")
-
- // AWSDynamoDBProvisionedWriteCapacityKey is the attribute Key conforming
- // to the "aws.dynamodb.provisioned_write_capacity" semantic conventions.
- // It represents the value of the
- // `ProvisionedThroughput.WriteCapacityUnits` request parameter.
- //
- // Type: double
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 1.0, 2.0
- AWSDynamoDBProvisionedWriteCapacityKey = attribute.Key("aws.dynamodb.provisioned_write_capacity")
-
- // AWSDynamoDBScanForwardKey is the attribute Key conforming to the
- // "aws.dynamodb.scan_forward" semantic conventions. It represents the
- // value of the `ScanIndexForward` request parameter.
- //
- // Type: boolean
- // RequirementLevel: Optional
- // Stability: experimental
- AWSDynamoDBScanForwardKey = attribute.Key("aws.dynamodb.scan_forward")
-
- // AWSDynamoDBScannedCountKey is the attribute Key conforming to the
- // "aws.dynamodb.scanned_count" semantic conventions. It represents the
- // value of the `ScannedCount` response parameter.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 50
- AWSDynamoDBScannedCountKey = attribute.Key("aws.dynamodb.scanned_count")
-
- // AWSDynamoDBSegmentKey is the attribute Key conforming to the
- // "aws.dynamodb.segment" semantic conventions. It represents the value of
- // the `Segment` request parameter.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 10
- AWSDynamoDBSegmentKey = attribute.Key("aws.dynamodb.segment")
-
- // AWSDynamoDBSelectKey is the attribute Key conforming to the
- // "aws.dynamodb.select" semantic conventions. It represents the value of
- // the `Select` request parameter.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'ALL_ATTRIBUTES', 'COUNT'
- AWSDynamoDBSelectKey = attribute.Key("aws.dynamodb.select")
-
- // AWSDynamoDBTableCountKey is the attribute Key conforming to the
- // "aws.dynamodb.table_count" semantic conventions. It represents the
- // number of items in the `TableNames` response parameter.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 20
- AWSDynamoDBTableCountKey = attribute.Key("aws.dynamodb.table_count")
-
- // AWSDynamoDBTableNamesKey is the attribute Key conforming to the
- // "aws.dynamodb.table_names" semantic conventions. It represents the keys
- // in the `RequestItems` object field.
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'Users', 'Cats'
- AWSDynamoDBTableNamesKey = attribute.Key("aws.dynamodb.table_names")
-
- // AWSDynamoDBTotalSegmentsKey is the attribute Key conforming to the
- // "aws.dynamodb.total_segments" semantic conventions. It represents the
- // value of the `TotalSegments` request parameter.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 100
- AWSDynamoDBTotalSegmentsKey = attribute.Key("aws.dynamodb.total_segments")
-)
-
-// AWSDynamoDBAttributeDefinitions returns an attribute KeyValue conforming
-// to the "aws.dynamodb.attribute_definitions" semantic conventions. It
-// represents the JSON-serialized value of each item in the
-// `AttributeDefinitions` request field.
-func AWSDynamoDBAttributeDefinitions(val ...string) attribute.KeyValue {
- return AWSDynamoDBAttributeDefinitionsKey.StringSlice(val)
-}
-
-// AWSDynamoDBAttributesToGet returns an attribute KeyValue conforming to
-// the "aws.dynamodb.attributes_to_get" semantic conventions. It represents the
-// value of the `AttributesToGet` request parameter.
-func AWSDynamoDBAttributesToGet(val ...string) attribute.KeyValue {
- return AWSDynamoDBAttributesToGetKey.StringSlice(val)
-}
-
-// AWSDynamoDBConsistentRead returns an attribute KeyValue conforming to the
-// "aws.dynamodb.consistent_read" semantic conventions. It represents the value
-// of the `ConsistentRead` request parameter.
-func AWSDynamoDBConsistentRead(val bool) attribute.KeyValue {
- return AWSDynamoDBConsistentReadKey.Bool(val)
-}
-
-// AWSDynamoDBConsumedCapacity returns an attribute KeyValue conforming to
-// the "aws.dynamodb.consumed_capacity" semantic conventions. It represents the
-// JSON-serialized value of each item in the `ConsumedCapacity` response field.
-func AWSDynamoDBConsumedCapacity(val ...string) attribute.KeyValue {
- return AWSDynamoDBConsumedCapacityKey.StringSlice(val)
-}
-
-// AWSDynamoDBCount returns an attribute KeyValue conforming to the
-// "aws.dynamodb.count" semantic conventions. It represents the value of the
-// `Count` response parameter.
-func AWSDynamoDBCount(val int) attribute.KeyValue {
- return AWSDynamoDBCountKey.Int(val)
-}
-
-// AWSDynamoDBExclusiveStartTable returns an attribute KeyValue conforming
-// to the "aws.dynamodb.exclusive_start_table" semantic conventions. It
-// represents the value of the `ExclusiveStartTableName` request parameter.
-func AWSDynamoDBExclusiveStartTable(val string) attribute.KeyValue {
- return AWSDynamoDBExclusiveStartTableKey.String(val)
-}
-
-// AWSDynamoDBGlobalSecondaryIndexUpdates returns an attribute KeyValue
-// conforming to the "aws.dynamodb.global_secondary_index_updates" semantic
-// conventions. It represents the JSON-serialized value of each item in the
-// `GlobalSecondaryIndexUpdates` request field.
-func AWSDynamoDBGlobalSecondaryIndexUpdates(val ...string) attribute.KeyValue {
- return AWSDynamoDBGlobalSecondaryIndexUpdatesKey.StringSlice(val)
-}
-
-// AWSDynamoDBGlobalSecondaryIndexes returns an attribute KeyValue
-// conforming to the "aws.dynamodb.global_secondary_indexes" semantic
-// conventions. It represents the JSON-serialized value of each item of the
-// `GlobalSecondaryIndexes` request field
-func AWSDynamoDBGlobalSecondaryIndexes(val ...string) attribute.KeyValue {
- return AWSDynamoDBGlobalSecondaryIndexesKey.StringSlice(val)
-}
-
-// AWSDynamoDBIndexName returns an attribute KeyValue conforming to the
-// "aws.dynamodb.index_name" semantic conventions. It represents the value of
-// the `IndexName` request parameter.
-func AWSDynamoDBIndexName(val string) attribute.KeyValue {
- return AWSDynamoDBIndexNameKey.String(val)
-}
-
-// AWSDynamoDBItemCollectionMetrics returns an attribute KeyValue conforming
-// to the "aws.dynamodb.item_collection_metrics" semantic conventions. It
-// represents the JSON-serialized value of the `ItemCollectionMetrics` response
-// field.
-func AWSDynamoDBItemCollectionMetrics(val string) attribute.KeyValue {
- return AWSDynamoDBItemCollectionMetricsKey.String(val)
-}
-
-// AWSDynamoDBLimit returns an attribute KeyValue conforming to the
-// "aws.dynamodb.limit" semantic conventions. It represents the value of the
-// `Limit` request parameter.
-func AWSDynamoDBLimit(val int) attribute.KeyValue {
- return AWSDynamoDBLimitKey.Int(val)
-}
-
-// AWSDynamoDBLocalSecondaryIndexes returns an attribute KeyValue conforming
-// to the "aws.dynamodb.local_secondary_indexes" semantic conventions. It
-// represents the JSON-serialized value of each item of the
-// `LocalSecondaryIndexes` request field.
-func AWSDynamoDBLocalSecondaryIndexes(val ...string) attribute.KeyValue {
- return AWSDynamoDBLocalSecondaryIndexesKey.StringSlice(val)
-}
-
-// AWSDynamoDBProjection returns an attribute KeyValue conforming to the
-// "aws.dynamodb.projection" semantic conventions. It represents the value of
-// the `ProjectionExpression` request parameter.
-func AWSDynamoDBProjection(val string) attribute.KeyValue {
- return AWSDynamoDBProjectionKey.String(val)
-}
-
-// AWSDynamoDBProvisionedReadCapacity returns an attribute KeyValue
-// conforming to the "aws.dynamodb.provisioned_read_capacity" semantic
-// conventions. It represents the value of the
-// `ProvisionedThroughput.ReadCapacityUnits` request parameter.
-func AWSDynamoDBProvisionedReadCapacity(val float64) attribute.KeyValue {
- return AWSDynamoDBProvisionedReadCapacityKey.Float64(val)
-}
-
-// AWSDynamoDBProvisionedWriteCapacity returns an attribute KeyValue
-// conforming to the "aws.dynamodb.provisioned_write_capacity" semantic
-// conventions. It represents the value of the
-// `ProvisionedThroughput.WriteCapacityUnits` request parameter.
-func AWSDynamoDBProvisionedWriteCapacity(val float64) attribute.KeyValue {
- return AWSDynamoDBProvisionedWriteCapacityKey.Float64(val)
-}
-
-// AWSDynamoDBScanForward returns an attribute KeyValue conforming to the
-// "aws.dynamodb.scan_forward" semantic conventions. It represents the value of
-// the `ScanIndexForward` request parameter.
-func AWSDynamoDBScanForward(val bool) attribute.KeyValue {
- return AWSDynamoDBScanForwardKey.Bool(val)
-}
-
-// AWSDynamoDBScannedCount returns an attribute KeyValue conforming to the
-// "aws.dynamodb.scanned_count" semantic conventions. It represents the value
-// of the `ScannedCount` response parameter.
-func AWSDynamoDBScannedCount(val int) attribute.KeyValue {
- return AWSDynamoDBScannedCountKey.Int(val)
-}
-
-// AWSDynamoDBSegment returns an attribute KeyValue conforming to the
-// "aws.dynamodb.segment" semantic conventions. It represents the value of the
-// `Segment` request parameter.
-func AWSDynamoDBSegment(val int) attribute.KeyValue {
- return AWSDynamoDBSegmentKey.Int(val)
-}
-
-// AWSDynamoDBSelect returns an attribute KeyValue conforming to the
-// "aws.dynamodb.select" semantic conventions. It represents the value of the
-// `Select` request parameter.
-func AWSDynamoDBSelect(val string) attribute.KeyValue {
- return AWSDynamoDBSelectKey.String(val)
-}
-
-// AWSDynamoDBTableCount returns an attribute KeyValue conforming to the
-// "aws.dynamodb.table_count" semantic conventions. It represents the number of
-// items in the `TableNames` response parameter.
-func AWSDynamoDBTableCount(val int) attribute.KeyValue {
- return AWSDynamoDBTableCountKey.Int(val)
-}
-
-// AWSDynamoDBTableNames returns an attribute KeyValue conforming to the
-// "aws.dynamodb.table_names" semantic conventions. It represents the keys in
-// the `RequestItems` object field.
-func AWSDynamoDBTableNames(val ...string) attribute.KeyValue {
- return AWSDynamoDBTableNamesKey.StringSlice(val)
-}
-
-// AWSDynamoDBTotalSegments returns an attribute KeyValue conforming to the
-// "aws.dynamodb.total_segments" semantic conventions. It represents the value
-// of the `TotalSegments` request parameter.
-func AWSDynamoDBTotalSegments(val int) attribute.KeyValue {
- return AWSDynamoDBTotalSegmentsKey.Int(val)
-}
-
-// Attributes for AWS Elastic Container Service (ECS).
-const (
- // AWSECSTaskIDKey is the attribute Key conforming to the "aws.ecs.task.id"
- // semantic conventions. It represents the ID of a running ECS task. The ID
- // MUST be extracted from `task.arn`.
- //
- // Type: string
- // RequirementLevel: ConditionallyRequired (If and only if `task.arn` is
- // populated.)
- // Stability: experimental
- // Examples: '10838bed-421f-43ef-870a-f43feacbbb5b',
- // '23ebb8ac-c18f-46c6-8bbe-d55d0e37cfbd'
- AWSECSTaskIDKey = attribute.Key("aws.ecs.task.id")
-
- // AWSECSClusterARNKey is the attribute Key conforming to the
- // "aws.ecs.cluster.arn" semantic conventions. It represents the ARN of an
- // [ECS
- // cluster](https://docs.aws.amazon.com/AmazonECS/latest/developerguide/clusters.html).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'arn:aws:ecs:us-west-2:123456789123:cluster/my-cluster'
- AWSECSClusterARNKey = attribute.Key("aws.ecs.cluster.arn")
-
- // AWSECSContainerARNKey is the attribute Key conforming to the
- // "aws.ecs.container.arn" semantic conventions. It represents the Amazon
- // Resource Name (ARN) of an [ECS container
- // instance](https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ECS_instances.html).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples:
- // 'arn:aws:ecs:us-west-1:123456789123:container/32624152-9086-4f0e-acae-1a75b14fe4d9'
- AWSECSContainerARNKey = attribute.Key("aws.ecs.container.arn")
-
- // AWSECSLaunchtypeKey is the attribute Key conforming to the
- // "aws.ecs.launchtype" semantic conventions. It represents the [launch
- // type](https://docs.aws.amazon.com/AmazonECS/latest/developerguide/launch_types.html)
- // for an ECS task.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- AWSECSLaunchtypeKey = attribute.Key("aws.ecs.launchtype")
-
- // AWSECSTaskARNKey is the attribute Key conforming to the
- // "aws.ecs.task.arn" semantic conventions. It represents the ARN of a
- // running [ECS
- // task](https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ecs-account-settings.html#ecs-resource-ids).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples:
- // 'arn:aws:ecs:us-west-1:123456789123:task/10838bed-421f-43ef-870a-f43feacbbb5b',
- // 'arn:aws:ecs:us-west-1:123456789123:task/my-cluster/task-id/23ebb8ac-c18f-46c6-8bbe-d55d0e37cfbd'
- AWSECSTaskARNKey = attribute.Key("aws.ecs.task.arn")
-
- // AWSECSTaskFamilyKey is the attribute Key conforming to the
- // "aws.ecs.task.family" semantic conventions. It represents the family
- // name of the [ECS task
- // definition](https://docs.aws.amazon.com/AmazonECS/latest/developerguide/task_definitions.html)
- // used to create the ECS task.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'opentelemetry-family'
- AWSECSTaskFamilyKey = attribute.Key("aws.ecs.task.family")
-
- // AWSECSTaskRevisionKey is the attribute Key conforming to the
- // "aws.ecs.task.revision" semantic conventions. It represents the revision
- // for the task definition used to create the ECS task.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '8', '26'
- AWSECSTaskRevisionKey = attribute.Key("aws.ecs.task.revision")
-)
-
-var (
- // ec2
- AWSECSLaunchtypeEC2 = AWSECSLaunchtypeKey.String("ec2")
- // fargate
- AWSECSLaunchtypeFargate = AWSECSLaunchtypeKey.String("fargate")
-)
-
-// AWSECSTaskID returns an attribute KeyValue conforming to the
-// "aws.ecs.task.id" semantic conventions. It represents the ID of a running
-// ECS task. The ID MUST be extracted from `task.arn`.
-func AWSECSTaskID(val string) attribute.KeyValue {
- return AWSECSTaskIDKey.String(val)
-}
-
-// AWSECSClusterARN returns an attribute KeyValue conforming to the
-// "aws.ecs.cluster.arn" semantic conventions. It represents the ARN of an [ECS
-// cluster](https://docs.aws.amazon.com/AmazonECS/latest/developerguide/clusters.html).
-func AWSECSClusterARN(val string) attribute.KeyValue {
- return AWSECSClusterARNKey.String(val)
-}
-
-// AWSECSContainerARN returns an attribute KeyValue conforming to the
-// "aws.ecs.container.arn" semantic conventions. It represents the Amazon
-// Resource Name (ARN) of an [ECS container
-// instance](https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ECS_instances.html).
-func AWSECSContainerARN(val string) attribute.KeyValue {
- return AWSECSContainerARNKey.String(val)
-}
-
-// AWSECSTaskARN returns an attribute KeyValue conforming to the
-// "aws.ecs.task.arn" semantic conventions. It represents the ARN of a running
-// [ECS
-// task](https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ecs-account-settings.html#ecs-resource-ids).
-func AWSECSTaskARN(val string) attribute.KeyValue {
- return AWSECSTaskARNKey.String(val)
-}
-
-// AWSECSTaskFamily returns an attribute KeyValue conforming to the
-// "aws.ecs.task.family" semantic conventions. It represents the family name of
-// the [ECS task
-// definition](https://docs.aws.amazon.com/AmazonECS/latest/developerguide/task_definitions.html)
-// used to create the ECS task.
-func AWSECSTaskFamily(val string) attribute.KeyValue {
- return AWSECSTaskFamilyKey.String(val)
-}
-
-// AWSECSTaskRevision returns an attribute KeyValue conforming to the
-// "aws.ecs.task.revision" semantic conventions. It represents the revision for
-// the task definition used to create the ECS task.
-func AWSECSTaskRevision(val string) attribute.KeyValue {
- return AWSECSTaskRevisionKey.String(val)
-}
-
-// Attributes for AWS Elastic Kubernetes Service (EKS).
-const (
- // AWSEKSClusterARNKey is the attribute Key conforming to the
- // "aws.eks.cluster.arn" semantic conventions. It represents the ARN of an
- // EKS cluster.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'arn:aws:ecs:us-west-2:123456789123:cluster/my-cluster'
- AWSEKSClusterARNKey = attribute.Key("aws.eks.cluster.arn")
-)
-
-// AWSEKSClusterARN returns an attribute KeyValue conforming to the
-// "aws.eks.cluster.arn" semantic conventions. It represents the ARN of an EKS
-// cluster.
-func AWSEKSClusterARN(val string) attribute.KeyValue {
- return AWSEKSClusterARNKey.String(val)
-}
-
-// Attributes for AWS Logs.
-const (
- // AWSLogGroupARNsKey is the attribute Key conforming to the
- // "aws.log.group.arns" semantic conventions. It represents the Amazon
- // Resource Name(s) (ARN) of the AWS log group(s).
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples:
- // 'arn:aws:logs:us-west-1:123456789012:log-group:/aws/my/group:*'
- // Note: See the [log group ARN format
- // documentation](https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/iam-access-control-overview-cwl.html#CWL_ARN_Format).
- AWSLogGroupARNsKey = attribute.Key("aws.log.group.arns")
-
- // AWSLogGroupNamesKey is the attribute Key conforming to the
- // "aws.log.group.names" semantic conventions. It represents the name(s) of
- // the AWS log group(s) an application is writing to.
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '/aws/lambda/my-function', 'opentelemetry-service'
- // Note: Multiple log groups must be supported for cases like
- // multi-container applications, where a single application has sidecar
- // containers, and each write to their own log group.
- AWSLogGroupNamesKey = attribute.Key("aws.log.group.names")
-
- // AWSLogStreamARNsKey is the attribute Key conforming to the
- // "aws.log.stream.arns" semantic conventions. It represents the ARN(s) of
- // the AWS log stream(s).
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples:
- // 'arn:aws:logs:us-west-1:123456789012:log-group:/aws/my/group:log-stream:logs/main/10838bed-421f-43ef-870a-f43feacbbb5b'
- // Note: See the [log stream ARN format
- // documentation](https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/iam-access-control-overview-cwl.html#CWL_ARN_Format).
- // One log group can contain several log streams, so these ARNs necessarily
- // identify both a log group and a log stream.
- AWSLogStreamARNsKey = attribute.Key("aws.log.stream.arns")
-
- // AWSLogStreamNamesKey is the attribute Key conforming to the
- // "aws.log.stream.names" semantic conventions. It represents the name(s)
- // of the AWS log stream(s) an application is writing to.
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'logs/main/10838bed-421f-43ef-870a-f43feacbbb5b'
- AWSLogStreamNamesKey = attribute.Key("aws.log.stream.names")
-)
-
-// AWSLogGroupARNs returns an attribute KeyValue conforming to the
-// "aws.log.group.arns" semantic conventions. It represents the Amazon Resource
-// Name(s) (ARN) of the AWS log group(s).
-func AWSLogGroupARNs(val ...string) attribute.KeyValue {
- return AWSLogGroupARNsKey.StringSlice(val)
-}
-
-// AWSLogGroupNames returns an attribute KeyValue conforming to the
-// "aws.log.group.names" semantic conventions. It represents the name(s) of the
-// AWS log group(s) an application is writing to.
-func AWSLogGroupNames(val ...string) attribute.KeyValue {
- return AWSLogGroupNamesKey.StringSlice(val)
-}
-
-// AWSLogStreamARNs returns an attribute KeyValue conforming to the
-// "aws.log.stream.arns" semantic conventions. It represents the ARN(s) of the
-// AWS log stream(s).
-func AWSLogStreamARNs(val ...string) attribute.KeyValue {
- return AWSLogStreamARNsKey.StringSlice(val)
-}
-
-// AWSLogStreamNames returns an attribute KeyValue conforming to the
-// "aws.log.stream.names" semantic conventions. It represents the name(s) of
-// the AWS log stream(s) an application is writing to.
-func AWSLogStreamNames(val ...string) attribute.KeyValue {
- return AWSLogStreamNamesKey.StringSlice(val)
-}
-
-// Attributes for AWS Lambda.
-const (
- // AWSLambdaInvokedARNKey is the attribute Key conforming to the
- // "aws.lambda.invoked_arn" semantic conventions. It represents the full
- // invoked ARN as provided on the `Context` passed to the function
- // (`Lambda-Runtime-Invoked-Function-ARN` header on the
- // `/runtime/invocation/next` applicable).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'arn:aws:lambda:us-east-1:123456:function:myfunction:myalias'
- // Note: This may be different from `cloud.resource_id` if an alias is
- // involved.
- AWSLambdaInvokedARNKey = attribute.Key("aws.lambda.invoked_arn")
-)
-
-// AWSLambdaInvokedARN returns an attribute KeyValue conforming to the
-// "aws.lambda.invoked_arn" semantic conventions. It represents the full
-// invoked ARN as provided on the `Context` passed to the function
-// (`Lambda-Runtime-Invoked-Function-ARN` header on the
-// `/runtime/invocation/next` applicable).
-func AWSLambdaInvokedARN(val string) attribute.KeyValue {
- return AWSLambdaInvokedARNKey.String(val)
-}
-
-// Attributes for AWS S3.
-const (
- // AWSS3BucketKey is the attribute Key conforming to the "aws.s3.bucket"
- // semantic conventions. It represents the S3 bucket name the request
- // refers to. Corresponds to the `--bucket` parameter of the [S3
- // API](https://docs.aws.amazon.com/cli/latest/reference/s3api/index.html)
- // operations.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'some-bucket-name'
- // Note: The `bucket` attribute is applicable to all S3 operations that
- // reference a bucket, i.e. that require the bucket name as a mandatory
- // parameter.
- // This applies to almost all S3 operations except `list-buckets`.
- AWSS3BucketKey = attribute.Key("aws.s3.bucket")
-
- // AWSS3CopySourceKey is the attribute Key conforming to the
- // "aws.s3.copy_source" semantic conventions. It represents the source
- // object (in the form `bucket`/`key`) for the copy operation.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'someFile.yml'
- // Note: The `copy_source` attribute applies to S3 copy operations and
- // corresponds to the `--copy-source` parameter
- // of the [copy-object operation within the S3
- // API](https://docs.aws.amazon.com/cli/latest/reference/s3api/copy-object.html).
- // This applies in particular to the following operations:
- //
- // -
- // [copy-object](https://docs.aws.amazon.com/cli/latest/reference/s3api/copy-object.html)
- // -
- // [upload-part-copy](https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part-copy.html)
- AWSS3CopySourceKey = attribute.Key("aws.s3.copy_source")
-
- // AWSS3DeleteKey is the attribute Key conforming to the "aws.s3.delete"
- // semantic conventions. It represents the delete request container that
- // specifies the objects to be deleted.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples:
- // 'Objects=[{Key=string,VersionID=string},{Key=string,VersionID=string}],Quiet=boolean'
- // Note: The `delete` attribute is only applicable to the
- // [delete-object](https://docs.aws.amazon.com/cli/latest/reference/s3api/delete-object.html)
- // operation.
- // The `delete` attribute corresponds to the `--delete` parameter of the
- // [delete-objects operation within the S3
- // API](https://docs.aws.amazon.com/cli/latest/reference/s3api/delete-objects.html).
- AWSS3DeleteKey = attribute.Key("aws.s3.delete")
-
- // AWSS3KeyKey is the attribute Key conforming to the "aws.s3.key" semantic
- // conventions. It represents the S3 object key the request refers to.
- // Corresponds to the `--key` parameter of the [S3
- // API](https://docs.aws.amazon.com/cli/latest/reference/s3api/index.html)
- // operations.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'someFile.yml'
- // Note: The `key` attribute is applicable to all object-related S3
- // operations, i.e. that require the object key as a mandatory parameter.
- // This applies in particular to the following operations:
- //
- // -
- // [copy-object](https://docs.aws.amazon.com/cli/latest/reference/s3api/copy-object.html)
- // -
- // [delete-object](https://docs.aws.amazon.com/cli/latest/reference/s3api/delete-object.html)
- // -
- // [get-object](https://docs.aws.amazon.com/cli/latest/reference/s3api/get-object.html)
- // -
- // [head-object](https://docs.aws.amazon.com/cli/latest/reference/s3api/head-object.html)
- // -
- // [put-object](https://docs.aws.amazon.com/cli/latest/reference/s3api/put-object.html)
- // -
- // [restore-object](https://docs.aws.amazon.com/cli/latest/reference/s3api/restore-object.html)
- // -
- // [select-object-content](https://docs.aws.amazon.com/cli/latest/reference/s3api/select-object-content.html)
- // -
- // [abort-multipart-upload](https://docs.aws.amazon.com/cli/latest/reference/s3api/abort-multipart-upload.html)
- // -
- // [complete-multipart-upload](https://docs.aws.amazon.com/cli/latest/reference/s3api/complete-multipart-upload.html)
- // -
- // [create-multipart-upload](https://docs.aws.amazon.com/cli/latest/reference/s3api/create-multipart-upload.html)
- // -
- // [list-parts](https://docs.aws.amazon.com/cli/latest/reference/s3api/list-parts.html)
- // -
- // [upload-part](https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part.html)
- // -
- // [upload-part-copy](https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part-copy.html)
- AWSS3KeyKey = attribute.Key("aws.s3.key")
-
- // AWSS3PartNumberKey is the attribute Key conforming to the
- // "aws.s3.part_number" semantic conventions. It represents the part number
- // of the part being uploaded in a multipart-upload operation. This is a
- // positive integer between 1 and 10,000.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 3456
- // Note: The `part_number` attribute is only applicable to the
- // [upload-part](https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part.html)
- // and
- // [upload-part-copy](https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part-copy.html)
- // operations.
- // The `part_number` attribute corresponds to the `--part-number` parameter
- // of the
- // [upload-part operation within the S3
- // API](https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part.html).
- AWSS3PartNumberKey = attribute.Key("aws.s3.part_number")
-
- // AWSS3UploadIDKey is the attribute Key conforming to the
- // "aws.s3.upload_id" semantic conventions. It represents the upload ID
- // that identifies the multipart upload.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'dfRtDYWFbkRONycy.Yxwh66Yjlx.cph0gtNBtJ'
- // Note: The `upload_id` attribute applies to S3 multipart-upload
- // operations and corresponds to the `--upload-id` parameter
- // of the [S3
- // API](https://docs.aws.amazon.com/cli/latest/reference/s3api/index.html)
- // multipart operations.
- // This applies in particular to the following operations:
- //
- // -
- // [abort-multipart-upload](https://docs.aws.amazon.com/cli/latest/reference/s3api/abort-multipart-upload.html)
- // -
- // [complete-multipart-upload](https://docs.aws.amazon.com/cli/latest/reference/s3api/complete-multipart-upload.html)
- // -
- // [list-parts](https://docs.aws.amazon.com/cli/latest/reference/s3api/list-parts.html)
- // -
- // [upload-part](https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part.html)
- // -
- // [upload-part-copy](https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part-copy.html)
- AWSS3UploadIDKey = attribute.Key("aws.s3.upload_id")
-)
-
-// AWSS3Bucket returns an attribute KeyValue conforming to the
-// "aws.s3.bucket" semantic conventions. It represents the S3 bucket name the
-// request refers to. Corresponds to the `--bucket` parameter of the [S3
-// API](https://docs.aws.amazon.com/cli/latest/reference/s3api/index.html)
-// operations.
-func AWSS3Bucket(val string) attribute.KeyValue {
- return AWSS3BucketKey.String(val)
-}
-
-// AWSS3CopySource returns an attribute KeyValue conforming to the
-// "aws.s3.copy_source" semantic conventions. It represents the source object
-// (in the form `bucket`/`key`) for the copy operation.
-func AWSS3CopySource(val string) attribute.KeyValue {
- return AWSS3CopySourceKey.String(val)
-}
-
-// AWSS3Delete returns an attribute KeyValue conforming to the
-// "aws.s3.delete" semantic conventions. It represents the delete request
-// container that specifies the objects to be deleted.
-func AWSS3Delete(val string) attribute.KeyValue {
- return AWSS3DeleteKey.String(val)
-}
-
-// AWSS3Key returns an attribute KeyValue conforming to the "aws.s3.key"
-// semantic conventions. It represents the S3 object key the request refers to.
-// Corresponds to the `--key` parameter of the [S3
-// API](https://docs.aws.amazon.com/cli/latest/reference/s3api/index.html)
-// operations.
-func AWSS3Key(val string) attribute.KeyValue {
- return AWSS3KeyKey.String(val)
-}
-
-// AWSS3PartNumber returns an attribute KeyValue conforming to the
-// "aws.s3.part_number" semantic conventions. It represents the part number of
-// the part being uploaded in a multipart-upload operation. This is a positive
-// integer between 1 and 10,000.
-func AWSS3PartNumber(val int) attribute.KeyValue {
- return AWSS3PartNumberKey.Int(val)
-}
-
-// AWSS3UploadID returns an attribute KeyValue conforming to the
-// "aws.s3.upload_id" semantic conventions. It represents the upload ID that
-// identifies the multipart upload.
-func AWSS3UploadID(val string) attribute.KeyValue {
- return AWSS3UploadIDKey.String(val)
-}
-
-// The web browser attributes
-const (
- // BrowserBrandsKey is the attribute Key conforming to the "browser.brands"
- // semantic conventions. It represents the array of brand name and version
- // separated by a space
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: ' Not A;Brand 99', 'Chromium 99', 'Chrome 99'
- // Note: This value is intended to be taken from the [UA client hints
- // API](https://wicg.github.io/ua-client-hints/#interface)
- // (`navigator.userAgentData.brands`).
- BrowserBrandsKey = attribute.Key("browser.brands")
-
- // BrowserLanguageKey is the attribute Key conforming to the
- // "browser.language" semantic conventions. It represents the preferred
- // language of the user using the browser
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'en', 'en-US', 'fr', 'fr-FR'
- // Note: This value is intended to be taken from the Navigator API
- // `navigator.language`.
- BrowserLanguageKey = attribute.Key("browser.language")
-
- // BrowserMobileKey is the attribute Key conforming to the "browser.mobile"
- // semantic conventions. It represents a boolean that is true if the
- // browser is running on a mobile device
- //
- // Type: boolean
- // RequirementLevel: Optional
- // Stability: experimental
- // Note: This value is intended to be taken from the [UA client hints
- // API](https://wicg.github.io/ua-client-hints/#interface)
- // (`navigator.userAgentData.mobile`). If unavailable, this attribute
- // SHOULD be left unset.
- BrowserMobileKey = attribute.Key("browser.mobile")
-
- // BrowserPlatformKey is the attribute Key conforming to the
- // "browser.platform" semantic conventions. It represents the platform on
- // which the browser is running
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'Windows', 'macOS', 'Android'
- // Note: This value is intended to be taken from the [UA client hints
- // API](https://wicg.github.io/ua-client-hints/#interface)
- // (`navigator.userAgentData.platform`). If unavailable, the legacy
- // `navigator.platform` API SHOULD NOT be used instead and this attribute
- // SHOULD be left unset in order for the values to be consistent.
- // The list of possible values is defined in the [W3C User-Agent Client
- // Hints
- // specification](https://wicg.github.io/ua-client-hints/#sec-ch-ua-platform).
- // Note that some (but not all) of these values can overlap with values in
- // the [`os.type` and `os.name` attributes](./os.md). However, for
- // consistency, the values in the `browser.platform` attribute should
- // capture the exact value that the user agent provides.
- BrowserPlatformKey = attribute.Key("browser.platform")
-)
-
-// BrowserBrands returns an attribute KeyValue conforming to the
-// "browser.brands" semantic conventions. It represents the array of brand name
-// and version separated by a space
-func BrowserBrands(val ...string) attribute.KeyValue {
- return BrowserBrandsKey.StringSlice(val)
-}
-
-// BrowserLanguage returns an attribute KeyValue conforming to the
-// "browser.language" semantic conventions. It represents the preferred
-// language of the user using the browser
-func BrowserLanguage(val string) attribute.KeyValue {
- return BrowserLanguageKey.String(val)
-}
-
-// BrowserMobile returns an attribute KeyValue conforming to the
-// "browser.mobile" semantic conventions. It represents a boolean that is true
-// if the browser is running on a mobile device
-func BrowserMobile(val bool) attribute.KeyValue {
- return BrowserMobileKey.Bool(val)
-}
-
-// BrowserPlatform returns an attribute KeyValue conforming to the
-// "browser.platform" semantic conventions. It represents the platform on which
-// the browser is running
-func BrowserPlatform(val string) attribute.KeyValue {
- return BrowserPlatformKey.String(val)
-}
-
-// These attributes may be used to describe the client in a connection-based
-// network interaction where there is one side that initiates the connection
-// (the client is the side that initiates the connection). This covers all TCP
-// network interactions since TCP is connection-based and one side initiates
-// the connection (an exception is made for peer-to-peer communication over TCP
-// where the "user-facing" surface of the protocol / API doesn't expose a clear
-// notion of client and server). This also covers UDP network interactions
-// where one side initiates the interaction, e.g. QUIC (HTTP/3) and DNS.
-const (
- // ClientAddressKey is the attribute Key conforming to the "client.address"
- // semantic conventions. It represents the client address - domain name if
- // available without reverse DNS lookup; otherwise, IP address or Unix
- // domain socket name.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'client.example.com', '10.1.2.80', '/tmp/my.sock'
- // Note: When observed from the server side, and when communicating through
- // an intermediary, `client.address` SHOULD represent the client address
- // behind any intermediaries, for example proxies, if it's available.
- ClientAddressKey = attribute.Key("client.address")
-
- // ClientPortKey is the attribute Key conforming to the "client.port"
- // semantic conventions. It represents the client port number.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 65123
- // Note: When observed from the server side, and when communicating through
- // an intermediary, `client.port` SHOULD represent the client port behind
- // any intermediaries, for example proxies, if it's available.
- ClientPortKey = attribute.Key("client.port")
-)
-
-// ClientAddress returns an attribute KeyValue conforming to the
-// "client.address" semantic conventions. It represents the client address -
-// domain name if available without reverse DNS lookup; otherwise, IP address
-// or Unix domain socket name.
-func ClientAddress(val string) attribute.KeyValue {
- return ClientAddressKey.String(val)
-}
-
-// ClientPort returns an attribute KeyValue conforming to the "client.port"
-// semantic conventions. It represents the client port number.
-func ClientPort(val int) attribute.KeyValue {
- return ClientPortKey.Int(val)
-}
-
-// A cloud environment (e.g. GCP, Azure, AWS).
-const (
- // CloudAccountIDKey is the attribute Key conforming to the
- // "cloud.account.id" semantic conventions. It represents the cloud account
- // ID the resource is assigned to.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '111111111111', 'opentelemetry'
- CloudAccountIDKey = attribute.Key("cloud.account.id")
-
- // CloudAvailabilityZoneKey is the attribute Key conforming to the
- // "cloud.availability_zone" semantic conventions. It represents the cloud
- // regions often have multiple, isolated locations known as zones to
- // increase availability. Availability zone represents the zone where the
- // resource is running.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'us-east-1c'
- // Note: Availability zones are called "zones" on Alibaba Cloud and Google
- // Cloud.
- CloudAvailabilityZoneKey = attribute.Key("cloud.availability_zone")
-
- // CloudPlatformKey is the attribute Key conforming to the "cloud.platform"
- // semantic conventions. It represents the cloud platform in use.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- // Note: The prefix of the service SHOULD match the one specified in
- // `cloud.provider`.
- CloudPlatformKey = attribute.Key("cloud.platform")
-
- // CloudProviderKey is the attribute Key conforming to the "cloud.provider"
- // semantic conventions. It represents the name of the cloud provider.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- CloudProviderKey = attribute.Key("cloud.provider")
-
- // CloudRegionKey is the attribute Key conforming to the "cloud.region"
- // semantic conventions. It represents the geographical region the resource
- // is running.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'us-central1', 'us-east-1'
- // Note: Refer to your provider's docs to see the available regions, for
- // example [Alibaba Cloud
- // regions](https://www.alibabacloud.com/help/doc-detail/40654.htm), [AWS
- // regions](https://aws.amazon.com/about-aws/global-infrastructure/regions_az/),
- // [Azure
- // regions](https://azure.microsoft.com/global-infrastructure/geographies/),
- // [Google Cloud regions](https://cloud.google.com/about/locations), or
- // [Tencent Cloud
- // regions](https://www.tencentcloud.com/document/product/213/6091).
- CloudRegionKey = attribute.Key("cloud.region")
-
- // CloudResourceIDKey is the attribute Key conforming to the
- // "cloud.resource_id" semantic conventions. It represents the cloud
- // provider-specific native identifier of the monitored cloud resource
- // (e.g. an
- // [ARN](https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html)
- // on AWS, a [fully qualified resource
- // ID](https://learn.microsoft.com/rest/api/resources/resources/get-by-id)
- // on Azure, a [full resource
- // name](https://cloud.google.com/apis/design/resource_names#full_resource_name)
- // on GCP)
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'arn:aws:lambda:REGION:ACCOUNT_ID:function:my-function',
- // '//run.googleapis.com/projects/PROJECT_ID/locations/LOCATION_ID/services/SERVICE_ID',
- // '/subscriptions//resourceGroups//providers/Microsoft.Web/sites//functions/'
- // Note: On some cloud providers, it may not be possible to determine the
- // full ID at startup,
- // so it may be necessary to set `cloud.resource_id` as a span attribute
- // instead.
- //
- // The exact value to use for `cloud.resource_id` depends on the cloud
- // provider.
- // The following well-known definitions MUST be used if you set this
- // attribute and they apply:
- //
- // * **AWS Lambda:** The function
- // [ARN](https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html).
- // Take care not to use the "invoked ARN" directly but replace any
- // [alias
- // suffix](https://docs.aws.amazon.com/lambda/latest/dg/configuration-aliases.html)
- // with the resolved function version, as the same runtime instance may
- // be invokable with
- // multiple different aliases.
- // * **GCP:** The [URI of the
- // resource](https://cloud.google.com/iam/docs/full-resource-names)
- // * **Azure:** The [Fully Qualified Resource
- // ID](https://docs.microsoft.com/rest/api/resources/resources/get-by-id)
- // of the invoked function,
- // *not* the function app, having the form
- // `/subscriptions//resourceGroups//providers/Microsoft.Web/sites//functions/`.
- // This means that a span attribute MUST be used, as an Azure function
- // app can host multiple functions that would usually share
- // a TracerProvider.
- CloudResourceIDKey = attribute.Key("cloud.resource_id")
-)
-
-var (
- // Alibaba Cloud Elastic Compute Service
- CloudPlatformAlibabaCloudECS = CloudPlatformKey.String("alibaba_cloud_ecs")
- // Alibaba Cloud Function Compute
- CloudPlatformAlibabaCloudFc = CloudPlatformKey.String("alibaba_cloud_fc")
- // Red Hat OpenShift on Alibaba Cloud
- CloudPlatformAlibabaCloudOpenshift = CloudPlatformKey.String("alibaba_cloud_openshift")
- // AWS Elastic Compute Cloud
- CloudPlatformAWSEC2 = CloudPlatformKey.String("aws_ec2")
- // AWS Elastic Container Service
- CloudPlatformAWSECS = CloudPlatformKey.String("aws_ecs")
- // AWS Elastic Kubernetes Service
- CloudPlatformAWSEKS = CloudPlatformKey.String("aws_eks")
- // AWS Lambda
- CloudPlatformAWSLambda = CloudPlatformKey.String("aws_lambda")
- // AWS Elastic Beanstalk
- CloudPlatformAWSElasticBeanstalk = CloudPlatformKey.String("aws_elastic_beanstalk")
- // AWS App Runner
- CloudPlatformAWSAppRunner = CloudPlatformKey.String("aws_app_runner")
- // Red Hat OpenShift on AWS (ROSA)
- CloudPlatformAWSOpenshift = CloudPlatformKey.String("aws_openshift")
- // Azure Virtual Machines
- CloudPlatformAzureVM = CloudPlatformKey.String("azure_vm")
- // Azure Container Apps
- CloudPlatformAzureContainerApps = CloudPlatformKey.String("azure_container_apps")
- // Azure Container Instances
- CloudPlatformAzureContainerInstances = CloudPlatformKey.String("azure_container_instances")
- // Azure Kubernetes Service
- CloudPlatformAzureAKS = CloudPlatformKey.String("azure_aks")
- // Azure Functions
- CloudPlatformAzureFunctions = CloudPlatformKey.String("azure_functions")
- // Azure App Service
- CloudPlatformAzureAppService = CloudPlatformKey.String("azure_app_service")
- // Azure Red Hat OpenShift
- CloudPlatformAzureOpenshift = CloudPlatformKey.String("azure_openshift")
- // Google Bare Metal Solution (BMS)
- CloudPlatformGCPBareMetalSolution = CloudPlatformKey.String("gcp_bare_metal_solution")
- // Google Cloud Compute Engine (GCE)
- CloudPlatformGCPComputeEngine = CloudPlatformKey.String("gcp_compute_engine")
- // Google Cloud Run
- CloudPlatformGCPCloudRun = CloudPlatformKey.String("gcp_cloud_run")
- // Google Cloud Kubernetes Engine (GKE)
- CloudPlatformGCPKubernetesEngine = CloudPlatformKey.String("gcp_kubernetes_engine")
- // Google Cloud Functions (GCF)
- CloudPlatformGCPCloudFunctions = CloudPlatformKey.String("gcp_cloud_functions")
- // Google Cloud App Engine (GAE)
- CloudPlatformGCPAppEngine = CloudPlatformKey.String("gcp_app_engine")
- // Red Hat OpenShift on Google Cloud
- CloudPlatformGCPOpenshift = CloudPlatformKey.String("gcp_openshift")
- // Red Hat OpenShift on IBM Cloud
- CloudPlatformIbmCloudOpenshift = CloudPlatformKey.String("ibm_cloud_openshift")
- // Tencent Cloud Cloud Virtual Machine (CVM)
- CloudPlatformTencentCloudCvm = CloudPlatformKey.String("tencent_cloud_cvm")
- // Tencent Cloud Elastic Kubernetes Service (EKS)
- CloudPlatformTencentCloudEKS = CloudPlatformKey.String("tencent_cloud_eks")
- // Tencent Cloud Serverless Cloud Function (SCF)
- CloudPlatformTencentCloudScf = CloudPlatformKey.String("tencent_cloud_scf")
-)
-
-var (
- // Alibaba Cloud
- CloudProviderAlibabaCloud = CloudProviderKey.String("alibaba_cloud")
- // Amazon Web Services
- CloudProviderAWS = CloudProviderKey.String("aws")
- // Microsoft Azure
- CloudProviderAzure = CloudProviderKey.String("azure")
- // Google Cloud Platform
- CloudProviderGCP = CloudProviderKey.String("gcp")
- // Heroku Platform as a Service
- CloudProviderHeroku = CloudProviderKey.String("heroku")
- // IBM Cloud
- CloudProviderIbmCloud = CloudProviderKey.String("ibm_cloud")
- // Tencent Cloud
- CloudProviderTencentCloud = CloudProviderKey.String("tencent_cloud")
-)
-
-// CloudAccountID returns an attribute KeyValue conforming to the
-// "cloud.account.id" semantic conventions. It represents the cloud account ID
-// the resource is assigned to.
-func CloudAccountID(val string) attribute.KeyValue {
- return CloudAccountIDKey.String(val)
-}
-
-// CloudAvailabilityZone returns an attribute KeyValue conforming to the
-// "cloud.availability_zone" semantic conventions. It represents the cloud
-// regions often have multiple, isolated locations known as zones to increase
-// availability. Availability zone represents the zone where the resource is
-// running.
-func CloudAvailabilityZone(val string) attribute.KeyValue {
- return CloudAvailabilityZoneKey.String(val)
-}
-
-// CloudRegion returns an attribute KeyValue conforming to the
-// "cloud.region" semantic conventions. It represents the geographical region
-// the resource is running.
-func CloudRegion(val string) attribute.KeyValue {
- return CloudRegionKey.String(val)
-}
-
-// CloudResourceID returns an attribute KeyValue conforming to the
-// "cloud.resource_id" semantic conventions. It represents the cloud
-// provider-specific native identifier of the monitored cloud resource (e.g. an
-// [ARN](https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html)
-// on AWS, a [fully qualified resource
-// ID](https://learn.microsoft.com/rest/api/resources/resources/get-by-id) on
-// Azure, a [full resource
-// name](https://cloud.google.com/apis/design/resource_names#full_resource_name)
-// on GCP)
-func CloudResourceID(val string) attribute.KeyValue {
- return CloudResourceIDKey.String(val)
-}
-
-// Attributes for CloudEvents.
-const (
- // CloudeventsEventIDKey is the attribute Key conforming to the
- // "cloudevents.event_id" semantic conventions. It represents the
- // [event_id](https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#id)
- // uniquely identifies the event.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '123e4567-e89b-12d3-a456-426614174000', '0001'
- CloudeventsEventIDKey = attribute.Key("cloudevents.event_id")
-
- // CloudeventsEventSourceKey is the attribute Key conforming to the
- // "cloudevents.event_source" semantic conventions. It represents the
- // [source](https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#source-1)
- // identifies the context in which an event happened.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'https://github.com/cloudevents',
- // '/cloudevents/spec/pull/123', 'my-service'
- CloudeventsEventSourceKey = attribute.Key("cloudevents.event_source")
-
- // CloudeventsEventSpecVersionKey is the attribute Key conforming to the
- // "cloudevents.event_spec_version" semantic conventions. It represents the
- // [version of the CloudEvents
- // specification](https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#specversion)
- // which the event uses.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '1.0'
- CloudeventsEventSpecVersionKey = attribute.Key("cloudevents.event_spec_version")
-
- // CloudeventsEventSubjectKey is the attribute Key conforming to the
- // "cloudevents.event_subject" semantic conventions. It represents the
- // [subject](https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#subject)
- // of the event in the context of the event producer (identified by
- // source).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'mynewfile.jpg'
- CloudeventsEventSubjectKey = attribute.Key("cloudevents.event_subject")
-
- // CloudeventsEventTypeKey is the attribute Key conforming to the
- // "cloudevents.event_type" semantic conventions. It represents the
- // [event_type](https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#type)
- // contains a value describing the type of event related to the originating
- // occurrence.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'com.github.pull_request.opened',
- // 'com.example.object.deleted.v2'
- CloudeventsEventTypeKey = attribute.Key("cloudevents.event_type")
-)
-
-// CloudeventsEventID returns an attribute KeyValue conforming to the
-// "cloudevents.event_id" semantic conventions. It represents the
-// [event_id](https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#id)
-// uniquely identifies the event.
-func CloudeventsEventID(val string) attribute.KeyValue {
- return CloudeventsEventIDKey.String(val)
-}
-
-// CloudeventsEventSource returns an attribute KeyValue conforming to the
-// "cloudevents.event_source" semantic conventions. It represents the
-// [source](https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#source-1)
-// identifies the context in which an event happened.
-func CloudeventsEventSource(val string) attribute.KeyValue {
- return CloudeventsEventSourceKey.String(val)
-}
-
-// CloudeventsEventSpecVersion returns an attribute KeyValue conforming to
-// the "cloudevents.event_spec_version" semantic conventions. It represents the
-// [version of the CloudEvents
-// specification](https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#specversion)
-// which the event uses.
-func CloudeventsEventSpecVersion(val string) attribute.KeyValue {
- return CloudeventsEventSpecVersionKey.String(val)
-}
-
-// CloudeventsEventSubject returns an attribute KeyValue conforming to the
-// "cloudevents.event_subject" semantic conventions. It represents the
-// [subject](https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#subject)
-// of the event in the context of the event producer (identified by source).
-func CloudeventsEventSubject(val string) attribute.KeyValue {
- return CloudeventsEventSubjectKey.String(val)
-}
-
-// CloudeventsEventType returns an attribute KeyValue conforming to the
-// "cloudevents.event_type" semantic conventions. It represents the
-// [event_type](https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#type)
-// contains a value describing the type of event related to the originating
-// occurrence.
-func CloudeventsEventType(val string) attribute.KeyValue {
- return CloudeventsEventTypeKey.String(val)
-}
-
-// These attributes allow to report this unit of code and therefore to provide
-// more context about the span.
-const (
- // CodeColumnKey is the attribute Key conforming to the "code.column"
- // semantic conventions. It represents the column number in `code.filepath`
- // best representing the operation. It SHOULD point within the code unit
- // named in `code.function`.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 16
- CodeColumnKey = attribute.Key("code.column")
-
- // CodeFilepathKey is the attribute Key conforming to the "code.filepath"
- // semantic conventions. It represents the source code file name that
- // identifies the code unit as uniquely as possible (preferably an absolute
- // file path).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '/usr/local/MyApplication/content_root/app/index.php'
- CodeFilepathKey = attribute.Key("code.filepath")
-
- // CodeFunctionKey is the attribute Key conforming to the "code.function"
- // semantic conventions. It represents the method or function name, or
- // equivalent (usually rightmost part of the code unit's name).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'serveRequest'
- CodeFunctionKey = attribute.Key("code.function")
-
- // CodeLineNumberKey is the attribute Key conforming to the "code.lineno"
- // semantic conventions. It represents the line number in `code.filepath`
- // best representing the operation. It SHOULD point within the code unit
- // named in `code.function`.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 42
- CodeLineNumberKey = attribute.Key("code.lineno")
-
- // CodeNamespaceKey is the attribute Key conforming to the "code.namespace"
- // semantic conventions. It represents the "namespace" within which
- // `code.function` is defined. Usually the qualified class or module name,
- // such that `code.namespace` + some separator + `code.function` form a
- // unique identifier for the code unit.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'com.example.MyHTTPService'
- CodeNamespaceKey = attribute.Key("code.namespace")
-
- // CodeStacktraceKey is the attribute Key conforming to the
- // "code.stacktrace" semantic conventions. It represents a stacktrace as a
- // string in the natural representation for the language runtime. The
- // representation is to be determined and documented by each language SIG.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'at
- // com.example.GenerateTrace.methodB(GenerateTrace.java:13)\\n at '
- // 'com.example.GenerateTrace.methodA(GenerateTrace.java:9)\\n at '
- // 'com.example.GenerateTrace.main(GenerateTrace.java:5)'
- CodeStacktraceKey = attribute.Key("code.stacktrace")
-)
-
-// CodeColumn returns an attribute KeyValue conforming to the "code.column"
-// semantic conventions. It represents the column number in `code.filepath`
-// best representing the operation. It SHOULD point within the code unit named
-// in `code.function`.
-func CodeColumn(val int) attribute.KeyValue {
- return CodeColumnKey.Int(val)
-}
-
-// CodeFilepath returns an attribute KeyValue conforming to the
-// "code.filepath" semantic conventions. It represents the source code file
-// name that identifies the code unit as uniquely as possible (preferably an
-// absolute file path).
-func CodeFilepath(val string) attribute.KeyValue {
- return CodeFilepathKey.String(val)
-}
-
-// CodeFunction returns an attribute KeyValue conforming to the
-// "code.function" semantic conventions. It represents the method or function
-// name, or equivalent (usually rightmost part of the code unit's name).
-func CodeFunction(val string) attribute.KeyValue {
- return CodeFunctionKey.String(val)
-}
-
-// CodeLineNumber returns an attribute KeyValue conforming to the "code.lineno"
-// semantic conventions. It represents the line number in `code.filepath` best
-// representing the operation. It SHOULD point within the code unit named in
-// `code.function`.
-func CodeLineNumber(val int) attribute.KeyValue {
- return CodeLineNumberKey.Int(val)
-}
-
-// CodeNamespace returns an attribute KeyValue conforming to the
-// "code.namespace" semantic conventions. It represents the "namespace" within
-// which `code.function` is defined. Usually the qualified class or module
-// name, such that `code.namespace` + some separator + `code.function` form a
-// unique identifier for the code unit.
-func CodeNamespace(val string) attribute.KeyValue {
- return CodeNamespaceKey.String(val)
-}
-
-// CodeStacktrace returns an attribute KeyValue conforming to the
-// "code.stacktrace" semantic conventions. It represents a stacktrace as a
-// string in the natural representation for the language runtime. The
-// representation is to be determined and documented by each language SIG.
-func CodeStacktrace(val string) attribute.KeyValue {
- return CodeStacktraceKey.String(val)
-}
-
-// A container instance.
-const (
- // ContainerCommandKey is the attribute Key conforming to the
- // "container.command" semantic conventions. It represents the command used
- // to run the container (i.e. the command name).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'otelcontribcol'
- // Note: If using embedded credentials or sensitive data, it is recommended
- // to remove them to prevent potential leakage.
- ContainerCommandKey = attribute.Key("container.command")
-
- // ContainerCommandArgsKey is the attribute Key conforming to the
- // "container.command_args" semantic conventions. It represents the all the
- // command arguments (including the command/executable itself) run by the
- // container. [2]
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'otelcontribcol, --config, config.yaml'
- ContainerCommandArgsKey = attribute.Key("container.command_args")
-
- // ContainerCommandLineKey is the attribute Key conforming to the
- // "container.command_line" semantic conventions. It represents the full
- // command run by the container as a single string representing the full
- // command. [2]
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'otelcontribcol --config config.yaml'
- ContainerCommandLineKey = attribute.Key("container.command_line")
-
- // ContainerCPUStateKey is the attribute Key conforming to the
- // "container.cpu.state" semantic conventions. It represents the CPU state
- // for this data point.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'user', 'kernel'
- ContainerCPUStateKey = attribute.Key("container.cpu.state")
-
- // ContainerIDKey is the attribute Key conforming to the "container.id"
- // semantic conventions. It represents the container ID. Usually a UUID, as
- // for example used to [identify Docker
- // containers](https://docs.docker.com/engine/reference/run/#container-identification).
- // The UUID might be abbreviated.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'a3bf90e006b2'
- ContainerIDKey = attribute.Key("container.id")
-
- // ContainerImageIDKey is the attribute Key conforming to the
- // "container.image.id" semantic conventions. It represents the runtime
- // specific image identifier. Usually a hash algorithm followed by a UUID.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples:
- // 'sha256:19c92d0a00d1b66d897bceaa7319bee0dd38a10a851c60bcec9474aa3f01e50f'
- // Note: Docker defines a sha256 of the image id; `container.image.id`
- // corresponds to the `Image` field from the Docker container inspect
- // [API](https://docs.docker.com/engine/api/v1.43/#tag/Container/operation/ContainerInspect)
- // endpoint.
- // K8S defines a link to the container registry repository with digest
- // `"imageID": "registry.azurecr.io
- // /namespace/service/dockerfile@sha256:bdeabd40c3a8a492eaf9e8e44d0ebbb84bac7ee25ac0cf8a7159d25f62555625"`.
- // The ID is assigned by the container runtime and can vary in different
- // environments. Consider using `oci.manifest.digest` if it is important to
- // identify the same image in different environments/runtimes.
- ContainerImageIDKey = attribute.Key("container.image.id")
-
- // ContainerImageNameKey is the attribute Key conforming to the
- // "container.image.name" semantic conventions. It represents the name of
- // the image the container was built on.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'gcr.io/opentelemetry/operator'
- ContainerImageNameKey = attribute.Key("container.image.name")
-
- // ContainerImageRepoDigestsKey is the attribute Key conforming to the
- // "container.image.repo_digests" semantic conventions. It represents the
- // repo digests of the container image as provided by the container
- // runtime.
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples:
- // 'example@sha256:afcc7f1ac1b49db317a7196c902e61c6c3c4607d63599ee1a82d702d249a0ccb',
- // 'internal.registry.example.com:5000/example@sha256:b69959407d21e8a062e0416bf13405bb2b71ed7a84dde4158ebafacfa06f5578'
- // Note:
- // [Docker](https://docs.docker.com/engine/api/v1.43/#tag/Image/operation/ImageInspect)
- // and
- // [CRI](https://github.com/kubernetes/cri-api/blob/c75ef5b473bbe2d0a4fc92f82235efd665ea8e9f/pkg/apis/runtime/v1/api.proto#L1237-L1238)
- // report those under the `RepoDigests` field.
- ContainerImageRepoDigestsKey = attribute.Key("container.image.repo_digests")
-
- // ContainerImageTagsKey is the attribute Key conforming to the
- // "container.image.tags" semantic conventions. It represents the container
- // image tags. An example can be found in [Docker Image
- // Inspect](https://docs.docker.com/engine/api/v1.43/#tag/Image/operation/ImageInspect).
- // Should be only the `` section of the full name for example from
- // `registry.example.com/my-org/my-image:`.
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'v1.27.1', '3.5.7-0'
- ContainerImageTagsKey = attribute.Key("container.image.tags")
-
- // ContainerNameKey is the attribute Key conforming to the "container.name"
- // semantic conventions. It represents the container name used by container
- // runtime.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'opentelemetry-autoconf'
- ContainerNameKey = attribute.Key("container.name")
-
- // ContainerRuntimeKey is the attribute Key conforming to the
- // "container.runtime" semantic conventions. It represents the container
- // runtime managing this container.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'docker', 'containerd', 'rkt'
- ContainerRuntimeKey = attribute.Key("container.runtime")
-)
-
-var (
- // When tasks of the cgroup are in user mode (Linux). When all container processes are in user mode (Windows)
- ContainerCPUStateUser = ContainerCPUStateKey.String("user")
- // When CPU is used by the system (host OS)
- ContainerCPUStateSystem = ContainerCPUStateKey.String("system")
- // When tasks of the cgroup are in kernel mode (Linux). When all container processes are in kernel mode (Windows)
- ContainerCPUStateKernel = ContainerCPUStateKey.String("kernel")
-)
-
-// ContainerCommand returns an attribute KeyValue conforming to the
-// "container.command" semantic conventions. It represents the command used to
-// run the container (i.e. the command name).
-func ContainerCommand(val string) attribute.KeyValue {
- return ContainerCommandKey.String(val)
-}
-
-// ContainerCommandArgs returns an attribute KeyValue conforming to the
-// "container.command_args" semantic conventions. It represents the all the
-// command arguments (including the command/executable itself) run by the
-// container. [2]
-func ContainerCommandArgs(val ...string) attribute.KeyValue {
- return ContainerCommandArgsKey.StringSlice(val)
-}
-
-// ContainerCommandLine returns an attribute KeyValue conforming to the
-// "container.command_line" semantic conventions. It represents the full
-// command run by the container as a single string representing the full
-// command. [2]
-func ContainerCommandLine(val string) attribute.KeyValue {
- return ContainerCommandLineKey.String(val)
-}
-
-// ContainerID returns an attribute KeyValue conforming to the
-// "container.id" semantic conventions. It represents the container ID. Usually
-// a UUID, as for example used to [identify Docker
-// containers](https://docs.docker.com/engine/reference/run/#container-identification).
-// The UUID might be abbreviated.
-func ContainerID(val string) attribute.KeyValue {
- return ContainerIDKey.String(val)
-}
-
-// ContainerImageID returns an attribute KeyValue conforming to the
-// "container.image.id" semantic conventions. It represents the runtime
-// specific image identifier. Usually a hash algorithm followed by a UUID.
-func ContainerImageID(val string) attribute.KeyValue {
- return ContainerImageIDKey.String(val)
-}
-
-// ContainerImageName returns an attribute KeyValue conforming to the
-// "container.image.name" semantic conventions. It represents the name of the
-// image the container was built on.
-func ContainerImageName(val string) attribute.KeyValue {
- return ContainerImageNameKey.String(val)
-}
-
-// ContainerImageRepoDigests returns an attribute KeyValue conforming to the
-// "container.image.repo_digests" semantic conventions. It represents the repo
-// digests of the container image as provided by the container runtime.
-func ContainerImageRepoDigests(val ...string) attribute.KeyValue {
- return ContainerImageRepoDigestsKey.StringSlice(val)
-}
-
-// ContainerImageTags returns an attribute KeyValue conforming to the
-// "container.image.tags" semantic conventions. It represents the container
-// image tags. An example can be found in [Docker Image
-// Inspect](https://docs.docker.com/engine/api/v1.43/#tag/Image/operation/ImageInspect).
-// Should be only the `` section of the full name for example from
-// `registry.example.com/my-org/my-image:`.
-func ContainerImageTags(val ...string) attribute.KeyValue {
- return ContainerImageTagsKey.StringSlice(val)
-}
-
-// ContainerName returns an attribute KeyValue conforming to the
-// "container.name" semantic conventions. It represents the container name used
-// by container runtime.
-func ContainerName(val string) attribute.KeyValue {
- return ContainerNameKey.String(val)
-}
-
-// ContainerRuntime returns an attribute KeyValue conforming to the
-// "container.runtime" semantic conventions. It represents the container
-// runtime managing this container.
-func ContainerRuntime(val string) attribute.KeyValue {
- return ContainerRuntimeKey.String(val)
-}
-
-// This group defines the attributes used to describe telemetry in the context
-// of databases.
-const (
- // DBClientConnectionsPoolNameKey is the attribute Key conforming to the
- // "db.client.connections.pool.name" semantic conventions. It represents
- // the name of the connection pool; unique within the instrumented
- // application. In case the connection pool implementation doesn't provide
- // a name, instrumentation should use a combination of `server.address` and
- // `server.port` attributes formatted as `server.address:server.port`.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'myDataSource'
- DBClientConnectionsPoolNameKey = attribute.Key("db.client.connections.pool.name")
-
- // DBClientConnectionsStateKey is the attribute Key conforming to the
- // "db.client.connections.state" semantic conventions. It represents the
- // state of a connection in the pool
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'idle'
- DBClientConnectionsStateKey = attribute.Key("db.client.connections.state")
-
- // DBCollectionNameKey is the attribute Key conforming to the
- // "db.collection.name" semantic conventions. It represents the name of a
- // collection (table, container) within the database.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'public.users', 'customers'
- // Note: If the collection name is parsed from the query, it SHOULD match
- // the value provided in the query and may be qualified with the schema and
- // database name.
- // It is RECOMMENDED to capture the value as provided by the application
- // without attempting to do any case normalization.
- DBCollectionNameKey = attribute.Key("db.collection.name")
-
- // DBNamespaceKey is the attribute Key conforming to the "db.namespace"
- // semantic conventions. It represents the name of the database, fully
- // qualified within the server address and port.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'customers', 'test.users'
- // Note: If a database system has multiple namespace components, they
- // SHOULD be concatenated (potentially using database system specific
- // conventions) from most general to most specific namespace component, and
- // more specific namespaces SHOULD NOT be captured without the more general
- // namespaces, to ensure that "startswith" queries for the more general
- // namespaces will be valid.
- // Semantic conventions for individual database systems SHOULD document
- // what `db.namespace` means in the context of that system.
- // It is RECOMMENDED to capture the value as provided by the application
- // without attempting to do any case normalization.
- DBNamespaceKey = attribute.Key("db.namespace")
-
- // DBOperationNameKey is the attribute Key conforming to the
- // "db.operation.name" semantic conventions. It represents the name of the
- // operation or command being executed.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'findAndModify', 'HMSET', 'SELECT'
- // Note: It is RECOMMENDED to capture the value as provided by the
- // application without attempting to do any case normalization.
- DBOperationNameKey = attribute.Key("db.operation.name")
-
- // DBQueryTextKey is the attribute Key conforming to the "db.query.text"
- // semantic conventions. It represents the database query being executed.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'SELECT * FROM wuser_table where username = ?', 'SET mykey
- // "WuValue"'
- DBQueryTextKey = attribute.Key("db.query.text")
-
- // DBSystemKey is the attribute Key conforming to the "db.system" semantic
- // conventions. It represents the database management system (DBMS) product
- // as identified by the client instrumentation.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- // Note: The actual DBMS may differ from the one identified by the client.
- // For example, when using PostgreSQL client libraries to connect to a
- // CockroachDB, the `db.system` is set to `postgresql` based on the
- // instrumentation's best knowledge.
- DBSystemKey = attribute.Key("db.system")
-)
-
-var (
- // idle
- DBClientConnectionsStateIdle = DBClientConnectionsStateKey.String("idle")
- // used
- DBClientConnectionsStateUsed = DBClientConnectionsStateKey.String("used")
-)
-
-var (
- // Some other SQL database. Fallback only. See notes
- DBSystemOtherSQL = DBSystemKey.String("other_sql")
- // Microsoft SQL Server
- DBSystemMSSQL = DBSystemKey.String("mssql")
- // Microsoft SQL Server Compact
- DBSystemMssqlcompact = DBSystemKey.String("mssqlcompact")
- // MySQL
- DBSystemMySQL = DBSystemKey.String("mysql")
- // Oracle Database
- DBSystemOracle = DBSystemKey.String("oracle")
- // IBM DB2
- DBSystemDB2 = DBSystemKey.String("db2")
- // PostgreSQL
- DBSystemPostgreSQL = DBSystemKey.String("postgresql")
- // Amazon Redshift
- DBSystemRedshift = DBSystemKey.String("redshift")
- // Apache Hive
- DBSystemHive = DBSystemKey.String("hive")
- // Cloudscape
- DBSystemCloudscape = DBSystemKey.String("cloudscape")
- // HyperSQL DataBase
- DBSystemHSQLDB = DBSystemKey.String("hsqldb")
- // Progress Database
- DBSystemProgress = DBSystemKey.String("progress")
- // SAP MaxDB
- DBSystemMaxDB = DBSystemKey.String("maxdb")
- // SAP HANA
- DBSystemHanaDB = DBSystemKey.String("hanadb")
- // Ingres
- DBSystemIngres = DBSystemKey.String("ingres")
- // FirstSQL
- DBSystemFirstSQL = DBSystemKey.String("firstsql")
- // EnterpriseDB
- DBSystemEDB = DBSystemKey.String("edb")
- // InterSystems Caché
- DBSystemCache = DBSystemKey.String("cache")
- // Adabas (Adaptable Database System)
- DBSystemAdabas = DBSystemKey.String("adabas")
- // Firebird
- DBSystemFirebird = DBSystemKey.String("firebird")
- // Apache Derby
- DBSystemDerby = DBSystemKey.String("derby")
- // FileMaker
- DBSystemFilemaker = DBSystemKey.String("filemaker")
- // Informix
- DBSystemInformix = DBSystemKey.String("informix")
- // InstantDB
- DBSystemInstantDB = DBSystemKey.String("instantdb")
- // InterBase
- DBSystemInterbase = DBSystemKey.String("interbase")
- // MariaDB
- DBSystemMariaDB = DBSystemKey.String("mariadb")
- // Netezza
- DBSystemNetezza = DBSystemKey.String("netezza")
- // Pervasive PSQL
- DBSystemPervasive = DBSystemKey.String("pervasive")
- // PointBase
- DBSystemPointbase = DBSystemKey.String("pointbase")
- // SQLite
- DBSystemSqlite = DBSystemKey.String("sqlite")
- // Sybase
- DBSystemSybase = DBSystemKey.String("sybase")
- // Teradata
- DBSystemTeradata = DBSystemKey.String("teradata")
- // Vertica
- DBSystemVertica = DBSystemKey.String("vertica")
- // H2
- DBSystemH2 = DBSystemKey.String("h2")
- // ColdFusion IMQ
- DBSystemColdfusion = DBSystemKey.String("coldfusion")
- // Apache Cassandra
- DBSystemCassandra = DBSystemKey.String("cassandra")
- // Apache HBase
- DBSystemHBase = DBSystemKey.String("hbase")
- // MongoDB
- DBSystemMongoDB = DBSystemKey.String("mongodb")
- // Redis
- DBSystemRedis = DBSystemKey.String("redis")
- // Couchbase
- DBSystemCouchbase = DBSystemKey.String("couchbase")
- // CouchDB
- DBSystemCouchDB = DBSystemKey.String("couchdb")
- // Microsoft Azure Cosmos DB
- DBSystemCosmosDB = DBSystemKey.String("cosmosdb")
- // Amazon DynamoDB
- DBSystemDynamoDB = DBSystemKey.String("dynamodb")
- // Neo4j
- DBSystemNeo4j = DBSystemKey.String("neo4j")
- // Apache Geode
- DBSystemGeode = DBSystemKey.String("geode")
- // Elasticsearch
- DBSystemElasticsearch = DBSystemKey.String("elasticsearch")
- // Memcached
- DBSystemMemcached = DBSystemKey.String("memcached")
- // CockroachDB
- DBSystemCockroachdb = DBSystemKey.String("cockroachdb")
- // OpenSearch
- DBSystemOpensearch = DBSystemKey.String("opensearch")
- // ClickHouse
- DBSystemClickhouse = DBSystemKey.String("clickhouse")
- // Cloud Spanner
- DBSystemSpanner = DBSystemKey.String("spanner")
- // Trino
- DBSystemTrino = DBSystemKey.String("trino")
-)
-
-// DBClientConnectionsPoolName returns an attribute KeyValue conforming to
-// the "db.client.connections.pool.name" semantic conventions. It represents
-// the name of the connection pool; unique within the instrumented application.
-// In case the connection pool implementation doesn't provide a name,
-// instrumentation should use a combination of `server.address` and
-// `server.port` attributes formatted as `server.address:server.port`.
-func DBClientConnectionsPoolName(val string) attribute.KeyValue {
- return DBClientConnectionsPoolNameKey.String(val)
-}
-
-// DBCollectionName returns an attribute KeyValue conforming to the
-// "db.collection.name" semantic conventions. It represents the name of a
-// collection (table, container) within the database.
-func DBCollectionName(val string) attribute.KeyValue {
- return DBCollectionNameKey.String(val)
-}
-
-// DBNamespace returns an attribute KeyValue conforming to the
-// "db.namespace" semantic conventions. It represents the name of the database,
-// fully qualified within the server address and port.
-func DBNamespace(val string) attribute.KeyValue {
- return DBNamespaceKey.String(val)
-}
-
-// DBOperationName returns an attribute KeyValue conforming to the
-// "db.operation.name" semantic conventions. It represents the name of the
-// operation or command being executed.
-func DBOperationName(val string) attribute.KeyValue {
- return DBOperationNameKey.String(val)
-}
-
-// DBQueryText returns an attribute KeyValue conforming to the
-// "db.query.text" semantic conventions. It represents the database query being
-// executed.
-func DBQueryText(val string) attribute.KeyValue {
- return DBQueryTextKey.String(val)
-}
-
-// This group defines attributes for Cassandra.
-const (
- // DBCassandraConsistencyLevelKey is the attribute Key conforming to the
- // "db.cassandra.consistency_level" semantic conventions. It represents the
- // consistency level of the query. Based on consistency values from
- // [CQL](https://docs.datastax.com/en/cassandra-oss/3.0/cassandra/dml/dmlConfigConsistency.html).
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- DBCassandraConsistencyLevelKey = attribute.Key("db.cassandra.consistency_level")
-
- // DBCassandraCoordinatorDCKey is the attribute Key conforming to the
- // "db.cassandra.coordinator.dc" semantic conventions. It represents the
- // data center of the coordinating node for a query.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'us-west-2'
- DBCassandraCoordinatorDCKey = attribute.Key("db.cassandra.coordinator.dc")
-
- // DBCassandraCoordinatorIDKey is the attribute Key conforming to the
- // "db.cassandra.coordinator.id" semantic conventions. It represents the ID
- // of the coordinating node for a query.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'be13faa2-8574-4d71-926d-27f16cf8a7af'
- DBCassandraCoordinatorIDKey = attribute.Key("db.cassandra.coordinator.id")
-
- // DBCassandraIdempotenceKey is the attribute Key conforming to the
- // "db.cassandra.idempotence" semantic conventions. It represents the
- // whether or not the query is idempotent.
- //
- // Type: boolean
- // RequirementLevel: Optional
- // Stability: experimental
- DBCassandraIdempotenceKey = attribute.Key("db.cassandra.idempotence")
-
- // DBCassandraPageSizeKey is the attribute Key conforming to the
- // "db.cassandra.page_size" semantic conventions. It represents the fetch
- // size used for paging, i.e. how many rows will be returned at once.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 5000
- DBCassandraPageSizeKey = attribute.Key("db.cassandra.page_size")
-
- // DBCassandraSpeculativeExecutionCountKey is the attribute Key conforming
- // to the "db.cassandra.speculative_execution_count" semantic conventions.
- // It represents the number of times a query was speculatively executed.
- // Not set or `0` if the query was not executed speculatively.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 0, 2
- DBCassandraSpeculativeExecutionCountKey = attribute.Key("db.cassandra.speculative_execution_count")
-)
-
-var (
- // all
- DBCassandraConsistencyLevelAll = DBCassandraConsistencyLevelKey.String("all")
- // each_quorum
- DBCassandraConsistencyLevelEachQuorum = DBCassandraConsistencyLevelKey.String("each_quorum")
- // quorum
- DBCassandraConsistencyLevelQuorum = DBCassandraConsistencyLevelKey.String("quorum")
- // local_quorum
- DBCassandraConsistencyLevelLocalQuorum = DBCassandraConsistencyLevelKey.String("local_quorum")
- // one
- DBCassandraConsistencyLevelOne = DBCassandraConsistencyLevelKey.String("one")
- // two
- DBCassandraConsistencyLevelTwo = DBCassandraConsistencyLevelKey.String("two")
- // three
- DBCassandraConsistencyLevelThree = DBCassandraConsistencyLevelKey.String("three")
- // local_one
- DBCassandraConsistencyLevelLocalOne = DBCassandraConsistencyLevelKey.String("local_one")
- // any
- DBCassandraConsistencyLevelAny = DBCassandraConsistencyLevelKey.String("any")
- // serial
- DBCassandraConsistencyLevelSerial = DBCassandraConsistencyLevelKey.String("serial")
- // local_serial
- DBCassandraConsistencyLevelLocalSerial = DBCassandraConsistencyLevelKey.String("local_serial")
-)
-
-// DBCassandraCoordinatorDC returns an attribute KeyValue conforming to the
-// "db.cassandra.coordinator.dc" semantic conventions. It represents the data
-// center of the coordinating node for a query.
-func DBCassandraCoordinatorDC(val string) attribute.KeyValue {
- return DBCassandraCoordinatorDCKey.String(val)
-}
-
-// DBCassandraCoordinatorID returns an attribute KeyValue conforming to the
-// "db.cassandra.coordinator.id" semantic conventions. It represents the ID of
-// the coordinating node for a query.
-func DBCassandraCoordinatorID(val string) attribute.KeyValue {
- return DBCassandraCoordinatorIDKey.String(val)
-}
-
-// DBCassandraIdempotence returns an attribute KeyValue conforming to the
-// "db.cassandra.idempotence" semantic conventions. It represents the whether
-// or not the query is idempotent.
-func DBCassandraIdempotence(val bool) attribute.KeyValue {
- return DBCassandraIdempotenceKey.Bool(val)
-}
-
-// DBCassandraPageSize returns an attribute KeyValue conforming to the
-// "db.cassandra.page_size" semantic conventions. It represents the fetch size
-// used for paging, i.e. how many rows will be returned at once.
-func DBCassandraPageSize(val int) attribute.KeyValue {
- return DBCassandraPageSizeKey.Int(val)
-}
-
-// DBCassandraSpeculativeExecutionCount returns an attribute KeyValue
-// conforming to the "db.cassandra.speculative_execution_count" semantic
-// conventions. It represents the number of times a query was speculatively
-// executed. Not set or `0` if the query was not executed speculatively.
-func DBCassandraSpeculativeExecutionCount(val int) attribute.KeyValue {
- return DBCassandraSpeculativeExecutionCountKey.Int(val)
-}
-
-// This group defines attributes for Azure Cosmos DB.
-const (
- // DBCosmosDBClientIDKey is the attribute Key conforming to the
- // "db.cosmosdb.client_id" semantic conventions. It represents the unique
- // Cosmos client instance id.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '3ba4827d-4422-483f-b59f-85b74211c11d'
- DBCosmosDBClientIDKey = attribute.Key("db.cosmosdb.client_id")
-
- // DBCosmosDBConnectionModeKey is the attribute Key conforming to the
- // "db.cosmosdb.connection_mode" semantic conventions. It represents the
- // cosmos client connection mode.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- DBCosmosDBConnectionModeKey = attribute.Key("db.cosmosdb.connection_mode")
-
- // DBCosmosDBOperationTypeKey is the attribute Key conforming to the
- // "db.cosmosdb.operation_type" semantic conventions. It represents the
- // cosmosDB Operation Type.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- DBCosmosDBOperationTypeKey = attribute.Key("db.cosmosdb.operation_type")
-
- // DBCosmosDBRequestChargeKey is the attribute Key conforming to the
- // "db.cosmosdb.request_charge" semantic conventions. It represents the rU
- // consumed for that operation
- //
- // Type: double
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 46.18, 1.0
- DBCosmosDBRequestChargeKey = attribute.Key("db.cosmosdb.request_charge")
-
- // DBCosmosDBRequestContentLengthKey is the attribute Key conforming to the
- // "db.cosmosdb.request_content_length" semantic conventions. It represents
- // the request payload size in bytes
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- DBCosmosDBRequestContentLengthKey = attribute.Key("db.cosmosdb.request_content_length")
-
- // DBCosmosDBStatusCodeKey is the attribute Key conforming to the
- // "db.cosmosdb.status_code" semantic conventions. It represents the cosmos
- // DB status code.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 200, 201
- DBCosmosDBStatusCodeKey = attribute.Key("db.cosmosdb.status_code")
-
- // DBCosmosDBSubStatusCodeKey is the attribute Key conforming to the
- // "db.cosmosdb.sub_status_code" semantic conventions. It represents the
- // cosmos DB sub status code.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 1000, 1002
- DBCosmosDBSubStatusCodeKey = attribute.Key("db.cosmosdb.sub_status_code")
-)
-
-var (
- // Gateway (HTTP) connections mode
- DBCosmosDBConnectionModeGateway = DBCosmosDBConnectionModeKey.String("gateway")
- // Direct connection
- DBCosmosDBConnectionModeDirect = DBCosmosDBConnectionModeKey.String("direct")
-)
-
-var (
- // invalid
- DBCosmosDBOperationTypeInvalid = DBCosmosDBOperationTypeKey.String("Invalid")
- // create
- DBCosmosDBOperationTypeCreate = DBCosmosDBOperationTypeKey.String("Create")
- // patch
- DBCosmosDBOperationTypePatch = DBCosmosDBOperationTypeKey.String("Patch")
- // read
- DBCosmosDBOperationTypeRead = DBCosmosDBOperationTypeKey.String("Read")
- // read_feed
- DBCosmosDBOperationTypeReadFeed = DBCosmosDBOperationTypeKey.String("ReadFeed")
- // delete
- DBCosmosDBOperationTypeDelete = DBCosmosDBOperationTypeKey.String("Delete")
- // replace
- DBCosmosDBOperationTypeReplace = DBCosmosDBOperationTypeKey.String("Replace")
- // execute
- DBCosmosDBOperationTypeExecute = DBCosmosDBOperationTypeKey.String("Execute")
- // query
- DBCosmosDBOperationTypeQuery = DBCosmosDBOperationTypeKey.String("Query")
- // head
- DBCosmosDBOperationTypeHead = DBCosmosDBOperationTypeKey.String("Head")
- // head_feed
- DBCosmosDBOperationTypeHeadFeed = DBCosmosDBOperationTypeKey.String("HeadFeed")
- // upsert
- DBCosmosDBOperationTypeUpsert = DBCosmosDBOperationTypeKey.String("Upsert")
- // batch
- DBCosmosDBOperationTypeBatch = DBCosmosDBOperationTypeKey.String("Batch")
- // query_plan
- DBCosmosDBOperationTypeQueryPlan = DBCosmosDBOperationTypeKey.String("QueryPlan")
- // execute_javascript
- DBCosmosDBOperationTypeExecuteJavascript = DBCosmosDBOperationTypeKey.String("ExecuteJavaScript")
-)
-
-// DBCosmosDBClientID returns an attribute KeyValue conforming to the
-// "db.cosmosdb.client_id" semantic conventions. It represents the unique
-// Cosmos client instance id.
-func DBCosmosDBClientID(val string) attribute.KeyValue {
- return DBCosmosDBClientIDKey.String(val)
-}
-
-// DBCosmosDBRequestCharge returns an attribute KeyValue conforming to the
-// "db.cosmosdb.request_charge" semantic conventions. It represents the rU
-// consumed for that operation
-func DBCosmosDBRequestCharge(val float64) attribute.KeyValue {
- return DBCosmosDBRequestChargeKey.Float64(val)
-}
-
-// DBCosmosDBRequestContentLength returns an attribute KeyValue conforming
-// to the "db.cosmosdb.request_content_length" semantic conventions. It
-// represents the request payload size in bytes
-func DBCosmosDBRequestContentLength(val int) attribute.KeyValue {
- return DBCosmosDBRequestContentLengthKey.Int(val)
-}
-
-// DBCosmosDBStatusCode returns an attribute KeyValue conforming to the
-// "db.cosmosdb.status_code" semantic conventions. It represents the cosmos DB
-// status code.
-func DBCosmosDBStatusCode(val int) attribute.KeyValue {
- return DBCosmosDBStatusCodeKey.Int(val)
-}
-
-// DBCosmosDBSubStatusCode returns an attribute KeyValue conforming to the
-// "db.cosmosdb.sub_status_code" semantic conventions. It represents the cosmos
-// DB sub status code.
-func DBCosmosDBSubStatusCode(val int) attribute.KeyValue {
- return DBCosmosDBSubStatusCodeKey.Int(val)
-}
-
-// This group defines attributes for Elasticsearch.
-const (
- // DBElasticsearchClusterNameKey is the attribute Key conforming to the
- // "db.elasticsearch.cluster.name" semantic conventions. It represents the
- // represents the identifier of an Elasticsearch cluster.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'e9106fc68e3044f0b1475b04bf4ffd5f'
- DBElasticsearchClusterNameKey = attribute.Key("db.elasticsearch.cluster.name")
-
- // DBElasticsearchNodeNameKey is the attribute Key conforming to the
- // "db.elasticsearch.node.name" semantic conventions. It represents the
- // represents the human-readable identifier of the node/instance to which a
- // request was routed.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'instance-0000000001'
- DBElasticsearchNodeNameKey = attribute.Key("db.elasticsearch.node.name")
-)
-
-// DBElasticsearchClusterName returns an attribute KeyValue conforming to
-// the "db.elasticsearch.cluster.name" semantic conventions. It represents the
-// represents the identifier of an Elasticsearch cluster.
-func DBElasticsearchClusterName(val string) attribute.KeyValue {
- return DBElasticsearchClusterNameKey.String(val)
-}
-
-// DBElasticsearchNodeName returns an attribute KeyValue conforming to the
-// "db.elasticsearch.node.name" semantic conventions. It represents the
-// represents the human-readable identifier of the node/instance to which a
-// request was routed.
-func DBElasticsearchNodeName(val string) attribute.KeyValue {
- return DBElasticsearchNodeNameKey.String(val)
-}
-
-// Attributes for software deployments.
-const (
- // DeploymentEnvironmentKey is the attribute Key conforming to the
- // "deployment.environment" semantic conventions. It represents the name of
- // the [deployment
- // environment](https://wikipedia.org/wiki/Deployment_environment) (aka
- // deployment tier).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'staging', 'production'
- // Note: `deployment.environment` does not affect the uniqueness
- // constraints defined through
- // the `service.namespace`, `service.name` and `service.instance.id`
- // resource attributes.
- // This implies that resources carrying the following attribute
- // combinations MUST be
- // considered to be identifying the same service:
- //
- // * `service.name=frontend`, `deployment.environment=production`
- // * `service.name=frontend`, `deployment.environment=staging`.
- DeploymentEnvironmentKey = attribute.Key("deployment.environment")
-)
-
-// DeploymentEnvironment returns an attribute KeyValue conforming to the
-// "deployment.environment" semantic conventions. It represents the name of the
-// [deployment environment](https://wikipedia.org/wiki/Deployment_environment)
-// (aka deployment tier).
-func DeploymentEnvironment(val string) attribute.KeyValue {
- return DeploymentEnvironmentKey.String(val)
-}
-
-// Attributes that represents an occurrence of a lifecycle transition on the
-// Android platform.
-const (
- // AndroidStateKey is the attribute Key conforming to the "android.state"
- // semantic conventions. It represents the deprecated use the
- // `device.app.lifecycle` event definition including `android.state` as a
- // payload field instead.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- // Note: The Android lifecycle states are defined in [Activity lifecycle
- // callbacks](https://developer.android.com/guide/components/activities/activity-lifecycle#lc),
- // and from which the `OS identifiers` are derived.
- AndroidStateKey = attribute.Key("android.state")
-)
-
-var (
- // Any time before Activity.onResume() or, if the app has no Activity, Context.startService() has been called in the app for the first time
- AndroidStateCreated = AndroidStateKey.String("created")
- // Any time after Activity.onPause() or, if the app has no Activity, Context.stopService() has been called when the app was in the foreground state
- AndroidStateBackground = AndroidStateKey.String("background")
- // Any time after Activity.onResume() or, if the app has no Activity, Context.startService() has been called when the app was in either the created or background states
- AndroidStateForeground = AndroidStateKey.String("foreground")
-)
-
-// These attributes may be used to describe the receiver of a network
-// exchange/packet. These should be used when there is no client/server
-// relationship between the two sides, or when that relationship is unknown.
-// This covers low-level network interactions (e.g. packet tracing) where you
-// don't know if there was a connection or which side initiated it. This also
-// covers unidirectional UDP flows and peer-to-peer communication where the
-// "user-facing" surface of the protocol / API doesn't expose a clear notion of
-// client and server.
-const (
- // DestinationAddressKey is the attribute Key conforming to the
- // "destination.address" semantic conventions. It represents the
- // destination address - domain name if available without reverse DNS
- // lookup; otherwise, IP address or Unix domain socket name.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'destination.example.com', '10.1.2.80', '/tmp/my.sock'
- // Note: When observed from the source side, and when communicating through
- // an intermediary, `destination.address` SHOULD represent the destination
- // address behind any intermediaries, for example proxies, if it's
- // available.
- DestinationAddressKey = attribute.Key("destination.address")
-
- // DestinationPortKey is the attribute Key conforming to the
- // "destination.port" semantic conventions. It represents the destination
- // port number
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 3389, 2888
- DestinationPortKey = attribute.Key("destination.port")
-)
-
-// DestinationAddress returns an attribute KeyValue conforming to the
-// "destination.address" semantic conventions. It represents the destination
-// address - domain name if available without reverse DNS lookup; otherwise, IP
-// address or Unix domain socket name.
-func DestinationAddress(val string) attribute.KeyValue {
- return DestinationAddressKey.String(val)
-}
-
-// DestinationPort returns an attribute KeyValue conforming to the
-// "destination.port" semantic conventions. It represents the destination port
-// number
-func DestinationPort(val int) attribute.KeyValue {
- return DestinationPortKey.Int(val)
-}
-
-// Describes device attributes.
-const (
- // DeviceIDKey is the attribute Key conforming to the "device.id" semantic
- // conventions. It represents a unique identifier representing the device
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '2ab2916d-a51f-4ac8-80ee-45ac31a28092'
- // Note: The device identifier MUST only be defined using the values
- // outlined below. This value is not an advertising identifier and MUST NOT
- // be used as such. On iOS (Swift or Objective-C), this value MUST be equal
- // to the [vendor
- // identifier](https://developer.apple.com/documentation/uikit/uidevice/1620059-identifierforvendor).
- // On Android (Java or Kotlin), this value MUST be equal to the Firebase
- // Installation ID or a globally unique UUID which is persisted across
- // sessions in your application. More information can be found
- // [here](https://developer.android.com/training/articles/user-data-ids) on
- // best practices and exact implementation details. Caution should be taken
- // when storing personal data or anything which can identify a user. GDPR
- // and data protection laws may apply, ensure you do your own due
- // diligence.
- DeviceIDKey = attribute.Key("device.id")
-
- // DeviceManufacturerKey is the attribute Key conforming to the
- // "device.manufacturer" semantic conventions. It represents the name of
- // the device manufacturer
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'Apple', 'Samsung'
- // Note: The Android OS provides this field via
- // [Build](https://developer.android.com/reference/android/os/Build#MANUFACTURER).
- // iOS apps SHOULD hardcode the value `Apple`.
- DeviceManufacturerKey = attribute.Key("device.manufacturer")
-
- // DeviceModelIdentifierKey is the attribute Key conforming to the
- // "device.model.identifier" semantic conventions. It represents the model
- // identifier for the device
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'iPhone3,4', 'SM-G920F'
- // Note: It's recommended this value represents a machine-readable version
- // of the model identifier rather than the market or consumer-friendly name
- // of the device.
- DeviceModelIdentifierKey = attribute.Key("device.model.identifier")
-
- // DeviceModelNameKey is the attribute Key conforming to the
- // "device.model.name" semantic conventions. It represents the marketing
- // name for the device model
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'iPhone 6s Plus', 'Samsung Galaxy S6'
- // Note: It's recommended this value represents a human-readable version of
- // the device model rather than a machine-readable alternative.
- DeviceModelNameKey = attribute.Key("device.model.name")
-)
-
-// DeviceID returns an attribute KeyValue conforming to the "device.id"
-// semantic conventions. It represents a unique identifier representing the
-// device
-func DeviceID(val string) attribute.KeyValue {
- return DeviceIDKey.String(val)
-}
-
-// DeviceManufacturer returns an attribute KeyValue conforming to the
-// "device.manufacturer" semantic conventions. It represents the name of the
-// device manufacturer
-func DeviceManufacturer(val string) attribute.KeyValue {
- return DeviceManufacturerKey.String(val)
-}
-
-// DeviceModelIdentifier returns an attribute KeyValue conforming to the
-// "device.model.identifier" semantic conventions. It represents the model
-// identifier for the device
-func DeviceModelIdentifier(val string) attribute.KeyValue {
- return DeviceModelIdentifierKey.String(val)
-}
-
-// DeviceModelName returns an attribute KeyValue conforming to the
-// "device.model.name" semantic conventions. It represents the marketing name
-// for the device model
-func DeviceModelName(val string) attribute.KeyValue {
- return DeviceModelNameKey.String(val)
-}
-
-// These attributes may be used for any disk related operation.
-const (
- // DiskIoDirectionKey is the attribute Key conforming to the
- // "disk.io.direction" semantic conventions. It represents the disk IO
- // operation direction.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'read'
- DiskIoDirectionKey = attribute.Key("disk.io.direction")
-)
-
-var (
- // read
- DiskIoDirectionRead = DiskIoDirectionKey.String("read")
- // write
- DiskIoDirectionWrite = DiskIoDirectionKey.String("write")
-)
-
-// The shared attributes used to report a DNS query.
-const (
- // DNSQuestionNameKey is the attribute Key conforming to the
- // "dns.question.name" semantic conventions. It represents the name being
- // queried.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'www.example.com', 'opentelemetry.io'
- // Note: If the name field contains non-printable characters (below 32 or
- // above 126), those characters should be represented as escaped base 10
- // integers (\DDD). Back slashes and quotes should be escaped. Tabs,
- // carriage returns, and line feeds should be converted to \t, \r, and \n
- // respectively.
- DNSQuestionNameKey = attribute.Key("dns.question.name")
-)
-
-// DNSQuestionName returns an attribute KeyValue conforming to the
-// "dns.question.name" semantic conventions. It represents the name being
-// queried.
-func DNSQuestionName(val string) attribute.KeyValue {
- return DNSQuestionNameKey.String(val)
-}
-
-// Attributes for operations with an authenticated and/or authorized enduser.
-const (
- // EnduserIDKey is the attribute Key conforming to the "enduser.id"
- // semantic conventions. It represents the username or client_id extracted
- // from the access token or
- // [Authorization](https://tools.ietf.org/html/rfc7235#section-4.2) header
- // in the inbound request from outside the system.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'username'
- EnduserIDKey = attribute.Key("enduser.id")
-
- // EnduserRoleKey is the attribute Key conforming to the "enduser.role"
- // semantic conventions. It represents the actual/assumed role the client
- // is making the request under extracted from token or application security
- // context.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'admin'
- EnduserRoleKey = attribute.Key("enduser.role")
-
- // EnduserScopeKey is the attribute Key conforming to the "enduser.scope"
- // semantic conventions. It represents the scopes or granted authorities
- // the client currently possesses extracted from token or application
- // security context. The value would come from the scope associated with an
- // [OAuth 2.0 Access
- // Token](https://tools.ietf.org/html/rfc6749#section-3.3) or an attribute
- // value in a [SAML 2.0
- // Assertion](http://docs.oasis-open.org/security/saml/Post2.0/sstc-saml-tech-overview-2.0.html).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'read:message, write:files'
- EnduserScopeKey = attribute.Key("enduser.scope")
-)
-
-// EnduserID returns an attribute KeyValue conforming to the "enduser.id"
-// semantic conventions. It represents the username or client_id extracted from
-// the access token or
-// [Authorization](https://tools.ietf.org/html/rfc7235#section-4.2) header in
-// the inbound request from outside the system.
-func EnduserID(val string) attribute.KeyValue {
- return EnduserIDKey.String(val)
-}
-
-// EnduserRole returns an attribute KeyValue conforming to the
-// "enduser.role" semantic conventions. It represents the actual/assumed role
-// the client is making the request under extracted from token or application
-// security context.
-func EnduserRole(val string) attribute.KeyValue {
- return EnduserRoleKey.String(val)
-}
-
-// EnduserScope returns an attribute KeyValue conforming to the
-// "enduser.scope" semantic conventions. It represents the scopes or granted
-// authorities the client currently possesses extracted from token or
-// application security context. The value would come from the scope associated
-// with an [OAuth 2.0 Access
-// Token](https://tools.ietf.org/html/rfc6749#section-3.3) or an attribute
-// value in a [SAML 2.0
-// Assertion](http://docs.oasis-open.org/security/saml/Post2.0/sstc-saml-tech-overview-2.0.html).
-func EnduserScope(val string) attribute.KeyValue {
- return EnduserScopeKey.String(val)
-}
-
-// The shared attributes used to report an error.
-const (
- // ErrorTypeKey is the attribute Key conforming to the "error.type"
- // semantic conventions. It represents the describes a class of error the
- // operation ended with.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'timeout', 'java.net.UnknownHostException',
- // 'server_certificate_invalid', '500'
- // Note: The `error.type` SHOULD be predictable, and SHOULD have low
- // cardinality.
- //
- // When `error.type` is set to a type (e.g., an exception type), its
- // canonical class name identifying the type within the artifact SHOULD be
- // used.
- //
- // Instrumentations SHOULD document the list of errors they report.
- //
- // The cardinality of `error.type` within one instrumentation library
- // SHOULD be low.
- // Telemetry consumers that aggregate data from multiple instrumentation
- // libraries and applications
- // should be prepared for `error.type` to have high cardinality at query
- // time when no
- // additional filters are applied.
- //
- // If the operation has completed successfully, instrumentations SHOULD NOT
- // set `error.type`.
- //
- // If a specific domain defines its own set of error identifiers (such as
- // HTTP or gRPC status codes),
- // it's RECOMMENDED to:
- //
- // * Use a domain-specific attribute
- // * Set `error.type` to capture all errors, regardless of whether they are
- // defined within the domain-specific set or not.
- ErrorTypeKey = attribute.Key("error.type")
-)
-
-var (
- // A fallback error value to be used when the instrumentation doesn't define a custom value
- ErrorTypeOther = ErrorTypeKey.String("_OTHER")
-)
-
-// Attributes for Events represented using Log Records.
-const (
- // EventNameKey is the attribute Key conforming to the "event.name"
- // semantic conventions. It represents the identifies the class / type of
- // event.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'browser.mouse.click', 'device.app.lifecycle'
- // Note: Event names are subject to the same rules as [attribute
- // names](https://github.com/open-telemetry/opentelemetry-specification/tree/v1.33.0/specification/common/attribute-naming.md).
- // Notably, event names are namespaced to avoid collisions and provide a
- // clean separation of semantics for events in separate domains like
- // browser, mobile, and kubernetes.
- EventNameKey = attribute.Key("event.name")
-)
-
-// EventName returns an attribute KeyValue conforming to the "event.name"
-// semantic conventions. It represents the identifies the class / type of
-// event.
-func EventName(val string) attribute.KeyValue {
- return EventNameKey.String(val)
-}
-
-// The shared attributes used to report a single exception associated with a
-// span or log.
-const (
- // ExceptionEscapedKey is the attribute Key conforming to the
- // "exception.escaped" semantic conventions. It represents the sHOULD be
- // set to true if the exception event is recorded at a point where it is
- // known that the exception is escaping the scope of the span.
- //
- // Type: boolean
- // RequirementLevel: Optional
- // Stability: stable
- // Note: An exception is considered to have escaped (or left) the scope of
- // a span,
- // if that span is ended while the exception is still logically "in
- // flight".
- // This may be actually "in flight" in some languages (e.g. if the
- // exception
- // is passed to a Context manager's `__exit__` method in Python) but will
- // usually be caught at the point of recording the exception in most
- // languages.
- //
- // It is usually not possible to determine at the point where an exception
- // is thrown
- // whether it will escape the scope of a span.
- // However, it is trivial to know that an exception
- // will escape, if one checks for an active exception just before ending
- // the span,
- // as done in the [example for recording span
- // exceptions](https://opentelemetry.io/docs/specs/semconv/exceptions/exceptions-spans/#recording-an-exception).
- //
- // It follows that an exception may still escape the scope of the span
- // even if the `exception.escaped` attribute was not set or set to false,
- // since the event might have been recorded at a time where it was not
- // clear whether the exception will escape.
- ExceptionEscapedKey = attribute.Key("exception.escaped")
-
- // ExceptionMessageKey is the attribute Key conforming to the
- // "exception.message" semantic conventions. It represents the exception
- // message.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'Division by zero', "Can't convert 'int' object to str
- // implicitly"
- ExceptionMessageKey = attribute.Key("exception.message")
-
- // ExceptionStacktraceKey is the attribute Key conforming to the
- // "exception.stacktrace" semantic conventions. It represents a stacktrace
- // as a string in the natural representation for the language runtime. The
- // representation is to be determined and documented by each language SIG.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'Exception in thread "main" java.lang.RuntimeException: Test
- // exception\\n at '
- // 'com.example.GenerateTrace.methodB(GenerateTrace.java:13)\\n at '
- // 'com.example.GenerateTrace.methodA(GenerateTrace.java:9)\\n at '
- // 'com.example.GenerateTrace.main(GenerateTrace.java:5)'
- ExceptionStacktraceKey = attribute.Key("exception.stacktrace")
-
- // ExceptionTypeKey is the attribute Key conforming to the "exception.type"
- // semantic conventions. It represents the type of the exception (its
- // fully-qualified class name, if applicable). The dynamic type of the
- // exception should be preferred over the static type in languages that
- // support it.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'java.net.ConnectException', 'OSError'
- ExceptionTypeKey = attribute.Key("exception.type")
-)
-
-// ExceptionEscaped returns an attribute KeyValue conforming to the
-// "exception.escaped" semantic conventions. It represents the sHOULD be set to
-// true if the exception event is recorded at a point where it is known that
-// the exception is escaping the scope of the span.
-func ExceptionEscaped(val bool) attribute.KeyValue {
- return ExceptionEscapedKey.Bool(val)
-}
-
-// ExceptionMessage returns an attribute KeyValue conforming to the
-// "exception.message" semantic conventions. It represents the exception
-// message.
-func ExceptionMessage(val string) attribute.KeyValue {
- return ExceptionMessageKey.String(val)
-}
-
-// ExceptionStacktrace returns an attribute KeyValue conforming to the
-// "exception.stacktrace" semantic conventions. It represents a stacktrace as a
-// string in the natural representation for the language runtime. The
-// representation is to be determined and documented by each language SIG.
-func ExceptionStacktrace(val string) attribute.KeyValue {
- return ExceptionStacktraceKey.String(val)
-}
-
-// ExceptionType returns an attribute KeyValue conforming to the
-// "exception.type" semantic conventions. It represents the type of the
-// exception (its fully-qualified class name, if applicable). The dynamic type
-// of the exception should be preferred over the static type in languages that
-// support it.
-func ExceptionType(val string) attribute.KeyValue {
- return ExceptionTypeKey.String(val)
-}
-
-// FaaS attributes
-const (
- // FaaSColdstartKey is the attribute Key conforming to the "faas.coldstart"
- // semantic conventions. It represents a boolean that is true if the
- // serverless function is executed for the first time (aka cold-start).
- //
- // Type: boolean
- // RequirementLevel: Optional
- // Stability: experimental
- FaaSColdstartKey = attribute.Key("faas.coldstart")
-
- // FaaSCronKey is the attribute Key conforming to the "faas.cron" semantic
- // conventions. It represents a string containing the schedule period as
- // [Cron
- // Expression](https://docs.oracle.com/cd/E12058_01/doc/doc.1014/e12030/cron_expressions.htm).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '0/5 * * * ? *'
- FaaSCronKey = attribute.Key("faas.cron")
-
- // FaaSDocumentCollectionKey is the attribute Key conforming to the
- // "faas.document.collection" semantic conventions. It represents the name
- // of the source on which the triggering operation was performed. For
- // example, in Cloud Storage or S3 corresponds to the bucket name, and in
- // Cosmos DB to the database name.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'myBucketName', 'myDBName'
- FaaSDocumentCollectionKey = attribute.Key("faas.document.collection")
-
- // FaaSDocumentNameKey is the attribute Key conforming to the
- // "faas.document.name" semantic conventions. It represents the document
- // name/table subjected to the operation. For example, in Cloud Storage or
- // S3 is the name of the file, and in Cosmos DB the table name.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'myFile.txt', 'myTableName'
- FaaSDocumentNameKey = attribute.Key("faas.document.name")
-
- // FaaSDocumentOperationKey is the attribute Key conforming to the
- // "faas.document.operation" semantic conventions. It represents the
- // describes the type of the operation that was performed on the data.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- FaaSDocumentOperationKey = attribute.Key("faas.document.operation")
-
- // FaaSDocumentTimeKey is the attribute Key conforming to the
- // "faas.document.time" semantic conventions. It represents a string
- // containing the time when the data was accessed in the [ISO
- // 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format
- // expressed in [UTC](https://www.w3.org/TR/NOTE-datetime).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '2020-01-23T13:47:06Z'
- FaaSDocumentTimeKey = attribute.Key("faas.document.time")
-
- // FaaSInstanceKey is the attribute Key conforming to the "faas.instance"
- // semantic conventions. It represents the execution environment ID as a
- // string, that will be potentially reused for other invocations to the
- // same function/function version.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '2021/06/28/[$LATEST]2f399eb14537447da05ab2a2e39309de'
- // Note: * **AWS Lambda:** Use the (full) log stream name.
- FaaSInstanceKey = attribute.Key("faas.instance")
-
- // FaaSInvocationIDKey is the attribute Key conforming to the
- // "faas.invocation_id" semantic conventions. It represents the invocation
- // ID of the current function invocation.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'af9d5aa4-a685-4c5f-a22b-444f80b3cc28'
- FaaSInvocationIDKey = attribute.Key("faas.invocation_id")
-
- // FaaSInvokedNameKey is the attribute Key conforming to the
- // "faas.invoked_name" semantic conventions. It represents the name of the
- // invoked function.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'my-function'
- // Note: SHOULD be equal to the `faas.name` resource attribute of the
- // invoked function.
- FaaSInvokedNameKey = attribute.Key("faas.invoked_name")
-
- // FaaSInvokedProviderKey is the attribute Key conforming to the
- // "faas.invoked_provider" semantic conventions. It represents the cloud
- // provider of the invoked function.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- // Note: SHOULD be equal to the `cloud.provider` resource attribute of the
- // invoked function.
- FaaSInvokedProviderKey = attribute.Key("faas.invoked_provider")
-
- // FaaSInvokedRegionKey is the attribute Key conforming to the
- // "faas.invoked_region" semantic conventions. It represents the cloud
- // region of the invoked function.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'eu-central-1'
- // Note: SHOULD be equal to the `cloud.region` resource attribute of the
- // invoked function.
- FaaSInvokedRegionKey = attribute.Key("faas.invoked_region")
-
- // FaaSMaxMemoryKey is the attribute Key conforming to the
- // "faas.max_memory" semantic conventions. It represents the amount of
- // memory available to the serverless function converted to Bytes.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 134217728
- // Note: It's recommended to set this attribute since e.g. too little
- // memory can easily stop a Java AWS Lambda function from working
- // correctly. On AWS Lambda, the environment variable
- // `AWS_LAMBDA_FUNCTION_MEMORY_SIZE` provides this information (which must
- // be multiplied by 1,048,576).
- FaaSMaxMemoryKey = attribute.Key("faas.max_memory")
-
- // FaaSNameKey is the attribute Key conforming to the "faas.name" semantic
- // conventions. It represents the name of the single function that this
- // runtime instance executes.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'my-function', 'myazurefunctionapp/some-function-name'
- // Note: This is the name of the function as configured/deployed on the
- // FaaS
- // platform and is usually different from the name of the callback
- // function (which may be stored in the
- // [`code.namespace`/`code.function`](/docs/general/attributes.md#source-code-attributes)
- // span attributes).
- //
- // For some cloud providers, the above definition is ambiguous. The
- // following
- // definition of function name MUST be used for this attribute
- // (and consequently the span name) for the listed cloud
- // providers/products:
- //
- // * **Azure:** The full name `/`, i.e., function app name
- // followed by a forward slash followed by the function name (this form
- // can also be seen in the resource JSON for the function).
- // This means that a span attribute MUST be used, as an Azure function
- // app can host multiple functions that would usually share
- // a TracerProvider (see also the `cloud.resource_id` attribute).
- FaaSNameKey = attribute.Key("faas.name")
-
- // FaaSTimeKey is the attribute Key conforming to the "faas.time" semantic
- // conventions. It represents a string containing the function invocation
- // time in the [ISO
- // 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format
- // expressed in [UTC](https://www.w3.org/TR/NOTE-datetime).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '2020-01-23T13:47:06Z'
- FaaSTimeKey = attribute.Key("faas.time")
-
- // FaaSTriggerKey is the attribute Key conforming to the "faas.trigger"
- // semantic conventions. It represents the type of the trigger which caused
- // this function invocation.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- FaaSTriggerKey = attribute.Key("faas.trigger")
-
- // FaaSVersionKey is the attribute Key conforming to the "faas.version"
- // semantic conventions. It represents the immutable version of the
- // function being executed.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '26', 'pinkfroid-00002'
- // Note: Depending on the cloud provider and platform, use:
- //
- // * **AWS Lambda:** The [function
- // version](https://docs.aws.amazon.com/lambda/latest/dg/configuration-versions.html)
- // (an integer represented as a decimal string).
- // * **Google Cloud Run (Services):** The
- // [revision](https://cloud.google.com/run/docs/managing/revisions)
- // (i.e., the function name plus the revision suffix).
- // * **Google Cloud Functions:** The value of the
- // [`K_REVISION` environment
- // variable](https://cloud.google.com/functions/docs/env-var#runtime_environment_variables_set_automatically).
- // * **Azure Functions:** Not applicable. Do not set this attribute.
- FaaSVersionKey = attribute.Key("faas.version")
-)
-
-var (
- // When a new object is created
- FaaSDocumentOperationInsert = FaaSDocumentOperationKey.String("insert")
- // When an object is modified
- FaaSDocumentOperationEdit = FaaSDocumentOperationKey.String("edit")
- // When an object is deleted
- FaaSDocumentOperationDelete = FaaSDocumentOperationKey.String("delete")
-)
-
-var (
- // Alibaba Cloud
- FaaSInvokedProviderAlibabaCloud = FaaSInvokedProviderKey.String("alibaba_cloud")
- // Amazon Web Services
- FaaSInvokedProviderAWS = FaaSInvokedProviderKey.String("aws")
- // Microsoft Azure
- FaaSInvokedProviderAzure = FaaSInvokedProviderKey.String("azure")
- // Google Cloud Platform
- FaaSInvokedProviderGCP = FaaSInvokedProviderKey.String("gcp")
- // Tencent Cloud
- FaaSInvokedProviderTencentCloud = FaaSInvokedProviderKey.String("tencent_cloud")
-)
-
-var (
- // A response to some data source operation such as a database or filesystem read/write
- FaaSTriggerDatasource = FaaSTriggerKey.String("datasource")
- // To provide an answer to an inbound HTTP request
- FaaSTriggerHTTP = FaaSTriggerKey.String("http")
- // A function is set to be executed when messages are sent to a messaging system
- FaaSTriggerPubsub = FaaSTriggerKey.String("pubsub")
- // A function is scheduled to be executed regularly
- FaaSTriggerTimer = FaaSTriggerKey.String("timer")
- // If none of the others apply
- FaaSTriggerOther = FaaSTriggerKey.String("other")
-)
-
-// FaaSColdstart returns an attribute KeyValue conforming to the
-// "faas.coldstart" semantic conventions. It represents a boolean that is true
-// if the serverless function is executed for the first time (aka cold-start).
-func FaaSColdstart(val bool) attribute.KeyValue {
- return FaaSColdstartKey.Bool(val)
-}
-
-// FaaSCron returns an attribute KeyValue conforming to the "faas.cron"
-// semantic conventions. It represents a string containing the schedule period
-// as [Cron
-// Expression](https://docs.oracle.com/cd/E12058_01/doc/doc.1014/e12030/cron_expressions.htm).
-func FaaSCron(val string) attribute.KeyValue {
- return FaaSCronKey.String(val)
-}
-
-// FaaSDocumentCollection returns an attribute KeyValue conforming to the
-// "faas.document.collection" semantic conventions. It represents the name of
-// the source on which the triggering operation was performed. For example, in
-// Cloud Storage or S3 corresponds to the bucket name, and in Cosmos DB to the
-// database name.
-func FaaSDocumentCollection(val string) attribute.KeyValue {
- return FaaSDocumentCollectionKey.String(val)
-}
-
-// FaaSDocumentName returns an attribute KeyValue conforming to the
-// "faas.document.name" semantic conventions. It represents the document
-// name/table subjected to the operation. For example, in Cloud Storage or S3
-// is the name of the file, and in Cosmos DB the table name.
-func FaaSDocumentName(val string) attribute.KeyValue {
- return FaaSDocumentNameKey.String(val)
-}
-
-// FaaSDocumentTime returns an attribute KeyValue conforming to the
-// "faas.document.time" semantic conventions. It represents a string containing
-// the time when the data was accessed in the [ISO
-// 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format
-// expressed in [UTC](https://www.w3.org/TR/NOTE-datetime).
-func FaaSDocumentTime(val string) attribute.KeyValue {
- return FaaSDocumentTimeKey.String(val)
-}
-
-// FaaSInstance returns an attribute KeyValue conforming to the
-// "faas.instance" semantic conventions. It represents the execution
-// environment ID as a string, that will be potentially reused for other
-// invocations to the same function/function version.
-func FaaSInstance(val string) attribute.KeyValue {
- return FaaSInstanceKey.String(val)
-}
-
-// FaaSInvocationID returns an attribute KeyValue conforming to the
-// "faas.invocation_id" semantic conventions. It represents the invocation ID
-// of the current function invocation.
-func FaaSInvocationID(val string) attribute.KeyValue {
- return FaaSInvocationIDKey.String(val)
-}
-
-// FaaSInvokedName returns an attribute KeyValue conforming to the
-// "faas.invoked_name" semantic conventions. It represents the name of the
-// invoked function.
-func FaaSInvokedName(val string) attribute.KeyValue {
- return FaaSInvokedNameKey.String(val)
-}
-
-// FaaSInvokedRegion returns an attribute KeyValue conforming to the
-// "faas.invoked_region" semantic conventions. It represents the cloud region
-// of the invoked function.
-func FaaSInvokedRegion(val string) attribute.KeyValue {
- return FaaSInvokedRegionKey.String(val)
-}
-
-// FaaSMaxMemory returns an attribute KeyValue conforming to the
-// "faas.max_memory" semantic conventions. It represents the amount of memory
-// available to the serverless function converted to Bytes.
-func FaaSMaxMemory(val int) attribute.KeyValue {
- return FaaSMaxMemoryKey.Int(val)
-}
-
-// FaaSName returns an attribute KeyValue conforming to the "faas.name"
-// semantic conventions. It represents the name of the single function that
-// this runtime instance executes.
-func FaaSName(val string) attribute.KeyValue {
- return FaaSNameKey.String(val)
-}
-
-// FaaSTime returns an attribute KeyValue conforming to the "faas.time"
-// semantic conventions. It represents a string containing the function
-// invocation time in the [ISO
-// 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format
-// expressed in [UTC](https://www.w3.org/TR/NOTE-datetime).
-func FaaSTime(val string) attribute.KeyValue {
- return FaaSTimeKey.String(val)
-}
-
-// FaaSVersion returns an attribute KeyValue conforming to the
-// "faas.version" semantic conventions. It represents the immutable version of
-// the function being executed.
-func FaaSVersion(val string) attribute.KeyValue {
- return FaaSVersionKey.String(val)
-}
-
-// Attributes for Feature Flags.
-const (
- // FeatureFlagKeyKey is the attribute Key conforming to the
- // "feature_flag.key" semantic conventions. It represents the unique
- // identifier of the feature flag.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'logo-color'
- FeatureFlagKeyKey = attribute.Key("feature_flag.key")
-
- // FeatureFlagProviderNameKey is the attribute Key conforming to the
- // "feature_flag.provider_name" semantic conventions. It represents the
- // name of the service provider that performs the flag evaluation.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'Flag Manager'
- FeatureFlagProviderNameKey = attribute.Key("feature_flag.provider_name")
-
- // FeatureFlagVariantKey is the attribute Key conforming to the
- // "feature_flag.variant" semantic conventions. It represents the sHOULD be
- // a semantic identifier for a value. If one is unavailable, a stringified
- // version of the value can be used.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'red', 'true', 'on'
- // Note: A semantic identifier, commonly referred to as a variant, provides
- // a means
- // for referring to a value without including the value itself. This can
- // provide additional context for understanding the meaning behind a value.
- // For example, the variant `red` maybe be used for the value `#c05543`.
- //
- // A stringified version of the value can be used in situations where a
- // semantic identifier is unavailable. String representation of the value
- // should be determined by the implementer.
- FeatureFlagVariantKey = attribute.Key("feature_flag.variant")
-)
-
-// FeatureFlagKey returns an attribute KeyValue conforming to the
-// "feature_flag.key" semantic conventions. It represents the unique identifier
-// of the feature flag.
-func FeatureFlagKey(val string) attribute.KeyValue {
- return FeatureFlagKeyKey.String(val)
-}
-
-// FeatureFlagProviderName returns an attribute KeyValue conforming to the
-// "feature_flag.provider_name" semantic conventions. It represents the name of
-// the service provider that performs the flag evaluation.
-func FeatureFlagProviderName(val string) attribute.KeyValue {
- return FeatureFlagProviderNameKey.String(val)
-}
-
-// FeatureFlagVariant returns an attribute KeyValue conforming to the
-// "feature_flag.variant" semantic conventions. It represents the sHOULD be a
-// semantic identifier for a value. If one is unavailable, a stringified
-// version of the value can be used.
-func FeatureFlagVariant(val string) attribute.KeyValue {
- return FeatureFlagVariantKey.String(val)
-}
-
-// Describes file attributes.
-const (
- // FileDirectoryKey is the attribute Key conforming to the "file.directory"
- // semantic conventions. It represents the directory where the file is
- // located. It should include the drive letter, when appropriate.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '/home/user', 'C:\\Program Files\\MyApp'
- FileDirectoryKey = attribute.Key("file.directory")
-
- // FileExtensionKey is the attribute Key conforming to the "file.extension"
- // semantic conventions. It represents the file extension, excluding the
- // leading dot.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'png', 'gz'
- // Note: When the file name has multiple extensions (example.tar.gz), only
- // the last one should be captured ("gz", not "tar.gz").
- FileExtensionKey = attribute.Key("file.extension")
-
- // FileNameKey is the attribute Key conforming to the "file.name" semantic
- // conventions. It represents the name of the file including the extension,
- // without the directory.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'example.png'
- FileNameKey = attribute.Key("file.name")
-
- // FilePathKey is the attribute Key conforming to the "file.path" semantic
- // conventions. It represents the full path to the file, including the file
- // name. It should include the drive letter, when appropriate.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '/home/alice/example.png', 'C:\\Program
- // Files\\MyApp\\myapp.exe'
- FilePathKey = attribute.Key("file.path")
-
- // FileSizeKey is the attribute Key conforming to the "file.size" semantic
- // conventions. It represents the file size in bytes.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- FileSizeKey = attribute.Key("file.size")
-)
-
-// FileDirectory returns an attribute KeyValue conforming to the
-// "file.directory" semantic conventions. It represents the directory where the
-// file is located. It should include the drive letter, when appropriate.
-func FileDirectory(val string) attribute.KeyValue {
- return FileDirectoryKey.String(val)
-}
-
-// FileExtension returns an attribute KeyValue conforming to the
-// "file.extension" semantic conventions. It represents the file extension,
-// excluding the leading dot.
-func FileExtension(val string) attribute.KeyValue {
- return FileExtensionKey.String(val)
-}
-
-// FileName returns an attribute KeyValue conforming to the "file.name"
-// semantic conventions. It represents the name of the file including the
-// extension, without the directory.
-func FileName(val string) attribute.KeyValue {
- return FileNameKey.String(val)
-}
-
-// FilePath returns an attribute KeyValue conforming to the "file.path"
-// semantic conventions. It represents the full path to the file, including the
-// file name. It should include the drive letter, when appropriate.
-func FilePath(val string) attribute.KeyValue {
- return FilePathKey.String(val)
-}
-
-// FileSize returns an attribute KeyValue conforming to the "file.size"
-// semantic conventions. It represents the file size in bytes.
-func FileSize(val int) attribute.KeyValue {
- return FileSizeKey.Int(val)
-}
-
-// Attributes for Google Cloud Run.
-const (
- // GCPCloudRunJobExecutionKey is the attribute Key conforming to the
- // "gcp.cloud_run.job.execution" semantic conventions. It represents the
- // name of the Cloud Run
- // [execution](https://cloud.google.com/run/docs/managing/job-executions)
- // being run for the Job, as set by the
- // [`CLOUD_RUN_EXECUTION`](https://cloud.google.com/run/docs/container-contract#jobs-env-vars)
- // environment variable.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'job-name-xxxx', 'sample-job-mdw84'
- GCPCloudRunJobExecutionKey = attribute.Key("gcp.cloud_run.job.execution")
-
- // GCPCloudRunJobTaskIndexKey is the attribute Key conforming to the
- // "gcp.cloud_run.job.task_index" semantic conventions. It represents the
- // index for a task within an execution as provided by the
- // [`CLOUD_RUN_TASK_INDEX`](https://cloud.google.com/run/docs/container-contract#jobs-env-vars)
- // environment variable.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 0, 1
- GCPCloudRunJobTaskIndexKey = attribute.Key("gcp.cloud_run.job.task_index")
-)
-
-// GCPCloudRunJobExecution returns an attribute KeyValue conforming to the
-// "gcp.cloud_run.job.execution" semantic conventions. It represents the name
-// of the Cloud Run
-// [execution](https://cloud.google.com/run/docs/managing/job-executions) being
-// run for the Job, as set by the
-// [`CLOUD_RUN_EXECUTION`](https://cloud.google.com/run/docs/container-contract#jobs-env-vars)
-// environment variable.
-func GCPCloudRunJobExecution(val string) attribute.KeyValue {
- return GCPCloudRunJobExecutionKey.String(val)
-}
-
-// GCPCloudRunJobTaskIndex returns an attribute KeyValue conforming to the
-// "gcp.cloud_run.job.task_index" semantic conventions. It represents the index
-// for a task within an execution as provided by the
-// [`CLOUD_RUN_TASK_INDEX`](https://cloud.google.com/run/docs/container-contract#jobs-env-vars)
-// environment variable.
-func GCPCloudRunJobTaskIndex(val int) attribute.KeyValue {
- return GCPCloudRunJobTaskIndexKey.Int(val)
-}
-
-// Attributes for Google Compute Engine (GCE).
-const (
- // GCPGceInstanceHostnameKey is the attribute Key conforming to the
- // "gcp.gce.instance.hostname" semantic conventions. It represents the
- // hostname of a GCE instance. This is the full value of the default or
- // [custom
- // hostname](https://cloud.google.com/compute/docs/instances/custom-hostname-vm).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'my-host1234.example.com',
- // 'sample-vm.us-west1-b.c.my-project.internal'
- GCPGceInstanceHostnameKey = attribute.Key("gcp.gce.instance.hostname")
-
- // GCPGceInstanceNameKey is the attribute Key conforming to the
- // "gcp.gce.instance.name" semantic conventions. It represents the instance
- // name of a GCE instance. This is the value provided by `host.name`, the
- // visible name of the instance in the Cloud Console UI, and the prefix for
- // the default hostname of the instance as defined by the [default internal
- // DNS
- // name](https://cloud.google.com/compute/docs/internal-dns#instance-fully-qualified-domain-names).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'instance-1', 'my-vm-name'
- GCPGceInstanceNameKey = attribute.Key("gcp.gce.instance.name")
-)
-
-// GCPGceInstanceHostname returns an attribute KeyValue conforming to the
-// "gcp.gce.instance.hostname" semantic conventions. It represents the hostname
-// of a GCE instance. This is the full value of the default or [custom
-// hostname](https://cloud.google.com/compute/docs/instances/custom-hostname-vm).
-func GCPGceInstanceHostname(val string) attribute.KeyValue {
- return GCPGceInstanceHostnameKey.String(val)
-}
-
-// GCPGceInstanceName returns an attribute KeyValue conforming to the
-// "gcp.gce.instance.name" semantic conventions. It represents the instance
-// name of a GCE instance. This is the value provided by `host.name`, the
-// visible name of the instance in the Cloud Console UI, and the prefix for the
-// default hostname of the instance as defined by the [default internal DNS
-// name](https://cloud.google.com/compute/docs/internal-dns#instance-fully-qualified-domain-names).
-func GCPGceInstanceName(val string) attribute.KeyValue {
- return GCPGceInstanceNameKey.String(val)
-}
-
-// The attributes used to describe telemetry in the context of LLM (Large
-// Language Models) requests and responses.
-const (
- // GenAiCompletionKey is the attribute Key conforming to the
- // "gen_ai.completion" semantic conventions. It represents the full
- // response received from the LLM.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: "[{'role': 'assistant', 'content': 'The capital of France is
- // Paris.'}]"
- // Note: It's RECOMMENDED to format completions as JSON string matching
- // [OpenAI messages
- // format](https://platform.openai.com/docs/guides/text-generation)
- GenAiCompletionKey = attribute.Key("gen_ai.completion")
-
- // GenAiPromptKey is the attribute Key conforming to the "gen_ai.prompt"
- // semantic conventions. It represents the full prompt sent to an LLM.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: "[{'role': 'user', 'content': 'What is the capital of
- // France?'}]"
- // Note: It's RECOMMENDED to format prompts as JSON string matching [OpenAI
- // messages
- // format](https://platform.openai.com/docs/guides/text-generation)
- GenAiPromptKey = attribute.Key("gen_ai.prompt")
-
- // GenAiRequestMaxTokensKey is the attribute Key conforming to the
- // "gen_ai.request.max_tokens" semantic conventions. It represents the
- // maximum number of tokens the LLM generates for a request.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 100
- GenAiRequestMaxTokensKey = attribute.Key("gen_ai.request.max_tokens")
-
- // GenAiRequestModelKey is the attribute Key conforming to the
- // "gen_ai.request.model" semantic conventions. It represents the name of
- // the LLM a request is being made to.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'gpt-4'
- GenAiRequestModelKey = attribute.Key("gen_ai.request.model")
-
- // GenAiRequestTemperatureKey is the attribute Key conforming to the
- // "gen_ai.request.temperature" semantic conventions. It represents the
- // temperature setting for the LLM request.
- //
- // Type: double
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 0.0
- GenAiRequestTemperatureKey = attribute.Key("gen_ai.request.temperature")
-
- // GenAiRequestTopPKey is the attribute Key conforming to the
- // "gen_ai.request.top_p" semantic conventions. It represents the top_p
- // sampling setting for the LLM request.
- //
- // Type: double
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 1.0
- GenAiRequestTopPKey = attribute.Key("gen_ai.request.top_p")
-
- // GenAiResponseFinishReasonsKey is the attribute Key conforming to the
- // "gen_ai.response.finish_reasons" semantic conventions. It represents the
- // array of reasons the model stopped generating tokens, corresponding to
- // each generation received.
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'stop'
- GenAiResponseFinishReasonsKey = attribute.Key("gen_ai.response.finish_reasons")
-
- // GenAiResponseIDKey is the attribute Key conforming to the
- // "gen_ai.response.id" semantic conventions. It represents the unique
- // identifier for the completion.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'chatcmpl-123'
- GenAiResponseIDKey = attribute.Key("gen_ai.response.id")
-
- // GenAiResponseModelKey is the attribute Key conforming to the
- // "gen_ai.response.model" semantic conventions. It represents the name of
- // the LLM a response was generated from.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'gpt-4-0613'
- GenAiResponseModelKey = attribute.Key("gen_ai.response.model")
-
- // GenAiSystemKey is the attribute Key conforming to the "gen_ai.system"
- // semantic conventions. It represents the Generative AI product as
- // identified by the client instrumentation.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'openai'
- // Note: The actual GenAI product may differ from the one identified by the
- // client. For example, when using OpenAI client libraries to communicate
- // with Mistral, the `gen_ai.system` is set to `openai` based on the
- // instrumentation's best knowledge.
- GenAiSystemKey = attribute.Key("gen_ai.system")
-
- // GenAiUsageCompletionTokensKey is the attribute Key conforming to the
- // "gen_ai.usage.completion_tokens" semantic conventions. It represents the
- // number of tokens used in the LLM response (completion).
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 180
- GenAiUsageCompletionTokensKey = attribute.Key("gen_ai.usage.completion_tokens")
-
- // GenAiUsagePromptTokensKey is the attribute Key conforming to the
- // "gen_ai.usage.prompt_tokens" semantic conventions. It represents the
- // number of tokens used in the LLM prompt.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 100
- GenAiUsagePromptTokensKey = attribute.Key("gen_ai.usage.prompt_tokens")
-)
-
-var (
- // OpenAI
- GenAiSystemOpenai = GenAiSystemKey.String("openai")
-)
-
-// GenAiCompletion returns an attribute KeyValue conforming to the
-// "gen_ai.completion" semantic conventions. It represents the full response
-// received from the LLM.
-func GenAiCompletion(val string) attribute.KeyValue {
- return GenAiCompletionKey.String(val)
-}
-
-// GenAiPrompt returns an attribute KeyValue conforming to the
-// "gen_ai.prompt" semantic conventions. It represents the full prompt sent to
-// an LLM.
-func GenAiPrompt(val string) attribute.KeyValue {
- return GenAiPromptKey.String(val)
-}
-
-// GenAiRequestMaxTokens returns an attribute KeyValue conforming to the
-// "gen_ai.request.max_tokens" semantic conventions. It represents the maximum
-// number of tokens the LLM generates for a request.
-func GenAiRequestMaxTokens(val int) attribute.KeyValue {
- return GenAiRequestMaxTokensKey.Int(val)
-}
-
-// GenAiRequestModel returns an attribute KeyValue conforming to the
-// "gen_ai.request.model" semantic conventions. It represents the name of the
-// LLM a request is being made to.
-func GenAiRequestModel(val string) attribute.KeyValue {
- return GenAiRequestModelKey.String(val)
-}
-
-// GenAiRequestTemperature returns an attribute KeyValue conforming to the
-// "gen_ai.request.temperature" semantic conventions. It represents the
-// temperature setting for the LLM request.
-func GenAiRequestTemperature(val float64) attribute.KeyValue {
- return GenAiRequestTemperatureKey.Float64(val)
-}
-
-// GenAiRequestTopP returns an attribute KeyValue conforming to the
-// "gen_ai.request.top_p" semantic conventions. It represents the top_p
-// sampling setting for the LLM request.
-func GenAiRequestTopP(val float64) attribute.KeyValue {
- return GenAiRequestTopPKey.Float64(val)
-}
-
-// GenAiResponseFinishReasons returns an attribute KeyValue conforming to
-// the "gen_ai.response.finish_reasons" semantic conventions. It represents the
-// array of reasons the model stopped generating tokens, corresponding to each
-// generation received.
-func GenAiResponseFinishReasons(val ...string) attribute.KeyValue {
- return GenAiResponseFinishReasonsKey.StringSlice(val)
-}
-
-// GenAiResponseID returns an attribute KeyValue conforming to the
-// "gen_ai.response.id" semantic conventions. It represents the unique
-// identifier for the completion.
-func GenAiResponseID(val string) attribute.KeyValue {
- return GenAiResponseIDKey.String(val)
-}
-
-// GenAiResponseModel returns an attribute KeyValue conforming to the
-// "gen_ai.response.model" semantic conventions. It represents the name of the
-// LLM a response was generated from.
-func GenAiResponseModel(val string) attribute.KeyValue {
- return GenAiResponseModelKey.String(val)
-}
-
-// GenAiUsageCompletionTokens returns an attribute KeyValue conforming to
-// the "gen_ai.usage.completion_tokens" semantic conventions. It represents the
-// number of tokens used in the LLM response (completion).
-func GenAiUsageCompletionTokens(val int) attribute.KeyValue {
- return GenAiUsageCompletionTokensKey.Int(val)
-}
-
-// GenAiUsagePromptTokens returns an attribute KeyValue conforming to the
-// "gen_ai.usage.prompt_tokens" semantic conventions. It represents the number
-// of tokens used in the LLM prompt.
-func GenAiUsagePromptTokens(val int) attribute.KeyValue {
- return GenAiUsagePromptTokensKey.Int(val)
-}
-
-// Attributes for GraphQL.
-const (
- // GraphqlDocumentKey is the attribute Key conforming to the
- // "graphql.document" semantic conventions. It represents the GraphQL
- // document being executed.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'query findBookByID { bookByID(id: ?) { name } }'
- // Note: The value may be sanitized to exclude sensitive information.
- GraphqlDocumentKey = attribute.Key("graphql.document")
-
- // GraphqlOperationNameKey is the attribute Key conforming to the
- // "graphql.operation.name" semantic conventions. It represents the name of
- // the operation being executed.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'findBookByID'
- GraphqlOperationNameKey = attribute.Key("graphql.operation.name")
-
- // GraphqlOperationTypeKey is the attribute Key conforming to the
- // "graphql.operation.type" semantic conventions. It represents the type of
- // the operation being executed.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'query', 'mutation', 'subscription'
- GraphqlOperationTypeKey = attribute.Key("graphql.operation.type")
-)
-
-var (
- // GraphQL query
- GraphqlOperationTypeQuery = GraphqlOperationTypeKey.String("query")
- // GraphQL mutation
- GraphqlOperationTypeMutation = GraphqlOperationTypeKey.String("mutation")
- // GraphQL subscription
- GraphqlOperationTypeSubscription = GraphqlOperationTypeKey.String("subscription")
-)
-
-// GraphqlDocument returns an attribute KeyValue conforming to the
-// "graphql.document" semantic conventions. It represents the GraphQL document
-// being executed.
-func GraphqlDocument(val string) attribute.KeyValue {
- return GraphqlDocumentKey.String(val)
-}
-
-// GraphqlOperationName returns an attribute KeyValue conforming to the
-// "graphql.operation.name" semantic conventions. It represents the name of the
-// operation being executed.
-func GraphqlOperationName(val string) attribute.KeyValue {
- return GraphqlOperationNameKey.String(val)
-}
-
-// Attributes for the Android platform on which the Android application is
-// running.
-const (
- // HerokuAppIDKey is the attribute Key conforming to the "heroku.app.id"
- // semantic conventions. It represents the unique identifier for the
- // application
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '2daa2797-e42b-4624-9322-ec3f968df4da'
- HerokuAppIDKey = attribute.Key("heroku.app.id")
-
- // HerokuReleaseCommitKey is the attribute Key conforming to the
- // "heroku.release.commit" semantic conventions. It represents the commit
- // hash for the current release
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'e6134959463efd8966b20e75b913cafe3f5ec'
- HerokuReleaseCommitKey = attribute.Key("heroku.release.commit")
-
- // HerokuReleaseCreationTimestampKey is the attribute Key conforming to the
- // "heroku.release.creation_timestamp" semantic conventions. It represents
- // the time and date the release was created
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '2022-10-23T18:00:42Z'
- HerokuReleaseCreationTimestampKey = attribute.Key("heroku.release.creation_timestamp")
-)
-
-// HerokuAppID returns an attribute KeyValue conforming to the
-// "heroku.app.id" semantic conventions. It represents the unique identifier
-// for the application
-func HerokuAppID(val string) attribute.KeyValue {
- return HerokuAppIDKey.String(val)
-}
-
-// HerokuReleaseCommit returns an attribute KeyValue conforming to the
-// "heroku.release.commit" semantic conventions. It represents the commit hash
-// for the current release
-func HerokuReleaseCommit(val string) attribute.KeyValue {
- return HerokuReleaseCommitKey.String(val)
-}
-
-// HerokuReleaseCreationTimestamp returns an attribute KeyValue conforming
-// to the "heroku.release.creation_timestamp" semantic conventions. It
-// represents the time and date the release was created
-func HerokuReleaseCreationTimestamp(val string) attribute.KeyValue {
- return HerokuReleaseCreationTimestampKey.String(val)
-}
-
-// A host is defined as a computing instance. For example, physical servers,
-// virtual machines, switches or disk array.
-const (
- // HostArchKey is the attribute Key conforming to the "host.arch" semantic
- // conventions. It represents the CPU architecture the host system is
- // running on.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- HostArchKey = attribute.Key("host.arch")
-
- // HostCPUCacheL2SizeKey is the attribute Key conforming to the
- // "host.cpu.cache.l2.size" semantic conventions. It represents the amount
- // of level 2 memory cache available to the processor (in Bytes).
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 12288000
- HostCPUCacheL2SizeKey = attribute.Key("host.cpu.cache.l2.size")
-
- // HostCPUFamilyKey is the attribute Key conforming to the
- // "host.cpu.family" semantic conventions. It represents the family or
- // generation of the CPU.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '6', 'PA-RISC 1.1e'
- HostCPUFamilyKey = attribute.Key("host.cpu.family")
-
- // HostCPUModelIDKey is the attribute Key conforming to the
- // "host.cpu.model.id" semantic conventions. It represents the model
- // identifier. It provides more granular information about the CPU,
- // distinguishing it from other CPUs within the same family.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '6', '9000/778/B180L'
- HostCPUModelIDKey = attribute.Key("host.cpu.model.id")
-
- // HostCPUModelNameKey is the attribute Key conforming to the
- // "host.cpu.model.name" semantic conventions. It represents the model
- // designation of the processor.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '11th Gen Intel(R) Core(TM) i7-1185G7 @ 3.00GHz'
- HostCPUModelNameKey = attribute.Key("host.cpu.model.name")
-
- // HostCPUSteppingKey is the attribute Key conforming to the
- // "host.cpu.stepping" semantic conventions. It represents the stepping or
- // core revisions.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '1', 'r1p1'
- HostCPUSteppingKey = attribute.Key("host.cpu.stepping")
-
- // HostCPUVendorIDKey is the attribute Key conforming to the
- // "host.cpu.vendor.id" semantic conventions. It represents the processor
- // manufacturer identifier. A maximum 12-character string.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'GenuineIntel'
- // Note: [CPUID](https://wiki.osdev.org/CPUID) command returns the vendor
- // ID string in EBX, EDX and ECX registers. Writing these to memory in this
- // order results in a 12-character string.
- HostCPUVendorIDKey = attribute.Key("host.cpu.vendor.id")
-
- // HostIDKey is the attribute Key conforming to the "host.id" semantic
- // conventions. It represents the unique host ID. For Cloud, this must be
- // the instance_id assigned by the cloud provider. For non-containerized
- // systems, this should be the `machine-id`. See the table below for the
- // sources to use to determine the `machine-id` based on operating system.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'fdbf79e8af94cb7f9e8df36789187052'
- HostIDKey = attribute.Key("host.id")
-
- // HostImageIDKey is the attribute Key conforming to the "host.image.id"
- // semantic conventions. It represents the vM image ID or host OS image ID.
- // For Cloud, this value is from the provider.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'ami-07b06b442921831e5'
- HostImageIDKey = attribute.Key("host.image.id")
-
- // HostImageNameKey is the attribute Key conforming to the
- // "host.image.name" semantic conventions. It represents the name of the VM
- // image or OS install the host was instantiated from.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'infra-ami-eks-worker-node-7d4ec78312', 'CentOS-8-x86_64-1905'
- HostImageNameKey = attribute.Key("host.image.name")
-
- // HostImageVersionKey is the attribute Key conforming to the
- // "host.image.version" semantic conventions. It represents the version
- // string of the VM image or host OS as defined in [Version
- // Attributes](/docs/resource/README.md#version-attributes).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '0.1'
- HostImageVersionKey = attribute.Key("host.image.version")
-
- // HostIPKey is the attribute Key conforming to the "host.ip" semantic
- // conventions. It represents the available IP addresses of the host,
- // excluding loopback interfaces.
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '192.168.1.140', 'fe80::abc2:4a28:737a:609e'
- // Note: IPv4 Addresses MUST be specified in dotted-quad notation. IPv6
- // addresses MUST be specified in the [RFC
- // 5952](https://www.rfc-editor.org/rfc/rfc5952.html) format.
- HostIPKey = attribute.Key("host.ip")
-
- // HostMacKey is the attribute Key conforming to the "host.mac" semantic
- // conventions. It represents the available MAC addresses of the host,
- // excluding loopback interfaces.
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'AC-DE-48-23-45-67', 'AC-DE-48-23-45-67-01-9F'
- // Note: MAC Addresses MUST be represented in [IEEE RA hexadecimal
- // form](https://standards.ieee.org/wp-content/uploads/import/documents/tutorials/eui.pdf):
- // as hyphen-separated octets in uppercase hexadecimal form from most to
- // least significant.
- HostMacKey = attribute.Key("host.mac")
-
- // HostNameKey is the attribute Key conforming to the "host.name" semantic
- // conventions. It represents the name of the host. On Unix systems, it may
- // contain what the hostname command returns, or the fully qualified
- // hostname, or another name specified by the user.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'opentelemetry-test'
- HostNameKey = attribute.Key("host.name")
-
- // HostTypeKey is the attribute Key conforming to the "host.type" semantic
- // conventions. It represents the type of host. For Cloud, this must be the
- // machine type.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'n1-standard-1'
- HostTypeKey = attribute.Key("host.type")
-)
-
-var (
- // AMD64
- HostArchAMD64 = HostArchKey.String("amd64")
- // ARM32
- HostArchARM32 = HostArchKey.String("arm32")
- // ARM64
- HostArchARM64 = HostArchKey.String("arm64")
- // Itanium
- HostArchIA64 = HostArchKey.String("ia64")
- // 32-bit PowerPC
- HostArchPPC32 = HostArchKey.String("ppc32")
- // 64-bit PowerPC
- HostArchPPC64 = HostArchKey.String("ppc64")
- // IBM z/Architecture
- HostArchS390x = HostArchKey.String("s390x")
- // 32-bit x86
- HostArchX86 = HostArchKey.String("x86")
-)
-
-// HostCPUCacheL2Size returns an attribute KeyValue conforming to the
-// "host.cpu.cache.l2.size" semantic conventions. It represents the amount of
-// level 2 memory cache available to the processor (in Bytes).
-func HostCPUCacheL2Size(val int) attribute.KeyValue {
- return HostCPUCacheL2SizeKey.Int(val)
-}
-
-// HostCPUFamily returns an attribute KeyValue conforming to the
-// "host.cpu.family" semantic conventions. It represents the family or
-// generation of the CPU.
-func HostCPUFamily(val string) attribute.KeyValue {
- return HostCPUFamilyKey.String(val)
-}
-
-// HostCPUModelID returns an attribute KeyValue conforming to the
-// "host.cpu.model.id" semantic conventions. It represents the model
-// identifier. It provides more granular information about the CPU,
-// distinguishing it from other CPUs within the same family.
-func HostCPUModelID(val string) attribute.KeyValue {
- return HostCPUModelIDKey.String(val)
-}
-
-// HostCPUModelName returns an attribute KeyValue conforming to the
-// "host.cpu.model.name" semantic conventions. It represents the model
-// designation of the processor.
-func HostCPUModelName(val string) attribute.KeyValue {
- return HostCPUModelNameKey.String(val)
-}
-
-// HostCPUStepping returns an attribute KeyValue conforming to the
-// "host.cpu.stepping" semantic conventions. It represents the stepping or core
-// revisions.
-func HostCPUStepping(val string) attribute.KeyValue {
- return HostCPUSteppingKey.String(val)
-}
-
-// HostCPUVendorID returns an attribute KeyValue conforming to the
-// "host.cpu.vendor.id" semantic conventions. It represents the processor
-// manufacturer identifier. A maximum 12-character string.
-func HostCPUVendorID(val string) attribute.KeyValue {
- return HostCPUVendorIDKey.String(val)
-}
-
-// HostID returns an attribute KeyValue conforming to the "host.id" semantic
-// conventions. It represents the unique host ID. For Cloud, this must be the
-// instance_id assigned by the cloud provider. For non-containerized systems,
-// this should be the `machine-id`. See the table below for the sources to use
-// to determine the `machine-id` based on operating system.
-func HostID(val string) attribute.KeyValue {
- return HostIDKey.String(val)
-}
-
-// HostImageID returns an attribute KeyValue conforming to the
-// "host.image.id" semantic conventions. It represents the vM image ID or host
-// OS image ID. For Cloud, this value is from the provider.
-func HostImageID(val string) attribute.KeyValue {
- return HostImageIDKey.String(val)
-}
-
-// HostImageName returns an attribute KeyValue conforming to the
-// "host.image.name" semantic conventions. It represents the name of the VM
-// image or OS install the host was instantiated from.
-func HostImageName(val string) attribute.KeyValue {
- return HostImageNameKey.String(val)
-}
-
-// HostImageVersion returns an attribute KeyValue conforming to the
-// "host.image.version" semantic conventions. It represents the version string
-// of the VM image or host OS as defined in [Version
-// Attributes](/docs/resource/README.md#version-attributes).
-func HostImageVersion(val string) attribute.KeyValue {
- return HostImageVersionKey.String(val)
-}
-
-// HostIP returns an attribute KeyValue conforming to the "host.ip" semantic
-// conventions. It represents the available IP addresses of the host, excluding
-// loopback interfaces.
-func HostIP(val ...string) attribute.KeyValue {
- return HostIPKey.StringSlice(val)
-}
-
-// HostMac returns an attribute KeyValue conforming to the "host.mac"
-// semantic conventions. It represents the available MAC addresses of the host,
-// excluding loopback interfaces.
-func HostMac(val ...string) attribute.KeyValue {
- return HostMacKey.StringSlice(val)
-}
-
-// HostName returns an attribute KeyValue conforming to the "host.name"
-// semantic conventions. It represents the name of the host. On Unix systems,
-// it may contain what the hostname command returns, or the fully qualified
-// hostname, or another name specified by the user.
-func HostName(val string) attribute.KeyValue {
- return HostNameKey.String(val)
-}
-
-// HostType returns an attribute KeyValue conforming to the "host.type"
-// semantic conventions. It represents the type of host. For Cloud, this must
-// be the machine type.
-func HostType(val string) attribute.KeyValue {
- return HostTypeKey.String(val)
-}
-
-// Semantic convention attributes in the HTTP namespace.
-const (
- // HTTPConnectionStateKey is the attribute Key conforming to the
- // "http.connection.state" semantic conventions. It represents the state of
- // the HTTP connection in the HTTP connection pool.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'active', 'idle'
- HTTPConnectionStateKey = attribute.Key("http.connection.state")
-
- // HTTPRequestBodySizeKey is the attribute Key conforming to the
- // "http.request.body.size" semantic conventions. It represents the size of
- // the request payload body in bytes. This is the number of bytes
- // transferred excluding headers and is often, but not always, present as
- // the
- // [Content-Length](https://www.rfc-editor.org/rfc/rfc9110.html#field.content-length)
- // header. For requests using transport encoding, this should be the
- // compressed size.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 3495
- HTTPRequestBodySizeKey = attribute.Key("http.request.body.size")
-
- // HTTPRequestMethodKey is the attribute Key conforming to the
- // "http.request.method" semantic conventions. It represents the hTTP
- // request method.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'GET', 'POST', 'HEAD'
- // Note: HTTP request method value SHOULD be "known" to the
- // instrumentation.
- // By default, this convention defines "known" methods as the ones listed
- // in [RFC9110](https://www.rfc-editor.org/rfc/rfc9110.html#name-methods)
- // and the PATCH method defined in
- // [RFC5789](https://www.rfc-editor.org/rfc/rfc5789.html).
- //
- // If the HTTP request method is not known to instrumentation, it MUST set
- // the `http.request.method` attribute to `_OTHER`.
- //
- // If the HTTP instrumentation could end up converting valid HTTP request
- // methods to `_OTHER`, then it MUST provide a way to override
- // the list of known HTTP methods. If this override is done via environment
- // variable, then the environment variable MUST be named
- // OTEL_INSTRUMENTATION_HTTP_KNOWN_METHODS and support a comma-separated
- // list of case-sensitive known HTTP methods
- // (this list MUST be a full override of the default known method, it is
- // not a list of known methods in addition to the defaults).
- //
- // HTTP method names are case-sensitive and `http.request.method` attribute
- // value MUST match a known HTTP method name exactly.
- // Instrumentations for specific web frameworks that consider HTTP methods
- // to be case insensitive, SHOULD populate a canonical equivalent.
- // Tracing instrumentations that do so, MUST also set
- // `http.request.method_original` to the original value.
- HTTPRequestMethodKey = attribute.Key("http.request.method")
-
- // HTTPRequestMethodOriginalKey is the attribute Key conforming to the
- // "http.request.method_original" semantic conventions. It represents the
- // original HTTP method sent by the client in the request line.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'GeT', 'ACL', 'foo'
- HTTPRequestMethodOriginalKey = attribute.Key("http.request.method_original")
-
- // HTTPRequestResendCountKey is the attribute Key conforming to the
- // "http.request.resend_count" semantic conventions. It represents the
- // ordinal number of request resending attempt (for any reason, including
- // redirects).
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 3
- // Note: The resend count SHOULD be updated each time an HTTP request gets
- // resent by the client, regardless of what was the cause of the resending
- // (e.g. redirection, authorization failure, 503 Server Unavailable,
- // network issues, or any other).
- HTTPRequestResendCountKey = attribute.Key("http.request.resend_count")
-
- // HTTPRequestSizeKey is the attribute Key conforming to the
- // "http.request.size" semantic conventions. It represents the total size
- // of the request in bytes. This should be the total number of bytes sent
- // over the wire, including the request line (HTTP/1.1), framing (HTTP/2
- // and HTTP/3), headers, and request body if any.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 1437
- HTTPRequestSizeKey = attribute.Key("http.request.size")
-
- // HTTPResponseBodySizeKey is the attribute Key conforming to the
- // "http.response.body.size" semantic conventions. It represents the size
- // of the response payload body in bytes. This is the number of bytes
- // transferred excluding headers and is often, but not always, present as
- // the
- // [Content-Length](https://www.rfc-editor.org/rfc/rfc9110.html#field.content-length)
- // header. For requests using transport encoding, this should be the
- // compressed size.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 3495
- HTTPResponseBodySizeKey = attribute.Key("http.response.body.size")
-
- // HTTPResponseSizeKey is the attribute Key conforming to the
- // "http.response.size" semantic conventions. It represents the total size
- // of the response in bytes. This should be the total number of bytes sent
- // over the wire, including the status line (HTTP/1.1), framing (HTTP/2 and
- // HTTP/3), headers, and response body and trailers if any.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 1437
- HTTPResponseSizeKey = attribute.Key("http.response.size")
-
- // HTTPResponseStatusCodeKey is the attribute Key conforming to the
- // "http.response.status_code" semantic conventions. It represents the
- // [HTTP response status
- // code](https://tools.ietf.org/html/rfc7231#section-6).
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 200
- HTTPResponseStatusCodeKey = attribute.Key("http.response.status_code")
-
- // HTTPRouteKey is the attribute Key conforming to the "http.route"
- // semantic conventions. It represents the matched route, that is, the path
- // template in the format used by the respective server framework.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '/users/:userID?', '{controller}/{action}/{id?}'
- // Note: MUST NOT be populated when this is not supported by the HTTP
- // server framework as the route attribute should have low-cardinality and
- // the URI path can NOT substitute it.
- // SHOULD include the [application
- // root](/docs/http/http-spans.md#http-server-definitions) if there is one.
- HTTPRouteKey = attribute.Key("http.route")
-)
-
-var (
- // active state
- HTTPConnectionStateActive = HTTPConnectionStateKey.String("active")
- // idle state
- HTTPConnectionStateIdle = HTTPConnectionStateKey.String("idle")
-)
-
-var (
- // CONNECT method
- HTTPRequestMethodConnect = HTTPRequestMethodKey.String("CONNECT")
- // DELETE method
- HTTPRequestMethodDelete = HTTPRequestMethodKey.String("DELETE")
- // GET method
- HTTPRequestMethodGet = HTTPRequestMethodKey.String("GET")
- // HEAD method
- HTTPRequestMethodHead = HTTPRequestMethodKey.String("HEAD")
- // OPTIONS method
- HTTPRequestMethodOptions = HTTPRequestMethodKey.String("OPTIONS")
- // PATCH method
- HTTPRequestMethodPatch = HTTPRequestMethodKey.String("PATCH")
- // POST method
- HTTPRequestMethodPost = HTTPRequestMethodKey.String("POST")
- // PUT method
- HTTPRequestMethodPut = HTTPRequestMethodKey.String("PUT")
- // TRACE method
- HTTPRequestMethodTrace = HTTPRequestMethodKey.String("TRACE")
- // Any HTTP method that the instrumentation has no prior knowledge of
- HTTPRequestMethodOther = HTTPRequestMethodKey.String("_OTHER")
-)
-
-// HTTPRequestBodySize returns an attribute KeyValue conforming to the
-// "http.request.body.size" semantic conventions. It represents the size of the
-// request payload body in bytes. This is the number of bytes transferred
-// excluding headers and is often, but not always, present as the
-// [Content-Length](https://www.rfc-editor.org/rfc/rfc9110.html#field.content-length)
-// header. For requests using transport encoding, this should be the compressed
-// size.
-func HTTPRequestBodySize(val int) attribute.KeyValue {
- return HTTPRequestBodySizeKey.Int(val)
-}
-
-// HTTPRequestMethodOriginal returns an attribute KeyValue conforming to the
-// "http.request.method_original" semantic conventions. It represents the
-// original HTTP method sent by the client in the request line.
-func HTTPRequestMethodOriginal(val string) attribute.KeyValue {
- return HTTPRequestMethodOriginalKey.String(val)
-}
-
-// HTTPRequestResendCount returns an attribute KeyValue conforming to the
-// "http.request.resend_count" semantic conventions. It represents the ordinal
-// number of request resending attempt (for any reason, including redirects).
-func HTTPRequestResendCount(val int) attribute.KeyValue {
- return HTTPRequestResendCountKey.Int(val)
-}
-
-// HTTPRequestSize returns an attribute KeyValue conforming to the
-// "http.request.size" semantic conventions. It represents the total size of
-// the request in bytes. This should be the total number of bytes sent over the
-// wire, including the request line (HTTP/1.1), framing (HTTP/2 and HTTP/3),
-// headers, and request body if any.
-func HTTPRequestSize(val int) attribute.KeyValue {
- return HTTPRequestSizeKey.Int(val)
-}
-
-// HTTPResponseBodySize returns an attribute KeyValue conforming to the
-// "http.response.body.size" semantic conventions. It represents the size of
-// the response payload body in bytes. This is the number of bytes transferred
-// excluding headers and is often, but not always, present as the
-// [Content-Length](https://www.rfc-editor.org/rfc/rfc9110.html#field.content-length)
-// header. For requests using transport encoding, this should be the compressed
-// size.
-func HTTPResponseBodySize(val int) attribute.KeyValue {
- return HTTPResponseBodySizeKey.Int(val)
-}
-
-// HTTPResponseSize returns an attribute KeyValue conforming to the
-// "http.response.size" semantic conventions. It represents the total size of
-// the response in bytes. This should be the total number of bytes sent over
-// the wire, including the status line (HTTP/1.1), framing (HTTP/2 and HTTP/3),
-// headers, and response body and trailers if any.
-func HTTPResponseSize(val int) attribute.KeyValue {
- return HTTPResponseSizeKey.Int(val)
-}
-
-// HTTPResponseStatusCode returns an attribute KeyValue conforming to the
-// "http.response.status_code" semantic conventions. It represents the [HTTP
-// response status code](https://tools.ietf.org/html/rfc7231#section-6).
-func HTTPResponseStatusCode(val int) attribute.KeyValue {
- return HTTPResponseStatusCodeKey.Int(val)
-}
-
-// HTTPRoute returns an attribute KeyValue conforming to the "http.route"
-// semantic conventions. It represents the matched route, that is, the path
-// template in the format used by the respective server framework.
-func HTTPRoute(val string) attribute.KeyValue {
- return HTTPRouteKey.String(val)
-}
-
-// Java Virtual machine related attributes.
-const (
- // JvmBufferPoolNameKey is the attribute Key conforming to the
- // "jvm.buffer.pool.name" semantic conventions. It represents the name of
- // the buffer pool.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'mapped', 'direct'
- // Note: Pool names are generally obtained via
- // [BufferPoolMXBean#getName()](https://docs.oracle.com/en/java/javase/11/docs/api/java.management/java/lang/management/BufferPoolMXBean.html#getName()).
- JvmBufferPoolNameKey = attribute.Key("jvm.buffer.pool.name")
-
- // JvmGcActionKey is the attribute Key conforming to the "jvm.gc.action"
- // semantic conventions. It represents the name of the garbage collector
- // action.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'end of minor GC', 'end of major GC'
- // Note: Garbage collector action is generally obtained via
- // [GarbageCollectionNotificationInfo#getGcAction()](https://docs.oracle.com/en/java/javase/11/docs/api/jdk.management/com/sun/management/GarbageCollectionNotificationInfo.html#getGcAction()).
- JvmGcActionKey = attribute.Key("jvm.gc.action")
-
- // JvmGcNameKey is the attribute Key conforming to the "jvm.gc.name"
- // semantic conventions. It represents the name of the garbage collector.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'G1 Young Generation', 'G1 Old Generation'
- // Note: Garbage collector name is generally obtained via
- // [GarbageCollectionNotificationInfo#getGcName()](https://docs.oracle.com/en/java/javase/11/docs/api/jdk.management/com/sun/management/GarbageCollectionNotificationInfo.html#getGcName()).
- JvmGcNameKey = attribute.Key("jvm.gc.name")
-
- // JvmMemoryPoolNameKey is the attribute Key conforming to the
- // "jvm.memory.pool.name" semantic conventions. It represents the name of
- // the memory pool.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'G1 Old Gen', 'G1 Eden space', 'G1 Survivor Space'
- // Note: Pool names are generally obtained via
- // [MemoryPoolMXBean#getName()](https://docs.oracle.com/en/java/javase/11/docs/api/java.management/java/lang/management/MemoryPoolMXBean.html#getName()).
- JvmMemoryPoolNameKey = attribute.Key("jvm.memory.pool.name")
-
- // JvmMemoryTypeKey is the attribute Key conforming to the
- // "jvm.memory.type" semantic conventions. It represents the type of
- // memory.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'heap', 'non_heap'
- JvmMemoryTypeKey = attribute.Key("jvm.memory.type")
-
- // JvmThreadDaemonKey is the attribute Key conforming to the
- // "jvm.thread.daemon" semantic conventions. It represents the whether the
- // thread is daemon or not.
- //
- // Type: boolean
- // RequirementLevel: Optional
- // Stability: stable
- JvmThreadDaemonKey = attribute.Key("jvm.thread.daemon")
-
- // JvmThreadStateKey is the attribute Key conforming to the
- // "jvm.thread.state" semantic conventions. It represents the state of the
- // thread.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'runnable', 'blocked'
- JvmThreadStateKey = attribute.Key("jvm.thread.state")
-)
-
-var (
- // Heap memory
- JvmMemoryTypeHeap = JvmMemoryTypeKey.String("heap")
- // Non-heap memory
- JvmMemoryTypeNonHeap = JvmMemoryTypeKey.String("non_heap")
-)
-
-var (
- // A thread that has not yet started is in this state
- JvmThreadStateNew = JvmThreadStateKey.String("new")
- // A thread executing in the Java virtual machine is in this state
- JvmThreadStateRunnable = JvmThreadStateKey.String("runnable")
- // A thread that is blocked waiting for a monitor lock is in this state
- JvmThreadStateBlocked = JvmThreadStateKey.String("blocked")
- // A thread that is waiting indefinitely for another thread to perform a particular action is in this state
- JvmThreadStateWaiting = JvmThreadStateKey.String("waiting")
- // A thread that is waiting for another thread to perform an action for up to a specified waiting time is in this state
- JvmThreadStateTimedWaiting = JvmThreadStateKey.String("timed_waiting")
- // A thread that has exited is in this state
- JvmThreadStateTerminated = JvmThreadStateKey.String("terminated")
-)
-
-// JvmBufferPoolName returns an attribute KeyValue conforming to the
-// "jvm.buffer.pool.name" semantic conventions. It represents the name of the
-// buffer pool.
-func JvmBufferPoolName(val string) attribute.KeyValue {
- return JvmBufferPoolNameKey.String(val)
-}
-
-// JvmGcAction returns an attribute KeyValue conforming to the
-// "jvm.gc.action" semantic conventions. It represents the name of the garbage
-// collector action.
-func JvmGcAction(val string) attribute.KeyValue {
- return JvmGcActionKey.String(val)
-}
-
-// JvmGcName returns an attribute KeyValue conforming to the "jvm.gc.name"
-// semantic conventions. It represents the name of the garbage collector.
-func JvmGcName(val string) attribute.KeyValue {
- return JvmGcNameKey.String(val)
-}
-
-// JvmMemoryPoolName returns an attribute KeyValue conforming to the
-// "jvm.memory.pool.name" semantic conventions. It represents the name of the
-// memory pool.
-func JvmMemoryPoolName(val string) attribute.KeyValue {
- return JvmMemoryPoolNameKey.String(val)
-}
-
-// JvmThreadDaemon returns an attribute KeyValue conforming to the
-// "jvm.thread.daemon" semantic conventions. It represents the whether the
-// thread is daemon or not.
-func JvmThreadDaemon(val bool) attribute.KeyValue {
- return JvmThreadDaemonKey.Bool(val)
-}
-
-// Kubernetes resource attributes.
-const (
- // K8SClusterNameKey is the attribute Key conforming to the
- // "k8s.cluster.name" semantic conventions. It represents the name of the
- // cluster.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'opentelemetry-cluster'
- K8SClusterNameKey = attribute.Key("k8s.cluster.name")
-
- // K8SClusterUIDKey is the attribute Key conforming to the
- // "k8s.cluster.uid" semantic conventions. It represents a pseudo-ID for
- // the cluster, set to the UID of the `kube-system` namespace.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '218fc5a9-a5f1-4b54-aa05-46717d0ab26d'
- // Note: K8S doesn't have support for obtaining a cluster ID. If this is
- // ever
- // added, we will recommend collecting the `k8s.cluster.uid` through the
- // official APIs. In the meantime, we are able to use the `uid` of the
- // `kube-system` namespace as a proxy for cluster ID. Read on for the
- // rationale.
- //
- // Every object created in a K8S cluster is assigned a distinct UID. The
- // `kube-system` namespace is used by Kubernetes itself and will exist
- // for the lifetime of the cluster. Using the `uid` of the `kube-system`
- // namespace is a reasonable proxy for the K8S ClusterID as it will only
- // change if the cluster is rebuilt. Furthermore, Kubernetes UIDs are
- // UUIDs as standardized by
- // [ISO/IEC 9834-8 and ITU-T
- // X.667](https://www.itu.int/ITU-T/studygroups/com17/oid.html).
- // Which states:
- //
- // > If generated according to one of the mechanisms defined in Rec.
- // ITU-T X.667 | ISO/IEC 9834-8, a UUID is either guaranteed to be
- // different from all other UUIDs generated before 3603 A.D., or is
- // extremely likely to be different (depending on the mechanism chosen).
- //
- // Therefore, UIDs between clusters should be extremely unlikely to
- // conflict.
- K8SClusterUIDKey = attribute.Key("k8s.cluster.uid")
-
- // K8SContainerNameKey is the attribute Key conforming to the
- // "k8s.container.name" semantic conventions. It represents the name of the
- // Container from Pod specification, must be unique within a Pod. Container
- // runtime usually uses different globally unique name (`container.name`).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'redis'
- K8SContainerNameKey = attribute.Key("k8s.container.name")
-
- // K8SContainerRestartCountKey is the attribute Key conforming to the
- // "k8s.container.restart_count" semantic conventions. It represents the
- // number of times the container was restarted. This attribute can be used
- // to identify a particular container (running or stopped) within a
- // container spec.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- K8SContainerRestartCountKey = attribute.Key("k8s.container.restart_count")
-
- // K8SContainerStatusLastTerminatedReasonKey is the attribute Key
- // conforming to the "k8s.container.status.last_terminated_reason" semantic
- // conventions. It represents the last terminated reason of the Container.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'Evicted', 'Error'
- K8SContainerStatusLastTerminatedReasonKey = attribute.Key("k8s.container.status.last_terminated_reason")
-
- // K8SCronJobNameKey is the attribute Key conforming to the
- // "k8s.cronjob.name" semantic conventions. It represents the name of the
- // CronJob.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'opentelemetry'
- K8SCronJobNameKey = attribute.Key("k8s.cronjob.name")
-
- // K8SCronJobUIDKey is the attribute Key conforming to the
- // "k8s.cronjob.uid" semantic conventions. It represents the UID of the
- // CronJob.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '275ecb36-5aa8-4c2a-9c47-d8bb681b9aff'
- K8SCronJobUIDKey = attribute.Key("k8s.cronjob.uid")
-
- // K8SDaemonSetNameKey is the attribute Key conforming to the
- // "k8s.daemonset.name" semantic conventions. It represents the name of the
- // DaemonSet.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'opentelemetry'
- K8SDaemonSetNameKey = attribute.Key("k8s.daemonset.name")
-
- // K8SDaemonSetUIDKey is the attribute Key conforming to the
- // "k8s.daemonset.uid" semantic conventions. It represents the UID of the
- // DaemonSet.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '275ecb36-5aa8-4c2a-9c47-d8bb681b9aff'
- K8SDaemonSetUIDKey = attribute.Key("k8s.daemonset.uid")
-
- // K8SDeploymentNameKey is the attribute Key conforming to the
- // "k8s.deployment.name" semantic conventions. It represents the name of
- // the Deployment.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'opentelemetry'
- K8SDeploymentNameKey = attribute.Key("k8s.deployment.name")
-
- // K8SDeploymentUIDKey is the attribute Key conforming to the
- // "k8s.deployment.uid" semantic conventions. It represents the UID of the
- // Deployment.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '275ecb36-5aa8-4c2a-9c47-d8bb681b9aff'
- K8SDeploymentUIDKey = attribute.Key("k8s.deployment.uid")
-
- // K8SJobNameKey is the attribute Key conforming to the "k8s.job.name"
- // semantic conventions. It represents the name of the Job.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'opentelemetry'
- K8SJobNameKey = attribute.Key("k8s.job.name")
-
- // K8SJobUIDKey is the attribute Key conforming to the "k8s.job.uid"
- // semantic conventions. It represents the UID of the Job.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '275ecb36-5aa8-4c2a-9c47-d8bb681b9aff'
- K8SJobUIDKey = attribute.Key("k8s.job.uid")
-
- // K8SNamespaceNameKey is the attribute Key conforming to the
- // "k8s.namespace.name" semantic conventions. It represents the name of the
- // namespace that the pod is running in.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'default'
- K8SNamespaceNameKey = attribute.Key("k8s.namespace.name")
-
- // K8SNodeNameKey is the attribute Key conforming to the "k8s.node.name"
- // semantic conventions. It represents the name of the Node.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'node-1'
- K8SNodeNameKey = attribute.Key("k8s.node.name")
-
- // K8SNodeUIDKey is the attribute Key conforming to the "k8s.node.uid"
- // semantic conventions. It represents the UID of the Node.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '1eb3a0c6-0477-4080-a9cb-0cb7db65c6a2'
- K8SNodeUIDKey = attribute.Key("k8s.node.uid")
-
- // K8SPodNameKey is the attribute Key conforming to the "k8s.pod.name"
- // semantic conventions. It represents the name of the Pod.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'opentelemetry-pod-autoconf'
- K8SPodNameKey = attribute.Key("k8s.pod.name")
-
- // K8SPodUIDKey is the attribute Key conforming to the "k8s.pod.uid"
- // semantic conventions. It represents the UID of the Pod.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '275ecb36-5aa8-4c2a-9c47-d8bb681b9aff'
- K8SPodUIDKey = attribute.Key("k8s.pod.uid")
-
- // K8SReplicaSetNameKey is the attribute Key conforming to the
- // "k8s.replicaset.name" semantic conventions. It represents the name of
- // the ReplicaSet.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'opentelemetry'
- K8SReplicaSetNameKey = attribute.Key("k8s.replicaset.name")
-
- // K8SReplicaSetUIDKey is the attribute Key conforming to the
- // "k8s.replicaset.uid" semantic conventions. It represents the UID of the
- // ReplicaSet.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '275ecb36-5aa8-4c2a-9c47-d8bb681b9aff'
- K8SReplicaSetUIDKey = attribute.Key("k8s.replicaset.uid")
-
- // K8SStatefulSetNameKey is the attribute Key conforming to the
- // "k8s.statefulset.name" semantic conventions. It represents the name of
- // the StatefulSet.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'opentelemetry'
- K8SStatefulSetNameKey = attribute.Key("k8s.statefulset.name")
-
- // K8SStatefulSetUIDKey is the attribute Key conforming to the
- // "k8s.statefulset.uid" semantic conventions. It represents the UID of the
- // StatefulSet.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '275ecb36-5aa8-4c2a-9c47-d8bb681b9aff'
- K8SStatefulSetUIDKey = attribute.Key("k8s.statefulset.uid")
-)
-
-// K8SClusterName returns an attribute KeyValue conforming to the
-// "k8s.cluster.name" semantic conventions. It represents the name of the
-// cluster.
-func K8SClusterName(val string) attribute.KeyValue {
- return K8SClusterNameKey.String(val)
-}
-
-// K8SClusterUID returns an attribute KeyValue conforming to the
-// "k8s.cluster.uid" semantic conventions. It represents a pseudo-ID for the
-// cluster, set to the UID of the `kube-system` namespace.
-func K8SClusterUID(val string) attribute.KeyValue {
- return K8SClusterUIDKey.String(val)
-}
-
-// K8SContainerName returns an attribute KeyValue conforming to the
-// "k8s.container.name" semantic conventions. It represents the name of the
-// Container from Pod specification, must be unique within a Pod. Container
-// runtime usually uses different globally unique name (`container.name`).
-func K8SContainerName(val string) attribute.KeyValue {
- return K8SContainerNameKey.String(val)
-}
-
-// K8SContainerRestartCount returns an attribute KeyValue conforming to the
-// "k8s.container.restart_count" semantic conventions. It represents the number
-// of times the container was restarted. This attribute can be used to identify
-// a particular container (running or stopped) within a container spec.
-func K8SContainerRestartCount(val int) attribute.KeyValue {
- return K8SContainerRestartCountKey.Int(val)
-}
-
-// K8SContainerStatusLastTerminatedReason returns an attribute KeyValue
-// conforming to the "k8s.container.status.last_terminated_reason" semantic
-// conventions. It represents the last terminated reason of the Container.
-func K8SContainerStatusLastTerminatedReason(val string) attribute.KeyValue {
- return K8SContainerStatusLastTerminatedReasonKey.String(val)
-}
-
-// K8SCronJobName returns an attribute KeyValue conforming to the
-// "k8s.cronjob.name" semantic conventions. It represents the name of the
-// CronJob.
-func K8SCronJobName(val string) attribute.KeyValue {
- return K8SCronJobNameKey.String(val)
-}
-
-// K8SCronJobUID returns an attribute KeyValue conforming to the
-// "k8s.cronjob.uid" semantic conventions. It represents the UID of the
-// CronJob.
-func K8SCronJobUID(val string) attribute.KeyValue {
- return K8SCronJobUIDKey.String(val)
-}
-
-// K8SDaemonSetName returns an attribute KeyValue conforming to the
-// "k8s.daemonset.name" semantic conventions. It represents the name of the
-// DaemonSet.
-func K8SDaemonSetName(val string) attribute.KeyValue {
- return K8SDaemonSetNameKey.String(val)
-}
-
-// K8SDaemonSetUID returns an attribute KeyValue conforming to the
-// "k8s.daemonset.uid" semantic conventions. It represents the UID of the
-// DaemonSet.
-func K8SDaemonSetUID(val string) attribute.KeyValue {
- return K8SDaemonSetUIDKey.String(val)
-}
-
-// K8SDeploymentName returns an attribute KeyValue conforming to the
-// "k8s.deployment.name" semantic conventions. It represents the name of the
-// Deployment.
-func K8SDeploymentName(val string) attribute.KeyValue {
- return K8SDeploymentNameKey.String(val)
-}
-
-// K8SDeploymentUID returns an attribute KeyValue conforming to the
-// "k8s.deployment.uid" semantic conventions. It represents the UID of the
-// Deployment.
-func K8SDeploymentUID(val string) attribute.KeyValue {
- return K8SDeploymentUIDKey.String(val)
-}
-
-// K8SJobName returns an attribute KeyValue conforming to the "k8s.job.name"
-// semantic conventions. It represents the name of the Job.
-func K8SJobName(val string) attribute.KeyValue {
- return K8SJobNameKey.String(val)
-}
-
-// K8SJobUID returns an attribute KeyValue conforming to the "k8s.job.uid"
-// semantic conventions. It represents the UID of the Job.
-func K8SJobUID(val string) attribute.KeyValue {
- return K8SJobUIDKey.String(val)
-}
-
-// K8SNamespaceName returns an attribute KeyValue conforming to the
-// "k8s.namespace.name" semantic conventions. It represents the name of the
-// namespace that the pod is running in.
-func K8SNamespaceName(val string) attribute.KeyValue {
- return K8SNamespaceNameKey.String(val)
-}
-
-// K8SNodeName returns an attribute KeyValue conforming to the
-// "k8s.node.name" semantic conventions. It represents the name of the Node.
-func K8SNodeName(val string) attribute.KeyValue {
- return K8SNodeNameKey.String(val)
-}
-
-// K8SNodeUID returns an attribute KeyValue conforming to the "k8s.node.uid"
-// semantic conventions. It represents the UID of the Node.
-func K8SNodeUID(val string) attribute.KeyValue {
- return K8SNodeUIDKey.String(val)
-}
-
-// K8SPodName returns an attribute KeyValue conforming to the "k8s.pod.name"
-// semantic conventions. It represents the name of the Pod.
-func K8SPodName(val string) attribute.KeyValue {
- return K8SPodNameKey.String(val)
-}
-
-// K8SPodUID returns an attribute KeyValue conforming to the "k8s.pod.uid"
-// semantic conventions. It represents the UID of the Pod.
-func K8SPodUID(val string) attribute.KeyValue {
- return K8SPodUIDKey.String(val)
-}
-
-// K8SReplicaSetName returns an attribute KeyValue conforming to the
-// "k8s.replicaset.name" semantic conventions. It represents the name of the
-// ReplicaSet.
-func K8SReplicaSetName(val string) attribute.KeyValue {
- return K8SReplicaSetNameKey.String(val)
-}
-
-// K8SReplicaSetUID returns an attribute KeyValue conforming to the
-// "k8s.replicaset.uid" semantic conventions. It represents the UID of the
-// ReplicaSet.
-func K8SReplicaSetUID(val string) attribute.KeyValue {
- return K8SReplicaSetUIDKey.String(val)
-}
-
-// K8SStatefulSetName returns an attribute KeyValue conforming to the
-// "k8s.statefulset.name" semantic conventions. It represents the name of the
-// StatefulSet.
-func K8SStatefulSetName(val string) attribute.KeyValue {
- return K8SStatefulSetNameKey.String(val)
-}
-
-// K8SStatefulSetUID returns an attribute KeyValue conforming to the
-// "k8s.statefulset.uid" semantic conventions. It represents the UID of the
-// StatefulSet.
-func K8SStatefulSetUID(val string) attribute.KeyValue {
- return K8SStatefulSetUIDKey.String(val)
-}
-
-// Log attributes
-const (
- // LogIostreamKey is the attribute Key conforming to the "log.iostream"
- // semantic conventions. It represents the stream associated with the log.
- // See below for a list of well-known values.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- LogIostreamKey = attribute.Key("log.iostream")
-)
-
-var (
- // Logs from stdout stream
- LogIostreamStdout = LogIostreamKey.String("stdout")
- // Events from stderr stream
- LogIostreamStderr = LogIostreamKey.String("stderr")
-)
-
-// Attributes for a file to which log was emitted.
-const (
- // LogFileNameKey is the attribute Key conforming to the "log.file.name"
- // semantic conventions. It represents the basename of the file.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'audit.log'
- LogFileNameKey = attribute.Key("log.file.name")
-
- // LogFileNameResolvedKey is the attribute Key conforming to the
- // "log.file.name_resolved" semantic conventions. It represents the
- // basename of the file, with symlinks resolved.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'uuid.log'
- LogFileNameResolvedKey = attribute.Key("log.file.name_resolved")
-
- // LogFilePathKey is the attribute Key conforming to the "log.file.path"
- // semantic conventions. It represents the full path to the file.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '/var/log/mysql/audit.log'
- LogFilePathKey = attribute.Key("log.file.path")
-
- // LogFilePathResolvedKey is the attribute Key conforming to the
- // "log.file.path_resolved" semantic conventions. It represents the full
- // path to the file, with symlinks resolved.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '/var/lib/docker/uuid.log'
- LogFilePathResolvedKey = attribute.Key("log.file.path_resolved")
-)
-
-// LogFileName returns an attribute KeyValue conforming to the
-// "log.file.name" semantic conventions. It represents the basename of the
-// file.
-func LogFileName(val string) attribute.KeyValue {
- return LogFileNameKey.String(val)
-}
-
-// LogFileNameResolved returns an attribute KeyValue conforming to the
-// "log.file.name_resolved" semantic conventions. It represents the basename of
-// the file, with symlinks resolved.
-func LogFileNameResolved(val string) attribute.KeyValue {
- return LogFileNameResolvedKey.String(val)
-}
-
-// LogFilePath returns an attribute KeyValue conforming to the
-// "log.file.path" semantic conventions. It represents the full path to the
-// file.
-func LogFilePath(val string) attribute.KeyValue {
- return LogFilePathKey.String(val)
-}
-
-// LogFilePathResolved returns an attribute KeyValue conforming to the
-// "log.file.path_resolved" semantic conventions. It represents the full path
-// to the file, with symlinks resolved.
-func LogFilePathResolved(val string) attribute.KeyValue {
- return LogFilePathResolvedKey.String(val)
-}
-
-// The generic attributes that may be used in any Log Record.
-const (
- // LogRecordUIDKey is the attribute Key conforming to the "log.record.uid"
- // semantic conventions. It represents a unique identifier for the Log
- // Record.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '01ARZ3NDEKTSV4RRFFQ69G5FAV'
- // Note: If an id is provided, other log records with the same id will be
- // considered duplicates and can be removed safely. This means, that two
- // distinguishable log records MUST have different values.
- // The id MAY be an [Universally Unique Lexicographically Sortable
- // Identifier (ULID)](https://github.com/ulid/spec), but other identifiers
- // (e.g. UUID) may be used as needed.
- LogRecordUIDKey = attribute.Key("log.record.uid")
-)
-
-// LogRecordUID returns an attribute KeyValue conforming to the
-// "log.record.uid" semantic conventions. It represents a unique identifier for
-// the Log Record.
-func LogRecordUID(val string) attribute.KeyValue {
- return LogRecordUIDKey.String(val)
-}
-
-// Attributes describing telemetry around messaging systems and messaging
-// activities.
-const (
- // MessagingBatchMessageCountKey is the attribute Key conforming to the
- // "messaging.batch.message_count" semantic conventions. It represents the
- // number of messages sent, received, or processed in the scope of the
- // batching operation.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 0, 1, 2
- // Note: Instrumentations SHOULD NOT set `messaging.batch.message_count` on
- // spans that operate with a single message. When a messaging client
- // library supports both batch and single-message API for the same
- // operation, instrumentations SHOULD use `messaging.batch.message_count`
- // for batching APIs and SHOULD NOT use it for single-message APIs.
- MessagingBatchMessageCountKey = attribute.Key("messaging.batch.message_count")
-
- // MessagingClientIDKey is the attribute Key conforming to the
- // "messaging.client.id" semantic conventions. It represents a unique
- // identifier for the client that consumes or produces a message.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'client-5', 'myhost@8742@s8083jm'
- MessagingClientIDKey = attribute.Key("messaging.client.id")
-
- // MessagingDestinationAnonymousKey is the attribute Key conforming to the
- // "messaging.destination.anonymous" semantic conventions. It represents a
- // boolean that is true if the message destination is anonymous (could be
- // unnamed or have auto-generated name).
- //
- // Type: boolean
- // RequirementLevel: Optional
- // Stability: experimental
- MessagingDestinationAnonymousKey = attribute.Key("messaging.destination.anonymous")
-
- // MessagingDestinationNameKey is the attribute Key conforming to the
- // "messaging.destination.name" semantic conventions. It represents the
- // message destination name
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'MyQueue', 'MyTopic'
- // Note: Destination name SHOULD uniquely identify a specific queue, topic
- // or other entity within the broker. If
- // the broker doesn't have such notion, the destination name SHOULD
- // uniquely identify the broker.
- MessagingDestinationNameKey = attribute.Key("messaging.destination.name")
-
- // MessagingDestinationPartitionIDKey is the attribute Key conforming to
- // the "messaging.destination.partition.id" semantic conventions. It
- // represents the identifier of the partition messages are sent to or
- // received from, unique within the `messaging.destination.name`.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '1'
- MessagingDestinationPartitionIDKey = attribute.Key("messaging.destination.partition.id")
-
- // MessagingDestinationTemplateKey is the attribute Key conforming to the
- // "messaging.destination.template" semantic conventions. It represents the
- // low cardinality representation of the messaging destination name
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '/customers/{customerID}'
- // Note: Destination names could be constructed from templates. An example
- // would be a destination name involving a user name or product id.
- // Although the destination name in this case is of high cardinality, the
- // underlying template is of low cardinality and can be effectively used
- // for grouping and aggregation.
- MessagingDestinationTemplateKey = attribute.Key("messaging.destination.template")
-
- // MessagingDestinationTemporaryKey is the attribute Key conforming to the
- // "messaging.destination.temporary" semantic conventions. It represents a
- // boolean that is true if the message destination is temporary and might
- // not exist anymore after messages are processed.
- //
- // Type: boolean
- // RequirementLevel: Optional
- // Stability: experimental
- MessagingDestinationTemporaryKey = attribute.Key("messaging.destination.temporary")
-
- // MessagingDestinationPublishAnonymousKey is the attribute Key conforming
- // to the "messaging.destination_publish.anonymous" semantic conventions.
- // It represents a boolean that is true if the publish message destination
- // is anonymous (could be unnamed or have auto-generated name).
- //
- // Type: boolean
- // RequirementLevel: Optional
- // Stability: experimental
- MessagingDestinationPublishAnonymousKey = attribute.Key("messaging.destination_publish.anonymous")
-
- // MessagingDestinationPublishNameKey is the attribute Key conforming to
- // the "messaging.destination_publish.name" semantic conventions. It
- // represents the name of the original destination the message was
- // published to
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'MyQueue', 'MyTopic'
- // Note: The name SHOULD uniquely identify a specific queue, topic, or
- // other entity within the broker. If
- // the broker doesn't have such notion, the original destination name
- // SHOULD uniquely identify the broker.
- MessagingDestinationPublishNameKey = attribute.Key("messaging.destination_publish.name")
-
- // MessagingMessageBodySizeKey is the attribute Key conforming to the
- // "messaging.message.body.size" semantic conventions. It represents the
- // size of the message body in bytes.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 1439
- // Note: This can refer to both the compressed or uncompressed body size.
- // If both sizes are known, the uncompressed
- // body size should be used.
- MessagingMessageBodySizeKey = attribute.Key("messaging.message.body.size")
-
- // MessagingMessageConversationIDKey is the attribute Key conforming to the
- // "messaging.message.conversation_id" semantic conventions. It represents
- // the conversation ID identifying the conversation to which the message
- // belongs, represented as a string. Sometimes called "Correlation ID".
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'MyConversationID'
- MessagingMessageConversationIDKey = attribute.Key("messaging.message.conversation_id")
-
- // MessagingMessageEnvelopeSizeKey is the attribute Key conforming to the
- // "messaging.message.envelope.size" semantic conventions. It represents
- // the size of the message body and metadata in bytes.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 2738
- // Note: This can refer to both the compressed or uncompressed size. If
- // both sizes are known, the uncompressed
- // size should be used.
- MessagingMessageEnvelopeSizeKey = attribute.Key("messaging.message.envelope.size")
-
- // MessagingMessageIDKey is the attribute Key conforming to the
- // "messaging.message.id" semantic conventions. It represents a value used
- // by the messaging system as an identifier for the message, represented as
- // a string.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '452a7c7c7c7048c2f887f61572b18fc2'
- MessagingMessageIDKey = attribute.Key("messaging.message.id")
-
- // MessagingOperationNameKey is the attribute Key conforming to the
- // "messaging.operation.name" semantic conventions. It represents the
- // system-specific name of the messaging operation.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'ack', 'nack', 'send'
- MessagingOperationNameKey = attribute.Key("messaging.operation.name")
-
- // MessagingOperationTypeKey is the attribute Key conforming to the
- // "messaging.operation.type" semantic conventions. It represents a string
- // identifying the type of the messaging operation.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- // Note: If a custom value is used, it MUST be of low cardinality.
- MessagingOperationTypeKey = attribute.Key("messaging.operation.type")
-
- // MessagingSystemKey is the attribute Key conforming to the
- // "messaging.system" semantic conventions. It represents the messaging
- // system as identified by the client instrumentation.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- // Note: The actual messaging system may differ from the one known by the
- // client. For example, when using Kafka client libraries to communicate
- // with Azure Event Hubs, the `messaging.system` is set to `kafka` based on
- // the instrumentation's best knowledge.
- MessagingSystemKey = attribute.Key("messaging.system")
-)
-
-var (
- // One or more messages are provided for publishing to an intermediary. If a single message is published, the context of the "Publish" span can be used as the creation context and no "Create" span needs to be created
- MessagingOperationTypePublish = MessagingOperationTypeKey.String("publish")
- // A message is created. "Create" spans always refer to a single message and are used to provide a unique creation context for messages in batch publishing scenarios
- MessagingOperationTypeCreate = MessagingOperationTypeKey.String("create")
- // One or more messages are requested by a consumer. This operation refers to pull-based scenarios, where consumers explicitly call methods of messaging SDKs to receive messages
- MessagingOperationTypeReceive = MessagingOperationTypeKey.String("receive")
- // One or more messages are delivered to or processed by a consumer
- MessagingOperationTypeDeliver = MessagingOperationTypeKey.String("process")
- // One or more messages are settled
- MessagingOperationTypeSettle = MessagingOperationTypeKey.String("settle")
-)
-
-var (
- // Apache ActiveMQ
- MessagingSystemActivemq = MessagingSystemKey.String("activemq")
- // Amazon Simple Queue Service (SQS)
- MessagingSystemAWSSqs = MessagingSystemKey.String("aws_sqs")
- // Azure Event Grid
- MessagingSystemEventgrid = MessagingSystemKey.String("eventgrid")
- // Azure Event Hubs
- MessagingSystemEventhubs = MessagingSystemKey.String("eventhubs")
- // Azure Service Bus
- MessagingSystemServicebus = MessagingSystemKey.String("servicebus")
- // Google Cloud Pub/Sub
- MessagingSystemGCPPubsub = MessagingSystemKey.String("gcp_pubsub")
- // Java Message Service
- MessagingSystemJms = MessagingSystemKey.String("jms")
- // Apache Kafka
- MessagingSystemKafka = MessagingSystemKey.String("kafka")
- // RabbitMQ
- MessagingSystemRabbitmq = MessagingSystemKey.String("rabbitmq")
- // Apache RocketMQ
- MessagingSystemRocketmq = MessagingSystemKey.String("rocketmq")
-)
-
-// MessagingBatchMessageCount returns an attribute KeyValue conforming to
-// the "messaging.batch.message_count" semantic conventions. It represents the
-// number of messages sent, received, or processed in the scope of the batching
-// operation.
-func MessagingBatchMessageCount(val int) attribute.KeyValue {
- return MessagingBatchMessageCountKey.Int(val)
-}
-
-// MessagingClientID returns an attribute KeyValue conforming to the
-// "messaging.client.id" semantic conventions. It represents a unique
-// identifier for the client that consumes or produces a message.
-func MessagingClientID(val string) attribute.KeyValue {
- return MessagingClientIDKey.String(val)
-}
-
-// MessagingDestinationAnonymous returns an attribute KeyValue conforming to
-// the "messaging.destination.anonymous" semantic conventions. It represents a
-// boolean that is true if the message destination is anonymous (could be
-// unnamed or have auto-generated name).
-func MessagingDestinationAnonymous(val bool) attribute.KeyValue {
- return MessagingDestinationAnonymousKey.Bool(val)
-}
-
-// MessagingDestinationName returns an attribute KeyValue conforming to the
-// "messaging.destination.name" semantic conventions. It represents the message
-// destination name
-func MessagingDestinationName(val string) attribute.KeyValue {
- return MessagingDestinationNameKey.String(val)
-}
-
-// MessagingDestinationPartitionID returns an attribute KeyValue conforming
-// to the "messaging.destination.partition.id" semantic conventions. It
-// represents the identifier of the partition messages are sent to or received
-// from, unique within the `messaging.destination.name`.
-func MessagingDestinationPartitionID(val string) attribute.KeyValue {
- return MessagingDestinationPartitionIDKey.String(val)
-}
-
-// MessagingDestinationTemplate returns an attribute KeyValue conforming to
-// the "messaging.destination.template" semantic conventions. It represents the
-// low cardinality representation of the messaging destination name
-func MessagingDestinationTemplate(val string) attribute.KeyValue {
- return MessagingDestinationTemplateKey.String(val)
-}
-
-// MessagingDestinationTemporary returns an attribute KeyValue conforming to
-// the "messaging.destination.temporary" semantic conventions. It represents a
-// boolean that is true if the message destination is temporary and might not
-// exist anymore after messages are processed.
-func MessagingDestinationTemporary(val bool) attribute.KeyValue {
- return MessagingDestinationTemporaryKey.Bool(val)
-}
-
-// MessagingDestinationPublishAnonymous returns an attribute KeyValue
-// conforming to the "messaging.destination_publish.anonymous" semantic
-// conventions. It represents a boolean that is true if the publish message
-// destination is anonymous (could be unnamed or have auto-generated name).
-func MessagingDestinationPublishAnonymous(val bool) attribute.KeyValue {
- return MessagingDestinationPublishAnonymousKey.Bool(val)
-}
-
-// MessagingDestinationPublishName returns an attribute KeyValue conforming
-// to the "messaging.destination_publish.name" semantic conventions. It
-// represents the name of the original destination the message was published to
-func MessagingDestinationPublishName(val string) attribute.KeyValue {
- return MessagingDestinationPublishNameKey.String(val)
-}
-
-// MessagingMessageBodySize returns an attribute KeyValue conforming to the
-// "messaging.message.body.size" semantic conventions. It represents the size
-// of the message body in bytes.
-func MessagingMessageBodySize(val int) attribute.KeyValue {
- return MessagingMessageBodySizeKey.Int(val)
-}
-
-// MessagingMessageConversationID returns an attribute KeyValue conforming
-// to the "messaging.message.conversation_id" semantic conventions. It
-// represents the conversation ID identifying the conversation to which the
-// message belongs, represented as a string. Sometimes called "Correlation ID".
-func MessagingMessageConversationID(val string) attribute.KeyValue {
- return MessagingMessageConversationIDKey.String(val)
-}
-
-// MessagingMessageEnvelopeSize returns an attribute KeyValue conforming to
-// the "messaging.message.envelope.size" semantic conventions. It represents
-// the size of the message body and metadata in bytes.
-func MessagingMessageEnvelopeSize(val int) attribute.KeyValue {
- return MessagingMessageEnvelopeSizeKey.Int(val)
-}
-
-// MessagingMessageID returns an attribute KeyValue conforming to the
-// "messaging.message.id" semantic conventions. It represents a value used by
-// the messaging system as an identifier for the message, represented as a
-// string.
-func MessagingMessageID(val string) attribute.KeyValue {
- return MessagingMessageIDKey.String(val)
-}
-
-// MessagingOperationName returns an attribute KeyValue conforming to the
-// "messaging.operation.name" semantic conventions. It represents the
-// system-specific name of the messaging operation.
-func MessagingOperationName(val string) attribute.KeyValue {
- return MessagingOperationNameKey.String(val)
-}
-
-// This group describes attributes specific to Apache Kafka.
-const (
- // MessagingKafkaConsumerGroupKey is the attribute Key conforming to the
- // "messaging.kafka.consumer.group" semantic conventions. It represents the
- // name of the Kafka Consumer Group that is handling the message. Only
- // applies to consumers, not producers.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'my-group'
- MessagingKafkaConsumerGroupKey = attribute.Key("messaging.kafka.consumer.group")
-
- // MessagingKafkaMessageKeyKey is the attribute Key conforming to the
- // "messaging.kafka.message.key" semantic conventions. It represents the
- // message keys in Kafka are used for grouping alike messages to ensure
- // they're processed on the same partition. They differ from
- // `messaging.message.id` in that they're not unique. If the key is `null`,
- // the attribute MUST NOT be set.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'myKey'
- // Note: If the key type is not string, it's string representation has to
- // be supplied for the attribute. If the key has no unambiguous, canonical
- // string form, don't include its value.
- MessagingKafkaMessageKeyKey = attribute.Key("messaging.kafka.message.key")
-
- // MessagingKafkaMessageOffsetKey is the attribute Key conforming to the
- // "messaging.kafka.message.offset" semantic conventions. It represents the
- // offset of a record in the corresponding Kafka partition.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 42
- MessagingKafkaMessageOffsetKey = attribute.Key("messaging.kafka.message.offset")
-
- // MessagingKafkaMessageTombstoneKey is the attribute Key conforming to the
- // "messaging.kafka.message.tombstone" semantic conventions. It represents
- // a boolean that is true if the message is a tombstone.
- //
- // Type: boolean
- // RequirementLevel: Optional
- // Stability: experimental
- MessagingKafkaMessageTombstoneKey = attribute.Key("messaging.kafka.message.tombstone")
-)
-
-// MessagingKafkaConsumerGroup returns an attribute KeyValue conforming to
-// the "messaging.kafka.consumer.group" semantic conventions. It represents the
-// name of the Kafka Consumer Group that is handling the message. Only applies
-// to consumers, not producers.
-func MessagingKafkaConsumerGroup(val string) attribute.KeyValue {
- return MessagingKafkaConsumerGroupKey.String(val)
-}
-
-// MessagingKafkaMessageKey returns an attribute KeyValue conforming to the
-// "messaging.kafka.message.key" semantic conventions. It represents the
-// message keys in Kafka are used for grouping alike messages to ensure they're
-// processed on the same partition. They differ from `messaging.message.id` in
-// that they're not unique. If the key is `null`, the attribute MUST NOT be
-// set.
-func MessagingKafkaMessageKey(val string) attribute.KeyValue {
- return MessagingKafkaMessageKeyKey.String(val)
-}
-
-// MessagingKafkaMessageOffset returns an attribute KeyValue conforming to
-// the "messaging.kafka.message.offset" semantic conventions. It represents the
-// offset of a record in the corresponding Kafka partition.
-func MessagingKafkaMessageOffset(val int) attribute.KeyValue {
- return MessagingKafkaMessageOffsetKey.Int(val)
-}
-
-// MessagingKafkaMessageTombstone returns an attribute KeyValue conforming
-// to the "messaging.kafka.message.tombstone" semantic conventions. It
-// represents a boolean that is true if the message is a tombstone.
-func MessagingKafkaMessageTombstone(val bool) attribute.KeyValue {
- return MessagingKafkaMessageTombstoneKey.Bool(val)
-}
-
-// This group describes attributes specific to RabbitMQ.
-const (
- // MessagingRabbitmqDestinationRoutingKeyKey is the attribute Key
- // conforming to the "messaging.rabbitmq.destination.routing_key" semantic
- // conventions. It represents the rabbitMQ message routing key.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'myKey'
- MessagingRabbitmqDestinationRoutingKeyKey = attribute.Key("messaging.rabbitmq.destination.routing_key")
-
- // MessagingRabbitmqMessageDeliveryTagKey is the attribute Key conforming
- // to the "messaging.rabbitmq.message.delivery_tag" semantic conventions.
- // It represents the rabbitMQ message delivery tag
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 123
- MessagingRabbitmqMessageDeliveryTagKey = attribute.Key("messaging.rabbitmq.message.delivery_tag")
-)
-
-// MessagingRabbitmqDestinationRoutingKey returns an attribute KeyValue
-// conforming to the "messaging.rabbitmq.destination.routing_key" semantic
-// conventions. It represents the rabbitMQ message routing key.
-func MessagingRabbitmqDestinationRoutingKey(val string) attribute.KeyValue {
- return MessagingRabbitmqDestinationRoutingKeyKey.String(val)
-}
-
-// MessagingRabbitmqMessageDeliveryTag returns an attribute KeyValue
-// conforming to the "messaging.rabbitmq.message.delivery_tag" semantic
-// conventions. It represents the rabbitMQ message delivery tag
-func MessagingRabbitmqMessageDeliveryTag(val int) attribute.KeyValue {
- return MessagingRabbitmqMessageDeliveryTagKey.Int(val)
-}
-
-// This group describes attributes specific to RocketMQ.
-const (
- // MessagingRocketmqClientGroupKey is the attribute Key conforming to the
- // "messaging.rocketmq.client_group" semantic conventions. It represents
- // the name of the RocketMQ producer/consumer group that is handling the
- // message. The client type is identified by the SpanKind.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'myConsumerGroup'
- MessagingRocketmqClientGroupKey = attribute.Key("messaging.rocketmq.client_group")
-
- // MessagingRocketmqConsumptionModelKey is the attribute Key conforming to
- // the "messaging.rocketmq.consumption_model" semantic conventions. It
- // represents the model of message consumption. This only applies to
- // consumer spans.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- MessagingRocketmqConsumptionModelKey = attribute.Key("messaging.rocketmq.consumption_model")
-
- // MessagingRocketmqMessageDelayTimeLevelKey is the attribute Key
- // conforming to the "messaging.rocketmq.message.delay_time_level" semantic
- // conventions. It represents the delay time level for delay message, which
- // determines the message delay time.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 3
- MessagingRocketmqMessageDelayTimeLevelKey = attribute.Key("messaging.rocketmq.message.delay_time_level")
-
- // MessagingRocketmqMessageDeliveryTimestampKey is the attribute Key
- // conforming to the "messaging.rocketmq.message.delivery_timestamp"
- // semantic conventions. It represents the timestamp in milliseconds that
- // the delay message is expected to be delivered to consumer.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 1665987217045
- MessagingRocketmqMessageDeliveryTimestampKey = attribute.Key("messaging.rocketmq.message.delivery_timestamp")
-
- // MessagingRocketmqMessageGroupKey is the attribute Key conforming to the
- // "messaging.rocketmq.message.group" semantic conventions. It represents
- // the it is essential for FIFO message. Messages that belong to the same
- // message group are always processed one by one within the same consumer
- // group.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'myMessageGroup'
- MessagingRocketmqMessageGroupKey = attribute.Key("messaging.rocketmq.message.group")
-
- // MessagingRocketmqMessageKeysKey is the attribute Key conforming to the
- // "messaging.rocketmq.message.keys" semantic conventions. It represents
- // the key(s) of message, another way to mark message besides message id.
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'keyA', 'keyB'
- MessagingRocketmqMessageKeysKey = attribute.Key("messaging.rocketmq.message.keys")
-
- // MessagingRocketmqMessageTagKey is the attribute Key conforming to the
- // "messaging.rocketmq.message.tag" semantic conventions. It represents the
- // secondary classifier of message besides topic.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'tagA'
- MessagingRocketmqMessageTagKey = attribute.Key("messaging.rocketmq.message.tag")
-
- // MessagingRocketmqMessageTypeKey is the attribute Key conforming to the
- // "messaging.rocketmq.message.type" semantic conventions. It represents
- // the type of message.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- MessagingRocketmqMessageTypeKey = attribute.Key("messaging.rocketmq.message.type")
-
- // MessagingRocketmqNamespaceKey is the attribute Key conforming to the
- // "messaging.rocketmq.namespace" semantic conventions. It represents the
- // namespace of RocketMQ resources, resources in different namespaces are
- // individual.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'myNamespace'
- MessagingRocketmqNamespaceKey = attribute.Key("messaging.rocketmq.namespace")
-)
-
-var (
- // Clustering consumption model
- MessagingRocketmqConsumptionModelClustering = MessagingRocketmqConsumptionModelKey.String("clustering")
- // Broadcasting consumption model
- MessagingRocketmqConsumptionModelBroadcasting = MessagingRocketmqConsumptionModelKey.String("broadcasting")
-)
-
-var (
- // Normal message
- MessagingRocketmqMessageTypeNormal = MessagingRocketmqMessageTypeKey.String("normal")
- // FIFO message
- MessagingRocketmqMessageTypeFifo = MessagingRocketmqMessageTypeKey.String("fifo")
- // Delay message
- MessagingRocketmqMessageTypeDelay = MessagingRocketmqMessageTypeKey.String("delay")
- // Transaction message
- MessagingRocketmqMessageTypeTransaction = MessagingRocketmqMessageTypeKey.String("transaction")
-)
-
-// MessagingRocketmqClientGroup returns an attribute KeyValue conforming to
-// the "messaging.rocketmq.client_group" semantic conventions. It represents
-// the name of the RocketMQ producer/consumer group that is handling the
-// message. The client type is identified by the SpanKind.
-func MessagingRocketmqClientGroup(val string) attribute.KeyValue {
- return MessagingRocketmqClientGroupKey.String(val)
-}
-
-// MessagingRocketmqMessageDelayTimeLevel returns an attribute KeyValue
-// conforming to the "messaging.rocketmq.message.delay_time_level" semantic
-// conventions. It represents the delay time level for delay message, which
-// determines the message delay time.
-func MessagingRocketmqMessageDelayTimeLevel(val int) attribute.KeyValue {
- return MessagingRocketmqMessageDelayTimeLevelKey.Int(val)
-}
-
-// MessagingRocketmqMessageDeliveryTimestamp returns an attribute KeyValue
-// conforming to the "messaging.rocketmq.message.delivery_timestamp" semantic
-// conventions. It represents the timestamp in milliseconds that the delay
-// message is expected to be delivered to consumer.
-func MessagingRocketmqMessageDeliveryTimestamp(val int) attribute.KeyValue {
- return MessagingRocketmqMessageDeliveryTimestampKey.Int(val)
-}
-
-// MessagingRocketmqMessageGroup returns an attribute KeyValue conforming to
-// the "messaging.rocketmq.message.group" semantic conventions. It represents
-// the it is essential for FIFO message. Messages that belong to the same
-// message group are always processed one by one within the same consumer
-// group.
-func MessagingRocketmqMessageGroup(val string) attribute.KeyValue {
- return MessagingRocketmqMessageGroupKey.String(val)
-}
-
-// MessagingRocketmqMessageKeys returns an attribute KeyValue conforming to
-// the "messaging.rocketmq.message.keys" semantic conventions. It represents
-// the key(s) of message, another way to mark message besides message id.
-func MessagingRocketmqMessageKeys(val ...string) attribute.KeyValue {
- return MessagingRocketmqMessageKeysKey.StringSlice(val)
-}
-
-// MessagingRocketmqMessageTag returns an attribute KeyValue conforming to
-// the "messaging.rocketmq.message.tag" semantic conventions. It represents the
-// secondary classifier of message besides topic.
-func MessagingRocketmqMessageTag(val string) attribute.KeyValue {
- return MessagingRocketmqMessageTagKey.String(val)
-}
-
-// MessagingRocketmqNamespace returns an attribute KeyValue conforming to
-// the "messaging.rocketmq.namespace" semantic conventions. It represents the
-// namespace of RocketMQ resources, resources in different namespaces are
-// individual.
-func MessagingRocketmqNamespace(val string) attribute.KeyValue {
- return MessagingRocketmqNamespaceKey.String(val)
-}
-
-// This group describes attributes specific to GCP Pub/Sub.
-const (
- // MessagingGCPPubsubMessageAckDeadlineKey is the attribute Key conforming
- // to the "messaging.gcp_pubsub.message.ack_deadline" semantic conventions.
- // It represents the ack deadline in seconds set for the modify ack
- // deadline request.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 10
- MessagingGCPPubsubMessageAckDeadlineKey = attribute.Key("messaging.gcp_pubsub.message.ack_deadline")
-
- // MessagingGCPPubsubMessageAckIDKey is the attribute Key conforming to the
- // "messaging.gcp_pubsub.message.ack_id" semantic conventions. It
- // represents the ack id for a given message.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'ack_id'
- MessagingGCPPubsubMessageAckIDKey = attribute.Key("messaging.gcp_pubsub.message.ack_id")
-
- // MessagingGCPPubsubMessageDeliveryAttemptKey is the attribute Key
- // conforming to the "messaging.gcp_pubsub.message.delivery_attempt"
- // semantic conventions. It represents the delivery attempt for a given
- // message.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 2
- MessagingGCPPubsubMessageDeliveryAttemptKey = attribute.Key("messaging.gcp_pubsub.message.delivery_attempt")
-
- // MessagingGCPPubsubMessageOrderingKeyKey is the attribute Key conforming
- // to the "messaging.gcp_pubsub.message.ordering_key" semantic conventions.
- // It represents the ordering key for a given message. If the attribute is
- // not present, the message does not have an ordering key.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'ordering_key'
- MessagingGCPPubsubMessageOrderingKeyKey = attribute.Key("messaging.gcp_pubsub.message.ordering_key")
-)
-
-// MessagingGCPPubsubMessageAckDeadline returns an attribute KeyValue
-// conforming to the "messaging.gcp_pubsub.message.ack_deadline" semantic
-// conventions. It represents the ack deadline in seconds set for the modify
-// ack deadline request.
-func MessagingGCPPubsubMessageAckDeadline(val int) attribute.KeyValue {
- return MessagingGCPPubsubMessageAckDeadlineKey.Int(val)
-}
-
-// MessagingGCPPubsubMessageAckID returns an attribute KeyValue conforming
-// to the "messaging.gcp_pubsub.message.ack_id" semantic conventions. It
-// represents the ack id for a given message.
-func MessagingGCPPubsubMessageAckID(val string) attribute.KeyValue {
- return MessagingGCPPubsubMessageAckIDKey.String(val)
-}
-
-// MessagingGCPPubsubMessageDeliveryAttempt returns an attribute KeyValue
-// conforming to the "messaging.gcp_pubsub.message.delivery_attempt" semantic
-// conventions. It represents the delivery attempt for a given message.
-func MessagingGCPPubsubMessageDeliveryAttempt(val int) attribute.KeyValue {
- return MessagingGCPPubsubMessageDeliveryAttemptKey.Int(val)
-}
-
-// MessagingGCPPubsubMessageOrderingKey returns an attribute KeyValue
-// conforming to the "messaging.gcp_pubsub.message.ordering_key" semantic
-// conventions. It represents the ordering key for a given message. If the
-// attribute is not present, the message does not have an ordering key.
-func MessagingGCPPubsubMessageOrderingKey(val string) attribute.KeyValue {
- return MessagingGCPPubsubMessageOrderingKeyKey.String(val)
-}
-
-// This group describes attributes specific to Azure Service Bus.
-const (
- // MessagingServicebusDestinationSubscriptionNameKey is the attribute Key
- // conforming to the "messaging.servicebus.destination.subscription_name"
- // semantic conventions. It represents the name of the subscription in the
- // topic messages are received from.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'mySubscription'
- MessagingServicebusDestinationSubscriptionNameKey = attribute.Key("messaging.servicebus.destination.subscription_name")
-
- // MessagingServicebusDispositionStatusKey is the attribute Key conforming
- // to the "messaging.servicebus.disposition_status" semantic conventions.
- // It represents the describes the [settlement
- // type](https://learn.microsoft.com/azure/service-bus-messaging/message-transfers-locks-settlement#peeklock).
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- MessagingServicebusDispositionStatusKey = attribute.Key("messaging.servicebus.disposition_status")
-
- // MessagingServicebusMessageDeliveryCountKey is the attribute Key
- // conforming to the "messaging.servicebus.message.delivery_count" semantic
- // conventions. It represents the number of deliveries that have been
- // attempted for this message.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 2
- MessagingServicebusMessageDeliveryCountKey = attribute.Key("messaging.servicebus.message.delivery_count")
-
- // MessagingServicebusMessageEnqueuedTimeKey is the attribute Key
- // conforming to the "messaging.servicebus.message.enqueued_time" semantic
- // conventions. It represents the UTC epoch seconds at which the message
- // has been accepted and stored in the entity.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 1701393730
- MessagingServicebusMessageEnqueuedTimeKey = attribute.Key("messaging.servicebus.message.enqueued_time")
-)
-
-var (
- // Message is completed
- MessagingServicebusDispositionStatusComplete = MessagingServicebusDispositionStatusKey.String("complete")
- // Message is abandoned
- MessagingServicebusDispositionStatusAbandon = MessagingServicebusDispositionStatusKey.String("abandon")
- // Message is sent to dead letter queue
- MessagingServicebusDispositionStatusDeadLetter = MessagingServicebusDispositionStatusKey.String("dead_letter")
- // Message is deferred
- MessagingServicebusDispositionStatusDefer = MessagingServicebusDispositionStatusKey.String("defer")
-)
-
-// MessagingServicebusDestinationSubscriptionName returns an attribute
-// KeyValue conforming to the
-// "messaging.servicebus.destination.subscription_name" semantic conventions.
-// It represents the name of the subscription in the topic messages are
-// received from.
-func MessagingServicebusDestinationSubscriptionName(val string) attribute.KeyValue {
- return MessagingServicebusDestinationSubscriptionNameKey.String(val)
-}
-
-// MessagingServicebusMessageDeliveryCount returns an attribute KeyValue
-// conforming to the "messaging.servicebus.message.delivery_count" semantic
-// conventions. It represents the number of deliveries that have been attempted
-// for this message.
-func MessagingServicebusMessageDeliveryCount(val int) attribute.KeyValue {
- return MessagingServicebusMessageDeliveryCountKey.Int(val)
-}
-
-// MessagingServicebusMessageEnqueuedTime returns an attribute KeyValue
-// conforming to the "messaging.servicebus.message.enqueued_time" semantic
-// conventions. It represents the UTC epoch seconds at which the message has
-// been accepted and stored in the entity.
-func MessagingServicebusMessageEnqueuedTime(val int) attribute.KeyValue {
- return MessagingServicebusMessageEnqueuedTimeKey.Int(val)
-}
-
-// This group describes attributes specific to Azure Event Hubs.
-const (
- // MessagingEventhubsConsumerGroupKey is the attribute Key conforming to
- // the "messaging.eventhubs.consumer.group" semantic conventions. It
- // represents the name of the consumer group the event consumer is
- // associated with.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'indexer'
- MessagingEventhubsConsumerGroupKey = attribute.Key("messaging.eventhubs.consumer.group")
-
- // MessagingEventhubsMessageEnqueuedTimeKey is the attribute Key conforming
- // to the "messaging.eventhubs.message.enqueued_time" semantic conventions.
- // It represents the UTC epoch seconds at which the message has been
- // accepted and stored in the entity.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 1701393730
- MessagingEventhubsMessageEnqueuedTimeKey = attribute.Key("messaging.eventhubs.message.enqueued_time")
-)
-
-// MessagingEventhubsConsumerGroup returns an attribute KeyValue conforming
-// to the "messaging.eventhubs.consumer.group" semantic conventions. It
-// represents the name of the consumer group the event consumer is associated
-// with.
-func MessagingEventhubsConsumerGroup(val string) attribute.KeyValue {
- return MessagingEventhubsConsumerGroupKey.String(val)
-}
-
-// MessagingEventhubsMessageEnqueuedTime returns an attribute KeyValue
-// conforming to the "messaging.eventhubs.message.enqueued_time" semantic
-// conventions. It represents the UTC epoch seconds at which the message has
-// been accepted and stored in the entity.
-func MessagingEventhubsMessageEnqueuedTime(val int) attribute.KeyValue {
- return MessagingEventhubsMessageEnqueuedTimeKey.Int(val)
-}
-
-// These attributes may be used for any network related operation.
-const (
- // NetworkCarrierIccKey is the attribute Key conforming to the
- // "network.carrier.icc" semantic conventions. It represents the ISO 3166-1
- // alpha-2 2-character country code associated with the mobile carrier
- // network.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'DE'
- NetworkCarrierIccKey = attribute.Key("network.carrier.icc")
-
- // NetworkCarrierMccKey is the attribute Key conforming to the
- // "network.carrier.mcc" semantic conventions. It represents the mobile
- // carrier country code.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '310'
- NetworkCarrierMccKey = attribute.Key("network.carrier.mcc")
-
- // NetworkCarrierMncKey is the attribute Key conforming to the
- // "network.carrier.mnc" semantic conventions. It represents the mobile
- // carrier network code.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '001'
- NetworkCarrierMncKey = attribute.Key("network.carrier.mnc")
-
- // NetworkCarrierNameKey is the attribute Key conforming to the
- // "network.carrier.name" semantic conventions. It represents the name of
- // the mobile carrier.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'sprint'
- NetworkCarrierNameKey = attribute.Key("network.carrier.name")
-
- // NetworkConnectionSubtypeKey is the attribute Key conforming to the
- // "network.connection.subtype" semantic conventions. It represents the
- // this describes more details regarding the connection.type. It may be the
- // type of cell technology connection, but it could be used for describing
- // details about a wifi connection.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'LTE'
- NetworkConnectionSubtypeKey = attribute.Key("network.connection.subtype")
-
- // NetworkConnectionTypeKey is the attribute Key conforming to the
- // "network.connection.type" semantic conventions. It represents the
- // internet connection type.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'wifi'
- NetworkConnectionTypeKey = attribute.Key("network.connection.type")
-
- // NetworkIoDirectionKey is the attribute Key conforming to the
- // "network.io.direction" semantic conventions. It represents the network
- // IO operation direction.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'transmit'
- NetworkIoDirectionKey = attribute.Key("network.io.direction")
-
- // NetworkLocalAddressKey is the attribute Key conforming to the
- // "network.local.address" semantic conventions. It represents the local
- // address of the network connection - IP address or Unix domain socket
- // name.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '10.1.2.80', '/tmp/my.sock'
- NetworkLocalAddressKey = attribute.Key("network.local.address")
-
- // NetworkLocalPortKey is the attribute Key conforming to the
- // "network.local.port" semantic conventions. It represents the local port
- // number of the network connection.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 65123
- NetworkLocalPortKey = attribute.Key("network.local.port")
-
- // NetworkPeerAddressKey is the attribute Key conforming to the
- // "network.peer.address" semantic conventions. It represents the peer
- // address of the network connection - IP address or Unix domain socket
- // name.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '10.1.2.80', '/tmp/my.sock'
- NetworkPeerAddressKey = attribute.Key("network.peer.address")
-
- // NetworkPeerPortKey is the attribute Key conforming to the
- // "network.peer.port" semantic conventions. It represents the peer port
- // number of the network connection.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 65123
- NetworkPeerPortKey = attribute.Key("network.peer.port")
-
- // NetworkProtocolNameKey is the attribute Key conforming to the
- // "network.protocol.name" semantic conventions. It represents the [OSI
- // application layer](https://osi-model.com/application-layer/) or non-OSI
- // equivalent.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'amqp', 'http', 'mqtt'
- // Note: The value SHOULD be normalized to lowercase.
- NetworkProtocolNameKey = attribute.Key("network.protocol.name")
-
- // NetworkProtocolVersionKey is the attribute Key conforming to the
- // "network.protocol.version" semantic conventions. It represents the
- // actual version of the protocol used for network communication.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '1.1', '2'
- // Note: If protocol version is subject to negotiation (for example using
- // [ALPN](https://www.rfc-editor.org/rfc/rfc7301.html)), this attribute
- // SHOULD be set to the negotiated version. If the actual protocol version
- // is not known, this attribute SHOULD NOT be set.
- NetworkProtocolVersionKey = attribute.Key("network.protocol.version")
-
- // NetworkTransportKey is the attribute Key conforming to the
- // "network.transport" semantic conventions. It represents the [OSI
- // transport layer](https://osi-model.com/transport-layer/) or
- // [inter-process communication
- // method](https://wikipedia.org/wiki/Inter-process_communication).
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'tcp', 'udp'
- // Note: The value SHOULD be normalized to lowercase.
- //
- // Consider always setting the transport when setting a port number, since
- // a port number is ambiguous without knowing the transport. For example
- // different processes could be listening on TCP port 12345 and UDP port
- // 12345.
- NetworkTransportKey = attribute.Key("network.transport")
-
- // NetworkTypeKey is the attribute Key conforming to the "network.type"
- // semantic conventions. It represents the [OSI network
- // layer](https://osi-model.com/network-layer/) or non-OSI equivalent.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'ipv4', 'ipv6'
- // Note: The value SHOULD be normalized to lowercase.
- NetworkTypeKey = attribute.Key("network.type")
-)
-
-var (
- // GPRS
- NetworkConnectionSubtypeGprs = NetworkConnectionSubtypeKey.String("gprs")
- // EDGE
- NetworkConnectionSubtypeEdge = NetworkConnectionSubtypeKey.String("edge")
- // UMTS
- NetworkConnectionSubtypeUmts = NetworkConnectionSubtypeKey.String("umts")
- // CDMA
- NetworkConnectionSubtypeCdma = NetworkConnectionSubtypeKey.String("cdma")
- // EVDO Rel. 0
- NetworkConnectionSubtypeEvdo0 = NetworkConnectionSubtypeKey.String("evdo_0")
- // EVDO Rev. A
- NetworkConnectionSubtypeEvdoA = NetworkConnectionSubtypeKey.String("evdo_a")
- // CDMA2000 1XRTT
- NetworkConnectionSubtypeCdma20001xrtt = NetworkConnectionSubtypeKey.String("cdma2000_1xrtt")
- // HSDPA
- NetworkConnectionSubtypeHsdpa = NetworkConnectionSubtypeKey.String("hsdpa")
- // HSUPA
- NetworkConnectionSubtypeHsupa = NetworkConnectionSubtypeKey.String("hsupa")
- // HSPA
- NetworkConnectionSubtypeHspa = NetworkConnectionSubtypeKey.String("hspa")
- // IDEN
- NetworkConnectionSubtypeIden = NetworkConnectionSubtypeKey.String("iden")
- // EVDO Rev. B
- NetworkConnectionSubtypeEvdoB = NetworkConnectionSubtypeKey.String("evdo_b")
- // LTE
- NetworkConnectionSubtypeLte = NetworkConnectionSubtypeKey.String("lte")
- // EHRPD
- NetworkConnectionSubtypeEhrpd = NetworkConnectionSubtypeKey.String("ehrpd")
- // HSPAP
- NetworkConnectionSubtypeHspap = NetworkConnectionSubtypeKey.String("hspap")
- // GSM
- NetworkConnectionSubtypeGsm = NetworkConnectionSubtypeKey.String("gsm")
- // TD-SCDMA
- NetworkConnectionSubtypeTdScdma = NetworkConnectionSubtypeKey.String("td_scdma")
- // IWLAN
- NetworkConnectionSubtypeIwlan = NetworkConnectionSubtypeKey.String("iwlan")
- // 5G NR (New Radio)
- NetworkConnectionSubtypeNr = NetworkConnectionSubtypeKey.String("nr")
- // 5G NRNSA (New Radio Non-Standalone)
- NetworkConnectionSubtypeNrnsa = NetworkConnectionSubtypeKey.String("nrnsa")
- // LTE CA
- NetworkConnectionSubtypeLteCa = NetworkConnectionSubtypeKey.String("lte_ca")
-)
-
-var (
- // wifi
- NetworkConnectionTypeWifi = NetworkConnectionTypeKey.String("wifi")
- // wired
- NetworkConnectionTypeWired = NetworkConnectionTypeKey.String("wired")
- // cell
- NetworkConnectionTypeCell = NetworkConnectionTypeKey.String("cell")
- // unavailable
- NetworkConnectionTypeUnavailable = NetworkConnectionTypeKey.String("unavailable")
- // unknown
- NetworkConnectionTypeUnknown = NetworkConnectionTypeKey.String("unknown")
-)
-
-var (
- // transmit
- NetworkIoDirectionTransmit = NetworkIoDirectionKey.String("transmit")
- // receive
- NetworkIoDirectionReceive = NetworkIoDirectionKey.String("receive")
-)
-
-var (
- // TCP
- NetworkTransportTCP = NetworkTransportKey.String("tcp")
- // UDP
- NetworkTransportUDP = NetworkTransportKey.String("udp")
- // Named or anonymous pipe
- NetworkTransportPipe = NetworkTransportKey.String("pipe")
- // Unix domain socket
- NetworkTransportUnix = NetworkTransportKey.String("unix")
-)
-
-var (
- // IPv4
- NetworkTypeIpv4 = NetworkTypeKey.String("ipv4")
- // IPv6
- NetworkTypeIpv6 = NetworkTypeKey.String("ipv6")
-)
-
-// NetworkCarrierIcc returns an attribute KeyValue conforming to the
-// "network.carrier.icc" semantic conventions. It represents the ISO 3166-1
-// alpha-2 2-character country code associated with the mobile carrier network.
-func NetworkCarrierIcc(val string) attribute.KeyValue {
- return NetworkCarrierIccKey.String(val)
-}
-
-// NetworkCarrierMcc returns an attribute KeyValue conforming to the
-// "network.carrier.mcc" semantic conventions. It represents the mobile carrier
-// country code.
-func NetworkCarrierMcc(val string) attribute.KeyValue {
- return NetworkCarrierMccKey.String(val)
-}
-
-// NetworkCarrierMnc returns an attribute KeyValue conforming to the
-// "network.carrier.mnc" semantic conventions. It represents the mobile carrier
-// network code.
-func NetworkCarrierMnc(val string) attribute.KeyValue {
- return NetworkCarrierMncKey.String(val)
-}
-
-// NetworkCarrierName returns an attribute KeyValue conforming to the
-// "network.carrier.name" semantic conventions. It represents the name of the
-// mobile carrier.
-func NetworkCarrierName(val string) attribute.KeyValue {
- return NetworkCarrierNameKey.String(val)
-}
-
-// NetworkLocalAddress returns an attribute KeyValue conforming to the
-// "network.local.address" semantic conventions. It represents the local
-// address of the network connection - IP address or Unix domain socket name.
-func NetworkLocalAddress(val string) attribute.KeyValue {
- return NetworkLocalAddressKey.String(val)
-}
-
-// NetworkLocalPort returns an attribute KeyValue conforming to the
-// "network.local.port" semantic conventions. It represents the local port
-// number of the network connection.
-func NetworkLocalPort(val int) attribute.KeyValue {
- return NetworkLocalPortKey.Int(val)
-}
-
-// NetworkPeerAddress returns an attribute KeyValue conforming to the
-// "network.peer.address" semantic conventions. It represents the peer address
-// of the network connection - IP address or Unix domain socket name.
-func NetworkPeerAddress(val string) attribute.KeyValue {
- return NetworkPeerAddressKey.String(val)
-}
-
-// NetworkPeerPort returns an attribute KeyValue conforming to the
-// "network.peer.port" semantic conventions. It represents the peer port number
-// of the network connection.
-func NetworkPeerPort(val int) attribute.KeyValue {
- return NetworkPeerPortKey.Int(val)
-}
-
-// NetworkProtocolName returns an attribute KeyValue conforming to the
-// "network.protocol.name" semantic conventions. It represents the [OSI
-// application layer](https://osi-model.com/application-layer/) or non-OSI
-// equivalent.
-func NetworkProtocolName(val string) attribute.KeyValue {
- return NetworkProtocolNameKey.String(val)
-}
-
-// NetworkProtocolVersion returns an attribute KeyValue conforming to the
-// "network.protocol.version" semantic conventions. It represents the actual
-// version of the protocol used for network communication.
-func NetworkProtocolVersion(val string) attribute.KeyValue {
- return NetworkProtocolVersionKey.String(val)
-}
-
-// An OCI image manifest.
-const (
- // OciManifestDigestKey is the attribute Key conforming to the
- // "oci.manifest.digest" semantic conventions. It represents the digest of
- // the OCI image manifest. For container images specifically is the digest
- // by which the container image is known.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples:
- // 'sha256:e4ca62c0d62f3e886e684806dfe9d4e0cda60d54986898173c1083856cfda0f4'
- // Note: Follows [OCI Image Manifest
- // Specification](https://github.com/opencontainers/image-spec/blob/main/manifest.md),
- // and specifically the [Digest
- // property](https://github.com/opencontainers/image-spec/blob/main/descriptor.md#digests).
- // An example can be found in [Example Image
- // Manifest](https://docs.docker.com/registry/spec/manifest-v2-2/#example-image-manifest).
- OciManifestDigestKey = attribute.Key("oci.manifest.digest")
-)
-
-// OciManifestDigest returns an attribute KeyValue conforming to the
-// "oci.manifest.digest" semantic conventions. It represents the digest of the
-// OCI image manifest. For container images specifically is the digest by which
-// the container image is known.
-func OciManifestDigest(val string) attribute.KeyValue {
- return OciManifestDigestKey.String(val)
-}
-
-// Attributes used by the OpenTracing Shim layer.
-const (
- // OpentracingRefTypeKey is the attribute Key conforming to the
- // "opentracing.ref_type" semantic conventions. It represents the
- // parent-child Reference type
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- // Note: The causal relationship between a child Span and a parent Span.
- OpentracingRefTypeKey = attribute.Key("opentracing.ref_type")
-)
-
-var (
- // The parent Span depends on the child Span in some capacity
- OpentracingRefTypeChildOf = OpentracingRefTypeKey.String("child_of")
- // The parent Span doesn't depend in any way on the result of the child Span
- OpentracingRefTypeFollowsFrom = OpentracingRefTypeKey.String("follows_from")
-)
-
-// The operating system (OS) on which the process represented by this resource
-// is running.
-const (
- // OSBuildIDKey is the attribute Key conforming to the "os.build_id"
- // semantic conventions. It represents the unique identifier for a
- // particular build or compilation of the operating system.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'TQ3C.230805.001.B2', '20E247', '22621'
- OSBuildIDKey = attribute.Key("os.build_id")
-
- // OSDescriptionKey is the attribute Key conforming to the "os.description"
- // semantic conventions. It represents the human readable (not intended to
- // be parsed) OS version information, like e.g. reported by `ver` or
- // `lsb_release -a` commands.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'Microsoft Windows [Version 10.0.18363.778]', 'Ubuntu 18.04.1
- // LTS'
- OSDescriptionKey = attribute.Key("os.description")
-
- // OSNameKey is the attribute Key conforming to the "os.name" semantic
- // conventions. It represents the human readable operating system name.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'iOS', 'Android', 'Ubuntu'
- OSNameKey = attribute.Key("os.name")
-
- // OSTypeKey is the attribute Key conforming to the "os.type" semantic
- // conventions. It represents the operating system type.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- OSTypeKey = attribute.Key("os.type")
-
- // OSVersionKey is the attribute Key conforming to the "os.version"
- // semantic conventions. It represents the version string of the operating
- // system as defined in [Version
- // Attributes](/docs/resource/README.md#version-attributes).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '14.2.1', '18.04.1'
- OSVersionKey = attribute.Key("os.version")
-)
-
-var (
- // Microsoft Windows
- OSTypeWindows = OSTypeKey.String("windows")
- // Linux
- OSTypeLinux = OSTypeKey.String("linux")
- // Apple Darwin
- OSTypeDarwin = OSTypeKey.String("darwin")
- // FreeBSD
- OSTypeFreeBSD = OSTypeKey.String("freebsd")
- // NetBSD
- OSTypeNetBSD = OSTypeKey.String("netbsd")
- // OpenBSD
- OSTypeOpenBSD = OSTypeKey.String("openbsd")
- // DragonFly BSD
- OSTypeDragonflyBSD = OSTypeKey.String("dragonflybsd")
- // HP-UX (Hewlett Packard Unix)
- OSTypeHPUX = OSTypeKey.String("hpux")
- // AIX (Advanced Interactive eXecutive)
- OSTypeAIX = OSTypeKey.String("aix")
- // SunOS, Oracle Solaris
- OSTypeSolaris = OSTypeKey.String("solaris")
- // IBM z/OS
- OSTypeZOS = OSTypeKey.String("z_os")
-)
-
-// OSBuildID returns an attribute KeyValue conforming to the "os.build_id"
-// semantic conventions. It represents the unique identifier for a particular
-// build or compilation of the operating system.
-func OSBuildID(val string) attribute.KeyValue {
- return OSBuildIDKey.String(val)
-}
-
-// OSDescription returns an attribute KeyValue conforming to the
-// "os.description" semantic conventions. It represents the human readable (not
-// intended to be parsed) OS version information, like e.g. reported by `ver`
-// or `lsb_release -a` commands.
-func OSDescription(val string) attribute.KeyValue {
- return OSDescriptionKey.String(val)
-}
-
-// OSName returns an attribute KeyValue conforming to the "os.name" semantic
-// conventions. It represents the human readable operating system name.
-func OSName(val string) attribute.KeyValue {
- return OSNameKey.String(val)
-}
-
-// OSVersion returns an attribute KeyValue conforming to the "os.version"
-// semantic conventions. It represents the version string of the operating
-// system as defined in [Version
-// Attributes](/docs/resource/README.md#version-attributes).
-func OSVersion(val string) attribute.KeyValue {
- return OSVersionKey.String(val)
-}
-
-// Attributes reserved for OpenTelemetry
-const (
- // OTelStatusCodeKey is the attribute Key conforming to the
- // "otel.status_code" semantic conventions. It represents the name of the
- // code, either "OK" or "ERROR". MUST NOT be set if the status code is
- // UNSET.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: stable
- OTelStatusCodeKey = attribute.Key("otel.status_code")
-
- // OTelStatusDescriptionKey is the attribute Key conforming to the
- // "otel.status_description" semantic conventions. It represents the
- // description of the Status if it has a value, otherwise not set.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'resource not found'
- OTelStatusDescriptionKey = attribute.Key("otel.status_description")
-)
-
-var (
- // The operation has been validated by an Application developer or Operator to have completed successfully
- OTelStatusCodeOk = OTelStatusCodeKey.String("OK")
- // The operation contains an error
- OTelStatusCodeError = OTelStatusCodeKey.String("ERROR")
-)
-
-// OTelStatusDescription returns an attribute KeyValue conforming to the
-// "otel.status_description" semantic conventions. It represents the
-// description of the Status if it has a value, otherwise not set.
-func OTelStatusDescription(val string) attribute.KeyValue {
- return OTelStatusDescriptionKey.String(val)
-}
-
-// Attributes used by non-OTLP exporters to represent OpenTelemetry Scope's
-// concepts.
-const (
- // OTelScopeNameKey is the attribute Key conforming to the
- // "otel.scope.name" semantic conventions. It represents the name of the
- // instrumentation scope - (`InstrumentationScope.Name` in OTLP).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'io.opentelemetry.contrib.mongodb'
- OTelScopeNameKey = attribute.Key("otel.scope.name")
-
- // OTelScopeVersionKey is the attribute Key conforming to the
- // "otel.scope.version" semantic conventions. It represents the version of
- // the instrumentation scope - (`InstrumentationScope.Version` in OTLP).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '1.0.0'
- OTelScopeVersionKey = attribute.Key("otel.scope.version")
-)
-
-// OTelScopeName returns an attribute KeyValue conforming to the
-// "otel.scope.name" semantic conventions. It represents the name of the
-// instrumentation scope - (`InstrumentationScope.Name` in OTLP).
-func OTelScopeName(val string) attribute.KeyValue {
- return OTelScopeNameKey.String(val)
-}
-
-// OTelScopeVersion returns an attribute KeyValue conforming to the
-// "otel.scope.version" semantic conventions. It represents the version of the
-// instrumentation scope - (`InstrumentationScope.Version` in OTLP).
-func OTelScopeVersion(val string) attribute.KeyValue {
- return OTelScopeVersionKey.String(val)
-}
-
-// Operations that access some remote service.
-const (
- // PeerServiceKey is the attribute Key conforming to the "peer.service"
- // semantic conventions. It represents the
- // [`service.name`](/docs/resource/README.md#service) of the remote
- // service. SHOULD be equal to the actual `service.name` resource attribute
- // of the remote service if any.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'AuthTokenCache'
- PeerServiceKey = attribute.Key("peer.service")
-)
-
-// PeerService returns an attribute KeyValue conforming to the
-// "peer.service" semantic conventions. It represents the
-// [`service.name`](/docs/resource/README.md#service) of the remote service.
-// SHOULD be equal to the actual `service.name` resource attribute of the
-// remote service if any.
-func PeerService(val string) attribute.KeyValue {
- return PeerServiceKey.String(val)
-}
-
-// An operating system process.
-const (
- // ProcessCommandKey is the attribute Key conforming to the
- // "process.command" semantic conventions. It represents the command used
- // to launch the process (i.e. the command name). On Linux based systems,
- // can be set to the zeroth string in `proc/[pid]/cmdline`. On Windows, can
- // be set to the first parameter extracted from `GetCommandLineW`.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'cmd/otelcol'
- ProcessCommandKey = attribute.Key("process.command")
-
- // ProcessCommandArgsKey is the attribute Key conforming to the
- // "process.command_args" semantic conventions. It represents the all the
- // command arguments (including the command/executable itself) as received
- // by the process. On Linux-based systems (and some other Unixoid systems
- // supporting procfs), can be set according to the list of null-delimited
- // strings extracted from `proc/[pid]/cmdline`. For libc-based executables,
- // this would be the full argv vector passed to `main`.
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'cmd/otecol', '--config=config.yaml'
- ProcessCommandArgsKey = attribute.Key("process.command_args")
-
- // ProcessCommandLineKey is the attribute Key conforming to the
- // "process.command_line" semantic conventions. It represents the full
- // command used to launch the process as a single string representing the
- // full command. On Windows, can be set to the result of `GetCommandLineW`.
- // Do not set this if you have to assemble it just for monitoring; use
- // `process.command_args` instead.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'C:\\cmd\\otecol --config="my directory\\config.yaml"'
- ProcessCommandLineKey = attribute.Key("process.command_line")
-
- // ProcessContextSwitchTypeKey is the attribute Key conforming to the
- // "process.context_switch_type" semantic conventions. It represents the
- // specifies whether the context switches for this data point were
- // voluntary or involuntary.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- ProcessContextSwitchTypeKey = attribute.Key("process.context_switch_type")
-
- // ProcessCreationTimeKey is the attribute Key conforming to the
- // "process.creation.time" semantic conventions. It represents the date and
- // time the process was created, in ISO 8601 format.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '2023-11-21T09:25:34.853Z'
- ProcessCreationTimeKey = attribute.Key("process.creation.time")
-
- // ProcessExecutableNameKey is the attribute Key conforming to the
- // "process.executable.name" semantic conventions. It represents the name
- // of the process executable. On Linux based systems, can be set to the
- // `Name` in `proc/[pid]/status`. On Windows, can be set to the base name
- // of `GetProcessImageFileNameW`.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'otelcol'
- ProcessExecutableNameKey = attribute.Key("process.executable.name")
-
- // ProcessExecutablePathKey is the attribute Key conforming to the
- // "process.executable.path" semantic conventions. It represents the full
- // path to the process executable. On Linux based systems, can be set to
- // the target of `proc/[pid]/exe`. On Windows, can be set to the result of
- // `GetProcessImageFileNameW`.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '/usr/bin/cmd/otelcol'
- ProcessExecutablePathKey = attribute.Key("process.executable.path")
-
- // ProcessExitCodeKey is the attribute Key conforming to the
- // "process.exit.code" semantic conventions. It represents the exit code of
- // the process.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 127
- ProcessExitCodeKey = attribute.Key("process.exit.code")
-
- // ProcessExitTimeKey is the attribute Key conforming to the
- // "process.exit.time" semantic conventions. It represents the date and
- // time the process exited, in ISO 8601 format.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '2023-11-21T09:26:12.315Z'
- ProcessExitTimeKey = attribute.Key("process.exit.time")
-
- // ProcessGroupLeaderPIDKey is the attribute Key conforming to the
- // "process.group_leader.pid" semantic conventions. It represents the PID
- // of the process's group leader. This is also the process group ID (PGID)
- // of the process.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 23
- ProcessGroupLeaderPIDKey = attribute.Key("process.group_leader.pid")
-
- // ProcessInteractiveKey is the attribute Key conforming to the
- // "process.interactive" semantic conventions. It represents the whether
- // the process is connected to an interactive shell.
- //
- // Type: boolean
- // RequirementLevel: Optional
- // Stability: experimental
- ProcessInteractiveKey = attribute.Key("process.interactive")
-
- // ProcessOwnerKey is the attribute Key conforming to the "process.owner"
- // semantic conventions. It represents the username of the user that owns
- // the process.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'root'
- ProcessOwnerKey = attribute.Key("process.owner")
-
- // ProcessPagingFaultTypeKey is the attribute Key conforming to the
- // "process.paging.fault_type" semantic conventions. It represents the type
- // of page fault for this data point. Type `major` is for major/hard page
- // faults, and `minor` is for minor/soft page faults.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- ProcessPagingFaultTypeKey = attribute.Key("process.paging.fault_type")
-
- // ProcessParentPIDKey is the attribute Key conforming to the
- // "process.parent_pid" semantic conventions. It represents the parent
- // Process identifier (PPID).
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 111
- ProcessParentPIDKey = attribute.Key("process.parent_pid")
-
- // ProcessPIDKey is the attribute Key conforming to the "process.pid"
- // semantic conventions. It represents the process identifier (PID).
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 1234
- ProcessPIDKey = attribute.Key("process.pid")
-
- // ProcessRealUserIDKey is the attribute Key conforming to the
- // "process.real_user.id" semantic conventions. It represents the real user
- // ID (RUID) of the process.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 1000
- ProcessRealUserIDKey = attribute.Key("process.real_user.id")
-
- // ProcessRealUserNameKey is the attribute Key conforming to the
- // "process.real_user.name" semantic conventions. It represents the
- // username of the real user of the process.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'operator'
- ProcessRealUserNameKey = attribute.Key("process.real_user.name")
-
- // ProcessRuntimeDescriptionKey is the attribute Key conforming to the
- // "process.runtime.description" semantic conventions. It represents an
- // additional description about the runtime of the process, for example a
- // specific vendor customization of the runtime environment.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'Eclipse OpenJ9 Eclipse OpenJ9 VM openj9-0.21.0'
- ProcessRuntimeDescriptionKey = attribute.Key("process.runtime.description")
-
- // ProcessRuntimeNameKey is the attribute Key conforming to the
- // "process.runtime.name" semantic conventions. It represents the name of
- // the runtime of this process. For compiled native binaries, this SHOULD
- // be the name of the compiler.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'OpenJDK Runtime Environment'
- ProcessRuntimeNameKey = attribute.Key("process.runtime.name")
-
- // ProcessRuntimeVersionKey is the attribute Key conforming to the
- // "process.runtime.version" semantic conventions. It represents the
- // version of the runtime of this process, as returned by the runtime
- // without modification.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '14.0.2'
- ProcessRuntimeVersionKey = attribute.Key("process.runtime.version")
-
- // ProcessSavedUserIDKey is the attribute Key conforming to the
- // "process.saved_user.id" semantic conventions. It represents the saved
- // user ID (SUID) of the process.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 1002
- ProcessSavedUserIDKey = attribute.Key("process.saved_user.id")
-
- // ProcessSavedUserNameKey is the attribute Key conforming to the
- // "process.saved_user.name" semantic conventions. It represents the
- // username of the saved user.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'operator'
- ProcessSavedUserNameKey = attribute.Key("process.saved_user.name")
-
- // ProcessSessionLeaderPIDKey is the attribute Key conforming to the
- // "process.session_leader.pid" semantic conventions. It represents the PID
- // of the process's session leader. This is also the session ID (SID) of
- // the process.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 14
- ProcessSessionLeaderPIDKey = attribute.Key("process.session_leader.pid")
-
- // ProcessUserIDKey is the attribute Key conforming to the
- // "process.user.id" semantic conventions. It represents the effective user
- // ID (EUID) of the process.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 1001
- ProcessUserIDKey = attribute.Key("process.user.id")
-
- // ProcessUserNameKey is the attribute Key conforming to the
- // "process.user.name" semantic conventions. It represents the username of
- // the effective user of the process.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'root'
- ProcessUserNameKey = attribute.Key("process.user.name")
-
- // ProcessVpidKey is the attribute Key conforming to the "process.vpid"
- // semantic conventions. It represents the virtual process identifier.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 12
- // Note: The process ID within a PID namespace. This is not necessarily
- // unique across all processes on the host but it is unique within the
- // process namespace that the process exists within.
- ProcessVpidKey = attribute.Key("process.vpid")
-)
-
-var (
- // voluntary
- ProcessContextSwitchTypeVoluntary = ProcessContextSwitchTypeKey.String("voluntary")
- // involuntary
- ProcessContextSwitchTypeInvoluntary = ProcessContextSwitchTypeKey.String("involuntary")
-)
-
-var (
- // major
- ProcessPagingFaultTypeMajor = ProcessPagingFaultTypeKey.String("major")
- // minor
- ProcessPagingFaultTypeMinor = ProcessPagingFaultTypeKey.String("minor")
-)
-
-// ProcessCommand returns an attribute KeyValue conforming to the
-// "process.command" semantic conventions. It represents the command used to
-// launch the process (i.e. the command name). On Linux based systems, can be
-// set to the zeroth string in `proc/[pid]/cmdline`. On Windows, can be set to
-// the first parameter extracted from `GetCommandLineW`.
-func ProcessCommand(val string) attribute.KeyValue {
- return ProcessCommandKey.String(val)
-}
-
-// ProcessCommandArgs returns an attribute KeyValue conforming to the
-// "process.command_args" semantic conventions. It represents the all the
-// command arguments (including the command/executable itself) as received by
-// the process. On Linux-based systems (and some other Unixoid systems
-// supporting procfs), can be set according to the list of null-delimited
-// strings extracted from `proc/[pid]/cmdline`. For libc-based executables,
-// this would be the full argv vector passed to `main`.
-func ProcessCommandArgs(val ...string) attribute.KeyValue {
- return ProcessCommandArgsKey.StringSlice(val)
-}
-
-// ProcessCommandLine returns an attribute KeyValue conforming to the
-// "process.command_line" semantic conventions. It represents the full command
-// used to launch the process as a single string representing the full command.
-// On Windows, can be set to the result of `GetCommandLineW`. Do not set this
-// if you have to assemble it just for monitoring; use `process.command_args`
-// instead.
-func ProcessCommandLine(val string) attribute.KeyValue {
- return ProcessCommandLineKey.String(val)
-}
-
-// ProcessCreationTime returns an attribute KeyValue conforming to the
-// "process.creation.time" semantic conventions. It represents the date and
-// time the process was created, in ISO 8601 format.
-func ProcessCreationTime(val string) attribute.KeyValue {
- return ProcessCreationTimeKey.String(val)
-}
-
-// ProcessExecutableName returns an attribute KeyValue conforming to the
-// "process.executable.name" semantic conventions. It represents the name of
-// the process executable. On Linux based systems, can be set to the `Name` in
-// `proc/[pid]/status`. On Windows, can be set to the base name of
-// `GetProcessImageFileNameW`.
-func ProcessExecutableName(val string) attribute.KeyValue {
- return ProcessExecutableNameKey.String(val)
-}
-
-// ProcessExecutablePath returns an attribute KeyValue conforming to the
-// "process.executable.path" semantic conventions. It represents the full path
-// to the process executable. On Linux based systems, can be set to the target
-// of `proc/[pid]/exe`. On Windows, can be set to the result of
-// `GetProcessImageFileNameW`.
-func ProcessExecutablePath(val string) attribute.KeyValue {
- return ProcessExecutablePathKey.String(val)
-}
-
-// ProcessExitCode returns an attribute KeyValue conforming to the
-// "process.exit.code" semantic conventions. It represents the exit code of the
-// process.
-func ProcessExitCode(val int) attribute.KeyValue {
- return ProcessExitCodeKey.Int(val)
-}
-
-// ProcessExitTime returns an attribute KeyValue conforming to the
-// "process.exit.time" semantic conventions. It represents the date and time
-// the process exited, in ISO 8601 format.
-func ProcessExitTime(val string) attribute.KeyValue {
- return ProcessExitTimeKey.String(val)
-}
-
-// ProcessGroupLeaderPID returns an attribute KeyValue conforming to the
-// "process.group_leader.pid" semantic conventions. It represents the PID of
-// the process's group leader. This is also the process group ID (PGID) of the
-// process.
-func ProcessGroupLeaderPID(val int) attribute.KeyValue {
- return ProcessGroupLeaderPIDKey.Int(val)
-}
-
-// ProcessInteractive returns an attribute KeyValue conforming to the
-// "process.interactive" semantic conventions. It represents the whether the
-// process is connected to an interactive shell.
-func ProcessInteractive(val bool) attribute.KeyValue {
- return ProcessInteractiveKey.Bool(val)
-}
-
-// ProcessOwner returns an attribute KeyValue conforming to the
-// "process.owner" semantic conventions. It represents the username of the user
-// that owns the process.
-func ProcessOwner(val string) attribute.KeyValue {
- return ProcessOwnerKey.String(val)
-}
-
-// ProcessParentPID returns an attribute KeyValue conforming to the
-// "process.parent_pid" semantic conventions. It represents the parent Process
-// identifier (PPID).
-func ProcessParentPID(val int) attribute.KeyValue {
- return ProcessParentPIDKey.Int(val)
-}
-
-// ProcessPID returns an attribute KeyValue conforming to the "process.pid"
-// semantic conventions. It represents the process identifier (PID).
-func ProcessPID(val int) attribute.KeyValue {
- return ProcessPIDKey.Int(val)
-}
-
-// ProcessRealUserID returns an attribute KeyValue conforming to the
-// "process.real_user.id" semantic conventions. It represents the real user ID
-// (RUID) of the process.
-func ProcessRealUserID(val int) attribute.KeyValue {
- return ProcessRealUserIDKey.Int(val)
-}
-
-// ProcessRealUserName returns an attribute KeyValue conforming to the
-// "process.real_user.name" semantic conventions. It represents the username of
-// the real user of the process.
-func ProcessRealUserName(val string) attribute.KeyValue {
- return ProcessRealUserNameKey.String(val)
-}
-
-// ProcessRuntimeDescription returns an attribute KeyValue conforming to the
-// "process.runtime.description" semantic conventions. It represents an
-// additional description about the runtime of the process, for example a
-// specific vendor customization of the runtime environment.
-func ProcessRuntimeDescription(val string) attribute.KeyValue {
- return ProcessRuntimeDescriptionKey.String(val)
-}
-
-// ProcessRuntimeName returns an attribute KeyValue conforming to the
-// "process.runtime.name" semantic conventions. It represents the name of the
-// runtime of this process. For compiled native binaries, this SHOULD be the
-// name of the compiler.
-func ProcessRuntimeName(val string) attribute.KeyValue {
- return ProcessRuntimeNameKey.String(val)
-}
-
-// ProcessRuntimeVersion returns an attribute KeyValue conforming to the
-// "process.runtime.version" semantic conventions. It represents the version of
-// the runtime of this process, as returned by the runtime without
-// modification.
-func ProcessRuntimeVersion(val string) attribute.KeyValue {
- return ProcessRuntimeVersionKey.String(val)
-}
-
-// ProcessSavedUserID returns an attribute KeyValue conforming to the
-// "process.saved_user.id" semantic conventions. It represents the saved user
-// ID (SUID) of the process.
-func ProcessSavedUserID(val int) attribute.KeyValue {
- return ProcessSavedUserIDKey.Int(val)
-}
-
-// ProcessSavedUserName returns an attribute KeyValue conforming to the
-// "process.saved_user.name" semantic conventions. It represents the username
-// of the saved user.
-func ProcessSavedUserName(val string) attribute.KeyValue {
- return ProcessSavedUserNameKey.String(val)
-}
-
-// ProcessSessionLeaderPID returns an attribute KeyValue conforming to the
-// "process.session_leader.pid" semantic conventions. It represents the PID of
-// the process's session leader. This is also the session ID (SID) of the
-// process.
-func ProcessSessionLeaderPID(val int) attribute.KeyValue {
- return ProcessSessionLeaderPIDKey.Int(val)
-}
-
-// ProcessUserID returns an attribute KeyValue conforming to the
-// "process.user.id" semantic conventions. It represents the effective user ID
-// (EUID) of the process.
-func ProcessUserID(val int) attribute.KeyValue {
- return ProcessUserIDKey.Int(val)
-}
-
-// ProcessUserName returns an attribute KeyValue conforming to the
-// "process.user.name" semantic conventions. It represents the username of the
-// effective user of the process.
-func ProcessUserName(val string) attribute.KeyValue {
- return ProcessUserNameKey.String(val)
-}
-
-// ProcessVpid returns an attribute KeyValue conforming to the
-// "process.vpid" semantic conventions. It represents the virtual process
-// identifier.
-func ProcessVpid(val int) attribute.KeyValue {
- return ProcessVpidKey.Int(val)
-}
-
-// Attributes for process CPU
-const (
- // ProcessCPUStateKey is the attribute Key conforming to the
- // "process.cpu.state" semantic conventions. It represents the CPU state of
- // the process.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- ProcessCPUStateKey = attribute.Key("process.cpu.state")
-)
-
-var (
- // system
- ProcessCPUStateSystem = ProcessCPUStateKey.String("system")
- // user
- ProcessCPUStateUser = ProcessCPUStateKey.String("user")
- // wait
- ProcessCPUStateWait = ProcessCPUStateKey.String("wait")
-)
-
-// Attributes for remote procedure calls.
-const (
- // RPCConnectRPCErrorCodeKey is the attribute Key conforming to the
- // "rpc.connect_rpc.error_code" semantic conventions. It represents the
- // [error codes](https://connect.build/docs/protocol/#error-codes) of the
- // Connect request. Error codes are always string values.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- RPCConnectRPCErrorCodeKey = attribute.Key("rpc.connect_rpc.error_code")
-
- // RPCGRPCStatusCodeKey is the attribute Key conforming to the
- // "rpc.grpc.status_code" semantic conventions. It represents the [numeric
- // status
- // code](https://github.com/grpc/grpc/blob/v1.33.2/doc/statuscodes.md) of
- // the gRPC request.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- RPCGRPCStatusCodeKey = attribute.Key("rpc.grpc.status_code")
-
- // RPCJsonrpcErrorCodeKey is the attribute Key conforming to the
- // "rpc.jsonrpc.error_code" semantic conventions. It represents the
- // `error.code` property of response if it is an error response.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: -32700, 100
- RPCJsonrpcErrorCodeKey = attribute.Key("rpc.jsonrpc.error_code")
-
- // RPCJsonrpcErrorMessageKey is the attribute Key conforming to the
- // "rpc.jsonrpc.error_message" semantic conventions. It represents the
- // `error.message` property of response if it is an error response.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'Parse error', 'User already exists'
- RPCJsonrpcErrorMessageKey = attribute.Key("rpc.jsonrpc.error_message")
-
- // RPCJsonrpcRequestIDKey is the attribute Key conforming to the
- // "rpc.jsonrpc.request_id" semantic conventions. It represents the `id`
- // property of request or response. Since protocol allows id to be int,
- // string, `null` or missing (for notifications), value is expected to be
- // cast to string for simplicity. Use empty string in case of `null` value.
- // Omit entirely if this is a notification.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '10', 'request-7', ''
- RPCJsonrpcRequestIDKey = attribute.Key("rpc.jsonrpc.request_id")
-
- // RPCJsonrpcVersionKey is the attribute Key conforming to the
- // "rpc.jsonrpc.version" semantic conventions. It represents the protocol
- // version as in `jsonrpc` property of request/response. Since JSON-RPC 1.0
- // doesn't specify this, the value can be omitted.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '2.0', '1.0'
- RPCJsonrpcVersionKey = attribute.Key("rpc.jsonrpc.version")
-
- // RPCMessageCompressedSizeKey is the attribute Key conforming to the
- // "rpc.message.compressed_size" semantic conventions. It represents the
- // compressed size of the message in bytes.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- RPCMessageCompressedSizeKey = attribute.Key("rpc.message.compressed_size")
-
- // RPCMessageIDKey is the attribute Key conforming to the "rpc.message.id"
- // semantic conventions. It represents the mUST be calculated as two
- // different counters starting from `1` one for sent messages and one for
- // received message.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Note: This way we guarantee that the values will be consistent between
- // different implementations.
- RPCMessageIDKey = attribute.Key("rpc.message.id")
-
- // RPCMessageTypeKey is the attribute Key conforming to the
- // "rpc.message.type" semantic conventions. It represents the whether this
- // is a received or sent message.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- RPCMessageTypeKey = attribute.Key("rpc.message.type")
-
- // RPCMessageUncompressedSizeKey is the attribute Key conforming to the
- // "rpc.message.uncompressed_size" semantic conventions. It represents the
- // uncompressed size of the message in bytes.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- RPCMessageUncompressedSizeKey = attribute.Key("rpc.message.uncompressed_size")
-
- // RPCMethodKey is the attribute Key conforming to the "rpc.method"
- // semantic conventions. It represents the name of the (logical) method
- // being called, must be equal to the $method part in the span name.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'exampleMethod'
- // Note: This is the logical name of the method from the RPC interface
- // perspective, which can be different from the name of any implementing
- // method/function. The `code.function` attribute may be used to store the
- // latter (e.g., method actually executing the call on the server side, RPC
- // client stub method on the client side).
- RPCMethodKey = attribute.Key("rpc.method")
-
- // RPCServiceKey is the attribute Key conforming to the "rpc.service"
- // semantic conventions. It represents the full (logical) name of the
- // service being called, including its package name, if applicable.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'myservice.EchoService'
- // Note: This is the logical name of the service from the RPC interface
- // perspective, which can be different from the name of any implementing
- // class. The `code.namespace` attribute may be used to store the latter
- // (despite the attribute name, it may include a class name; e.g., class
- // with method actually executing the call on the server side, RPC client
- // stub class on the client side).
- RPCServiceKey = attribute.Key("rpc.service")
-
- // RPCSystemKey is the attribute Key conforming to the "rpc.system"
- // semantic conventions. It represents a string identifying the remoting
- // system. See below for a list of well-known identifiers.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- RPCSystemKey = attribute.Key("rpc.system")
-)
-
-var (
- // cancelled
- RPCConnectRPCErrorCodeCancelled = RPCConnectRPCErrorCodeKey.String("cancelled")
- // unknown
- RPCConnectRPCErrorCodeUnknown = RPCConnectRPCErrorCodeKey.String("unknown")
- // invalid_argument
- RPCConnectRPCErrorCodeInvalidArgument = RPCConnectRPCErrorCodeKey.String("invalid_argument")
- // deadline_exceeded
- RPCConnectRPCErrorCodeDeadlineExceeded = RPCConnectRPCErrorCodeKey.String("deadline_exceeded")
- // not_found
- RPCConnectRPCErrorCodeNotFound = RPCConnectRPCErrorCodeKey.String("not_found")
- // already_exists
- RPCConnectRPCErrorCodeAlreadyExists = RPCConnectRPCErrorCodeKey.String("already_exists")
- // permission_denied
- RPCConnectRPCErrorCodePermissionDenied = RPCConnectRPCErrorCodeKey.String("permission_denied")
- // resource_exhausted
- RPCConnectRPCErrorCodeResourceExhausted = RPCConnectRPCErrorCodeKey.String("resource_exhausted")
- // failed_precondition
- RPCConnectRPCErrorCodeFailedPrecondition = RPCConnectRPCErrorCodeKey.String("failed_precondition")
- // aborted
- RPCConnectRPCErrorCodeAborted = RPCConnectRPCErrorCodeKey.String("aborted")
- // out_of_range
- RPCConnectRPCErrorCodeOutOfRange = RPCConnectRPCErrorCodeKey.String("out_of_range")
- // unimplemented
- RPCConnectRPCErrorCodeUnimplemented = RPCConnectRPCErrorCodeKey.String("unimplemented")
- // internal
- RPCConnectRPCErrorCodeInternal = RPCConnectRPCErrorCodeKey.String("internal")
- // unavailable
- RPCConnectRPCErrorCodeUnavailable = RPCConnectRPCErrorCodeKey.String("unavailable")
- // data_loss
- RPCConnectRPCErrorCodeDataLoss = RPCConnectRPCErrorCodeKey.String("data_loss")
- // unauthenticated
- RPCConnectRPCErrorCodeUnauthenticated = RPCConnectRPCErrorCodeKey.String("unauthenticated")
-)
-
-var (
- // OK
- RPCGRPCStatusCodeOk = RPCGRPCStatusCodeKey.Int(0)
- // CANCELLED
- RPCGRPCStatusCodeCancelled = RPCGRPCStatusCodeKey.Int(1)
- // UNKNOWN
- RPCGRPCStatusCodeUnknown = RPCGRPCStatusCodeKey.Int(2)
- // INVALID_ARGUMENT
- RPCGRPCStatusCodeInvalidArgument = RPCGRPCStatusCodeKey.Int(3)
- // DEADLINE_EXCEEDED
- RPCGRPCStatusCodeDeadlineExceeded = RPCGRPCStatusCodeKey.Int(4)
- // NOT_FOUND
- RPCGRPCStatusCodeNotFound = RPCGRPCStatusCodeKey.Int(5)
- // ALREADY_EXISTS
- RPCGRPCStatusCodeAlreadyExists = RPCGRPCStatusCodeKey.Int(6)
- // PERMISSION_DENIED
- RPCGRPCStatusCodePermissionDenied = RPCGRPCStatusCodeKey.Int(7)
- // RESOURCE_EXHAUSTED
- RPCGRPCStatusCodeResourceExhausted = RPCGRPCStatusCodeKey.Int(8)
- // FAILED_PRECONDITION
- RPCGRPCStatusCodeFailedPrecondition = RPCGRPCStatusCodeKey.Int(9)
- // ABORTED
- RPCGRPCStatusCodeAborted = RPCGRPCStatusCodeKey.Int(10)
- // OUT_OF_RANGE
- RPCGRPCStatusCodeOutOfRange = RPCGRPCStatusCodeKey.Int(11)
- // UNIMPLEMENTED
- RPCGRPCStatusCodeUnimplemented = RPCGRPCStatusCodeKey.Int(12)
- // INTERNAL
- RPCGRPCStatusCodeInternal = RPCGRPCStatusCodeKey.Int(13)
- // UNAVAILABLE
- RPCGRPCStatusCodeUnavailable = RPCGRPCStatusCodeKey.Int(14)
- // DATA_LOSS
- RPCGRPCStatusCodeDataLoss = RPCGRPCStatusCodeKey.Int(15)
- // UNAUTHENTICATED
- RPCGRPCStatusCodeUnauthenticated = RPCGRPCStatusCodeKey.Int(16)
-)
-
-var (
- // sent
- RPCMessageTypeSent = RPCMessageTypeKey.String("SENT")
- // received
- RPCMessageTypeReceived = RPCMessageTypeKey.String("RECEIVED")
-)
-
-var (
- // gRPC
- RPCSystemGRPC = RPCSystemKey.String("grpc")
- // Java RMI
- RPCSystemJavaRmi = RPCSystemKey.String("java_rmi")
- // .NET WCF
- RPCSystemDotnetWcf = RPCSystemKey.String("dotnet_wcf")
- // Apache Dubbo
- RPCSystemApacheDubbo = RPCSystemKey.String("apache_dubbo")
- // Connect RPC
- RPCSystemConnectRPC = RPCSystemKey.String("connect_rpc")
-)
-
-// RPCJsonrpcErrorCode returns an attribute KeyValue conforming to the
-// "rpc.jsonrpc.error_code" semantic conventions. It represents the
-// `error.code` property of response if it is an error response.
-func RPCJsonrpcErrorCode(val int) attribute.KeyValue {
- return RPCJsonrpcErrorCodeKey.Int(val)
-}
-
-// RPCJsonrpcErrorMessage returns an attribute KeyValue conforming to the
-// "rpc.jsonrpc.error_message" semantic conventions. It represents the
-// `error.message` property of response if it is an error response.
-func RPCJsonrpcErrorMessage(val string) attribute.KeyValue {
- return RPCJsonrpcErrorMessageKey.String(val)
-}
-
-// RPCJsonrpcRequestID returns an attribute KeyValue conforming to the
-// "rpc.jsonrpc.request_id" semantic conventions. It represents the `id`
-// property of request or response. Since protocol allows id to be int, string,
-// `null` or missing (for notifications), value is expected to be cast to
-// string for simplicity. Use empty string in case of `null` value. Omit
-// entirely if this is a notification.
-func RPCJsonrpcRequestID(val string) attribute.KeyValue {
- return RPCJsonrpcRequestIDKey.String(val)
-}
-
-// RPCJsonrpcVersion returns an attribute KeyValue conforming to the
-// "rpc.jsonrpc.version" semantic conventions. It represents the protocol
-// version as in `jsonrpc` property of request/response. Since JSON-RPC 1.0
-// doesn't specify this, the value can be omitted.
-func RPCJsonrpcVersion(val string) attribute.KeyValue {
- return RPCJsonrpcVersionKey.String(val)
-}
-
-// RPCMessageCompressedSize returns an attribute KeyValue conforming to the
-// "rpc.message.compressed_size" semantic conventions. It represents the
-// compressed size of the message in bytes.
-func RPCMessageCompressedSize(val int) attribute.KeyValue {
- return RPCMessageCompressedSizeKey.Int(val)
-}
-
-// RPCMessageID returns an attribute KeyValue conforming to the
-// "rpc.message.id" semantic conventions. It represents the mUST be calculated
-// as two different counters starting from `1` one for sent messages and one
-// for received message.
-func RPCMessageID(val int) attribute.KeyValue {
- return RPCMessageIDKey.Int(val)
-}
-
-// RPCMessageUncompressedSize returns an attribute KeyValue conforming to
-// the "rpc.message.uncompressed_size" semantic conventions. It represents the
-// uncompressed size of the message in bytes.
-func RPCMessageUncompressedSize(val int) attribute.KeyValue {
- return RPCMessageUncompressedSizeKey.Int(val)
-}
-
-// RPCMethod returns an attribute KeyValue conforming to the "rpc.method"
-// semantic conventions. It represents the name of the (logical) method being
-// called, must be equal to the $method part in the span name.
-func RPCMethod(val string) attribute.KeyValue {
- return RPCMethodKey.String(val)
-}
-
-// RPCService returns an attribute KeyValue conforming to the "rpc.service"
-// semantic conventions. It represents the full (logical) name of the service
-// being called, including its package name, if applicable.
-func RPCService(val string) attribute.KeyValue {
- return RPCServiceKey.String(val)
-}
-
-// These attributes may be used to describe the server in a connection-based
-// network interaction where there is one side that initiates the connection
-// (the client is the side that initiates the connection). This covers all TCP
-// network interactions since TCP is connection-based and one side initiates
-// the connection (an exception is made for peer-to-peer communication over TCP
-// where the "user-facing" surface of the protocol / API doesn't expose a clear
-// notion of client and server). This also covers UDP network interactions
-// where one side initiates the interaction, e.g. QUIC (HTTP/3) and DNS.
-const (
- // ServerAddressKey is the attribute Key conforming to the "server.address"
- // semantic conventions. It represents the server domain name if available
- // without reverse DNS lookup; otherwise, IP address or Unix domain socket
- // name.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'example.com', '10.1.2.80', '/tmp/my.sock'
- // Note: When observed from the client side, and when communicating through
- // an intermediary, `server.address` SHOULD represent the server address
- // behind any intermediaries, for example proxies, if it's available.
- ServerAddressKey = attribute.Key("server.address")
-
- // ServerPortKey is the attribute Key conforming to the "server.port"
- // semantic conventions. It represents the server port number.
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 80, 8080, 443
- // Note: When observed from the client side, and when communicating through
- // an intermediary, `server.port` SHOULD represent the server port behind
- // any intermediaries, for example proxies, if it's available.
- ServerPortKey = attribute.Key("server.port")
-)
-
-// ServerAddress returns an attribute KeyValue conforming to the
-// "server.address" semantic conventions. It represents the server domain name
-// if available without reverse DNS lookup; otherwise, IP address or Unix
-// domain socket name.
-func ServerAddress(val string) attribute.KeyValue {
- return ServerAddressKey.String(val)
-}
-
-// ServerPort returns an attribute KeyValue conforming to the "server.port"
-// semantic conventions. It represents the server port number.
-func ServerPort(val int) attribute.KeyValue {
- return ServerPortKey.Int(val)
-}
-
-// A service instance.
-const (
- // ServiceInstanceIDKey is the attribute Key conforming to the
- // "service.instance.id" semantic conventions. It represents the string ID
- // of the service instance.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '627cc493-f310-47de-96bd-71410b7dec09'
- // Note: MUST be unique for each instance of the same
- // `service.namespace,service.name` pair (in other words
- // `service.namespace,service.name,service.instance.id` triplet MUST be
- // globally unique). The ID helps to
- // distinguish instances of the same service that exist at the same time
- // (e.g. instances of a horizontally scaled
- // service).
- //
- // Implementations, such as SDKs, are recommended to generate a random
- // Version 1 or Version 4 [RFC
- // 4122](https://www.ietf.org/rfc/rfc4122.txt) UUID, but are free to use an
- // inherent unique ID as the source of
- // this value if stability is desirable. In that case, the ID SHOULD be
- // used as source of a UUID Version 5 and
- // SHOULD use the following UUID as the namespace:
- // `4d63009a-8d0f-11ee-aad7-4c796ed8e320`.
- //
- // UUIDs are typically recommended, as only an opaque value for the
- // purposes of identifying a service instance is
- // needed. Similar to what can be seen in the man page for the
- // [`/etc/machine-id`](https://www.freedesktop.org/software/systemd/man/machine-id.html)
- // file, the underlying
- // data, such as pod name and namespace should be treated as confidential,
- // being the user's choice to expose it
- // or not via another resource attribute.
- //
- // For applications running behind an application server (like unicorn), we
- // do not recommend using one identifier
- // for all processes participating in the application. Instead, it's
- // recommended each division (e.g. a worker
- // thread in unicorn) to have its own instance.id.
- //
- // It's not recommended for a Collector to set `service.instance.id` if it
- // can't unambiguously determine the
- // service instance that is generating that telemetry. For instance,
- // creating an UUID based on `pod.name` will
- // likely be wrong, as the Collector might not know from which container
- // within that pod the telemetry originated.
- // However, Collectors can set the `service.instance.id` if they can
- // unambiguously determine the service instance
- // for that telemetry. This is typically the case for scraping receivers,
- // as they know the target address and
- // port.
- ServiceInstanceIDKey = attribute.Key("service.instance.id")
-
- // ServiceNameKey is the attribute Key conforming to the "service.name"
- // semantic conventions. It represents the logical name of the service.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'shoppingcart'
- // Note: MUST be the same for all instances of horizontally scaled
- // services. If the value was not specified, SDKs MUST fallback to
- // `unknown_service:` concatenated with
- // [`process.executable.name`](process.md), e.g. `unknown_service:bash`. If
- // `process.executable.name` is not available, the value MUST be set to
- // `unknown_service`.
- ServiceNameKey = attribute.Key("service.name")
-
- // ServiceNamespaceKey is the attribute Key conforming to the
- // "service.namespace" semantic conventions. It represents a namespace for
- // `service.name`.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'Shop'
- // Note: A string value having a meaning that helps to distinguish a group
- // of services, for example the team name that owns a group of services.
- // `service.name` is expected to be unique within the same namespace. If
- // `service.namespace` is not specified in the Resource then `service.name`
- // is expected to be unique for all services that have no explicit
- // namespace defined (so the empty/unspecified namespace is simply one more
- // valid namespace). Zero-length namespace string is assumed equal to
- // unspecified namespace.
- ServiceNamespaceKey = attribute.Key("service.namespace")
-
- // ServiceVersionKey is the attribute Key conforming to the
- // "service.version" semantic conventions. It represents the version string
- // of the service API or implementation. The format is not defined by these
- // conventions.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '2.0.0', 'a01dbef8a'
- ServiceVersionKey = attribute.Key("service.version")
-)
-
-// ServiceInstanceID returns an attribute KeyValue conforming to the
-// "service.instance.id" semantic conventions. It represents the string ID of
-// the service instance.
-func ServiceInstanceID(val string) attribute.KeyValue {
- return ServiceInstanceIDKey.String(val)
-}
-
-// ServiceName returns an attribute KeyValue conforming to the
-// "service.name" semantic conventions. It represents the logical name of the
-// service.
-func ServiceName(val string) attribute.KeyValue {
- return ServiceNameKey.String(val)
-}
-
-// ServiceNamespace returns an attribute KeyValue conforming to the
-// "service.namespace" semantic conventions. It represents a namespace for
-// `service.name`.
-func ServiceNamespace(val string) attribute.KeyValue {
- return ServiceNamespaceKey.String(val)
-}
-
-// ServiceVersion returns an attribute KeyValue conforming to the
-// "service.version" semantic conventions. It represents the version string of
-// the service API or implementation. The format is not defined by these
-// conventions.
-func ServiceVersion(val string) attribute.KeyValue {
- return ServiceVersionKey.String(val)
-}
-
-// Session is defined as the period of time encompassing all activities
-// performed by the application and the actions executed by the end user.
-// Consequently, a Session is represented as a collection of Logs, Events, and
-// Spans emitted by the Client Application throughout the Session's duration.
-// Each Session is assigned a unique identifier, which is included as an
-// attribute in the Logs, Events, and Spans generated during the Session's
-// lifecycle.
-// When a session reaches end of life, typically due to user inactivity or
-// session timeout, a new session identifier will be assigned. The previous
-// session identifier may be provided by the instrumentation so that telemetry
-// backends can link the two sessions.
-const (
- // SessionIDKey is the attribute Key conforming to the "session.id"
- // semantic conventions. It represents a unique id to identify a session.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '00112233-4455-6677-8899-aabbccddeeff'
- SessionIDKey = attribute.Key("session.id")
-
- // SessionPreviousIDKey is the attribute Key conforming to the
- // "session.previous_id" semantic conventions. It represents the previous
- // `session.id` for this user, when known.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '00112233-4455-6677-8899-aabbccddeeff'
- SessionPreviousIDKey = attribute.Key("session.previous_id")
-)
-
-// SessionID returns an attribute KeyValue conforming to the "session.id"
-// semantic conventions. It represents a unique id to identify a session.
-func SessionID(val string) attribute.KeyValue {
- return SessionIDKey.String(val)
-}
-
-// SessionPreviousID returns an attribute KeyValue conforming to the
-// "session.previous_id" semantic conventions. It represents the previous
-// `session.id` for this user, when known.
-func SessionPreviousID(val string) attribute.KeyValue {
- return SessionPreviousIDKey.String(val)
-}
-
-// SignalR attributes
-const (
- // SignalrConnectionStatusKey is the attribute Key conforming to the
- // "signalr.connection.status" semantic conventions. It represents the
- // signalR HTTP connection closure status.
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'app_shutdown', 'timeout'
- SignalrConnectionStatusKey = attribute.Key("signalr.connection.status")
-
- // SignalrTransportKey is the attribute Key conforming to the
- // "signalr.transport" semantic conventions. It represents the [SignalR
- // transport
- // type](https://github.com/dotnet/aspnetcore/blob/main/src/SignalR/docs/specs/TransportProtocols.md)
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'web_sockets', 'long_polling'
- SignalrTransportKey = attribute.Key("signalr.transport")
-)
-
-var (
- // The connection was closed normally
- SignalrConnectionStatusNormalClosure = SignalrConnectionStatusKey.String("normal_closure")
- // The connection was closed due to a timeout
- SignalrConnectionStatusTimeout = SignalrConnectionStatusKey.String("timeout")
- // The connection was closed because the app is shutting down
- SignalrConnectionStatusAppShutdown = SignalrConnectionStatusKey.String("app_shutdown")
-)
-
-var (
- // ServerSentEvents protocol
- SignalrTransportServerSentEvents = SignalrTransportKey.String("server_sent_events")
- // LongPolling protocol
- SignalrTransportLongPolling = SignalrTransportKey.String("long_polling")
- // WebSockets protocol
- SignalrTransportWebSockets = SignalrTransportKey.String("web_sockets")
-)
-
-// These attributes may be used to describe the sender of a network
-// exchange/packet. These should be used when there is no client/server
-// relationship between the two sides, or when that relationship is unknown.
-// This covers low-level network interactions (e.g. packet tracing) where you
-// don't know if there was a connection or which side initiated it. This also
-// covers unidirectional UDP flows and peer-to-peer communication where the
-// "user-facing" surface of the protocol / API doesn't expose a clear notion of
-// client and server.
-const (
- // SourceAddressKey is the attribute Key conforming to the "source.address"
- // semantic conventions. It represents the source address - domain name if
- // available without reverse DNS lookup; otherwise, IP address or Unix
- // domain socket name.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'source.example.com', '10.1.2.80', '/tmp/my.sock'
- // Note: When observed from the destination side, and when communicating
- // through an intermediary, `source.address` SHOULD represent the source
- // address behind any intermediaries, for example proxies, if it's
- // available.
- SourceAddressKey = attribute.Key("source.address")
-
- // SourcePortKey is the attribute Key conforming to the "source.port"
- // semantic conventions. It represents the source port number
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 3389, 2888
- SourcePortKey = attribute.Key("source.port")
-)
-
-// SourceAddress returns an attribute KeyValue conforming to the
-// "source.address" semantic conventions. It represents the source address -
-// domain name if available without reverse DNS lookup; otherwise, IP address
-// or Unix domain socket name.
-func SourceAddress(val string) attribute.KeyValue {
- return SourceAddressKey.String(val)
-}
-
-// SourcePort returns an attribute KeyValue conforming to the "source.port"
-// semantic conventions. It represents the source port number
-func SourcePort(val int) attribute.KeyValue {
- return SourcePortKey.Int(val)
-}
-
-// Describes System attributes
-const (
- // SystemDeviceKey is the attribute Key conforming to the "system.device"
- // semantic conventions. It represents the device identifier
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '(identifier)'
- SystemDeviceKey = attribute.Key("system.device")
-)
-
-// SystemDevice returns an attribute KeyValue conforming to the
-// "system.device" semantic conventions. It represents the device identifier
-func SystemDevice(val string) attribute.KeyValue {
- return SystemDeviceKey.String(val)
-}
-
-// Describes System CPU attributes
-const (
- // SystemCPULogicalNumberKey is the attribute Key conforming to the
- // "system.cpu.logical_number" semantic conventions. It represents the
- // logical CPU number [0..n-1]
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 1
- SystemCPULogicalNumberKey = attribute.Key("system.cpu.logical_number")
-
- // SystemCPUStateKey is the attribute Key conforming to the
- // "system.cpu.state" semantic conventions. It represents the state of the
- // CPU
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'idle', 'interrupt'
- SystemCPUStateKey = attribute.Key("system.cpu.state")
-)
-
-var (
- // user
- SystemCPUStateUser = SystemCPUStateKey.String("user")
- // system
- SystemCPUStateSystem = SystemCPUStateKey.String("system")
- // nice
- SystemCPUStateNice = SystemCPUStateKey.String("nice")
- // idle
- SystemCPUStateIdle = SystemCPUStateKey.String("idle")
- // iowait
- SystemCPUStateIowait = SystemCPUStateKey.String("iowait")
- // interrupt
- SystemCPUStateInterrupt = SystemCPUStateKey.String("interrupt")
- // steal
- SystemCPUStateSteal = SystemCPUStateKey.String("steal")
-)
-
-// SystemCPULogicalNumber returns an attribute KeyValue conforming to the
-// "system.cpu.logical_number" semantic conventions. It represents the logical
-// CPU number [0..n-1]
-func SystemCPULogicalNumber(val int) attribute.KeyValue {
- return SystemCPULogicalNumberKey.Int(val)
-}
-
-// Describes System Memory attributes
-const (
- // SystemMemoryStateKey is the attribute Key conforming to the
- // "system.memory.state" semantic conventions. It represents the memory
- // state
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'free', 'cached'
- SystemMemoryStateKey = attribute.Key("system.memory.state")
-)
-
-var (
- // used
- SystemMemoryStateUsed = SystemMemoryStateKey.String("used")
- // free
- SystemMemoryStateFree = SystemMemoryStateKey.String("free")
- // shared
- SystemMemoryStateShared = SystemMemoryStateKey.String("shared")
- // buffers
- SystemMemoryStateBuffers = SystemMemoryStateKey.String("buffers")
- // cached
- SystemMemoryStateCached = SystemMemoryStateKey.String("cached")
-)
-
-// Describes System Memory Paging attributes
-const (
- // SystemPagingDirectionKey is the attribute Key conforming to the
- // "system.paging.direction" semantic conventions. It represents the paging
- // access direction
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'in'
- SystemPagingDirectionKey = attribute.Key("system.paging.direction")
-
- // SystemPagingStateKey is the attribute Key conforming to the
- // "system.paging.state" semantic conventions. It represents the memory
- // paging state
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'free'
- SystemPagingStateKey = attribute.Key("system.paging.state")
-
- // SystemPagingTypeKey is the attribute Key conforming to the
- // "system.paging.type" semantic conventions. It represents the memory
- // paging type
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'minor'
- SystemPagingTypeKey = attribute.Key("system.paging.type")
-)
-
-var (
- // in
- SystemPagingDirectionIn = SystemPagingDirectionKey.String("in")
- // out
- SystemPagingDirectionOut = SystemPagingDirectionKey.String("out")
-)
-
-var (
- // used
- SystemPagingStateUsed = SystemPagingStateKey.String("used")
- // free
- SystemPagingStateFree = SystemPagingStateKey.String("free")
-)
-
-var (
- // major
- SystemPagingTypeMajor = SystemPagingTypeKey.String("major")
- // minor
- SystemPagingTypeMinor = SystemPagingTypeKey.String("minor")
-)
-
-// Describes Filesystem attributes
-const (
- // SystemFilesystemModeKey is the attribute Key conforming to the
- // "system.filesystem.mode" semantic conventions. It represents the
- // filesystem mode
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'rw, ro'
- SystemFilesystemModeKey = attribute.Key("system.filesystem.mode")
-
- // SystemFilesystemMountpointKey is the attribute Key conforming to the
- // "system.filesystem.mountpoint" semantic conventions. It represents the
- // filesystem mount path
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '/mnt/data'
- SystemFilesystemMountpointKey = attribute.Key("system.filesystem.mountpoint")
-
- // SystemFilesystemStateKey is the attribute Key conforming to the
- // "system.filesystem.state" semantic conventions. It represents the
- // filesystem state
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'used'
- SystemFilesystemStateKey = attribute.Key("system.filesystem.state")
-
- // SystemFilesystemTypeKey is the attribute Key conforming to the
- // "system.filesystem.type" semantic conventions. It represents the
- // filesystem type
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'ext4'
- SystemFilesystemTypeKey = attribute.Key("system.filesystem.type")
-)
-
-var (
- // used
- SystemFilesystemStateUsed = SystemFilesystemStateKey.String("used")
- // free
- SystemFilesystemStateFree = SystemFilesystemStateKey.String("free")
- // reserved
- SystemFilesystemStateReserved = SystemFilesystemStateKey.String("reserved")
-)
-
-var (
- // fat32
- SystemFilesystemTypeFat32 = SystemFilesystemTypeKey.String("fat32")
- // exfat
- SystemFilesystemTypeExfat = SystemFilesystemTypeKey.String("exfat")
- // ntfs
- SystemFilesystemTypeNtfs = SystemFilesystemTypeKey.String("ntfs")
- // refs
- SystemFilesystemTypeRefs = SystemFilesystemTypeKey.String("refs")
- // hfsplus
- SystemFilesystemTypeHfsplus = SystemFilesystemTypeKey.String("hfsplus")
- // ext4
- SystemFilesystemTypeExt4 = SystemFilesystemTypeKey.String("ext4")
-)
-
-// SystemFilesystemMode returns an attribute KeyValue conforming to the
-// "system.filesystem.mode" semantic conventions. It represents the filesystem
-// mode
-func SystemFilesystemMode(val string) attribute.KeyValue {
- return SystemFilesystemModeKey.String(val)
-}
-
-// SystemFilesystemMountpoint returns an attribute KeyValue conforming to
-// the "system.filesystem.mountpoint" semantic conventions. It represents the
-// filesystem mount path
-func SystemFilesystemMountpoint(val string) attribute.KeyValue {
- return SystemFilesystemMountpointKey.String(val)
-}
-
-// Describes Network attributes
-const (
- // SystemNetworkStateKey is the attribute Key conforming to the
- // "system.network.state" semantic conventions. It represents a stateless
- // protocol MUST NOT set this attribute
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'close_wait'
- SystemNetworkStateKey = attribute.Key("system.network.state")
-)
-
-var (
- // close
- SystemNetworkStateClose = SystemNetworkStateKey.String("close")
- // close_wait
- SystemNetworkStateCloseWait = SystemNetworkStateKey.String("close_wait")
- // closing
- SystemNetworkStateClosing = SystemNetworkStateKey.String("closing")
- // delete
- SystemNetworkStateDelete = SystemNetworkStateKey.String("delete")
- // established
- SystemNetworkStateEstablished = SystemNetworkStateKey.String("established")
- // fin_wait_1
- SystemNetworkStateFinWait1 = SystemNetworkStateKey.String("fin_wait_1")
- // fin_wait_2
- SystemNetworkStateFinWait2 = SystemNetworkStateKey.String("fin_wait_2")
- // last_ack
- SystemNetworkStateLastAck = SystemNetworkStateKey.String("last_ack")
- // listen
- SystemNetworkStateListen = SystemNetworkStateKey.String("listen")
- // syn_recv
- SystemNetworkStateSynRecv = SystemNetworkStateKey.String("syn_recv")
- // syn_sent
- SystemNetworkStateSynSent = SystemNetworkStateKey.String("syn_sent")
- // time_wait
- SystemNetworkStateTimeWait = SystemNetworkStateKey.String("time_wait")
-)
-
-// Describes System Process attributes
-const (
- // SystemProcessStatusKey is the attribute Key conforming to the
- // "system.process.status" semantic conventions. It represents the process
- // state, e.g., [Linux Process State
- // Codes](https://man7.org/linux/man-pages/man1/ps.1.html#PROCESS_STATE_CODES)
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'running'
- SystemProcessStatusKey = attribute.Key("system.process.status")
-)
-
-var (
- // running
- SystemProcessStatusRunning = SystemProcessStatusKey.String("running")
- // sleeping
- SystemProcessStatusSleeping = SystemProcessStatusKey.String("sleeping")
- // stopped
- SystemProcessStatusStopped = SystemProcessStatusKey.String("stopped")
- // defunct
- SystemProcessStatusDefunct = SystemProcessStatusKey.String("defunct")
-)
-
-// Attributes for telemetry SDK.
-const (
- // TelemetrySDKLanguageKey is the attribute Key conforming to the
- // "telemetry.sdk.language" semantic conventions. It represents the
- // language of the telemetry SDK.
- //
- // Type: Enum
- // RequirementLevel: Required
- // Stability: stable
- TelemetrySDKLanguageKey = attribute.Key("telemetry.sdk.language")
-
- // TelemetrySDKNameKey is the attribute Key conforming to the
- // "telemetry.sdk.name" semantic conventions. It represents the name of the
- // telemetry SDK as defined above.
- //
- // Type: string
- // RequirementLevel: Required
- // Stability: stable
- // Examples: 'opentelemetry'
- // Note: The OpenTelemetry SDK MUST set the `telemetry.sdk.name` attribute
- // to `opentelemetry`.
- // If another SDK, like a fork or a vendor-provided implementation, is
- // used, this SDK MUST set the
- // `telemetry.sdk.name` attribute to the fully-qualified class or module
- // name of this SDK's main entry point
- // or another suitable identifier depending on the language.
- // The identifier `opentelemetry` is reserved and MUST NOT be used in this
- // case.
- // All custom identifiers SHOULD be stable across different versions of an
- // implementation.
- TelemetrySDKNameKey = attribute.Key("telemetry.sdk.name")
-
- // TelemetrySDKVersionKey is the attribute Key conforming to the
- // "telemetry.sdk.version" semantic conventions. It represents the version
- // string of the telemetry SDK.
- //
- // Type: string
- // RequirementLevel: Required
- // Stability: stable
- // Examples: '1.2.3'
- TelemetrySDKVersionKey = attribute.Key("telemetry.sdk.version")
-
- // TelemetryDistroNameKey is the attribute Key conforming to the
- // "telemetry.distro.name" semantic conventions. It represents the name of
- // the auto instrumentation agent or distribution, if used.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'parts-unlimited-java'
- // Note: Official auto instrumentation agents and distributions SHOULD set
- // the `telemetry.distro.name` attribute to
- // a string starting with `opentelemetry-`, e.g.
- // `opentelemetry-java-instrumentation`.
- TelemetryDistroNameKey = attribute.Key("telemetry.distro.name")
-
- // TelemetryDistroVersionKey is the attribute Key conforming to the
- // "telemetry.distro.version" semantic conventions. It represents the
- // version string of the auto instrumentation agent or distribution, if
- // used.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '1.2.3'
- TelemetryDistroVersionKey = attribute.Key("telemetry.distro.version")
-)
-
-var (
- // cpp
- TelemetrySDKLanguageCPP = TelemetrySDKLanguageKey.String("cpp")
- // dotnet
- TelemetrySDKLanguageDotnet = TelemetrySDKLanguageKey.String("dotnet")
- // erlang
- TelemetrySDKLanguageErlang = TelemetrySDKLanguageKey.String("erlang")
- // go
- TelemetrySDKLanguageGo = TelemetrySDKLanguageKey.String("go")
- // java
- TelemetrySDKLanguageJava = TelemetrySDKLanguageKey.String("java")
- // nodejs
- TelemetrySDKLanguageNodejs = TelemetrySDKLanguageKey.String("nodejs")
- // php
- TelemetrySDKLanguagePHP = TelemetrySDKLanguageKey.String("php")
- // python
- TelemetrySDKLanguagePython = TelemetrySDKLanguageKey.String("python")
- // ruby
- TelemetrySDKLanguageRuby = TelemetrySDKLanguageKey.String("ruby")
- // rust
- TelemetrySDKLanguageRust = TelemetrySDKLanguageKey.String("rust")
- // swift
- TelemetrySDKLanguageSwift = TelemetrySDKLanguageKey.String("swift")
- // webjs
- TelemetrySDKLanguageWebjs = TelemetrySDKLanguageKey.String("webjs")
-)
-
-// TelemetrySDKName returns an attribute KeyValue conforming to the
-// "telemetry.sdk.name" semantic conventions. It represents the name of the
-// telemetry SDK as defined above.
-func TelemetrySDKName(val string) attribute.KeyValue {
- return TelemetrySDKNameKey.String(val)
-}
-
-// TelemetrySDKVersion returns an attribute KeyValue conforming to the
-// "telemetry.sdk.version" semantic conventions. It represents the version
-// string of the telemetry SDK.
-func TelemetrySDKVersion(val string) attribute.KeyValue {
- return TelemetrySDKVersionKey.String(val)
-}
-
-// TelemetryDistroName returns an attribute KeyValue conforming to the
-// "telemetry.distro.name" semantic conventions. It represents the name of the
-// auto instrumentation agent or distribution, if used.
-func TelemetryDistroName(val string) attribute.KeyValue {
- return TelemetryDistroNameKey.String(val)
-}
-
-// TelemetryDistroVersion returns an attribute KeyValue conforming to the
-// "telemetry.distro.version" semantic conventions. It represents the version
-// string of the auto instrumentation agent or distribution, if used.
-func TelemetryDistroVersion(val string) attribute.KeyValue {
- return TelemetryDistroVersionKey.String(val)
-}
-
-// These attributes may be used for any operation to store information about a
-// thread that started a span.
-const (
- // ThreadIDKey is the attribute Key conforming to the "thread.id" semantic
- // conventions. It represents the current "managed" thread ID (as opposed
- // to OS thread ID).
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 42
- ThreadIDKey = attribute.Key("thread.id")
-
- // ThreadNameKey is the attribute Key conforming to the "thread.name"
- // semantic conventions. It represents the current thread name.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'main'
- ThreadNameKey = attribute.Key("thread.name")
-)
-
-// ThreadID returns an attribute KeyValue conforming to the "thread.id"
-// semantic conventions. It represents the current "managed" thread ID (as
-// opposed to OS thread ID).
-func ThreadID(val int) attribute.KeyValue {
- return ThreadIDKey.Int(val)
-}
-
-// ThreadName returns an attribute KeyValue conforming to the "thread.name"
-// semantic conventions. It represents the current thread name.
-func ThreadName(val string) attribute.KeyValue {
- return ThreadNameKey.String(val)
-}
-
-// Semantic convention attributes in the TLS namespace.
-const (
- // TLSCipherKey is the attribute Key conforming to the "tls.cipher"
- // semantic conventions. It represents the string indicating the
- // [cipher](https://datatracker.ietf.org/doc/html/rfc5246#appendix-A.5)
- // used during the current connection.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'TLS_RSA_WITH_3DES_EDE_CBC_SHA',
- // 'TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256'
- // Note: The values allowed for `tls.cipher` MUST be one of the
- // `Descriptions` of the [registered TLS Cipher
- // Suits](https://www.iana.org/assignments/tls-parameters/tls-parameters.xhtml#table-tls-parameters-4).
- TLSCipherKey = attribute.Key("tls.cipher")
-
- // TLSClientCertificateKey is the attribute Key conforming to the
- // "tls.client.certificate" semantic conventions. It represents the
- // pEM-encoded stand-alone certificate offered by the client. This is
- // usually mutually-exclusive of `client.certificate_chain` since this
- // value also exists in that list.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'MII...'
- TLSClientCertificateKey = attribute.Key("tls.client.certificate")
-
- // TLSClientCertificateChainKey is the attribute Key conforming to the
- // "tls.client.certificate_chain" semantic conventions. It represents the
- // array of PEM-encoded certificates that make up the certificate chain
- // offered by the client. This is usually mutually-exclusive of
- // `client.certificate` since that value should be the first certificate in
- // the chain.
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'MII...', 'MI...'
- TLSClientCertificateChainKey = attribute.Key("tls.client.certificate_chain")
-
- // TLSClientHashMd5Key is the attribute Key conforming to the
- // "tls.client.hash.md5" semantic conventions. It represents the
- // certificate fingerprint using the MD5 digest of DER-encoded version of
- // certificate offered by the client. For consistency with other hash
- // values, this value should be formatted as an uppercase hash.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '0F76C7F2C55BFD7D8E8B8F4BFBF0C9EC'
- TLSClientHashMd5Key = attribute.Key("tls.client.hash.md5")
-
- // TLSClientHashSha1Key is the attribute Key conforming to the
- // "tls.client.hash.sha1" semantic conventions. It represents the
- // certificate fingerprint using the SHA1 digest of DER-encoded version of
- // certificate offered by the client. For consistency with other hash
- // values, this value should be formatted as an uppercase hash.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '9E393D93138888D288266C2D915214D1D1CCEB2A'
- TLSClientHashSha1Key = attribute.Key("tls.client.hash.sha1")
-
- // TLSClientHashSha256Key is the attribute Key conforming to the
- // "tls.client.hash.sha256" semantic conventions. It represents the
- // certificate fingerprint using the SHA256 digest of DER-encoded version
- // of certificate offered by the client. For consistency with other hash
- // values, this value should be formatted as an uppercase hash.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples:
- // '0687F666A054EF17A08E2F2162EAB4CBC0D265E1D7875BE74BF3C712CA92DAF0'
- TLSClientHashSha256Key = attribute.Key("tls.client.hash.sha256")
-
- // TLSClientIssuerKey is the attribute Key conforming to the
- // "tls.client.issuer" semantic conventions. It represents the
- // distinguished name of
- // [subject](https://datatracker.ietf.org/doc/html/rfc5280#section-4.1.2.6)
- // of the issuer of the x.509 certificate presented by the client.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'CN=Example Root CA, OU=Infrastructure Team, DC=example,
- // DC=com'
- TLSClientIssuerKey = attribute.Key("tls.client.issuer")
-
- // TLSClientJa3Key is the attribute Key conforming to the "tls.client.ja3"
- // semantic conventions. It represents a hash that identifies clients based
- // on how they perform an SSL/TLS handshake.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'd4e5b18d6b55c71272893221c96ba240'
- TLSClientJa3Key = attribute.Key("tls.client.ja3")
-
- // TLSClientNotAfterKey is the attribute Key conforming to the
- // "tls.client.not_after" semantic conventions. It represents the date/Time
- // indicating when client certificate is no longer considered valid.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '2021-01-01T00:00:00.000Z'
- TLSClientNotAfterKey = attribute.Key("tls.client.not_after")
-
- // TLSClientNotBeforeKey is the attribute Key conforming to the
- // "tls.client.not_before" semantic conventions. It represents the
- // date/Time indicating when client certificate is first considered valid.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '1970-01-01T00:00:00.000Z'
- TLSClientNotBeforeKey = attribute.Key("tls.client.not_before")
-
- // TLSClientServerNameKey is the attribute Key conforming to the
- // "tls.client.server_name" semantic conventions. It represents the also
- // called an SNI, this tells the server which hostname to which the client
- // is attempting to connect to.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'opentelemetry.io'
- TLSClientServerNameKey = attribute.Key("tls.client.server_name")
-
- // TLSClientSubjectKey is the attribute Key conforming to the
- // "tls.client.subject" semantic conventions. It represents the
- // distinguished name of subject of the x.509 certificate presented by the
- // client.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'CN=myclient, OU=Documentation Team, DC=example, DC=com'
- TLSClientSubjectKey = attribute.Key("tls.client.subject")
-
- // TLSClientSupportedCiphersKey is the attribute Key conforming to the
- // "tls.client.supported_ciphers" semantic conventions. It represents the
- // array of ciphers offered by the client during the client hello.
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '"TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384",
- // "TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384", "..."'
- TLSClientSupportedCiphersKey = attribute.Key("tls.client.supported_ciphers")
-
- // TLSCurveKey is the attribute Key conforming to the "tls.curve" semantic
- // conventions. It represents the string indicating the curve used for the
- // given cipher, when applicable
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'secp256r1'
- TLSCurveKey = attribute.Key("tls.curve")
-
- // TLSEstablishedKey is the attribute Key conforming to the
- // "tls.established" semantic conventions. It represents the boolean flag
- // indicating if the TLS negotiation was successful and transitioned to an
- // encrypted tunnel.
- //
- // Type: boolean
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: True
- TLSEstablishedKey = attribute.Key("tls.established")
-
- // TLSNextProtocolKey is the attribute Key conforming to the
- // "tls.next_protocol" semantic conventions. It represents the string
- // indicating the protocol being tunneled. Per the values in the [IANA
- // registry](https://www.iana.org/assignments/tls-extensiontype-values/tls-extensiontype-values.xhtml#alpn-protocol-ids),
- // this string should be lower case.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'http/1.1'
- TLSNextProtocolKey = attribute.Key("tls.next_protocol")
-
- // TLSProtocolNameKey is the attribute Key conforming to the
- // "tls.protocol.name" semantic conventions. It represents the normalized
- // lowercase protocol name parsed from original string of the negotiated
- // [SSL/TLS protocol
- // version](https://www.openssl.org/docs/man1.1.1/man3/SSL_get_version.html#RETURN-VALUES)
- //
- // Type: Enum
- // RequirementLevel: Optional
- // Stability: experimental
- TLSProtocolNameKey = attribute.Key("tls.protocol.name")
-
- // TLSProtocolVersionKey is the attribute Key conforming to the
- // "tls.protocol.version" semantic conventions. It represents the numeric
- // part of the version parsed from the original string of the negotiated
- // [SSL/TLS protocol
- // version](https://www.openssl.org/docs/man1.1.1/man3/SSL_get_version.html#RETURN-VALUES)
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '1.2', '3'
- TLSProtocolVersionKey = attribute.Key("tls.protocol.version")
-
- // TLSResumedKey is the attribute Key conforming to the "tls.resumed"
- // semantic conventions. It represents the boolean flag indicating if this
- // TLS connection was resumed from an existing TLS negotiation.
- //
- // Type: boolean
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: True
- TLSResumedKey = attribute.Key("tls.resumed")
-
- // TLSServerCertificateKey is the attribute Key conforming to the
- // "tls.server.certificate" semantic conventions. It represents the
- // pEM-encoded stand-alone certificate offered by the server. This is
- // usually mutually-exclusive of `server.certificate_chain` since this
- // value also exists in that list.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'MII...'
- TLSServerCertificateKey = attribute.Key("tls.server.certificate")
-
- // TLSServerCertificateChainKey is the attribute Key conforming to the
- // "tls.server.certificate_chain" semantic conventions. It represents the
- // array of PEM-encoded certificates that make up the certificate chain
- // offered by the server. This is usually mutually-exclusive of
- // `server.certificate` since that value should be the first certificate in
- // the chain.
- //
- // Type: string[]
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'MII...', 'MI...'
- TLSServerCertificateChainKey = attribute.Key("tls.server.certificate_chain")
-
- // TLSServerHashMd5Key is the attribute Key conforming to the
- // "tls.server.hash.md5" semantic conventions. It represents the
- // certificate fingerprint using the MD5 digest of DER-encoded version of
- // certificate offered by the server. For consistency with other hash
- // values, this value should be formatted as an uppercase hash.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '0F76C7F2C55BFD7D8E8B8F4BFBF0C9EC'
- TLSServerHashMd5Key = attribute.Key("tls.server.hash.md5")
-
- // TLSServerHashSha1Key is the attribute Key conforming to the
- // "tls.server.hash.sha1" semantic conventions. It represents the
- // certificate fingerprint using the SHA1 digest of DER-encoded version of
- // certificate offered by the server. For consistency with other hash
- // values, this value should be formatted as an uppercase hash.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '9E393D93138888D288266C2D915214D1D1CCEB2A'
- TLSServerHashSha1Key = attribute.Key("tls.server.hash.sha1")
-
- // TLSServerHashSha256Key is the attribute Key conforming to the
- // "tls.server.hash.sha256" semantic conventions. It represents the
- // certificate fingerprint using the SHA256 digest of DER-encoded version
- // of certificate offered by the server. For consistency with other hash
- // values, this value should be formatted as an uppercase hash.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples:
- // '0687F666A054EF17A08E2F2162EAB4CBC0D265E1D7875BE74BF3C712CA92DAF0'
- TLSServerHashSha256Key = attribute.Key("tls.server.hash.sha256")
-
- // TLSServerIssuerKey is the attribute Key conforming to the
- // "tls.server.issuer" semantic conventions. It represents the
- // distinguished name of
- // [subject](https://datatracker.ietf.org/doc/html/rfc5280#section-4.1.2.6)
- // of the issuer of the x.509 certificate presented by the client.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'CN=Example Root CA, OU=Infrastructure Team, DC=example,
- // DC=com'
- TLSServerIssuerKey = attribute.Key("tls.server.issuer")
-
- // TLSServerJa3sKey is the attribute Key conforming to the
- // "tls.server.ja3s" semantic conventions. It represents a hash that
- // identifies servers based on how they perform an SSL/TLS handshake.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'd4e5b18d6b55c71272893221c96ba240'
- TLSServerJa3sKey = attribute.Key("tls.server.ja3s")
-
- // TLSServerNotAfterKey is the attribute Key conforming to the
- // "tls.server.not_after" semantic conventions. It represents the date/Time
- // indicating when server certificate is no longer considered valid.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '2021-01-01T00:00:00.000Z'
- TLSServerNotAfterKey = attribute.Key("tls.server.not_after")
-
- // TLSServerNotBeforeKey is the attribute Key conforming to the
- // "tls.server.not_before" semantic conventions. It represents the
- // date/Time indicating when server certificate is first considered valid.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '1970-01-01T00:00:00.000Z'
- TLSServerNotBeforeKey = attribute.Key("tls.server.not_before")
-
- // TLSServerSubjectKey is the attribute Key conforming to the
- // "tls.server.subject" semantic conventions. It represents the
- // distinguished name of subject of the x.509 certificate presented by the
- // server.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'CN=myserver, OU=Documentation Team, DC=example, DC=com'
- TLSServerSubjectKey = attribute.Key("tls.server.subject")
-)
-
-var (
- // ssl
- TLSProtocolNameSsl = TLSProtocolNameKey.String("ssl")
- // tls
- TLSProtocolNameTLS = TLSProtocolNameKey.String("tls")
-)
-
-// TLSCipher returns an attribute KeyValue conforming to the "tls.cipher"
-// semantic conventions. It represents the string indicating the
-// [cipher](https://datatracker.ietf.org/doc/html/rfc5246#appendix-A.5) used
-// during the current connection.
-func TLSCipher(val string) attribute.KeyValue {
- return TLSCipherKey.String(val)
-}
-
-// TLSClientCertificate returns an attribute KeyValue conforming to the
-// "tls.client.certificate" semantic conventions. It represents the pEM-encoded
-// stand-alone certificate offered by the client. This is usually
-// mutually-exclusive of `client.certificate_chain` since this value also
-// exists in that list.
-func TLSClientCertificate(val string) attribute.KeyValue {
- return TLSClientCertificateKey.String(val)
-}
-
-// TLSClientCertificateChain returns an attribute KeyValue conforming to the
-// "tls.client.certificate_chain" semantic conventions. It represents the array
-// of PEM-encoded certificates that make up the certificate chain offered by
-// the client. This is usually mutually-exclusive of `client.certificate` since
-// that value should be the first certificate in the chain.
-func TLSClientCertificateChain(val ...string) attribute.KeyValue {
- return TLSClientCertificateChainKey.StringSlice(val)
-}
-
-// TLSClientHashMd5 returns an attribute KeyValue conforming to the
-// "tls.client.hash.md5" semantic conventions. It represents the certificate
-// fingerprint using the MD5 digest of DER-encoded version of certificate
-// offered by the client. For consistency with other hash values, this value
-// should be formatted as an uppercase hash.
-func TLSClientHashMd5(val string) attribute.KeyValue {
- return TLSClientHashMd5Key.String(val)
-}
-
-// TLSClientHashSha1 returns an attribute KeyValue conforming to the
-// "tls.client.hash.sha1" semantic conventions. It represents the certificate
-// fingerprint using the SHA1 digest of DER-encoded version of certificate
-// offered by the client. For consistency with other hash values, this value
-// should be formatted as an uppercase hash.
-func TLSClientHashSha1(val string) attribute.KeyValue {
- return TLSClientHashSha1Key.String(val)
-}
-
-// TLSClientHashSha256 returns an attribute KeyValue conforming to the
-// "tls.client.hash.sha256" semantic conventions. It represents the certificate
-// fingerprint using the SHA256 digest of DER-encoded version of certificate
-// offered by the client. For consistency with other hash values, this value
-// should be formatted as an uppercase hash.
-func TLSClientHashSha256(val string) attribute.KeyValue {
- return TLSClientHashSha256Key.String(val)
-}
-
-// TLSClientIssuer returns an attribute KeyValue conforming to the
-// "tls.client.issuer" semantic conventions. It represents the distinguished
-// name of
-// [subject](https://datatracker.ietf.org/doc/html/rfc5280#section-4.1.2.6) of
-// the issuer of the x.509 certificate presented by the client.
-func TLSClientIssuer(val string) attribute.KeyValue {
- return TLSClientIssuerKey.String(val)
-}
-
-// TLSClientJa3 returns an attribute KeyValue conforming to the
-// "tls.client.ja3" semantic conventions. It represents a hash that identifies
-// clients based on how they perform an SSL/TLS handshake.
-func TLSClientJa3(val string) attribute.KeyValue {
- return TLSClientJa3Key.String(val)
-}
-
-// TLSClientNotAfter returns an attribute KeyValue conforming to the
-// "tls.client.not_after" semantic conventions. It represents the date/Time
-// indicating when client certificate is no longer considered valid.
-func TLSClientNotAfter(val string) attribute.KeyValue {
- return TLSClientNotAfterKey.String(val)
-}
-
-// TLSClientNotBefore returns an attribute KeyValue conforming to the
-// "tls.client.not_before" semantic conventions. It represents the date/Time
-// indicating when client certificate is first considered valid.
-func TLSClientNotBefore(val string) attribute.KeyValue {
- return TLSClientNotBeforeKey.String(val)
-}
-
-// TLSClientServerName returns an attribute KeyValue conforming to the
-// "tls.client.server_name" semantic conventions. It represents the also called
-// an SNI, this tells the server which hostname to which the client is
-// attempting to connect to.
-func TLSClientServerName(val string) attribute.KeyValue {
- return TLSClientServerNameKey.String(val)
-}
-
-// TLSClientSubject returns an attribute KeyValue conforming to the
-// "tls.client.subject" semantic conventions. It represents the distinguished
-// name of subject of the x.509 certificate presented by the client.
-func TLSClientSubject(val string) attribute.KeyValue {
- return TLSClientSubjectKey.String(val)
-}
-
-// TLSClientSupportedCiphers returns an attribute KeyValue conforming to the
-// "tls.client.supported_ciphers" semantic conventions. It represents the array
-// of ciphers offered by the client during the client hello.
-func TLSClientSupportedCiphers(val ...string) attribute.KeyValue {
- return TLSClientSupportedCiphersKey.StringSlice(val)
-}
-
-// TLSCurve returns an attribute KeyValue conforming to the "tls.curve"
-// semantic conventions. It represents the string indicating the curve used for
-// the given cipher, when applicable
-func TLSCurve(val string) attribute.KeyValue {
- return TLSCurveKey.String(val)
-}
-
-// TLSEstablished returns an attribute KeyValue conforming to the
-// "tls.established" semantic conventions. It represents the boolean flag
-// indicating if the TLS negotiation was successful and transitioned to an
-// encrypted tunnel.
-func TLSEstablished(val bool) attribute.KeyValue {
- return TLSEstablishedKey.Bool(val)
-}
-
-// TLSNextProtocol returns an attribute KeyValue conforming to the
-// "tls.next_protocol" semantic conventions. It represents the string
-// indicating the protocol being tunneled. Per the values in the [IANA
-// registry](https://www.iana.org/assignments/tls-extensiontype-values/tls-extensiontype-values.xhtml#alpn-protocol-ids),
-// this string should be lower case.
-func TLSNextProtocol(val string) attribute.KeyValue {
- return TLSNextProtocolKey.String(val)
-}
-
-// TLSProtocolVersion returns an attribute KeyValue conforming to the
-// "tls.protocol.version" semantic conventions. It represents the numeric part
-// of the version parsed from the original string of the negotiated [SSL/TLS
-// protocol
-// version](https://www.openssl.org/docs/man1.1.1/man3/SSL_get_version.html#RETURN-VALUES)
-func TLSProtocolVersion(val string) attribute.KeyValue {
- return TLSProtocolVersionKey.String(val)
-}
-
-// TLSResumed returns an attribute KeyValue conforming to the "tls.resumed"
-// semantic conventions. It represents the boolean flag indicating if this TLS
-// connection was resumed from an existing TLS negotiation.
-func TLSResumed(val bool) attribute.KeyValue {
- return TLSResumedKey.Bool(val)
-}
-
-// TLSServerCertificate returns an attribute KeyValue conforming to the
-// "tls.server.certificate" semantic conventions. It represents the pEM-encoded
-// stand-alone certificate offered by the server. This is usually
-// mutually-exclusive of `server.certificate_chain` since this value also
-// exists in that list.
-func TLSServerCertificate(val string) attribute.KeyValue {
- return TLSServerCertificateKey.String(val)
-}
-
-// TLSServerCertificateChain returns an attribute KeyValue conforming to the
-// "tls.server.certificate_chain" semantic conventions. It represents the array
-// of PEM-encoded certificates that make up the certificate chain offered by
-// the server. This is usually mutually-exclusive of `server.certificate` since
-// that value should be the first certificate in the chain.
-func TLSServerCertificateChain(val ...string) attribute.KeyValue {
- return TLSServerCertificateChainKey.StringSlice(val)
-}
-
-// TLSServerHashMd5 returns an attribute KeyValue conforming to the
-// "tls.server.hash.md5" semantic conventions. It represents the certificate
-// fingerprint using the MD5 digest of DER-encoded version of certificate
-// offered by the server. For consistency with other hash values, this value
-// should be formatted as an uppercase hash.
-func TLSServerHashMd5(val string) attribute.KeyValue {
- return TLSServerHashMd5Key.String(val)
-}
-
-// TLSServerHashSha1 returns an attribute KeyValue conforming to the
-// "tls.server.hash.sha1" semantic conventions. It represents the certificate
-// fingerprint using the SHA1 digest of DER-encoded version of certificate
-// offered by the server. For consistency with other hash values, this value
-// should be formatted as an uppercase hash.
-func TLSServerHashSha1(val string) attribute.KeyValue {
- return TLSServerHashSha1Key.String(val)
-}
-
-// TLSServerHashSha256 returns an attribute KeyValue conforming to the
-// "tls.server.hash.sha256" semantic conventions. It represents the certificate
-// fingerprint using the SHA256 digest of DER-encoded version of certificate
-// offered by the server. For consistency with other hash values, this value
-// should be formatted as an uppercase hash.
-func TLSServerHashSha256(val string) attribute.KeyValue {
- return TLSServerHashSha256Key.String(val)
-}
-
-// TLSServerIssuer returns an attribute KeyValue conforming to the
-// "tls.server.issuer" semantic conventions. It represents the distinguished
-// name of
-// [subject](https://datatracker.ietf.org/doc/html/rfc5280#section-4.1.2.6) of
-// the issuer of the x.509 certificate presented by the client.
-func TLSServerIssuer(val string) attribute.KeyValue {
- return TLSServerIssuerKey.String(val)
-}
-
-// TLSServerJa3s returns an attribute KeyValue conforming to the
-// "tls.server.ja3s" semantic conventions. It represents a hash that identifies
-// servers based on how they perform an SSL/TLS handshake.
-func TLSServerJa3s(val string) attribute.KeyValue {
- return TLSServerJa3sKey.String(val)
-}
-
-// TLSServerNotAfter returns an attribute KeyValue conforming to the
-// "tls.server.not_after" semantic conventions. It represents the date/Time
-// indicating when server certificate is no longer considered valid.
-func TLSServerNotAfter(val string) attribute.KeyValue {
- return TLSServerNotAfterKey.String(val)
-}
-
-// TLSServerNotBefore returns an attribute KeyValue conforming to the
-// "tls.server.not_before" semantic conventions. It represents the date/Time
-// indicating when server certificate is first considered valid.
-func TLSServerNotBefore(val string) attribute.KeyValue {
- return TLSServerNotBeforeKey.String(val)
-}
-
-// TLSServerSubject returns an attribute KeyValue conforming to the
-// "tls.server.subject" semantic conventions. It represents the distinguished
-// name of subject of the x.509 certificate presented by the server.
-func TLSServerSubject(val string) attribute.KeyValue {
- return TLSServerSubjectKey.String(val)
-}
-
-// Attributes describing URL.
-const (
- // URLDomainKey is the attribute Key conforming to the "url.domain"
- // semantic conventions. It represents the domain extracted from the
- // `url.full`, such as "opentelemetry.io".
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'www.foo.bar', 'opentelemetry.io', '3.12.167.2',
- // '[1080:0:0:0:8:800:200C:417A]'
- // Note: In some cases a URL may refer to an IP and/or port directly,
- // without a domain name. In this case, the IP address would go to the
- // domain field. If the URL contains a [literal IPv6
- // address](https://www.rfc-editor.org/rfc/rfc2732#section-2) enclosed by
- // `[` and `]`, the `[` and `]` characters should also be captured in the
- // domain field.
- URLDomainKey = attribute.Key("url.domain")
-
- // URLExtensionKey is the attribute Key conforming to the "url.extension"
- // semantic conventions. It represents the file extension extracted from
- // the `url.full`, excluding the leading dot.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'png', 'gz'
- // Note: The file extension is only set if it exists, as not every url has
- // a file extension. When the file name has multiple extensions
- // `example.tar.gz`, only the last one should be captured `gz`, not
- // `tar.gz`.
- URLExtensionKey = attribute.Key("url.extension")
-
- // URLFragmentKey is the attribute Key conforming to the "url.fragment"
- // semantic conventions. It represents the [URI
- // fragment](https://www.rfc-editor.org/rfc/rfc3986#section-3.5) component
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'SemConv'
- URLFragmentKey = attribute.Key("url.fragment")
-
- // URLFullKey is the attribute Key conforming to the "url.full" semantic
- // conventions. It represents the absolute URL describing a network
- // resource according to [RFC3986](https://www.rfc-editor.org/rfc/rfc3986)
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'https://www.foo.bar/search?q=OpenTelemetry#SemConv',
- // '//localhost'
- // Note: For network calls, URL usually has
- // `scheme://host[:port][path][?query][#fragment]` format, where the
- // fragment is not transmitted over HTTP, but if it is known, it SHOULD be
- // included nevertheless.
- // `url.full` MUST NOT contain credentials passed via URL in form of
- // `https://username:password@www.example.com/`. In such case username and
- // password SHOULD be redacted and attribute's value SHOULD be
- // `https://REDACTED:REDACTED@www.example.com/`.
- // `url.full` SHOULD capture the absolute URL when it is available (or can
- // be reconstructed). Sensitive content provided in `url.full` SHOULD be
- // scrubbed when instrumentations can identify it.
- URLFullKey = attribute.Key("url.full")
-
- // URLOriginalKey is the attribute Key conforming to the "url.original"
- // semantic conventions. It represents the unmodified original URL as seen
- // in the event source.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'https://www.foo.bar/search?q=OpenTelemetry#SemConv',
- // 'search?q=OpenTelemetry'
- // Note: In network monitoring, the observed URL may be a full URL, whereas
- // in access logs, the URL is often just represented as a path. This field
- // is meant to represent the URL as it was observed, complete or not.
- // `url.original` might contain credentials passed via URL in form of
- // `https://username:password@www.example.com/`. In such case password and
- // username SHOULD NOT be redacted and attribute's value SHOULD remain the
- // same.
- URLOriginalKey = attribute.Key("url.original")
-
- // URLPathKey is the attribute Key conforming to the "url.path" semantic
- // conventions. It represents the [URI
- // path](https://www.rfc-editor.org/rfc/rfc3986#section-3.3) component
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: '/search'
- // Note: Sensitive content provided in `url.path` SHOULD be scrubbed when
- // instrumentations can identify it.
- URLPathKey = attribute.Key("url.path")
-
- // URLPortKey is the attribute Key conforming to the "url.port" semantic
- // conventions. It represents the port extracted from the `url.full`
- //
- // Type: int
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 443
- URLPortKey = attribute.Key("url.port")
-
- // URLQueryKey is the attribute Key conforming to the "url.query" semantic
- // conventions. It represents the [URI
- // query](https://www.rfc-editor.org/rfc/rfc3986#section-3.4) component
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'q=OpenTelemetry'
- // Note: Sensitive content provided in `url.query` SHOULD be scrubbed when
- // instrumentations can identify it.
- URLQueryKey = attribute.Key("url.query")
-
- // URLRegisteredDomainKey is the attribute Key conforming to the
- // "url.registered_domain" semantic conventions. It represents the highest
- // registered url domain, stripped of the subdomain.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'example.com', 'foo.co.uk'
- // Note: This value can be determined precisely with the [public suffix
- // list](http://publicsuffix.org). For example, the registered domain for
- // `foo.example.com` is `example.com`. Trying to approximate this by simply
- // taking the last two labels will not work well for TLDs such as `co.uk`.
- URLRegisteredDomainKey = attribute.Key("url.registered_domain")
-
- // URLSchemeKey is the attribute Key conforming to the "url.scheme"
- // semantic conventions. It represents the [URI
- // scheme](https://www.rfc-editor.org/rfc/rfc3986#section-3.1) component
- // identifying the used protocol.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'https', 'ftp', 'telnet'
- URLSchemeKey = attribute.Key("url.scheme")
-
- // URLSubdomainKey is the attribute Key conforming to the "url.subdomain"
- // semantic conventions. It represents the subdomain portion of a fully
- // qualified domain name includes all of the names except the host name
- // under the registered_domain. In a partially qualified domain, or if the
- // qualification level of the full name cannot be determined, subdomain
- // contains all of the names below the registered domain.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'east', 'sub2.sub1'
- // Note: The subdomain portion of `www.east.mydomain.co.uk` is `east`. If
- // the domain has multiple levels of subdomain, such as
- // `sub2.sub1.example.com`, the subdomain field should contain `sub2.sub1`,
- // with no trailing period.
- URLSubdomainKey = attribute.Key("url.subdomain")
-
- // URLTemplateKey is the attribute Key conforming to the "url.template"
- // semantic conventions. It represents the low-cardinality template of an
- // [absolute path
- // reference](https://www.rfc-editor.org/rfc/rfc3986#section-4.2).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '/users/{id}', '/users/:id', '/users?id={id}'
- URLTemplateKey = attribute.Key("url.template")
-
- // URLTopLevelDomainKey is the attribute Key conforming to the
- // "url.top_level_domain" semantic conventions. It represents the effective
- // top level domain (eTLD), also known as the domain suffix, is the last
- // part of the domain name. For example, the top level domain for
- // example.com is `com`.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'com', 'co.uk'
- // Note: This value can be determined precisely with the [public suffix
- // list](http://publicsuffix.org).
- URLTopLevelDomainKey = attribute.Key("url.top_level_domain")
-)
-
-// URLDomain returns an attribute KeyValue conforming to the "url.domain"
-// semantic conventions. It represents the domain extracted from the
-// `url.full`, such as "opentelemetry.io".
-func URLDomain(val string) attribute.KeyValue {
- return URLDomainKey.String(val)
-}
-
-// URLExtension returns an attribute KeyValue conforming to the
-// "url.extension" semantic conventions. It represents the file extension
-// extracted from the `url.full`, excluding the leading dot.
-func URLExtension(val string) attribute.KeyValue {
- return URLExtensionKey.String(val)
-}
-
-// URLFragment returns an attribute KeyValue conforming to the
-// "url.fragment" semantic conventions. It represents the [URI
-// fragment](https://www.rfc-editor.org/rfc/rfc3986#section-3.5) component
-func URLFragment(val string) attribute.KeyValue {
- return URLFragmentKey.String(val)
-}
-
-// URLFull returns an attribute KeyValue conforming to the "url.full"
-// semantic conventions. It represents the absolute URL describing a network
-// resource according to [RFC3986](https://www.rfc-editor.org/rfc/rfc3986)
-func URLFull(val string) attribute.KeyValue {
- return URLFullKey.String(val)
-}
-
-// URLOriginal returns an attribute KeyValue conforming to the
-// "url.original" semantic conventions. It represents the unmodified original
-// URL as seen in the event source.
-func URLOriginal(val string) attribute.KeyValue {
- return URLOriginalKey.String(val)
-}
-
-// URLPath returns an attribute KeyValue conforming to the "url.path"
-// semantic conventions. It represents the [URI
-// path](https://www.rfc-editor.org/rfc/rfc3986#section-3.3) component
-func URLPath(val string) attribute.KeyValue {
- return URLPathKey.String(val)
-}
-
-// URLPort returns an attribute KeyValue conforming to the "url.port"
-// semantic conventions. It represents the port extracted from the `url.full`
-func URLPort(val int) attribute.KeyValue {
- return URLPortKey.Int(val)
-}
-
-// URLQuery returns an attribute KeyValue conforming to the "url.query"
-// semantic conventions. It represents the [URI
-// query](https://www.rfc-editor.org/rfc/rfc3986#section-3.4) component
-func URLQuery(val string) attribute.KeyValue {
- return URLQueryKey.String(val)
-}
-
-// URLRegisteredDomain returns an attribute KeyValue conforming to the
-// "url.registered_domain" semantic conventions. It represents the highest
-// registered url domain, stripped of the subdomain.
-func URLRegisteredDomain(val string) attribute.KeyValue {
- return URLRegisteredDomainKey.String(val)
-}
-
-// URLScheme returns an attribute KeyValue conforming to the "url.scheme"
-// semantic conventions. It represents the [URI
-// scheme](https://www.rfc-editor.org/rfc/rfc3986#section-3.1) component
-// identifying the used protocol.
-func URLScheme(val string) attribute.KeyValue {
- return URLSchemeKey.String(val)
-}
-
-// URLSubdomain returns an attribute KeyValue conforming to the
-// "url.subdomain" semantic conventions. It represents the subdomain portion of
-// a fully qualified domain name includes all of the names except the host name
-// under the registered_domain. In a partially qualified domain, or if the
-// qualification level of the full name cannot be determined, subdomain
-// contains all of the names below the registered domain.
-func URLSubdomain(val string) attribute.KeyValue {
- return URLSubdomainKey.String(val)
-}
-
-// URLTemplate returns an attribute KeyValue conforming to the
-// "url.template" semantic conventions. It represents the low-cardinality
-// template of an [absolute path
-// reference](https://www.rfc-editor.org/rfc/rfc3986#section-4.2).
-func URLTemplate(val string) attribute.KeyValue {
- return URLTemplateKey.String(val)
-}
-
-// URLTopLevelDomain returns an attribute KeyValue conforming to the
-// "url.top_level_domain" semantic conventions. It represents the effective top
-// level domain (eTLD), also known as the domain suffix, is the last part of
-// the domain name. For example, the top level domain for example.com is `com`.
-func URLTopLevelDomain(val string) attribute.KeyValue {
- return URLTopLevelDomainKey.String(val)
-}
-
-// Describes user-agent attributes.
-const (
- // UserAgentNameKey is the attribute Key conforming to the
- // "user_agent.name" semantic conventions. It represents the name of the
- // user-agent extracted from original. Usually refers to the browser's
- // name.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'Safari', 'YourApp'
- // Note: [Example](https://www.whatsmyua.info) of extracting browser's name
- // from original string. In the case of using a user-agent for non-browser
- // products, such as microservices with multiple names/versions inside the
- // `user_agent.original`, the most significant name SHOULD be selected. In
- // such a scenario it should align with `user_agent.version`
- UserAgentNameKey = attribute.Key("user_agent.name")
-
- // UserAgentOriginalKey is the attribute Key conforming to the
- // "user_agent.original" semantic conventions. It represents the value of
- // the [HTTP
- // User-Agent](https://www.rfc-editor.org/rfc/rfc9110.html#field.user-agent)
- // header sent by the client.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: stable
- // Examples: 'CERN-LineMode/2.15 libwww/2.17b3', 'Mozilla/5.0 (iPhone; CPU
- // iPhone OS 14_7_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko)
- // Version/14.1.2 Mobile/15E148 Safari/604.1', 'YourApp/1.0.0
- // grpc-java-okhttp/1.27.2'
- UserAgentOriginalKey = attribute.Key("user_agent.original")
-
- // UserAgentVersionKey is the attribute Key conforming to the
- // "user_agent.version" semantic conventions. It represents the version of
- // the user-agent extracted from original. Usually refers to the browser's
- // version
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '14.1.2', '1.0.0'
- // Note: [Example](https://www.whatsmyua.info) of extracting browser's
- // version from original string. In the case of using a user-agent for
- // non-browser products, such as microservices with multiple names/versions
- // inside the `user_agent.original`, the most significant version SHOULD be
- // selected. In such a scenario it should align with `user_agent.name`
- UserAgentVersionKey = attribute.Key("user_agent.version")
-)
-
-// UserAgentName returns an attribute KeyValue conforming to the
-// "user_agent.name" semantic conventions. It represents the name of the
-// user-agent extracted from original. Usually refers to the browser's name.
-func UserAgentName(val string) attribute.KeyValue {
- return UserAgentNameKey.String(val)
-}
-
-// UserAgentOriginal returns an attribute KeyValue conforming to the
-// "user_agent.original" semantic conventions. It represents the value of the
-// [HTTP
-// User-Agent](https://www.rfc-editor.org/rfc/rfc9110.html#field.user-agent)
-// header sent by the client.
-func UserAgentOriginal(val string) attribute.KeyValue {
- return UserAgentOriginalKey.String(val)
-}
-
-// UserAgentVersion returns an attribute KeyValue conforming to the
-// "user_agent.version" semantic conventions. It represents the version of the
-// user-agent extracted from original. Usually refers to the browser's version
-func UserAgentVersion(val string) attribute.KeyValue {
- return UserAgentVersionKey.String(val)
-}
-
-// The attributes used to describe the packaged software running the
-// application code.
-const (
- // WebEngineDescriptionKey is the attribute Key conforming to the
- // "webengine.description" semantic conventions. It represents the
- // additional description of the web engine (e.g. detailed version and
- // edition information).
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'WildFly Full 21.0.0.Final (WildFly Core 13.0.1.Final) -
- // 2.2.2.Final'
- WebEngineDescriptionKey = attribute.Key("webengine.description")
-
- // WebEngineNameKey is the attribute Key conforming to the "webengine.name"
- // semantic conventions. It represents the name of the web engine.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: 'WildFly'
- WebEngineNameKey = attribute.Key("webengine.name")
-
- // WebEngineVersionKey is the attribute Key conforming to the
- // "webengine.version" semantic conventions. It represents the version of
- // the web engine.
- //
- // Type: string
- // RequirementLevel: Optional
- // Stability: experimental
- // Examples: '21.0.0'
- WebEngineVersionKey = attribute.Key("webengine.version")
-)
-
-// WebEngineDescription returns an attribute KeyValue conforming to the
-// "webengine.description" semantic conventions. It represents the additional
-// description of the web engine (e.g. detailed version and edition
-// information).
-func WebEngineDescription(val string) attribute.KeyValue {
- return WebEngineDescriptionKey.String(val)
-}
-
-// WebEngineName returns an attribute KeyValue conforming to the
-// "webengine.name" semantic conventions. It represents the name of the web
-// engine.
-func WebEngineName(val string) attribute.KeyValue {
- return WebEngineNameKey.String(val)
-}
-
-// WebEngineVersion returns an attribute KeyValue conforming to the
-// "webengine.version" semantic conventions. It represents the version of the
-// web engine.
-func WebEngineVersion(val string) attribute.KeyValue {
- return WebEngineVersionKey.String(val)
-}
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.26.0/doc.go b/vendor/go.opentelemetry.io/otel/semconv/v1.26.0/doc.go
deleted file mode 100644
index d031bbea78..0000000000
--- a/vendor/go.opentelemetry.io/otel/semconv/v1.26.0/doc.go
+++ /dev/null
@@ -1,9 +0,0 @@
-// Copyright The OpenTelemetry Authors
-// SPDX-License-Identifier: Apache-2.0
-
-// Package semconv implements OpenTelemetry semantic conventions.
-//
-// OpenTelemetry semantic conventions are agreed standardized naming
-// patterns for OpenTelemetry things. This package represents the v1.26.0
-// version of the OpenTelemetry semantic conventions.
-package semconv // import "go.opentelemetry.io/otel/semconv/v1.26.0"
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.26.0/exception.go b/vendor/go.opentelemetry.io/otel/semconv/v1.26.0/exception.go
deleted file mode 100644
index bfaee0d56e..0000000000
--- a/vendor/go.opentelemetry.io/otel/semconv/v1.26.0/exception.go
+++ /dev/null
@@ -1,9 +0,0 @@
-// Copyright The OpenTelemetry Authors
-// SPDX-License-Identifier: Apache-2.0
-
-package semconv // import "go.opentelemetry.io/otel/semconv/v1.26.0"
-
-const (
- // ExceptionEventName is the name of the Span event representing an exception.
- ExceptionEventName = "exception"
-)
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.26.0/metric.go b/vendor/go.opentelemetry.io/otel/semconv/v1.26.0/metric.go
deleted file mode 100644
index fcdb9f4859..0000000000
--- a/vendor/go.opentelemetry.io/otel/semconv/v1.26.0/metric.go
+++ /dev/null
@@ -1,1307 +0,0 @@
-// Copyright The OpenTelemetry Authors
-// SPDX-License-Identifier: Apache-2.0
-
-// Code generated from semantic convention specification. DO NOT EDIT.
-
-package semconv // import "go.opentelemetry.io/otel/semconv/v1.26.0"
-
-const (
-
- // ContainerCPUTime is the metric conforming to the "container.cpu.time"
- // semantic conventions. It represents the total CPU time consumed.
- // Instrument: counter
- // Unit: s
- // Stability: Experimental
- ContainerCPUTimeName = "container.cpu.time"
- ContainerCPUTimeUnit = "s"
- ContainerCPUTimeDescription = "Total CPU time consumed"
-
- // ContainerMemoryUsage is the metric conforming to the
- // "container.memory.usage" semantic conventions. It represents the memory
- // usage of the container.
- // Instrument: counter
- // Unit: By
- // Stability: Experimental
- ContainerMemoryUsageName = "container.memory.usage"
- ContainerMemoryUsageUnit = "By"
- ContainerMemoryUsageDescription = "Memory usage of the container."
-
- // ContainerDiskIo is the metric conforming to the "container.disk.io" semantic
- // conventions. It represents the disk bytes for the container.
- // Instrument: counter
- // Unit: By
- // Stability: Experimental
- ContainerDiskIoName = "container.disk.io"
- ContainerDiskIoUnit = "By"
- ContainerDiskIoDescription = "Disk bytes for the container."
-
- // ContainerNetworkIo is the metric conforming to the "container.network.io"
- // semantic conventions. It represents the network bytes for the container.
- // Instrument: counter
- // Unit: By
- // Stability: Experimental
- ContainerNetworkIoName = "container.network.io"
- ContainerNetworkIoUnit = "By"
- ContainerNetworkIoDescription = "Network bytes for the container."
-
- // DBClientOperationDuration is the metric conforming to the
- // "db.client.operation.duration" semantic conventions. It represents the
- // duration of database client operations.
- // Instrument: histogram
- // Unit: s
- // Stability: Experimental
- DBClientOperationDurationName = "db.client.operation.duration"
- DBClientOperationDurationUnit = "s"
- DBClientOperationDurationDescription = "Duration of database client operations."
-
- // DBClientConnectionCount is the metric conforming to the
- // "db.client.connection.count" semantic conventions. It represents the number
- // of connections that are currently in state described by the `state`
- // attribute.
- // Instrument: updowncounter
- // Unit: {connection}
- // Stability: Experimental
- DBClientConnectionCountName = "db.client.connection.count"
- DBClientConnectionCountUnit = "{connection}"
- DBClientConnectionCountDescription = "The number of connections that are currently in state described by the `state` attribute"
-
- // DBClientConnectionIdleMax is the metric conforming to the
- // "db.client.connection.idle.max" semantic conventions. It represents the
- // maximum number of idle open connections allowed.
- // Instrument: updowncounter
- // Unit: {connection}
- // Stability: Experimental
- DBClientConnectionIdleMaxName = "db.client.connection.idle.max"
- DBClientConnectionIdleMaxUnit = "{connection}"
- DBClientConnectionIdleMaxDescription = "The maximum number of idle open connections allowed"
-
- // DBClientConnectionIdleMin is the metric conforming to the
- // "db.client.connection.idle.min" semantic conventions. It represents the
- // minimum number of idle open connections allowed.
- // Instrument: updowncounter
- // Unit: {connection}
- // Stability: Experimental
- DBClientConnectionIdleMinName = "db.client.connection.idle.min"
- DBClientConnectionIdleMinUnit = "{connection}"
- DBClientConnectionIdleMinDescription = "The minimum number of idle open connections allowed"
-
- // DBClientConnectionMax is the metric conforming to the
- // "db.client.connection.max" semantic conventions. It represents the maximum
- // number of open connections allowed.
- // Instrument: updowncounter
- // Unit: {connection}
- // Stability: Experimental
- DBClientConnectionMaxName = "db.client.connection.max"
- DBClientConnectionMaxUnit = "{connection}"
- DBClientConnectionMaxDescription = "The maximum number of open connections allowed"
-
- // DBClientConnectionPendingRequests is the metric conforming to the
- // "db.client.connection.pending_requests" semantic conventions. It represents
- // the number of pending requests for an open connection, cumulative for the
- // entire pool.
- // Instrument: updowncounter
- // Unit: {request}
- // Stability: Experimental
- DBClientConnectionPendingRequestsName = "db.client.connection.pending_requests"
- DBClientConnectionPendingRequestsUnit = "{request}"
- DBClientConnectionPendingRequestsDescription = "The number of pending requests for an open connection, cumulative for the entire pool"
-
- // DBClientConnectionTimeouts is the metric conforming to the
- // "db.client.connection.timeouts" semantic conventions. It represents the
- // number of connection timeouts that have occurred trying to obtain a
- // connection from the pool.
- // Instrument: counter
- // Unit: {timeout}
- // Stability: Experimental
- DBClientConnectionTimeoutsName = "db.client.connection.timeouts"
- DBClientConnectionTimeoutsUnit = "{timeout}"
- DBClientConnectionTimeoutsDescription = "The number of connection timeouts that have occurred trying to obtain a connection from the pool"
-
- // DBClientConnectionCreateTime is the metric conforming to the
- // "db.client.connection.create_time" semantic conventions. It represents the
- // time it took to create a new connection.
- // Instrument: histogram
- // Unit: s
- // Stability: Experimental
- DBClientConnectionCreateTimeName = "db.client.connection.create_time"
- DBClientConnectionCreateTimeUnit = "s"
- DBClientConnectionCreateTimeDescription = "The time it took to create a new connection"
-
- // DBClientConnectionWaitTime is the metric conforming to the
- // "db.client.connection.wait_time" semantic conventions. It represents the
- // time it took to obtain an open connection from the pool.
- // Instrument: histogram
- // Unit: s
- // Stability: Experimental
- DBClientConnectionWaitTimeName = "db.client.connection.wait_time"
- DBClientConnectionWaitTimeUnit = "s"
- DBClientConnectionWaitTimeDescription = "The time it took to obtain an open connection from the pool"
-
- // DBClientConnectionUseTime is the metric conforming to the
- // "db.client.connection.use_time" semantic conventions. It represents the time
- // between borrowing a connection and returning it to the pool.
- // Instrument: histogram
- // Unit: s
- // Stability: Experimental
- DBClientConnectionUseTimeName = "db.client.connection.use_time"
- DBClientConnectionUseTimeUnit = "s"
- DBClientConnectionUseTimeDescription = "The time between borrowing a connection and returning it to the pool"
-
- // DBClientConnectionsUsage is the metric conforming to the
- // "db.client.connections.usage" semantic conventions. It represents the
- // deprecated, use `db.client.connection.count` instead.
- // Instrument: updowncounter
- // Unit: {connection}
- // Stability: Experimental
- DBClientConnectionsUsageName = "db.client.connections.usage"
- DBClientConnectionsUsageUnit = "{connection}"
- DBClientConnectionsUsageDescription = "Deprecated, use `db.client.connection.count` instead."
-
- // DBClientConnectionsIdleMax is the metric conforming to the
- // "db.client.connections.idle.max" semantic conventions. It represents the
- // deprecated, use `db.client.connection.idle.max` instead.
- // Instrument: updowncounter
- // Unit: {connection}
- // Stability: Experimental
- DBClientConnectionsIdleMaxName = "db.client.connections.idle.max"
- DBClientConnectionsIdleMaxUnit = "{connection}"
- DBClientConnectionsIdleMaxDescription = "Deprecated, use `db.client.connection.idle.max` instead."
-
- // DBClientConnectionsIdleMin is the metric conforming to the
- // "db.client.connections.idle.min" semantic conventions. It represents the
- // deprecated, use `db.client.connection.idle.min` instead.
- // Instrument: updowncounter
- // Unit: {connection}
- // Stability: Experimental
- DBClientConnectionsIdleMinName = "db.client.connections.idle.min"
- DBClientConnectionsIdleMinUnit = "{connection}"
- DBClientConnectionsIdleMinDescription = "Deprecated, use `db.client.connection.idle.min` instead."
-
- // DBClientConnectionsMax is the metric conforming to the
- // "db.client.connections.max" semantic conventions. It represents the
- // deprecated, use `db.client.connection.max` instead.
- // Instrument: updowncounter
- // Unit: {connection}
- // Stability: Experimental
- DBClientConnectionsMaxName = "db.client.connections.max"
- DBClientConnectionsMaxUnit = "{connection}"
- DBClientConnectionsMaxDescription = "Deprecated, use `db.client.connection.max` instead."
-
- // DBClientConnectionsPendingRequests is the metric conforming to the
- // "db.client.connections.pending_requests" semantic conventions. It represents
- // the deprecated, use `db.client.connection.pending_requests` instead.
- // Instrument: updowncounter
- // Unit: {request}
- // Stability: Experimental
- DBClientConnectionsPendingRequestsName = "db.client.connections.pending_requests"
- DBClientConnectionsPendingRequestsUnit = "{request}"
- DBClientConnectionsPendingRequestsDescription = "Deprecated, use `db.client.connection.pending_requests` instead."
-
- // DBClientConnectionsTimeouts is the metric conforming to the
- // "db.client.connections.timeouts" semantic conventions. It represents the
- // deprecated, use `db.client.connection.timeouts` instead.
- // Instrument: counter
- // Unit: {timeout}
- // Stability: Experimental
- DBClientConnectionsTimeoutsName = "db.client.connections.timeouts"
- DBClientConnectionsTimeoutsUnit = "{timeout}"
- DBClientConnectionsTimeoutsDescription = "Deprecated, use `db.client.connection.timeouts` instead."
-
- // DBClientConnectionsCreateTime is the metric conforming to the
- // "db.client.connections.create_time" semantic conventions. It represents the
- // deprecated, use `db.client.connection.create_time` instead. Note: the unit
- // also changed from `ms` to `s`.
- // Instrument: histogram
- // Unit: ms
- // Stability: Experimental
- DBClientConnectionsCreateTimeName = "db.client.connections.create_time"
- DBClientConnectionsCreateTimeUnit = "ms"
- DBClientConnectionsCreateTimeDescription = "Deprecated, use `db.client.connection.create_time` instead. Note: the unit also changed from `ms` to `s`."
-
- // DBClientConnectionsWaitTime is the metric conforming to the
- // "db.client.connections.wait_time" semantic conventions. It represents the
- // deprecated, use `db.client.connection.wait_time` instead. Note: the unit
- // also changed from `ms` to `s`.
- // Instrument: histogram
- // Unit: ms
- // Stability: Experimental
- DBClientConnectionsWaitTimeName = "db.client.connections.wait_time"
- DBClientConnectionsWaitTimeUnit = "ms"
- DBClientConnectionsWaitTimeDescription = "Deprecated, use `db.client.connection.wait_time` instead. Note: the unit also changed from `ms` to `s`."
-
- // DBClientConnectionsUseTime is the metric conforming to the
- // "db.client.connections.use_time" semantic conventions. It represents the
- // deprecated, use `db.client.connection.use_time` instead. Note: the unit also
- // changed from `ms` to `s`.
- // Instrument: histogram
- // Unit: ms
- // Stability: Experimental
- DBClientConnectionsUseTimeName = "db.client.connections.use_time"
- DBClientConnectionsUseTimeUnit = "ms"
- DBClientConnectionsUseTimeDescription = "Deprecated, use `db.client.connection.use_time` instead. Note: the unit also changed from `ms` to `s`."
-
- // DNSLookupDuration is the metric conforming to the "dns.lookup.duration"
- // semantic conventions. It represents the measures the time taken to perform a
- // DNS lookup.
- // Instrument: histogram
- // Unit: s
- // Stability: Experimental
- DNSLookupDurationName = "dns.lookup.duration"
- DNSLookupDurationUnit = "s"
- DNSLookupDurationDescription = "Measures the time taken to perform a DNS lookup."
-
- // AspnetcoreRoutingMatchAttempts is the metric conforming to the
- // "aspnetcore.routing.match_attempts" semantic conventions. It represents the
- // number of requests that were attempted to be matched to an endpoint.
- // Instrument: counter
- // Unit: {match_attempt}
- // Stability: Stable
- AspnetcoreRoutingMatchAttemptsName = "aspnetcore.routing.match_attempts"
- AspnetcoreRoutingMatchAttemptsUnit = "{match_attempt}"
- AspnetcoreRoutingMatchAttemptsDescription = "Number of requests that were attempted to be matched to an endpoint."
-
- // AspnetcoreDiagnosticsExceptions is the metric conforming to the
- // "aspnetcore.diagnostics.exceptions" semantic conventions. It represents the
- // number of exceptions caught by exception handling middleware.
- // Instrument: counter
- // Unit: {exception}
- // Stability: Stable
- AspnetcoreDiagnosticsExceptionsName = "aspnetcore.diagnostics.exceptions"
- AspnetcoreDiagnosticsExceptionsUnit = "{exception}"
- AspnetcoreDiagnosticsExceptionsDescription = "Number of exceptions caught by exception handling middleware."
-
- // AspnetcoreRateLimitingActiveRequestLeases is the metric conforming to the
- // "aspnetcore.rate_limiting.active_request_leases" semantic conventions. It
- // represents the number of requests that are currently active on the server
- // that hold a rate limiting lease.
- // Instrument: updowncounter
- // Unit: {request}
- // Stability: Stable
- AspnetcoreRateLimitingActiveRequestLeasesName = "aspnetcore.rate_limiting.active_request_leases"
- AspnetcoreRateLimitingActiveRequestLeasesUnit = "{request}"
- AspnetcoreRateLimitingActiveRequestLeasesDescription = "Number of requests that are currently active on the server that hold a rate limiting lease."
-
- // AspnetcoreRateLimitingRequestLeaseDuration is the metric conforming to the
- // "aspnetcore.rate_limiting.request_lease.duration" semantic conventions. It
- // represents the duration of rate limiting lease held by requests on the
- // server.
- // Instrument: histogram
- // Unit: s
- // Stability: Stable
- AspnetcoreRateLimitingRequestLeaseDurationName = "aspnetcore.rate_limiting.request_lease.duration"
- AspnetcoreRateLimitingRequestLeaseDurationUnit = "s"
- AspnetcoreRateLimitingRequestLeaseDurationDescription = "The duration of rate limiting lease held by requests on the server."
-
- // AspnetcoreRateLimitingRequestTimeInQueue is the metric conforming to the
- // "aspnetcore.rate_limiting.request.time_in_queue" semantic conventions. It
- // represents the time the request spent in a queue waiting to acquire a rate
- // limiting lease.
- // Instrument: histogram
- // Unit: s
- // Stability: Stable
- AspnetcoreRateLimitingRequestTimeInQueueName = "aspnetcore.rate_limiting.request.time_in_queue"
- AspnetcoreRateLimitingRequestTimeInQueueUnit = "s"
- AspnetcoreRateLimitingRequestTimeInQueueDescription = "The time the request spent in a queue waiting to acquire a rate limiting lease."
-
- // AspnetcoreRateLimitingQueuedRequests is the metric conforming to the
- // "aspnetcore.rate_limiting.queued_requests" semantic conventions. It
- // represents the number of requests that are currently queued, waiting to
- // acquire a rate limiting lease.
- // Instrument: updowncounter
- // Unit: {request}
- // Stability: Stable
- AspnetcoreRateLimitingQueuedRequestsName = "aspnetcore.rate_limiting.queued_requests"
- AspnetcoreRateLimitingQueuedRequestsUnit = "{request}"
- AspnetcoreRateLimitingQueuedRequestsDescription = "Number of requests that are currently queued, waiting to acquire a rate limiting lease."
-
- // AspnetcoreRateLimitingRequests is the metric conforming to the
- // "aspnetcore.rate_limiting.requests" semantic conventions. It represents the
- // number of requests that tried to acquire a rate limiting lease.
- // Instrument: counter
- // Unit: {request}
- // Stability: Stable
- AspnetcoreRateLimitingRequestsName = "aspnetcore.rate_limiting.requests"
- AspnetcoreRateLimitingRequestsUnit = "{request}"
- AspnetcoreRateLimitingRequestsDescription = "Number of requests that tried to acquire a rate limiting lease."
-
- // KestrelActiveConnections is the metric conforming to the
- // "kestrel.active_connections" semantic conventions. It represents the number
- // of connections that are currently active on the server.
- // Instrument: updowncounter
- // Unit: {connection}
- // Stability: Stable
- KestrelActiveConnectionsName = "kestrel.active_connections"
- KestrelActiveConnectionsUnit = "{connection}"
- KestrelActiveConnectionsDescription = "Number of connections that are currently active on the server."
-
- // KestrelConnectionDuration is the metric conforming to the
- // "kestrel.connection.duration" semantic conventions. It represents the
- // duration of connections on the server.
- // Instrument: histogram
- // Unit: s
- // Stability: Stable
- KestrelConnectionDurationName = "kestrel.connection.duration"
- KestrelConnectionDurationUnit = "s"
- KestrelConnectionDurationDescription = "The duration of connections on the server."
-
- // KestrelRejectedConnections is the metric conforming to the
- // "kestrel.rejected_connections" semantic conventions. It represents the
- // number of connections rejected by the server.
- // Instrument: counter
- // Unit: {connection}
- // Stability: Stable
- KestrelRejectedConnectionsName = "kestrel.rejected_connections"
- KestrelRejectedConnectionsUnit = "{connection}"
- KestrelRejectedConnectionsDescription = "Number of connections rejected by the server."
-
- // KestrelQueuedConnections is the metric conforming to the
- // "kestrel.queued_connections" semantic conventions. It represents the number
- // of connections that are currently queued and are waiting to start.
- // Instrument: updowncounter
- // Unit: {connection}
- // Stability: Stable
- KestrelQueuedConnectionsName = "kestrel.queued_connections"
- KestrelQueuedConnectionsUnit = "{connection}"
- KestrelQueuedConnectionsDescription = "Number of connections that are currently queued and are waiting to start."
-
- // KestrelQueuedRequests is the metric conforming to the
- // "kestrel.queued_requests" semantic conventions. It represents the number of
- // HTTP requests on multiplexed connections (HTTP/2 and HTTP/3) that are
- // currently queued and are waiting to start.
- // Instrument: updowncounter
- // Unit: {request}
- // Stability: Stable
- KestrelQueuedRequestsName = "kestrel.queued_requests"
- KestrelQueuedRequestsUnit = "{request}"
- KestrelQueuedRequestsDescription = "Number of HTTP requests on multiplexed connections (HTTP/2 and HTTP/3) that are currently queued and are waiting to start."
-
- // KestrelUpgradedConnections is the metric conforming to the
- // "kestrel.upgraded_connections" semantic conventions. It represents the
- // number of connections that are currently upgraded (WebSockets). .
- // Instrument: updowncounter
- // Unit: {connection}
- // Stability: Stable
- KestrelUpgradedConnectionsName = "kestrel.upgraded_connections"
- KestrelUpgradedConnectionsUnit = "{connection}"
- KestrelUpgradedConnectionsDescription = "Number of connections that are currently upgraded (WebSockets). ."
-
- // KestrelTLSHandshakeDuration is the metric conforming to the
- // "kestrel.tls_handshake.duration" semantic conventions. It represents the
- // duration of TLS handshakes on the server.
- // Instrument: histogram
- // Unit: s
- // Stability: Stable
- KestrelTLSHandshakeDurationName = "kestrel.tls_handshake.duration"
- KestrelTLSHandshakeDurationUnit = "s"
- KestrelTLSHandshakeDurationDescription = "The duration of TLS handshakes on the server."
-
- // KestrelActiveTLSHandshakes is the metric conforming to the
- // "kestrel.active_tls_handshakes" semantic conventions. It represents the
- // number of TLS handshakes that are currently in progress on the server.
- // Instrument: updowncounter
- // Unit: {handshake}
- // Stability: Stable
- KestrelActiveTLSHandshakesName = "kestrel.active_tls_handshakes"
- KestrelActiveTLSHandshakesUnit = "{handshake}"
- KestrelActiveTLSHandshakesDescription = "Number of TLS handshakes that are currently in progress on the server."
-
- // SignalrServerConnectionDuration is the metric conforming to the
- // "signalr.server.connection.duration" semantic conventions. It represents the
- // duration of connections on the server.
- // Instrument: histogram
- // Unit: s
- // Stability: Stable
- SignalrServerConnectionDurationName = "signalr.server.connection.duration"
- SignalrServerConnectionDurationUnit = "s"
- SignalrServerConnectionDurationDescription = "The duration of connections on the server."
-
- // SignalrServerActiveConnections is the metric conforming to the
- // "signalr.server.active_connections" semantic conventions. It represents the
- // number of connections that are currently active on the server.
- // Instrument: updowncounter
- // Unit: {connection}
- // Stability: Stable
- SignalrServerActiveConnectionsName = "signalr.server.active_connections"
- SignalrServerActiveConnectionsUnit = "{connection}"
- SignalrServerActiveConnectionsDescription = "Number of connections that are currently active on the server."
-
- // FaaSInvokeDuration is the metric conforming to the "faas.invoke_duration"
- // semantic conventions. It represents the measures the duration of the
- // function's logic execution.
- // Instrument: histogram
- // Unit: s
- // Stability: Experimental
- FaaSInvokeDurationName = "faas.invoke_duration"
- FaaSInvokeDurationUnit = "s"
- FaaSInvokeDurationDescription = "Measures the duration of the function's logic execution"
-
- // FaaSInitDuration is the metric conforming to the "faas.init_duration"
- // semantic conventions. It represents the measures the duration of the
- // function's initialization, such as a cold start.
- // Instrument: histogram
- // Unit: s
- // Stability: Experimental
- FaaSInitDurationName = "faas.init_duration"
- FaaSInitDurationUnit = "s"
- FaaSInitDurationDescription = "Measures the duration of the function's initialization, such as a cold start"
-
- // FaaSColdstarts is the metric conforming to the "faas.coldstarts" semantic
- // conventions. It represents the number of invocation cold starts.
- // Instrument: counter
- // Unit: {coldstart}
- // Stability: Experimental
- FaaSColdstartsName = "faas.coldstarts"
- FaaSColdstartsUnit = "{coldstart}"
- FaaSColdstartsDescription = "Number of invocation cold starts"
-
- // FaaSErrors is the metric conforming to the "faas.errors" semantic
- // conventions. It represents the number of invocation errors.
- // Instrument: counter
- // Unit: {error}
- // Stability: Experimental
- FaaSErrorsName = "faas.errors"
- FaaSErrorsUnit = "{error}"
- FaaSErrorsDescription = "Number of invocation errors"
-
- // FaaSInvocations is the metric conforming to the "faas.invocations" semantic
- // conventions. It represents the number of successful invocations.
- // Instrument: counter
- // Unit: {invocation}
- // Stability: Experimental
- FaaSInvocationsName = "faas.invocations"
- FaaSInvocationsUnit = "{invocation}"
- FaaSInvocationsDescription = "Number of successful invocations"
-
- // FaaSTimeouts is the metric conforming to the "faas.timeouts" semantic
- // conventions. It represents the number of invocation timeouts.
- // Instrument: counter
- // Unit: {timeout}
- // Stability: Experimental
- FaaSTimeoutsName = "faas.timeouts"
- FaaSTimeoutsUnit = "{timeout}"
- FaaSTimeoutsDescription = "Number of invocation timeouts"
-
- // FaaSMemUsage is the metric conforming to the "faas.mem_usage" semantic
- // conventions. It represents the distribution of max memory usage per
- // invocation.
- // Instrument: histogram
- // Unit: By
- // Stability: Experimental
- FaaSMemUsageName = "faas.mem_usage"
- FaaSMemUsageUnit = "By"
- FaaSMemUsageDescription = "Distribution of max memory usage per invocation"
-
- // FaaSCPUUsage is the metric conforming to the "faas.cpu_usage" semantic
- // conventions. It represents the distribution of CPU usage per invocation.
- // Instrument: histogram
- // Unit: s
- // Stability: Experimental
- FaaSCPUUsageName = "faas.cpu_usage"
- FaaSCPUUsageUnit = "s"
- FaaSCPUUsageDescription = "Distribution of CPU usage per invocation"
-
- // FaaSNetIo is the metric conforming to the "faas.net_io" semantic
- // conventions. It represents the distribution of net I/O usage per invocation.
- // Instrument: histogram
- // Unit: By
- // Stability: Experimental
- FaaSNetIoName = "faas.net_io"
- FaaSNetIoUnit = "By"
- FaaSNetIoDescription = "Distribution of net I/O usage per invocation"
-
- // HTTPServerRequestDuration is the metric conforming to the
- // "http.server.request.duration" semantic conventions. It represents the
- // duration of HTTP server requests.
- // Instrument: histogram
- // Unit: s
- // Stability: Stable
- HTTPServerRequestDurationName = "http.server.request.duration"
- HTTPServerRequestDurationUnit = "s"
- HTTPServerRequestDurationDescription = "Duration of HTTP server requests."
-
- // HTTPServerActiveRequests is the metric conforming to the
- // "http.server.active_requests" semantic conventions. It represents the number
- // of active HTTP server requests.
- // Instrument: updowncounter
- // Unit: {request}
- // Stability: Experimental
- HTTPServerActiveRequestsName = "http.server.active_requests"
- HTTPServerActiveRequestsUnit = "{request}"
- HTTPServerActiveRequestsDescription = "Number of active HTTP server requests."
-
- // HTTPServerRequestBodySize is the metric conforming to the
- // "http.server.request.body.size" semantic conventions. It represents the size
- // of HTTP server request bodies.
- // Instrument: histogram
- // Unit: By
- // Stability: Experimental
- HTTPServerRequestBodySizeName = "http.server.request.body.size"
- HTTPServerRequestBodySizeUnit = "By"
- HTTPServerRequestBodySizeDescription = "Size of HTTP server request bodies."
-
- // HTTPServerResponseBodySize is the metric conforming to the
- // "http.server.response.body.size" semantic conventions. It represents the
- // size of HTTP server response bodies.
- // Instrument: histogram
- // Unit: By
- // Stability: Experimental
- HTTPServerResponseBodySizeName = "http.server.response.body.size"
- HTTPServerResponseBodySizeUnit = "By"
- HTTPServerResponseBodySizeDescription = "Size of HTTP server response bodies."
-
- // HTTPClientRequestDuration is the metric conforming to the
- // "http.client.request.duration" semantic conventions. It represents the
- // duration of HTTP client requests.
- // Instrument: histogram
- // Unit: s
- // Stability: Stable
- HTTPClientRequestDurationName = "http.client.request.duration"
- HTTPClientRequestDurationUnit = "s"
- HTTPClientRequestDurationDescription = "Duration of HTTP client requests."
-
- // HTTPClientRequestBodySize is the metric conforming to the
- // "http.client.request.body.size" semantic conventions. It represents the size
- // of HTTP client request bodies.
- // Instrument: histogram
- // Unit: By
- // Stability: Experimental
- HTTPClientRequestBodySizeName = "http.client.request.body.size"
- HTTPClientRequestBodySizeUnit = "By"
- HTTPClientRequestBodySizeDescription = "Size of HTTP client request bodies."
-
- // HTTPClientResponseBodySize is the metric conforming to the
- // "http.client.response.body.size" semantic conventions. It represents the
- // size of HTTP client response bodies.
- // Instrument: histogram
- // Unit: By
- // Stability: Experimental
- HTTPClientResponseBodySizeName = "http.client.response.body.size"
- HTTPClientResponseBodySizeUnit = "By"
- HTTPClientResponseBodySizeDescription = "Size of HTTP client response bodies."
-
- // HTTPClientOpenConnections is the metric conforming to the
- // "http.client.open_connections" semantic conventions. It represents the
- // number of outbound HTTP connections that are currently active or idle on the
- // client.
- // Instrument: updowncounter
- // Unit: {connection}
- // Stability: Experimental
- HTTPClientOpenConnectionsName = "http.client.open_connections"
- HTTPClientOpenConnectionsUnit = "{connection}"
- HTTPClientOpenConnectionsDescription = "Number of outbound HTTP connections that are currently active or idle on the client."
-
- // HTTPClientConnectionDuration is the metric conforming to the
- // "http.client.connection.duration" semantic conventions. It represents the
- // duration of the successfully established outbound HTTP connections.
- // Instrument: histogram
- // Unit: s
- // Stability: Experimental
- HTTPClientConnectionDurationName = "http.client.connection.duration"
- HTTPClientConnectionDurationUnit = "s"
- HTTPClientConnectionDurationDescription = "The duration of the successfully established outbound HTTP connections."
-
- // HTTPClientActiveRequests is the metric conforming to the
- // "http.client.active_requests" semantic conventions. It represents the number
- // of active HTTP requests.
- // Instrument: updowncounter
- // Unit: {request}
- // Stability: Experimental
- HTTPClientActiveRequestsName = "http.client.active_requests"
- HTTPClientActiveRequestsUnit = "{request}"
- HTTPClientActiveRequestsDescription = "Number of active HTTP requests."
-
- // JvmMemoryInit is the metric conforming to the "jvm.memory.init" semantic
- // conventions. It represents the measure of initial memory requested.
- // Instrument: updowncounter
- // Unit: By
- // Stability: Experimental
- JvmMemoryInitName = "jvm.memory.init"
- JvmMemoryInitUnit = "By"
- JvmMemoryInitDescription = "Measure of initial memory requested."
-
- // JvmSystemCPUUtilization is the metric conforming to the
- // "jvm.system.cpu.utilization" semantic conventions. It represents the recent
- // CPU utilization for the whole system as reported by the JVM.
- // Instrument: gauge
- // Unit: 1
- // Stability: Experimental
- JvmSystemCPUUtilizationName = "jvm.system.cpu.utilization"
- JvmSystemCPUUtilizationUnit = "1"
- JvmSystemCPUUtilizationDescription = "Recent CPU utilization for the whole system as reported by the JVM."
-
- // JvmSystemCPULoad1m is the metric conforming to the "jvm.system.cpu.load_1m"
- // semantic conventions. It represents the average CPU load of the whole system
- // for the last minute as reported by the JVM.
- // Instrument: gauge
- // Unit: {run_queue_item}
- // Stability: Experimental
- JvmSystemCPULoad1mName = "jvm.system.cpu.load_1m"
- JvmSystemCPULoad1mUnit = "{run_queue_item}"
- JvmSystemCPULoad1mDescription = "Average CPU load of the whole system for the last minute as reported by the JVM."
-
- // JvmBufferMemoryUsage is the metric conforming to the
- // "jvm.buffer.memory.usage" semantic conventions. It represents the measure of
- // memory used by buffers.
- // Instrument: updowncounter
- // Unit: By
- // Stability: Experimental
- JvmBufferMemoryUsageName = "jvm.buffer.memory.usage"
- JvmBufferMemoryUsageUnit = "By"
- JvmBufferMemoryUsageDescription = "Measure of memory used by buffers."
-
- // JvmBufferMemoryLimit is the metric conforming to the
- // "jvm.buffer.memory.limit" semantic conventions. It represents the measure of
- // total memory capacity of buffers.
- // Instrument: updowncounter
- // Unit: By
- // Stability: Experimental
- JvmBufferMemoryLimitName = "jvm.buffer.memory.limit"
- JvmBufferMemoryLimitUnit = "By"
- JvmBufferMemoryLimitDescription = "Measure of total memory capacity of buffers."
-
- // JvmBufferCount is the metric conforming to the "jvm.buffer.count" semantic
- // conventions. It represents the number of buffers in the pool.
- // Instrument: updowncounter
- // Unit: {buffer}
- // Stability: Experimental
- JvmBufferCountName = "jvm.buffer.count"
- JvmBufferCountUnit = "{buffer}"
- JvmBufferCountDescription = "Number of buffers in the pool."
-
- // JvmMemoryUsed is the metric conforming to the "jvm.memory.used" semantic
- // conventions. It represents the measure of memory used.
- // Instrument: updowncounter
- // Unit: By
- // Stability: Stable
- JvmMemoryUsedName = "jvm.memory.used"
- JvmMemoryUsedUnit = "By"
- JvmMemoryUsedDescription = "Measure of memory used."
-
- // JvmMemoryCommitted is the metric conforming to the "jvm.memory.committed"
- // semantic conventions. It represents the measure of memory committed.
- // Instrument: updowncounter
- // Unit: By
- // Stability: Stable
- JvmMemoryCommittedName = "jvm.memory.committed"
- JvmMemoryCommittedUnit = "By"
- JvmMemoryCommittedDescription = "Measure of memory committed."
-
- // JvmMemoryLimit is the metric conforming to the "jvm.memory.limit" semantic
- // conventions. It represents the measure of max obtainable memory.
- // Instrument: updowncounter
- // Unit: By
- // Stability: Stable
- JvmMemoryLimitName = "jvm.memory.limit"
- JvmMemoryLimitUnit = "By"
- JvmMemoryLimitDescription = "Measure of max obtainable memory."
-
- // JvmMemoryUsedAfterLastGc is the metric conforming to the
- // "jvm.memory.used_after_last_gc" semantic conventions. It represents the
- // measure of memory used, as measured after the most recent garbage collection
- // event on this pool.
- // Instrument: updowncounter
- // Unit: By
- // Stability: Stable
- JvmMemoryUsedAfterLastGcName = "jvm.memory.used_after_last_gc"
- JvmMemoryUsedAfterLastGcUnit = "By"
- JvmMemoryUsedAfterLastGcDescription = "Measure of memory used, as measured after the most recent garbage collection event on this pool."
-
- // JvmGcDuration is the metric conforming to the "jvm.gc.duration" semantic
- // conventions. It represents the duration of JVM garbage collection actions.
- // Instrument: histogram
- // Unit: s
- // Stability: Stable
- JvmGcDurationName = "jvm.gc.duration"
- JvmGcDurationUnit = "s"
- JvmGcDurationDescription = "Duration of JVM garbage collection actions."
-
- // JvmThreadCount is the metric conforming to the "jvm.thread.count" semantic
- // conventions. It represents the number of executing platform threads.
- // Instrument: updowncounter
- // Unit: {thread}
- // Stability: Stable
- JvmThreadCountName = "jvm.thread.count"
- JvmThreadCountUnit = "{thread}"
- JvmThreadCountDescription = "Number of executing platform threads."
-
- // JvmClassLoaded is the metric conforming to the "jvm.class.loaded" semantic
- // conventions. It represents the number of classes loaded since JVM start.
- // Instrument: counter
- // Unit: {class}
- // Stability: Stable
- JvmClassLoadedName = "jvm.class.loaded"
- JvmClassLoadedUnit = "{class}"
- JvmClassLoadedDescription = "Number of classes loaded since JVM start."
-
- // JvmClassUnloaded is the metric conforming to the "jvm.class.unloaded"
- // semantic conventions. It represents the number of classes unloaded since JVM
- // start.
- // Instrument: counter
- // Unit: {class}
- // Stability: Stable
- JvmClassUnloadedName = "jvm.class.unloaded"
- JvmClassUnloadedUnit = "{class}"
- JvmClassUnloadedDescription = "Number of classes unloaded since JVM start."
-
- // JvmClassCount is the metric conforming to the "jvm.class.count" semantic
- // conventions. It represents the number of classes currently loaded.
- // Instrument: updowncounter
- // Unit: {class}
- // Stability: Stable
- JvmClassCountName = "jvm.class.count"
- JvmClassCountUnit = "{class}"
- JvmClassCountDescription = "Number of classes currently loaded."
-
- // JvmCPUCount is the metric conforming to the "jvm.cpu.count" semantic
- // conventions. It represents the number of processors available to the Java
- // virtual machine.
- // Instrument: updowncounter
- // Unit: {cpu}
- // Stability: Stable
- JvmCPUCountName = "jvm.cpu.count"
- JvmCPUCountUnit = "{cpu}"
- JvmCPUCountDescription = "Number of processors available to the Java virtual machine."
-
- // JvmCPUTime is the metric conforming to the "jvm.cpu.time" semantic
- // conventions. It represents the cPU time used by the process as reported by
- // the JVM.
- // Instrument: counter
- // Unit: s
- // Stability: Stable
- JvmCPUTimeName = "jvm.cpu.time"
- JvmCPUTimeUnit = "s"
- JvmCPUTimeDescription = "CPU time used by the process as reported by the JVM."
-
- // JvmCPURecentUtilization is the metric conforming to the
- // "jvm.cpu.recent_utilization" semantic conventions. It represents the recent
- // CPU utilization for the process as reported by the JVM.
- // Instrument: gauge
- // Unit: 1
- // Stability: Stable
- JvmCPURecentUtilizationName = "jvm.cpu.recent_utilization"
- JvmCPURecentUtilizationUnit = "1"
- JvmCPURecentUtilizationDescription = "Recent CPU utilization for the process as reported by the JVM."
-
- // MessagingPublishDuration is the metric conforming to the
- // "messaging.publish.duration" semantic conventions. It represents the
- // measures the duration of publish operation.
- // Instrument: histogram
- // Unit: s
- // Stability: Experimental
- MessagingPublishDurationName = "messaging.publish.duration"
- MessagingPublishDurationUnit = "s"
- MessagingPublishDurationDescription = "Measures the duration of publish operation."
-
- // MessagingReceiveDuration is the metric conforming to the
- // "messaging.receive.duration" semantic conventions. It represents the
- // measures the duration of receive operation.
- // Instrument: histogram
- // Unit: s
- // Stability: Experimental
- MessagingReceiveDurationName = "messaging.receive.duration"
- MessagingReceiveDurationUnit = "s"
- MessagingReceiveDurationDescription = "Measures the duration of receive operation."
-
- // MessagingProcessDuration is the metric conforming to the
- // "messaging.process.duration" semantic conventions. It represents the
- // measures the duration of process operation.
- // Instrument: histogram
- // Unit: s
- // Stability: Experimental
- MessagingProcessDurationName = "messaging.process.duration"
- MessagingProcessDurationUnit = "s"
- MessagingProcessDurationDescription = "Measures the duration of process operation."
-
- // MessagingPublishMessages is the metric conforming to the
- // "messaging.publish.messages" semantic conventions. It represents the
- // measures the number of published messages.
- // Instrument: counter
- // Unit: {message}
- // Stability: Experimental
- MessagingPublishMessagesName = "messaging.publish.messages"
- MessagingPublishMessagesUnit = "{message}"
- MessagingPublishMessagesDescription = "Measures the number of published messages."
-
- // MessagingReceiveMessages is the metric conforming to the
- // "messaging.receive.messages" semantic conventions. It represents the
- // measures the number of received messages.
- // Instrument: counter
- // Unit: {message}
- // Stability: Experimental
- MessagingReceiveMessagesName = "messaging.receive.messages"
- MessagingReceiveMessagesUnit = "{message}"
- MessagingReceiveMessagesDescription = "Measures the number of received messages."
-
- // MessagingProcessMessages is the metric conforming to the
- // "messaging.process.messages" semantic conventions. It represents the
- // measures the number of processed messages.
- // Instrument: counter
- // Unit: {message}
- // Stability: Experimental
- MessagingProcessMessagesName = "messaging.process.messages"
- MessagingProcessMessagesUnit = "{message}"
- MessagingProcessMessagesDescription = "Measures the number of processed messages."
-
- // ProcessCPUTime is the metric conforming to the "process.cpu.time" semantic
- // conventions. It represents the total CPU seconds broken down by different
- // states.
- // Instrument: counter
- // Unit: s
- // Stability: Experimental
- ProcessCPUTimeName = "process.cpu.time"
- ProcessCPUTimeUnit = "s"
- ProcessCPUTimeDescription = "Total CPU seconds broken down by different states."
-
- // ProcessCPUUtilization is the metric conforming to the
- // "process.cpu.utilization" semantic conventions. It represents the difference
- // in process.cpu.time since the last measurement, divided by the elapsed time
- // and number of CPUs available to the process.
- // Instrument: gauge
- // Unit: 1
- // Stability: Experimental
- ProcessCPUUtilizationName = "process.cpu.utilization"
- ProcessCPUUtilizationUnit = "1"
- ProcessCPUUtilizationDescription = "Difference in process.cpu.time since the last measurement, divided by the elapsed time and number of CPUs available to the process."
-
- // ProcessMemoryUsage is the metric conforming to the "process.memory.usage"
- // semantic conventions. It represents the amount of physical memory in use.
- // Instrument: updowncounter
- // Unit: By
- // Stability: Experimental
- ProcessMemoryUsageName = "process.memory.usage"
- ProcessMemoryUsageUnit = "By"
- ProcessMemoryUsageDescription = "The amount of physical memory in use."
-
- // ProcessMemoryVirtual is the metric conforming to the
- // "process.memory.virtual" semantic conventions. It represents the amount of
- // committed virtual memory.
- // Instrument: updowncounter
- // Unit: By
- // Stability: Experimental
- ProcessMemoryVirtualName = "process.memory.virtual"
- ProcessMemoryVirtualUnit = "By"
- ProcessMemoryVirtualDescription = "The amount of committed virtual memory."
-
- // ProcessDiskIo is the metric conforming to the "process.disk.io" semantic
- // conventions. It represents the disk bytes transferred.
- // Instrument: counter
- // Unit: By
- // Stability: Experimental
- ProcessDiskIoName = "process.disk.io"
- ProcessDiskIoUnit = "By"
- ProcessDiskIoDescription = "Disk bytes transferred."
-
- // ProcessNetworkIo is the metric conforming to the "process.network.io"
- // semantic conventions. It represents the network bytes transferred.
- // Instrument: counter
- // Unit: By
- // Stability: Experimental
- ProcessNetworkIoName = "process.network.io"
- ProcessNetworkIoUnit = "By"
- ProcessNetworkIoDescription = "Network bytes transferred."
-
- // ProcessThreadCount is the metric conforming to the "process.thread.count"
- // semantic conventions. It represents the process threads count.
- // Instrument: updowncounter
- // Unit: {thread}
- // Stability: Experimental
- ProcessThreadCountName = "process.thread.count"
- ProcessThreadCountUnit = "{thread}"
- ProcessThreadCountDescription = "Process threads count."
-
- // ProcessOpenFileDescriptorCount is the metric conforming to the
- // "process.open_file_descriptor.count" semantic conventions. It represents the
- // number of file descriptors in use by the process.
- // Instrument: updowncounter
- // Unit: {count}
- // Stability: Experimental
- ProcessOpenFileDescriptorCountName = "process.open_file_descriptor.count"
- ProcessOpenFileDescriptorCountUnit = "{count}"
- ProcessOpenFileDescriptorCountDescription = "Number of file descriptors in use by the process."
-
- // ProcessContextSwitches is the metric conforming to the
- // "process.context_switches" semantic conventions. It represents the number of
- // times the process has been context switched.
- // Instrument: counter
- // Unit: {count}
- // Stability: Experimental
- ProcessContextSwitchesName = "process.context_switches"
- ProcessContextSwitchesUnit = "{count}"
- ProcessContextSwitchesDescription = "Number of times the process has been context switched."
-
- // ProcessPagingFaults is the metric conforming to the "process.paging.faults"
- // semantic conventions. It represents the number of page faults the process
- // has made.
- // Instrument: counter
- // Unit: {fault}
- // Stability: Experimental
- ProcessPagingFaultsName = "process.paging.faults"
- ProcessPagingFaultsUnit = "{fault}"
- ProcessPagingFaultsDescription = "Number of page faults the process has made."
-
- // RPCServerDuration is the metric conforming to the "rpc.server.duration"
- // semantic conventions. It represents the measures the duration of inbound
- // RPC.
- // Instrument: histogram
- // Unit: ms
- // Stability: Experimental
- RPCServerDurationName = "rpc.server.duration"
- RPCServerDurationUnit = "ms"
- RPCServerDurationDescription = "Measures the duration of inbound RPC."
-
- // RPCServerRequestSize is the metric conforming to the
- // "rpc.server.request.size" semantic conventions. It represents the measures
- // the size of RPC request messages (uncompressed).
- // Instrument: histogram
- // Unit: By
- // Stability: Experimental
- RPCServerRequestSizeName = "rpc.server.request.size"
- RPCServerRequestSizeUnit = "By"
- RPCServerRequestSizeDescription = "Measures the size of RPC request messages (uncompressed)."
-
- // RPCServerResponseSize is the metric conforming to the
- // "rpc.server.response.size" semantic conventions. It represents the measures
- // the size of RPC response messages (uncompressed).
- // Instrument: histogram
- // Unit: By
- // Stability: Experimental
- RPCServerResponseSizeName = "rpc.server.response.size"
- RPCServerResponseSizeUnit = "By"
- RPCServerResponseSizeDescription = "Measures the size of RPC response messages (uncompressed)."
-
- // RPCServerRequestsPerRPC is the metric conforming to the
- // "rpc.server.requests_per_rpc" semantic conventions. It represents the
- // measures the number of messages received per RPC.
- // Instrument: histogram
- // Unit: {count}
- // Stability: Experimental
- RPCServerRequestsPerRPCName = "rpc.server.requests_per_rpc"
- RPCServerRequestsPerRPCUnit = "{count}"
- RPCServerRequestsPerRPCDescription = "Measures the number of messages received per RPC."
-
- // RPCServerResponsesPerRPC is the metric conforming to the
- // "rpc.server.responses_per_rpc" semantic conventions. It represents the
- // measures the number of messages sent per RPC.
- // Instrument: histogram
- // Unit: {count}
- // Stability: Experimental
- RPCServerResponsesPerRPCName = "rpc.server.responses_per_rpc"
- RPCServerResponsesPerRPCUnit = "{count}"
- RPCServerResponsesPerRPCDescription = "Measures the number of messages sent per RPC."
-
- // RPCClientDuration is the metric conforming to the "rpc.client.duration"
- // semantic conventions. It represents the measures the duration of outbound
- // RPC.
- // Instrument: histogram
- // Unit: ms
- // Stability: Experimental
- RPCClientDurationName = "rpc.client.duration"
- RPCClientDurationUnit = "ms"
- RPCClientDurationDescription = "Measures the duration of outbound RPC."
-
- // RPCClientRequestSize is the metric conforming to the
- // "rpc.client.request.size" semantic conventions. It represents the measures
- // the size of RPC request messages (uncompressed).
- // Instrument: histogram
- // Unit: By
- // Stability: Experimental
- RPCClientRequestSizeName = "rpc.client.request.size"
- RPCClientRequestSizeUnit = "By"
- RPCClientRequestSizeDescription = "Measures the size of RPC request messages (uncompressed)."
-
- // RPCClientResponseSize is the metric conforming to the
- // "rpc.client.response.size" semantic conventions. It represents the measures
- // the size of RPC response messages (uncompressed).
- // Instrument: histogram
- // Unit: By
- // Stability: Experimental
- RPCClientResponseSizeName = "rpc.client.response.size"
- RPCClientResponseSizeUnit = "By"
- RPCClientResponseSizeDescription = "Measures the size of RPC response messages (uncompressed)."
-
- // RPCClientRequestsPerRPC is the metric conforming to the
- // "rpc.client.requests_per_rpc" semantic conventions. It represents the
- // measures the number of messages received per RPC.
- // Instrument: histogram
- // Unit: {count}
- // Stability: Experimental
- RPCClientRequestsPerRPCName = "rpc.client.requests_per_rpc"
- RPCClientRequestsPerRPCUnit = "{count}"
- RPCClientRequestsPerRPCDescription = "Measures the number of messages received per RPC."
-
- // RPCClientResponsesPerRPC is the metric conforming to the
- // "rpc.client.responses_per_rpc" semantic conventions. It represents the
- // measures the number of messages sent per RPC.
- // Instrument: histogram
- // Unit: {count}
- // Stability: Experimental
- RPCClientResponsesPerRPCName = "rpc.client.responses_per_rpc"
- RPCClientResponsesPerRPCUnit = "{count}"
- RPCClientResponsesPerRPCDescription = "Measures the number of messages sent per RPC."
-
- // SystemCPUTime is the metric conforming to the "system.cpu.time" semantic
- // conventions. It represents the seconds each logical CPU spent on each mode.
- // Instrument: counter
- // Unit: s
- // Stability: Experimental
- SystemCPUTimeName = "system.cpu.time"
- SystemCPUTimeUnit = "s"
- SystemCPUTimeDescription = "Seconds each logical CPU spent on each mode"
-
- // SystemCPUUtilization is the metric conforming to the
- // "system.cpu.utilization" semantic conventions. It represents the difference
- // in system.cpu.time since the last measurement, divided by the elapsed time
- // and number of logical CPUs.
- // Instrument: gauge
- // Unit: 1
- // Stability: Experimental
- SystemCPUUtilizationName = "system.cpu.utilization"
- SystemCPUUtilizationUnit = "1"
- SystemCPUUtilizationDescription = "Difference in system.cpu.time since the last measurement, divided by the elapsed time and number of logical CPUs"
-
- // SystemCPUFrequency is the metric conforming to the "system.cpu.frequency"
- // semantic conventions. It represents the reports the current frequency of the
- // CPU in Hz.
- // Instrument: gauge
- // Unit: {Hz}
- // Stability: Experimental
- SystemCPUFrequencyName = "system.cpu.frequency"
- SystemCPUFrequencyUnit = "{Hz}"
- SystemCPUFrequencyDescription = "Reports the current frequency of the CPU in Hz"
-
- // SystemCPUPhysicalCount is the metric conforming to the
- // "system.cpu.physical.count" semantic conventions. It represents the reports
- // the number of actual physical processor cores on the hardware.
- // Instrument: updowncounter
- // Unit: {cpu}
- // Stability: Experimental
- SystemCPUPhysicalCountName = "system.cpu.physical.count"
- SystemCPUPhysicalCountUnit = "{cpu}"
- SystemCPUPhysicalCountDescription = "Reports the number of actual physical processor cores on the hardware"
-
- // SystemCPULogicalCount is the metric conforming to the
- // "system.cpu.logical.count" semantic conventions. It represents the reports
- // the number of logical (virtual) processor cores created by the operating
- // system to manage multitasking.
- // Instrument: updowncounter
- // Unit: {cpu}
- // Stability: Experimental
- SystemCPULogicalCountName = "system.cpu.logical.count"
- SystemCPULogicalCountUnit = "{cpu}"
- SystemCPULogicalCountDescription = "Reports the number of logical (virtual) processor cores created by the operating system to manage multitasking"
-
- // SystemMemoryUsage is the metric conforming to the "system.memory.usage"
- // semantic conventions. It represents the reports memory in use by state.
- // Instrument: updowncounter
- // Unit: By
- // Stability: Experimental
- SystemMemoryUsageName = "system.memory.usage"
- SystemMemoryUsageUnit = "By"
- SystemMemoryUsageDescription = "Reports memory in use by state."
-
- // SystemMemoryLimit is the metric conforming to the "system.memory.limit"
- // semantic conventions. It represents the total memory available in the
- // system.
- // Instrument: updowncounter
- // Unit: By
- // Stability: Experimental
- SystemMemoryLimitName = "system.memory.limit"
- SystemMemoryLimitUnit = "By"
- SystemMemoryLimitDescription = "Total memory available in the system."
-
- // SystemMemoryShared is the metric conforming to the "system.memory.shared"
- // semantic conventions. It represents the shared memory used (mostly by
- // tmpfs).
- // Instrument: updowncounter
- // Unit: By
- // Stability: Experimental
- SystemMemorySharedName = "system.memory.shared"
- SystemMemorySharedUnit = "By"
- SystemMemorySharedDescription = "Shared memory used (mostly by tmpfs)."
-
- // SystemMemoryUtilization is the metric conforming to the
- // "system.memory.utilization" semantic conventions.
- // Instrument: gauge
- // Unit: 1
- // Stability: Experimental
- // NOTE: The description (brief) for this metric is not defined in the semantic-conventions repository.
- SystemMemoryUtilizationName = "system.memory.utilization"
- SystemMemoryUtilizationUnit = "1"
-
- // SystemPagingUsage is the metric conforming to the "system.paging.usage"
- // semantic conventions. It represents the unix swap or windows pagefile usage.
- // Instrument: updowncounter
- // Unit: By
- // Stability: Experimental
- SystemPagingUsageName = "system.paging.usage"
- SystemPagingUsageUnit = "By"
- SystemPagingUsageDescription = "Unix swap or windows pagefile usage"
-
- // SystemPagingUtilization is the metric conforming to the
- // "system.paging.utilization" semantic conventions.
- // Instrument: gauge
- // Unit: 1
- // Stability: Experimental
- // NOTE: The description (brief) for this metric is not defined in the semantic-conventions repository.
- SystemPagingUtilizationName = "system.paging.utilization"
- SystemPagingUtilizationUnit = "1"
-
- // SystemPagingFaults is the metric conforming to the "system.paging.faults"
- // semantic conventions.
- // Instrument: counter
- // Unit: {fault}
- // Stability: Experimental
- // NOTE: The description (brief) for this metric is not defined in the semantic-conventions repository.
- SystemPagingFaultsName = "system.paging.faults"
- SystemPagingFaultsUnit = "{fault}"
-
- // SystemPagingOperations is the metric conforming to the
- // "system.paging.operations" semantic conventions.
- // Instrument: counter
- // Unit: {operation}
- // Stability: Experimental
- // NOTE: The description (brief) for this metric is not defined in the semantic-conventions repository.
- SystemPagingOperationsName = "system.paging.operations"
- SystemPagingOperationsUnit = "{operation}"
-
- // SystemDiskIo is the metric conforming to the "system.disk.io" semantic
- // conventions.
- // Instrument: counter
- // Unit: By
- // Stability: Experimental
- // NOTE: The description (brief) for this metric is not defined in the semantic-conventions repository.
- SystemDiskIoName = "system.disk.io"
- SystemDiskIoUnit = "By"
-
- // SystemDiskOperations is the metric conforming to the
- // "system.disk.operations" semantic conventions.
- // Instrument: counter
- // Unit: {operation}
- // Stability: Experimental
- // NOTE: The description (brief) for this metric is not defined in the semantic-conventions repository.
- SystemDiskOperationsName = "system.disk.operations"
- SystemDiskOperationsUnit = "{operation}"
-
- // SystemDiskIoTime is the metric conforming to the "system.disk.io_time"
- // semantic conventions. It represents the time disk spent activated.
- // Instrument: counter
- // Unit: s
- // Stability: Experimental
- SystemDiskIoTimeName = "system.disk.io_time"
- SystemDiskIoTimeUnit = "s"
- SystemDiskIoTimeDescription = "Time disk spent activated"
-
- // SystemDiskOperationTime is the metric conforming to the
- // "system.disk.operation_time" semantic conventions. It represents the sum of
- // the time each operation took to complete.
- // Instrument: counter
- // Unit: s
- // Stability: Experimental
- SystemDiskOperationTimeName = "system.disk.operation_time"
- SystemDiskOperationTimeUnit = "s"
- SystemDiskOperationTimeDescription = "Sum of the time each operation took to complete"
-
- // SystemDiskMerged is the metric conforming to the "system.disk.merged"
- // semantic conventions.
- // Instrument: counter
- // Unit: {operation}
- // Stability: Experimental
- // NOTE: The description (brief) for this metric is not defined in the semantic-conventions repository.
- SystemDiskMergedName = "system.disk.merged"
- SystemDiskMergedUnit = "{operation}"
-
- // SystemFilesystemUsage is the metric conforming to the
- // "system.filesystem.usage" semantic conventions.
- // Instrument: updowncounter
- // Unit: By
- // Stability: Experimental
- // NOTE: The description (brief) for this metric is not defined in the semantic-conventions repository.
- SystemFilesystemUsageName = "system.filesystem.usage"
- SystemFilesystemUsageUnit = "By"
-
- // SystemFilesystemUtilization is the metric conforming to the
- // "system.filesystem.utilization" semantic conventions.
- // Instrument: gauge
- // Unit: 1
- // Stability: Experimental
- // NOTE: The description (brief) for this metric is not defined in the semantic-conventions repository.
- SystemFilesystemUtilizationName = "system.filesystem.utilization"
- SystemFilesystemUtilizationUnit = "1"
-
- // SystemNetworkDropped is the metric conforming to the
- // "system.network.dropped" semantic conventions. It represents the count of
- // packets that are dropped or discarded even though there was no error.
- // Instrument: counter
- // Unit: {packet}
- // Stability: Experimental
- SystemNetworkDroppedName = "system.network.dropped"
- SystemNetworkDroppedUnit = "{packet}"
- SystemNetworkDroppedDescription = "Count of packets that are dropped or discarded even though there was no error"
-
- // SystemNetworkPackets is the metric conforming to the
- // "system.network.packets" semantic conventions.
- // Instrument: counter
- // Unit: {packet}
- // Stability: Experimental
- // NOTE: The description (brief) for this metric is not defined in the semantic-conventions repository.
- SystemNetworkPacketsName = "system.network.packets"
- SystemNetworkPacketsUnit = "{packet}"
-
- // SystemNetworkErrors is the metric conforming to the "system.network.errors"
- // semantic conventions. It represents the count of network errors detected.
- // Instrument: counter
- // Unit: {error}
- // Stability: Experimental
- SystemNetworkErrorsName = "system.network.errors"
- SystemNetworkErrorsUnit = "{error}"
- SystemNetworkErrorsDescription = "Count of network errors detected"
-
- // SystemNetworkIo is the metric conforming to the "system.network.io" semantic
- // conventions.
- // Instrument: counter
- // Unit: By
- // Stability: Experimental
- // NOTE: The description (brief) for this metric is not defined in the semantic-conventions repository.
- SystemNetworkIoName = "system.network.io"
- SystemNetworkIoUnit = "By"
-
- // SystemNetworkConnections is the metric conforming to the
- // "system.network.connections" semantic conventions.
- // Instrument: updowncounter
- // Unit: {connection}
- // Stability: Experimental
- // NOTE: The description (brief) for this metric is not defined in the semantic-conventions repository.
- SystemNetworkConnectionsName = "system.network.connections"
- SystemNetworkConnectionsUnit = "{connection}"
-
- // SystemProcessCount is the metric conforming to the "system.process.count"
- // semantic conventions. It represents the total number of processes in each
- // state.
- // Instrument: updowncounter
- // Unit: {process}
- // Stability: Experimental
- SystemProcessCountName = "system.process.count"
- SystemProcessCountUnit = "{process}"
- SystemProcessCountDescription = "Total number of processes in each state"
-
- // SystemProcessCreated is the metric conforming to the
- // "system.process.created" semantic conventions. It represents the total
- // number of processes created over uptime of the host.
- // Instrument: counter
- // Unit: {process}
- // Stability: Experimental
- SystemProcessCreatedName = "system.process.created"
- SystemProcessCreatedUnit = "{process}"
- SystemProcessCreatedDescription = "Total number of processes created over uptime of the host"
-
- // SystemLinuxMemoryAvailable is the metric conforming to the
- // "system.linux.memory.available" semantic conventions. It represents an
- // estimate of how much memory is available for starting new applications,
- // without causing swapping.
- // Instrument: updowncounter
- // Unit: By
- // Stability: Experimental
- SystemLinuxMemoryAvailableName = "system.linux.memory.available"
- SystemLinuxMemoryAvailableUnit = "By"
- SystemLinuxMemoryAvailableDescription = "An estimate of how much memory is available for starting new applications, without causing swapping"
-)
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.26.0/schema.go b/vendor/go.opentelemetry.io/otel/semconv/v1.26.0/schema.go
deleted file mode 100644
index 4c87c7adcc..0000000000
--- a/vendor/go.opentelemetry.io/otel/semconv/v1.26.0/schema.go
+++ /dev/null
@@ -1,9 +0,0 @@
-// Copyright The OpenTelemetry Authors
-// SPDX-License-Identifier: Apache-2.0
-
-package semconv // import "go.opentelemetry.io/otel/semconv/v1.26.0"
-
-// SchemaURL is the schema URL that matches the version of the semantic conventions
-// that this package defines. Semconv packages starting from v1.4.0 must declare
-// non-empty schema URL in the form https://opentelemetry.io/schemas/
-const SchemaURL = "https://opentelemetry.io/schemas/1.26.0"
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.37.0/MIGRATION.md b/vendor/go.opentelemetry.io/otel/semconv/v1.37.0/MIGRATION.md
new file mode 100644
index 0000000000..2480547895
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/semconv/v1.37.0/MIGRATION.md
@@ -0,0 +1,41 @@
+
+# Migration from v1.36.0 to v1.37.0
+
+The `go.opentelemetry.io/otel/semconv/v1.37.0` package should be a drop-in replacement for `go.opentelemetry.io/otel/semconv/v1.36.0` with the following exceptions.
+
+## Removed
+
+The following declarations have been removed.
+Refer to the [OpenTelemetry Semantic Conventions documentation] for deprecation instructions.
+
+If the type is not listed in the documentation as deprecated, it has been removed in this version due to lack of applicability or use.
+If you use any of these non-deprecated declarations in your Go application, please [open an issue] describing your use-case.
+
+- `ContainerRuntime`
+- `ContainerRuntimeKey`
+- `GenAIOpenAIRequestServiceTierAuto`
+- `GenAIOpenAIRequestServiceTierDefault`
+- `GenAIOpenAIRequestServiceTierKey`
+- `GenAIOpenAIResponseServiceTier`
+- `GenAIOpenAIResponseServiceTierKey`
+- `GenAIOpenAIResponseSystemFingerprint`
+- `GenAIOpenAIResponseSystemFingerprintKey`
+- `GenAISystemAWSBedrock`
+- `GenAISystemAnthropic`
+- `GenAISystemAzureAIInference`
+- `GenAISystemAzureAIOpenAI`
+- `GenAISystemCohere`
+- `GenAISystemDeepseek`
+- `GenAISystemGCPGemini`
+- `GenAISystemGCPGenAI`
+- `GenAISystemGCPVertexAI`
+- `GenAISystemGroq`
+- `GenAISystemIBMWatsonxAI`
+- `GenAISystemKey`
+- `GenAISystemMistralAI`
+- `GenAISystemOpenAI`
+- `GenAISystemPerplexity`
+- `GenAISystemXai`
+
+[OpenTelemetry Semantic Conventions documentation]: https://github.com/open-telemetry/semantic-conventions
+[open an issue]: https://github.com/open-telemetry/opentelemetry-go/issues/new?template=Blank+issue
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.37.0/README.md b/vendor/go.opentelemetry.io/otel/semconv/v1.37.0/README.md
new file mode 100644
index 0000000000..d795247f32
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/semconv/v1.37.0/README.md
@@ -0,0 +1,3 @@
+# Semconv v1.37.0
+
+[](https://pkg.go.dev/go.opentelemetry.io/otel/semconv/v1.37.0)
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.37.0/attribute_group.go b/vendor/go.opentelemetry.io/otel/semconv/v1.37.0/attribute_group.go
new file mode 100644
index 0000000000..b6b27498f2
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/semconv/v1.37.0/attribute_group.go
@@ -0,0 +1,15193 @@
+// Copyright The OpenTelemetry Authors
+// SPDX-License-Identifier: Apache-2.0
+
+// Code generated from semantic convention specification. DO NOT EDIT.
+
+package semconv // import "go.opentelemetry.io/otel/semconv/v1.37.0"
+
+import "go.opentelemetry.io/otel/attribute"
+
+// Namespace: android
+const (
+ // AndroidAppStateKey is the attribute Key conforming to the "android.app.state"
+ // semantic conventions. It represents the this attribute represents the state
+ // of the application.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "created"
+ // Note: The Android lifecycle states are defined in
+ // [Activity lifecycle callbacks], and from which the `OS identifiers` are
+ // derived.
+ //
+ // [Activity lifecycle callbacks]: https://developer.android.com/guide/components/activities/activity-lifecycle#lc
+ AndroidAppStateKey = attribute.Key("android.app.state")
+
+ // AndroidOSAPILevelKey is the attribute Key conforming to the
+ // "android.os.api_level" semantic conventions. It represents the uniquely
+ // identifies the framework API revision offered by a version (`os.version`) of
+ // the android operating system. More information can be found in the
+ // [Android API levels documentation].
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "33", "32"
+ //
+ // [Android API levels documentation]: https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels
+ AndroidOSAPILevelKey = attribute.Key("android.os.api_level")
+)
+
+// AndroidOSAPILevel returns an attribute KeyValue conforming to the
+// "android.os.api_level" semantic conventions. It represents the uniquely
+// identifies the framework API revision offered by a version (`os.version`) of
+// the android operating system. More information can be found in the
+// [Android API levels documentation].
+//
+// [Android API levels documentation]: https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels
+func AndroidOSAPILevel(val string) attribute.KeyValue {
+ return AndroidOSAPILevelKey.String(val)
+}
+
+// Enum values for android.app.state
+var (
+ // Any time before Activity.onResume() or, if the app has no Activity,
+ // Context.startService() has been called in the app for the first time.
+ //
+ // Stability: development
+ AndroidAppStateCreated = AndroidAppStateKey.String("created")
+ // Any time after Activity.onPause() or, if the app has no Activity,
+ // Context.stopService() has been called when the app was in the foreground
+ // state.
+ //
+ // Stability: development
+ AndroidAppStateBackground = AndroidAppStateKey.String("background")
+ // Any time after Activity.onResume() or, if the app has no Activity,
+ // Context.startService() has been called when the app was in either the created
+ // or background states.
+ //
+ // Stability: development
+ AndroidAppStateForeground = AndroidAppStateKey.String("foreground")
+)
+
+// Namespace: app
+const (
+ // AppBuildIDKey is the attribute Key conforming to the "app.build_id" semantic
+ // conventions. It represents the unique identifier for a particular build or
+ // compilation of the application.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "6cff0a7e-cefc-4668-96f5-1273d8b334d0",
+ // "9f2b833506aa6973a92fde9733e6271f", "my-app-1.0.0-code-123"
+ AppBuildIDKey = attribute.Key("app.build_id")
+
+ // AppInstallationIDKey is the attribute Key conforming to the
+ // "app.installation.id" semantic conventions. It represents a unique identifier
+ // representing the installation of an application on a specific device.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "2ab2916d-a51f-4ac8-80ee-45ac31a28092"
+ // Note: Its value SHOULD persist across launches of the same application
+ // installation, including through application upgrades.
+ // It SHOULD change if the application is uninstalled or if all applications of
+ // the vendor are uninstalled.
+ // Additionally, users might be able to reset this value (e.g. by clearing
+ // application data).
+ // If an app is installed multiple times on the same device (e.g. in different
+ // accounts on Android), each `app.installation.id` SHOULD have a different
+ // value.
+ // If multiple OpenTelemetry SDKs are used within the same application, they
+ // SHOULD use the same value for `app.installation.id`.
+ // Hardware IDs (e.g. serial number, IMEI, MAC address) MUST NOT be used as the
+ // `app.installation.id`.
+ //
+ // For iOS, this value SHOULD be equal to the [vendor identifier].
+ //
+ // For Android, examples of `app.installation.id` implementations include:
+ //
+ // - [Firebase Installation ID].
+ // - A globally unique UUID which is persisted across sessions in your
+ // application.
+ // - [App set ID].
+ // - [`Settings.getString(Settings.Secure.ANDROID_ID)`].
+ //
+ // More information about Android identifier best practices can be found in the
+ // [Android user data IDs guide].
+ //
+ // [vendor identifier]: https://developer.apple.com/documentation/uikit/uidevice/identifierforvendor
+ // [Firebase Installation ID]: https://firebase.google.com/docs/projects/manage-installations
+ // [App set ID]: https://developer.android.com/identity/app-set-id
+ // [`Settings.getString(Settings.Secure.ANDROID_ID)`]: https://developer.android.com/reference/android/provider/Settings.Secure#ANDROID_ID
+ // [Android user data IDs guide]: https://developer.android.com/training/articles/user-data-ids
+ AppInstallationIDKey = attribute.Key("app.installation.id")
+
+ // AppJankFrameCountKey is the attribute Key conforming to the
+ // "app.jank.frame_count" semantic conventions. It represents a number of frame
+ // renders that experienced jank.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 9, 42
+ // Note: Depending on platform limitations, the value provided MAY be
+ // approximation.
+ AppJankFrameCountKey = attribute.Key("app.jank.frame_count")
+
+ // AppJankPeriodKey is the attribute Key conforming to the "app.jank.period"
+ // semantic conventions. It represents the time period, in seconds, for which
+ // this jank is being reported.
+ //
+ // Type: double
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 1.0, 5.0, 10.24
+ AppJankPeriodKey = attribute.Key("app.jank.period")
+
+ // AppJankThresholdKey is the attribute Key conforming to the
+ // "app.jank.threshold" semantic conventions. It represents the minimum
+ // rendering threshold for this jank, in seconds.
+ //
+ // Type: double
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 0.016, 0.7, 1.024
+ AppJankThresholdKey = attribute.Key("app.jank.threshold")
+
+ // AppScreenCoordinateXKey is the attribute Key conforming to the
+ // "app.screen.coordinate.x" semantic conventions. It represents the x
+ // (horizontal) coordinate of a screen coordinate, in screen pixels.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 0, 131
+ AppScreenCoordinateXKey = attribute.Key("app.screen.coordinate.x")
+
+ // AppScreenCoordinateYKey is the attribute Key conforming to the
+ // "app.screen.coordinate.y" semantic conventions. It represents the y
+ // (vertical) component of a screen coordinate, in screen pixels.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 12, 99
+ AppScreenCoordinateYKey = attribute.Key("app.screen.coordinate.y")
+
+ // AppWidgetIDKey is the attribute Key conforming to the "app.widget.id"
+ // semantic conventions. It represents an identifier that uniquely
+ // differentiates this widget from other widgets in the same application.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "f9bc787d-ff05-48ad-90e1-fca1d46130b3", "submit_order_1829"
+ // Note: A widget is an application component, typically an on-screen visual GUI
+ // element.
+ AppWidgetIDKey = attribute.Key("app.widget.id")
+
+ // AppWidgetNameKey is the attribute Key conforming to the "app.widget.name"
+ // semantic conventions. It represents the name of an application widget.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "submit", "attack", "Clear Cart"
+ // Note: A widget is an application component, typically an on-screen visual GUI
+ // element.
+ AppWidgetNameKey = attribute.Key("app.widget.name")
+)
+
+// AppBuildID returns an attribute KeyValue conforming to the "app.build_id"
+// semantic conventions. It represents the unique identifier for a particular
+// build or compilation of the application.
+func AppBuildID(val string) attribute.KeyValue {
+ return AppBuildIDKey.String(val)
+}
+
+// AppInstallationID returns an attribute KeyValue conforming to the
+// "app.installation.id" semantic conventions. It represents a unique identifier
+// representing the installation of an application on a specific device.
+func AppInstallationID(val string) attribute.KeyValue {
+ return AppInstallationIDKey.String(val)
+}
+
+// AppJankFrameCount returns an attribute KeyValue conforming to the
+// "app.jank.frame_count" semantic conventions. It represents a number of frame
+// renders that experienced jank.
+func AppJankFrameCount(val int) attribute.KeyValue {
+ return AppJankFrameCountKey.Int(val)
+}
+
+// AppJankPeriod returns an attribute KeyValue conforming to the
+// "app.jank.period" semantic conventions. It represents the time period, in
+// seconds, for which this jank is being reported.
+func AppJankPeriod(val float64) attribute.KeyValue {
+ return AppJankPeriodKey.Float64(val)
+}
+
+// AppJankThreshold returns an attribute KeyValue conforming to the
+// "app.jank.threshold" semantic conventions. It represents the minimum rendering
+// threshold for this jank, in seconds.
+func AppJankThreshold(val float64) attribute.KeyValue {
+ return AppJankThresholdKey.Float64(val)
+}
+
+// AppScreenCoordinateX returns an attribute KeyValue conforming to the
+// "app.screen.coordinate.x" semantic conventions. It represents the x
+// (horizontal) coordinate of a screen coordinate, in screen pixels.
+func AppScreenCoordinateX(val int) attribute.KeyValue {
+ return AppScreenCoordinateXKey.Int(val)
+}
+
+// AppScreenCoordinateY returns an attribute KeyValue conforming to the
+// "app.screen.coordinate.y" semantic conventions. It represents the y (vertical)
+// component of a screen coordinate, in screen pixels.
+func AppScreenCoordinateY(val int) attribute.KeyValue {
+ return AppScreenCoordinateYKey.Int(val)
+}
+
+// AppWidgetID returns an attribute KeyValue conforming to the "app.widget.id"
+// semantic conventions. It represents an identifier that uniquely differentiates
+// this widget from other widgets in the same application.
+func AppWidgetID(val string) attribute.KeyValue {
+ return AppWidgetIDKey.String(val)
+}
+
+// AppWidgetName returns an attribute KeyValue conforming to the
+// "app.widget.name" semantic conventions. It represents the name of an
+// application widget.
+func AppWidgetName(val string) attribute.KeyValue {
+ return AppWidgetNameKey.String(val)
+}
+
+// Namespace: artifact
+const (
+ // ArtifactAttestationFilenameKey is the attribute Key conforming to the
+ // "artifact.attestation.filename" semantic conventions. It represents the
+ // provenance filename of the built attestation which directly relates to the
+ // build artifact filename. This filename SHOULD accompany the artifact at
+ // publish time. See the [SLSA Relationship] specification for more information.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "golang-binary-amd64-v0.1.0.attestation",
+ // "docker-image-amd64-v0.1.0.intoto.json1", "release-1.tar.gz.attestation",
+ // "file-name-package.tar.gz.intoto.json1"
+ //
+ // [SLSA Relationship]: https://slsa.dev/spec/v1.0/distributing-provenance#relationship-between-artifacts-and-attestations
+ ArtifactAttestationFilenameKey = attribute.Key("artifact.attestation.filename")
+
+ // ArtifactAttestationHashKey is the attribute Key conforming to the
+ // "artifact.attestation.hash" semantic conventions. It represents the full
+ // [hash value (see glossary)], of the built attestation. Some envelopes in the
+ // [software attestation space] also refer to this as the **digest**.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "1b31dfcd5b7f9267bf2ff47651df1cfb9147b9e4df1f335accf65b4cda498408"
+ //
+ // [hash value (see glossary)]: https://nvlpubs.nist.gov/nistpubs/FIPS/NIST.FIPS.186-5.pdf
+ // [software attestation space]: https://github.com/in-toto/attestation/tree/main/spec
+ ArtifactAttestationHashKey = attribute.Key("artifact.attestation.hash")
+
+ // ArtifactAttestationIDKey is the attribute Key conforming to the
+ // "artifact.attestation.id" semantic conventions. It represents the id of the
+ // build [software attestation].
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "123"
+ //
+ // [software attestation]: https://slsa.dev/attestation-model
+ ArtifactAttestationIDKey = attribute.Key("artifact.attestation.id")
+
+ // ArtifactFilenameKey is the attribute Key conforming to the
+ // "artifact.filename" semantic conventions. It represents the human readable
+ // file name of the artifact, typically generated during build and release
+ // processes. Often includes the package name and version in the file name.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "golang-binary-amd64-v0.1.0", "docker-image-amd64-v0.1.0",
+ // "release-1.tar.gz", "file-name-package.tar.gz"
+ // Note: This file name can also act as the [Package Name]
+ // in cases where the package ecosystem maps accordingly.
+ // Additionally, the artifact [can be published]
+ // for others, but that is not a guarantee.
+ //
+ // [Package Name]: https://slsa.dev/spec/v1.0/terminology#package-model
+ // [can be published]: https://slsa.dev/spec/v1.0/terminology#software-supply-chain
+ ArtifactFilenameKey = attribute.Key("artifact.filename")
+
+ // ArtifactHashKey is the attribute Key conforming to the "artifact.hash"
+ // semantic conventions. It represents the full [hash value (see glossary)],
+ // often found in checksum.txt on a release of the artifact and used to verify
+ // package integrity.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "9ff4c52759e2c4ac70b7d517bc7fcdc1cda631ca0045271ddd1b192544f8a3e9"
+ // Note: The specific algorithm used to create the cryptographic hash value is
+ // not defined. In situations where an artifact has multiple
+ // cryptographic hashes, it is up to the implementer to choose which
+ // hash value to set here; this should be the most secure hash algorithm
+ // that is suitable for the situation and consistent with the
+ // corresponding attestation. The implementer can then provide the other
+ // hash values through an additional set of attribute extensions as they
+ // deem necessary.
+ //
+ // [hash value (see glossary)]: https://nvlpubs.nist.gov/nistpubs/FIPS/NIST.FIPS.186-5.pdf
+ ArtifactHashKey = attribute.Key("artifact.hash")
+
+ // ArtifactPurlKey is the attribute Key conforming to the "artifact.purl"
+ // semantic conventions. It represents the [Package URL] of the
+ // [package artifact] provides a standard way to identify and locate the
+ // packaged artifact.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "pkg:github/package-url/purl-spec@1209109710924",
+ // "pkg:npm/foo@12.12.3"
+ //
+ // [Package URL]: https://github.com/package-url/purl-spec
+ // [package artifact]: https://slsa.dev/spec/v1.0/terminology#package-model
+ ArtifactPurlKey = attribute.Key("artifact.purl")
+
+ // ArtifactVersionKey is the attribute Key conforming to the "artifact.version"
+ // semantic conventions. It represents the version of the artifact.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "v0.1.0", "1.2.1", "122691-build"
+ ArtifactVersionKey = attribute.Key("artifact.version")
+)
+
+// ArtifactAttestationFilename returns an attribute KeyValue conforming to the
+// "artifact.attestation.filename" semantic conventions. It represents the
+// provenance filename of the built attestation which directly relates to the
+// build artifact filename. This filename SHOULD accompany the artifact at
+// publish time. See the [SLSA Relationship] specification for more information.
+//
+// [SLSA Relationship]: https://slsa.dev/spec/v1.0/distributing-provenance#relationship-between-artifacts-and-attestations
+func ArtifactAttestationFilename(val string) attribute.KeyValue {
+ return ArtifactAttestationFilenameKey.String(val)
+}
+
+// ArtifactAttestationHash returns an attribute KeyValue conforming to the
+// "artifact.attestation.hash" semantic conventions. It represents the full
+// [hash value (see glossary)], of the built attestation. Some envelopes in the
+// [software attestation space] also refer to this as the **digest**.
+//
+// [hash value (see glossary)]: https://nvlpubs.nist.gov/nistpubs/FIPS/NIST.FIPS.186-5.pdf
+// [software attestation space]: https://github.com/in-toto/attestation/tree/main/spec
+func ArtifactAttestationHash(val string) attribute.KeyValue {
+ return ArtifactAttestationHashKey.String(val)
+}
+
+// ArtifactAttestationID returns an attribute KeyValue conforming to the
+// "artifact.attestation.id" semantic conventions. It represents the id of the
+// build [software attestation].
+//
+// [software attestation]: https://slsa.dev/attestation-model
+func ArtifactAttestationID(val string) attribute.KeyValue {
+ return ArtifactAttestationIDKey.String(val)
+}
+
+// ArtifactFilename returns an attribute KeyValue conforming to the
+// "artifact.filename" semantic conventions. It represents the human readable
+// file name of the artifact, typically generated during build and release
+// processes. Often includes the package name and version in the file name.
+func ArtifactFilename(val string) attribute.KeyValue {
+ return ArtifactFilenameKey.String(val)
+}
+
+// ArtifactHash returns an attribute KeyValue conforming to the "artifact.hash"
+// semantic conventions. It represents the full [hash value (see glossary)],
+// often found in checksum.txt on a release of the artifact and used to verify
+// package integrity.
+//
+// [hash value (see glossary)]: https://nvlpubs.nist.gov/nistpubs/FIPS/NIST.FIPS.186-5.pdf
+func ArtifactHash(val string) attribute.KeyValue {
+ return ArtifactHashKey.String(val)
+}
+
+// ArtifactPurl returns an attribute KeyValue conforming to the "artifact.purl"
+// semantic conventions. It represents the [Package URL] of the
+// [package artifact] provides a standard way to identify and locate the packaged
+// artifact.
+//
+// [Package URL]: https://github.com/package-url/purl-spec
+// [package artifact]: https://slsa.dev/spec/v1.0/terminology#package-model
+func ArtifactPurl(val string) attribute.KeyValue {
+ return ArtifactPurlKey.String(val)
+}
+
+// ArtifactVersion returns an attribute KeyValue conforming to the
+// "artifact.version" semantic conventions. It represents the version of the
+// artifact.
+func ArtifactVersion(val string) attribute.KeyValue {
+ return ArtifactVersionKey.String(val)
+}
+
+// Namespace: aws
+const (
+ // AWSBedrockGuardrailIDKey is the attribute Key conforming to the
+ // "aws.bedrock.guardrail.id" semantic conventions. It represents the unique
+ // identifier of the AWS Bedrock Guardrail. A [guardrail] helps safeguard and
+ // prevent unwanted behavior from model responses or user messages.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "sgi5gkybzqak"
+ //
+ // [guardrail]: https://docs.aws.amazon.com/bedrock/latest/userguide/guardrails.html
+ AWSBedrockGuardrailIDKey = attribute.Key("aws.bedrock.guardrail.id")
+
+ // AWSBedrockKnowledgeBaseIDKey is the attribute Key conforming to the
+ // "aws.bedrock.knowledge_base.id" semantic conventions. It represents the
+ // unique identifier of the AWS Bedrock Knowledge base. A [knowledge base] is a
+ // bank of information that can be queried by models to generate more relevant
+ // responses and augment prompts.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "XFWUPB9PAW"
+ //
+ // [knowledge base]: https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base.html
+ AWSBedrockKnowledgeBaseIDKey = attribute.Key("aws.bedrock.knowledge_base.id")
+
+ // AWSDynamoDBAttributeDefinitionsKey is the attribute Key conforming to the
+ // "aws.dynamodb.attribute_definitions" semantic conventions. It represents the
+ // JSON-serialized value of each item in the `AttributeDefinitions` request
+ // field.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "{ "AttributeName": "string", "AttributeType": "string" }"
+ AWSDynamoDBAttributeDefinitionsKey = attribute.Key("aws.dynamodb.attribute_definitions")
+
+ // AWSDynamoDBAttributesToGetKey is the attribute Key conforming to the
+ // "aws.dynamodb.attributes_to_get" semantic conventions. It represents the
+ // value of the `AttributesToGet` request parameter.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "lives", "id"
+ AWSDynamoDBAttributesToGetKey = attribute.Key("aws.dynamodb.attributes_to_get")
+
+ // AWSDynamoDBConsistentReadKey is the attribute Key conforming to the
+ // "aws.dynamodb.consistent_read" semantic conventions. It represents the value
+ // of the `ConsistentRead` request parameter.
+ //
+ // Type: boolean
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ AWSDynamoDBConsistentReadKey = attribute.Key("aws.dynamodb.consistent_read")
+
+ // AWSDynamoDBConsumedCapacityKey is the attribute Key conforming to the
+ // "aws.dynamodb.consumed_capacity" semantic conventions. It represents the
+ // JSON-serialized value of each item in the `ConsumedCapacity` response field.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "{ "CapacityUnits": number, "GlobalSecondaryIndexes": { "string" :
+ // { "CapacityUnits": number, "ReadCapacityUnits": number, "WriteCapacityUnits":
+ // number } }, "LocalSecondaryIndexes": { "string" : { "CapacityUnits": number,
+ // "ReadCapacityUnits": number, "WriteCapacityUnits": number } },
+ // "ReadCapacityUnits": number, "Table": { "CapacityUnits": number,
+ // "ReadCapacityUnits": number, "WriteCapacityUnits": number }, "TableName":
+ // "string", "WriteCapacityUnits": number }"
+ AWSDynamoDBConsumedCapacityKey = attribute.Key("aws.dynamodb.consumed_capacity")
+
+ // AWSDynamoDBCountKey is the attribute Key conforming to the
+ // "aws.dynamodb.count" semantic conventions. It represents the value of the
+ // `Count` response parameter.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 10
+ AWSDynamoDBCountKey = attribute.Key("aws.dynamodb.count")
+
+ // AWSDynamoDBExclusiveStartTableKey is the attribute Key conforming to the
+ // "aws.dynamodb.exclusive_start_table" semantic conventions. It represents the
+ // value of the `ExclusiveStartTableName` request parameter.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Users", "CatsTable"
+ AWSDynamoDBExclusiveStartTableKey = attribute.Key("aws.dynamodb.exclusive_start_table")
+
+ // AWSDynamoDBGlobalSecondaryIndexUpdatesKey is the attribute Key conforming to
+ // the "aws.dynamodb.global_secondary_index_updates" semantic conventions. It
+ // represents the JSON-serialized value of each item in the
+ // `GlobalSecondaryIndexUpdates` request field.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "{ "Create": { "IndexName": "string", "KeySchema": [ {
+ // "AttributeName": "string", "KeyType": "string" } ], "Projection": {
+ // "NonKeyAttributes": [ "string" ], "ProjectionType": "string" },
+ // "ProvisionedThroughput": { "ReadCapacityUnits": number, "WriteCapacityUnits":
+ // number } }"
+ AWSDynamoDBGlobalSecondaryIndexUpdatesKey = attribute.Key("aws.dynamodb.global_secondary_index_updates")
+
+ // AWSDynamoDBGlobalSecondaryIndexesKey is the attribute Key conforming to the
+ // "aws.dynamodb.global_secondary_indexes" semantic conventions. It represents
+ // the JSON-serialized value of each item of the `GlobalSecondaryIndexes`
+ // request field.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "{ "IndexName": "string", "KeySchema": [ { "AttributeName":
+ // "string", "KeyType": "string" } ], "Projection": { "NonKeyAttributes": [
+ // "string" ], "ProjectionType": "string" }, "ProvisionedThroughput": {
+ // "ReadCapacityUnits": number, "WriteCapacityUnits": number } }"
+ AWSDynamoDBGlobalSecondaryIndexesKey = attribute.Key("aws.dynamodb.global_secondary_indexes")
+
+ // AWSDynamoDBIndexNameKey is the attribute Key conforming to the
+ // "aws.dynamodb.index_name" semantic conventions. It represents the value of
+ // the `IndexName` request parameter.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "name_to_group"
+ AWSDynamoDBIndexNameKey = attribute.Key("aws.dynamodb.index_name")
+
+ // AWSDynamoDBItemCollectionMetricsKey is the attribute Key conforming to the
+ // "aws.dynamodb.item_collection_metrics" semantic conventions. It represents
+ // the JSON-serialized value of the `ItemCollectionMetrics` response field.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "{ "string" : [ { "ItemCollectionKey": { "string" : { "B": blob,
+ // "BOOL": boolean, "BS": [ blob ], "L": [ "AttributeValue" ], "M": { "string" :
+ // "AttributeValue" }, "N": "string", "NS": [ "string" ], "NULL": boolean, "S":
+ // "string", "SS": [ "string" ] } }, "SizeEstimateRangeGB": [ number ] } ] }"
+ AWSDynamoDBItemCollectionMetricsKey = attribute.Key("aws.dynamodb.item_collection_metrics")
+
+ // AWSDynamoDBLimitKey is the attribute Key conforming to the
+ // "aws.dynamodb.limit" semantic conventions. It represents the value of the
+ // `Limit` request parameter.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 10
+ AWSDynamoDBLimitKey = attribute.Key("aws.dynamodb.limit")
+
+ // AWSDynamoDBLocalSecondaryIndexesKey is the attribute Key conforming to the
+ // "aws.dynamodb.local_secondary_indexes" semantic conventions. It represents
+ // the JSON-serialized value of each item of the `LocalSecondaryIndexes` request
+ // field.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "{ "IndexArn": "string", "IndexName": "string", "IndexSizeBytes":
+ // number, "ItemCount": number, "KeySchema": [ { "AttributeName": "string",
+ // "KeyType": "string" } ], "Projection": { "NonKeyAttributes": [ "string" ],
+ // "ProjectionType": "string" } }"
+ AWSDynamoDBLocalSecondaryIndexesKey = attribute.Key("aws.dynamodb.local_secondary_indexes")
+
+ // AWSDynamoDBProjectionKey is the attribute Key conforming to the
+ // "aws.dynamodb.projection" semantic conventions. It represents the value of
+ // the `ProjectionExpression` request parameter.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Title", "Title, Price, Color", "Title, Description, RelatedItems,
+ // ProductReviews"
+ AWSDynamoDBProjectionKey = attribute.Key("aws.dynamodb.projection")
+
+ // AWSDynamoDBProvisionedReadCapacityKey is the attribute Key conforming to the
+ // "aws.dynamodb.provisioned_read_capacity" semantic conventions. It represents
+ // the value of the `ProvisionedThroughput.ReadCapacityUnits` request parameter.
+ //
+ // Type: double
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 1.0, 2.0
+ AWSDynamoDBProvisionedReadCapacityKey = attribute.Key("aws.dynamodb.provisioned_read_capacity")
+
+ // AWSDynamoDBProvisionedWriteCapacityKey is the attribute Key conforming to the
+ // "aws.dynamodb.provisioned_write_capacity" semantic conventions. It represents
+ // the value of the `ProvisionedThroughput.WriteCapacityUnits` request
+ // parameter.
+ //
+ // Type: double
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 1.0, 2.0
+ AWSDynamoDBProvisionedWriteCapacityKey = attribute.Key("aws.dynamodb.provisioned_write_capacity")
+
+ // AWSDynamoDBScanForwardKey is the attribute Key conforming to the
+ // "aws.dynamodb.scan_forward" semantic conventions. It represents the value of
+ // the `ScanIndexForward` request parameter.
+ //
+ // Type: boolean
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ AWSDynamoDBScanForwardKey = attribute.Key("aws.dynamodb.scan_forward")
+
+ // AWSDynamoDBScannedCountKey is the attribute Key conforming to the
+ // "aws.dynamodb.scanned_count" semantic conventions. It represents the value of
+ // the `ScannedCount` response parameter.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 50
+ AWSDynamoDBScannedCountKey = attribute.Key("aws.dynamodb.scanned_count")
+
+ // AWSDynamoDBSegmentKey is the attribute Key conforming to the
+ // "aws.dynamodb.segment" semantic conventions. It represents the value of the
+ // `Segment` request parameter.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 10
+ AWSDynamoDBSegmentKey = attribute.Key("aws.dynamodb.segment")
+
+ // AWSDynamoDBSelectKey is the attribute Key conforming to the
+ // "aws.dynamodb.select" semantic conventions. It represents the value of the
+ // `Select` request parameter.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "ALL_ATTRIBUTES", "COUNT"
+ AWSDynamoDBSelectKey = attribute.Key("aws.dynamodb.select")
+
+ // AWSDynamoDBTableCountKey is the attribute Key conforming to the
+ // "aws.dynamodb.table_count" semantic conventions. It represents the number of
+ // items in the `TableNames` response parameter.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 20
+ AWSDynamoDBTableCountKey = attribute.Key("aws.dynamodb.table_count")
+
+ // AWSDynamoDBTableNamesKey is the attribute Key conforming to the
+ // "aws.dynamodb.table_names" semantic conventions. It represents the keys in
+ // the `RequestItems` object field.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Users", "Cats"
+ AWSDynamoDBTableNamesKey = attribute.Key("aws.dynamodb.table_names")
+
+ // AWSDynamoDBTotalSegmentsKey is the attribute Key conforming to the
+ // "aws.dynamodb.total_segments" semantic conventions. It represents the value
+ // of the `TotalSegments` request parameter.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 100
+ AWSDynamoDBTotalSegmentsKey = attribute.Key("aws.dynamodb.total_segments")
+
+ // AWSECSClusterARNKey is the attribute Key conforming to the
+ // "aws.ecs.cluster.arn" semantic conventions. It represents the ARN of an
+ // [ECS cluster].
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "arn:aws:ecs:us-west-2:123456789123:cluster/my-cluster"
+ //
+ // [ECS cluster]: https://docs.aws.amazon.com/AmazonECS/latest/developerguide/clusters.html
+ AWSECSClusterARNKey = attribute.Key("aws.ecs.cluster.arn")
+
+ // AWSECSContainerARNKey is the attribute Key conforming to the
+ // "aws.ecs.container.arn" semantic conventions. It represents the Amazon
+ // Resource Name (ARN) of an [ECS container instance].
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // "arn:aws:ecs:us-west-1:123456789123:container/32624152-9086-4f0e-acae-1a75b14fe4d9"
+ //
+ // [ECS container instance]: https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ECS_instances.html
+ AWSECSContainerARNKey = attribute.Key("aws.ecs.container.arn")
+
+ // AWSECSLaunchtypeKey is the attribute Key conforming to the
+ // "aws.ecs.launchtype" semantic conventions. It represents the [launch type]
+ // for an ECS task.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ //
+ // [launch type]: https://docs.aws.amazon.com/AmazonECS/latest/developerguide/launch_types.html
+ AWSECSLaunchtypeKey = attribute.Key("aws.ecs.launchtype")
+
+ // AWSECSTaskARNKey is the attribute Key conforming to the "aws.ecs.task.arn"
+ // semantic conventions. It represents the ARN of a running [ECS task].
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // "arn:aws:ecs:us-west-1:123456789123:task/10838bed-421f-43ef-870a-f43feacbbb5b",
+ // "arn:aws:ecs:us-west-1:123456789123:task/my-cluster/task-id/23ebb8ac-c18f-46c6-8bbe-d55d0e37cfbd"
+ //
+ // [ECS task]: https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ecs-account-settings.html#ecs-resource-ids
+ AWSECSTaskARNKey = attribute.Key("aws.ecs.task.arn")
+
+ // AWSECSTaskFamilyKey is the attribute Key conforming to the
+ // "aws.ecs.task.family" semantic conventions. It represents the family name of
+ // the [ECS task definition] used to create the ECS task.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "opentelemetry-family"
+ //
+ // [ECS task definition]: https://docs.aws.amazon.com/AmazonECS/latest/developerguide/task_definitions.html
+ AWSECSTaskFamilyKey = attribute.Key("aws.ecs.task.family")
+
+ // AWSECSTaskIDKey is the attribute Key conforming to the "aws.ecs.task.id"
+ // semantic conventions. It represents the ID of a running ECS task. The ID MUST
+ // be extracted from `task.arn`.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "10838bed-421f-43ef-870a-f43feacbbb5b",
+ // "23ebb8ac-c18f-46c6-8bbe-d55d0e37cfbd"
+ AWSECSTaskIDKey = attribute.Key("aws.ecs.task.id")
+
+ // AWSECSTaskRevisionKey is the attribute Key conforming to the
+ // "aws.ecs.task.revision" semantic conventions. It represents the revision for
+ // the task definition used to create the ECS task.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "8", "26"
+ AWSECSTaskRevisionKey = attribute.Key("aws.ecs.task.revision")
+
+ // AWSEKSClusterARNKey is the attribute Key conforming to the
+ // "aws.eks.cluster.arn" semantic conventions. It represents the ARN of an EKS
+ // cluster.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "arn:aws:ecs:us-west-2:123456789123:cluster/my-cluster"
+ AWSEKSClusterARNKey = attribute.Key("aws.eks.cluster.arn")
+
+ // AWSExtendedRequestIDKey is the attribute Key conforming to the
+ // "aws.extended_request_id" semantic conventions. It represents the AWS
+ // extended request ID as returned in the response header `x-amz-id-2`.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // "wzHcyEWfmOGDIE5QOhTAqFDoDWP3y8IUvpNINCwL9N4TEHbUw0/gZJ+VZTmCNCWR7fezEN3eCiQ="
+ AWSExtendedRequestIDKey = attribute.Key("aws.extended_request_id")
+
+ // AWSKinesisStreamNameKey is the attribute Key conforming to the
+ // "aws.kinesis.stream_name" semantic conventions. It represents the name of the
+ // AWS Kinesis [stream] the request refers to. Corresponds to the
+ // `--stream-name` parameter of the Kinesis [describe-stream] operation.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "some-stream-name"
+ //
+ // [stream]: https://docs.aws.amazon.com/streams/latest/dev/introduction.html
+ // [describe-stream]: https://docs.aws.amazon.com/cli/latest/reference/kinesis/describe-stream.html
+ AWSKinesisStreamNameKey = attribute.Key("aws.kinesis.stream_name")
+
+ // AWSLambdaInvokedARNKey is the attribute Key conforming to the
+ // "aws.lambda.invoked_arn" semantic conventions. It represents the full invoked
+ // ARN as provided on the `Context` passed to the function (
+ // `Lambda-Runtime-Invoked-Function-Arn` header on the
+ // `/runtime/invocation/next` applicable).
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "arn:aws:lambda:us-east-1:123456:function:myfunction:myalias"
+ // Note: This may be different from `cloud.resource_id` if an alias is involved.
+ AWSLambdaInvokedARNKey = attribute.Key("aws.lambda.invoked_arn")
+
+ // AWSLambdaResourceMappingIDKey is the attribute Key conforming to the
+ // "aws.lambda.resource_mapping.id" semantic conventions. It represents the UUID
+ // of the [AWS Lambda EvenSource Mapping]. An event source is mapped to a lambda
+ // function. It's contents are read by Lambda and used to trigger a function.
+ // This isn't available in the lambda execution context or the lambda runtime
+ // environtment. This is going to be populated by the AWS SDK for each language
+ // when that UUID is present. Some of these operations are
+ // Create/Delete/Get/List/Update EventSourceMapping.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "587ad24b-03b9-4413-8202-bbd56b36e5b7"
+ //
+ // [AWS Lambda EvenSource Mapping]: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-lambda-eventsourcemapping.html
+ AWSLambdaResourceMappingIDKey = attribute.Key("aws.lambda.resource_mapping.id")
+
+ // AWSLogGroupARNsKey is the attribute Key conforming to the
+ // "aws.log.group.arns" semantic conventions. It represents the Amazon Resource
+ // Name(s) (ARN) of the AWS log group(s).
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "arn:aws:logs:us-west-1:123456789012:log-group:/aws/my/group:*"
+ // Note: See the [log group ARN format documentation].
+ //
+ // [log group ARN format documentation]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/iam-access-control-overview-cwl.html#CWL_ARN_Format
+ AWSLogGroupARNsKey = attribute.Key("aws.log.group.arns")
+
+ // AWSLogGroupNamesKey is the attribute Key conforming to the
+ // "aws.log.group.names" semantic conventions. It represents the name(s) of the
+ // AWS log group(s) an application is writing to.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "/aws/lambda/my-function", "opentelemetry-service"
+ // Note: Multiple log groups must be supported for cases like multi-container
+ // applications, where a single application has sidecar containers, and each
+ // write to their own log group.
+ AWSLogGroupNamesKey = attribute.Key("aws.log.group.names")
+
+ // AWSLogStreamARNsKey is the attribute Key conforming to the
+ // "aws.log.stream.arns" semantic conventions. It represents the ARN(s) of the
+ // AWS log stream(s).
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // "arn:aws:logs:us-west-1:123456789012:log-group:/aws/my/group:log-stream:logs/main/10838bed-421f-43ef-870a-f43feacbbb5b"
+ // Note: See the [log stream ARN format documentation]. One log group can
+ // contain several log streams, so these ARNs necessarily identify both a log
+ // group and a log stream.
+ //
+ // [log stream ARN format documentation]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/iam-access-control-overview-cwl.html#CWL_ARN_Format
+ AWSLogStreamARNsKey = attribute.Key("aws.log.stream.arns")
+
+ // AWSLogStreamNamesKey is the attribute Key conforming to the
+ // "aws.log.stream.names" semantic conventions. It represents the name(s) of the
+ // AWS log stream(s) an application is writing to.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "logs/main/10838bed-421f-43ef-870a-f43feacbbb5b"
+ AWSLogStreamNamesKey = attribute.Key("aws.log.stream.names")
+
+ // AWSRequestIDKey is the attribute Key conforming to the "aws.request_id"
+ // semantic conventions. It represents the AWS request ID as returned in the
+ // response headers `x-amzn-requestid`, `x-amzn-request-id` or
+ // `x-amz-request-id`.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "79b9da39-b7ae-508a-a6bc-864b2829c622", "C9ER4AJX75574TDJ"
+ AWSRequestIDKey = attribute.Key("aws.request_id")
+
+ // AWSS3BucketKey is the attribute Key conforming to the "aws.s3.bucket"
+ // semantic conventions. It represents the S3 bucket name the request refers to.
+ // Corresponds to the `--bucket` parameter of the [S3 API] operations.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "some-bucket-name"
+ // Note: The `bucket` attribute is applicable to all S3 operations that
+ // reference a bucket, i.e. that require the bucket name as a mandatory
+ // parameter.
+ // This applies to almost all S3 operations except `list-buckets`.
+ //
+ // [S3 API]: https://docs.aws.amazon.com/cli/latest/reference/s3api/index.html
+ AWSS3BucketKey = attribute.Key("aws.s3.bucket")
+
+ // AWSS3CopySourceKey is the attribute Key conforming to the
+ // "aws.s3.copy_source" semantic conventions. It represents the source object
+ // (in the form `bucket`/`key`) for the copy operation.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "someFile.yml"
+ // Note: The `copy_source` attribute applies to S3 copy operations and
+ // corresponds to the `--copy-source` parameter
+ // of the [copy-object operation within the S3 API].
+ // This applies in particular to the following operations:
+ //
+ // - [copy-object]
+ // - [upload-part-copy]
+ //
+ //
+ // [copy-object operation within the S3 API]: https://docs.aws.amazon.com/cli/latest/reference/s3api/copy-object.html
+ // [copy-object]: https://docs.aws.amazon.com/cli/latest/reference/s3api/copy-object.html
+ // [upload-part-copy]: https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part-copy.html
+ AWSS3CopySourceKey = attribute.Key("aws.s3.copy_source")
+
+ // AWSS3DeleteKey is the attribute Key conforming to the "aws.s3.delete"
+ // semantic conventions. It represents the delete request container that
+ // specifies the objects to be deleted.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // "Objects=[{Key=string,VersionId=string},{Key=string,VersionId=string}],Quiet=boolean"
+ // Note: The `delete` attribute is only applicable to the [delete-object]
+ // operation.
+ // The `delete` attribute corresponds to the `--delete` parameter of the
+ // [delete-objects operation within the S3 API].
+ //
+ // [delete-object]: https://docs.aws.amazon.com/cli/latest/reference/s3api/delete-object.html
+ // [delete-objects operation within the S3 API]: https://docs.aws.amazon.com/cli/latest/reference/s3api/delete-objects.html
+ AWSS3DeleteKey = attribute.Key("aws.s3.delete")
+
+ // AWSS3KeyKey is the attribute Key conforming to the "aws.s3.key" semantic
+ // conventions. It represents the S3 object key the request refers to.
+ // Corresponds to the `--key` parameter of the [S3 API] operations.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "someFile.yml"
+ // Note: The `key` attribute is applicable to all object-related S3 operations,
+ // i.e. that require the object key as a mandatory parameter.
+ // This applies in particular to the following operations:
+ //
+ // - [copy-object]
+ // - [delete-object]
+ // - [get-object]
+ // - [head-object]
+ // - [put-object]
+ // - [restore-object]
+ // - [select-object-content]
+ // - [abort-multipart-upload]
+ // - [complete-multipart-upload]
+ // - [create-multipart-upload]
+ // - [list-parts]
+ // - [upload-part]
+ // - [upload-part-copy]
+ //
+ //
+ // [S3 API]: https://docs.aws.amazon.com/cli/latest/reference/s3api/index.html
+ // [copy-object]: https://docs.aws.amazon.com/cli/latest/reference/s3api/copy-object.html
+ // [delete-object]: https://docs.aws.amazon.com/cli/latest/reference/s3api/delete-object.html
+ // [get-object]: https://docs.aws.amazon.com/cli/latest/reference/s3api/get-object.html
+ // [head-object]: https://docs.aws.amazon.com/cli/latest/reference/s3api/head-object.html
+ // [put-object]: https://docs.aws.amazon.com/cli/latest/reference/s3api/put-object.html
+ // [restore-object]: https://docs.aws.amazon.com/cli/latest/reference/s3api/restore-object.html
+ // [select-object-content]: https://docs.aws.amazon.com/cli/latest/reference/s3api/select-object-content.html
+ // [abort-multipart-upload]: https://docs.aws.amazon.com/cli/latest/reference/s3api/abort-multipart-upload.html
+ // [complete-multipart-upload]: https://docs.aws.amazon.com/cli/latest/reference/s3api/complete-multipart-upload.html
+ // [create-multipart-upload]: https://docs.aws.amazon.com/cli/latest/reference/s3api/create-multipart-upload.html
+ // [list-parts]: https://docs.aws.amazon.com/cli/latest/reference/s3api/list-parts.html
+ // [upload-part]: https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part.html
+ // [upload-part-copy]: https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part-copy.html
+ AWSS3KeyKey = attribute.Key("aws.s3.key")
+
+ // AWSS3PartNumberKey is the attribute Key conforming to the
+ // "aws.s3.part_number" semantic conventions. It represents the part number of
+ // the part being uploaded in a multipart-upload operation. This is a positive
+ // integer between 1 and 10,000.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 3456
+ // Note: The `part_number` attribute is only applicable to the [upload-part]
+ // and [upload-part-copy] operations.
+ // The `part_number` attribute corresponds to the `--part-number` parameter of
+ // the
+ // [upload-part operation within the S3 API].
+ //
+ // [upload-part]: https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part.html
+ // [upload-part-copy]: https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part-copy.html
+ // [upload-part operation within the S3 API]: https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part.html
+ AWSS3PartNumberKey = attribute.Key("aws.s3.part_number")
+
+ // AWSS3UploadIDKey is the attribute Key conforming to the "aws.s3.upload_id"
+ // semantic conventions. It represents the upload ID that identifies the
+ // multipart upload.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "dfRtDYWFbkRONycy.Yxwh66Yjlx.cph0gtNBtJ"
+ // Note: The `upload_id` attribute applies to S3 multipart-upload operations and
+ // corresponds to the `--upload-id` parameter
+ // of the [S3 API] multipart operations.
+ // This applies in particular to the following operations:
+ //
+ // - [abort-multipart-upload]
+ // - [complete-multipart-upload]
+ // - [list-parts]
+ // - [upload-part]
+ // - [upload-part-copy]
+ //
+ //
+ // [S3 API]: https://docs.aws.amazon.com/cli/latest/reference/s3api/index.html
+ // [abort-multipart-upload]: https://docs.aws.amazon.com/cli/latest/reference/s3api/abort-multipart-upload.html
+ // [complete-multipart-upload]: https://docs.aws.amazon.com/cli/latest/reference/s3api/complete-multipart-upload.html
+ // [list-parts]: https://docs.aws.amazon.com/cli/latest/reference/s3api/list-parts.html
+ // [upload-part]: https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part.html
+ // [upload-part-copy]: https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part-copy.html
+ AWSS3UploadIDKey = attribute.Key("aws.s3.upload_id")
+
+ // AWSSecretsmanagerSecretARNKey is the attribute Key conforming to the
+ // "aws.secretsmanager.secret.arn" semantic conventions. It represents the ARN
+ // of the Secret stored in the Secrets Mangger.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // "arn:aws:secretsmanager:us-east-1:123456789012:secret:SecretName-6RandomCharacters"
+ AWSSecretsmanagerSecretARNKey = attribute.Key("aws.secretsmanager.secret.arn")
+
+ // AWSSNSTopicARNKey is the attribute Key conforming to the "aws.sns.topic.arn"
+ // semantic conventions. It represents the ARN of the AWS SNS Topic. An Amazon
+ // SNS [topic] is a logical access point that acts as a communication channel.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "arn:aws:sns:us-east-1:123456789012:mystack-mytopic-NZJ5JSMVGFIE"
+ //
+ // [topic]: https://docs.aws.amazon.com/sns/latest/dg/sns-create-topic.html
+ AWSSNSTopicARNKey = attribute.Key("aws.sns.topic.arn")
+
+ // AWSSQSQueueURLKey is the attribute Key conforming to the "aws.sqs.queue.url"
+ // semantic conventions. It represents the URL of the AWS SQS Queue. It's a
+ // unique identifier for a queue in Amazon Simple Queue Service (SQS) and is
+ // used to access the queue and perform actions on it.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "https://sqs.us-east-1.amazonaws.com/123456789012/MyQueue"
+ AWSSQSQueueURLKey = attribute.Key("aws.sqs.queue.url")
+
+ // AWSStepFunctionsActivityARNKey is the attribute Key conforming to the
+ // "aws.step_functions.activity.arn" semantic conventions. It represents the ARN
+ // of the AWS Step Functions Activity.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "arn:aws:states:us-east-1:123456789012:activity:get-greeting"
+ AWSStepFunctionsActivityARNKey = attribute.Key("aws.step_functions.activity.arn")
+
+ // AWSStepFunctionsStateMachineARNKey is the attribute Key conforming to the
+ // "aws.step_functions.state_machine.arn" semantic conventions. It represents
+ // the ARN of the AWS Step Functions State Machine.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // "arn:aws:states:us-east-1:123456789012:stateMachine:myStateMachine:1"
+ AWSStepFunctionsStateMachineARNKey = attribute.Key("aws.step_functions.state_machine.arn")
+)
+
+// AWSBedrockGuardrailID returns an attribute KeyValue conforming to the
+// "aws.bedrock.guardrail.id" semantic conventions. It represents the unique
+// identifier of the AWS Bedrock Guardrail. A [guardrail] helps safeguard and
+// prevent unwanted behavior from model responses or user messages.
+//
+// [guardrail]: https://docs.aws.amazon.com/bedrock/latest/userguide/guardrails.html
+func AWSBedrockGuardrailID(val string) attribute.KeyValue {
+ return AWSBedrockGuardrailIDKey.String(val)
+}
+
+// AWSBedrockKnowledgeBaseID returns an attribute KeyValue conforming to the
+// "aws.bedrock.knowledge_base.id" semantic conventions. It represents the unique
+// identifier of the AWS Bedrock Knowledge base. A [knowledge base] is a bank of
+// information that can be queried by models to generate more relevant responses
+// and augment prompts.
+//
+// [knowledge base]: https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base.html
+func AWSBedrockKnowledgeBaseID(val string) attribute.KeyValue {
+ return AWSBedrockKnowledgeBaseIDKey.String(val)
+}
+
+// AWSDynamoDBAttributeDefinitions returns an attribute KeyValue conforming to
+// the "aws.dynamodb.attribute_definitions" semantic conventions. It represents
+// the JSON-serialized value of each item in the `AttributeDefinitions` request
+// field.
+func AWSDynamoDBAttributeDefinitions(val ...string) attribute.KeyValue {
+ return AWSDynamoDBAttributeDefinitionsKey.StringSlice(val)
+}
+
+// AWSDynamoDBAttributesToGet returns an attribute KeyValue conforming to the
+// "aws.dynamodb.attributes_to_get" semantic conventions. It represents the value
+// of the `AttributesToGet` request parameter.
+func AWSDynamoDBAttributesToGet(val ...string) attribute.KeyValue {
+ return AWSDynamoDBAttributesToGetKey.StringSlice(val)
+}
+
+// AWSDynamoDBConsistentRead returns an attribute KeyValue conforming to the
+// "aws.dynamodb.consistent_read" semantic conventions. It represents the value
+// of the `ConsistentRead` request parameter.
+func AWSDynamoDBConsistentRead(val bool) attribute.KeyValue {
+ return AWSDynamoDBConsistentReadKey.Bool(val)
+}
+
+// AWSDynamoDBConsumedCapacity returns an attribute KeyValue conforming to the
+// "aws.dynamodb.consumed_capacity" semantic conventions. It represents the
+// JSON-serialized value of each item in the `ConsumedCapacity` response field.
+func AWSDynamoDBConsumedCapacity(val ...string) attribute.KeyValue {
+ return AWSDynamoDBConsumedCapacityKey.StringSlice(val)
+}
+
+// AWSDynamoDBCount returns an attribute KeyValue conforming to the
+// "aws.dynamodb.count" semantic conventions. It represents the value of the
+// `Count` response parameter.
+func AWSDynamoDBCount(val int) attribute.KeyValue {
+ return AWSDynamoDBCountKey.Int(val)
+}
+
+// AWSDynamoDBExclusiveStartTable returns an attribute KeyValue conforming to the
+// "aws.dynamodb.exclusive_start_table" semantic conventions. It represents the
+// value of the `ExclusiveStartTableName` request parameter.
+func AWSDynamoDBExclusiveStartTable(val string) attribute.KeyValue {
+ return AWSDynamoDBExclusiveStartTableKey.String(val)
+}
+
+// AWSDynamoDBGlobalSecondaryIndexUpdates returns an attribute KeyValue
+// conforming to the "aws.dynamodb.global_secondary_index_updates" semantic
+// conventions. It represents the JSON-serialized value of each item in the
+// `GlobalSecondaryIndexUpdates` request field.
+func AWSDynamoDBGlobalSecondaryIndexUpdates(val ...string) attribute.KeyValue {
+ return AWSDynamoDBGlobalSecondaryIndexUpdatesKey.StringSlice(val)
+}
+
+// AWSDynamoDBGlobalSecondaryIndexes returns an attribute KeyValue conforming to
+// the "aws.dynamodb.global_secondary_indexes" semantic conventions. It
+// represents the JSON-serialized value of each item of the
+// `GlobalSecondaryIndexes` request field.
+func AWSDynamoDBGlobalSecondaryIndexes(val ...string) attribute.KeyValue {
+ return AWSDynamoDBGlobalSecondaryIndexesKey.StringSlice(val)
+}
+
+// AWSDynamoDBIndexName returns an attribute KeyValue conforming to the
+// "aws.dynamodb.index_name" semantic conventions. It represents the value of the
+// `IndexName` request parameter.
+func AWSDynamoDBIndexName(val string) attribute.KeyValue {
+ return AWSDynamoDBIndexNameKey.String(val)
+}
+
+// AWSDynamoDBItemCollectionMetrics returns an attribute KeyValue conforming to
+// the "aws.dynamodb.item_collection_metrics" semantic conventions. It represents
+// the JSON-serialized value of the `ItemCollectionMetrics` response field.
+func AWSDynamoDBItemCollectionMetrics(val string) attribute.KeyValue {
+ return AWSDynamoDBItemCollectionMetricsKey.String(val)
+}
+
+// AWSDynamoDBLimit returns an attribute KeyValue conforming to the
+// "aws.dynamodb.limit" semantic conventions. It represents the value of the
+// `Limit` request parameter.
+func AWSDynamoDBLimit(val int) attribute.KeyValue {
+ return AWSDynamoDBLimitKey.Int(val)
+}
+
+// AWSDynamoDBLocalSecondaryIndexes returns an attribute KeyValue conforming to
+// the "aws.dynamodb.local_secondary_indexes" semantic conventions. It represents
+// the JSON-serialized value of each item of the `LocalSecondaryIndexes` request
+// field.
+func AWSDynamoDBLocalSecondaryIndexes(val ...string) attribute.KeyValue {
+ return AWSDynamoDBLocalSecondaryIndexesKey.StringSlice(val)
+}
+
+// AWSDynamoDBProjection returns an attribute KeyValue conforming to the
+// "aws.dynamodb.projection" semantic conventions. It represents the value of the
+// `ProjectionExpression` request parameter.
+func AWSDynamoDBProjection(val string) attribute.KeyValue {
+ return AWSDynamoDBProjectionKey.String(val)
+}
+
+// AWSDynamoDBProvisionedReadCapacity returns an attribute KeyValue conforming to
+// the "aws.dynamodb.provisioned_read_capacity" semantic conventions. It
+// represents the value of the `ProvisionedThroughput.ReadCapacityUnits` request
+// parameter.
+func AWSDynamoDBProvisionedReadCapacity(val float64) attribute.KeyValue {
+ return AWSDynamoDBProvisionedReadCapacityKey.Float64(val)
+}
+
+// AWSDynamoDBProvisionedWriteCapacity returns an attribute KeyValue conforming
+// to the "aws.dynamodb.provisioned_write_capacity" semantic conventions. It
+// represents the value of the `ProvisionedThroughput.WriteCapacityUnits` request
+// parameter.
+func AWSDynamoDBProvisionedWriteCapacity(val float64) attribute.KeyValue {
+ return AWSDynamoDBProvisionedWriteCapacityKey.Float64(val)
+}
+
+// AWSDynamoDBScanForward returns an attribute KeyValue conforming to the
+// "aws.dynamodb.scan_forward" semantic conventions. It represents the value of
+// the `ScanIndexForward` request parameter.
+func AWSDynamoDBScanForward(val bool) attribute.KeyValue {
+ return AWSDynamoDBScanForwardKey.Bool(val)
+}
+
+// AWSDynamoDBScannedCount returns an attribute KeyValue conforming to the
+// "aws.dynamodb.scanned_count" semantic conventions. It represents the value of
+// the `ScannedCount` response parameter.
+func AWSDynamoDBScannedCount(val int) attribute.KeyValue {
+ return AWSDynamoDBScannedCountKey.Int(val)
+}
+
+// AWSDynamoDBSegment returns an attribute KeyValue conforming to the
+// "aws.dynamodb.segment" semantic conventions. It represents the value of the
+// `Segment` request parameter.
+func AWSDynamoDBSegment(val int) attribute.KeyValue {
+ return AWSDynamoDBSegmentKey.Int(val)
+}
+
+// AWSDynamoDBSelect returns an attribute KeyValue conforming to the
+// "aws.dynamodb.select" semantic conventions. It represents the value of the
+// `Select` request parameter.
+func AWSDynamoDBSelect(val string) attribute.KeyValue {
+ return AWSDynamoDBSelectKey.String(val)
+}
+
+// AWSDynamoDBTableCount returns an attribute KeyValue conforming to the
+// "aws.dynamodb.table_count" semantic conventions. It represents the number of
+// items in the `TableNames` response parameter.
+func AWSDynamoDBTableCount(val int) attribute.KeyValue {
+ return AWSDynamoDBTableCountKey.Int(val)
+}
+
+// AWSDynamoDBTableNames returns an attribute KeyValue conforming to the
+// "aws.dynamodb.table_names" semantic conventions. It represents the keys in the
+// `RequestItems` object field.
+func AWSDynamoDBTableNames(val ...string) attribute.KeyValue {
+ return AWSDynamoDBTableNamesKey.StringSlice(val)
+}
+
+// AWSDynamoDBTotalSegments returns an attribute KeyValue conforming to the
+// "aws.dynamodb.total_segments" semantic conventions. It represents the value of
+// the `TotalSegments` request parameter.
+func AWSDynamoDBTotalSegments(val int) attribute.KeyValue {
+ return AWSDynamoDBTotalSegmentsKey.Int(val)
+}
+
+// AWSECSClusterARN returns an attribute KeyValue conforming to the
+// "aws.ecs.cluster.arn" semantic conventions. It represents the ARN of an
+// [ECS cluster].
+//
+// [ECS cluster]: https://docs.aws.amazon.com/AmazonECS/latest/developerguide/clusters.html
+func AWSECSClusterARN(val string) attribute.KeyValue {
+ return AWSECSClusterARNKey.String(val)
+}
+
+// AWSECSContainerARN returns an attribute KeyValue conforming to the
+// "aws.ecs.container.arn" semantic conventions. It represents the Amazon
+// Resource Name (ARN) of an [ECS container instance].
+//
+// [ECS container instance]: https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ECS_instances.html
+func AWSECSContainerARN(val string) attribute.KeyValue {
+ return AWSECSContainerARNKey.String(val)
+}
+
+// AWSECSTaskARN returns an attribute KeyValue conforming to the
+// "aws.ecs.task.arn" semantic conventions. It represents the ARN of a running
+// [ECS task].
+//
+// [ECS task]: https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ecs-account-settings.html#ecs-resource-ids
+func AWSECSTaskARN(val string) attribute.KeyValue {
+ return AWSECSTaskARNKey.String(val)
+}
+
+// AWSECSTaskFamily returns an attribute KeyValue conforming to the
+// "aws.ecs.task.family" semantic conventions. It represents the family name of
+// the [ECS task definition] used to create the ECS task.
+//
+// [ECS task definition]: https://docs.aws.amazon.com/AmazonECS/latest/developerguide/task_definitions.html
+func AWSECSTaskFamily(val string) attribute.KeyValue {
+ return AWSECSTaskFamilyKey.String(val)
+}
+
+// AWSECSTaskID returns an attribute KeyValue conforming to the "aws.ecs.task.id"
+// semantic conventions. It represents the ID of a running ECS task. The ID MUST
+// be extracted from `task.arn`.
+func AWSECSTaskID(val string) attribute.KeyValue {
+ return AWSECSTaskIDKey.String(val)
+}
+
+// AWSECSTaskRevision returns an attribute KeyValue conforming to the
+// "aws.ecs.task.revision" semantic conventions. It represents the revision for
+// the task definition used to create the ECS task.
+func AWSECSTaskRevision(val string) attribute.KeyValue {
+ return AWSECSTaskRevisionKey.String(val)
+}
+
+// AWSEKSClusterARN returns an attribute KeyValue conforming to the
+// "aws.eks.cluster.arn" semantic conventions. It represents the ARN of an EKS
+// cluster.
+func AWSEKSClusterARN(val string) attribute.KeyValue {
+ return AWSEKSClusterARNKey.String(val)
+}
+
+// AWSExtendedRequestID returns an attribute KeyValue conforming to the
+// "aws.extended_request_id" semantic conventions. It represents the AWS extended
+// request ID as returned in the response header `x-amz-id-2`.
+func AWSExtendedRequestID(val string) attribute.KeyValue {
+ return AWSExtendedRequestIDKey.String(val)
+}
+
+// AWSKinesisStreamName returns an attribute KeyValue conforming to the
+// "aws.kinesis.stream_name" semantic conventions. It represents the name of the
+// AWS Kinesis [stream] the request refers to. Corresponds to the `--stream-name`
+// parameter of the Kinesis [describe-stream] operation.
+//
+// [stream]: https://docs.aws.amazon.com/streams/latest/dev/introduction.html
+// [describe-stream]: https://docs.aws.amazon.com/cli/latest/reference/kinesis/describe-stream.html
+func AWSKinesisStreamName(val string) attribute.KeyValue {
+ return AWSKinesisStreamNameKey.String(val)
+}
+
+// AWSLambdaInvokedARN returns an attribute KeyValue conforming to the
+// "aws.lambda.invoked_arn" semantic conventions. It represents the full invoked
+// ARN as provided on the `Context` passed to the function (
+// `Lambda-Runtime-Invoked-Function-Arn` header on the `/runtime/invocation/next`
+// applicable).
+func AWSLambdaInvokedARN(val string) attribute.KeyValue {
+ return AWSLambdaInvokedARNKey.String(val)
+}
+
+// AWSLambdaResourceMappingID returns an attribute KeyValue conforming to the
+// "aws.lambda.resource_mapping.id" semantic conventions. It represents the UUID
+// of the [AWS Lambda EvenSource Mapping]. An event source is mapped to a lambda
+// function. It's contents are read by Lambda and used to trigger a function.
+// This isn't available in the lambda execution context or the lambda runtime
+// environtment. This is going to be populated by the AWS SDK for each language
+// when that UUID is present. Some of these operations are
+// Create/Delete/Get/List/Update EventSourceMapping.
+//
+// [AWS Lambda EvenSource Mapping]: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-lambda-eventsourcemapping.html
+func AWSLambdaResourceMappingID(val string) attribute.KeyValue {
+ return AWSLambdaResourceMappingIDKey.String(val)
+}
+
+// AWSLogGroupARNs returns an attribute KeyValue conforming to the
+// "aws.log.group.arns" semantic conventions. It represents the Amazon Resource
+// Name(s) (ARN) of the AWS log group(s).
+func AWSLogGroupARNs(val ...string) attribute.KeyValue {
+ return AWSLogGroupARNsKey.StringSlice(val)
+}
+
+// AWSLogGroupNames returns an attribute KeyValue conforming to the
+// "aws.log.group.names" semantic conventions. It represents the name(s) of the
+// AWS log group(s) an application is writing to.
+func AWSLogGroupNames(val ...string) attribute.KeyValue {
+ return AWSLogGroupNamesKey.StringSlice(val)
+}
+
+// AWSLogStreamARNs returns an attribute KeyValue conforming to the
+// "aws.log.stream.arns" semantic conventions. It represents the ARN(s) of the
+// AWS log stream(s).
+func AWSLogStreamARNs(val ...string) attribute.KeyValue {
+ return AWSLogStreamARNsKey.StringSlice(val)
+}
+
+// AWSLogStreamNames returns an attribute KeyValue conforming to the
+// "aws.log.stream.names" semantic conventions. It represents the name(s) of the
+// AWS log stream(s) an application is writing to.
+func AWSLogStreamNames(val ...string) attribute.KeyValue {
+ return AWSLogStreamNamesKey.StringSlice(val)
+}
+
+// AWSRequestID returns an attribute KeyValue conforming to the "aws.request_id"
+// semantic conventions. It represents the AWS request ID as returned in the
+// response headers `x-amzn-requestid`, `x-amzn-request-id` or `x-amz-request-id`
+// .
+func AWSRequestID(val string) attribute.KeyValue {
+ return AWSRequestIDKey.String(val)
+}
+
+// AWSS3Bucket returns an attribute KeyValue conforming to the "aws.s3.bucket"
+// semantic conventions. It represents the S3 bucket name the request refers to.
+// Corresponds to the `--bucket` parameter of the [S3 API] operations.
+//
+// [S3 API]: https://docs.aws.amazon.com/cli/latest/reference/s3api/index.html
+func AWSS3Bucket(val string) attribute.KeyValue {
+ return AWSS3BucketKey.String(val)
+}
+
+// AWSS3CopySource returns an attribute KeyValue conforming to the
+// "aws.s3.copy_source" semantic conventions. It represents the source object (in
+// the form `bucket`/`key`) for the copy operation.
+func AWSS3CopySource(val string) attribute.KeyValue {
+ return AWSS3CopySourceKey.String(val)
+}
+
+// AWSS3Delete returns an attribute KeyValue conforming to the "aws.s3.delete"
+// semantic conventions. It represents the delete request container that
+// specifies the objects to be deleted.
+func AWSS3Delete(val string) attribute.KeyValue {
+ return AWSS3DeleteKey.String(val)
+}
+
+// AWSS3Key returns an attribute KeyValue conforming to the "aws.s3.key" semantic
+// conventions. It represents the S3 object key the request refers to.
+// Corresponds to the `--key` parameter of the [S3 API] operations.
+//
+// [S3 API]: https://docs.aws.amazon.com/cli/latest/reference/s3api/index.html
+func AWSS3Key(val string) attribute.KeyValue {
+ return AWSS3KeyKey.String(val)
+}
+
+// AWSS3PartNumber returns an attribute KeyValue conforming to the
+// "aws.s3.part_number" semantic conventions. It represents the part number of
+// the part being uploaded in a multipart-upload operation. This is a positive
+// integer between 1 and 10,000.
+func AWSS3PartNumber(val int) attribute.KeyValue {
+ return AWSS3PartNumberKey.Int(val)
+}
+
+// AWSS3UploadID returns an attribute KeyValue conforming to the
+// "aws.s3.upload_id" semantic conventions. It represents the upload ID that
+// identifies the multipart upload.
+func AWSS3UploadID(val string) attribute.KeyValue {
+ return AWSS3UploadIDKey.String(val)
+}
+
+// AWSSecretsmanagerSecretARN returns an attribute KeyValue conforming to the
+// "aws.secretsmanager.secret.arn" semantic conventions. It represents the ARN of
+// the Secret stored in the Secrets Mangger.
+func AWSSecretsmanagerSecretARN(val string) attribute.KeyValue {
+ return AWSSecretsmanagerSecretARNKey.String(val)
+}
+
+// AWSSNSTopicARN returns an attribute KeyValue conforming to the
+// "aws.sns.topic.arn" semantic conventions. It represents the ARN of the AWS SNS
+// Topic. An Amazon SNS [topic] is a logical access point that acts as a
+// communication channel.
+//
+// [topic]: https://docs.aws.amazon.com/sns/latest/dg/sns-create-topic.html
+func AWSSNSTopicARN(val string) attribute.KeyValue {
+ return AWSSNSTopicARNKey.String(val)
+}
+
+// AWSSQSQueueURL returns an attribute KeyValue conforming to the
+// "aws.sqs.queue.url" semantic conventions. It represents the URL of the AWS SQS
+// Queue. It's a unique identifier for a queue in Amazon Simple Queue Service
+// (SQS) and is used to access the queue and perform actions on it.
+func AWSSQSQueueURL(val string) attribute.KeyValue {
+ return AWSSQSQueueURLKey.String(val)
+}
+
+// AWSStepFunctionsActivityARN returns an attribute KeyValue conforming to the
+// "aws.step_functions.activity.arn" semantic conventions. It represents the ARN
+// of the AWS Step Functions Activity.
+func AWSStepFunctionsActivityARN(val string) attribute.KeyValue {
+ return AWSStepFunctionsActivityARNKey.String(val)
+}
+
+// AWSStepFunctionsStateMachineARN returns an attribute KeyValue conforming to
+// the "aws.step_functions.state_machine.arn" semantic conventions. It represents
+// the ARN of the AWS Step Functions State Machine.
+func AWSStepFunctionsStateMachineARN(val string) attribute.KeyValue {
+ return AWSStepFunctionsStateMachineARNKey.String(val)
+}
+
+// Enum values for aws.ecs.launchtype
+var (
+ // Amazon EC2
+ // Stability: development
+ AWSECSLaunchtypeEC2 = AWSECSLaunchtypeKey.String("ec2")
+ // Amazon Fargate
+ // Stability: development
+ AWSECSLaunchtypeFargate = AWSECSLaunchtypeKey.String("fargate")
+)
+
+// Namespace: azure
+const (
+ // AzureClientIDKey is the attribute Key conforming to the "azure.client.id"
+ // semantic conventions. It represents the unique identifier of the client
+ // instance.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "3ba4827d-4422-483f-b59f-85b74211c11d", "storage-client-1"
+ AzureClientIDKey = attribute.Key("azure.client.id")
+
+ // AzureCosmosDBConnectionModeKey is the attribute Key conforming to the
+ // "azure.cosmosdb.connection.mode" semantic conventions. It represents the
+ // cosmos client connection mode.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ AzureCosmosDBConnectionModeKey = attribute.Key("azure.cosmosdb.connection.mode")
+
+ // AzureCosmosDBConsistencyLevelKey is the attribute Key conforming to the
+ // "azure.cosmosdb.consistency.level" semantic conventions. It represents the
+ // account or request [consistency level].
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Eventual", "ConsistentPrefix", "BoundedStaleness", "Strong",
+ // "Session"
+ //
+ // [consistency level]: https://learn.microsoft.com/azure/cosmos-db/consistency-levels
+ AzureCosmosDBConsistencyLevelKey = attribute.Key("azure.cosmosdb.consistency.level")
+
+ // AzureCosmosDBOperationContactedRegionsKey is the attribute Key conforming to
+ // the "azure.cosmosdb.operation.contacted_regions" semantic conventions. It
+ // represents the list of regions contacted during operation in the order that
+ // they were contacted. If there is more than one region listed, it indicates
+ // that the operation was performed on multiple regions i.e. cross-regional
+ // call.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "North Central US", "Australia East", "Australia Southeast"
+ // Note: Region name matches the format of `displayName` in [Azure Location API]
+ //
+ // [Azure Location API]: https://learn.microsoft.com/rest/api/subscription/subscriptions/list-locations?view=rest-subscription-2021-10-01&tabs=HTTP#location
+ AzureCosmosDBOperationContactedRegionsKey = attribute.Key("azure.cosmosdb.operation.contacted_regions")
+
+ // AzureCosmosDBOperationRequestChargeKey is the attribute Key conforming to the
+ // "azure.cosmosdb.operation.request_charge" semantic conventions. It represents
+ // the number of request units consumed by the operation.
+ //
+ // Type: double
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 46.18, 1.0
+ AzureCosmosDBOperationRequestChargeKey = attribute.Key("azure.cosmosdb.operation.request_charge")
+
+ // AzureCosmosDBRequestBodySizeKey is the attribute Key conforming to the
+ // "azure.cosmosdb.request.body.size" semantic conventions. It represents the
+ // request payload size in bytes.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ AzureCosmosDBRequestBodySizeKey = attribute.Key("azure.cosmosdb.request.body.size")
+
+ // AzureCosmosDBResponseSubStatusCodeKey is the attribute Key conforming to the
+ // "azure.cosmosdb.response.sub_status_code" semantic conventions. It represents
+ // the cosmos DB sub status code.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 1000, 1002
+ AzureCosmosDBResponseSubStatusCodeKey = attribute.Key("azure.cosmosdb.response.sub_status_code")
+
+ // AzureResourceProviderNamespaceKey is the attribute Key conforming to the
+ // "azure.resource_provider.namespace" semantic conventions. It represents the
+ // [Azure Resource Provider Namespace] as recognized by the client.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Microsoft.Storage", "Microsoft.KeyVault", "Microsoft.ServiceBus"
+ //
+ // [Azure Resource Provider Namespace]: https://learn.microsoft.com/azure/azure-resource-manager/management/azure-services-resource-providers
+ AzureResourceProviderNamespaceKey = attribute.Key("azure.resource_provider.namespace")
+
+ // AzureServiceRequestIDKey is the attribute Key conforming to the
+ // "azure.service.request.id" semantic conventions. It represents the unique
+ // identifier of the service request. It's generated by the Azure service and
+ // returned with the response.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "00000000-0000-0000-0000-000000000000"
+ AzureServiceRequestIDKey = attribute.Key("azure.service.request.id")
+)
+
+// AzureClientID returns an attribute KeyValue conforming to the
+// "azure.client.id" semantic conventions. It represents the unique identifier of
+// the client instance.
+func AzureClientID(val string) attribute.KeyValue {
+ return AzureClientIDKey.String(val)
+}
+
+// AzureCosmosDBOperationContactedRegions returns an attribute KeyValue
+// conforming to the "azure.cosmosdb.operation.contacted_regions" semantic
+// conventions. It represents the list of regions contacted during operation in
+// the order that they were contacted. If there is more than one region listed,
+// it indicates that the operation was performed on multiple regions i.e.
+// cross-regional call.
+func AzureCosmosDBOperationContactedRegions(val ...string) attribute.KeyValue {
+ return AzureCosmosDBOperationContactedRegionsKey.StringSlice(val)
+}
+
+// AzureCosmosDBOperationRequestCharge returns an attribute KeyValue conforming
+// to the "azure.cosmosdb.operation.request_charge" semantic conventions. It
+// represents the number of request units consumed by the operation.
+func AzureCosmosDBOperationRequestCharge(val float64) attribute.KeyValue {
+ return AzureCosmosDBOperationRequestChargeKey.Float64(val)
+}
+
+// AzureCosmosDBRequestBodySize returns an attribute KeyValue conforming to the
+// "azure.cosmosdb.request.body.size" semantic conventions. It represents the
+// request payload size in bytes.
+func AzureCosmosDBRequestBodySize(val int) attribute.KeyValue {
+ return AzureCosmosDBRequestBodySizeKey.Int(val)
+}
+
+// AzureCosmosDBResponseSubStatusCode returns an attribute KeyValue conforming to
+// the "azure.cosmosdb.response.sub_status_code" semantic conventions. It
+// represents the cosmos DB sub status code.
+func AzureCosmosDBResponseSubStatusCode(val int) attribute.KeyValue {
+ return AzureCosmosDBResponseSubStatusCodeKey.Int(val)
+}
+
+// AzureResourceProviderNamespace returns an attribute KeyValue conforming to the
+// "azure.resource_provider.namespace" semantic conventions. It represents the
+// [Azure Resource Provider Namespace] as recognized by the client.
+//
+// [Azure Resource Provider Namespace]: https://learn.microsoft.com/azure/azure-resource-manager/management/azure-services-resource-providers
+func AzureResourceProviderNamespace(val string) attribute.KeyValue {
+ return AzureResourceProviderNamespaceKey.String(val)
+}
+
+// AzureServiceRequestID returns an attribute KeyValue conforming to the
+// "azure.service.request.id" semantic conventions. It represents the unique
+// identifier of the service request. It's generated by the Azure service and
+// returned with the response.
+func AzureServiceRequestID(val string) attribute.KeyValue {
+ return AzureServiceRequestIDKey.String(val)
+}
+
+// Enum values for azure.cosmosdb.connection.mode
+var (
+ // Gateway (HTTP) connection.
+ // Stability: development
+ AzureCosmosDBConnectionModeGateway = AzureCosmosDBConnectionModeKey.String("gateway")
+ // Direct connection.
+ // Stability: development
+ AzureCosmosDBConnectionModeDirect = AzureCosmosDBConnectionModeKey.String("direct")
+)
+
+// Enum values for azure.cosmosdb.consistency.level
+var (
+ // Strong
+ // Stability: development
+ AzureCosmosDBConsistencyLevelStrong = AzureCosmosDBConsistencyLevelKey.String("Strong")
+ // Bounded Staleness
+ // Stability: development
+ AzureCosmosDBConsistencyLevelBoundedStaleness = AzureCosmosDBConsistencyLevelKey.String("BoundedStaleness")
+ // Session
+ // Stability: development
+ AzureCosmosDBConsistencyLevelSession = AzureCosmosDBConsistencyLevelKey.String("Session")
+ // Eventual
+ // Stability: development
+ AzureCosmosDBConsistencyLevelEventual = AzureCosmosDBConsistencyLevelKey.String("Eventual")
+ // Consistent Prefix
+ // Stability: development
+ AzureCosmosDBConsistencyLevelConsistentPrefix = AzureCosmosDBConsistencyLevelKey.String("ConsistentPrefix")
+)
+
+// Namespace: browser
+const (
+ // BrowserBrandsKey is the attribute Key conforming to the "browser.brands"
+ // semantic conventions. It represents the array of brand name and version
+ // separated by a space.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: " Not A;Brand 99", "Chromium 99", "Chrome 99"
+ // Note: This value is intended to be taken from the [UA client hints API] (
+ // `navigator.userAgentData.brands`).
+ //
+ // [UA client hints API]: https://wicg.github.io/ua-client-hints/#interface
+ BrowserBrandsKey = attribute.Key("browser.brands")
+
+ // BrowserLanguageKey is the attribute Key conforming to the "browser.language"
+ // semantic conventions. It represents the preferred language of the user using
+ // the browser.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "en", "en-US", "fr", "fr-FR"
+ // Note: This value is intended to be taken from the Navigator API
+ // `navigator.language`.
+ BrowserLanguageKey = attribute.Key("browser.language")
+
+ // BrowserMobileKey is the attribute Key conforming to the "browser.mobile"
+ // semantic conventions. It represents a boolean that is true if the browser is
+ // running on a mobile device.
+ //
+ // Type: boolean
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // Note: This value is intended to be taken from the [UA client hints API] (
+ // `navigator.userAgentData.mobile`). If unavailable, this attribute SHOULD be
+ // left unset.
+ //
+ // [UA client hints API]: https://wicg.github.io/ua-client-hints/#interface
+ BrowserMobileKey = attribute.Key("browser.mobile")
+
+ // BrowserPlatformKey is the attribute Key conforming to the "browser.platform"
+ // semantic conventions. It represents the platform on which the browser is
+ // running.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Windows", "macOS", "Android"
+ // Note: This value is intended to be taken from the [UA client hints API] (
+ // `navigator.userAgentData.platform`). If unavailable, the legacy
+ // `navigator.platform` API SHOULD NOT be used instead and this attribute SHOULD
+ // be left unset in order for the values to be consistent.
+ // The list of possible values is defined in the
+ // [W3C User-Agent Client Hints specification]. Note that some (but not all) of
+ // these values can overlap with values in the
+ // [`os.type` and `os.name` attributes]. However, for consistency, the values in
+ // the `browser.platform` attribute should capture the exact value that the user
+ // agent provides.
+ //
+ // [UA client hints API]: https://wicg.github.io/ua-client-hints/#interface
+ // [W3C User-Agent Client Hints specification]: https://wicg.github.io/ua-client-hints/#sec-ch-ua-platform
+ // [`os.type` and `os.name` attributes]: ./os.md
+ BrowserPlatformKey = attribute.Key("browser.platform")
+)
+
+// BrowserBrands returns an attribute KeyValue conforming to the "browser.brands"
+// semantic conventions. It represents the array of brand name and version
+// separated by a space.
+func BrowserBrands(val ...string) attribute.KeyValue {
+ return BrowserBrandsKey.StringSlice(val)
+}
+
+// BrowserLanguage returns an attribute KeyValue conforming to the
+// "browser.language" semantic conventions. It represents the preferred language
+// of the user using the browser.
+func BrowserLanguage(val string) attribute.KeyValue {
+ return BrowserLanguageKey.String(val)
+}
+
+// BrowserMobile returns an attribute KeyValue conforming to the "browser.mobile"
+// semantic conventions. It represents a boolean that is true if the browser is
+// running on a mobile device.
+func BrowserMobile(val bool) attribute.KeyValue {
+ return BrowserMobileKey.Bool(val)
+}
+
+// BrowserPlatform returns an attribute KeyValue conforming to the
+// "browser.platform" semantic conventions. It represents the platform on which
+// the browser is running.
+func BrowserPlatform(val string) attribute.KeyValue {
+ return BrowserPlatformKey.String(val)
+}
+
+// Namespace: cassandra
+const (
+ // CassandraConsistencyLevelKey is the attribute Key conforming to the
+ // "cassandra.consistency.level" semantic conventions. It represents the
+ // consistency level of the query. Based on consistency values from [CQL].
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ //
+ // [CQL]: https://docs.datastax.com/en/cassandra-oss/3.0/cassandra/dml/dmlConfigConsistency.html
+ CassandraConsistencyLevelKey = attribute.Key("cassandra.consistency.level")
+
+ // CassandraCoordinatorDCKey is the attribute Key conforming to the
+ // "cassandra.coordinator.dc" semantic conventions. It represents the data
+ // center of the coordinating node for a query.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: us-west-2
+ CassandraCoordinatorDCKey = attribute.Key("cassandra.coordinator.dc")
+
+ // CassandraCoordinatorIDKey is the attribute Key conforming to the
+ // "cassandra.coordinator.id" semantic conventions. It represents the ID of the
+ // coordinating node for a query.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: be13faa2-8574-4d71-926d-27f16cf8a7af
+ CassandraCoordinatorIDKey = attribute.Key("cassandra.coordinator.id")
+
+ // CassandraPageSizeKey is the attribute Key conforming to the
+ // "cassandra.page.size" semantic conventions. It represents the fetch size used
+ // for paging, i.e. how many rows will be returned at once.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 5000
+ CassandraPageSizeKey = attribute.Key("cassandra.page.size")
+
+ // CassandraQueryIdempotentKey is the attribute Key conforming to the
+ // "cassandra.query.idempotent" semantic conventions. It represents the whether
+ // or not the query is idempotent.
+ //
+ // Type: boolean
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ CassandraQueryIdempotentKey = attribute.Key("cassandra.query.idempotent")
+
+ // CassandraSpeculativeExecutionCountKey is the attribute Key conforming to the
+ // "cassandra.speculative_execution.count" semantic conventions. It represents
+ // the number of times a query was speculatively executed. Not set or `0` if the
+ // query was not executed speculatively.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 0, 2
+ CassandraSpeculativeExecutionCountKey = attribute.Key("cassandra.speculative_execution.count")
+)
+
+// CassandraCoordinatorDC returns an attribute KeyValue conforming to the
+// "cassandra.coordinator.dc" semantic conventions. It represents the data center
+// of the coordinating node for a query.
+func CassandraCoordinatorDC(val string) attribute.KeyValue {
+ return CassandraCoordinatorDCKey.String(val)
+}
+
+// CassandraCoordinatorID returns an attribute KeyValue conforming to the
+// "cassandra.coordinator.id" semantic conventions. It represents the ID of the
+// coordinating node for a query.
+func CassandraCoordinatorID(val string) attribute.KeyValue {
+ return CassandraCoordinatorIDKey.String(val)
+}
+
+// CassandraPageSize returns an attribute KeyValue conforming to the
+// "cassandra.page.size" semantic conventions. It represents the fetch size used
+// for paging, i.e. how many rows will be returned at once.
+func CassandraPageSize(val int) attribute.KeyValue {
+ return CassandraPageSizeKey.Int(val)
+}
+
+// CassandraQueryIdempotent returns an attribute KeyValue conforming to the
+// "cassandra.query.idempotent" semantic conventions. It represents the whether
+// or not the query is idempotent.
+func CassandraQueryIdempotent(val bool) attribute.KeyValue {
+ return CassandraQueryIdempotentKey.Bool(val)
+}
+
+// CassandraSpeculativeExecutionCount returns an attribute KeyValue conforming to
+// the "cassandra.speculative_execution.count" semantic conventions. It
+// represents the number of times a query was speculatively executed. Not set or
+// `0` if the query was not executed speculatively.
+func CassandraSpeculativeExecutionCount(val int) attribute.KeyValue {
+ return CassandraSpeculativeExecutionCountKey.Int(val)
+}
+
+// Enum values for cassandra.consistency.level
+var (
+ // All
+ // Stability: development
+ CassandraConsistencyLevelAll = CassandraConsistencyLevelKey.String("all")
+ // Each Quorum
+ // Stability: development
+ CassandraConsistencyLevelEachQuorum = CassandraConsistencyLevelKey.String("each_quorum")
+ // Quorum
+ // Stability: development
+ CassandraConsistencyLevelQuorum = CassandraConsistencyLevelKey.String("quorum")
+ // Local Quorum
+ // Stability: development
+ CassandraConsistencyLevelLocalQuorum = CassandraConsistencyLevelKey.String("local_quorum")
+ // One
+ // Stability: development
+ CassandraConsistencyLevelOne = CassandraConsistencyLevelKey.String("one")
+ // Two
+ // Stability: development
+ CassandraConsistencyLevelTwo = CassandraConsistencyLevelKey.String("two")
+ // Three
+ // Stability: development
+ CassandraConsistencyLevelThree = CassandraConsistencyLevelKey.String("three")
+ // Local One
+ // Stability: development
+ CassandraConsistencyLevelLocalOne = CassandraConsistencyLevelKey.String("local_one")
+ // Any
+ // Stability: development
+ CassandraConsistencyLevelAny = CassandraConsistencyLevelKey.String("any")
+ // Serial
+ // Stability: development
+ CassandraConsistencyLevelSerial = CassandraConsistencyLevelKey.String("serial")
+ // Local Serial
+ // Stability: development
+ CassandraConsistencyLevelLocalSerial = CassandraConsistencyLevelKey.String("local_serial")
+)
+
+// Namespace: cicd
+const (
+ // CICDPipelineActionNameKey is the attribute Key conforming to the
+ // "cicd.pipeline.action.name" semantic conventions. It represents the kind of
+ // action a pipeline run is performing.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "BUILD", "RUN", "SYNC"
+ CICDPipelineActionNameKey = attribute.Key("cicd.pipeline.action.name")
+
+ // CICDPipelineNameKey is the attribute Key conforming to the
+ // "cicd.pipeline.name" semantic conventions. It represents the human readable
+ // name of the pipeline within a CI/CD system.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Build and Test", "Lint", "Deploy Go Project",
+ // "deploy_to_environment"
+ CICDPipelineNameKey = attribute.Key("cicd.pipeline.name")
+
+ // CICDPipelineResultKey is the attribute Key conforming to the
+ // "cicd.pipeline.result" semantic conventions. It represents the result of a
+ // pipeline run.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "success", "failure", "timeout", "skipped"
+ CICDPipelineResultKey = attribute.Key("cicd.pipeline.result")
+
+ // CICDPipelineRunIDKey is the attribute Key conforming to the
+ // "cicd.pipeline.run.id" semantic conventions. It represents the unique
+ // identifier of a pipeline run within a CI/CD system.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "120912"
+ CICDPipelineRunIDKey = attribute.Key("cicd.pipeline.run.id")
+
+ // CICDPipelineRunStateKey is the attribute Key conforming to the
+ // "cicd.pipeline.run.state" semantic conventions. It represents the pipeline
+ // run goes through these states during its lifecycle.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "pending", "executing", "finalizing"
+ CICDPipelineRunStateKey = attribute.Key("cicd.pipeline.run.state")
+
+ // CICDPipelineRunURLFullKey is the attribute Key conforming to the
+ // "cicd.pipeline.run.url.full" semantic conventions. It represents the [URL] of
+ // the pipeline run, providing the complete address in order to locate and
+ // identify the pipeline run.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // "https://github.com/open-telemetry/semantic-conventions/actions/runs/9753949763?pr=1075"
+ //
+ // [URL]: https://wikipedia.org/wiki/URL
+ CICDPipelineRunURLFullKey = attribute.Key("cicd.pipeline.run.url.full")
+
+ // CICDPipelineTaskNameKey is the attribute Key conforming to the
+ // "cicd.pipeline.task.name" semantic conventions. It represents the human
+ // readable name of a task within a pipeline. Task here most closely aligns with
+ // a [computing process] in a pipeline. Other terms for tasks include commands,
+ // steps, and procedures.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Run GoLang Linter", "Go Build", "go-test", "deploy_binary"
+ //
+ // [computing process]: https://wikipedia.org/wiki/Pipeline_(computing)
+ CICDPipelineTaskNameKey = attribute.Key("cicd.pipeline.task.name")
+
+ // CICDPipelineTaskRunIDKey is the attribute Key conforming to the
+ // "cicd.pipeline.task.run.id" semantic conventions. It represents the unique
+ // identifier of a task run within a pipeline.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "12097"
+ CICDPipelineTaskRunIDKey = attribute.Key("cicd.pipeline.task.run.id")
+
+ // CICDPipelineTaskRunResultKey is the attribute Key conforming to the
+ // "cicd.pipeline.task.run.result" semantic conventions. It represents the
+ // result of a task run.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "success", "failure", "timeout", "skipped"
+ CICDPipelineTaskRunResultKey = attribute.Key("cicd.pipeline.task.run.result")
+
+ // CICDPipelineTaskRunURLFullKey is the attribute Key conforming to the
+ // "cicd.pipeline.task.run.url.full" semantic conventions. It represents the
+ // [URL] of the pipeline task run, providing the complete address in order to
+ // locate and identify the pipeline task run.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // "https://github.com/open-telemetry/semantic-conventions/actions/runs/9753949763/job/26920038674?pr=1075"
+ //
+ // [URL]: https://wikipedia.org/wiki/URL
+ CICDPipelineTaskRunURLFullKey = attribute.Key("cicd.pipeline.task.run.url.full")
+
+ // CICDPipelineTaskTypeKey is the attribute Key conforming to the
+ // "cicd.pipeline.task.type" semantic conventions. It represents the type of the
+ // task within a pipeline.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "build", "test", "deploy"
+ CICDPipelineTaskTypeKey = attribute.Key("cicd.pipeline.task.type")
+
+ // CICDSystemComponentKey is the attribute Key conforming to the
+ // "cicd.system.component" semantic conventions. It represents the name of a
+ // component of the CICD system.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "controller", "scheduler", "agent"
+ CICDSystemComponentKey = attribute.Key("cicd.system.component")
+
+ // CICDWorkerIDKey is the attribute Key conforming to the "cicd.worker.id"
+ // semantic conventions. It represents the unique identifier of a worker within
+ // a CICD system.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "abc123", "10.0.1.2", "controller"
+ CICDWorkerIDKey = attribute.Key("cicd.worker.id")
+
+ // CICDWorkerNameKey is the attribute Key conforming to the "cicd.worker.name"
+ // semantic conventions. It represents the name of a worker within a CICD
+ // system.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "agent-abc", "controller", "Ubuntu LTS"
+ CICDWorkerNameKey = attribute.Key("cicd.worker.name")
+
+ // CICDWorkerStateKey is the attribute Key conforming to the "cicd.worker.state"
+ // semantic conventions. It represents the state of a CICD worker / agent.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "idle", "busy", "down"
+ CICDWorkerStateKey = attribute.Key("cicd.worker.state")
+
+ // CICDWorkerURLFullKey is the attribute Key conforming to the
+ // "cicd.worker.url.full" semantic conventions. It represents the [URL] of the
+ // worker, providing the complete address in order to locate and identify the
+ // worker.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "https://cicd.example.org/worker/abc123"
+ //
+ // [URL]: https://wikipedia.org/wiki/URL
+ CICDWorkerURLFullKey = attribute.Key("cicd.worker.url.full")
+)
+
+// CICDPipelineName returns an attribute KeyValue conforming to the
+// "cicd.pipeline.name" semantic conventions. It represents the human readable
+// name of the pipeline within a CI/CD system.
+func CICDPipelineName(val string) attribute.KeyValue {
+ return CICDPipelineNameKey.String(val)
+}
+
+// CICDPipelineRunID returns an attribute KeyValue conforming to the
+// "cicd.pipeline.run.id" semantic conventions. It represents the unique
+// identifier of a pipeline run within a CI/CD system.
+func CICDPipelineRunID(val string) attribute.KeyValue {
+ return CICDPipelineRunIDKey.String(val)
+}
+
+// CICDPipelineRunURLFull returns an attribute KeyValue conforming to the
+// "cicd.pipeline.run.url.full" semantic conventions. It represents the [URL] of
+// the pipeline run, providing the complete address in order to locate and
+// identify the pipeline run.
+//
+// [URL]: https://wikipedia.org/wiki/URL
+func CICDPipelineRunURLFull(val string) attribute.KeyValue {
+ return CICDPipelineRunURLFullKey.String(val)
+}
+
+// CICDPipelineTaskName returns an attribute KeyValue conforming to the
+// "cicd.pipeline.task.name" semantic conventions. It represents the human
+// readable name of a task within a pipeline. Task here most closely aligns with
+// a [computing process] in a pipeline. Other terms for tasks include commands,
+// steps, and procedures.
+//
+// [computing process]: https://wikipedia.org/wiki/Pipeline_(computing)
+func CICDPipelineTaskName(val string) attribute.KeyValue {
+ return CICDPipelineTaskNameKey.String(val)
+}
+
+// CICDPipelineTaskRunID returns an attribute KeyValue conforming to the
+// "cicd.pipeline.task.run.id" semantic conventions. It represents the unique
+// identifier of a task run within a pipeline.
+func CICDPipelineTaskRunID(val string) attribute.KeyValue {
+ return CICDPipelineTaskRunIDKey.String(val)
+}
+
+// CICDPipelineTaskRunURLFull returns an attribute KeyValue conforming to the
+// "cicd.pipeline.task.run.url.full" semantic conventions. It represents the
+// [URL] of the pipeline task run, providing the complete address in order to
+// locate and identify the pipeline task run.
+//
+// [URL]: https://wikipedia.org/wiki/URL
+func CICDPipelineTaskRunURLFull(val string) attribute.KeyValue {
+ return CICDPipelineTaskRunURLFullKey.String(val)
+}
+
+// CICDSystemComponent returns an attribute KeyValue conforming to the
+// "cicd.system.component" semantic conventions. It represents the name of a
+// component of the CICD system.
+func CICDSystemComponent(val string) attribute.KeyValue {
+ return CICDSystemComponentKey.String(val)
+}
+
+// CICDWorkerID returns an attribute KeyValue conforming to the "cicd.worker.id"
+// semantic conventions. It represents the unique identifier of a worker within a
+// CICD system.
+func CICDWorkerID(val string) attribute.KeyValue {
+ return CICDWorkerIDKey.String(val)
+}
+
+// CICDWorkerName returns an attribute KeyValue conforming to the
+// "cicd.worker.name" semantic conventions. It represents the name of a worker
+// within a CICD system.
+func CICDWorkerName(val string) attribute.KeyValue {
+ return CICDWorkerNameKey.String(val)
+}
+
+// CICDWorkerURLFull returns an attribute KeyValue conforming to the
+// "cicd.worker.url.full" semantic conventions. It represents the [URL] of the
+// worker, providing the complete address in order to locate and identify the
+// worker.
+//
+// [URL]: https://wikipedia.org/wiki/URL
+func CICDWorkerURLFull(val string) attribute.KeyValue {
+ return CICDWorkerURLFullKey.String(val)
+}
+
+// Enum values for cicd.pipeline.action.name
+var (
+ // The pipeline run is executing a build.
+ // Stability: development
+ CICDPipelineActionNameBuild = CICDPipelineActionNameKey.String("BUILD")
+ // The pipeline run is executing.
+ // Stability: development
+ CICDPipelineActionNameRun = CICDPipelineActionNameKey.String("RUN")
+ // The pipeline run is executing a sync.
+ // Stability: development
+ CICDPipelineActionNameSync = CICDPipelineActionNameKey.String("SYNC")
+)
+
+// Enum values for cicd.pipeline.result
+var (
+ // The pipeline run finished successfully.
+ // Stability: development
+ CICDPipelineResultSuccess = CICDPipelineResultKey.String("success")
+ // The pipeline run did not finish successfully, eg. due to a compile error or a
+ // failing test. Such failures are usually detected by non-zero exit codes of
+ // the tools executed in the pipeline run.
+ // Stability: development
+ CICDPipelineResultFailure = CICDPipelineResultKey.String("failure")
+ // The pipeline run failed due to an error in the CICD system, eg. due to the
+ // worker being killed.
+ // Stability: development
+ CICDPipelineResultError = CICDPipelineResultKey.String("error")
+ // A timeout caused the pipeline run to be interrupted.
+ // Stability: development
+ CICDPipelineResultTimeout = CICDPipelineResultKey.String("timeout")
+ // The pipeline run was cancelled, eg. by a user manually cancelling the
+ // pipeline run.
+ // Stability: development
+ CICDPipelineResultCancellation = CICDPipelineResultKey.String("cancellation")
+ // The pipeline run was skipped, eg. due to a precondition not being met.
+ // Stability: development
+ CICDPipelineResultSkip = CICDPipelineResultKey.String("skip")
+)
+
+// Enum values for cicd.pipeline.run.state
+var (
+ // The run pending state spans from the event triggering the pipeline run until
+ // the execution of the run starts (eg. time spent in a queue, provisioning
+ // agents, creating run resources).
+ //
+ // Stability: development
+ CICDPipelineRunStatePending = CICDPipelineRunStateKey.String("pending")
+ // The executing state spans the execution of any run tasks (eg. build, test).
+ // Stability: development
+ CICDPipelineRunStateExecuting = CICDPipelineRunStateKey.String("executing")
+ // The finalizing state spans from when the run has finished executing (eg.
+ // cleanup of run resources).
+ // Stability: development
+ CICDPipelineRunStateFinalizing = CICDPipelineRunStateKey.String("finalizing")
+)
+
+// Enum values for cicd.pipeline.task.run.result
+var (
+ // The task run finished successfully.
+ // Stability: development
+ CICDPipelineTaskRunResultSuccess = CICDPipelineTaskRunResultKey.String("success")
+ // The task run did not finish successfully, eg. due to a compile error or a
+ // failing test. Such failures are usually detected by non-zero exit codes of
+ // the tools executed in the task run.
+ // Stability: development
+ CICDPipelineTaskRunResultFailure = CICDPipelineTaskRunResultKey.String("failure")
+ // The task run failed due to an error in the CICD system, eg. due to the worker
+ // being killed.
+ // Stability: development
+ CICDPipelineTaskRunResultError = CICDPipelineTaskRunResultKey.String("error")
+ // A timeout caused the task run to be interrupted.
+ // Stability: development
+ CICDPipelineTaskRunResultTimeout = CICDPipelineTaskRunResultKey.String("timeout")
+ // The task run was cancelled, eg. by a user manually cancelling the task run.
+ // Stability: development
+ CICDPipelineTaskRunResultCancellation = CICDPipelineTaskRunResultKey.String("cancellation")
+ // The task run was skipped, eg. due to a precondition not being met.
+ // Stability: development
+ CICDPipelineTaskRunResultSkip = CICDPipelineTaskRunResultKey.String("skip")
+)
+
+// Enum values for cicd.pipeline.task.type
+var (
+ // build
+ // Stability: development
+ CICDPipelineTaskTypeBuild = CICDPipelineTaskTypeKey.String("build")
+ // test
+ // Stability: development
+ CICDPipelineTaskTypeTest = CICDPipelineTaskTypeKey.String("test")
+ // deploy
+ // Stability: development
+ CICDPipelineTaskTypeDeploy = CICDPipelineTaskTypeKey.String("deploy")
+)
+
+// Enum values for cicd.worker.state
+var (
+ // The worker is not performing work for the CICD system. It is available to the
+ // CICD system to perform work on (online / idle).
+ // Stability: development
+ CICDWorkerStateAvailable = CICDWorkerStateKey.String("available")
+ // The worker is performing work for the CICD system.
+ // Stability: development
+ CICDWorkerStateBusy = CICDWorkerStateKey.String("busy")
+ // The worker is not available to the CICD system (disconnected / down).
+ // Stability: development
+ CICDWorkerStateOffline = CICDWorkerStateKey.String("offline")
+)
+
+// Namespace: client
+const (
+ // ClientAddressKey is the attribute Key conforming to the "client.address"
+ // semantic conventions. It represents the client address - domain name if
+ // available without reverse DNS lookup; otherwise, IP address or Unix domain
+ // socket name.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "client.example.com", "10.1.2.80", "/tmp/my.sock"
+ // Note: When observed from the server side, and when communicating through an
+ // intermediary, `client.address` SHOULD represent the client address behind any
+ // intermediaries, for example proxies, if it's available.
+ ClientAddressKey = attribute.Key("client.address")
+
+ // ClientPortKey is the attribute Key conforming to the "client.port" semantic
+ // conventions. It represents the client port number.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: 65123
+ // Note: When observed from the server side, and when communicating through an
+ // intermediary, `client.port` SHOULD represent the client port behind any
+ // intermediaries, for example proxies, if it's available.
+ ClientPortKey = attribute.Key("client.port")
+)
+
+// ClientAddress returns an attribute KeyValue conforming to the "client.address"
+// semantic conventions. It represents the client address - domain name if
+// available without reverse DNS lookup; otherwise, IP address or Unix domain
+// socket name.
+func ClientAddress(val string) attribute.KeyValue {
+ return ClientAddressKey.String(val)
+}
+
+// ClientPort returns an attribute KeyValue conforming to the "client.port"
+// semantic conventions. It represents the client port number.
+func ClientPort(val int) attribute.KeyValue {
+ return ClientPortKey.Int(val)
+}
+
+// Namespace: cloud
+const (
+ // CloudAccountIDKey is the attribute Key conforming to the "cloud.account.id"
+ // semantic conventions. It represents the cloud account ID the resource is
+ // assigned to.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "111111111111", "opentelemetry"
+ CloudAccountIDKey = attribute.Key("cloud.account.id")
+
+ // CloudAvailabilityZoneKey is the attribute Key conforming to the
+ // "cloud.availability_zone" semantic conventions. It represents the cloud
+ // regions often have multiple, isolated locations known as zones to increase
+ // availability. Availability zone represents the zone where the resource is
+ // running.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "us-east-1c"
+ // Note: Availability zones are called "zones" on Alibaba Cloud and Google
+ // Cloud.
+ CloudAvailabilityZoneKey = attribute.Key("cloud.availability_zone")
+
+ // CloudPlatformKey is the attribute Key conforming to the "cloud.platform"
+ // semantic conventions. It represents the cloud platform in use.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // Note: The prefix of the service SHOULD match the one specified in
+ // `cloud.provider`.
+ CloudPlatformKey = attribute.Key("cloud.platform")
+
+ // CloudProviderKey is the attribute Key conforming to the "cloud.provider"
+ // semantic conventions. It represents the name of the cloud provider.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ CloudProviderKey = attribute.Key("cloud.provider")
+
+ // CloudRegionKey is the attribute Key conforming to the "cloud.region" semantic
+ // conventions. It represents the geographical region within a cloud provider.
+ // When associated with a resource, this attribute specifies the region where
+ // the resource operates. When calling services or APIs deployed on a cloud,
+ // this attribute identifies the region where the called destination is
+ // deployed.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "us-central1", "us-east-1"
+ // Note: Refer to your provider's docs to see the available regions, for example
+ // [Alibaba Cloud regions], [AWS regions], [Azure regions],
+ // [Google Cloud regions], or [Tencent Cloud regions].
+ //
+ // [Alibaba Cloud regions]: https://www.alibabacloud.com/help/doc-detail/40654.htm
+ // [AWS regions]: https://aws.amazon.com/about-aws/global-infrastructure/regions_az/
+ // [Azure regions]: https://azure.microsoft.com/global-infrastructure/geographies/
+ // [Google Cloud regions]: https://cloud.google.com/about/locations
+ // [Tencent Cloud regions]: https://www.tencentcloud.com/document/product/213/6091
+ CloudRegionKey = attribute.Key("cloud.region")
+
+ // CloudResourceIDKey is the attribute Key conforming to the "cloud.resource_id"
+ // semantic conventions. It represents the cloud provider-specific native
+ // identifier of the monitored cloud resource (e.g. an [ARN] on AWS, a
+ // [fully qualified resource ID] on Azure, a [full resource name] on GCP).
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "arn:aws:lambda:REGION:ACCOUNT_ID:function:my-function",
+ // "//run.googleapis.com/projects/PROJECT_ID/locations/LOCATION_ID/services/SERVICE_ID",
+ // "/subscriptions//resourceGroups/
+ // /providers/Microsoft.Web/sites//functions/"
+ // Note: On some cloud providers, it may not be possible to determine the full
+ // ID at startup,
+ // so it may be necessary to set `cloud.resource_id` as a span attribute
+ // instead.
+ //
+ // The exact value to use for `cloud.resource_id` depends on the cloud provider.
+ // The following well-known definitions MUST be used if you set this attribute
+ // and they apply:
+ //
+ // - **AWS Lambda:** The function [ARN].
+ // Take care not to use the "invoked ARN" directly but replace any
+ // [alias suffix]
+ // with the resolved function version, as the same runtime instance may be
+ // invocable with
+ // multiple different aliases.
+ // - **GCP:** The [URI of the resource]
+ // - **Azure:** The [Fully Qualified Resource ID] of the invoked function,
+ // *not* the function app, having the form
+ //
+ // `/subscriptions//resourceGroups//providers/Microsoft.Web/sites//functions/`
+ // .
+ // This means that a span attribute MUST be used, as an Azure function app
+ // can host multiple functions that would usually share
+ // a TracerProvider.
+ //
+ //
+ // [ARN]: https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html
+ // [fully qualified resource ID]: https://learn.microsoft.com/rest/api/resources/resources/get-by-id
+ // [full resource name]: https://google.aip.dev/122#full-resource-names
+ // [ARN]: https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html
+ // [alias suffix]: https://docs.aws.amazon.com/lambda/latest/dg/configuration-aliases.html
+ // [URI of the resource]: https://cloud.google.com/iam/docs/full-resource-names
+ // [Fully Qualified Resource ID]: https://learn.microsoft.com/rest/api/resources/resources/get-by-id
+ CloudResourceIDKey = attribute.Key("cloud.resource_id")
+)
+
+// CloudAccountID returns an attribute KeyValue conforming to the
+// "cloud.account.id" semantic conventions. It represents the cloud account ID
+// the resource is assigned to.
+func CloudAccountID(val string) attribute.KeyValue {
+ return CloudAccountIDKey.String(val)
+}
+
+// CloudAvailabilityZone returns an attribute KeyValue conforming to the
+// "cloud.availability_zone" semantic conventions. It represents the cloud
+// regions often have multiple, isolated locations known as zones to increase
+// availability. Availability zone represents the zone where the resource is
+// running.
+func CloudAvailabilityZone(val string) attribute.KeyValue {
+ return CloudAvailabilityZoneKey.String(val)
+}
+
+// CloudRegion returns an attribute KeyValue conforming to the "cloud.region"
+// semantic conventions. It represents the geographical region within a cloud
+// provider. When associated with a resource, this attribute specifies the region
+// where the resource operates. When calling services or APIs deployed on a
+// cloud, this attribute identifies the region where the called destination is
+// deployed.
+func CloudRegion(val string) attribute.KeyValue {
+ return CloudRegionKey.String(val)
+}
+
+// CloudResourceID returns an attribute KeyValue conforming to the
+// "cloud.resource_id" semantic conventions. It represents the cloud
+// provider-specific native identifier of the monitored cloud resource (e.g. an
+// [ARN] on AWS, a [fully qualified resource ID] on Azure, a [full resource name]
+// on GCP).
+//
+// [ARN]: https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html
+// [fully qualified resource ID]: https://learn.microsoft.com/rest/api/resources/resources/get-by-id
+// [full resource name]: https://google.aip.dev/122#full-resource-names
+func CloudResourceID(val string) attribute.KeyValue {
+ return CloudResourceIDKey.String(val)
+}
+
+// Enum values for cloud.platform
+var (
+ // Alibaba Cloud Elastic Compute Service
+ // Stability: development
+ CloudPlatformAlibabaCloudECS = CloudPlatformKey.String("alibaba_cloud_ecs")
+ // Alibaba Cloud Function Compute
+ // Stability: development
+ CloudPlatformAlibabaCloudFC = CloudPlatformKey.String("alibaba_cloud_fc")
+ // Red Hat OpenShift on Alibaba Cloud
+ // Stability: development
+ CloudPlatformAlibabaCloudOpenShift = CloudPlatformKey.String("alibaba_cloud_openshift")
+ // AWS Elastic Compute Cloud
+ // Stability: development
+ CloudPlatformAWSEC2 = CloudPlatformKey.String("aws_ec2")
+ // AWS Elastic Container Service
+ // Stability: development
+ CloudPlatformAWSECS = CloudPlatformKey.String("aws_ecs")
+ // AWS Elastic Kubernetes Service
+ // Stability: development
+ CloudPlatformAWSEKS = CloudPlatformKey.String("aws_eks")
+ // AWS Lambda
+ // Stability: development
+ CloudPlatformAWSLambda = CloudPlatformKey.String("aws_lambda")
+ // AWS Elastic Beanstalk
+ // Stability: development
+ CloudPlatformAWSElasticBeanstalk = CloudPlatformKey.String("aws_elastic_beanstalk")
+ // AWS App Runner
+ // Stability: development
+ CloudPlatformAWSAppRunner = CloudPlatformKey.String("aws_app_runner")
+ // Red Hat OpenShift on AWS (ROSA)
+ // Stability: development
+ CloudPlatformAWSOpenShift = CloudPlatformKey.String("aws_openshift")
+ // Azure Virtual Machines
+ // Stability: development
+ CloudPlatformAzureVM = CloudPlatformKey.String("azure.vm")
+ // Azure Container Apps
+ // Stability: development
+ CloudPlatformAzureContainerApps = CloudPlatformKey.String("azure.container_apps")
+ // Azure Container Instances
+ // Stability: development
+ CloudPlatformAzureContainerInstances = CloudPlatformKey.String("azure.container_instances")
+ // Azure Kubernetes Service
+ // Stability: development
+ CloudPlatformAzureAKS = CloudPlatformKey.String("azure.aks")
+ // Azure Functions
+ // Stability: development
+ CloudPlatformAzureFunctions = CloudPlatformKey.String("azure.functions")
+ // Azure App Service
+ // Stability: development
+ CloudPlatformAzureAppService = CloudPlatformKey.String("azure.app_service")
+ // Azure Red Hat OpenShift
+ // Stability: development
+ CloudPlatformAzureOpenShift = CloudPlatformKey.String("azure.openshift")
+ // Google Bare Metal Solution (BMS)
+ // Stability: development
+ CloudPlatformGCPBareMetalSolution = CloudPlatformKey.String("gcp_bare_metal_solution")
+ // Google Cloud Compute Engine (GCE)
+ // Stability: development
+ CloudPlatformGCPComputeEngine = CloudPlatformKey.String("gcp_compute_engine")
+ // Google Cloud Run
+ // Stability: development
+ CloudPlatformGCPCloudRun = CloudPlatformKey.String("gcp_cloud_run")
+ // Google Cloud Kubernetes Engine (GKE)
+ // Stability: development
+ CloudPlatformGCPKubernetesEngine = CloudPlatformKey.String("gcp_kubernetes_engine")
+ // Google Cloud Functions (GCF)
+ // Stability: development
+ CloudPlatformGCPCloudFunctions = CloudPlatformKey.String("gcp_cloud_functions")
+ // Google Cloud App Engine (GAE)
+ // Stability: development
+ CloudPlatformGCPAppEngine = CloudPlatformKey.String("gcp_app_engine")
+ // Red Hat OpenShift on Google Cloud
+ // Stability: development
+ CloudPlatformGCPOpenShift = CloudPlatformKey.String("gcp_openshift")
+ // Red Hat OpenShift on IBM Cloud
+ // Stability: development
+ CloudPlatformIBMCloudOpenShift = CloudPlatformKey.String("ibm_cloud_openshift")
+ // Compute on Oracle Cloud Infrastructure (OCI)
+ // Stability: development
+ CloudPlatformOracleCloudCompute = CloudPlatformKey.String("oracle_cloud_compute")
+ // Kubernetes Engine (OKE) on Oracle Cloud Infrastructure (OCI)
+ // Stability: development
+ CloudPlatformOracleCloudOKE = CloudPlatformKey.String("oracle_cloud_oke")
+ // Tencent Cloud Cloud Virtual Machine (CVM)
+ // Stability: development
+ CloudPlatformTencentCloudCVM = CloudPlatformKey.String("tencent_cloud_cvm")
+ // Tencent Cloud Elastic Kubernetes Service (EKS)
+ // Stability: development
+ CloudPlatformTencentCloudEKS = CloudPlatformKey.String("tencent_cloud_eks")
+ // Tencent Cloud Serverless Cloud Function (SCF)
+ // Stability: development
+ CloudPlatformTencentCloudSCF = CloudPlatformKey.String("tencent_cloud_scf")
+)
+
+// Enum values for cloud.provider
+var (
+ // Alibaba Cloud
+ // Stability: development
+ CloudProviderAlibabaCloud = CloudProviderKey.String("alibaba_cloud")
+ // Amazon Web Services
+ // Stability: development
+ CloudProviderAWS = CloudProviderKey.String("aws")
+ // Microsoft Azure
+ // Stability: development
+ CloudProviderAzure = CloudProviderKey.String("azure")
+ // Google Cloud Platform
+ // Stability: development
+ CloudProviderGCP = CloudProviderKey.String("gcp")
+ // Heroku Platform as a Service
+ // Stability: development
+ CloudProviderHeroku = CloudProviderKey.String("heroku")
+ // IBM Cloud
+ // Stability: development
+ CloudProviderIBMCloud = CloudProviderKey.String("ibm_cloud")
+ // Oracle Cloud Infrastructure (OCI)
+ // Stability: development
+ CloudProviderOracleCloud = CloudProviderKey.String("oracle_cloud")
+ // Tencent Cloud
+ // Stability: development
+ CloudProviderTencentCloud = CloudProviderKey.String("tencent_cloud")
+)
+
+// Namespace: cloudevents
+const (
+ // CloudEventsEventIDKey is the attribute Key conforming to the
+ // "cloudevents.event_id" semantic conventions. It represents the [event_id]
+ // uniquely identifies the event.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "123e4567-e89b-12d3-a456-426614174000", "0001"
+ //
+ // [event_id]: https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#id
+ CloudEventsEventIDKey = attribute.Key("cloudevents.event_id")
+
+ // CloudEventsEventSourceKey is the attribute Key conforming to the
+ // "cloudevents.event_source" semantic conventions. It represents the [source]
+ // identifies the context in which an event happened.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "https://github.com/cloudevents", "/cloudevents/spec/pull/123",
+ // "my-service"
+ //
+ // [source]: https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#source-1
+ CloudEventsEventSourceKey = attribute.Key("cloudevents.event_source")
+
+ // CloudEventsEventSpecVersionKey is the attribute Key conforming to the
+ // "cloudevents.event_spec_version" semantic conventions. It represents the
+ // [version of the CloudEvents specification] which the event uses.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 1.0
+ //
+ // [version of the CloudEvents specification]: https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#specversion
+ CloudEventsEventSpecVersionKey = attribute.Key("cloudevents.event_spec_version")
+
+ // CloudEventsEventSubjectKey is the attribute Key conforming to the
+ // "cloudevents.event_subject" semantic conventions. It represents the [subject]
+ // of the event in the context of the event producer (identified by source).
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: mynewfile.jpg
+ //
+ // [subject]: https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#subject
+ CloudEventsEventSubjectKey = attribute.Key("cloudevents.event_subject")
+
+ // CloudEventsEventTypeKey is the attribute Key conforming to the
+ // "cloudevents.event_type" semantic conventions. It represents the [event_type]
+ // contains a value describing the type of event related to the originating
+ // occurrence.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "com.github.pull_request.opened", "com.example.object.deleted.v2"
+ //
+ // [event_type]: https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#type
+ CloudEventsEventTypeKey = attribute.Key("cloudevents.event_type")
+)
+
+// CloudEventsEventID returns an attribute KeyValue conforming to the
+// "cloudevents.event_id" semantic conventions. It represents the [event_id]
+// uniquely identifies the event.
+//
+// [event_id]: https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#id
+func CloudEventsEventID(val string) attribute.KeyValue {
+ return CloudEventsEventIDKey.String(val)
+}
+
+// CloudEventsEventSource returns an attribute KeyValue conforming to the
+// "cloudevents.event_source" semantic conventions. It represents the [source]
+// identifies the context in which an event happened.
+//
+// [source]: https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#source-1
+func CloudEventsEventSource(val string) attribute.KeyValue {
+ return CloudEventsEventSourceKey.String(val)
+}
+
+// CloudEventsEventSpecVersion returns an attribute KeyValue conforming to the
+// "cloudevents.event_spec_version" semantic conventions. It represents the
+// [version of the CloudEvents specification] which the event uses.
+//
+// [version of the CloudEvents specification]: https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#specversion
+func CloudEventsEventSpecVersion(val string) attribute.KeyValue {
+ return CloudEventsEventSpecVersionKey.String(val)
+}
+
+// CloudEventsEventSubject returns an attribute KeyValue conforming to the
+// "cloudevents.event_subject" semantic conventions. It represents the [subject]
+// of the event in the context of the event producer (identified by source).
+//
+// [subject]: https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#subject
+func CloudEventsEventSubject(val string) attribute.KeyValue {
+ return CloudEventsEventSubjectKey.String(val)
+}
+
+// CloudEventsEventType returns an attribute KeyValue conforming to the
+// "cloudevents.event_type" semantic conventions. It represents the [event_type]
+// contains a value describing the type of event related to the originating
+// occurrence.
+//
+// [event_type]: https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#type
+func CloudEventsEventType(val string) attribute.KeyValue {
+ return CloudEventsEventTypeKey.String(val)
+}
+
+// Namespace: cloudfoundry
+const (
+ // CloudFoundryAppIDKey is the attribute Key conforming to the
+ // "cloudfoundry.app.id" semantic conventions. It represents the guid of the
+ // application.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "218fc5a9-a5f1-4b54-aa05-46717d0ab26d"
+ // Note: Application instrumentation should use the value from environment
+ // variable `VCAP_APPLICATION.application_id`. This is the same value as
+ // reported by `cf app --guid`.
+ CloudFoundryAppIDKey = attribute.Key("cloudfoundry.app.id")
+
+ // CloudFoundryAppInstanceIDKey is the attribute Key conforming to the
+ // "cloudfoundry.app.instance.id" semantic conventions. It represents the index
+ // of the application instance. 0 when just one instance is active.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "0", "1"
+ // Note: CloudFoundry defines the `instance_id` in the [Loggregator v2 envelope]
+ // .
+ // It is used for logs and metrics emitted by CloudFoundry. It is
+ // supposed to contain the application instance index for applications
+ // deployed on the runtime.
+ //
+ // Application instrumentation should use the value from environment
+ // variable `CF_INSTANCE_INDEX`.
+ //
+ // [Loggregator v2 envelope]: https://github.com/cloudfoundry/loggregator-api#v2-envelope
+ CloudFoundryAppInstanceIDKey = attribute.Key("cloudfoundry.app.instance.id")
+
+ // CloudFoundryAppNameKey is the attribute Key conforming to the
+ // "cloudfoundry.app.name" semantic conventions. It represents the name of the
+ // application.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "my-app-name"
+ // Note: Application instrumentation should use the value from environment
+ // variable `VCAP_APPLICATION.application_name`. This is the same value
+ // as reported by `cf apps`.
+ CloudFoundryAppNameKey = attribute.Key("cloudfoundry.app.name")
+
+ // CloudFoundryOrgIDKey is the attribute Key conforming to the
+ // "cloudfoundry.org.id" semantic conventions. It represents the guid of the
+ // CloudFoundry org the application is running in.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "218fc5a9-a5f1-4b54-aa05-46717d0ab26d"
+ // Note: Application instrumentation should use the value from environment
+ // variable `VCAP_APPLICATION.org_id`. This is the same value as
+ // reported by `cf org --guid`.
+ CloudFoundryOrgIDKey = attribute.Key("cloudfoundry.org.id")
+
+ // CloudFoundryOrgNameKey is the attribute Key conforming to the
+ // "cloudfoundry.org.name" semantic conventions. It represents the name of the
+ // CloudFoundry organization the app is running in.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "my-org-name"
+ // Note: Application instrumentation should use the value from environment
+ // variable `VCAP_APPLICATION.org_name`. This is the same value as
+ // reported by `cf orgs`.
+ CloudFoundryOrgNameKey = attribute.Key("cloudfoundry.org.name")
+
+ // CloudFoundryProcessIDKey is the attribute Key conforming to the
+ // "cloudfoundry.process.id" semantic conventions. It represents the UID
+ // identifying the process.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "218fc5a9-a5f1-4b54-aa05-46717d0ab26d"
+ // Note: Application instrumentation should use the value from environment
+ // variable `VCAP_APPLICATION.process_id`. It is supposed to be equal to
+ // `VCAP_APPLICATION.app_id` for applications deployed to the runtime.
+ // For system components, this could be the actual PID.
+ CloudFoundryProcessIDKey = attribute.Key("cloudfoundry.process.id")
+
+ // CloudFoundryProcessTypeKey is the attribute Key conforming to the
+ // "cloudfoundry.process.type" semantic conventions. It represents the type of
+ // process.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "web"
+ // Note: CloudFoundry applications can consist of multiple jobs. Usually the
+ // main process will be of type `web`. There can be additional background
+ // tasks or side-cars with different process types.
+ CloudFoundryProcessTypeKey = attribute.Key("cloudfoundry.process.type")
+
+ // CloudFoundrySpaceIDKey is the attribute Key conforming to the
+ // "cloudfoundry.space.id" semantic conventions. It represents the guid of the
+ // CloudFoundry space the application is running in.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "218fc5a9-a5f1-4b54-aa05-46717d0ab26d"
+ // Note: Application instrumentation should use the value from environment
+ // variable `VCAP_APPLICATION.space_id`. This is the same value as
+ // reported by `cf space --guid`.
+ CloudFoundrySpaceIDKey = attribute.Key("cloudfoundry.space.id")
+
+ // CloudFoundrySpaceNameKey is the attribute Key conforming to the
+ // "cloudfoundry.space.name" semantic conventions. It represents the name of the
+ // CloudFoundry space the application is running in.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "my-space-name"
+ // Note: Application instrumentation should use the value from environment
+ // variable `VCAP_APPLICATION.space_name`. This is the same value as
+ // reported by `cf spaces`.
+ CloudFoundrySpaceNameKey = attribute.Key("cloudfoundry.space.name")
+
+ // CloudFoundrySystemIDKey is the attribute Key conforming to the
+ // "cloudfoundry.system.id" semantic conventions. It represents a guid or
+ // another name describing the event source.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "cf/gorouter"
+ // Note: CloudFoundry defines the `source_id` in the [Loggregator v2 envelope].
+ // It is used for logs and metrics emitted by CloudFoundry. It is
+ // supposed to contain the component name, e.g. "gorouter", for
+ // CloudFoundry components.
+ //
+ // When system components are instrumented, values from the
+ // [Bosh spec]
+ // should be used. The `system.id` should be set to
+ // `spec.deployment/spec.name`.
+ //
+ // [Loggregator v2 envelope]: https://github.com/cloudfoundry/loggregator-api#v2-envelope
+ // [Bosh spec]: https://bosh.io/docs/jobs/#properties-spec
+ CloudFoundrySystemIDKey = attribute.Key("cloudfoundry.system.id")
+
+ // CloudFoundrySystemInstanceIDKey is the attribute Key conforming to the
+ // "cloudfoundry.system.instance.id" semantic conventions. It represents a guid
+ // describing the concrete instance of the event source.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "218fc5a9-a5f1-4b54-aa05-46717d0ab26d"
+ // Note: CloudFoundry defines the `instance_id` in the [Loggregator v2 envelope]
+ // .
+ // It is used for logs and metrics emitted by CloudFoundry. It is
+ // supposed to contain the vm id for CloudFoundry components.
+ //
+ // When system components are instrumented, values from the
+ // [Bosh spec]
+ // should be used. The `system.instance.id` should be set to `spec.id`.
+ //
+ // [Loggregator v2 envelope]: https://github.com/cloudfoundry/loggregator-api#v2-envelope
+ // [Bosh spec]: https://bosh.io/docs/jobs/#properties-spec
+ CloudFoundrySystemInstanceIDKey = attribute.Key("cloudfoundry.system.instance.id")
+)
+
+// CloudFoundryAppID returns an attribute KeyValue conforming to the
+// "cloudfoundry.app.id" semantic conventions. It represents the guid of the
+// application.
+func CloudFoundryAppID(val string) attribute.KeyValue {
+ return CloudFoundryAppIDKey.String(val)
+}
+
+// CloudFoundryAppInstanceID returns an attribute KeyValue conforming to the
+// "cloudfoundry.app.instance.id" semantic conventions. It represents the index
+// of the application instance. 0 when just one instance is active.
+func CloudFoundryAppInstanceID(val string) attribute.KeyValue {
+ return CloudFoundryAppInstanceIDKey.String(val)
+}
+
+// CloudFoundryAppName returns an attribute KeyValue conforming to the
+// "cloudfoundry.app.name" semantic conventions. It represents the name of the
+// application.
+func CloudFoundryAppName(val string) attribute.KeyValue {
+ return CloudFoundryAppNameKey.String(val)
+}
+
+// CloudFoundryOrgID returns an attribute KeyValue conforming to the
+// "cloudfoundry.org.id" semantic conventions. It represents the guid of the
+// CloudFoundry org the application is running in.
+func CloudFoundryOrgID(val string) attribute.KeyValue {
+ return CloudFoundryOrgIDKey.String(val)
+}
+
+// CloudFoundryOrgName returns an attribute KeyValue conforming to the
+// "cloudfoundry.org.name" semantic conventions. It represents the name of the
+// CloudFoundry organization the app is running in.
+func CloudFoundryOrgName(val string) attribute.KeyValue {
+ return CloudFoundryOrgNameKey.String(val)
+}
+
+// CloudFoundryProcessID returns an attribute KeyValue conforming to the
+// "cloudfoundry.process.id" semantic conventions. It represents the UID
+// identifying the process.
+func CloudFoundryProcessID(val string) attribute.KeyValue {
+ return CloudFoundryProcessIDKey.String(val)
+}
+
+// CloudFoundryProcessType returns an attribute KeyValue conforming to the
+// "cloudfoundry.process.type" semantic conventions. It represents the type of
+// process.
+func CloudFoundryProcessType(val string) attribute.KeyValue {
+ return CloudFoundryProcessTypeKey.String(val)
+}
+
+// CloudFoundrySpaceID returns an attribute KeyValue conforming to the
+// "cloudfoundry.space.id" semantic conventions. It represents the guid of the
+// CloudFoundry space the application is running in.
+func CloudFoundrySpaceID(val string) attribute.KeyValue {
+ return CloudFoundrySpaceIDKey.String(val)
+}
+
+// CloudFoundrySpaceName returns an attribute KeyValue conforming to the
+// "cloudfoundry.space.name" semantic conventions. It represents the name of the
+// CloudFoundry space the application is running in.
+func CloudFoundrySpaceName(val string) attribute.KeyValue {
+ return CloudFoundrySpaceNameKey.String(val)
+}
+
+// CloudFoundrySystemID returns an attribute KeyValue conforming to the
+// "cloudfoundry.system.id" semantic conventions. It represents a guid or another
+// name describing the event source.
+func CloudFoundrySystemID(val string) attribute.KeyValue {
+ return CloudFoundrySystemIDKey.String(val)
+}
+
+// CloudFoundrySystemInstanceID returns an attribute KeyValue conforming to the
+// "cloudfoundry.system.instance.id" semantic conventions. It represents a guid
+// describing the concrete instance of the event source.
+func CloudFoundrySystemInstanceID(val string) attribute.KeyValue {
+ return CloudFoundrySystemInstanceIDKey.String(val)
+}
+
+// Namespace: code
+const (
+ // CodeColumnNumberKey is the attribute Key conforming to the
+ // "code.column.number" semantic conventions. It represents the column number in
+ // `code.file.path` best representing the operation. It SHOULD point within the
+ // code unit named in `code.function.name`. This attribute MUST NOT be used on
+ // the Profile signal since the data is already captured in 'message Line'. This
+ // constraint is imposed to prevent redundancy and maintain data integrity.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ CodeColumnNumberKey = attribute.Key("code.column.number")
+
+ // CodeFilePathKey is the attribute Key conforming to the "code.file.path"
+ // semantic conventions. It represents the source code file name that identifies
+ // the code unit as uniquely as possible (preferably an absolute file path).
+ // This attribute MUST NOT be used on the Profile signal since the data is
+ // already captured in 'message Function'. This constraint is imposed to prevent
+ // redundancy and maintain data integrity.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: /usr/local/MyApplication/content_root/app/index.php
+ CodeFilePathKey = attribute.Key("code.file.path")
+
+ // CodeFunctionNameKey is the attribute Key conforming to the
+ // "code.function.name" semantic conventions. It represents the method or
+ // function fully-qualified name without arguments. The value should fit the
+ // natural representation of the language runtime, which is also likely the same
+ // used within `code.stacktrace` attribute value. This attribute MUST NOT be
+ // used on the Profile signal since the data is already captured in 'message
+ // Function'. This constraint is imposed to prevent redundancy and maintain data
+ // integrity.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "com.example.MyHttpService.serveRequest",
+ // "GuzzleHttp\Client::transfer", "fopen"
+ // Note: Values and format depends on each language runtime, thus it is
+ // impossible to provide an exhaustive list of examples.
+ // The values are usually the same (or prefixes of) the ones found in native
+ // stack trace representation stored in
+ // `code.stacktrace` without information on arguments.
+ //
+ // Examples:
+ //
+ // - Java method: `com.example.MyHttpService.serveRequest`
+ // - Java anonymous class method: `com.mycompany.Main$1.myMethod`
+ // - Java lambda method:
+ // `com.mycompany.Main$$Lambda/0x0000748ae4149c00.myMethod`
+ // - PHP function: `GuzzleHttp\Client::transfer`
+ // - Go function: `github.com/my/repo/pkg.foo.func5`
+ // - Elixir: `OpenTelemetry.Ctx.new`
+ // - Erlang: `opentelemetry_ctx:new`
+ // - Rust: `playground::my_module::my_cool_func`
+ // - C function: `fopen`
+ CodeFunctionNameKey = attribute.Key("code.function.name")
+
+ // CodeLineNumberKey is the attribute Key conforming to the "code.line.number"
+ // semantic conventions. It represents the line number in `code.file.path` best
+ // representing the operation. It SHOULD point within the code unit named in
+ // `code.function.name`. This attribute MUST NOT be used on the Profile signal
+ // since the data is already captured in 'message Line'. This constraint is
+ // imposed to prevent redundancy and maintain data integrity.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ CodeLineNumberKey = attribute.Key("code.line.number")
+
+ // CodeStacktraceKey is the attribute Key conforming to the "code.stacktrace"
+ // semantic conventions. It represents a stacktrace as a string in the natural
+ // representation for the language runtime. The representation is identical to
+ // [`exception.stacktrace`]. This attribute MUST NOT be used on the Profile
+ // signal since the data is already captured in 'message Location'. This
+ // constraint is imposed to prevent redundancy and maintain data integrity.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: at com.example.GenerateTrace.methodB(GenerateTrace.java:13)\n at
+ // com.example.GenerateTrace.methodA(GenerateTrace.java:9)\n at
+ // com.example.GenerateTrace.main(GenerateTrace.java:5)
+ //
+ // [`exception.stacktrace`]: /docs/exceptions/exceptions-spans.md#stacktrace-representation
+ CodeStacktraceKey = attribute.Key("code.stacktrace")
+)
+
+// CodeColumnNumber returns an attribute KeyValue conforming to the
+// "code.column.number" semantic conventions. It represents the column number in
+// `code.file.path` best representing the operation. It SHOULD point within the
+// code unit named in `code.function.name`. This attribute MUST NOT be used on
+// the Profile signal since the data is already captured in 'message Line'. This
+// constraint is imposed to prevent redundancy and maintain data integrity.
+func CodeColumnNumber(val int) attribute.KeyValue {
+ return CodeColumnNumberKey.Int(val)
+}
+
+// CodeFilePath returns an attribute KeyValue conforming to the "code.file.path"
+// semantic conventions. It represents the source code file name that identifies
+// the code unit as uniquely as possible (preferably an absolute file path). This
+// attribute MUST NOT be used on the Profile signal since the data is already
+// captured in 'message Function'. This constraint is imposed to prevent
+// redundancy and maintain data integrity.
+func CodeFilePath(val string) attribute.KeyValue {
+ return CodeFilePathKey.String(val)
+}
+
+// CodeFunctionName returns an attribute KeyValue conforming to the
+// "code.function.name" semantic conventions. It represents the method or
+// function fully-qualified name without arguments. The value should fit the
+// natural representation of the language runtime, which is also likely the same
+// used within `code.stacktrace` attribute value. This attribute MUST NOT be used
+// on the Profile signal since the data is already captured in 'message
+// Function'. This constraint is imposed to prevent redundancy and maintain data
+// integrity.
+func CodeFunctionName(val string) attribute.KeyValue {
+ return CodeFunctionNameKey.String(val)
+}
+
+// CodeLineNumber returns an attribute KeyValue conforming to the
+// "code.line.number" semantic conventions. It represents the line number in
+// `code.file.path` best representing the operation. It SHOULD point within the
+// code unit named in `code.function.name`. This attribute MUST NOT be used on
+// the Profile signal since the data is already captured in 'message Line'. This
+// constraint is imposed to prevent redundancy and maintain data integrity.
+func CodeLineNumber(val int) attribute.KeyValue {
+ return CodeLineNumberKey.Int(val)
+}
+
+// CodeStacktrace returns an attribute KeyValue conforming to the
+// "code.stacktrace" semantic conventions. It represents a stacktrace as a string
+// in the natural representation for the language runtime. The representation is
+// identical to [`exception.stacktrace`]. This attribute MUST NOT be used on the
+// Profile signal since the data is already captured in 'message Location'. This
+// constraint is imposed to prevent redundancy and maintain data integrity.
+//
+// [`exception.stacktrace`]: /docs/exceptions/exceptions-spans.md#stacktrace-representation
+func CodeStacktrace(val string) attribute.KeyValue {
+ return CodeStacktraceKey.String(val)
+}
+
+// Namespace: container
+const (
+ // ContainerCommandKey is the attribute Key conforming to the
+ // "container.command" semantic conventions. It represents the command used to
+ // run the container (i.e. the command name).
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "otelcontribcol"
+ // Note: If using embedded credentials or sensitive data, it is recommended to
+ // remove them to prevent potential leakage.
+ ContainerCommandKey = attribute.Key("container.command")
+
+ // ContainerCommandArgsKey is the attribute Key conforming to the
+ // "container.command_args" semantic conventions. It represents the all the
+ // command arguments (including the command/executable itself) run by the
+ // container.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "otelcontribcol", "--config", "config.yaml"
+ ContainerCommandArgsKey = attribute.Key("container.command_args")
+
+ // ContainerCommandLineKey is the attribute Key conforming to the
+ // "container.command_line" semantic conventions. It represents the full command
+ // run by the container as a single string representing the full command.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "otelcontribcol --config config.yaml"
+ ContainerCommandLineKey = attribute.Key("container.command_line")
+
+ // ContainerCSIPluginNameKey is the attribute Key conforming to the
+ // "container.csi.plugin.name" semantic conventions. It represents the name of
+ // the CSI ([Container Storage Interface]) plugin used by the volume.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "pd.csi.storage.gke.io"
+ // Note: This can sometimes be referred to as a "driver" in CSI implementations.
+ // This should represent the `name` field of the GetPluginInfo RPC.
+ //
+ // [Container Storage Interface]: https://github.com/container-storage-interface/spec
+ ContainerCSIPluginNameKey = attribute.Key("container.csi.plugin.name")
+
+ // ContainerCSIVolumeIDKey is the attribute Key conforming to the
+ // "container.csi.volume.id" semantic conventions. It represents the unique
+ // volume ID returned by the CSI ([Container Storage Interface]) plugin.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "projects/my-gcp-project/zones/my-gcp-zone/disks/my-gcp-disk"
+ // Note: This can sometimes be referred to as a "volume handle" in CSI
+ // implementations. This should represent the `Volume.volume_id` field in CSI
+ // spec.
+ //
+ // [Container Storage Interface]: https://github.com/container-storage-interface/spec
+ ContainerCSIVolumeIDKey = attribute.Key("container.csi.volume.id")
+
+ // ContainerIDKey is the attribute Key conforming to the "container.id" semantic
+ // conventions. It represents the container ID. Usually a UUID, as for example
+ // used to [identify Docker containers]. The UUID might be abbreviated.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "a3bf90e006b2"
+ //
+ // [identify Docker containers]: https://docs.docker.com/engine/containers/run/#container-identification
+ ContainerIDKey = attribute.Key("container.id")
+
+ // ContainerImageIDKey is the attribute Key conforming to the
+ // "container.image.id" semantic conventions. It represents the runtime specific
+ // image identifier. Usually a hash algorithm followed by a UUID.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // "sha256:19c92d0a00d1b66d897bceaa7319bee0dd38a10a851c60bcec9474aa3f01e50f"
+ // Note: Docker defines a sha256 of the image id; `container.image.id`
+ // corresponds to the `Image` field from the Docker container inspect [API]
+ // endpoint.
+ // K8s defines a link to the container registry repository with digest
+ // `"imageID": "registry.azurecr.io /namespace/service/dockerfile@sha256:bdeabd40c3a8a492eaf9e8e44d0ebbb84bac7ee25ac0cf8a7159d25f62555625"`
+ // .
+ // The ID is assigned by the container runtime and can vary in different
+ // environments. Consider using `oci.manifest.digest` if it is important to
+ // identify the same image in different environments/runtimes.
+ //
+ // [API]: https://docs.docker.com/engine/api/v1.43/#tag/Container/operation/ContainerInspect
+ ContainerImageIDKey = attribute.Key("container.image.id")
+
+ // ContainerImageNameKey is the attribute Key conforming to the
+ // "container.image.name" semantic conventions. It represents the name of the
+ // image the container was built on.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "gcr.io/opentelemetry/operator"
+ ContainerImageNameKey = attribute.Key("container.image.name")
+
+ // ContainerImageRepoDigestsKey is the attribute Key conforming to the
+ // "container.image.repo_digests" semantic conventions. It represents the repo
+ // digests of the container image as provided by the container runtime.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // "example@sha256:afcc7f1ac1b49db317a7196c902e61c6c3c4607d63599ee1a82d702d249a0ccb",
+ // "internal.registry.example.com:5000/example@sha256:b69959407d21e8a062e0416bf13405bb2b71ed7a84dde4158ebafacfa06f5578"
+ // Note: [Docker] and [CRI] report those under the `RepoDigests` field.
+ //
+ // [Docker]: https://docs.docker.com/engine/api/v1.43/#tag/Image/operation/ImageInspect
+ // [CRI]: https://github.com/kubernetes/cri-api/blob/c75ef5b473bbe2d0a4fc92f82235efd665ea8e9f/pkg/apis/runtime/v1/api.proto#L1237-L1238
+ ContainerImageRepoDigestsKey = attribute.Key("container.image.repo_digests")
+
+ // ContainerImageTagsKey is the attribute Key conforming to the
+ // "container.image.tags" semantic conventions. It represents the container
+ // image tags. An example can be found in [Docker Image Inspect]. Should be only
+ // the `` section of the full name for example from
+ // `registry.example.com/my-org/my-image:`.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "v1.27.1", "3.5.7-0"
+ //
+ // [Docker Image Inspect]: https://docs.docker.com/engine/api/v1.43/#tag/Image/operation/ImageInspect
+ ContainerImageTagsKey = attribute.Key("container.image.tags")
+
+ // ContainerNameKey is the attribute Key conforming to the "container.name"
+ // semantic conventions. It represents the container name used by container
+ // runtime.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "opentelemetry-autoconf"
+ ContainerNameKey = attribute.Key("container.name")
+
+ // ContainerRuntimeDescriptionKey is the attribute Key conforming to the
+ // "container.runtime.description" semantic conventions. It represents a
+ // description about the runtime which could include, for example details about
+ // the CRI/API version being used or other customisations.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "docker://19.3.1 - CRI: 1.22.0"
+ ContainerRuntimeDescriptionKey = attribute.Key("container.runtime.description")
+
+ // ContainerRuntimeNameKey is the attribute Key conforming to the
+ // "container.runtime.name" semantic conventions. It represents the container
+ // runtime managing this container.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "docker", "containerd", "rkt"
+ ContainerRuntimeNameKey = attribute.Key("container.runtime.name")
+
+ // ContainerRuntimeVersionKey is the attribute Key conforming to the
+ // "container.runtime.version" semantic conventions. It represents the version
+ // of the runtime of this process, as returned by the runtime without
+ // modification.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 1.0.0
+ ContainerRuntimeVersionKey = attribute.Key("container.runtime.version")
+)
+
+// ContainerCommand returns an attribute KeyValue conforming to the
+// "container.command" semantic conventions. It represents the command used to
+// run the container (i.e. the command name).
+func ContainerCommand(val string) attribute.KeyValue {
+ return ContainerCommandKey.String(val)
+}
+
+// ContainerCommandArgs returns an attribute KeyValue conforming to the
+// "container.command_args" semantic conventions. It represents the all the
+// command arguments (including the command/executable itself) run by the
+// container.
+func ContainerCommandArgs(val ...string) attribute.KeyValue {
+ return ContainerCommandArgsKey.StringSlice(val)
+}
+
+// ContainerCommandLine returns an attribute KeyValue conforming to the
+// "container.command_line" semantic conventions. It represents the full command
+// run by the container as a single string representing the full command.
+func ContainerCommandLine(val string) attribute.KeyValue {
+ return ContainerCommandLineKey.String(val)
+}
+
+// ContainerCSIPluginName returns an attribute KeyValue conforming to the
+// "container.csi.plugin.name" semantic conventions. It represents the name of
+// the CSI ([Container Storage Interface]) plugin used by the volume.
+//
+// [Container Storage Interface]: https://github.com/container-storage-interface/spec
+func ContainerCSIPluginName(val string) attribute.KeyValue {
+ return ContainerCSIPluginNameKey.String(val)
+}
+
+// ContainerCSIVolumeID returns an attribute KeyValue conforming to the
+// "container.csi.volume.id" semantic conventions. It represents the unique
+// volume ID returned by the CSI ([Container Storage Interface]) plugin.
+//
+// [Container Storage Interface]: https://github.com/container-storage-interface/spec
+func ContainerCSIVolumeID(val string) attribute.KeyValue {
+ return ContainerCSIVolumeIDKey.String(val)
+}
+
+// ContainerID returns an attribute KeyValue conforming to the "container.id"
+// semantic conventions. It represents the container ID. Usually a UUID, as for
+// example used to [identify Docker containers]. The UUID might be abbreviated.
+//
+// [identify Docker containers]: https://docs.docker.com/engine/containers/run/#container-identification
+func ContainerID(val string) attribute.KeyValue {
+ return ContainerIDKey.String(val)
+}
+
+// ContainerImageID returns an attribute KeyValue conforming to the
+// "container.image.id" semantic conventions. It represents the runtime specific
+// image identifier. Usually a hash algorithm followed by a UUID.
+func ContainerImageID(val string) attribute.KeyValue {
+ return ContainerImageIDKey.String(val)
+}
+
+// ContainerImageName returns an attribute KeyValue conforming to the
+// "container.image.name" semantic conventions. It represents the name of the
+// image the container was built on.
+func ContainerImageName(val string) attribute.KeyValue {
+ return ContainerImageNameKey.String(val)
+}
+
+// ContainerImageRepoDigests returns an attribute KeyValue conforming to the
+// "container.image.repo_digests" semantic conventions. It represents the repo
+// digests of the container image as provided by the container runtime.
+func ContainerImageRepoDigests(val ...string) attribute.KeyValue {
+ return ContainerImageRepoDigestsKey.StringSlice(val)
+}
+
+// ContainerImageTags returns an attribute KeyValue conforming to the
+// "container.image.tags" semantic conventions. It represents the container image
+// tags. An example can be found in [Docker Image Inspect]. Should be only the
+// `` section of the full name for example from
+// `registry.example.com/my-org/my-image:`.
+//
+// [Docker Image Inspect]: https://docs.docker.com/engine/api/v1.43/#tag/Image/operation/ImageInspect
+func ContainerImageTags(val ...string) attribute.KeyValue {
+ return ContainerImageTagsKey.StringSlice(val)
+}
+
+// ContainerLabel returns an attribute KeyValue conforming to the
+// "container.label" semantic conventions. It represents the container labels,
+// `` being the label name, the value being the label value.
+func ContainerLabel(key string, val string) attribute.KeyValue {
+ return attribute.String("container.label."+key, val)
+}
+
+// ContainerName returns an attribute KeyValue conforming to the "container.name"
+// semantic conventions. It represents the container name used by container
+// runtime.
+func ContainerName(val string) attribute.KeyValue {
+ return ContainerNameKey.String(val)
+}
+
+// ContainerRuntimeDescription returns an attribute KeyValue conforming to the
+// "container.runtime.description" semantic conventions. It represents a
+// description about the runtime which could include, for example details about
+// the CRI/API version being used or other customisations.
+func ContainerRuntimeDescription(val string) attribute.KeyValue {
+ return ContainerRuntimeDescriptionKey.String(val)
+}
+
+// ContainerRuntimeName returns an attribute KeyValue conforming to the
+// "container.runtime.name" semantic conventions. It represents the container
+// runtime managing this container.
+func ContainerRuntimeName(val string) attribute.KeyValue {
+ return ContainerRuntimeNameKey.String(val)
+}
+
+// ContainerRuntimeVersion returns an attribute KeyValue conforming to the
+// "container.runtime.version" semantic conventions. It represents the version of
+// the runtime of this process, as returned by the runtime without modification.
+func ContainerRuntimeVersion(val string) attribute.KeyValue {
+ return ContainerRuntimeVersionKey.String(val)
+}
+
+// Namespace: cpu
+const (
+ // CPULogicalNumberKey is the attribute Key conforming to the
+ // "cpu.logical_number" semantic conventions. It represents the logical CPU
+ // number [0..n-1].
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 1
+ CPULogicalNumberKey = attribute.Key("cpu.logical_number")
+
+ // CPUModeKey is the attribute Key conforming to the "cpu.mode" semantic
+ // conventions. It represents the mode of the CPU.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "user", "system"
+ CPUModeKey = attribute.Key("cpu.mode")
+)
+
+// CPULogicalNumber returns an attribute KeyValue conforming to the
+// "cpu.logical_number" semantic conventions. It represents the logical CPU
+// number [0..n-1].
+func CPULogicalNumber(val int) attribute.KeyValue {
+ return CPULogicalNumberKey.Int(val)
+}
+
+// Enum values for cpu.mode
+var (
+ // User
+ // Stability: development
+ CPUModeUser = CPUModeKey.String("user")
+ // System
+ // Stability: development
+ CPUModeSystem = CPUModeKey.String("system")
+ // Nice
+ // Stability: development
+ CPUModeNice = CPUModeKey.String("nice")
+ // Idle
+ // Stability: development
+ CPUModeIdle = CPUModeKey.String("idle")
+ // IO Wait
+ // Stability: development
+ CPUModeIOWait = CPUModeKey.String("iowait")
+ // Interrupt
+ // Stability: development
+ CPUModeInterrupt = CPUModeKey.String("interrupt")
+ // Steal
+ // Stability: development
+ CPUModeSteal = CPUModeKey.String("steal")
+ // Kernel
+ // Stability: development
+ CPUModeKernel = CPUModeKey.String("kernel")
+)
+
+// Namespace: db
+const (
+ // DBClientConnectionPoolNameKey is the attribute Key conforming to the
+ // "db.client.connection.pool.name" semantic conventions. It represents the name
+ // of the connection pool; unique within the instrumented application. In case
+ // the connection pool implementation doesn't provide a name, instrumentation
+ // SHOULD use a combination of parameters that would make the name unique, for
+ // example, combining attributes `server.address`, `server.port`, and
+ // `db.namespace`, formatted as `server.address:server.port/db.namespace`.
+ // Instrumentations that generate connection pool name following different
+ // patterns SHOULD document it.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "myDataSource"
+ DBClientConnectionPoolNameKey = attribute.Key("db.client.connection.pool.name")
+
+ // DBClientConnectionStateKey is the attribute Key conforming to the
+ // "db.client.connection.state" semantic conventions. It represents the state of
+ // a connection in the pool.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "idle"
+ DBClientConnectionStateKey = attribute.Key("db.client.connection.state")
+
+ // DBCollectionNameKey is the attribute Key conforming to the
+ // "db.collection.name" semantic conventions. It represents the name of a
+ // collection (table, container) within the database.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "public.users", "customers"
+ // Note: It is RECOMMENDED to capture the value as provided by the application
+ // without attempting to do any case normalization.
+ //
+ // The collection name SHOULD NOT be extracted from `db.query.text`,
+ // when the database system supports query text with multiple collections
+ // in non-batch operations.
+ //
+ // For batch operations, if the individual operations are known to have the same
+ // collection name then that collection name SHOULD be used.
+ DBCollectionNameKey = attribute.Key("db.collection.name")
+
+ // DBNamespaceKey is the attribute Key conforming to the "db.namespace" semantic
+ // conventions. It represents the name of the database, fully qualified within
+ // the server address and port.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "customers", "test.users"
+ // Note: If a database system has multiple namespace components, they SHOULD be
+ // concatenated from the most general to the most specific namespace component,
+ // using `|` as a separator between the components. Any missing components (and
+ // their associated separators) SHOULD be omitted.
+ // Semantic conventions for individual database systems SHOULD document what
+ // `db.namespace` means in the context of that system.
+ // It is RECOMMENDED to capture the value as provided by the application without
+ // attempting to do any case normalization.
+ DBNamespaceKey = attribute.Key("db.namespace")
+
+ // DBOperationBatchSizeKey is the attribute Key conforming to the
+ // "db.operation.batch.size" semantic conventions. It represents the number of
+ // queries included in a batch operation.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: 2, 3, 4
+ // Note: Operations are only considered batches when they contain two or more
+ // operations, and so `db.operation.batch.size` SHOULD never be `1`.
+ DBOperationBatchSizeKey = attribute.Key("db.operation.batch.size")
+
+ // DBOperationNameKey is the attribute Key conforming to the "db.operation.name"
+ // semantic conventions. It represents the name of the operation or command
+ // being executed.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "findAndModify", "HMSET", "SELECT"
+ // Note: It is RECOMMENDED to capture the value as provided by the application
+ // without attempting to do any case normalization.
+ //
+ // The operation name SHOULD NOT be extracted from `db.query.text`,
+ // when the database system supports query text with multiple operations
+ // in non-batch operations.
+ //
+ // If spaces can occur in the operation name, multiple consecutive spaces
+ // SHOULD be normalized to a single space.
+ //
+ // For batch operations, if the individual operations are known to have the same
+ // operation name
+ // then that operation name SHOULD be used prepended by `BATCH `,
+ // otherwise `db.operation.name` SHOULD be `BATCH` or some other database
+ // system specific term if more applicable.
+ DBOperationNameKey = attribute.Key("db.operation.name")
+
+ // DBQuerySummaryKey is the attribute Key conforming to the "db.query.summary"
+ // semantic conventions. It represents the low cardinality summary of a database
+ // query.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "SELECT wuser_table", "INSERT shipping_details SELECT orders", "get
+ // user by id"
+ // Note: The query summary describes a class of database queries and is useful
+ // as a grouping key, especially when analyzing telemetry for database
+ // calls involving complex queries.
+ //
+ // Summary may be available to the instrumentation through
+ // instrumentation hooks or other means. If it is not available,
+ // instrumentations
+ // that support query parsing SHOULD generate a summary following
+ // [Generating query summary]
+ // section.
+ //
+ // [Generating query summary]: /docs/database/database-spans.md#generating-a-summary-of-the-query
+ DBQuerySummaryKey = attribute.Key("db.query.summary")
+
+ // DBQueryTextKey is the attribute Key conforming to the "db.query.text"
+ // semantic conventions. It represents the database query being executed.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "SELECT * FROM wuser_table where username = ?", "SET mykey ?"
+ // Note: For sanitization see [Sanitization of `db.query.text`].
+ // For batch operations, if the individual operations are known to have the same
+ // query text then that query text SHOULD be used, otherwise all of the
+ // individual query texts SHOULD be concatenated with separator `; ` or some
+ // other database system specific separator if more applicable.
+ // Parameterized query text SHOULD NOT be sanitized. Even though parameterized
+ // query text can potentially have sensitive data, by using a parameterized
+ // query the user is giving a strong signal that any sensitive data will be
+ // passed as parameter values, and the benefit to observability of capturing the
+ // static part of the query text by default outweighs the risk.
+ //
+ // [Sanitization of `db.query.text`]: /docs/database/database-spans.md#sanitization-of-dbquerytext
+ DBQueryTextKey = attribute.Key("db.query.text")
+
+ // DBResponseReturnedRowsKey is the attribute Key conforming to the
+ // "db.response.returned_rows" semantic conventions. It represents the number of
+ // rows returned by the operation.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 10, 30, 1000
+ DBResponseReturnedRowsKey = attribute.Key("db.response.returned_rows")
+
+ // DBResponseStatusCodeKey is the attribute Key conforming to the
+ // "db.response.status_code" semantic conventions. It represents the database
+ // response status code.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "102", "ORA-17002", "08P01", "404"
+ // Note: The status code returned by the database. Usually it represents an
+ // error code, but may also represent partial success, warning, or differentiate
+ // between various types of successful outcomes.
+ // Semantic conventions for individual database systems SHOULD document what
+ // `db.response.status_code` means in the context of that system.
+ DBResponseStatusCodeKey = attribute.Key("db.response.status_code")
+
+ // DBStoredProcedureNameKey is the attribute Key conforming to the
+ // "db.stored_procedure.name" semantic conventions. It represents the name of a
+ // stored procedure within the database.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "GetCustomer"
+ // Note: It is RECOMMENDED to capture the value as provided by the application
+ // without attempting to do any case normalization.
+ //
+ // For batch operations, if the individual operations are known to have the same
+ // stored procedure name then that stored procedure name SHOULD be used.
+ DBStoredProcedureNameKey = attribute.Key("db.stored_procedure.name")
+
+ // DBSystemNameKey is the attribute Key conforming to the "db.system.name"
+ // semantic conventions. It represents the database management system (DBMS)
+ // product as identified by the client instrumentation.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples:
+ // Note: The actual DBMS may differ from the one identified by the client. For
+ // example, when using PostgreSQL client libraries to connect to a CockroachDB,
+ // the `db.system.name` is set to `postgresql` based on the instrumentation's
+ // best knowledge.
+ DBSystemNameKey = attribute.Key("db.system.name")
+)
+
+// DBClientConnectionPoolName returns an attribute KeyValue conforming to the
+// "db.client.connection.pool.name" semantic conventions. It represents the name
+// of the connection pool; unique within the instrumented application. In case
+// the connection pool implementation doesn't provide a name, instrumentation
+// SHOULD use a combination of parameters that would make the name unique, for
+// example, combining attributes `server.address`, `server.port`, and
+// `db.namespace`, formatted as `server.address:server.port/db.namespace`.
+// Instrumentations that generate connection pool name following different
+// patterns SHOULD document it.
+func DBClientConnectionPoolName(val string) attribute.KeyValue {
+ return DBClientConnectionPoolNameKey.String(val)
+}
+
+// DBCollectionName returns an attribute KeyValue conforming to the
+// "db.collection.name" semantic conventions. It represents the name of a
+// collection (table, container) within the database.
+func DBCollectionName(val string) attribute.KeyValue {
+ return DBCollectionNameKey.String(val)
+}
+
+// DBNamespace returns an attribute KeyValue conforming to the "db.namespace"
+// semantic conventions. It represents the name of the database, fully qualified
+// within the server address and port.
+func DBNamespace(val string) attribute.KeyValue {
+ return DBNamespaceKey.String(val)
+}
+
+// DBOperationBatchSize returns an attribute KeyValue conforming to the
+// "db.operation.batch.size" semantic conventions. It represents the number of
+// queries included in a batch operation.
+func DBOperationBatchSize(val int) attribute.KeyValue {
+ return DBOperationBatchSizeKey.Int(val)
+}
+
+// DBOperationName returns an attribute KeyValue conforming to the
+// "db.operation.name" semantic conventions. It represents the name of the
+// operation or command being executed.
+func DBOperationName(val string) attribute.KeyValue {
+ return DBOperationNameKey.String(val)
+}
+
+// DBOperationParameter returns an attribute KeyValue conforming to the
+// "db.operation.parameter" semantic conventions. It represents a database
+// operation parameter, with `` being the parameter name, and the attribute
+// value being a string representation of the parameter value.
+func DBOperationParameter(key string, val string) attribute.KeyValue {
+ return attribute.String("db.operation.parameter."+key, val)
+}
+
+// DBQueryParameter returns an attribute KeyValue conforming to the
+// "db.query.parameter" semantic conventions. It represents a database query
+// parameter, with `` being the parameter name, and the attribute value
+// being a string representation of the parameter value.
+func DBQueryParameter(key string, val string) attribute.KeyValue {
+ return attribute.String("db.query.parameter."+key, val)
+}
+
+// DBQuerySummary returns an attribute KeyValue conforming to the
+// "db.query.summary" semantic conventions. It represents the low cardinality
+// summary of a database query.
+func DBQuerySummary(val string) attribute.KeyValue {
+ return DBQuerySummaryKey.String(val)
+}
+
+// DBQueryText returns an attribute KeyValue conforming to the "db.query.text"
+// semantic conventions. It represents the database query being executed.
+func DBQueryText(val string) attribute.KeyValue {
+ return DBQueryTextKey.String(val)
+}
+
+// DBResponseReturnedRows returns an attribute KeyValue conforming to the
+// "db.response.returned_rows" semantic conventions. It represents the number of
+// rows returned by the operation.
+func DBResponseReturnedRows(val int) attribute.KeyValue {
+ return DBResponseReturnedRowsKey.Int(val)
+}
+
+// DBResponseStatusCode returns an attribute KeyValue conforming to the
+// "db.response.status_code" semantic conventions. It represents the database
+// response status code.
+func DBResponseStatusCode(val string) attribute.KeyValue {
+ return DBResponseStatusCodeKey.String(val)
+}
+
+// DBStoredProcedureName returns an attribute KeyValue conforming to the
+// "db.stored_procedure.name" semantic conventions. It represents the name of a
+// stored procedure within the database.
+func DBStoredProcedureName(val string) attribute.KeyValue {
+ return DBStoredProcedureNameKey.String(val)
+}
+
+// Enum values for db.client.connection.state
+var (
+ // idle
+ // Stability: development
+ DBClientConnectionStateIdle = DBClientConnectionStateKey.String("idle")
+ // used
+ // Stability: development
+ DBClientConnectionStateUsed = DBClientConnectionStateKey.String("used")
+)
+
+// Enum values for db.system.name
+var (
+ // Some other SQL database. Fallback only.
+ // Stability: development
+ DBSystemNameOtherSQL = DBSystemNameKey.String("other_sql")
+ // [Adabas (Adaptable Database System)]
+ // Stability: development
+ //
+ // [Adabas (Adaptable Database System)]: https://documentation.softwareag.com/?pf=adabas
+ DBSystemNameSoftwareagAdabas = DBSystemNameKey.String("softwareag.adabas")
+ // [Actian Ingres]
+ // Stability: development
+ //
+ // [Actian Ingres]: https://www.actian.com/databases/ingres/
+ DBSystemNameActianIngres = DBSystemNameKey.String("actian.ingres")
+ // [Amazon DynamoDB]
+ // Stability: development
+ //
+ // [Amazon DynamoDB]: https://aws.amazon.com/pm/dynamodb/
+ DBSystemNameAWSDynamoDB = DBSystemNameKey.String("aws.dynamodb")
+ // [Amazon Redshift]
+ // Stability: development
+ //
+ // [Amazon Redshift]: https://aws.amazon.com/redshift/
+ DBSystemNameAWSRedshift = DBSystemNameKey.String("aws.redshift")
+ // [Azure Cosmos DB]
+ // Stability: development
+ //
+ // [Azure Cosmos DB]: https://learn.microsoft.com/azure/cosmos-db
+ DBSystemNameAzureCosmosDB = DBSystemNameKey.String("azure.cosmosdb")
+ // [InterSystems Caché]
+ // Stability: development
+ //
+ // [InterSystems Caché]: https://www.intersystems.com/products/cache/
+ DBSystemNameIntersystemsCache = DBSystemNameKey.String("intersystems.cache")
+ // [Apache Cassandra]
+ // Stability: development
+ //
+ // [Apache Cassandra]: https://cassandra.apache.org/
+ DBSystemNameCassandra = DBSystemNameKey.String("cassandra")
+ // [ClickHouse]
+ // Stability: development
+ //
+ // [ClickHouse]: https://clickhouse.com/
+ DBSystemNameClickHouse = DBSystemNameKey.String("clickhouse")
+ // [CockroachDB]
+ // Stability: development
+ //
+ // [CockroachDB]: https://www.cockroachlabs.com/
+ DBSystemNameCockroachDB = DBSystemNameKey.String("cockroachdb")
+ // [Couchbase]
+ // Stability: development
+ //
+ // [Couchbase]: https://www.couchbase.com/
+ DBSystemNameCouchbase = DBSystemNameKey.String("couchbase")
+ // [Apache CouchDB]
+ // Stability: development
+ //
+ // [Apache CouchDB]: https://couchdb.apache.org/
+ DBSystemNameCouchDB = DBSystemNameKey.String("couchdb")
+ // [Apache Derby]
+ // Stability: development
+ //
+ // [Apache Derby]: https://db.apache.org/derby/
+ DBSystemNameDerby = DBSystemNameKey.String("derby")
+ // [Elasticsearch]
+ // Stability: development
+ //
+ // [Elasticsearch]: https://www.elastic.co/elasticsearch
+ DBSystemNameElasticsearch = DBSystemNameKey.String("elasticsearch")
+ // [Firebird]
+ // Stability: development
+ //
+ // [Firebird]: https://www.firebirdsql.org/
+ DBSystemNameFirebirdSQL = DBSystemNameKey.String("firebirdsql")
+ // [Google Cloud Spanner]
+ // Stability: development
+ //
+ // [Google Cloud Spanner]: https://cloud.google.com/spanner
+ DBSystemNameGCPSpanner = DBSystemNameKey.String("gcp.spanner")
+ // [Apache Geode]
+ // Stability: development
+ //
+ // [Apache Geode]: https://geode.apache.org/
+ DBSystemNameGeode = DBSystemNameKey.String("geode")
+ // [H2 Database]
+ // Stability: development
+ //
+ // [H2 Database]: https://h2database.com/
+ DBSystemNameH2database = DBSystemNameKey.String("h2database")
+ // [Apache HBase]
+ // Stability: development
+ //
+ // [Apache HBase]: https://hbase.apache.org/
+ DBSystemNameHBase = DBSystemNameKey.String("hbase")
+ // [Apache Hive]
+ // Stability: development
+ //
+ // [Apache Hive]: https://hive.apache.org/
+ DBSystemNameHive = DBSystemNameKey.String("hive")
+ // [HyperSQL Database]
+ // Stability: development
+ //
+ // [HyperSQL Database]: https://hsqldb.org/
+ DBSystemNameHSQLDB = DBSystemNameKey.String("hsqldb")
+ // [IBM Db2]
+ // Stability: development
+ //
+ // [IBM Db2]: https://www.ibm.com/db2
+ DBSystemNameIBMDB2 = DBSystemNameKey.String("ibm.db2")
+ // [IBM Informix]
+ // Stability: development
+ //
+ // [IBM Informix]: https://www.ibm.com/products/informix
+ DBSystemNameIBMInformix = DBSystemNameKey.String("ibm.informix")
+ // [IBM Netezza]
+ // Stability: development
+ //
+ // [IBM Netezza]: https://www.ibm.com/products/netezza
+ DBSystemNameIBMNetezza = DBSystemNameKey.String("ibm.netezza")
+ // [InfluxDB]
+ // Stability: development
+ //
+ // [InfluxDB]: https://www.influxdata.com/
+ DBSystemNameInfluxDB = DBSystemNameKey.String("influxdb")
+ // [Instant]
+ // Stability: development
+ //
+ // [Instant]: https://www.instantdb.com/
+ DBSystemNameInstantDB = DBSystemNameKey.String("instantdb")
+ // [MariaDB]
+ // Stability: stable
+ //
+ // [MariaDB]: https://mariadb.org/
+ DBSystemNameMariaDB = DBSystemNameKey.String("mariadb")
+ // [Memcached]
+ // Stability: development
+ //
+ // [Memcached]: https://memcached.org/
+ DBSystemNameMemcached = DBSystemNameKey.String("memcached")
+ // [MongoDB]
+ // Stability: development
+ //
+ // [MongoDB]: https://www.mongodb.com/
+ DBSystemNameMongoDB = DBSystemNameKey.String("mongodb")
+ // [Microsoft SQL Server]
+ // Stability: stable
+ //
+ // [Microsoft SQL Server]: https://www.microsoft.com/sql-server
+ DBSystemNameMicrosoftSQLServer = DBSystemNameKey.String("microsoft.sql_server")
+ // [MySQL]
+ // Stability: stable
+ //
+ // [MySQL]: https://www.mysql.com/
+ DBSystemNameMySQL = DBSystemNameKey.String("mysql")
+ // [Neo4j]
+ // Stability: development
+ //
+ // [Neo4j]: https://neo4j.com/
+ DBSystemNameNeo4j = DBSystemNameKey.String("neo4j")
+ // [OpenSearch]
+ // Stability: development
+ //
+ // [OpenSearch]: https://opensearch.org/
+ DBSystemNameOpenSearch = DBSystemNameKey.String("opensearch")
+ // [Oracle Database]
+ // Stability: development
+ //
+ // [Oracle Database]: https://www.oracle.com/database/
+ DBSystemNameOracleDB = DBSystemNameKey.String("oracle.db")
+ // [PostgreSQL]
+ // Stability: stable
+ //
+ // [PostgreSQL]: https://www.postgresql.org/
+ DBSystemNamePostgreSQL = DBSystemNameKey.String("postgresql")
+ // [Redis]
+ // Stability: development
+ //
+ // [Redis]: https://redis.io/
+ DBSystemNameRedis = DBSystemNameKey.String("redis")
+ // [SAP HANA]
+ // Stability: development
+ //
+ // [SAP HANA]: https://www.sap.com/products/technology-platform/hana/what-is-sap-hana.html
+ DBSystemNameSAPHANA = DBSystemNameKey.String("sap.hana")
+ // [SAP MaxDB]
+ // Stability: development
+ //
+ // [SAP MaxDB]: https://maxdb.sap.com/
+ DBSystemNameSAPMaxDB = DBSystemNameKey.String("sap.maxdb")
+ // [SQLite]
+ // Stability: development
+ //
+ // [SQLite]: https://www.sqlite.org/
+ DBSystemNameSQLite = DBSystemNameKey.String("sqlite")
+ // [Teradata]
+ // Stability: development
+ //
+ // [Teradata]: https://www.teradata.com/
+ DBSystemNameTeradata = DBSystemNameKey.String("teradata")
+ // [Trino]
+ // Stability: development
+ //
+ // [Trino]: https://trino.io/
+ DBSystemNameTrino = DBSystemNameKey.String("trino")
+)
+
+// Namespace: deployment
+const (
+ // DeploymentEnvironmentNameKey is the attribute Key conforming to the
+ // "deployment.environment.name" semantic conventions. It represents the name of
+ // the [deployment environment] (aka deployment tier).
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "staging", "production"
+ // Note: `deployment.environment.name` does not affect the uniqueness
+ // constraints defined through
+ // the `service.namespace`, `service.name` and `service.instance.id` resource
+ // attributes.
+ // This implies that resources carrying the following attribute combinations
+ // MUST be
+ // considered to be identifying the same service:
+ //
+ // - `service.name=frontend`, `deployment.environment.name=production`
+ // - `service.name=frontend`, `deployment.environment.name=staging`.
+ //
+ //
+ // [deployment environment]: https://wikipedia.org/wiki/Deployment_environment
+ DeploymentEnvironmentNameKey = attribute.Key("deployment.environment.name")
+
+ // DeploymentIDKey is the attribute Key conforming to the "deployment.id"
+ // semantic conventions. It represents the id of the deployment.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "1208"
+ DeploymentIDKey = attribute.Key("deployment.id")
+
+ // DeploymentNameKey is the attribute Key conforming to the "deployment.name"
+ // semantic conventions. It represents the name of the deployment.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "deploy my app", "deploy-frontend"
+ DeploymentNameKey = attribute.Key("deployment.name")
+
+ // DeploymentStatusKey is the attribute Key conforming to the
+ // "deployment.status" semantic conventions. It represents the status of the
+ // deployment.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ DeploymentStatusKey = attribute.Key("deployment.status")
+)
+
+// DeploymentEnvironmentName returns an attribute KeyValue conforming to the
+// "deployment.environment.name" semantic conventions. It represents the name of
+// the [deployment environment] (aka deployment tier).
+//
+// [deployment environment]: https://wikipedia.org/wiki/Deployment_environment
+func DeploymentEnvironmentName(val string) attribute.KeyValue {
+ return DeploymentEnvironmentNameKey.String(val)
+}
+
+// DeploymentID returns an attribute KeyValue conforming to the "deployment.id"
+// semantic conventions. It represents the id of the deployment.
+func DeploymentID(val string) attribute.KeyValue {
+ return DeploymentIDKey.String(val)
+}
+
+// DeploymentName returns an attribute KeyValue conforming to the
+// "deployment.name" semantic conventions. It represents the name of the
+// deployment.
+func DeploymentName(val string) attribute.KeyValue {
+ return DeploymentNameKey.String(val)
+}
+
+// Enum values for deployment.status
+var (
+ // failed
+ // Stability: development
+ DeploymentStatusFailed = DeploymentStatusKey.String("failed")
+ // succeeded
+ // Stability: development
+ DeploymentStatusSucceeded = DeploymentStatusKey.String("succeeded")
+)
+
+// Namespace: destination
+const (
+ // DestinationAddressKey is the attribute Key conforming to the
+ // "destination.address" semantic conventions. It represents the destination
+ // address - domain name if available without reverse DNS lookup; otherwise, IP
+ // address or Unix domain socket name.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "destination.example.com", "10.1.2.80", "/tmp/my.sock"
+ // Note: When observed from the source side, and when communicating through an
+ // intermediary, `destination.address` SHOULD represent the destination address
+ // behind any intermediaries, for example proxies, if it's available.
+ DestinationAddressKey = attribute.Key("destination.address")
+
+ // DestinationPortKey is the attribute Key conforming to the "destination.port"
+ // semantic conventions. It represents the destination port number.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 3389, 2888
+ DestinationPortKey = attribute.Key("destination.port")
+)
+
+// DestinationAddress returns an attribute KeyValue conforming to the
+// "destination.address" semantic conventions. It represents the destination
+// address - domain name if available without reverse DNS lookup; otherwise, IP
+// address or Unix domain socket name.
+func DestinationAddress(val string) attribute.KeyValue {
+ return DestinationAddressKey.String(val)
+}
+
+// DestinationPort returns an attribute KeyValue conforming to the
+// "destination.port" semantic conventions. It represents the destination port
+// number.
+func DestinationPort(val int) attribute.KeyValue {
+ return DestinationPortKey.Int(val)
+}
+
+// Namespace: device
+const (
+ // DeviceIDKey is the attribute Key conforming to the "device.id" semantic
+ // conventions. It represents a unique identifier representing the device.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "123456789012345", "01:23:45:67:89:AB"
+ // Note: Its value SHOULD be identical for all apps on a device and it SHOULD
+ // NOT change if an app is uninstalled and re-installed.
+ // However, it might be resettable by the user for all apps on a device.
+ // Hardware IDs (e.g. vendor-specific serial number, IMEI or MAC address) MAY be
+ // used as values.
+ //
+ // More information about Android identifier best practices can be found in the
+ // [Android user data IDs guide].
+ //
+ // > [!WARNING]> This attribute may contain sensitive (PII) information. Caution
+ // > should be taken when storing personal data or anything which can identify a
+ // > user. GDPR and data protection laws may apply,
+ // > ensure you do your own due diligence.> Due to these reasons, this
+ // > identifier is not recommended for consumer applications and will likely
+ // > result in rejection from both Google Play and App Store.
+ // > However, it may be appropriate for specific enterprise scenarios, such as
+ // > kiosk devices or enterprise-managed devices, with appropriate compliance
+ // > clearance.
+ // > Any instrumentation providing this identifier MUST implement it as an
+ // > opt-in feature.> See [`app.installation.id`]> for a more
+ // > privacy-preserving alternative.
+ //
+ // [Android user data IDs guide]: https://developer.android.com/training/articles/user-data-ids
+ // [`app.installation.id`]: /docs/registry/attributes/app.md#app-installation-id
+ DeviceIDKey = attribute.Key("device.id")
+
+ // DeviceManufacturerKey is the attribute Key conforming to the
+ // "device.manufacturer" semantic conventions. It represents the name of the
+ // device manufacturer.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Apple", "Samsung"
+ // Note: The Android OS provides this field via [Build]. iOS apps SHOULD
+ // hardcode the value `Apple`.
+ //
+ // [Build]: https://developer.android.com/reference/android/os/Build#MANUFACTURER
+ DeviceManufacturerKey = attribute.Key("device.manufacturer")
+
+ // DeviceModelIdentifierKey is the attribute Key conforming to the
+ // "device.model.identifier" semantic conventions. It represents the model
+ // identifier for the device.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "iPhone3,4", "SM-G920F"
+ // Note: It's recommended this value represents a machine-readable version of
+ // the model identifier rather than the market or consumer-friendly name of the
+ // device.
+ DeviceModelIdentifierKey = attribute.Key("device.model.identifier")
+
+ // DeviceModelNameKey is the attribute Key conforming to the "device.model.name"
+ // semantic conventions. It represents the marketing name for the device model.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "iPhone 6s Plus", "Samsung Galaxy S6"
+ // Note: It's recommended this value represents a human-readable version of the
+ // device model rather than a machine-readable alternative.
+ DeviceModelNameKey = attribute.Key("device.model.name")
+)
+
+// DeviceID returns an attribute KeyValue conforming to the "device.id" semantic
+// conventions. It represents a unique identifier representing the device.
+func DeviceID(val string) attribute.KeyValue {
+ return DeviceIDKey.String(val)
+}
+
+// DeviceManufacturer returns an attribute KeyValue conforming to the
+// "device.manufacturer" semantic conventions. It represents the name of the
+// device manufacturer.
+func DeviceManufacturer(val string) attribute.KeyValue {
+ return DeviceManufacturerKey.String(val)
+}
+
+// DeviceModelIdentifier returns an attribute KeyValue conforming to the
+// "device.model.identifier" semantic conventions. It represents the model
+// identifier for the device.
+func DeviceModelIdentifier(val string) attribute.KeyValue {
+ return DeviceModelIdentifierKey.String(val)
+}
+
+// DeviceModelName returns an attribute KeyValue conforming to the
+// "device.model.name" semantic conventions. It represents the marketing name for
+// the device model.
+func DeviceModelName(val string) attribute.KeyValue {
+ return DeviceModelNameKey.String(val)
+}
+
+// Namespace: disk
+const (
+ // DiskIODirectionKey is the attribute Key conforming to the "disk.io.direction"
+ // semantic conventions. It represents the disk IO operation direction.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "read"
+ DiskIODirectionKey = attribute.Key("disk.io.direction")
+)
+
+// Enum values for disk.io.direction
+var (
+ // read
+ // Stability: development
+ DiskIODirectionRead = DiskIODirectionKey.String("read")
+ // write
+ // Stability: development
+ DiskIODirectionWrite = DiskIODirectionKey.String("write")
+)
+
+// Namespace: dns
+const (
+ // DNSAnswersKey is the attribute Key conforming to the "dns.answers" semantic
+ // conventions. It represents the list of IPv4 or IPv6 addresses resolved during
+ // DNS lookup.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "10.0.0.1", "2001:0db8:85a3:0000:0000:8a2e:0370:7334"
+ DNSAnswersKey = attribute.Key("dns.answers")
+
+ // DNSQuestionNameKey is the attribute Key conforming to the "dns.question.name"
+ // semantic conventions. It represents the name being queried.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "www.example.com", "opentelemetry.io"
+ // Note: If the name field contains non-printable characters (below 32 or above
+ // 126), those characters should be represented as escaped base 10 integers
+ // (\DDD). Back slashes and quotes should be escaped. Tabs, carriage returns,
+ // and line feeds should be converted to \t, \r, and \n respectively.
+ DNSQuestionNameKey = attribute.Key("dns.question.name")
+)
+
+// DNSAnswers returns an attribute KeyValue conforming to the "dns.answers"
+// semantic conventions. It represents the list of IPv4 or IPv6 addresses
+// resolved during DNS lookup.
+func DNSAnswers(val ...string) attribute.KeyValue {
+ return DNSAnswersKey.StringSlice(val)
+}
+
+// DNSQuestionName returns an attribute KeyValue conforming to the
+// "dns.question.name" semantic conventions. It represents the name being
+// queried.
+func DNSQuestionName(val string) attribute.KeyValue {
+ return DNSQuestionNameKey.String(val)
+}
+
+// Namespace: elasticsearch
+const (
+ // ElasticsearchNodeNameKey is the attribute Key conforming to the
+ // "elasticsearch.node.name" semantic conventions. It represents the represents
+ // the human-readable identifier of the node/instance to which a request was
+ // routed.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "instance-0000000001"
+ ElasticsearchNodeNameKey = attribute.Key("elasticsearch.node.name")
+)
+
+// ElasticsearchNodeName returns an attribute KeyValue conforming to the
+// "elasticsearch.node.name" semantic conventions. It represents the represents
+// the human-readable identifier of the node/instance to which a request was
+// routed.
+func ElasticsearchNodeName(val string) attribute.KeyValue {
+ return ElasticsearchNodeNameKey.String(val)
+}
+
+// Namespace: enduser
+const (
+ // EnduserIDKey is the attribute Key conforming to the "enduser.id" semantic
+ // conventions. It represents the unique identifier of an end user in the
+ // system. It maybe a username, email address, or other identifier.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "username"
+ // Note: Unique identifier of an end user in the system.
+ //
+ // > [!Warning]
+ // > This field contains sensitive (PII) information.
+ EnduserIDKey = attribute.Key("enduser.id")
+
+ // EnduserPseudoIDKey is the attribute Key conforming to the "enduser.pseudo.id"
+ // semantic conventions. It represents the pseudonymous identifier of an end
+ // user. This identifier should be a random value that is not directly linked or
+ // associated with the end user's actual identity.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "QdH5CAWJgqVT4rOr0qtumf"
+ // Note: Pseudonymous identifier of an end user.
+ //
+ // > [!Warning]
+ // > This field contains sensitive (linkable PII) information.
+ EnduserPseudoIDKey = attribute.Key("enduser.pseudo.id")
+)
+
+// EnduserID returns an attribute KeyValue conforming to the "enduser.id"
+// semantic conventions. It represents the unique identifier of an end user in
+// the system. It maybe a username, email address, or other identifier.
+func EnduserID(val string) attribute.KeyValue {
+ return EnduserIDKey.String(val)
+}
+
+// EnduserPseudoID returns an attribute KeyValue conforming to the
+// "enduser.pseudo.id" semantic conventions. It represents the pseudonymous
+// identifier of an end user. This identifier should be a random value that is
+// not directly linked or associated with the end user's actual identity.
+func EnduserPseudoID(val string) attribute.KeyValue {
+ return EnduserPseudoIDKey.String(val)
+}
+
+// Namespace: error
+const (
+ // ErrorMessageKey is the attribute Key conforming to the "error.message"
+ // semantic conventions. It represents a message providing more detail about an
+ // error in human-readable form.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Unexpected input type: string", "The user has exceeded their
+ // storage quota"
+ // Note: `error.message` should provide additional context and detail about an
+ // error.
+ // It is NOT RECOMMENDED to duplicate the value of `error.type` in
+ // `error.message`.
+ // It is also NOT RECOMMENDED to duplicate the value of `exception.message` in
+ // `error.message`.
+ //
+ // `error.message` is NOT RECOMMENDED for metrics or spans due to its unbounded
+ // cardinality and overlap with span status.
+ ErrorMessageKey = attribute.Key("error.message")
+
+ // ErrorTypeKey is the attribute Key conforming to the "error.type" semantic
+ // conventions. It represents the describes a class of error the operation ended
+ // with.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "timeout", "java.net.UnknownHostException",
+ // "server_certificate_invalid", "500"
+ // Note: The `error.type` SHOULD be predictable, and SHOULD have low
+ // cardinality.
+ //
+ // When `error.type` is set to a type (e.g., an exception type), its
+ // canonical class name identifying the type within the artifact SHOULD be used.
+ //
+ // Instrumentations SHOULD document the list of errors they report.
+ //
+ // The cardinality of `error.type` within one instrumentation library SHOULD be
+ // low.
+ // Telemetry consumers that aggregate data from multiple instrumentation
+ // libraries and applications
+ // should be prepared for `error.type` to have high cardinality at query time
+ // when no
+ // additional filters are applied.
+ //
+ // If the operation has completed successfully, instrumentations SHOULD NOT set
+ // `error.type`.
+ //
+ // If a specific domain defines its own set of error identifiers (such as HTTP
+ // or gRPC status codes),
+ // it's RECOMMENDED to:
+ //
+ // - Use a domain-specific attribute
+ // - Set `error.type` to capture all errors, regardless of whether they are
+ // defined within the domain-specific set or not.
+ ErrorTypeKey = attribute.Key("error.type")
+)
+
+// ErrorMessage returns an attribute KeyValue conforming to the "error.message"
+// semantic conventions. It represents a message providing more detail about an
+// error in human-readable form.
+func ErrorMessage(val string) attribute.KeyValue {
+ return ErrorMessageKey.String(val)
+}
+
+// Enum values for error.type
+var (
+ // A fallback error value to be used when the instrumentation doesn't define a
+ // custom value.
+ //
+ // Stability: stable
+ ErrorTypeOther = ErrorTypeKey.String("_OTHER")
+)
+
+// Namespace: exception
+const (
+ // ExceptionMessageKey is the attribute Key conforming to the
+ // "exception.message" semantic conventions. It represents the exception
+ // message.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "Division by zero", "Can't convert 'int' object to str implicitly"
+ ExceptionMessageKey = attribute.Key("exception.message")
+
+ // ExceptionStacktraceKey is the attribute Key conforming to the
+ // "exception.stacktrace" semantic conventions. It represents a stacktrace as a
+ // string in the natural representation for the language runtime. The
+ // representation is to be determined and documented by each language SIG.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: Exception in thread "main" java.lang.RuntimeException: Test
+ // exception\n at com.example.GenerateTrace.methodB(GenerateTrace.java:13)\n at
+ // com.example.GenerateTrace.methodA(GenerateTrace.java:9)\n at
+ // com.example.GenerateTrace.main(GenerateTrace.java:5)
+ ExceptionStacktraceKey = attribute.Key("exception.stacktrace")
+
+ // ExceptionTypeKey is the attribute Key conforming to the "exception.type"
+ // semantic conventions. It represents the type of the exception (its
+ // fully-qualified class name, if applicable). The dynamic type of the exception
+ // should be preferred over the static type in languages that support it.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "java.net.ConnectException", "OSError"
+ ExceptionTypeKey = attribute.Key("exception.type")
+)
+
+// ExceptionMessage returns an attribute KeyValue conforming to the
+// "exception.message" semantic conventions. It represents the exception message.
+func ExceptionMessage(val string) attribute.KeyValue {
+ return ExceptionMessageKey.String(val)
+}
+
+// ExceptionStacktrace returns an attribute KeyValue conforming to the
+// "exception.stacktrace" semantic conventions. It represents a stacktrace as a
+// string in the natural representation for the language runtime. The
+// representation is to be determined and documented by each language SIG.
+func ExceptionStacktrace(val string) attribute.KeyValue {
+ return ExceptionStacktraceKey.String(val)
+}
+
+// ExceptionType returns an attribute KeyValue conforming to the "exception.type"
+// semantic conventions. It represents the type of the exception (its
+// fully-qualified class name, if applicable). The dynamic type of the exception
+// should be preferred over the static type in languages that support it.
+func ExceptionType(val string) attribute.KeyValue {
+ return ExceptionTypeKey.String(val)
+}
+
+// Namespace: faas
+const (
+ // FaaSColdstartKey is the attribute Key conforming to the "faas.coldstart"
+ // semantic conventions. It represents a boolean that is true if the serverless
+ // function is executed for the first time (aka cold-start).
+ //
+ // Type: boolean
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ FaaSColdstartKey = attribute.Key("faas.coldstart")
+
+ // FaaSCronKey is the attribute Key conforming to the "faas.cron" semantic
+ // conventions. It represents a string containing the schedule period as
+ // [Cron Expression].
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 0/5 * * * ? *
+ //
+ // [Cron Expression]: https://docs.oracle.com/cd/E12058_01/doc/doc.1014/e12030/cron_expressions.htm
+ FaaSCronKey = attribute.Key("faas.cron")
+
+ // FaaSDocumentCollectionKey is the attribute Key conforming to the
+ // "faas.document.collection" semantic conventions. It represents the name of
+ // the source on which the triggering operation was performed. For example, in
+ // Cloud Storage or S3 corresponds to the bucket name, and in Cosmos DB to the
+ // database name.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "myBucketName", "myDbName"
+ FaaSDocumentCollectionKey = attribute.Key("faas.document.collection")
+
+ // FaaSDocumentNameKey is the attribute Key conforming to the
+ // "faas.document.name" semantic conventions. It represents the document
+ // name/table subjected to the operation. For example, in Cloud Storage or S3 is
+ // the name of the file, and in Cosmos DB the table name.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "myFile.txt", "myTableName"
+ FaaSDocumentNameKey = attribute.Key("faas.document.name")
+
+ // FaaSDocumentOperationKey is the attribute Key conforming to the
+ // "faas.document.operation" semantic conventions. It represents the describes
+ // the type of the operation that was performed on the data.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ FaaSDocumentOperationKey = attribute.Key("faas.document.operation")
+
+ // FaaSDocumentTimeKey is the attribute Key conforming to the
+ // "faas.document.time" semantic conventions. It represents a string containing
+ // the time when the data was accessed in the [ISO 8601] format expressed in
+ // [UTC].
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 2020-01-23T13:47:06Z
+ //
+ // [ISO 8601]: https://www.iso.org/iso-8601-date-and-time-format.html
+ // [UTC]: https://www.w3.org/TR/NOTE-datetime
+ FaaSDocumentTimeKey = attribute.Key("faas.document.time")
+
+ // FaaSInstanceKey is the attribute Key conforming to the "faas.instance"
+ // semantic conventions. It represents the execution environment ID as a string,
+ // that will be potentially reused for other invocations to the same
+ // function/function version.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "2021/06/28/[$LATEST]2f399eb14537447da05ab2a2e39309de"
+ // Note: - **AWS Lambda:** Use the (full) log stream name.
+ FaaSInstanceKey = attribute.Key("faas.instance")
+
+ // FaaSInvocationIDKey is the attribute Key conforming to the
+ // "faas.invocation_id" semantic conventions. It represents the invocation ID of
+ // the current function invocation.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: af9d5aa4-a685-4c5f-a22b-444f80b3cc28
+ FaaSInvocationIDKey = attribute.Key("faas.invocation_id")
+
+ // FaaSInvokedNameKey is the attribute Key conforming to the "faas.invoked_name"
+ // semantic conventions. It represents the name of the invoked function.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: my-function
+ // Note: SHOULD be equal to the `faas.name` resource attribute of the invoked
+ // function.
+ FaaSInvokedNameKey = attribute.Key("faas.invoked_name")
+
+ // FaaSInvokedProviderKey is the attribute Key conforming to the
+ // "faas.invoked_provider" semantic conventions. It represents the cloud
+ // provider of the invoked function.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // Note: SHOULD be equal to the `cloud.provider` resource attribute of the
+ // invoked function.
+ FaaSInvokedProviderKey = attribute.Key("faas.invoked_provider")
+
+ // FaaSInvokedRegionKey is the attribute Key conforming to the
+ // "faas.invoked_region" semantic conventions. It represents the cloud region of
+ // the invoked function.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: eu-central-1
+ // Note: SHOULD be equal to the `cloud.region` resource attribute of the invoked
+ // function.
+ FaaSInvokedRegionKey = attribute.Key("faas.invoked_region")
+
+ // FaaSMaxMemoryKey is the attribute Key conforming to the "faas.max_memory"
+ // semantic conventions. It represents the amount of memory available to the
+ // serverless function converted to Bytes.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Note: It's recommended to set this attribute since e.g. too little memory can
+ // easily stop a Java AWS Lambda function from working correctly. On AWS Lambda,
+ // the environment variable `AWS_LAMBDA_FUNCTION_MEMORY_SIZE` provides this
+ // information (which must be multiplied by 1,048,576).
+ FaaSMaxMemoryKey = attribute.Key("faas.max_memory")
+
+ // FaaSNameKey is the attribute Key conforming to the "faas.name" semantic
+ // conventions. It represents the name of the single function that this runtime
+ // instance executes.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "my-function", "myazurefunctionapp/some-function-name"
+ // Note: This is the name of the function as configured/deployed on the FaaS
+ // platform and is usually different from the name of the callback
+ // function (which may be stored in the
+ // [`code.namespace`/`code.function.name`]
+ // span attributes).
+ //
+ // For some cloud providers, the above definition is ambiguous. The following
+ // definition of function name MUST be used for this attribute
+ // (and consequently the span name) for the listed cloud providers/products:
+ //
+ // - **Azure:** The full name `/`, i.e., function app name
+ // followed by a forward slash followed by the function name (this form
+ // can also be seen in the resource JSON for the function).
+ // This means that a span attribute MUST be used, as an Azure function
+ // app can host multiple functions that would usually share
+ // a TracerProvider (see also the `cloud.resource_id` attribute).
+ //
+ //
+ // [`code.namespace`/`code.function.name`]: /docs/general/attributes.md#source-code-attributes
+ FaaSNameKey = attribute.Key("faas.name")
+
+ // FaaSTimeKey is the attribute Key conforming to the "faas.time" semantic
+ // conventions. It represents a string containing the function invocation time
+ // in the [ISO 8601] format expressed in [UTC].
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 2020-01-23T13:47:06Z
+ //
+ // [ISO 8601]: https://www.iso.org/iso-8601-date-and-time-format.html
+ // [UTC]: https://www.w3.org/TR/NOTE-datetime
+ FaaSTimeKey = attribute.Key("faas.time")
+
+ // FaaSTriggerKey is the attribute Key conforming to the "faas.trigger" semantic
+ // conventions. It represents the type of the trigger which caused this function
+ // invocation.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ FaaSTriggerKey = attribute.Key("faas.trigger")
+
+ // FaaSVersionKey is the attribute Key conforming to the "faas.version" semantic
+ // conventions. It represents the immutable version of the function being
+ // executed.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "26", "pinkfroid-00002"
+ // Note: Depending on the cloud provider and platform, use:
+ //
+ // - **AWS Lambda:** The [function version]
+ // (an integer represented as a decimal string).
+ // - **Google Cloud Run (Services):** The [revision]
+ // (i.e., the function name plus the revision suffix).
+ // - **Google Cloud Functions:** The value of the
+ // [`K_REVISION` environment variable].
+ // - **Azure Functions:** Not applicable. Do not set this attribute.
+ //
+ //
+ // [function version]: https://docs.aws.amazon.com/lambda/latest/dg/configuration-versions.html
+ // [revision]: https://cloud.google.com/run/docs/managing/revisions
+ // [`K_REVISION` environment variable]: https://cloud.google.com/functions/docs/env-var#runtime_environment_variables_set_automatically
+ FaaSVersionKey = attribute.Key("faas.version")
+)
+
+// FaaSColdstart returns an attribute KeyValue conforming to the "faas.coldstart"
+// semantic conventions. It represents a boolean that is true if the serverless
+// function is executed for the first time (aka cold-start).
+func FaaSColdstart(val bool) attribute.KeyValue {
+ return FaaSColdstartKey.Bool(val)
+}
+
+// FaaSCron returns an attribute KeyValue conforming to the "faas.cron" semantic
+// conventions. It represents a string containing the schedule period as
+// [Cron Expression].
+//
+// [Cron Expression]: https://docs.oracle.com/cd/E12058_01/doc/doc.1014/e12030/cron_expressions.htm
+func FaaSCron(val string) attribute.KeyValue {
+ return FaaSCronKey.String(val)
+}
+
+// FaaSDocumentCollection returns an attribute KeyValue conforming to the
+// "faas.document.collection" semantic conventions. It represents the name of the
+// source on which the triggering operation was performed. For example, in Cloud
+// Storage or S3 corresponds to the bucket name, and in Cosmos DB to the database
+// name.
+func FaaSDocumentCollection(val string) attribute.KeyValue {
+ return FaaSDocumentCollectionKey.String(val)
+}
+
+// FaaSDocumentName returns an attribute KeyValue conforming to the
+// "faas.document.name" semantic conventions. It represents the document
+// name/table subjected to the operation. For example, in Cloud Storage or S3 is
+// the name of the file, and in Cosmos DB the table name.
+func FaaSDocumentName(val string) attribute.KeyValue {
+ return FaaSDocumentNameKey.String(val)
+}
+
+// FaaSDocumentTime returns an attribute KeyValue conforming to the
+// "faas.document.time" semantic conventions. It represents a string containing
+// the time when the data was accessed in the [ISO 8601] format expressed in
+// [UTC].
+//
+// [ISO 8601]: https://www.iso.org/iso-8601-date-and-time-format.html
+// [UTC]: https://www.w3.org/TR/NOTE-datetime
+func FaaSDocumentTime(val string) attribute.KeyValue {
+ return FaaSDocumentTimeKey.String(val)
+}
+
+// FaaSInstance returns an attribute KeyValue conforming to the "faas.instance"
+// semantic conventions. It represents the execution environment ID as a string,
+// that will be potentially reused for other invocations to the same
+// function/function version.
+func FaaSInstance(val string) attribute.KeyValue {
+ return FaaSInstanceKey.String(val)
+}
+
+// FaaSInvocationID returns an attribute KeyValue conforming to the
+// "faas.invocation_id" semantic conventions. It represents the invocation ID of
+// the current function invocation.
+func FaaSInvocationID(val string) attribute.KeyValue {
+ return FaaSInvocationIDKey.String(val)
+}
+
+// FaaSInvokedName returns an attribute KeyValue conforming to the
+// "faas.invoked_name" semantic conventions. It represents the name of the
+// invoked function.
+func FaaSInvokedName(val string) attribute.KeyValue {
+ return FaaSInvokedNameKey.String(val)
+}
+
+// FaaSInvokedRegion returns an attribute KeyValue conforming to the
+// "faas.invoked_region" semantic conventions. It represents the cloud region of
+// the invoked function.
+func FaaSInvokedRegion(val string) attribute.KeyValue {
+ return FaaSInvokedRegionKey.String(val)
+}
+
+// FaaSMaxMemory returns an attribute KeyValue conforming to the
+// "faas.max_memory" semantic conventions. It represents the amount of memory
+// available to the serverless function converted to Bytes.
+func FaaSMaxMemory(val int) attribute.KeyValue {
+ return FaaSMaxMemoryKey.Int(val)
+}
+
+// FaaSName returns an attribute KeyValue conforming to the "faas.name" semantic
+// conventions. It represents the name of the single function that this runtime
+// instance executes.
+func FaaSName(val string) attribute.KeyValue {
+ return FaaSNameKey.String(val)
+}
+
+// FaaSTime returns an attribute KeyValue conforming to the "faas.time" semantic
+// conventions. It represents a string containing the function invocation time in
+// the [ISO 8601] format expressed in [UTC].
+//
+// [ISO 8601]: https://www.iso.org/iso-8601-date-and-time-format.html
+// [UTC]: https://www.w3.org/TR/NOTE-datetime
+func FaaSTime(val string) attribute.KeyValue {
+ return FaaSTimeKey.String(val)
+}
+
+// FaaSVersion returns an attribute KeyValue conforming to the "faas.version"
+// semantic conventions. It represents the immutable version of the function
+// being executed.
+func FaaSVersion(val string) attribute.KeyValue {
+ return FaaSVersionKey.String(val)
+}
+
+// Enum values for faas.document.operation
+var (
+ // When a new object is created.
+ // Stability: development
+ FaaSDocumentOperationInsert = FaaSDocumentOperationKey.String("insert")
+ // When an object is modified.
+ // Stability: development
+ FaaSDocumentOperationEdit = FaaSDocumentOperationKey.String("edit")
+ // When an object is deleted.
+ // Stability: development
+ FaaSDocumentOperationDelete = FaaSDocumentOperationKey.String("delete")
+)
+
+// Enum values for faas.invoked_provider
+var (
+ // Alibaba Cloud
+ // Stability: development
+ FaaSInvokedProviderAlibabaCloud = FaaSInvokedProviderKey.String("alibaba_cloud")
+ // Amazon Web Services
+ // Stability: development
+ FaaSInvokedProviderAWS = FaaSInvokedProviderKey.String("aws")
+ // Microsoft Azure
+ // Stability: development
+ FaaSInvokedProviderAzure = FaaSInvokedProviderKey.String("azure")
+ // Google Cloud Platform
+ // Stability: development
+ FaaSInvokedProviderGCP = FaaSInvokedProviderKey.String("gcp")
+ // Tencent Cloud
+ // Stability: development
+ FaaSInvokedProviderTencentCloud = FaaSInvokedProviderKey.String("tencent_cloud")
+)
+
+// Enum values for faas.trigger
+var (
+ // A response to some data source operation such as a database or filesystem
+ // read/write
+ // Stability: development
+ FaaSTriggerDatasource = FaaSTriggerKey.String("datasource")
+ // To provide an answer to an inbound HTTP request
+ // Stability: development
+ FaaSTriggerHTTP = FaaSTriggerKey.String("http")
+ // A function is set to be executed when messages are sent to a messaging system
+ // Stability: development
+ FaaSTriggerPubSub = FaaSTriggerKey.String("pubsub")
+ // A function is scheduled to be executed regularly
+ // Stability: development
+ FaaSTriggerTimer = FaaSTriggerKey.String("timer")
+ // If none of the others apply
+ // Stability: development
+ FaaSTriggerOther = FaaSTriggerKey.String("other")
+)
+
+// Namespace: feature_flag
+const (
+ // FeatureFlagContextIDKey is the attribute Key conforming to the
+ // "feature_flag.context.id" semantic conventions. It represents the unique
+ // identifier for the flag evaluation context. For example, the targeting key.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Release_Candidate
+ //
+ // Examples: "5157782b-2203-4c80-a857-dbbd5e7761db"
+ FeatureFlagContextIDKey = attribute.Key("feature_flag.context.id")
+
+ // FeatureFlagKeyKey is the attribute Key conforming to the "feature_flag.key"
+ // semantic conventions. It represents the lookup key of the feature flag.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Release_Candidate
+ //
+ // Examples: "logo-color"
+ FeatureFlagKeyKey = attribute.Key("feature_flag.key")
+
+ // FeatureFlagProviderNameKey is the attribute Key conforming to the
+ // "feature_flag.provider.name" semantic conventions. It represents the
+ // identifies the feature flag provider.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Release_Candidate
+ //
+ // Examples: "Flag Manager"
+ FeatureFlagProviderNameKey = attribute.Key("feature_flag.provider.name")
+
+ // FeatureFlagResultReasonKey is the attribute Key conforming to the
+ // "feature_flag.result.reason" semantic conventions. It represents the reason
+ // code which shows how a feature flag value was determined.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Release_Candidate
+ //
+ // Examples: "static", "targeting_match", "error", "default"
+ FeatureFlagResultReasonKey = attribute.Key("feature_flag.result.reason")
+
+ // FeatureFlagResultValueKey is the attribute Key conforming to the
+ // "feature_flag.result.value" semantic conventions. It represents the evaluated
+ // value of the feature flag.
+ //
+ // Type: any
+ // RequirementLevel: Recommended
+ // Stability: Release_Candidate
+ //
+ // Examples: "#ff0000", true, 3
+ // Note: With some feature flag providers, feature flag results can be quite
+ // large or contain private or sensitive details.
+ // Because of this, `feature_flag.result.variant` is often the preferred
+ // attribute if it is available.
+ //
+ // It may be desirable to redact or otherwise limit the size and scope of
+ // `feature_flag.result.value` if possible.
+ // Because the evaluated flag value is unstructured and may be any type, it is
+ // left to the instrumentation author to determine how best to achieve this.
+ FeatureFlagResultValueKey = attribute.Key("feature_flag.result.value")
+
+ // FeatureFlagResultVariantKey is the attribute Key conforming to the
+ // "feature_flag.result.variant" semantic conventions. It represents a semantic
+ // identifier for an evaluated flag value.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Release_Candidate
+ //
+ // Examples: "red", "true", "on"
+ // Note: A semantic identifier, commonly referred to as a variant, provides a
+ // means
+ // for referring to a value without including the value itself. This can
+ // provide additional context for understanding the meaning behind a value.
+ // For example, the variant `red` maybe be used for the value `#c05543`.
+ FeatureFlagResultVariantKey = attribute.Key("feature_flag.result.variant")
+
+ // FeatureFlagSetIDKey is the attribute Key conforming to the
+ // "feature_flag.set.id" semantic conventions. It represents the identifier of
+ // the [flag set] to which the feature flag belongs.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Release_Candidate
+ //
+ // Examples: "proj-1", "ab98sgs", "service1/dev"
+ //
+ // [flag set]: https://openfeature.dev/specification/glossary/#flag-set
+ FeatureFlagSetIDKey = attribute.Key("feature_flag.set.id")
+
+ // FeatureFlagVersionKey is the attribute Key conforming to the
+ // "feature_flag.version" semantic conventions. It represents the version of the
+ // ruleset used during the evaluation. This may be any stable value which
+ // uniquely identifies the ruleset.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Release_Candidate
+ //
+ // Examples: "1", "01ABCDEF"
+ FeatureFlagVersionKey = attribute.Key("feature_flag.version")
+)
+
+// FeatureFlagContextID returns an attribute KeyValue conforming to the
+// "feature_flag.context.id" semantic conventions. It represents the unique
+// identifier for the flag evaluation context. For example, the targeting key.
+func FeatureFlagContextID(val string) attribute.KeyValue {
+ return FeatureFlagContextIDKey.String(val)
+}
+
+// FeatureFlagKey returns an attribute KeyValue conforming to the
+// "feature_flag.key" semantic conventions. It represents the lookup key of the
+// feature flag.
+func FeatureFlagKey(val string) attribute.KeyValue {
+ return FeatureFlagKeyKey.String(val)
+}
+
+// FeatureFlagProviderName returns an attribute KeyValue conforming to the
+// "feature_flag.provider.name" semantic conventions. It represents the
+// identifies the feature flag provider.
+func FeatureFlagProviderName(val string) attribute.KeyValue {
+ return FeatureFlagProviderNameKey.String(val)
+}
+
+// FeatureFlagResultVariant returns an attribute KeyValue conforming to the
+// "feature_flag.result.variant" semantic conventions. It represents a semantic
+// identifier for an evaluated flag value.
+func FeatureFlagResultVariant(val string) attribute.KeyValue {
+ return FeatureFlagResultVariantKey.String(val)
+}
+
+// FeatureFlagSetID returns an attribute KeyValue conforming to the
+// "feature_flag.set.id" semantic conventions. It represents the identifier of
+// the [flag set] to which the feature flag belongs.
+//
+// [flag set]: https://openfeature.dev/specification/glossary/#flag-set
+func FeatureFlagSetID(val string) attribute.KeyValue {
+ return FeatureFlagSetIDKey.String(val)
+}
+
+// FeatureFlagVersion returns an attribute KeyValue conforming to the
+// "feature_flag.version" semantic conventions. It represents the version of the
+// ruleset used during the evaluation. This may be any stable value which
+// uniquely identifies the ruleset.
+func FeatureFlagVersion(val string) attribute.KeyValue {
+ return FeatureFlagVersionKey.String(val)
+}
+
+// Enum values for feature_flag.result.reason
+var (
+ // The resolved value is static (no dynamic evaluation).
+ // Stability: release_candidate
+ FeatureFlagResultReasonStatic = FeatureFlagResultReasonKey.String("static")
+ // The resolved value fell back to a pre-configured value (no dynamic evaluation
+ // occurred or dynamic evaluation yielded no result).
+ // Stability: release_candidate
+ FeatureFlagResultReasonDefault = FeatureFlagResultReasonKey.String("default")
+ // The resolved value was the result of a dynamic evaluation, such as a rule or
+ // specific user-targeting.
+ // Stability: release_candidate
+ FeatureFlagResultReasonTargetingMatch = FeatureFlagResultReasonKey.String("targeting_match")
+ // The resolved value was the result of pseudorandom assignment.
+ // Stability: release_candidate
+ FeatureFlagResultReasonSplit = FeatureFlagResultReasonKey.String("split")
+ // The resolved value was retrieved from cache.
+ // Stability: release_candidate
+ FeatureFlagResultReasonCached = FeatureFlagResultReasonKey.String("cached")
+ // The resolved value was the result of the flag being disabled in the
+ // management system.
+ // Stability: release_candidate
+ FeatureFlagResultReasonDisabled = FeatureFlagResultReasonKey.String("disabled")
+ // The reason for the resolved value could not be determined.
+ // Stability: release_candidate
+ FeatureFlagResultReasonUnknown = FeatureFlagResultReasonKey.String("unknown")
+ // The resolved value is non-authoritative or possibly out of date
+ // Stability: release_candidate
+ FeatureFlagResultReasonStale = FeatureFlagResultReasonKey.String("stale")
+ // The resolved value was the result of an error.
+ // Stability: release_candidate
+ FeatureFlagResultReasonError = FeatureFlagResultReasonKey.String("error")
+)
+
+// Namespace: file
+const (
+ // FileAccessedKey is the attribute Key conforming to the "file.accessed"
+ // semantic conventions. It represents the time when the file was last accessed,
+ // in ISO 8601 format.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "2021-01-01T12:00:00Z"
+ // Note: This attribute might not be supported by some file systems — NFS,
+ // FAT32, in embedded OS, etc.
+ FileAccessedKey = attribute.Key("file.accessed")
+
+ // FileAttributesKey is the attribute Key conforming to the "file.attributes"
+ // semantic conventions. It represents the array of file attributes.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "readonly", "hidden"
+ // Note: Attributes names depend on the OS or file system. Here’s a
+ // non-exhaustive list of values expected for this attribute: `archive`,
+ // `compressed`, `directory`, `encrypted`, `execute`, `hidden`, `immutable`,
+ // `journaled`, `read`, `readonly`, `symbolic link`, `system`, `temporary`,
+ // `write`.
+ FileAttributesKey = attribute.Key("file.attributes")
+
+ // FileChangedKey is the attribute Key conforming to the "file.changed" semantic
+ // conventions. It represents the time when the file attributes or metadata was
+ // last changed, in ISO 8601 format.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "2021-01-01T12:00:00Z"
+ // Note: `file.changed` captures the time when any of the file's properties or
+ // attributes (including the content) are changed, while `file.modified`
+ // captures the timestamp when the file content is modified.
+ FileChangedKey = attribute.Key("file.changed")
+
+ // FileCreatedKey is the attribute Key conforming to the "file.created" semantic
+ // conventions. It represents the time when the file was created, in ISO 8601
+ // format.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "2021-01-01T12:00:00Z"
+ // Note: This attribute might not be supported by some file systems — NFS,
+ // FAT32, in embedded OS, etc.
+ FileCreatedKey = attribute.Key("file.created")
+
+ // FileDirectoryKey is the attribute Key conforming to the "file.directory"
+ // semantic conventions. It represents the directory where the file is located.
+ // It should include the drive letter, when appropriate.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "/home/user", "C:\Program Files\MyApp"
+ FileDirectoryKey = attribute.Key("file.directory")
+
+ // FileExtensionKey is the attribute Key conforming to the "file.extension"
+ // semantic conventions. It represents the file extension, excluding the leading
+ // dot.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "png", "gz"
+ // Note: When the file name has multiple extensions (example.tar.gz), only the
+ // last one should be captured ("gz", not "tar.gz").
+ FileExtensionKey = attribute.Key("file.extension")
+
+ // FileForkNameKey is the attribute Key conforming to the "file.fork_name"
+ // semantic conventions. It represents the name of the fork. A fork is
+ // additional data associated with a filesystem object.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Zone.Identifier"
+ // Note: On Linux, a resource fork is used to store additional data with a
+ // filesystem object. A file always has at least one fork for the data portion,
+ // and additional forks may exist.
+ // On NTFS, this is analogous to an Alternate Data Stream (ADS), and the default
+ // data stream for a file is just called $DATA. Zone.Identifier is commonly used
+ // by Windows to track contents downloaded from the Internet. An ADS is
+ // typically of the form: C:\path\to\filename.extension:some_fork_name, and
+ // some_fork_name is the value that should populate `fork_name`.
+ // `filename.extension` should populate `file.name`, and `extension` should
+ // populate `file.extension`. The full path, `file.path`, will include the fork
+ // name.
+ FileForkNameKey = attribute.Key("file.fork_name")
+
+ // FileGroupIDKey is the attribute Key conforming to the "file.group.id"
+ // semantic conventions. It represents the primary Group ID (GID) of the file.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "1000"
+ FileGroupIDKey = attribute.Key("file.group.id")
+
+ // FileGroupNameKey is the attribute Key conforming to the "file.group.name"
+ // semantic conventions. It represents the primary group name of the file.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "users"
+ FileGroupNameKey = attribute.Key("file.group.name")
+
+ // FileInodeKey is the attribute Key conforming to the "file.inode" semantic
+ // conventions. It represents the inode representing the file in the filesystem.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "256383"
+ FileInodeKey = attribute.Key("file.inode")
+
+ // FileModeKey is the attribute Key conforming to the "file.mode" semantic
+ // conventions. It represents the mode of the file in octal representation.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "0640"
+ FileModeKey = attribute.Key("file.mode")
+
+ // FileModifiedKey is the attribute Key conforming to the "file.modified"
+ // semantic conventions. It represents the time when the file content was last
+ // modified, in ISO 8601 format.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "2021-01-01T12:00:00Z"
+ FileModifiedKey = attribute.Key("file.modified")
+
+ // FileNameKey is the attribute Key conforming to the "file.name" semantic
+ // conventions. It represents the name of the file including the extension,
+ // without the directory.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "example.png"
+ FileNameKey = attribute.Key("file.name")
+
+ // FileOwnerIDKey is the attribute Key conforming to the "file.owner.id"
+ // semantic conventions. It represents the user ID (UID) or security identifier
+ // (SID) of the file owner.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "1000"
+ FileOwnerIDKey = attribute.Key("file.owner.id")
+
+ // FileOwnerNameKey is the attribute Key conforming to the "file.owner.name"
+ // semantic conventions. It represents the username of the file owner.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "root"
+ FileOwnerNameKey = attribute.Key("file.owner.name")
+
+ // FilePathKey is the attribute Key conforming to the "file.path" semantic
+ // conventions. It represents the full path to the file, including the file
+ // name. It should include the drive letter, when appropriate.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "/home/alice/example.png", "C:\Program Files\MyApp\myapp.exe"
+ FilePathKey = attribute.Key("file.path")
+
+ // FileSizeKey is the attribute Key conforming to the "file.size" semantic
+ // conventions. It represents the file size in bytes.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ FileSizeKey = attribute.Key("file.size")
+
+ // FileSymbolicLinkTargetPathKey is the attribute Key conforming to the
+ // "file.symbolic_link.target_path" semantic conventions. It represents the path
+ // to the target of a symbolic link.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "/usr/bin/python3"
+ // Note: This attribute is only applicable to symbolic links.
+ FileSymbolicLinkTargetPathKey = attribute.Key("file.symbolic_link.target_path")
+)
+
+// FileAccessed returns an attribute KeyValue conforming to the "file.accessed"
+// semantic conventions. It represents the time when the file was last accessed,
+// in ISO 8601 format.
+func FileAccessed(val string) attribute.KeyValue {
+ return FileAccessedKey.String(val)
+}
+
+// FileAttributes returns an attribute KeyValue conforming to the
+// "file.attributes" semantic conventions. It represents the array of file
+// attributes.
+func FileAttributes(val ...string) attribute.KeyValue {
+ return FileAttributesKey.StringSlice(val)
+}
+
+// FileChanged returns an attribute KeyValue conforming to the "file.changed"
+// semantic conventions. It represents the time when the file attributes or
+// metadata was last changed, in ISO 8601 format.
+func FileChanged(val string) attribute.KeyValue {
+ return FileChangedKey.String(val)
+}
+
+// FileCreated returns an attribute KeyValue conforming to the "file.created"
+// semantic conventions. It represents the time when the file was created, in ISO
+// 8601 format.
+func FileCreated(val string) attribute.KeyValue {
+ return FileCreatedKey.String(val)
+}
+
+// FileDirectory returns an attribute KeyValue conforming to the "file.directory"
+// semantic conventions. It represents the directory where the file is located.
+// It should include the drive letter, when appropriate.
+func FileDirectory(val string) attribute.KeyValue {
+ return FileDirectoryKey.String(val)
+}
+
+// FileExtension returns an attribute KeyValue conforming to the "file.extension"
+// semantic conventions. It represents the file extension, excluding the leading
+// dot.
+func FileExtension(val string) attribute.KeyValue {
+ return FileExtensionKey.String(val)
+}
+
+// FileForkName returns an attribute KeyValue conforming to the "file.fork_name"
+// semantic conventions. It represents the name of the fork. A fork is additional
+// data associated with a filesystem object.
+func FileForkName(val string) attribute.KeyValue {
+ return FileForkNameKey.String(val)
+}
+
+// FileGroupID returns an attribute KeyValue conforming to the "file.group.id"
+// semantic conventions. It represents the primary Group ID (GID) of the file.
+func FileGroupID(val string) attribute.KeyValue {
+ return FileGroupIDKey.String(val)
+}
+
+// FileGroupName returns an attribute KeyValue conforming to the
+// "file.group.name" semantic conventions. It represents the primary group name
+// of the file.
+func FileGroupName(val string) attribute.KeyValue {
+ return FileGroupNameKey.String(val)
+}
+
+// FileInode returns an attribute KeyValue conforming to the "file.inode"
+// semantic conventions. It represents the inode representing the file in the
+// filesystem.
+func FileInode(val string) attribute.KeyValue {
+ return FileInodeKey.String(val)
+}
+
+// FileMode returns an attribute KeyValue conforming to the "file.mode" semantic
+// conventions. It represents the mode of the file in octal representation.
+func FileMode(val string) attribute.KeyValue {
+ return FileModeKey.String(val)
+}
+
+// FileModified returns an attribute KeyValue conforming to the "file.modified"
+// semantic conventions. It represents the time when the file content was last
+// modified, in ISO 8601 format.
+func FileModified(val string) attribute.KeyValue {
+ return FileModifiedKey.String(val)
+}
+
+// FileName returns an attribute KeyValue conforming to the "file.name" semantic
+// conventions. It represents the name of the file including the extension,
+// without the directory.
+func FileName(val string) attribute.KeyValue {
+ return FileNameKey.String(val)
+}
+
+// FileOwnerID returns an attribute KeyValue conforming to the "file.owner.id"
+// semantic conventions. It represents the user ID (UID) or security identifier
+// (SID) of the file owner.
+func FileOwnerID(val string) attribute.KeyValue {
+ return FileOwnerIDKey.String(val)
+}
+
+// FileOwnerName returns an attribute KeyValue conforming to the
+// "file.owner.name" semantic conventions. It represents the username of the file
+// owner.
+func FileOwnerName(val string) attribute.KeyValue {
+ return FileOwnerNameKey.String(val)
+}
+
+// FilePath returns an attribute KeyValue conforming to the "file.path" semantic
+// conventions. It represents the full path to the file, including the file name.
+// It should include the drive letter, when appropriate.
+func FilePath(val string) attribute.KeyValue {
+ return FilePathKey.String(val)
+}
+
+// FileSize returns an attribute KeyValue conforming to the "file.size" semantic
+// conventions. It represents the file size in bytes.
+func FileSize(val int) attribute.KeyValue {
+ return FileSizeKey.Int(val)
+}
+
+// FileSymbolicLinkTargetPath returns an attribute KeyValue conforming to the
+// "file.symbolic_link.target_path" semantic conventions. It represents the path
+// to the target of a symbolic link.
+func FileSymbolicLinkTargetPath(val string) attribute.KeyValue {
+ return FileSymbolicLinkTargetPathKey.String(val)
+}
+
+// Namespace: gcp
+const (
+ // GCPAppHubApplicationContainerKey is the attribute Key conforming to the
+ // "gcp.apphub.application.container" semantic conventions. It represents the
+ // container within GCP where the AppHub application is defined.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "projects/my-container-project"
+ GCPAppHubApplicationContainerKey = attribute.Key("gcp.apphub.application.container")
+
+ // GCPAppHubApplicationIDKey is the attribute Key conforming to the
+ // "gcp.apphub.application.id" semantic conventions. It represents the name of
+ // the application as configured in AppHub.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "my-application"
+ GCPAppHubApplicationIDKey = attribute.Key("gcp.apphub.application.id")
+
+ // GCPAppHubApplicationLocationKey is the attribute Key conforming to the
+ // "gcp.apphub.application.location" semantic conventions. It represents the GCP
+ // zone or region where the application is defined.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "us-central1"
+ GCPAppHubApplicationLocationKey = attribute.Key("gcp.apphub.application.location")
+
+ // GCPAppHubServiceCriticalityTypeKey is the attribute Key conforming to the
+ // "gcp.apphub.service.criticality_type" semantic conventions. It represents the
+ // criticality of a service indicates its importance to the business.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // Note: [See AppHub type enum]
+ //
+ // [See AppHub type enum]: https://cloud.google.com/app-hub/docs/reference/rest/v1/Attributes#type
+ GCPAppHubServiceCriticalityTypeKey = attribute.Key("gcp.apphub.service.criticality_type")
+
+ // GCPAppHubServiceEnvironmentTypeKey is the attribute Key conforming to the
+ // "gcp.apphub.service.environment_type" semantic conventions. It represents the
+ // environment of a service is the stage of a software lifecycle.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // Note: [See AppHub environment type]
+ //
+ // [See AppHub environment type]: https://cloud.google.com/app-hub/docs/reference/rest/v1/Attributes#type_1
+ GCPAppHubServiceEnvironmentTypeKey = attribute.Key("gcp.apphub.service.environment_type")
+
+ // GCPAppHubServiceIDKey is the attribute Key conforming to the
+ // "gcp.apphub.service.id" semantic conventions. It represents the name of the
+ // service as configured in AppHub.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "my-service"
+ GCPAppHubServiceIDKey = attribute.Key("gcp.apphub.service.id")
+
+ // GCPAppHubWorkloadCriticalityTypeKey is the attribute Key conforming to the
+ // "gcp.apphub.workload.criticality_type" semantic conventions. It represents
+ // the criticality of a workload indicates its importance to the business.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // Note: [See AppHub type enum]
+ //
+ // [See AppHub type enum]: https://cloud.google.com/app-hub/docs/reference/rest/v1/Attributes#type
+ GCPAppHubWorkloadCriticalityTypeKey = attribute.Key("gcp.apphub.workload.criticality_type")
+
+ // GCPAppHubWorkloadEnvironmentTypeKey is the attribute Key conforming to the
+ // "gcp.apphub.workload.environment_type" semantic conventions. It represents
+ // the environment of a workload is the stage of a software lifecycle.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // Note: [See AppHub environment type]
+ //
+ // [See AppHub environment type]: https://cloud.google.com/app-hub/docs/reference/rest/v1/Attributes#type_1
+ GCPAppHubWorkloadEnvironmentTypeKey = attribute.Key("gcp.apphub.workload.environment_type")
+
+ // GCPAppHubWorkloadIDKey is the attribute Key conforming to the
+ // "gcp.apphub.workload.id" semantic conventions. It represents the name of the
+ // workload as configured in AppHub.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "my-workload"
+ GCPAppHubWorkloadIDKey = attribute.Key("gcp.apphub.workload.id")
+
+ // GCPClientServiceKey is the attribute Key conforming to the
+ // "gcp.client.service" semantic conventions. It represents the identifies the
+ // Google Cloud service for which the official client library is intended.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "appengine", "run", "firestore", "alloydb", "spanner"
+ // Note: Intended to be a stable identifier for Google Cloud client libraries
+ // that is uniform across implementation languages. The value should be derived
+ // from the canonical service domain for the service; for example,
+ // 'foo.googleapis.com' should result in a value of 'foo'.
+ GCPClientServiceKey = attribute.Key("gcp.client.service")
+
+ // GCPCloudRunJobExecutionKey is the attribute Key conforming to the
+ // "gcp.cloud_run.job.execution" semantic conventions. It represents the name of
+ // the Cloud Run [execution] being run for the Job, as set by the
+ // [`CLOUD_RUN_EXECUTION`] environment variable.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "job-name-xxxx", "sample-job-mdw84"
+ //
+ // [execution]: https://cloud.google.com/run/docs/managing/job-executions
+ // [`CLOUD_RUN_EXECUTION`]: https://cloud.google.com/run/docs/container-contract#jobs-env-vars
+ GCPCloudRunJobExecutionKey = attribute.Key("gcp.cloud_run.job.execution")
+
+ // GCPCloudRunJobTaskIndexKey is the attribute Key conforming to the
+ // "gcp.cloud_run.job.task_index" semantic conventions. It represents the index
+ // for a task within an execution as provided by the [`CLOUD_RUN_TASK_INDEX`]
+ // environment variable.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 0, 1
+ //
+ // [`CLOUD_RUN_TASK_INDEX`]: https://cloud.google.com/run/docs/container-contract#jobs-env-vars
+ GCPCloudRunJobTaskIndexKey = attribute.Key("gcp.cloud_run.job.task_index")
+
+ // GCPGCEInstanceHostnameKey is the attribute Key conforming to the
+ // "gcp.gce.instance.hostname" semantic conventions. It represents the hostname
+ // of a GCE instance. This is the full value of the default or [custom hostname]
+ // .
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "my-host1234.example.com",
+ // "sample-vm.us-west1-b.c.my-project.internal"
+ //
+ // [custom hostname]: https://cloud.google.com/compute/docs/instances/custom-hostname-vm
+ GCPGCEInstanceHostnameKey = attribute.Key("gcp.gce.instance.hostname")
+
+ // GCPGCEInstanceNameKey is the attribute Key conforming to the
+ // "gcp.gce.instance.name" semantic conventions. It represents the instance name
+ // of a GCE instance. This is the value provided by `host.name`, the visible
+ // name of the instance in the Cloud Console UI, and the prefix for the default
+ // hostname of the instance as defined by the [default internal DNS name].
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "instance-1", "my-vm-name"
+ //
+ // [default internal DNS name]: https://cloud.google.com/compute/docs/internal-dns#instance-fully-qualified-domain-names
+ GCPGCEInstanceNameKey = attribute.Key("gcp.gce.instance.name")
+)
+
+// GCPAppHubApplicationContainer returns an attribute KeyValue conforming to the
+// "gcp.apphub.application.container" semantic conventions. It represents the
+// container within GCP where the AppHub application is defined.
+func GCPAppHubApplicationContainer(val string) attribute.KeyValue {
+ return GCPAppHubApplicationContainerKey.String(val)
+}
+
+// GCPAppHubApplicationID returns an attribute KeyValue conforming to the
+// "gcp.apphub.application.id" semantic conventions. It represents the name of
+// the application as configured in AppHub.
+func GCPAppHubApplicationID(val string) attribute.KeyValue {
+ return GCPAppHubApplicationIDKey.String(val)
+}
+
+// GCPAppHubApplicationLocation returns an attribute KeyValue conforming to the
+// "gcp.apphub.application.location" semantic conventions. It represents the GCP
+// zone or region where the application is defined.
+func GCPAppHubApplicationLocation(val string) attribute.KeyValue {
+ return GCPAppHubApplicationLocationKey.String(val)
+}
+
+// GCPAppHubServiceID returns an attribute KeyValue conforming to the
+// "gcp.apphub.service.id" semantic conventions. It represents the name of the
+// service as configured in AppHub.
+func GCPAppHubServiceID(val string) attribute.KeyValue {
+ return GCPAppHubServiceIDKey.String(val)
+}
+
+// GCPAppHubWorkloadID returns an attribute KeyValue conforming to the
+// "gcp.apphub.workload.id" semantic conventions. It represents the name of the
+// workload as configured in AppHub.
+func GCPAppHubWorkloadID(val string) attribute.KeyValue {
+ return GCPAppHubWorkloadIDKey.String(val)
+}
+
+// GCPClientService returns an attribute KeyValue conforming to the
+// "gcp.client.service" semantic conventions. It represents the identifies the
+// Google Cloud service for which the official client library is intended.
+func GCPClientService(val string) attribute.KeyValue {
+ return GCPClientServiceKey.String(val)
+}
+
+// GCPCloudRunJobExecution returns an attribute KeyValue conforming to the
+// "gcp.cloud_run.job.execution" semantic conventions. It represents the name of
+// the Cloud Run [execution] being run for the Job, as set by the
+// [`CLOUD_RUN_EXECUTION`] environment variable.
+//
+// [execution]: https://cloud.google.com/run/docs/managing/job-executions
+// [`CLOUD_RUN_EXECUTION`]: https://cloud.google.com/run/docs/container-contract#jobs-env-vars
+func GCPCloudRunJobExecution(val string) attribute.KeyValue {
+ return GCPCloudRunJobExecutionKey.String(val)
+}
+
+// GCPCloudRunJobTaskIndex returns an attribute KeyValue conforming to the
+// "gcp.cloud_run.job.task_index" semantic conventions. It represents the index
+// for a task within an execution as provided by the [`CLOUD_RUN_TASK_INDEX`]
+// environment variable.
+//
+// [`CLOUD_RUN_TASK_INDEX`]: https://cloud.google.com/run/docs/container-contract#jobs-env-vars
+func GCPCloudRunJobTaskIndex(val int) attribute.KeyValue {
+ return GCPCloudRunJobTaskIndexKey.Int(val)
+}
+
+// GCPGCEInstanceHostname returns an attribute KeyValue conforming to the
+// "gcp.gce.instance.hostname" semantic conventions. It represents the hostname
+// of a GCE instance. This is the full value of the default or [custom hostname]
+// .
+//
+// [custom hostname]: https://cloud.google.com/compute/docs/instances/custom-hostname-vm
+func GCPGCEInstanceHostname(val string) attribute.KeyValue {
+ return GCPGCEInstanceHostnameKey.String(val)
+}
+
+// GCPGCEInstanceName returns an attribute KeyValue conforming to the
+// "gcp.gce.instance.name" semantic conventions. It represents the instance name
+// of a GCE instance. This is the value provided by `host.name`, the visible name
+// of the instance in the Cloud Console UI, and the prefix for the default
+// hostname of the instance as defined by the [default internal DNS name].
+//
+// [default internal DNS name]: https://cloud.google.com/compute/docs/internal-dns#instance-fully-qualified-domain-names
+func GCPGCEInstanceName(val string) attribute.KeyValue {
+ return GCPGCEInstanceNameKey.String(val)
+}
+
+// Enum values for gcp.apphub.service.criticality_type
+var (
+ // Mission critical service.
+ // Stability: development
+ GCPAppHubServiceCriticalityTypeMissionCritical = GCPAppHubServiceCriticalityTypeKey.String("MISSION_CRITICAL")
+ // High impact.
+ // Stability: development
+ GCPAppHubServiceCriticalityTypeHigh = GCPAppHubServiceCriticalityTypeKey.String("HIGH")
+ // Medium impact.
+ // Stability: development
+ GCPAppHubServiceCriticalityTypeMedium = GCPAppHubServiceCriticalityTypeKey.String("MEDIUM")
+ // Low impact.
+ // Stability: development
+ GCPAppHubServiceCriticalityTypeLow = GCPAppHubServiceCriticalityTypeKey.String("LOW")
+)
+
+// Enum values for gcp.apphub.service.environment_type
+var (
+ // Production environment.
+ // Stability: development
+ GCPAppHubServiceEnvironmentTypeProduction = GCPAppHubServiceEnvironmentTypeKey.String("PRODUCTION")
+ // Staging environment.
+ // Stability: development
+ GCPAppHubServiceEnvironmentTypeStaging = GCPAppHubServiceEnvironmentTypeKey.String("STAGING")
+ // Test environment.
+ // Stability: development
+ GCPAppHubServiceEnvironmentTypeTest = GCPAppHubServiceEnvironmentTypeKey.String("TEST")
+ // Development environment.
+ // Stability: development
+ GCPAppHubServiceEnvironmentTypeDevelopment = GCPAppHubServiceEnvironmentTypeKey.String("DEVELOPMENT")
+)
+
+// Enum values for gcp.apphub.workload.criticality_type
+var (
+ // Mission critical service.
+ // Stability: development
+ GCPAppHubWorkloadCriticalityTypeMissionCritical = GCPAppHubWorkloadCriticalityTypeKey.String("MISSION_CRITICAL")
+ // High impact.
+ // Stability: development
+ GCPAppHubWorkloadCriticalityTypeHigh = GCPAppHubWorkloadCriticalityTypeKey.String("HIGH")
+ // Medium impact.
+ // Stability: development
+ GCPAppHubWorkloadCriticalityTypeMedium = GCPAppHubWorkloadCriticalityTypeKey.String("MEDIUM")
+ // Low impact.
+ // Stability: development
+ GCPAppHubWorkloadCriticalityTypeLow = GCPAppHubWorkloadCriticalityTypeKey.String("LOW")
+)
+
+// Enum values for gcp.apphub.workload.environment_type
+var (
+ // Production environment.
+ // Stability: development
+ GCPAppHubWorkloadEnvironmentTypeProduction = GCPAppHubWorkloadEnvironmentTypeKey.String("PRODUCTION")
+ // Staging environment.
+ // Stability: development
+ GCPAppHubWorkloadEnvironmentTypeStaging = GCPAppHubWorkloadEnvironmentTypeKey.String("STAGING")
+ // Test environment.
+ // Stability: development
+ GCPAppHubWorkloadEnvironmentTypeTest = GCPAppHubWorkloadEnvironmentTypeKey.String("TEST")
+ // Development environment.
+ // Stability: development
+ GCPAppHubWorkloadEnvironmentTypeDevelopment = GCPAppHubWorkloadEnvironmentTypeKey.String("DEVELOPMENT")
+)
+
+// Namespace: gen_ai
+const (
+ // GenAIAgentDescriptionKey is the attribute Key conforming to the
+ // "gen_ai.agent.description" semantic conventions. It represents the free-form
+ // description of the GenAI agent provided by the application.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Helps with math problems", "Generates fiction stories"
+ GenAIAgentDescriptionKey = attribute.Key("gen_ai.agent.description")
+
+ // GenAIAgentIDKey is the attribute Key conforming to the "gen_ai.agent.id"
+ // semantic conventions. It represents the unique identifier of the GenAI agent.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "asst_5j66UpCpwteGg4YSxUnt7lPY"
+ GenAIAgentIDKey = attribute.Key("gen_ai.agent.id")
+
+ // GenAIAgentNameKey is the attribute Key conforming to the "gen_ai.agent.name"
+ // semantic conventions. It represents the human-readable name of the GenAI
+ // agent provided by the application.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Math Tutor", "Fiction Writer"
+ GenAIAgentNameKey = attribute.Key("gen_ai.agent.name")
+
+ // GenAIConversationIDKey is the attribute Key conforming to the
+ // "gen_ai.conversation.id" semantic conventions. It represents the unique
+ // identifier for a conversation (session, thread), used to store and correlate
+ // messages within this conversation.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "conv_5j66UpCpwteGg4YSxUnt7lPY"
+ GenAIConversationIDKey = attribute.Key("gen_ai.conversation.id")
+
+ // GenAIDataSourceIDKey is the attribute Key conforming to the
+ // "gen_ai.data_source.id" semantic conventions. It represents the data source
+ // identifier.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "H7STPQYOND"
+ // Note: Data sources are used by AI agents and RAG applications to store
+ // grounding data. A data source may be an external database, object store,
+ // document collection, website, or any other storage system used by the GenAI
+ // agent or application. The `gen_ai.data_source.id` SHOULD match the identifier
+ // used by the GenAI system rather than a name specific to the external storage,
+ // such as a database or object store. Semantic conventions referencing
+ // `gen_ai.data_source.id` MAY also leverage additional attributes, such as
+ // `db.*`, to further identify and describe the data source.
+ GenAIDataSourceIDKey = attribute.Key("gen_ai.data_source.id")
+
+ // GenAIInputMessagesKey is the attribute Key conforming to the
+ // "gen_ai.input.messages" semantic conventions. It represents the chat history
+ // provided to the model as an input.
+ //
+ // Type: any
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "[\n {\n "role": "user",\n "parts": [\n {\n "type": "text",\n
+ // "content": "Weather in Paris?"\n }\n ]\n },\n {\n "role": "assistant",\n
+ // "parts": [\n {\n "type": "tool_call",\n "id":
+ // "call_VSPygqKTWdrhaFErNvMV18Yl",\n "name": "get_weather",\n "arguments": {\n
+ // "location": "Paris"\n }\n }\n ]\n },\n {\n "role": "tool",\n "parts": [\n {\n
+ // "type": "tool_call_response",\n "id": " call_VSPygqKTWdrhaFErNvMV18Yl",\n
+ // "result": "rainy, 57°F"\n }\n ]\n }\n]\n"
+ // Note: Instrumentations MUST follow [Input messages JSON schema].
+ // When the attribute is recorded on events, it MUST be recorded in structured
+ // form. When recorded on spans, it MAY be recorded as a JSON string if
+ // structured
+ // format is not supported and SHOULD be recorded in structured form otherwise.
+ //
+ // Messages MUST be provided in the order they were sent to the model.
+ // Instrumentations MAY provide a way for users to filter or truncate
+ // input messages.
+ //
+ // > [!Warning]
+ // > This attribute is likely to contain sensitive information including
+ // > user/PII data.
+ //
+ // See [Recording content on attributes]
+ // section for more details.
+ //
+ // [Input messages JSON schema]: /docs/gen-ai/gen-ai-input-messages.json
+ // [Recording content on attributes]: /docs/gen-ai/gen-ai-spans.md#recording-content-on-attributes
+ GenAIInputMessagesKey = attribute.Key("gen_ai.input.messages")
+
+ // GenAIOperationNameKey is the attribute Key conforming to the
+ // "gen_ai.operation.name" semantic conventions. It represents the name of the
+ // operation being performed.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // Note: If one of the predefined values applies, but specific system uses a
+ // different name it's RECOMMENDED to document it in the semantic conventions
+ // for specific GenAI system and use system-specific name in the
+ // instrumentation. If a different name is not documented, instrumentation
+ // libraries SHOULD use applicable predefined value.
+ GenAIOperationNameKey = attribute.Key("gen_ai.operation.name")
+
+ // GenAIOutputMessagesKey is the attribute Key conforming to the
+ // "gen_ai.output.messages" semantic conventions. It represents the messages
+ // returned by the model where each message represents a specific model response
+ // (choice, candidate).
+ //
+ // Type: any
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "[\n {\n "role": "assistant",\n "parts": [\n {\n "type": "text",\n
+ // "content": "The weather in Paris is currently rainy with a temperature of
+ // 57°F."\n }\n ],\n "finish_reason": "stop"\n }\n]\n"
+ // Note: Instrumentations MUST follow [Output messages JSON schema]
+ //
+ // Each message represents a single output choice/candidate generated by
+ // the model. Each message corresponds to exactly one generation
+ // (choice/candidate) and vice versa - one choice cannot be split across
+ // multiple messages or one message cannot contain parts from multiple choices.
+ //
+ // When the attribute is recorded on events, it MUST be recorded in structured
+ // form. When recorded on spans, it MAY be recorded as a JSON string if
+ // structured
+ // format is not supported and SHOULD be recorded in structured form otherwise.
+ //
+ // Instrumentations MAY provide a way for users to filter or truncate
+ // output messages.
+ //
+ // > [!Warning]
+ // > This attribute is likely to contain sensitive information including
+ // > user/PII data.
+ //
+ // See [Recording content on attributes]
+ // section for more details.
+ //
+ // [Output messages JSON schema]: /docs/gen-ai/gen-ai-output-messages.json
+ // [Recording content on attributes]: /docs/gen-ai/gen-ai-spans.md#recording-content-on-attributes
+ GenAIOutputMessagesKey = attribute.Key("gen_ai.output.messages")
+
+ // GenAIOutputTypeKey is the attribute Key conforming to the
+ // "gen_ai.output.type" semantic conventions. It represents the represents the
+ // content type requested by the client.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // Note: This attribute SHOULD be used when the client requests output of a
+ // specific type. The model may return zero or more outputs of this type.
+ // This attribute specifies the output modality and not the actual output
+ // format. For example, if an image is requested, the actual output could be a
+ // URL pointing to an image file.
+ // Additional output format details may be recorded in the future in the
+ // `gen_ai.output.{type}.*` attributes.
+ GenAIOutputTypeKey = attribute.Key("gen_ai.output.type")
+
+ // GenAIProviderNameKey is the attribute Key conforming to the
+ // "gen_ai.provider.name" semantic conventions. It represents the Generative AI
+ // provider as identified by the client or server instrumentation.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // Note: The attribute SHOULD be set based on the instrumentation's best
+ // knowledge and may differ from the actual model provider.
+ //
+ // Multiple providers, including Azure OpenAI, Gemini, and AI hosting platforms
+ // are accessible using the OpenAI REST API and corresponding client libraries,
+ // but may proxy or host models from different providers.
+ //
+ // The `gen_ai.request.model`, `gen_ai.response.model`, and `server.address`
+ // attributes may help identify the actual system in use.
+ //
+ // The `gen_ai.provider.name` attribute acts as a discriminator that
+ // identifies the GenAI telemetry format flavor specific to that provider
+ // within GenAI semantic conventions.
+ // It SHOULD be set consistently with provider-specific attributes and signals.
+ // For example, GenAI spans, metrics, and events related to AWS Bedrock
+ // should have the `gen_ai.provider.name` set to `aws.bedrock` and include
+ // applicable `aws.bedrock.*` attributes and are not expected to include
+ // `openai.*` attributes.
+ GenAIProviderNameKey = attribute.Key("gen_ai.provider.name")
+
+ // GenAIRequestChoiceCountKey is the attribute Key conforming to the
+ // "gen_ai.request.choice.count" semantic conventions. It represents the target
+ // number of candidate completions to return.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 3
+ GenAIRequestChoiceCountKey = attribute.Key("gen_ai.request.choice.count")
+
+ // GenAIRequestEncodingFormatsKey is the attribute Key conforming to the
+ // "gen_ai.request.encoding_formats" semantic conventions. It represents the
+ // encoding formats requested in an embeddings operation, if specified.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "base64"], ["float", "binary"
+ // Note: In some GenAI systems the encoding formats are called embedding types.
+ // Also, some GenAI systems only accept a single format per request.
+ GenAIRequestEncodingFormatsKey = attribute.Key("gen_ai.request.encoding_formats")
+
+ // GenAIRequestFrequencyPenaltyKey is the attribute Key conforming to the
+ // "gen_ai.request.frequency_penalty" semantic conventions. It represents the
+ // frequency penalty setting for the GenAI request.
+ //
+ // Type: double
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 0.1
+ GenAIRequestFrequencyPenaltyKey = attribute.Key("gen_ai.request.frequency_penalty")
+
+ // GenAIRequestMaxTokensKey is the attribute Key conforming to the
+ // "gen_ai.request.max_tokens" semantic conventions. It represents the maximum
+ // number of tokens the model generates for a request.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 100
+ GenAIRequestMaxTokensKey = attribute.Key("gen_ai.request.max_tokens")
+
+ // GenAIRequestModelKey is the attribute Key conforming to the
+ // "gen_ai.request.model" semantic conventions. It represents the name of the
+ // GenAI model a request is being made to.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: gpt-4
+ GenAIRequestModelKey = attribute.Key("gen_ai.request.model")
+
+ // GenAIRequestPresencePenaltyKey is the attribute Key conforming to the
+ // "gen_ai.request.presence_penalty" semantic conventions. It represents the
+ // presence penalty setting for the GenAI request.
+ //
+ // Type: double
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 0.1
+ GenAIRequestPresencePenaltyKey = attribute.Key("gen_ai.request.presence_penalty")
+
+ // GenAIRequestSeedKey is the attribute Key conforming to the
+ // "gen_ai.request.seed" semantic conventions. It represents the requests with
+ // same seed value more likely to return same result.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 100
+ GenAIRequestSeedKey = attribute.Key("gen_ai.request.seed")
+
+ // GenAIRequestStopSequencesKey is the attribute Key conforming to the
+ // "gen_ai.request.stop_sequences" semantic conventions. It represents the list
+ // of sequences that the model will use to stop generating further tokens.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "forest", "lived"
+ GenAIRequestStopSequencesKey = attribute.Key("gen_ai.request.stop_sequences")
+
+ // GenAIRequestTemperatureKey is the attribute Key conforming to the
+ // "gen_ai.request.temperature" semantic conventions. It represents the
+ // temperature setting for the GenAI request.
+ //
+ // Type: double
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 0.0
+ GenAIRequestTemperatureKey = attribute.Key("gen_ai.request.temperature")
+
+ // GenAIRequestTopKKey is the attribute Key conforming to the
+ // "gen_ai.request.top_k" semantic conventions. It represents the top_k sampling
+ // setting for the GenAI request.
+ //
+ // Type: double
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 1.0
+ GenAIRequestTopKKey = attribute.Key("gen_ai.request.top_k")
+
+ // GenAIRequestTopPKey is the attribute Key conforming to the
+ // "gen_ai.request.top_p" semantic conventions. It represents the top_p sampling
+ // setting for the GenAI request.
+ //
+ // Type: double
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 1.0
+ GenAIRequestTopPKey = attribute.Key("gen_ai.request.top_p")
+
+ // GenAIResponseFinishReasonsKey is the attribute Key conforming to the
+ // "gen_ai.response.finish_reasons" semantic conventions. It represents the
+ // array of reasons the model stopped generating tokens, corresponding to each
+ // generation received.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "stop"], ["stop", "length"
+ GenAIResponseFinishReasonsKey = attribute.Key("gen_ai.response.finish_reasons")
+
+ // GenAIResponseIDKey is the attribute Key conforming to the
+ // "gen_ai.response.id" semantic conventions. It represents the unique
+ // identifier for the completion.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "chatcmpl-123"
+ GenAIResponseIDKey = attribute.Key("gen_ai.response.id")
+
+ // GenAIResponseModelKey is the attribute Key conforming to the
+ // "gen_ai.response.model" semantic conventions. It represents the name of the
+ // model that generated the response.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "gpt-4-0613"
+ GenAIResponseModelKey = attribute.Key("gen_ai.response.model")
+
+ // GenAISystemInstructionsKey is the attribute Key conforming to the
+ // "gen_ai.system_instructions" semantic conventions. It represents the system
+ // message or instructions provided to the GenAI model separately from the chat
+ // history.
+ //
+ // Type: any
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "[\n {\n "type": "text",\n "content": "You are an Agent that greet
+ // users, always use greetings tool to respond"\n }\n]\n", "[\n {\n "type":
+ // "text",\n "content": "You are a language translator."\n },\n {\n "type":
+ // "text",\n "content": "Your mission is to translate text in English to
+ // French."\n }\n]\n"
+ // Note: This attribute SHOULD be used when the corresponding provider or API
+ // allows to provide system instructions or messages separately from the
+ // chat history.
+ //
+ // Instructions that are part of the chat history SHOULD be recorded in
+ // `gen_ai.input.messages` attribute instead.
+ //
+ // Instrumentations MUST follow [System instructions JSON schema].
+ //
+ // When recorded on spans, it MAY be recorded as a JSON string if structured
+ // format is not supported and SHOULD be recorded in structured form otherwise.
+ //
+ // Instrumentations MAY provide a way for users to filter or truncate
+ // system instructions.
+ //
+ // > [!Warning]
+ // > This attribute may contain sensitive information.
+ //
+ // See [Recording content on attributes]
+ // section for more details.
+ //
+ // [System instructions JSON schema]: /docs/gen-ai/gen-ai-system-instructions.json
+ // [Recording content on attributes]: /docs/gen-ai/gen-ai-spans.md#recording-content-on-attributes
+ GenAISystemInstructionsKey = attribute.Key("gen_ai.system_instructions")
+
+ // GenAITokenTypeKey is the attribute Key conforming to the "gen_ai.token.type"
+ // semantic conventions. It represents the type of token being counted.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "input", "output"
+ GenAITokenTypeKey = attribute.Key("gen_ai.token.type")
+
+ // GenAIToolCallIDKey is the attribute Key conforming to the
+ // "gen_ai.tool.call.id" semantic conventions. It represents the tool call
+ // identifier.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "call_mszuSIzqtI65i1wAUOE8w5H4"
+ GenAIToolCallIDKey = attribute.Key("gen_ai.tool.call.id")
+
+ // GenAIToolDescriptionKey is the attribute Key conforming to the
+ // "gen_ai.tool.description" semantic conventions. It represents the tool
+ // description.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Multiply two numbers"
+ GenAIToolDescriptionKey = attribute.Key("gen_ai.tool.description")
+
+ // GenAIToolNameKey is the attribute Key conforming to the "gen_ai.tool.name"
+ // semantic conventions. It represents the name of the tool utilized by the
+ // agent.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Flights"
+ GenAIToolNameKey = attribute.Key("gen_ai.tool.name")
+
+ // GenAIToolTypeKey is the attribute Key conforming to the "gen_ai.tool.type"
+ // semantic conventions. It represents the type of the tool utilized by the
+ // agent.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "function", "extension", "datastore"
+ // Note: Extension: A tool executed on the agent-side to directly call external
+ // APIs, bridging the gap between the agent and real-world systems.
+ // Agent-side operations involve actions that are performed by the agent on the
+ // server or within the agent's controlled environment.
+ // Function: A tool executed on the client-side, where the agent generates
+ // parameters for a predefined function, and the client executes the logic.
+ // Client-side operations are actions taken on the user's end or within the
+ // client application.
+ // Datastore: A tool used by the agent to access and query structured or
+ // unstructured external data for retrieval-augmented tasks or knowledge
+ // updates.
+ GenAIToolTypeKey = attribute.Key("gen_ai.tool.type")
+
+ // GenAIUsageInputTokensKey is the attribute Key conforming to the
+ // "gen_ai.usage.input_tokens" semantic conventions. It represents the number of
+ // tokens used in the GenAI input (prompt).
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 100
+ GenAIUsageInputTokensKey = attribute.Key("gen_ai.usage.input_tokens")
+
+ // GenAIUsageOutputTokensKey is the attribute Key conforming to the
+ // "gen_ai.usage.output_tokens" semantic conventions. It represents the number
+ // of tokens used in the GenAI response (completion).
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 180
+ GenAIUsageOutputTokensKey = attribute.Key("gen_ai.usage.output_tokens")
+)
+
+// GenAIAgentDescription returns an attribute KeyValue conforming to the
+// "gen_ai.agent.description" semantic conventions. It represents the free-form
+// description of the GenAI agent provided by the application.
+func GenAIAgentDescription(val string) attribute.KeyValue {
+ return GenAIAgentDescriptionKey.String(val)
+}
+
+// GenAIAgentID returns an attribute KeyValue conforming to the "gen_ai.agent.id"
+// semantic conventions. It represents the unique identifier of the GenAI agent.
+func GenAIAgentID(val string) attribute.KeyValue {
+ return GenAIAgentIDKey.String(val)
+}
+
+// GenAIAgentName returns an attribute KeyValue conforming to the
+// "gen_ai.agent.name" semantic conventions. It represents the human-readable
+// name of the GenAI agent provided by the application.
+func GenAIAgentName(val string) attribute.KeyValue {
+ return GenAIAgentNameKey.String(val)
+}
+
+// GenAIConversationID returns an attribute KeyValue conforming to the
+// "gen_ai.conversation.id" semantic conventions. It represents the unique
+// identifier for a conversation (session, thread), used to store and correlate
+// messages within this conversation.
+func GenAIConversationID(val string) attribute.KeyValue {
+ return GenAIConversationIDKey.String(val)
+}
+
+// GenAIDataSourceID returns an attribute KeyValue conforming to the
+// "gen_ai.data_source.id" semantic conventions. It represents the data source
+// identifier.
+func GenAIDataSourceID(val string) attribute.KeyValue {
+ return GenAIDataSourceIDKey.String(val)
+}
+
+// GenAIRequestChoiceCount returns an attribute KeyValue conforming to the
+// "gen_ai.request.choice.count" semantic conventions. It represents the target
+// number of candidate completions to return.
+func GenAIRequestChoiceCount(val int) attribute.KeyValue {
+ return GenAIRequestChoiceCountKey.Int(val)
+}
+
+// GenAIRequestEncodingFormats returns an attribute KeyValue conforming to the
+// "gen_ai.request.encoding_formats" semantic conventions. It represents the
+// encoding formats requested in an embeddings operation, if specified.
+func GenAIRequestEncodingFormats(val ...string) attribute.KeyValue {
+ return GenAIRequestEncodingFormatsKey.StringSlice(val)
+}
+
+// GenAIRequestFrequencyPenalty returns an attribute KeyValue conforming to the
+// "gen_ai.request.frequency_penalty" semantic conventions. It represents the
+// frequency penalty setting for the GenAI request.
+func GenAIRequestFrequencyPenalty(val float64) attribute.KeyValue {
+ return GenAIRequestFrequencyPenaltyKey.Float64(val)
+}
+
+// GenAIRequestMaxTokens returns an attribute KeyValue conforming to the
+// "gen_ai.request.max_tokens" semantic conventions. It represents the maximum
+// number of tokens the model generates for a request.
+func GenAIRequestMaxTokens(val int) attribute.KeyValue {
+ return GenAIRequestMaxTokensKey.Int(val)
+}
+
+// GenAIRequestModel returns an attribute KeyValue conforming to the
+// "gen_ai.request.model" semantic conventions. It represents the name of the
+// GenAI model a request is being made to.
+func GenAIRequestModel(val string) attribute.KeyValue {
+ return GenAIRequestModelKey.String(val)
+}
+
+// GenAIRequestPresencePenalty returns an attribute KeyValue conforming to the
+// "gen_ai.request.presence_penalty" semantic conventions. It represents the
+// presence penalty setting for the GenAI request.
+func GenAIRequestPresencePenalty(val float64) attribute.KeyValue {
+ return GenAIRequestPresencePenaltyKey.Float64(val)
+}
+
+// GenAIRequestSeed returns an attribute KeyValue conforming to the
+// "gen_ai.request.seed" semantic conventions. It represents the requests with
+// same seed value more likely to return same result.
+func GenAIRequestSeed(val int) attribute.KeyValue {
+ return GenAIRequestSeedKey.Int(val)
+}
+
+// GenAIRequestStopSequences returns an attribute KeyValue conforming to the
+// "gen_ai.request.stop_sequences" semantic conventions. It represents the list
+// of sequences that the model will use to stop generating further tokens.
+func GenAIRequestStopSequences(val ...string) attribute.KeyValue {
+ return GenAIRequestStopSequencesKey.StringSlice(val)
+}
+
+// GenAIRequestTemperature returns an attribute KeyValue conforming to the
+// "gen_ai.request.temperature" semantic conventions. It represents the
+// temperature setting for the GenAI request.
+func GenAIRequestTemperature(val float64) attribute.KeyValue {
+ return GenAIRequestTemperatureKey.Float64(val)
+}
+
+// GenAIRequestTopK returns an attribute KeyValue conforming to the
+// "gen_ai.request.top_k" semantic conventions. It represents the top_k sampling
+// setting for the GenAI request.
+func GenAIRequestTopK(val float64) attribute.KeyValue {
+ return GenAIRequestTopKKey.Float64(val)
+}
+
+// GenAIRequestTopP returns an attribute KeyValue conforming to the
+// "gen_ai.request.top_p" semantic conventions. It represents the top_p sampling
+// setting for the GenAI request.
+func GenAIRequestTopP(val float64) attribute.KeyValue {
+ return GenAIRequestTopPKey.Float64(val)
+}
+
+// GenAIResponseFinishReasons returns an attribute KeyValue conforming to the
+// "gen_ai.response.finish_reasons" semantic conventions. It represents the array
+// of reasons the model stopped generating tokens, corresponding to each
+// generation received.
+func GenAIResponseFinishReasons(val ...string) attribute.KeyValue {
+ return GenAIResponseFinishReasonsKey.StringSlice(val)
+}
+
+// GenAIResponseID returns an attribute KeyValue conforming to the
+// "gen_ai.response.id" semantic conventions. It represents the unique identifier
+// for the completion.
+func GenAIResponseID(val string) attribute.KeyValue {
+ return GenAIResponseIDKey.String(val)
+}
+
+// GenAIResponseModel returns an attribute KeyValue conforming to the
+// "gen_ai.response.model" semantic conventions. It represents the name of the
+// model that generated the response.
+func GenAIResponseModel(val string) attribute.KeyValue {
+ return GenAIResponseModelKey.String(val)
+}
+
+// GenAIToolCallID returns an attribute KeyValue conforming to the
+// "gen_ai.tool.call.id" semantic conventions. It represents the tool call
+// identifier.
+func GenAIToolCallID(val string) attribute.KeyValue {
+ return GenAIToolCallIDKey.String(val)
+}
+
+// GenAIToolDescription returns an attribute KeyValue conforming to the
+// "gen_ai.tool.description" semantic conventions. It represents the tool
+// description.
+func GenAIToolDescription(val string) attribute.KeyValue {
+ return GenAIToolDescriptionKey.String(val)
+}
+
+// GenAIToolName returns an attribute KeyValue conforming to the
+// "gen_ai.tool.name" semantic conventions. It represents the name of the tool
+// utilized by the agent.
+func GenAIToolName(val string) attribute.KeyValue {
+ return GenAIToolNameKey.String(val)
+}
+
+// GenAIToolType returns an attribute KeyValue conforming to the
+// "gen_ai.tool.type" semantic conventions. It represents the type of the tool
+// utilized by the agent.
+func GenAIToolType(val string) attribute.KeyValue {
+ return GenAIToolTypeKey.String(val)
+}
+
+// GenAIUsageInputTokens returns an attribute KeyValue conforming to the
+// "gen_ai.usage.input_tokens" semantic conventions. It represents the number of
+// tokens used in the GenAI input (prompt).
+func GenAIUsageInputTokens(val int) attribute.KeyValue {
+ return GenAIUsageInputTokensKey.Int(val)
+}
+
+// GenAIUsageOutputTokens returns an attribute KeyValue conforming to the
+// "gen_ai.usage.output_tokens" semantic conventions. It represents the number of
+// tokens used in the GenAI response (completion).
+func GenAIUsageOutputTokens(val int) attribute.KeyValue {
+ return GenAIUsageOutputTokensKey.Int(val)
+}
+
+// Enum values for gen_ai.operation.name
+var (
+ // Chat completion operation such as [OpenAI Chat API]
+ // Stability: development
+ //
+ // [OpenAI Chat API]: https://platform.openai.com/docs/api-reference/chat
+ GenAIOperationNameChat = GenAIOperationNameKey.String("chat")
+ // Multimodal content generation operation such as [Gemini Generate Content]
+ // Stability: development
+ //
+ // [Gemini Generate Content]: https://ai.google.dev/api/generate-content
+ GenAIOperationNameGenerateContent = GenAIOperationNameKey.String("generate_content")
+ // Text completions operation such as [OpenAI Completions API (Legacy)]
+ // Stability: development
+ //
+ // [OpenAI Completions API (Legacy)]: https://platform.openai.com/docs/api-reference/completions
+ GenAIOperationNameTextCompletion = GenAIOperationNameKey.String("text_completion")
+ // Embeddings operation such as [OpenAI Create embeddings API]
+ // Stability: development
+ //
+ // [OpenAI Create embeddings API]: https://platform.openai.com/docs/api-reference/embeddings/create
+ GenAIOperationNameEmbeddings = GenAIOperationNameKey.String("embeddings")
+ // Create GenAI agent
+ // Stability: development
+ GenAIOperationNameCreateAgent = GenAIOperationNameKey.String("create_agent")
+ // Invoke GenAI agent
+ // Stability: development
+ GenAIOperationNameInvokeAgent = GenAIOperationNameKey.String("invoke_agent")
+ // Execute a tool
+ // Stability: development
+ GenAIOperationNameExecuteTool = GenAIOperationNameKey.String("execute_tool")
+)
+
+// Enum values for gen_ai.output.type
+var (
+ // Plain text
+ // Stability: development
+ GenAIOutputTypeText = GenAIOutputTypeKey.String("text")
+ // JSON object with known or unknown schema
+ // Stability: development
+ GenAIOutputTypeJSON = GenAIOutputTypeKey.String("json")
+ // Image
+ // Stability: development
+ GenAIOutputTypeImage = GenAIOutputTypeKey.String("image")
+ // Speech
+ // Stability: development
+ GenAIOutputTypeSpeech = GenAIOutputTypeKey.String("speech")
+)
+
+// Enum values for gen_ai.provider.name
+var (
+ // [OpenAI]
+ // Stability: development
+ //
+ // [OpenAI]: https://openai.com/
+ GenAIProviderNameOpenAI = GenAIProviderNameKey.String("openai")
+ // Any Google generative AI endpoint
+ // Stability: development
+ GenAIProviderNameGCPGenAI = GenAIProviderNameKey.String("gcp.gen_ai")
+ // [Vertex AI]
+ // Stability: development
+ //
+ // [Vertex AI]: https://cloud.google.com/vertex-ai
+ GenAIProviderNameGCPVertexAI = GenAIProviderNameKey.String("gcp.vertex_ai")
+ // [Gemini]
+ // Stability: development
+ //
+ // [Gemini]: https://cloud.google.com/products/gemini
+ GenAIProviderNameGCPGemini = GenAIProviderNameKey.String("gcp.gemini")
+ // [Anthropic]
+ // Stability: development
+ //
+ // [Anthropic]: https://www.anthropic.com/
+ GenAIProviderNameAnthropic = GenAIProviderNameKey.String("anthropic")
+ // [Cohere]
+ // Stability: development
+ //
+ // [Cohere]: https://cohere.com/
+ GenAIProviderNameCohere = GenAIProviderNameKey.String("cohere")
+ // Azure AI Inference
+ // Stability: development
+ GenAIProviderNameAzureAIInference = GenAIProviderNameKey.String("azure.ai.inference")
+ // [Azure OpenAI]
+ // Stability: development
+ //
+ // [Azure OpenAI]: https://azure.microsoft.com/products/ai-services/openai-service/
+ GenAIProviderNameAzureAIOpenAI = GenAIProviderNameKey.String("azure.ai.openai")
+ // [IBM Watsonx AI]
+ // Stability: development
+ //
+ // [IBM Watsonx AI]: https://www.ibm.com/products/watsonx-ai
+ GenAIProviderNameIBMWatsonxAI = GenAIProviderNameKey.String("ibm.watsonx.ai")
+ // [AWS Bedrock]
+ // Stability: development
+ //
+ // [AWS Bedrock]: https://aws.amazon.com/bedrock
+ GenAIProviderNameAWSBedrock = GenAIProviderNameKey.String("aws.bedrock")
+ // [Perplexity]
+ // Stability: development
+ //
+ // [Perplexity]: https://www.perplexity.ai/
+ GenAIProviderNamePerplexity = GenAIProviderNameKey.String("perplexity")
+ // [xAI]
+ // Stability: development
+ //
+ // [xAI]: https://x.ai/
+ GenAIProviderNameXAI = GenAIProviderNameKey.String("x_ai")
+ // [DeepSeek]
+ // Stability: development
+ //
+ // [DeepSeek]: https://www.deepseek.com/
+ GenAIProviderNameDeepseek = GenAIProviderNameKey.String("deepseek")
+ // [Groq]
+ // Stability: development
+ //
+ // [Groq]: https://groq.com/
+ GenAIProviderNameGroq = GenAIProviderNameKey.String("groq")
+ // [Mistral AI]
+ // Stability: development
+ //
+ // [Mistral AI]: https://mistral.ai/
+ GenAIProviderNameMistralAI = GenAIProviderNameKey.String("mistral_ai")
+)
+
+// Enum values for gen_ai.token.type
+var (
+ // Input tokens (prompt, input, etc.)
+ // Stability: development
+ GenAITokenTypeInput = GenAITokenTypeKey.String("input")
+ // Output tokens (completion, response, etc.)
+ // Stability: development
+ GenAITokenTypeOutput = GenAITokenTypeKey.String("output")
+)
+
+// Namespace: geo
+const (
+ // GeoContinentCodeKey is the attribute Key conforming to the
+ // "geo.continent.code" semantic conventions. It represents the two-letter code
+ // representing continent’s name.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ GeoContinentCodeKey = attribute.Key("geo.continent.code")
+
+ // GeoCountryISOCodeKey is the attribute Key conforming to the
+ // "geo.country.iso_code" semantic conventions. It represents the two-letter ISO
+ // Country Code ([ISO 3166-1 alpha2]).
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "CA"
+ //
+ // [ISO 3166-1 alpha2]: https://wikipedia.org/wiki/ISO_3166-1#Codes
+ GeoCountryISOCodeKey = attribute.Key("geo.country.iso_code")
+
+ // GeoLocalityNameKey is the attribute Key conforming to the "geo.locality.name"
+ // semantic conventions. It represents the locality name. Represents the name of
+ // a city, town, village, or similar populated place.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Montreal", "Berlin"
+ GeoLocalityNameKey = attribute.Key("geo.locality.name")
+
+ // GeoLocationLatKey is the attribute Key conforming to the "geo.location.lat"
+ // semantic conventions. It represents the latitude of the geo location in
+ // [WGS84].
+ //
+ // Type: double
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 45.505918
+ //
+ // [WGS84]: https://wikipedia.org/wiki/World_Geodetic_System#WGS84
+ GeoLocationLatKey = attribute.Key("geo.location.lat")
+
+ // GeoLocationLonKey is the attribute Key conforming to the "geo.location.lon"
+ // semantic conventions. It represents the longitude of the geo location in
+ // [WGS84].
+ //
+ // Type: double
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: -73.61483
+ //
+ // [WGS84]: https://wikipedia.org/wiki/World_Geodetic_System#WGS84
+ GeoLocationLonKey = attribute.Key("geo.location.lon")
+
+ // GeoPostalCodeKey is the attribute Key conforming to the "geo.postal_code"
+ // semantic conventions. It represents the postal code associated with the
+ // location. Values appropriate for this field may also be known as a postcode
+ // or ZIP code and will vary widely from country to country.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "94040"
+ GeoPostalCodeKey = attribute.Key("geo.postal_code")
+
+ // GeoRegionISOCodeKey is the attribute Key conforming to the
+ // "geo.region.iso_code" semantic conventions. It represents the region ISO code
+ // ([ISO 3166-2]).
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "CA-QC"
+ //
+ // [ISO 3166-2]: https://wikipedia.org/wiki/ISO_3166-2
+ GeoRegionISOCodeKey = attribute.Key("geo.region.iso_code")
+)
+
+// GeoCountryISOCode returns an attribute KeyValue conforming to the
+// "geo.country.iso_code" semantic conventions. It represents the two-letter ISO
+// Country Code ([ISO 3166-1 alpha2]).
+//
+// [ISO 3166-1 alpha2]: https://wikipedia.org/wiki/ISO_3166-1#Codes
+func GeoCountryISOCode(val string) attribute.KeyValue {
+ return GeoCountryISOCodeKey.String(val)
+}
+
+// GeoLocalityName returns an attribute KeyValue conforming to the
+// "geo.locality.name" semantic conventions. It represents the locality name.
+// Represents the name of a city, town, village, or similar populated place.
+func GeoLocalityName(val string) attribute.KeyValue {
+ return GeoLocalityNameKey.String(val)
+}
+
+// GeoLocationLat returns an attribute KeyValue conforming to the
+// "geo.location.lat" semantic conventions. It represents the latitude of the geo
+// location in [WGS84].
+//
+// [WGS84]: https://wikipedia.org/wiki/World_Geodetic_System#WGS84
+func GeoLocationLat(val float64) attribute.KeyValue {
+ return GeoLocationLatKey.Float64(val)
+}
+
+// GeoLocationLon returns an attribute KeyValue conforming to the
+// "geo.location.lon" semantic conventions. It represents the longitude of the
+// geo location in [WGS84].
+//
+// [WGS84]: https://wikipedia.org/wiki/World_Geodetic_System#WGS84
+func GeoLocationLon(val float64) attribute.KeyValue {
+ return GeoLocationLonKey.Float64(val)
+}
+
+// GeoPostalCode returns an attribute KeyValue conforming to the
+// "geo.postal_code" semantic conventions. It represents the postal code
+// associated with the location. Values appropriate for this field may also be
+// known as a postcode or ZIP code and will vary widely from country to country.
+func GeoPostalCode(val string) attribute.KeyValue {
+ return GeoPostalCodeKey.String(val)
+}
+
+// GeoRegionISOCode returns an attribute KeyValue conforming to the
+// "geo.region.iso_code" semantic conventions. It represents the region ISO code
+// ([ISO 3166-2]).
+//
+// [ISO 3166-2]: https://wikipedia.org/wiki/ISO_3166-2
+func GeoRegionISOCode(val string) attribute.KeyValue {
+ return GeoRegionISOCodeKey.String(val)
+}
+
+// Enum values for geo.continent.code
+var (
+ // Africa
+ // Stability: development
+ GeoContinentCodeAf = GeoContinentCodeKey.String("AF")
+ // Antarctica
+ // Stability: development
+ GeoContinentCodeAn = GeoContinentCodeKey.String("AN")
+ // Asia
+ // Stability: development
+ GeoContinentCodeAs = GeoContinentCodeKey.String("AS")
+ // Europe
+ // Stability: development
+ GeoContinentCodeEu = GeoContinentCodeKey.String("EU")
+ // North America
+ // Stability: development
+ GeoContinentCodeNa = GeoContinentCodeKey.String("NA")
+ // Oceania
+ // Stability: development
+ GeoContinentCodeOc = GeoContinentCodeKey.String("OC")
+ // South America
+ // Stability: development
+ GeoContinentCodeSa = GeoContinentCodeKey.String("SA")
+)
+
+// Namespace: go
+const (
+ // GoMemoryTypeKey is the attribute Key conforming to the "go.memory.type"
+ // semantic conventions. It represents the type of memory.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "other", "stack"
+ GoMemoryTypeKey = attribute.Key("go.memory.type")
+)
+
+// Enum values for go.memory.type
+var (
+ // Memory allocated from the heap that is reserved for stack space, whether or
+ // not it is currently in-use.
+ // Stability: development
+ GoMemoryTypeStack = GoMemoryTypeKey.String("stack")
+ // Memory used by the Go runtime, excluding other categories of memory usage
+ // described in this enumeration.
+ // Stability: development
+ GoMemoryTypeOther = GoMemoryTypeKey.String("other")
+)
+
+// Namespace: graphql
+const (
+ // GraphQLDocumentKey is the attribute Key conforming to the "graphql.document"
+ // semantic conventions. It represents the GraphQL document being executed.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: query findBookById { bookById(id: ?) { name } }
+ // Note: The value may be sanitized to exclude sensitive information.
+ GraphQLDocumentKey = attribute.Key("graphql.document")
+
+ // GraphQLOperationNameKey is the attribute Key conforming to the
+ // "graphql.operation.name" semantic conventions. It represents the name of the
+ // operation being executed.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: findBookById
+ GraphQLOperationNameKey = attribute.Key("graphql.operation.name")
+
+ // GraphQLOperationTypeKey is the attribute Key conforming to the
+ // "graphql.operation.type" semantic conventions. It represents the type of the
+ // operation being executed.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "query", "mutation", "subscription"
+ GraphQLOperationTypeKey = attribute.Key("graphql.operation.type")
+)
+
+// GraphQLDocument returns an attribute KeyValue conforming to the
+// "graphql.document" semantic conventions. It represents the GraphQL document
+// being executed.
+func GraphQLDocument(val string) attribute.KeyValue {
+ return GraphQLDocumentKey.String(val)
+}
+
+// GraphQLOperationName returns an attribute KeyValue conforming to the
+// "graphql.operation.name" semantic conventions. It represents the name of the
+// operation being executed.
+func GraphQLOperationName(val string) attribute.KeyValue {
+ return GraphQLOperationNameKey.String(val)
+}
+
+// Enum values for graphql.operation.type
+var (
+ // GraphQL query
+ // Stability: development
+ GraphQLOperationTypeQuery = GraphQLOperationTypeKey.String("query")
+ // GraphQL mutation
+ // Stability: development
+ GraphQLOperationTypeMutation = GraphQLOperationTypeKey.String("mutation")
+ // GraphQL subscription
+ // Stability: development
+ GraphQLOperationTypeSubscription = GraphQLOperationTypeKey.String("subscription")
+)
+
+// Namespace: heroku
+const (
+ // HerokuAppIDKey is the attribute Key conforming to the "heroku.app.id"
+ // semantic conventions. It represents the unique identifier for the
+ // application.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "2daa2797-e42b-4624-9322-ec3f968df4da"
+ HerokuAppIDKey = attribute.Key("heroku.app.id")
+
+ // HerokuReleaseCommitKey is the attribute Key conforming to the
+ // "heroku.release.commit" semantic conventions. It represents the commit hash
+ // for the current release.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "e6134959463efd8966b20e75b913cafe3f5ec"
+ HerokuReleaseCommitKey = attribute.Key("heroku.release.commit")
+
+ // HerokuReleaseCreationTimestampKey is the attribute Key conforming to the
+ // "heroku.release.creation_timestamp" semantic conventions. It represents the
+ // time and date the release was created.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "2022-10-23T18:00:42Z"
+ HerokuReleaseCreationTimestampKey = attribute.Key("heroku.release.creation_timestamp")
+)
+
+// HerokuAppID returns an attribute KeyValue conforming to the "heroku.app.id"
+// semantic conventions. It represents the unique identifier for the application.
+func HerokuAppID(val string) attribute.KeyValue {
+ return HerokuAppIDKey.String(val)
+}
+
+// HerokuReleaseCommit returns an attribute KeyValue conforming to the
+// "heroku.release.commit" semantic conventions. It represents the commit hash
+// for the current release.
+func HerokuReleaseCommit(val string) attribute.KeyValue {
+ return HerokuReleaseCommitKey.String(val)
+}
+
+// HerokuReleaseCreationTimestamp returns an attribute KeyValue conforming to the
+// "heroku.release.creation_timestamp" semantic conventions. It represents the
+// time and date the release was created.
+func HerokuReleaseCreationTimestamp(val string) attribute.KeyValue {
+ return HerokuReleaseCreationTimestampKey.String(val)
+}
+
+// Namespace: host
+const (
+ // HostArchKey is the attribute Key conforming to the "host.arch" semantic
+ // conventions. It represents the CPU architecture the host system is running
+ // on.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ HostArchKey = attribute.Key("host.arch")
+
+ // HostCPUCacheL2SizeKey is the attribute Key conforming to the
+ // "host.cpu.cache.l2.size" semantic conventions. It represents the amount of
+ // level 2 memory cache available to the processor (in Bytes).
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 12288000
+ HostCPUCacheL2SizeKey = attribute.Key("host.cpu.cache.l2.size")
+
+ // HostCPUFamilyKey is the attribute Key conforming to the "host.cpu.family"
+ // semantic conventions. It represents the family or generation of the CPU.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "6", "PA-RISC 1.1e"
+ HostCPUFamilyKey = attribute.Key("host.cpu.family")
+
+ // HostCPUModelIDKey is the attribute Key conforming to the "host.cpu.model.id"
+ // semantic conventions. It represents the model identifier. It provides more
+ // granular information about the CPU, distinguishing it from other CPUs within
+ // the same family.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "6", "9000/778/B180L"
+ HostCPUModelIDKey = attribute.Key("host.cpu.model.id")
+
+ // HostCPUModelNameKey is the attribute Key conforming to the
+ // "host.cpu.model.name" semantic conventions. It represents the model
+ // designation of the processor.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "11th Gen Intel(R) Core(TM) i7-1185G7 @ 3.00GHz"
+ HostCPUModelNameKey = attribute.Key("host.cpu.model.name")
+
+ // HostCPUSteppingKey is the attribute Key conforming to the "host.cpu.stepping"
+ // semantic conventions. It represents the stepping or core revisions.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "1", "r1p1"
+ HostCPUSteppingKey = attribute.Key("host.cpu.stepping")
+
+ // HostCPUVendorIDKey is the attribute Key conforming to the
+ // "host.cpu.vendor.id" semantic conventions. It represents the processor
+ // manufacturer identifier. A maximum 12-character string.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "GenuineIntel"
+ // Note: [CPUID] command returns the vendor ID string in EBX, EDX and ECX
+ // registers. Writing these to memory in this order results in a 12-character
+ // string.
+ //
+ // [CPUID]: https://wiki.osdev.org/CPUID
+ HostCPUVendorIDKey = attribute.Key("host.cpu.vendor.id")
+
+ // HostIDKey is the attribute Key conforming to the "host.id" semantic
+ // conventions. It represents the unique host ID. For Cloud, this must be the
+ // instance_id assigned by the cloud provider. For non-containerized systems,
+ // this should be the `machine-id`. See the table below for the sources to use
+ // to determine the `machine-id` based on operating system.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "fdbf79e8af94cb7f9e8df36789187052"
+ HostIDKey = attribute.Key("host.id")
+
+ // HostImageIDKey is the attribute Key conforming to the "host.image.id"
+ // semantic conventions. It represents the VM image ID or host OS image ID. For
+ // Cloud, this value is from the provider.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "ami-07b06b442921831e5"
+ HostImageIDKey = attribute.Key("host.image.id")
+
+ // HostImageNameKey is the attribute Key conforming to the "host.image.name"
+ // semantic conventions. It represents the name of the VM image or OS install
+ // the host was instantiated from.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "infra-ami-eks-worker-node-7d4ec78312", "CentOS-8-x86_64-1905"
+ HostImageNameKey = attribute.Key("host.image.name")
+
+ // HostImageVersionKey is the attribute Key conforming to the
+ // "host.image.version" semantic conventions. It represents the version string
+ // of the VM image or host OS as defined in [Version Attributes].
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "0.1"
+ //
+ // [Version Attributes]: /docs/resource/README.md#version-attributes
+ HostImageVersionKey = attribute.Key("host.image.version")
+
+ // HostIPKey is the attribute Key conforming to the "host.ip" semantic
+ // conventions. It represents the available IP addresses of the host, excluding
+ // loopback interfaces.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "192.168.1.140", "fe80::abc2:4a28:737a:609e"
+ // Note: IPv4 Addresses MUST be specified in dotted-quad notation. IPv6
+ // addresses MUST be specified in the [RFC 5952] format.
+ //
+ // [RFC 5952]: https://www.rfc-editor.org/rfc/rfc5952.html
+ HostIPKey = attribute.Key("host.ip")
+
+ // HostMacKey is the attribute Key conforming to the "host.mac" semantic
+ // conventions. It represents the available MAC addresses of the host, excluding
+ // loopback interfaces.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "AC-DE-48-23-45-67", "AC-DE-48-23-45-67-01-9F"
+ // Note: MAC Addresses MUST be represented in [IEEE RA hexadecimal form]: as
+ // hyphen-separated octets in uppercase hexadecimal form from most to least
+ // significant.
+ //
+ // [IEEE RA hexadecimal form]: https://standards.ieee.org/wp-content/uploads/import/documents/tutorials/eui.pdf
+ HostMacKey = attribute.Key("host.mac")
+
+ // HostNameKey is the attribute Key conforming to the "host.name" semantic
+ // conventions. It represents the name of the host. On Unix systems, it may
+ // contain what the hostname command returns, or the fully qualified hostname,
+ // or another name specified by the user.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "opentelemetry-test"
+ HostNameKey = attribute.Key("host.name")
+
+ // HostTypeKey is the attribute Key conforming to the "host.type" semantic
+ // conventions. It represents the type of host. For Cloud, this must be the
+ // machine type.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "n1-standard-1"
+ HostTypeKey = attribute.Key("host.type")
+)
+
+// HostCPUCacheL2Size returns an attribute KeyValue conforming to the
+// "host.cpu.cache.l2.size" semantic conventions. It represents the amount of
+// level 2 memory cache available to the processor (in Bytes).
+func HostCPUCacheL2Size(val int) attribute.KeyValue {
+ return HostCPUCacheL2SizeKey.Int(val)
+}
+
+// HostCPUFamily returns an attribute KeyValue conforming to the
+// "host.cpu.family" semantic conventions. It represents the family or generation
+// of the CPU.
+func HostCPUFamily(val string) attribute.KeyValue {
+ return HostCPUFamilyKey.String(val)
+}
+
+// HostCPUModelID returns an attribute KeyValue conforming to the
+// "host.cpu.model.id" semantic conventions. It represents the model identifier.
+// It provides more granular information about the CPU, distinguishing it from
+// other CPUs within the same family.
+func HostCPUModelID(val string) attribute.KeyValue {
+ return HostCPUModelIDKey.String(val)
+}
+
+// HostCPUModelName returns an attribute KeyValue conforming to the
+// "host.cpu.model.name" semantic conventions. It represents the model
+// designation of the processor.
+func HostCPUModelName(val string) attribute.KeyValue {
+ return HostCPUModelNameKey.String(val)
+}
+
+// HostCPUStepping returns an attribute KeyValue conforming to the
+// "host.cpu.stepping" semantic conventions. It represents the stepping or core
+// revisions.
+func HostCPUStepping(val string) attribute.KeyValue {
+ return HostCPUSteppingKey.String(val)
+}
+
+// HostCPUVendorID returns an attribute KeyValue conforming to the
+// "host.cpu.vendor.id" semantic conventions. It represents the processor
+// manufacturer identifier. A maximum 12-character string.
+func HostCPUVendorID(val string) attribute.KeyValue {
+ return HostCPUVendorIDKey.String(val)
+}
+
+// HostID returns an attribute KeyValue conforming to the "host.id" semantic
+// conventions. It represents the unique host ID. For Cloud, this must be the
+// instance_id assigned by the cloud provider. For non-containerized systems,
+// this should be the `machine-id`. See the table below for the sources to use to
+// determine the `machine-id` based on operating system.
+func HostID(val string) attribute.KeyValue {
+ return HostIDKey.String(val)
+}
+
+// HostImageID returns an attribute KeyValue conforming to the "host.image.id"
+// semantic conventions. It represents the VM image ID or host OS image ID. For
+// Cloud, this value is from the provider.
+func HostImageID(val string) attribute.KeyValue {
+ return HostImageIDKey.String(val)
+}
+
+// HostImageName returns an attribute KeyValue conforming to the
+// "host.image.name" semantic conventions. It represents the name of the VM image
+// or OS install the host was instantiated from.
+func HostImageName(val string) attribute.KeyValue {
+ return HostImageNameKey.String(val)
+}
+
+// HostImageVersion returns an attribute KeyValue conforming to the
+// "host.image.version" semantic conventions. It represents the version string of
+// the VM image or host OS as defined in [Version Attributes].
+//
+// [Version Attributes]: /docs/resource/README.md#version-attributes
+func HostImageVersion(val string) attribute.KeyValue {
+ return HostImageVersionKey.String(val)
+}
+
+// HostIP returns an attribute KeyValue conforming to the "host.ip" semantic
+// conventions. It represents the available IP addresses of the host, excluding
+// loopback interfaces.
+func HostIP(val ...string) attribute.KeyValue {
+ return HostIPKey.StringSlice(val)
+}
+
+// HostMac returns an attribute KeyValue conforming to the "host.mac" semantic
+// conventions. It represents the available MAC addresses of the host, excluding
+// loopback interfaces.
+func HostMac(val ...string) attribute.KeyValue {
+ return HostMacKey.StringSlice(val)
+}
+
+// HostName returns an attribute KeyValue conforming to the "host.name" semantic
+// conventions. It represents the name of the host. On Unix systems, it may
+// contain what the hostname command returns, or the fully qualified hostname, or
+// another name specified by the user.
+func HostName(val string) attribute.KeyValue {
+ return HostNameKey.String(val)
+}
+
+// HostType returns an attribute KeyValue conforming to the "host.type" semantic
+// conventions. It represents the type of host. For Cloud, this must be the
+// machine type.
+func HostType(val string) attribute.KeyValue {
+ return HostTypeKey.String(val)
+}
+
+// Enum values for host.arch
+var (
+ // AMD64
+ // Stability: development
+ HostArchAMD64 = HostArchKey.String("amd64")
+ // ARM32
+ // Stability: development
+ HostArchARM32 = HostArchKey.String("arm32")
+ // ARM64
+ // Stability: development
+ HostArchARM64 = HostArchKey.String("arm64")
+ // Itanium
+ // Stability: development
+ HostArchIA64 = HostArchKey.String("ia64")
+ // 32-bit PowerPC
+ // Stability: development
+ HostArchPPC32 = HostArchKey.String("ppc32")
+ // 64-bit PowerPC
+ // Stability: development
+ HostArchPPC64 = HostArchKey.String("ppc64")
+ // IBM z/Architecture
+ // Stability: development
+ HostArchS390x = HostArchKey.String("s390x")
+ // 32-bit x86
+ // Stability: development
+ HostArchX86 = HostArchKey.String("x86")
+)
+
+// Namespace: http
+const (
+ // HTTPConnectionStateKey is the attribute Key conforming to the
+ // "http.connection.state" semantic conventions. It represents the state of the
+ // HTTP connection in the HTTP connection pool.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "active", "idle"
+ HTTPConnectionStateKey = attribute.Key("http.connection.state")
+
+ // HTTPRequestBodySizeKey is the attribute Key conforming to the
+ // "http.request.body.size" semantic conventions. It represents the size of the
+ // request payload body in bytes. This is the number of bytes transferred
+ // excluding headers and is often, but not always, present as the
+ // [Content-Length] header. For requests using transport encoding, this should
+ // be the compressed size.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // [Content-Length]: https://www.rfc-editor.org/rfc/rfc9110.html#field.content-length
+ HTTPRequestBodySizeKey = attribute.Key("http.request.body.size")
+
+ // HTTPRequestMethodKey is the attribute Key conforming to the
+ // "http.request.method" semantic conventions. It represents the HTTP request
+ // method.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "GET", "POST", "HEAD"
+ // Note: HTTP request method value SHOULD be "known" to the instrumentation.
+ // By default, this convention defines "known" methods as the ones listed in
+ // [RFC9110]
+ // and the PATCH method defined in [RFC5789].
+ //
+ // If the HTTP request method is not known to instrumentation, it MUST set the
+ // `http.request.method` attribute to `_OTHER`.
+ //
+ // If the HTTP instrumentation could end up converting valid HTTP request
+ // methods to `_OTHER`, then it MUST provide a way to override
+ // the list of known HTTP methods. If this override is done via environment
+ // variable, then the environment variable MUST be named
+ // OTEL_INSTRUMENTATION_HTTP_KNOWN_METHODS and support a comma-separated list of
+ // case-sensitive known HTTP methods
+ // (this list MUST be a full override of the default known method, it is not a
+ // list of known methods in addition to the defaults).
+ //
+ // HTTP method names are case-sensitive and `http.request.method` attribute
+ // value MUST match a known HTTP method name exactly.
+ // Instrumentations for specific web frameworks that consider HTTP methods to be
+ // case insensitive, SHOULD populate a canonical equivalent.
+ // Tracing instrumentations that do so, MUST also set
+ // `http.request.method_original` to the original value.
+ //
+ // [RFC9110]: https://www.rfc-editor.org/rfc/rfc9110.html#name-methods
+ // [RFC5789]: https://www.rfc-editor.org/rfc/rfc5789.html
+ HTTPRequestMethodKey = attribute.Key("http.request.method")
+
+ // HTTPRequestMethodOriginalKey is the attribute Key conforming to the
+ // "http.request.method_original" semantic conventions. It represents the
+ // original HTTP method sent by the client in the request line.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "GeT", "ACL", "foo"
+ HTTPRequestMethodOriginalKey = attribute.Key("http.request.method_original")
+
+ // HTTPRequestResendCountKey is the attribute Key conforming to the
+ // "http.request.resend_count" semantic conventions. It represents the ordinal
+ // number of request resending attempt (for any reason, including redirects).
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Note: The resend count SHOULD be updated each time an HTTP request gets
+ // resent by the client, regardless of what was the cause of the resending (e.g.
+ // redirection, authorization failure, 503 Server Unavailable, network issues,
+ // or any other).
+ HTTPRequestResendCountKey = attribute.Key("http.request.resend_count")
+
+ // HTTPRequestSizeKey is the attribute Key conforming to the "http.request.size"
+ // semantic conventions. It represents the total size of the request in bytes.
+ // This should be the total number of bytes sent over the wire, including the
+ // request line (HTTP/1.1), framing (HTTP/2 and HTTP/3), headers, and request
+ // body if any.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ HTTPRequestSizeKey = attribute.Key("http.request.size")
+
+ // HTTPResponseBodySizeKey is the attribute Key conforming to the
+ // "http.response.body.size" semantic conventions. It represents the size of the
+ // response payload body in bytes. This is the number of bytes transferred
+ // excluding headers and is often, but not always, present as the
+ // [Content-Length] header. For requests using transport encoding, this should
+ // be the compressed size.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // [Content-Length]: https://www.rfc-editor.org/rfc/rfc9110.html#field.content-length
+ HTTPResponseBodySizeKey = attribute.Key("http.response.body.size")
+
+ // HTTPResponseSizeKey is the attribute Key conforming to the
+ // "http.response.size" semantic conventions. It represents the total size of
+ // the response in bytes. This should be the total number of bytes sent over the
+ // wire, including the status line (HTTP/1.1), framing (HTTP/2 and HTTP/3),
+ // headers, and response body and trailers if any.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ HTTPResponseSizeKey = attribute.Key("http.response.size")
+
+ // HTTPResponseStatusCodeKey is the attribute Key conforming to the
+ // "http.response.status_code" semantic conventions. It represents the
+ // [HTTP response status code].
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: 200
+ //
+ // [HTTP response status code]: https://tools.ietf.org/html/rfc7231#section-6
+ HTTPResponseStatusCodeKey = attribute.Key("http.response.status_code")
+
+ // HTTPRouteKey is the attribute Key conforming to the "http.route" semantic
+ // conventions. It represents the matched route, that is, the path template in
+ // the format used by the respective server framework.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "/users/:userID?", "{controller}/{action}/{id?}"
+ // Note: MUST NOT be populated when this is not supported by the HTTP server
+ // framework as the route attribute should have low-cardinality and the URI path
+ // can NOT substitute it.
+ // SHOULD include the [application root] if there is one.
+ //
+ // [application root]: /docs/http/http-spans.md#http-server-definitions
+ HTTPRouteKey = attribute.Key("http.route")
+)
+
+// HTTPRequestBodySize returns an attribute KeyValue conforming to the
+// "http.request.body.size" semantic conventions. It represents the size of the
+// request payload body in bytes. This is the number of bytes transferred
+// excluding headers and is often, but not always, present as the
+// [Content-Length] header. For requests using transport encoding, this should be
+// the compressed size.
+//
+// [Content-Length]: https://www.rfc-editor.org/rfc/rfc9110.html#field.content-length
+func HTTPRequestBodySize(val int) attribute.KeyValue {
+ return HTTPRequestBodySizeKey.Int(val)
+}
+
+// HTTPRequestHeader returns an attribute KeyValue conforming to the
+// "http.request.header" semantic conventions. It represents the HTTP request
+// headers, `` being the normalized HTTP Header name (lowercase), the value
+// being the header values.
+func HTTPRequestHeader(key string, val ...string) attribute.KeyValue {
+ return attribute.StringSlice("http.request.header."+key, val)
+}
+
+// HTTPRequestMethodOriginal returns an attribute KeyValue conforming to the
+// "http.request.method_original" semantic conventions. It represents the
+// original HTTP method sent by the client in the request line.
+func HTTPRequestMethodOriginal(val string) attribute.KeyValue {
+ return HTTPRequestMethodOriginalKey.String(val)
+}
+
+// HTTPRequestResendCount returns an attribute KeyValue conforming to the
+// "http.request.resend_count" semantic conventions. It represents the ordinal
+// number of request resending attempt (for any reason, including redirects).
+func HTTPRequestResendCount(val int) attribute.KeyValue {
+ return HTTPRequestResendCountKey.Int(val)
+}
+
+// HTTPRequestSize returns an attribute KeyValue conforming to the
+// "http.request.size" semantic conventions. It represents the total size of the
+// request in bytes. This should be the total number of bytes sent over the wire,
+// including the request line (HTTP/1.1), framing (HTTP/2 and HTTP/3), headers,
+// and request body if any.
+func HTTPRequestSize(val int) attribute.KeyValue {
+ return HTTPRequestSizeKey.Int(val)
+}
+
+// HTTPResponseBodySize returns an attribute KeyValue conforming to the
+// "http.response.body.size" semantic conventions. It represents the size of the
+// response payload body in bytes. This is the number of bytes transferred
+// excluding headers and is often, but not always, present as the
+// [Content-Length] header. For requests using transport encoding, this should be
+// the compressed size.
+//
+// [Content-Length]: https://www.rfc-editor.org/rfc/rfc9110.html#field.content-length
+func HTTPResponseBodySize(val int) attribute.KeyValue {
+ return HTTPResponseBodySizeKey.Int(val)
+}
+
+// HTTPResponseHeader returns an attribute KeyValue conforming to the
+// "http.response.header" semantic conventions. It represents the HTTP response
+// headers, `` being the normalized HTTP Header name (lowercase), the value
+// being the header values.
+func HTTPResponseHeader(key string, val ...string) attribute.KeyValue {
+ return attribute.StringSlice("http.response.header."+key, val)
+}
+
+// HTTPResponseSize returns an attribute KeyValue conforming to the
+// "http.response.size" semantic conventions. It represents the total size of the
+// response in bytes. This should be the total number of bytes sent over the
+// wire, including the status line (HTTP/1.1), framing (HTTP/2 and HTTP/3),
+// headers, and response body and trailers if any.
+func HTTPResponseSize(val int) attribute.KeyValue {
+ return HTTPResponseSizeKey.Int(val)
+}
+
+// HTTPResponseStatusCode returns an attribute KeyValue conforming to the
+// "http.response.status_code" semantic conventions. It represents the
+// [HTTP response status code].
+//
+// [HTTP response status code]: https://tools.ietf.org/html/rfc7231#section-6
+func HTTPResponseStatusCode(val int) attribute.KeyValue {
+ return HTTPResponseStatusCodeKey.Int(val)
+}
+
+// HTTPRoute returns an attribute KeyValue conforming to the "http.route"
+// semantic conventions. It represents the matched route, that is, the path
+// template in the format used by the respective server framework.
+func HTTPRoute(val string) attribute.KeyValue {
+ return HTTPRouteKey.String(val)
+}
+
+// Enum values for http.connection.state
+var (
+ // active state.
+ // Stability: development
+ HTTPConnectionStateActive = HTTPConnectionStateKey.String("active")
+ // idle state.
+ // Stability: development
+ HTTPConnectionStateIdle = HTTPConnectionStateKey.String("idle")
+)
+
+// Enum values for http.request.method
+var (
+ // CONNECT method.
+ // Stability: stable
+ HTTPRequestMethodConnect = HTTPRequestMethodKey.String("CONNECT")
+ // DELETE method.
+ // Stability: stable
+ HTTPRequestMethodDelete = HTTPRequestMethodKey.String("DELETE")
+ // GET method.
+ // Stability: stable
+ HTTPRequestMethodGet = HTTPRequestMethodKey.String("GET")
+ // HEAD method.
+ // Stability: stable
+ HTTPRequestMethodHead = HTTPRequestMethodKey.String("HEAD")
+ // OPTIONS method.
+ // Stability: stable
+ HTTPRequestMethodOptions = HTTPRequestMethodKey.String("OPTIONS")
+ // PATCH method.
+ // Stability: stable
+ HTTPRequestMethodPatch = HTTPRequestMethodKey.String("PATCH")
+ // POST method.
+ // Stability: stable
+ HTTPRequestMethodPost = HTTPRequestMethodKey.String("POST")
+ // PUT method.
+ // Stability: stable
+ HTTPRequestMethodPut = HTTPRequestMethodKey.String("PUT")
+ // TRACE method.
+ // Stability: stable
+ HTTPRequestMethodTrace = HTTPRequestMethodKey.String("TRACE")
+ // Any HTTP method that the instrumentation has no prior knowledge of.
+ // Stability: stable
+ HTTPRequestMethodOther = HTTPRequestMethodKey.String("_OTHER")
+)
+
+// Namespace: hw
+const (
+ // HwBatteryCapacityKey is the attribute Key conforming to the
+ // "hw.battery.capacity" semantic conventions. It represents the design capacity
+ // in Watts-hours or Amper-hours.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "9.3Ah", "50Wh"
+ HwBatteryCapacityKey = attribute.Key("hw.battery.capacity")
+
+ // HwBatteryChemistryKey is the attribute Key conforming to the
+ // "hw.battery.chemistry" semantic conventions. It represents the battery
+ // [chemistry], e.g. Lithium-Ion, Nickel-Cadmium, etc.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Li-ion", "NiMH"
+ //
+ // [chemistry]: https://schemas.dmtf.org/wbem/cim-html/2.31.0/CIM_Battery.html
+ HwBatteryChemistryKey = attribute.Key("hw.battery.chemistry")
+
+ // HwBatteryStateKey is the attribute Key conforming to the "hw.battery.state"
+ // semantic conventions. It represents the current state of the battery.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ HwBatteryStateKey = attribute.Key("hw.battery.state")
+
+ // HwBiosVersionKey is the attribute Key conforming to the "hw.bios_version"
+ // semantic conventions. It represents the BIOS version of the hardware
+ // component.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "1.2.3"
+ HwBiosVersionKey = attribute.Key("hw.bios_version")
+
+ // HwDriverVersionKey is the attribute Key conforming to the "hw.driver_version"
+ // semantic conventions. It represents the driver version for the hardware
+ // component.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "10.2.1-3"
+ HwDriverVersionKey = attribute.Key("hw.driver_version")
+
+ // HwEnclosureTypeKey is the attribute Key conforming to the "hw.enclosure.type"
+ // semantic conventions. It represents the type of the enclosure (useful for
+ // modular systems).
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Computer", "Storage", "Switch"
+ HwEnclosureTypeKey = attribute.Key("hw.enclosure.type")
+
+ // HwFirmwareVersionKey is the attribute Key conforming to the
+ // "hw.firmware_version" semantic conventions. It represents the firmware
+ // version of the hardware component.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "2.0.1"
+ HwFirmwareVersionKey = attribute.Key("hw.firmware_version")
+
+ // HwGpuTaskKey is the attribute Key conforming to the "hw.gpu.task" semantic
+ // conventions. It represents the type of task the GPU is performing.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ HwGpuTaskKey = attribute.Key("hw.gpu.task")
+
+ // HwIDKey is the attribute Key conforming to the "hw.id" semantic conventions.
+ // It represents an identifier for the hardware component, unique within the
+ // monitored host.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "win32battery_battery_testsysa33_1"
+ HwIDKey = attribute.Key("hw.id")
+
+ // HwLimitTypeKey is the attribute Key conforming to the "hw.limit_type"
+ // semantic conventions. It represents the type of limit for hardware
+ // components.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ HwLimitTypeKey = attribute.Key("hw.limit_type")
+
+ // HwLogicalDiskRaidLevelKey is the attribute Key conforming to the
+ // "hw.logical_disk.raid_level" semantic conventions. It represents the RAID
+ // Level of the logical disk.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "RAID0+1", "RAID5", "RAID10"
+ HwLogicalDiskRaidLevelKey = attribute.Key("hw.logical_disk.raid_level")
+
+ // HwLogicalDiskStateKey is the attribute Key conforming to the
+ // "hw.logical_disk.state" semantic conventions. It represents the state of the
+ // logical disk space usage.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ HwLogicalDiskStateKey = attribute.Key("hw.logical_disk.state")
+
+ // HwMemoryTypeKey is the attribute Key conforming to the "hw.memory.type"
+ // semantic conventions. It represents the type of the memory module.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "DDR4", "DDR5", "LPDDR5"
+ HwMemoryTypeKey = attribute.Key("hw.memory.type")
+
+ // HwModelKey is the attribute Key conforming to the "hw.model" semantic
+ // conventions. It represents the descriptive model name of the hardware
+ // component.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "PERC H740P", "Intel(R) Core(TM) i7-10700K", "Dell XPS 15 Battery"
+ HwModelKey = attribute.Key("hw.model")
+
+ // HwNameKey is the attribute Key conforming to the "hw.name" semantic
+ // conventions. It represents an easily-recognizable name for the hardware
+ // component.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "eth0"
+ HwNameKey = attribute.Key("hw.name")
+
+ // HwNetworkLogicalAddressesKey is the attribute Key conforming to the
+ // "hw.network.logical_addresses" semantic conventions. It represents the
+ // logical addresses of the adapter (e.g. IP address, or WWPN).
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "172.16.8.21", "57.11.193.42"
+ HwNetworkLogicalAddressesKey = attribute.Key("hw.network.logical_addresses")
+
+ // HwNetworkPhysicalAddressKey is the attribute Key conforming to the
+ // "hw.network.physical_address" semantic conventions. It represents the
+ // physical address of the adapter (e.g. MAC address, or WWNN).
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "00-90-F5-E9-7B-36"
+ HwNetworkPhysicalAddressKey = attribute.Key("hw.network.physical_address")
+
+ // HwParentKey is the attribute Key conforming to the "hw.parent" semantic
+ // conventions. It represents the unique identifier of the parent component
+ // (typically the `hw.id` attribute of the enclosure, or disk controller).
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "dellStorage_perc_0"
+ HwParentKey = attribute.Key("hw.parent")
+
+ // HwPhysicalDiskSmartAttributeKey is the attribute Key conforming to the
+ // "hw.physical_disk.smart_attribute" semantic conventions. It represents the
+ // [S.M.A.R.T.] (Self-Monitoring, Analysis, and Reporting Technology) attribute
+ // of the physical disk.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Spin Retry Count", "Seek Error Rate", "Raw Read Error Rate"
+ //
+ // [S.M.A.R.T.]: https://wikipedia.org/wiki/S.M.A.R.T.
+ HwPhysicalDiskSmartAttributeKey = attribute.Key("hw.physical_disk.smart_attribute")
+
+ // HwPhysicalDiskStateKey is the attribute Key conforming to the
+ // "hw.physical_disk.state" semantic conventions. It represents the state of the
+ // physical disk endurance utilization.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ HwPhysicalDiskStateKey = attribute.Key("hw.physical_disk.state")
+
+ // HwPhysicalDiskTypeKey is the attribute Key conforming to the
+ // "hw.physical_disk.type" semantic conventions. It represents the type of the
+ // physical disk.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "HDD", "SSD", "10K"
+ HwPhysicalDiskTypeKey = attribute.Key("hw.physical_disk.type")
+
+ // HwSensorLocationKey is the attribute Key conforming to the
+ // "hw.sensor_location" semantic conventions. It represents the location of the
+ // sensor.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "cpu0", "ps1", "INLET", "CPU0_DIE", "AMBIENT", "MOTHERBOARD", "PS0
+ // V3_3", "MAIN_12V", "CPU_VCORE"
+ HwSensorLocationKey = attribute.Key("hw.sensor_location")
+
+ // HwSerialNumberKey is the attribute Key conforming to the "hw.serial_number"
+ // semantic conventions. It represents the serial number of the hardware
+ // component.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "CNFCP0123456789"
+ HwSerialNumberKey = attribute.Key("hw.serial_number")
+
+ // HwStateKey is the attribute Key conforming to the "hw.state" semantic
+ // conventions. It represents the current state of the component.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ HwStateKey = attribute.Key("hw.state")
+
+ // HwTapeDriveOperationTypeKey is the attribute Key conforming to the
+ // "hw.tape_drive.operation_type" semantic conventions. It represents the type
+ // of tape drive operation.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ HwTapeDriveOperationTypeKey = attribute.Key("hw.tape_drive.operation_type")
+
+ // HwTypeKey is the attribute Key conforming to the "hw.type" semantic
+ // conventions. It represents the type of the component.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // Note: Describes the category of the hardware component for which `hw.state`
+ // is being reported. For example, `hw.type=temperature` along with
+ // `hw.state=degraded` would indicate that the temperature of the hardware
+ // component has been reported as `degraded`.
+ HwTypeKey = attribute.Key("hw.type")
+
+ // HwVendorKey is the attribute Key conforming to the "hw.vendor" semantic
+ // conventions. It represents the vendor name of the hardware component.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Dell", "HP", "Intel", "AMD", "LSI", "Lenovo"
+ HwVendorKey = attribute.Key("hw.vendor")
+)
+
+// HwBatteryCapacity returns an attribute KeyValue conforming to the
+// "hw.battery.capacity" semantic conventions. It represents the design capacity
+// in Watts-hours or Amper-hours.
+func HwBatteryCapacity(val string) attribute.KeyValue {
+ return HwBatteryCapacityKey.String(val)
+}
+
+// HwBatteryChemistry returns an attribute KeyValue conforming to the
+// "hw.battery.chemistry" semantic conventions. It represents the battery
+// [chemistry], e.g. Lithium-Ion, Nickel-Cadmium, etc.
+//
+// [chemistry]: https://schemas.dmtf.org/wbem/cim-html/2.31.0/CIM_Battery.html
+func HwBatteryChemistry(val string) attribute.KeyValue {
+ return HwBatteryChemistryKey.String(val)
+}
+
+// HwBiosVersion returns an attribute KeyValue conforming to the
+// "hw.bios_version" semantic conventions. It represents the BIOS version of the
+// hardware component.
+func HwBiosVersion(val string) attribute.KeyValue {
+ return HwBiosVersionKey.String(val)
+}
+
+// HwDriverVersion returns an attribute KeyValue conforming to the
+// "hw.driver_version" semantic conventions. It represents the driver version for
+// the hardware component.
+func HwDriverVersion(val string) attribute.KeyValue {
+ return HwDriverVersionKey.String(val)
+}
+
+// HwEnclosureType returns an attribute KeyValue conforming to the
+// "hw.enclosure.type" semantic conventions. It represents the type of the
+// enclosure (useful for modular systems).
+func HwEnclosureType(val string) attribute.KeyValue {
+ return HwEnclosureTypeKey.String(val)
+}
+
+// HwFirmwareVersion returns an attribute KeyValue conforming to the
+// "hw.firmware_version" semantic conventions. It represents the firmware version
+// of the hardware component.
+func HwFirmwareVersion(val string) attribute.KeyValue {
+ return HwFirmwareVersionKey.String(val)
+}
+
+// HwID returns an attribute KeyValue conforming to the "hw.id" semantic
+// conventions. It represents an identifier for the hardware component, unique
+// within the monitored host.
+func HwID(val string) attribute.KeyValue {
+ return HwIDKey.String(val)
+}
+
+// HwLogicalDiskRaidLevel returns an attribute KeyValue conforming to the
+// "hw.logical_disk.raid_level" semantic conventions. It represents the RAID
+// Level of the logical disk.
+func HwLogicalDiskRaidLevel(val string) attribute.KeyValue {
+ return HwLogicalDiskRaidLevelKey.String(val)
+}
+
+// HwMemoryType returns an attribute KeyValue conforming to the "hw.memory.type"
+// semantic conventions. It represents the type of the memory module.
+func HwMemoryType(val string) attribute.KeyValue {
+ return HwMemoryTypeKey.String(val)
+}
+
+// HwModel returns an attribute KeyValue conforming to the "hw.model" semantic
+// conventions. It represents the descriptive model name of the hardware
+// component.
+func HwModel(val string) attribute.KeyValue {
+ return HwModelKey.String(val)
+}
+
+// HwName returns an attribute KeyValue conforming to the "hw.name" semantic
+// conventions. It represents an easily-recognizable name for the hardware
+// component.
+func HwName(val string) attribute.KeyValue {
+ return HwNameKey.String(val)
+}
+
+// HwNetworkLogicalAddresses returns an attribute KeyValue conforming to the
+// "hw.network.logical_addresses" semantic conventions. It represents the logical
+// addresses of the adapter (e.g. IP address, or WWPN).
+func HwNetworkLogicalAddresses(val ...string) attribute.KeyValue {
+ return HwNetworkLogicalAddressesKey.StringSlice(val)
+}
+
+// HwNetworkPhysicalAddress returns an attribute KeyValue conforming to the
+// "hw.network.physical_address" semantic conventions. It represents the physical
+// address of the adapter (e.g. MAC address, or WWNN).
+func HwNetworkPhysicalAddress(val string) attribute.KeyValue {
+ return HwNetworkPhysicalAddressKey.String(val)
+}
+
+// HwParent returns an attribute KeyValue conforming to the "hw.parent" semantic
+// conventions. It represents the unique identifier of the parent component
+// (typically the `hw.id` attribute of the enclosure, or disk controller).
+func HwParent(val string) attribute.KeyValue {
+ return HwParentKey.String(val)
+}
+
+// HwPhysicalDiskSmartAttribute returns an attribute KeyValue conforming to the
+// "hw.physical_disk.smart_attribute" semantic conventions. It represents the
+// [S.M.A.R.T.] (Self-Monitoring, Analysis, and Reporting Technology) attribute
+// of the physical disk.
+//
+// [S.M.A.R.T.]: https://wikipedia.org/wiki/S.M.A.R.T.
+func HwPhysicalDiskSmartAttribute(val string) attribute.KeyValue {
+ return HwPhysicalDiskSmartAttributeKey.String(val)
+}
+
+// HwPhysicalDiskType returns an attribute KeyValue conforming to the
+// "hw.physical_disk.type" semantic conventions. It represents the type of the
+// physical disk.
+func HwPhysicalDiskType(val string) attribute.KeyValue {
+ return HwPhysicalDiskTypeKey.String(val)
+}
+
+// HwSensorLocation returns an attribute KeyValue conforming to the
+// "hw.sensor_location" semantic conventions. It represents the location of the
+// sensor.
+func HwSensorLocation(val string) attribute.KeyValue {
+ return HwSensorLocationKey.String(val)
+}
+
+// HwSerialNumber returns an attribute KeyValue conforming to the
+// "hw.serial_number" semantic conventions. It represents the serial number of
+// the hardware component.
+func HwSerialNumber(val string) attribute.KeyValue {
+ return HwSerialNumberKey.String(val)
+}
+
+// HwVendor returns an attribute KeyValue conforming to the "hw.vendor" semantic
+// conventions. It represents the vendor name of the hardware component.
+func HwVendor(val string) attribute.KeyValue {
+ return HwVendorKey.String(val)
+}
+
+// Enum values for hw.battery.state
+var (
+ // Charging
+ // Stability: development
+ HwBatteryStateCharging = HwBatteryStateKey.String("charging")
+ // Discharging
+ // Stability: development
+ HwBatteryStateDischarging = HwBatteryStateKey.String("discharging")
+)
+
+// Enum values for hw.gpu.task
+var (
+ // Decoder
+ // Stability: development
+ HwGpuTaskDecoder = HwGpuTaskKey.String("decoder")
+ // Encoder
+ // Stability: development
+ HwGpuTaskEncoder = HwGpuTaskKey.String("encoder")
+ // General
+ // Stability: development
+ HwGpuTaskGeneral = HwGpuTaskKey.String("general")
+)
+
+// Enum values for hw.limit_type
+var (
+ // Critical
+ // Stability: development
+ HwLimitTypeCritical = HwLimitTypeKey.String("critical")
+ // Degraded
+ // Stability: development
+ HwLimitTypeDegraded = HwLimitTypeKey.String("degraded")
+ // High Critical
+ // Stability: development
+ HwLimitTypeHighCritical = HwLimitTypeKey.String("high.critical")
+ // High Degraded
+ // Stability: development
+ HwLimitTypeHighDegraded = HwLimitTypeKey.String("high.degraded")
+ // Low Critical
+ // Stability: development
+ HwLimitTypeLowCritical = HwLimitTypeKey.String("low.critical")
+ // Low Degraded
+ // Stability: development
+ HwLimitTypeLowDegraded = HwLimitTypeKey.String("low.degraded")
+ // Maximum
+ // Stability: development
+ HwLimitTypeMax = HwLimitTypeKey.String("max")
+ // Throttled
+ // Stability: development
+ HwLimitTypeThrottled = HwLimitTypeKey.String("throttled")
+ // Turbo
+ // Stability: development
+ HwLimitTypeTurbo = HwLimitTypeKey.String("turbo")
+)
+
+// Enum values for hw.logical_disk.state
+var (
+ // Used
+ // Stability: development
+ HwLogicalDiskStateUsed = HwLogicalDiskStateKey.String("used")
+ // Free
+ // Stability: development
+ HwLogicalDiskStateFree = HwLogicalDiskStateKey.String("free")
+)
+
+// Enum values for hw.physical_disk.state
+var (
+ // Remaining
+ // Stability: development
+ HwPhysicalDiskStateRemaining = HwPhysicalDiskStateKey.String("remaining")
+)
+
+// Enum values for hw.state
+var (
+ // Degraded
+ // Stability: development
+ HwStateDegraded = HwStateKey.String("degraded")
+ // Failed
+ // Stability: development
+ HwStateFailed = HwStateKey.String("failed")
+ // Needs Cleaning
+ // Stability: development
+ HwStateNeedsCleaning = HwStateKey.String("needs_cleaning")
+ // OK
+ // Stability: development
+ HwStateOk = HwStateKey.String("ok")
+ // Predicted Failure
+ // Stability: development
+ HwStatePredictedFailure = HwStateKey.String("predicted_failure")
+)
+
+// Enum values for hw.tape_drive.operation_type
+var (
+ // Mount
+ // Stability: development
+ HwTapeDriveOperationTypeMount = HwTapeDriveOperationTypeKey.String("mount")
+ // Unmount
+ // Stability: development
+ HwTapeDriveOperationTypeUnmount = HwTapeDriveOperationTypeKey.String("unmount")
+ // Clean
+ // Stability: development
+ HwTapeDriveOperationTypeClean = HwTapeDriveOperationTypeKey.String("clean")
+)
+
+// Enum values for hw.type
+var (
+ // Battery
+ // Stability: development
+ HwTypeBattery = HwTypeKey.String("battery")
+ // CPU
+ // Stability: development
+ HwTypeCPU = HwTypeKey.String("cpu")
+ // Disk controller
+ // Stability: development
+ HwTypeDiskController = HwTypeKey.String("disk_controller")
+ // Enclosure
+ // Stability: development
+ HwTypeEnclosure = HwTypeKey.String("enclosure")
+ // Fan
+ // Stability: development
+ HwTypeFan = HwTypeKey.String("fan")
+ // GPU
+ // Stability: development
+ HwTypeGpu = HwTypeKey.String("gpu")
+ // Logical disk
+ // Stability: development
+ HwTypeLogicalDisk = HwTypeKey.String("logical_disk")
+ // Memory
+ // Stability: development
+ HwTypeMemory = HwTypeKey.String("memory")
+ // Network
+ // Stability: development
+ HwTypeNetwork = HwTypeKey.String("network")
+ // Physical disk
+ // Stability: development
+ HwTypePhysicalDisk = HwTypeKey.String("physical_disk")
+ // Power supply
+ // Stability: development
+ HwTypePowerSupply = HwTypeKey.String("power_supply")
+ // Tape drive
+ // Stability: development
+ HwTypeTapeDrive = HwTypeKey.String("tape_drive")
+ // Temperature
+ // Stability: development
+ HwTypeTemperature = HwTypeKey.String("temperature")
+ // Voltage
+ // Stability: development
+ HwTypeVoltage = HwTypeKey.String("voltage")
+)
+
+// Namespace: ios
+const (
+ // IOSAppStateKey is the attribute Key conforming to the "ios.app.state"
+ // semantic conventions. It represents the this attribute represents the state
+ // of the application.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // Note: The iOS lifecycle states are defined in the
+ // [UIApplicationDelegate documentation], and from which the `OS terminology`
+ // column values are derived.
+ //
+ // [UIApplicationDelegate documentation]: https://developer.apple.com/documentation/uikit/uiapplicationdelegate
+ IOSAppStateKey = attribute.Key("ios.app.state")
+)
+
+// Enum values for ios.app.state
+var (
+ // The app has become `active`. Associated with UIKit notification
+ // `applicationDidBecomeActive`.
+ //
+ // Stability: development
+ IOSAppStateActive = IOSAppStateKey.String("active")
+ // The app is now `inactive`. Associated with UIKit notification
+ // `applicationWillResignActive`.
+ //
+ // Stability: development
+ IOSAppStateInactive = IOSAppStateKey.String("inactive")
+ // The app is now in the background. This value is associated with UIKit
+ // notification `applicationDidEnterBackground`.
+ //
+ // Stability: development
+ IOSAppStateBackground = IOSAppStateKey.String("background")
+ // The app is now in the foreground. This value is associated with UIKit
+ // notification `applicationWillEnterForeground`.
+ //
+ // Stability: development
+ IOSAppStateForeground = IOSAppStateKey.String("foreground")
+ // The app is about to terminate. Associated with UIKit notification
+ // `applicationWillTerminate`.
+ //
+ // Stability: development
+ IOSAppStateTerminate = IOSAppStateKey.String("terminate")
+)
+
+// Namespace: k8s
+const (
+ // K8SClusterNameKey is the attribute Key conforming to the "k8s.cluster.name"
+ // semantic conventions. It represents the name of the cluster.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "opentelemetry-cluster"
+ K8SClusterNameKey = attribute.Key("k8s.cluster.name")
+
+ // K8SClusterUIDKey is the attribute Key conforming to the "k8s.cluster.uid"
+ // semantic conventions. It represents a pseudo-ID for the cluster, set to the
+ // UID of the `kube-system` namespace.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "218fc5a9-a5f1-4b54-aa05-46717d0ab26d"
+ // Note: K8s doesn't have support for obtaining a cluster ID. If this is ever
+ // added, we will recommend collecting the `k8s.cluster.uid` through the
+ // official APIs. In the meantime, we are able to use the `uid` of the
+ // `kube-system` namespace as a proxy for cluster ID. Read on for the
+ // rationale.
+ //
+ // Every object created in a K8s cluster is assigned a distinct UID. The
+ // `kube-system` namespace is used by Kubernetes itself and will exist
+ // for the lifetime of the cluster. Using the `uid` of the `kube-system`
+ // namespace is a reasonable proxy for the K8s ClusterID as it will only
+ // change if the cluster is rebuilt. Furthermore, Kubernetes UIDs are
+ // UUIDs as standardized by
+ // [ISO/IEC 9834-8 and ITU-T X.667].
+ // Which states:
+ //
+ // > If generated according to one of the mechanisms defined in Rec.
+ // > ITU-T X.667 | ISO/IEC 9834-8, a UUID is either guaranteed to be
+ // > different from all other UUIDs generated before 3603 A.D., or is
+ // > extremely likely to be different (depending on the mechanism chosen).
+ //
+ // Therefore, UIDs between clusters should be extremely unlikely to
+ // conflict.
+ //
+ // [ISO/IEC 9834-8 and ITU-T X.667]: https://www.itu.int/ITU-T/studygroups/com17/oid.html
+ K8SClusterUIDKey = attribute.Key("k8s.cluster.uid")
+
+ // K8SContainerNameKey is the attribute Key conforming to the
+ // "k8s.container.name" semantic conventions. It represents the name of the
+ // Container from Pod specification, must be unique within a Pod. Container
+ // runtime usually uses different globally unique name (`container.name`).
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "redis"
+ K8SContainerNameKey = attribute.Key("k8s.container.name")
+
+ // K8SContainerRestartCountKey is the attribute Key conforming to the
+ // "k8s.container.restart_count" semantic conventions. It represents the number
+ // of times the container was restarted. This attribute can be used to identify
+ // a particular container (running or stopped) within a container spec.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ K8SContainerRestartCountKey = attribute.Key("k8s.container.restart_count")
+
+ // K8SContainerStatusLastTerminatedReasonKey is the attribute Key conforming to
+ // the "k8s.container.status.last_terminated_reason" semantic conventions. It
+ // represents the last terminated reason of the Container.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Evicted", "Error"
+ K8SContainerStatusLastTerminatedReasonKey = attribute.Key("k8s.container.status.last_terminated_reason")
+
+ // K8SContainerStatusReasonKey is the attribute Key conforming to the
+ // "k8s.container.status.reason" semantic conventions. It represents the reason
+ // for the container state. Corresponds to the `reason` field of the:
+ // [K8s ContainerStateWaiting] or [K8s ContainerStateTerminated].
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "ContainerCreating", "CrashLoopBackOff",
+ // "CreateContainerConfigError", "ErrImagePull", "ImagePullBackOff",
+ // "OOMKilled", "Completed", "Error", "ContainerCannotRun"
+ //
+ // [K8s ContainerStateWaiting]: https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.30/#containerstatewaiting-v1-core
+ // [K8s ContainerStateTerminated]: https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.30/#containerstateterminated-v1-core
+ K8SContainerStatusReasonKey = attribute.Key("k8s.container.status.reason")
+
+ // K8SContainerStatusStateKey is the attribute Key conforming to the
+ // "k8s.container.status.state" semantic conventions. It represents the state of
+ // the container. [K8s ContainerState].
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "terminated", "running", "waiting"
+ //
+ // [K8s ContainerState]: https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.30/#containerstate-v1-core
+ K8SContainerStatusStateKey = attribute.Key("k8s.container.status.state")
+
+ // K8SCronJobNameKey is the attribute Key conforming to the "k8s.cronjob.name"
+ // semantic conventions. It represents the name of the CronJob.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "opentelemetry"
+ K8SCronJobNameKey = attribute.Key("k8s.cronjob.name")
+
+ // K8SCronJobUIDKey is the attribute Key conforming to the "k8s.cronjob.uid"
+ // semantic conventions. It represents the UID of the CronJob.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "275ecb36-5aa8-4c2a-9c47-d8bb681b9aff"
+ K8SCronJobUIDKey = attribute.Key("k8s.cronjob.uid")
+
+ // K8SDaemonSetNameKey is the attribute Key conforming to the
+ // "k8s.daemonset.name" semantic conventions. It represents the name of the
+ // DaemonSet.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "opentelemetry"
+ K8SDaemonSetNameKey = attribute.Key("k8s.daemonset.name")
+
+ // K8SDaemonSetUIDKey is the attribute Key conforming to the "k8s.daemonset.uid"
+ // semantic conventions. It represents the UID of the DaemonSet.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "275ecb36-5aa8-4c2a-9c47-d8bb681b9aff"
+ K8SDaemonSetUIDKey = attribute.Key("k8s.daemonset.uid")
+
+ // K8SDeploymentNameKey is the attribute Key conforming to the
+ // "k8s.deployment.name" semantic conventions. It represents the name of the
+ // Deployment.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "opentelemetry"
+ K8SDeploymentNameKey = attribute.Key("k8s.deployment.name")
+
+ // K8SDeploymentUIDKey is the attribute Key conforming to the
+ // "k8s.deployment.uid" semantic conventions. It represents the UID of the
+ // Deployment.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "275ecb36-5aa8-4c2a-9c47-d8bb681b9aff"
+ K8SDeploymentUIDKey = attribute.Key("k8s.deployment.uid")
+
+ // K8SHPAMetricTypeKey is the attribute Key conforming to the
+ // "k8s.hpa.metric.type" semantic conventions. It represents the type of metric
+ // source for the horizontal pod autoscaler.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Resource", "ContainerResource"
+ // Note: This attribute reflects the `type` field of spec.metrics[] in the HPA.
+ K8SHPAMetricTypeKey = attribute.Key("k8s.hpa.metric.type")
+
+ // K8SHPANameKey is the attribute Key conforming to the "k8s.hpa.name" semantic
+ // conventions. It represents the name of the horizontal pod autoscaler.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "opentelemetry"
+ K8SHPANameKey = attribute.Key("k8s.hpa.name")
+
+ // K8SHPAScaletargetrefAPIVersionKey is the attribute Key conforming to the
+ // "k8s.hpa.scaletargetref.api_version" semantic conventions. It represents the
+ // API version of the target resource to scale for the HorizontalPodAutoscaler.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "apps/v1", "autoscaling/v2"
+ // Note: This maps to the `apiVersion` field in the `scaleTargetRef` of the HPA
+ // spec.
+ K8SHPAScaletargetrefAPIVersionKey = attribute.Key("k8s.hpa.scaletargetref.api_version")
+
+ // K8SHPAScaletargetrefKindKey is the attribute Key conforming to the
+ // "k8s.hpa.scaletargetref.kind" semantic conventions. It represents the kind of
+ // the target resource to scale for the HorizontalPodAutoscaler.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Deployment", "StatefulSet"
+ // Note: This maps to the `kind` field in the `scaleTargetRef` of the HPA spec.
+ K8SHPAScaletargetrefKindKey = attribute.Key("k8s.hpa.scaletargetref.kind")
+
+ // K8SHPAScaletargetrefNameKey is the attribute Key conforming to the
+ // "k8s.hpa.scaletargetref.name" semantic conventions. It represents the name of
+ // the target resource to scale for the HorizontalPodAutoscaler.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "my-deployment", "my-statefulset"
+ // Note: This maps to the `name` field in the `scaleTargetRef` of the HPA spec.
+ K8SHPAScaletargetrefNameKey = attribute.Key("k8s.hpa.scaletargetref.name")
+
+ // K8SHPAUIDKey is the attribute Key conforming to the "k8s.hpa.uid" semantic
+ // conventions. It represents the UID of the horizontal pod autoscaler.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "275ecb36-5aa8-4c2a-9c47-d8bb681b9aff"
+ K8SHPAUIDKey = attribute.Key("k8s.hpa.uid")
+
+ // K8SHugepageSizeKey is the attribute Key conforming to the "k8s.hugepage.size"
+ // semantic conventions. It represents the size (identifier) of the K8s huge
+ // page.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "2Mi"
+ K8SHugepageSizeKey = attribute.Key("k8s.hugepage.size")
+
+ // K8SJobNameKey is the attribute Key conforming to the "k8s.job.name" semantic
+ // conventions. It represents the name of the Job.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "opentelemetry"
+ K8SJobNameKey = attribute.Key("k8s.job.name")
+
+ // K8SJobUIDKey is the attribute Key conforming to the "k8s.job.uid" semantic
+ // conventions. It represents the UID of the Job.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "275ecb36-5aa8-4c2a-9c47-d8bb681b9aff"
+ K8SJobUIDKey = attribute.Key("k8s.job.uid")
+
+ // K8SNamespaceNameKey is the attribute Key conforming to the
+ // "k8s.namespace.name" semantic conventions. It represents the name of the
+ // namespace that the pod is running in.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "default"
+ K8SNamespaceNameKey = attribute.Key("k8s.namespace.name")
+
+ // K8SNamespacePhaseKey is the attribute Key conforming to the
+ // "k8s.namespace.phase" semantic conventions. It represents the phase of the
+ // K8s namespace.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "active", "terminating"
+ // Note: This attribute aligns with the `phase` field of the
+ // [K8s NamespaceStatus]
+ //
+ // [K8s NamespaceStatus]: https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.30/#namespacestatus-v1-core
+ K8SNamespacePhaseKey = attribute.Key("k8s.namespace.phase")
+
+ // K8SNodeConditionStatusKey is the attribute Key conforming to the
+ // "k8s.node.condition.status" semantic conventions. It represents the status of
+ // the condition, one of True, False, Unknown.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "true", "false", "unknown"
+ // Note: This attribute aligns with the `status` field of the
+ // [NodeCondition]
+ //
+ // [NodeCondition]: https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.30/#nodecondition-v1-core
+ K8SNodeConditionStatusKey = attribute.Key("k8s.node.condition.status")
+
+ // K8SNodeConditionTypeKey is the attribute Key conforming to the
+ // "k8s.node.condition.type" semantic conventions. It represents the condition
+ // type of a K8s Node.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Ready", "DiskPressure"
+ // Note: K8s Node conditions as described
+ // by [K8s documentation].
+ //
+ // This attribute aligns with the `type` field of the
+ // [NodeCondition]
+ //
+ // The set of possible values is not limited to those listed here. Managed
+ // Kubernetes environments,
+ // or custom controllers MAY introduce additional node condition types.
+ // When this occurs, the exact value as reported by the Kubernetes API SHOULD be
+ // used.
+ //
+ // [K8s documentation]: https://v1-32.docs.kubernetes.io/docs/reference/node/node-status/#condition
+ // [NodeCondition]: https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.30/#nodecondition-v1-core
+ K8SNodeConditionTypeKey = attribute.Key("k8s.node.condition.type")
+
+ // K8SNodeNameKey is the attribute Key conforming to the "k8s.node.name"
+ // semantic conventions. It represents the name of the Node.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "node-1"
+ K8SNodeNameKey = attribute.Key("k8s.node.name")
+
+ // K8SNodeUIDKey is the attribute Key conforming to the "k8s.node.uid" semantic
+ // conventions. It represents the UID of the Node.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "1eb3a0c6-0477-4080-a9cb-0cb7db65c6a2"
+ K8SNodeUIDKey = attribute.Key("k8s.node.uid")
+
+ // K8SPodNameKey is the attribute Key conforming to the "k8s.pod.name" semantic
+ // conventions. It represents the name of the Pod.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "opentelemetry-pod-autoconf"
+ K8SPodNameKey = attribute.Key("k8s.pod.name")
+
+ // K8SPodUIDKey is the attribute Key conforming to the "k8s.pod.uid" semantic
+ // conventions. It represents the UID of the Pod.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "275ecb36-5aa8-4c2a-9c47-d8bb681b9aff"
+ K8SPodUIDKey = attribute.Key("k8s.pod.uid")
+
+ // K8SReplicaSetNameKey is the attribute Key conforming to the
+ // "k8s.replicaset.name" semantic conventions. It represents the name of the
+ // ReplicaSet.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "opentelemetry"
+ K8SReplicaSetNameKey = attribute.Key("k8s.replicaset.name")
+
+ // K8SReplicaSetUIDKey is the attribute Key conforming to the
+ // "k8s.replicaset.uid" semantic conventions. It represents the UID of the
+ // ReplicaSet.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "275ecb36-5aa8-4c2a-9c47-d8bb681b9aff"
+ K8SReplicaSetUIDKey = attribute.Key("k8s.replicaset.uid")
+
+ // K8SReplicationControllerNameKey is the attribute Key conforming to the
+ // "k8s.replicationcontroller.name" semantic conventions. It represents the name
+ // of the replication controller.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "opentelemetry"
+ K8SReplicationControllerNameKey = attribute.Key("k8s.replicationcontroller.name")
+
+ // K8SReplicationControllerUIDKey is the attribute Key conforming to the
+ // "k8s.replicationcontroller.uid" semantic conventions. It represents the UID
+ // of the replication controller.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "275ecb36-5aa8-4c2a-9c47-d8bb681b9aff"
+ K8SReplicationControllerUIDKey = attribute.Key("k8s.replicationcontroller.uid")
+
+ // K8SResourceQuotaNameKey is the attribute Key conforming to the
+ // "k8s.resourcequota.name" semantic conventions. It represents the name of the
+ // resource quota.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "opentelemetry"
+ K8SResourceQuotaNameKey = attribute.Key("k8s.resourcequota.name")
+
+ // K8SResourceQuotaResourceNameKey is the attribute Key conforming to the
+ // "k8s.resourcequota.resource_name" semantic conventions. It represents the
+ // name of the K8s resource a resource quota defines.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "count/replicationcontrollers"
+ // Note: The value for this attribute can be either the full
+ // `count/[.]` string (e.g., count/deployments.apps,
+ // count/pods), or, for certain core Kubernetes resources, just the resource
+ // name (e.g., pods, services, configmaps). Both forms are supported by
+ // Kubernetes for object count quotas. See
+ // [Kubernetes Resource Quotas documentation] for more details.
+ //
+ // [Kubernetes Resource Quotas documentation]: https://kubernetes.io/docs/concepts/policy/resource-quotas/#object-count-quota
+ K8SResourceQuotaResourceNameKey = attribute.Key("k8s.resourcequota.resource_name")
+
+ // K8SResourceQuotaUIDKey is the attribute Key conforming to the
+ // "k8s.resourcequota.uid" semantic conventions. It represents the UID of the
+ // resource quota.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "275ecb36-5aa8-4c2a-9c47-d8bb681b9aff"
+ K8SResourceQuotaUIDKey = attribute.Key("k8s.resourcequota.uid")
+
+ // K8SStatefulSetNameKey is the attribute Key conforming to the
+ // "k8s.statefulset.name" semantic conventions. It represents the name of the
+ // StatefulSet.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "opentelemetry"
+ K8SStatefulSetNameKey = attribute.Key("k8s.statefulset.name")
+
+ // K8SStatefulSetUIDKey is the attribute Key conforming to the
+ // "k8s.statefulset.uid" semantic conventions. It represents the UID of the
+ // StatefulSet.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "275ecb36-5aa8-4c2a-9c47-d8bb681b9aff"
+ K8SStatefulSetUIDKey = attribute.Key("k8s.statefulset.uid")
+
+ // K8SStorageclassNameKey is the attribute Key conforming to the
+ // "k8s.storageclass.name" semantic conventions. It represents the name of K8s
+ // [StorageClass] object.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "gold.storageclass.storage.k8s.io"
+ //
+ // [StorageClass]: https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.30/#storageclass-v1-storage-k8s-io
+ K8SStorageclassNameKey = attribute.Key("k8s.storageclass.name")
+
+ // K8SVolumeNameKey is the attribute Key conforming to the "k8s.volume.name"
+ // semantic conventions. It represents the name of the K8s volume.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "volume0"
+ K8SVolumeNameKey = attribute.Key("k8s.volume.name")
+
+ // K8SVolumeTypeKey is the attribute Key conforming to the "k8s.volume.type"
+ // semantic conventions. It represents the type of the K8s volume.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "emptyDir", "persistentVolumeClaim"
+ K8SVolumeTypeKey = attribute.Key("k8s.volume.type")
+)
+
+// K8SClusterName returns an attribute KeyValue conforming to the
+// "k8s.cluster.name" semantic conventions. It represents the name of the
+// cluster.
+func K8SClusterName(val string) attribute.KeyValue {
+ return K8SClusterNameKey.String(val)
+}
+
+// K8SClusterUID returns an attribute KeyValue conforming to the
+// "k8s.cluster.uid" semantic conventions. It represents a pseudo-ID for the
+// cluster, set to the UID of the `kube-system` namespace.
+func K8SClusterUID(val string) attribute.KeyValue {
+ return K8SClusterUIDKey.String(val)
+}
+
+// K8SContainerName returns an attribute KeyValue conforming to the
+// "k8s.container.name" semantic conventions. It represents the name of the
+// Container from Pod specification, must be unique within a Pod. Container
+// runtime usually uses different globally unique name (`container.name`).
+func K8SContainerName(val string) attribute.KeyValue {
+ return K8SContainerNameKey.String(val)
+}
+
+// K8SContainerRestartCount returns an attribute KeyValue conforming to the
+// "k8s.container.restart_count" semantic conventions. It represents the number
+// of times the container was restarted. This attribute can be used to identify a
+// particular container (running or stopped) within a container spec.
+func K8SContainerRestartCount(val int) attribute.KeyValue {
+ return K8SContainerRestartCountKey.Int(val)
+}
+
+// K8SContainerStatusLastTerminatedReason returns an attribute KeyValue
+// conforming to the "k8s.container.status.last_terminated_reason" semantic
+// conventions. It represents the last terminated reason of the Container.
+func K8SContainerStatusLastTerminatedReason(val string) attribute.KeyValue {
+ return K8SContainerStatusLastTerminatedReasonKey.String(val)
+}
+
+// K8SCronJobAnnotation returns an attribute KeyValue conforming to the
+// "k8s.cronjob.annotation" semantic conventions. It represents the cronjob
+// annotation placed on the CronJob, the `` being the annotation name, the
+// value being the annotation value.
+func K8SCronJobAnnotation(key string, val string) attribute.KeyValue {
+ return attribute.String("k8s.cronjob.annotation."+key, val)
+}
+
+// K8SCronJobLabel returns an attribute KeyValue conforming to the
+// "k8s.cronjob.label" semantic conventions. It represents the label placed on
+// the CronJob, the `` being the label name, the value being the label
+// value.
+func K8SCronJobLabel(key string, val string) attribute.KeyValue {
+ return attribute.String("k8s.cronjob.label."+key, val)
+}
+
+// K8SCronJobName returns an attribute KeyValue conforming to the
+// "k8s.cronjob.name" semantic conventions. It represents the name of the
+// CronJob.
+func K8SCronJobName(val string) attribute.KeyValue {
+ return K8SCronJobNameKey.String(val)
+}
+
+// K8SCronJobUID returns an attribute KeyValue conforming to the
+// "k8s.cronjob.uid" semantic conventions. It represents the UID of the CronJob.
+func K8SCronJobUID(val string) attribute.KeyValue {
+ return K8SCronJobUIDKey.String(val)
+}
+
+// K8SDaemonSetAnnotation returns an attribute KeyValue conforming to the
+// "k8s.daemonset.annotation" semantic conventions. It represents the annotation
+// placed on the DaemonSet, the `` being the annotation name, the value
+// being the annotation value, even if the value is empty.
+func K8SDaemonSetAnnotation(key string, val string) attribute.KeyValue {
+ return attribute.String("k8s.daemonset.annotation."+key, val)
+}
+
+// K8SDaemonSetLabel returns an attribute KeyValue conforming to the
+// "k8s.daemonset.label" semantic conventions. It represents the label placed on
+// the DaemonSet, the `` being the label name, the value being the label
+// value, even if the value is empty.
+func K8SDaemonSetLabel(key string, val string) attribute.KeyValue {
+ return attribute.String("k8s.daemonset.label."+key, val)
+}
+
+// K8SDaemonSetName returns an attribute KeyValue conforming to the
+// "k8s.daemonset.name" semantic conventions. It represents the name of the
+// DaemonSet.
+func K8SDaemonSetName(val string) attribute.KeyValue {
+ return K8SDaemonSetNameKey.String(val)
+}
+
+// K8SDaemonSetUID returns an attribute KeyValue conforming to the
+// "k8s.daemonset.uid" semantic conventions. It represents the UID of the
+// DaemonSet.
+func K8SDaemonSetUID(val string) attribute.KeyValue {
+ return K8SDaemonSetUIDKey.String(val)
+}
+
+// K8SDeploymentAnnotation returns an attribute KeyValue conforming to the
+// "k8s.deployment.annotation" semantic conventions. It represents the annotation
+// placed on the Deployment, the `` being the annotation name, the value
+// being the annotation value, even if the value is empty.
+func K8SDeploymentAnnotation(key string, val string) attribute.KeyValue {
+ return attribute.String("k8s.deployment.annotation."+key, val)
+}
+
+// K8SDeploymentLabel returns an attribute KeyValue conforming to the
+// "k8s.deployment.label" semantic conventions. It represents the label placed on
+// the Deployment, the `` being the label name, the value being the label
+// value, even if the value is empty.
+func K8SDeploymentLabel(key string, val string) attribute.KeyValue {
+ return attribute.String("k8s.deployment.label."+key, val)
+}
+
+// K8SDeploymentName returns an attribute KeyValue conforming to the
+// "k8s.deployment.name" semantic conventions. It represents the name of the
+// Deployment.
+func K8SDeploymentName(val string) attribute.KeyValue {
+ return K8SDeploymentNameKey.String(val)
+}
+
+// K8SDeploymentUID returns an attribute KeyValue conforming to the
+// "k8s.deployment.uid" semantic conventions. It represents the UID of the
+// Deployment.
+func K8SDeploymentUID(val string) attribute.KeyValue {
+ return K8SDeploymentUIDKey.String(val)
+}
+
+// K8SHPAMetricType returns an attribute KeyValue conforming to the
+// "k8s.hpa.metric.type" semantic conventions. It represents the type of metric
+// source for the horizontal pod autoscaler.
+func K8SHPAMetricType(val string) attribute.KeyValue {
+ return K8SHPAMetricTypeKey.String(val)
+}
+
+// K8SHPAName returns an attribute KeyValue conforming to the "k8s.hpa.name"
+// semantic conventions. It represents the name of the horizontal pod autoscaler.
+func K8SHPAName(val string) attribute.KeyValue {
+ return K8SHPANameKey.String(val)
+}
+
+// K8SHPAScaletargetrefAPIVersion returns an attribute KeyValue conforming to the
+// "k8s.hpa.scaletargetref.api_version" semantic conventions. It represents the
+// API version of the target resource to scale for the HorizontalPodAutoscaler.
+func K8SHPAScaletargetrefAPIVersion(val string) attribute.KeyValue {
+ return K8SHPAScaletargetrefAPIVersionKey.String(val)
+}
+
+// K8SHPAScaletargetrefKind returns an attribute KeyValue conforming to the
+// "k8s.hpa.scaletargetref.kind" semantic conventions. It represents the kind of
+// the target resource to scale for the HorizontalPodAutoscaler.
+func K8SHPAScaletargetrefKind(val string) attribute.KeyValue {
+ return K8SHPAScaletargetrefKindKey.String(val)
+}
+
+// K8SHPAScaletargetrefName returns an attribute KeyValue conforming to the
+// "k8s.hpa.scaletargetref.name" semantic conventions. It represents the name of
+// the target resource to scale for the HorizontalPodAutoscaler.
+func K8SHPAScaletargetrefName(val string) attribute.KeyValue {
+ return K8SHPAScaletargetrefNameKey.String(val)
+}
+
+// K8SHPAUID returns an attribute KeyValue conforming to the "k8s.hpa.uid"
+// semantic conventions. It represents the UID of the horizontal pod autoscaler.
+func K8SHPAUID(val string) attribute.KeyValue {
+ return K8SHPAUIDKey.String(val)
+}
+
+// K8SHugepageSize returns an attribute KeyValue conforming to the
+// "k8s.hugepage.size" semantic conventions. It represents the size (identifier)
+// of the K8s huge page.
+func K8SHugepageSize(val string) attribute.KeyValue {
+ return K8SHugepageSizeKey.String(val)
+}
+
+// K8SJobAnnotation returns an attribute KeyValue conforming to the
+// "k8s.job.annotation" semantic conventions. It represents the annotation placed
+// on the Job, the `` being the annotation name, the value being the
+// annotation value, even if the value is empty.
+func K8SJobAnnotation(key string, val string) attribute.KeyValue {
+ return attribute.String("k8s.job.annotation."+key, val)
+}
+
+// K8SJobLabel returns an attribute KeyValue conforming to the "k8s.job.label"
+// semantic conventions. It represents the label placed on the Job, the ``
+// being the label name, the value being the label value, even if the value is
+// empty.
+func K8SJobLabel(key string, val string) attribute.KeyValue {
+ return attribute.String("k8s.job.label."+key, val)
+}
+
+// K8SJobName returns an attribute KeyValue conforming to the "k8s.job.name"
+// semantic conventions. It represents the name of the Job.
+func K8SJobName(val string) attribute.KeyValue {
+ return K8SJobNameKey.String(val)
+}
+
+// K8SJobUID returns an attribute KeyValue conforming to the "k8s.job.uid"
+// semantic conventions. It represents the UID of the Job.
+func K8SJobUID(val string) attribute.KeyValue {
+ return K8SJobUIDKey.String(val)
+}
+
+// K8SNamespaceAnnotation returns an attribute KeyValue conforming to the
+// "k8s.namespace.annotation" semantic conventions. It represents the annotation
+// placed on the Namespace, the `` being the annotation name, the value
+// being the annotation value, even if the value is empty.
+func K8SNamespaceAnnotation(key string, val string) attribute.KeyValue {
+ return attribute.String("k8s.namespace.annotation."+key, val)
+}
+
+// K8SNamespaceLabel returns an attribute KeyValue conforming to the
+// "k8s.namespace.label" semantic conventions. It represents the label placed on
+// the Namespace, the `` being the label name, the value being the label
+// value, even if the value is empty.
+func K8SNamespaceLabel(key string, val string) attribute.KeyValue {
+ return attribute.String("k8s.namespace.label."+key, val)
+}
+
+// K8SNamespaceName returns an attribute KeyValue conforming to the
+// "k8s.namespace.name" semantic conventions. It represents the name of the
+// namespace that the pod is running in.
+func K8SNamespaceName(val string) attribute.KeyValue {
+ return K8SNamespaceNameKey.String(val)
+}
+
+// K8SNodeAnnotation returns an attribute KeyValue conforming to the
+// "k8s.node.annotation" semantic conventions. It represents the annotation
+// placed on the Node, the `` being the annotation name, the value being the
+// annotation value, even if the value is empty.
+func K8SNodeAnnotation(key string, val string) attribute.KeyValue {
+ return attribute.String("k8s.node.annotation."+key, val)
+}
+
+// K8SNodeLabel returns an attribute KeyValue conforming to the "k8s.node.label"
+// semantic conventions. It represents the label placed on the Node, the ``
+// being the label name, the value being the label value, even if the value is
+// empty.
+func K8SNodeLabel(key string, val string) attribute.KeyValue {
+ return attribute.String("k8s.node.label."+key, val)
+}
+
+// K8SNodeName returns an attribute KeyValue conforming to the "k8s.node.name"
+// semantic conventions. It represents the name of the Node.
+func K8SNodeName(val string) attribute.KeyValue {
+ return K8SNodeNameKey.String(val)
+}
+
+// K8SNodeUID returns an attribute KeyValue conforming to the "k8s.node.uid"
+// semantic conventions. It represents the UID of the Node.
+func K8SNodeUID(val string) attribute.KeyValue {
+ return K8SNodeUIDKey.String(val)
+}
+
+// K8SPodAnnotation returns an attribute KeyValue conforming to the
+// "k8s.pod.annotation" semantic conventions. It represents the annotation placed
+// on the Pod, the `` being the annotation name, the value being the
+// annotation value.
+func K8SPodAnnotation(key string, val string) attribute.KeyValue {
+ return attribute.String("k8s.pod.annotation."+key, val)
+}
+
+// K8SPodLabel returns an attribute KeyValue conforming to the "k8s.pod.label"
+// semantic conventions. It represents the label placed on the Pod, the ``
+// being the label name, the value being the label value.
+func K8SPodLabel(key string, val string) attribute.KeyValue {
+ return attribute.String("k8s.pod.label."+key, val)
+}
+
+// K8SPodName returns an attribute KeyValue conforming to the "k8s.pod.name"
+// semantic conventions. It represents the name of the Pod.
+func K8SPodName(val string) attribute.KeyValue {
+ return K8SPodNameKey.String(val)
+}
+
+// K8SPodUID returns an attribute KeyValue conforming to the "k8s.pod.uid"
+// semantic conventions. It represents the UID of the Pod.
+func K8SPodUID(val string) attribute.KeyValue {
+ return K8SPodUIDKey.String(val)
+}
+
+// K8SReplicaSetAnnotation returns an attribute KeyValue conforming to the
+// "k8s.replicaset.annotation" semantic conventions. It represents the annotation
+// placed on the ReplicaSet, the `` being the annotation name, the value
+// being the annotation value, even if the value is empty.
+func K8SReplicaSetAnnotation(key string, val string) attribute.KeyValue {
+ return attribute.String("k8s.replicaset.annotation."+key, val)
+}
+
+// K8SReplicaSetLabel returns an attribute KeyValue conforming to the
+// "k8s.replicaset.label" semantic conventions. It represents the label placed on
+// the ReplicaSet, the `` being the label name, the value being the label
+// value, even if the value is empty.
+func K8SReplicaSetLabel(key string, val string) attribute.KeyValue {
+ return attribute.String("k8s.replicaset.label."+key, val)
+}
+
+// K8SReplicaSetName returns an attribute KeyValue conforming to the
+// "k8s.replicaset.name" semantic conventions. It represents the name of the
+// ReplicaSet.
+func K8SReplicaSetName(val string) attribute.KeyValue {
+ return K8SReplicaSetNameKey.String(val)
+}
+
+// K8SReplicaSetUID returns an attribute KeyValue conforming to the
+// "k8s.replicaset.uid" semantic conventions. It represents the UID of the
+// ReplicaSet.
+func K8SReplicaSetUID(val string) attribute.KeyValue {
+ return K8SReplicaSetUIDKey.String(val)
+}
+
+// K8SReplicationControllerName returns an attribute KeyValue conforming to the
+// "k8s.replicationcontroller.name" semantic conventions. It represents the name
+// of the replication controller.
+func K8SReplicationControllerName(val string) attribute.KeyValue {
+ return K8SReplicationControllerNameKey.String(val)
+}
+
+// K8SReplicationControllerUID returns an attribute KeyValue conforming to the
+// "k8s.replicationcontroller.uid" semantic conventions. It represents the UID of
+// the replication controller.
+func K8SReplicationControllerUID(val string) attribute.KeyValue {
+ return K8SReplicationControllerUIDKey.String(val)
+}
+
+// K8SResourceQuotaName returns an attribute KeyValue conforming to the
+// "k8s.resourcequota.name" semantic conventions. It represents the name of the
+// resource quota.
+func K8SResourceQuotaName(val string) attribute.KeyValue {
+ return K8SResourceQuotaNameKey.String(val)
+}
+
+// K8SResourceQuotaResourceName returns an attribute KeyValue conforming to the
+// "k8s.resourcequota.resource_name" semantic conventions. It represents the name
+// of the K8s resource a resource quota defines.
+func K8SResourceQuotaResourceName(val string) attribute.KeyValue {
+ return K8SResourceQuotaResourceNameKey.String(val)
+}
+
+// K8SResourceQuotaUID returns an attribute KeyValue conforming to the
+// "k8s.resourcequota.uid" semantic conventions. It represents the UID of the
+// resource quota.
+func K8SResourceQuotaUID(val string) attribute.KeyValue {
+ return K8SResourceQuotaUIDKey.String(val)
+}
+
+// K8SStatefulSetAnnotation returns an attribute KeyValue conforming to the
+// "k8s.statefulset.annotation" semantic conventions. It represents the
+// annotation placed on the StatefulSet, the `` being the annotation name,
+// the value being the annotation value, even if the value is empty.
+func K8SStatefulSetAnnotation(key string, val string) attribute.KeyValue {
+ return attribute.String("k8s.statefulset.annotation."+key, val)
+}
+
+// K8SStatefulSetLabel returns an attribute KeyValue conforming to the
+// "k8s.statefulset.label" semantic conventions. It represents the label placed
+// on the StatefulSet, the `` being the label name, the value being the
+// label value, even if the value is empty.
+func K8SStatefulSetLabel(key string, val string) attribute.KeyValue {
+ return attribute.String("k8s.statefulset.label."+key, val)
+}
+
+// K8SStatefulSetName returns an attribute KeyValue conforming to the
+// "k8s.statefulset.name" semantic conventions. It represents the name of the
+// StatefulSet.
+func K8SStatefulSetName(val string) attribute.KeyValue {
+ return K8SStatefulSetNameKey.String(val)
+}
+
+// K8SStatefulSetUID returns an attribute KeyValue conforming to the
+// "k8s.statefulset.uid" semantic conventions. It represents the UID of the
+// StatefulSet.
+func K8SStatefulSetUID(val string) attribute.KeyValue {
+ return K8SStatefulSetUIDKey.String(val)
+}
+
+// K8SStorageclassName returns an attribute KeyValue conforming to the
+// "k8s.storageclass.name" semantic conventions. It represents the name of K8s
+// [StorageClass] object.
+//
+// [StorageClass]: https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.30/#storageclass-v1-storage-k8s-io
+func K8SStorageclassName(val string) attribute.KeyValue {
+ return K8SStorageclassNameKey.String(val)
+}
+
+// K8SVolumeName returns an attribute KeyValue conforming to the
+// "k8s.volume.name" semantic conventions. It represents the name of the K8s
+// volume.
+func K8SVolumeName(val string) attribute.KeyValue {
+ return K8SVolumeNameKey.String(val)
+}
+
+// Enum values for k8s.container.status.reason
+var (
+ // The container is being created.
+ // Stability: development
+ K8SContainerStatusReasonContainerCreating = K8SContainerStatusReasonKey.String("ContainerCreating")
+ // The container is in a crash loop back off state.
+ // Stability: development
+ K8SContainerStatusReasonCrashLoopBackOff = K8SContainerStatusReasonKey.String("CrashLoopBackOff")
+ // There was an error creating the container configuration.
+ // Stability: development
+ K8SContainerStatusReasonCreateContainerConfigError = K8SContainerStatusReasonKey.String("CreateContainerConfigError")
+ // There was an error pulling the container image.
+ // Stability: development
+ K8SContainerStatusReasonErrImagePull = K8SContainerStatusReasonKey.String("ErrImagePull")
+ // The container image pull is in back off state.
+ // Stability: development
+ K8SContainerStatusReasonImagePullBackOff = K8SContainerStatusReasonKey.String("ImagePullBackOff")
+ // The container was killed due to out of memory.
+ // Stability: development
+ K8SContainerStatusReasonOomKilled = K8SContainerStatusReasonKey.String("OOMKilled")
+ // The container has completed execution.
+ // Stability: development
+ K8SContainerStatusReasonCompleted = K8SContainerStatusReasonKey.String("Completed")
+ // There was an error with the container.
+ // Stability: development
+ K8SContainerStatusReasonError = K8SContainerStatusReasonKey.String("Error")
+ // The container cannot run.
+ // Stability: development
+ K8SContainerStatusReasonContainerCannotRun = K8SContainerStatusReasonKey.String("ContainerCannotRun")
+)
+
+// Enum values for k8s.container.status.state
+var (
+ // The container has terminated.
+ // Stability: development
+ K8SContainerStatusStateTerminated = K8SContainerStatusStateKey.String("terminated")
+ // The container is running.
+ // Stability: development
+ K8SContainerStatusStateRunning = K8SContainerStatusStateKey.String("running")
+ // The container is waiting.
+ // Stability: development
+ K8SContainerStatusStateWaiting = K8SContainerStatusStateKey.String("waiting")
+)
+
+// Enum values for k8s.namespace.phase
+var (
+ // Active namespace phase as described by [K8s API]
+ // Stability: development
+ //
+ // [K8s API]: https://pkg.go.dev/k8s.io/api@v0.31.3/core/v1#NamespacePhase
+ K8SNamespacePhaseActive = K8SNamespacePhaseKey.String("active")
+ // Terminating namespace phase as described by [K8s API]
+ // Stability: development
+ //
+ // [K8s API]: https://pkg.go.dev/k8s.io/api@v0.31.3/core/v1#NamespacePhase
+ K8SNamespacePhaseTerminating = K8SNamespacePhaseKey.String("terminating")
+)
+
+// Enum values for k8s.node.condition.status
+var (
+ // condition_true
+ // Stability: development
+ K8SNodeConditionStatusConditionTrue = K8SNodeConditionStatusKey.String("true")
+ // condition_false
+ // Stability: development
+ K8SNodeConditionStatusConditionFalse = K8SNodeConditionStatusKey.String("false")
+ // condition_unknown
+ // Stability: development
+ K8SNodeConditionStatusConditionUnknown = K8SNodeConditionStatusKey.String("unknown")
+)
+
+// Enum values for k8s.node.condition.type
+var (
+ // The node is healthy and ready to accept pods
+ // Stability: development
+ K8SNodeConditionTypeReady = K8SNodeConditionTypeKey.String("Ready")
+ // Pressure exists on the disk size—that is, if the disk capacity is low
+ // Stability: development
+ K8SNodeConditionTypeDiskPressure = K8SNodeConditionTypeKey.String("DiskPressure")
+ // Pressure exists on the node memory—that is, if the node memory is low
+ // Stability: development
+ K8SNodeConditionTypeMemoryPressure = K8SNodeConditionTypeKey.String("MemoryPressure")
+ // Pressure exists on the processes—that is, if there are too many processes
+ // on the node
+ // Stability: development
+ K8SNodeConditionTypePIDPressure = K8SNodeConditionTypeKey.String("PIDPressure")
+ // The network for the node is not correctly configured
+ // Stability: development
+ K8SNodeConditionTypeNetworkUnavailable = K8SNodeConditionTypeKey.String("NetworkUnavailable")
+)
+
+// Enum values for k8s.volume.type
+var (
+ // A [persistentVolumeClaim] volume
+ // Stability: development
+ //
+ // [persistentVolumeClaim]: https://v1-30.docs.kubernetes.io/docs/concepts/storage/volumes/#persistentvolumeclaim
+ K8SVolumeTypePersistentVolumeClaim = K8SVolumeTypeKey.String("persistentVolumeClaim")
+ // A [configMap] volume
+ // Stability: development
+ //
+ // [configMap]: https://v1-30.docs.kubernetes.io/docs/concepts/storage/volumes/#configmap
+ K8SVolumeTypeConfigMap = K8SVolumeTypeKey.String("configMap")
+ // A [downwardAPI] volume
+ // Stability: development
+ //
+ // [downwardAPI]: https://v1-30.docs.kubernetes.io/docs/concepts/storage/volumes/#downwardapi
+ K8SVolumeTypeDownwardAPI = K8SVolumeTypeKey.String("downwardAPI")
+ // An [emptyDir] volume
+ // Stability: development
+ //
+ // [emptyDir]: https://v1-30.docs.kubernetes.io/docs/concepts/storage/volumes/#emptydir
+ K8SVolumeTypeEmptyDir = K8SVolumeTypeKey.String("emptyDir")
+ // A [secret] volume
+ // Stability: development
+ //
+ // [secret]: https://v1-30.docs.kubernetes.io/docs/concepts/storage/volumes/#secret
+ K8SVolumeTypeSecret = K8SVolumeTypeKey.String("secret")
+ // A [local] volume
+ // Stability: development
+ //
+ // [local]: https://v1-30.docs.kubernetes.io/docs/concepts/storage/volumes/#local
+ K8SVolumeTypeLocal = K8SVolumeTypeKey.String("local")
+)
+
+// Namespace: linux
+const (
+ // LinuxMemorySlabStateKey is the attribute Key conforming to the
+ // "linux.memory.slab.state" semantic conventions. It represents the Linux Slab
+ // memory state.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "reclaimable", "unreclaimable"
+ LinuxMemorySlabStateKey = attribute.Key("linux.memory.slab.state")
+)
+
+// Enum values for linux.memory.slab.state
+var (
+ // reclaimable
+ // Stability: development
+ LinuxMemorySlabStateReclaimable = LinuxMemorySlabStateKey.String("reclaimable")
+ // unreclaimable
+ // Stability: development
+ LinuxMemorySlabStateUnreclaimable = LinuxMemorySlabStateKey.String("unreclaimable")
+)
+
+// Namespace: log
+const (
+ // LogFileNameKey is the attribute Key conforming to the "log.file.name"
+ // semantic conventions. It represents the basename of the file.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "audit.log"
+ LogFileNameKey = attribute.Key("log.file.name")
+
+ // LogFileNameResolvedKey is the attribute Key conforming to the
+ // "log.file.name_resolved" semantic conventions. It represents the basename of
+ // the file, with symlinks resolved.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "uuid.log"
+ LogFileNameResolvedKey = attribute.Key("log.file.name_resolved")
+
+ // LogFilePathKey is the attribute Key conforming to the "log.file.path"
+ // semantic conventions. It represents the full path to the file.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "/var/log/mysql/audit.log"
+ LogFilePathKey = attribute.Key("log.file.path")
+
+ // LogFilePathResolvedKey is the attribute Key conforming to the
+ // "log.file.path_resolved" semantic conventions. It represents the full path to
+ // the file, with symlinks resolved.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "/var/lib/docker/uuid.log"
+ LogFilePathResolvedKey = attribute.Key("log.file.path_resolved")
+
+ // LogIostreamKey is the attribute Key conforming to the "log.iostream" semantic
+ // conventions. It represents the stream associated with the log. See below for
+ // a list of well-known values.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ LogIostreamKey = attribute.Key("log.iostream")
+
+ // LogRecordOriginalKey is the attribute Key conforming to the
+ // "log.record.original" semantic conventions. It represents the complete
+ // original Log Record.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "77 <86>1 2015-08-06T21:58:59.694Z 192.168.2.133 inactive - - -
+ // Something happened", "[INFO] 8/3/24 12:34:56 Something happened"
+ // Note: This value MAY be added when processing a Log Record which was
+ // originally transmitted as a string or equivalent data type AND the Body field
+ // of the Log Record does not contain the same value. (e.g. a syslog or a log
+ // record read from a file.)
+ LogRecordOriginalKey = attribute.Key("log.record.original")
+
+ // LogRecordUIDKey is the attribute Key conforming to the "log.record.uid"
+ // semantic conventions. It represents a unique identifier for the Log Record.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "01ARZ3NDEKTSV4RRFFQ69G5FAV"
+ // Note: If an id is provided, other log records with the same id will be
+ // considered duplicates and can be removed safely. This means, that two
+ // distinguishable log records MUST have different values.
+ // The id MAY be an
+ // [Universally Unique Lexicographically Sortable Identifier (ULID)], but other
+ // identifiers (e.g. UUID) may be used as needed.
+ //
+ // [Universally Unique Lexicographically Sortable Identifier (ULID)]: https://github.com/ulid/spec
+ LogRecordUIDKey = attribute.Key("log.record.uid")
+)
+
+// LogFileName returns an attribute KeyValue conforming to the "log.file.name"
+// semantic conventions. It represents the basename of the file.
+func LogFileName(val string) attribute.KeyValue {
+ return LogFileNameKey.String(val)
+}
+
+// LogFileNameResolved returns an attribute KeyValue conforming to the
+// "log.file.name_resolved" semantic conventions. It represents the basename of
+// the file, with symlinks resolved.
+func LogFileNameResolved(val string) attribute.KeyValue {
+ return LogFileNameResolvedKey.String(val)
+}
+
+// LogFilePath returns an attribute KeyValue conforming to the "log.file.path"
+// semantic conventions. It represents the full path to the file.
+func LogFilePath(val string) attribute.KeyValue {
+ return LogFilePathKey.String(val)
+}
+
+// LogFilePathResolved returns an attribute KeyValue conforming to the
+// "log.file.path_resolved" semantic conventions. It represents the full path to
+// the file, with symlinks resolved.
+func LogFilePathResolved(val string) attribute.KeyValue {
+ return LogFilePathResolvedKey.String(val)
+}
+
+// LogRecordOriginal returns an attribute KeyValue conforming to the
+// "log.record.original" semantic conventions. It represents the complete
+// original Log Record.
+func LogRecordOriginal(val string) attribute.KeyValue {
+ return LogRecordOriginalKey.String(val)
+}
+
+// LogRecordUID returns an attribute KeyValue conforming to the "log.record.uid"
+// semantic conventions. It represents a unique identifier for the Log Record.
+func LogRecordUID(val string) attribute.KeyValue {
+ return LogRecordUIDKey.String(val)
+}
+
+// Enum values for log.iostream
+var (
+ // Logs from stdout stream
+ // Stability: development
+ LogIostreamStdout = LogIostreamKey.String("stdout")
+ // Events from stderr stream
+ // Stability: development
+ LogIostreamStderr = LogIostreamKey.String("stderr")
+)
+
+// Namespace: mainframe
+const (
+ // MainframeLparNameKey is the attribute Key conforming to the
+ // "mainframe.lpar.name" semantic conventions. It represents the name of the
+ // logical partition that hosts a systems with a mainframe operating system.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "LPAR01"
+ MainframeLparNameKey = attribute.Key("mainframe.lpar.name")
+)
+
+// MainframeLparName returns an attribute KeyValue conforming to the
+// "mainframe.lpar.name" semantic conventions. It represents the name of the
+// logical partition that hosts a systems with a mainframe operating system.
+func MainframeLparName(val string) attribute.KeyValue {
+ return MainframeLparNameKey.String(val)
+}
+
+// Namespace: messaging
+const (
+ // MessagingBatchMessageCountKey is the attribute Key conforming to the
+ // "messaging.batch.message_count" semantic conventions. It represents the
+ // number of messages sent, received, or processed in the scope of the batching
+ // operation.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 0, 1, 2
+ // Note: Instrumentations SHOULD NOT set `messaging.batch.message_count` on
+ // spans that operate with a single message. When a messaging client library
+ // supports both batch and single-message API for the same operation,
+ // instrumentations SHOULD use `messaging.batch.message_count` for batching APIs
+ // and SHOULD NOT use it for single-message APIs.
+ MessagingBatchMessageCountKey = attribute.Key("messaging.batch.message_count")
+
+ // MessagingClientIDKey is the attribute Key conforming to the
+ // "messaging.client.id" semantic conventions. It represents a unique identifier
+ // for the client that consumes or produces a message.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "client-5", "myhost@8742@s8083jm"
+ MessagingClientIDKey = attribute.Key("messaging.client.id")
+
+ // MessagingConsumerGroupNameKey is the attribute Key conforming to the
+ // "messaging.consumer.group.name" semantic conventions. It represents the name
+ // of the consumer group with which a consumer is associated.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "my-group", "indexer"
+ // Note: Semantic conventions for individual messaging systems SHOULD document
+ // whether `messaging.consumer.group.name` is applicable and what it means in
+ // the context of that system.
+ MessagingConsumerGroupNameKey = attribute.Key("messaging.consumer.group.name")
+
+ // MessagingDestinationAnonymousKey is the attribute Key conforming to the
+ // "messaging.destination.anonymous" semantic conventions. It represents a
+ // boolean that is true if the message destination is anonymous (could be
+ // unnamed or have auto-generated name).
+ //
+ // Type: boolean
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ MessagingDestinationAnonymousKey = attribute.Key("messaging.destination.anonymous")
+
+ // MessagingDestinationNameKey is the attribute Key conforming to the
+ // "messaging.destination.name" semantic conventions. It represents the message
+ // destination name.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "MyQueue", "MyTopic"
+ // Note: Destination name SHOULD uniquely identify a specific queue, topic or
+ // other entity within the broker. If
+ // the broker doesn't have such notion, the destination name SHOULD uniquely
+ // identify the broker.
+ MessagingDestinationNameKey = attribute.Key("messaging.destination.name")
+
+ // MessagingDestinationPartitionIDKey is the attribute Key conforming to the
+ // "messaging.destination.partition.id" semantic conventions. It represents the
+ // identifier of the partition messages are sent to or received from, unique
+ // within the `messaging.destination.name`.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 1
+ MessagingDestinationPartitionIDKey = attribute.Key("messaging.destination.partition.id")
+
+ // MessagingDestinationSubscriptionNameKey is the attribute Key conforming to
+ // the "messaging.destination.subscription.name" semantic conventions. It
+ // represents the name of the destination subscription from which a message is
+ // consumed.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "subscription-a"
+ // Note: Semantic conventions for individual messaging systems SHOULD document
+ // whether `messaging.destination.subscription.name` is applicable and what it
+ // means in the context of that system.
+ MessagingDestinationSubscriptionNameKey = attribute.Key("messaging.destination.subscription.name")
+
+ // MessagingDestinationTemplateKey is the attribute Key conforming to the
+ // "messaging.destination.template" semantic conventions. It represents the low
+ // cardinality representation of the messaging destination name.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "/customers/{customerId}"
+ // Note: Destination names could be constructed from templates. An example would
+ // be a destination name involving a user name or product id. Although the
+ // destination name in this case is of high cardinality, the underlying template
+ // is of low cardinality and can be effectively used for grouping and
+ // aggregation.
+ MessagingDestinationTemplateKey = attribute.Key("messaging.destination.template")
+
+ // MessagingDestinationTemporaryKey is the attribute Key conforming to the
+ // "messaging.destination.temporary" semantic conventions. It represents a
+ // boolean that is true if the message destination is temporary and might not
+ // exist anymore after messages are processed.
+ //
+ // Type: boolean
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ MessagingDestinationTemporaryKey = attribute.Key("messaging.destination.temporary")
+
+ // MessagingEventHubsMessageEnqueuedTimeKey is the attribute Key conforming to
+ // the "messaging.eventhubs.message.enqueued_time" semantic conventions. It
+ // represents the UTC epoch seconds at which the message has been accepted and
+ // stored in the entity.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ MessagingEventHubsMessageEnqueuedTimeKey = attribute.Key("messaging.eventhubs.message.enqueued_time")
+
+ // MessagingGCPPubSubMessageAckDeadlineKey is the attribute Key conforming to
+ // the "messaging.gcp_pubsub.message.ack_deadline" semantic conventions. It
+ // represents the ack deadline in seconds set for the modify ack deadline
+ // request.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ MessagingGCPPubSubMessageAckDeadlineKey = attribute.Key("messaging.gcp_pubsub.message.ack_deadline")
+
+ // MessagingGCPPubSubMessageAckIDKey is the attribute Key conforming to the
+ // "messaging.gcp_pubsub.message.ack_id" semantic conventions. It represents the
+ // ack id for a given message.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: ack_id
+ MessagingGCPPubSubMessageAckIDKey = attribute.Key("messaging.gcp_pubsub.message.ack_id")
+
+ // MessagingGCPPubSubMessageDeliveryAttemptKey is the attribute Key conforming
+ // to the "messaging.gcp_pubsub.message.delivery_attempt" semantic conventions.
+ // It represents the delivery attempt for a given message.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ MessagingGCPPubSubMessageDeliveryAttemptKey = attribute.Key("messaging.gcp_pubsub.message.delivery_attempt")
+
+ // MessagingGCPPubSubMessageOrderingKeyKey is the attribute Key conforming to
+ // the "messaging.gcp_pubsub.message.ordering_key" semantic conventions. It
+ // represents the ordering key for a given message. If the attribute is not
+ // present, the message does not have an ordering key.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: ordering_key
+ MessagingGCPPubSubMessageOrderingKeyKey = attribute.Key("messaging.gcp_pubsub.message.ordering_key")
+
+ // MessagingKafkaMessageKeyKey is the attribute Key conforming to the
+ // "messaging.kafka.message.key" semantic conventions. It represents the message
+ // keys in Kafka are used for grouping alike messages to ensure they're
+ // processed on the same partition. They differ from `messaging.message.id` in
+ // that they're not unique. If the key is `null`, the attribute MUST NOT be set.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: myKey
+ // Note: If the key type is not string, it's string representation has to be
+ // supplied for the attribute. If the key has no unambiguous, canonical string
+ // form, don't include its value.
+ MessagingKafkaMessageKeyKey = attribute.Key("messaging.kafka.message.key")
+
+ // MessagingKafkaMessageTombstoneKey is the attribute Key conforming to the
+ // "messaging.kafka.message.tombstone" semantic conventions. It represents a
+ // boolean that is true if the message is a tombstone.
+ //
+ // Type: boolean
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ MessagingKafkaMessageTombstoneKey = attribute.Key("messaging.kafka.message.tombstone")
+
+ // MessagingKafkaOffsetKey is the attribute Key conforming to the
+ // "messaging.kafka.offset" semantic conventions. It represents the offset of a
+ // record in the corresponding Kafka partition.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ MessagingKafkaOffsetKey = attribute.Key("messaging.kafka.offset")
+
+ // MessagingMessageBodySizeKey is the attribute Key conforming to the
+ // "messaging.message.body.size" semantic conventions. It represents the size of
+ // the message body in bytes.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Note: This can refer to both the compressed or uncompressed body size. If
+ // both sizes are known, the uncompressed
+ // body size should be used.
+ MessagingMessageBodySizeKey = attribute.Key("messaging.message.body.size")
+
+ // MessagingMessageConversationIDKey is the attribute Key conforming to the
+ // "messaging.message.conversation_id" semantic conventions. It represents the
+ // conversation ID identifying the conversation to which the message belongs,
+ // represented as a string. Sometimes called "Correlation ID".
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: MyConversationId
+ MessagingMessageConversationIDKey = attribute.Key("messaging.message.conversation_id")
+
+ // MessagingMessageEnvelopeSizeKey is the attribute Key conforming to the
+ // "messaging.message.envelope.size" semantic conventions. It represents the
+ // size of the message body and metadata in bytes.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Note: This can refer to both the compressed or uncompressed size. If both
+ // sizes are known, the uncompressed
+ // size should be used.
+ MessagingMessageEnvelopeSizeKey = attribute.Key("messaging.message.envelope.size")
+
+ // MessagingMessageIDKey is the attribute Key conforming to the
+ // "messaging.message.id" semantic conventions. It represents a value used by
+ // the messaging system as an identifier for the message, represented as a
+ // string.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 452a7c7c7c7048c2f887f61572b18fc2
+ MessagingMessageIDKey = attribute.Key("messaging.message.id")
+
+ // MessagingOperationNameKey is the attribute Key conforming to the
+ // "messaging.operation.name" semantic conventions. It represents the
+ // system-specific name of the messaging operation.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "ack", "nack", "send"
+ MessagingOperationNameKey = attribute.Key("messaging.operation.name")
+
+ // MessagingOperationTypeKey is the attribute Key conforming to the
+ // "messaging.operation.type" semantic conventions. It represents a string
+ // identifying the type of the messaging operation.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // Note: If a custom value is used, it MUST be of low cardinality.
+ MessagingOperationTypeKey = attribute.Key("messaging.operation.type")
+
+ // MessagingRabbitMQDestinationRoutingKeyKey is the attribute Key conforming to
+ // the "messaging.rabbitmq.destination.routing_key" semantic conventions. It
+ // represents the rabbitMQ message routing key.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: myKey
+ MessagingRabbitMQDestinationRoutingKeyKey = attribute.Key("messaging.rabbitmq.destination.routing_key")
+
+ // MessagingRabbitMQMessageDeliveryTagKey is the attribute Key conforming to the
+ // "messaging.rabbitmq.message.delivery_tag" semantic conventions. It represents
+ // the rabbitMQ message delivery tag.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ MessagingRabbitMQMessageDeliveryTagKey = attribute.Key("messaging.rabbitmq.message.delivery_tag")
+
+ // MessagingRocketMQConsumptionModelKey is the attribute Key conforming to the
+ // "messaging.rocketmq.consumption_model" semantic conventions. It represents
+ // the model of message consumption. This only applies to consumer spans.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ MessagingRocketMQConsumptionModelKey = attribute.Key("messaging.rocketmq.consumption_model")
+
+ // MessagingRocketMQMessageDelayTimeLevelKey is the attribute Key conforming to
+ // the "messaging.rocketmq.message.delay_time_level" semantic conventions. It
+ // represents the delay time level for delay message, which determines the
+ // message delay time.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ MessagingRocketMQMessageDelayTimeLevelKey = attribute.Key("messaging.rocketmq.message.delay_time_level")
+
+ // MessagingRocketMQMessageDeliveryTimestampKey is the attribute Key conforming
+ // to the "messaging.rocketmq.message.delivery_timestamp" semantic conventions.
+ // It represents the timestamp in milliseconds that the delay message is
+ // expected to be delivered to consumer.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ MessagingRocketMQMessageDeliveryTimestampKey = attribute.Key("messaging.rocketmq.message.delivery_timestamp")
+
+ // MessagingRocketMQMessageGroupKey is the attribute Key conforming to the
+ // "messaging.rocketmq.message.group" semantic conventions. It represents the it
+ // is essential for FIFO message. Messages that belong to the same message group
+ // are always processed one by one within the same consumer group.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: myMessageGroup
+ MessagingRocketMQMessageGroupKey = attribute.Key("messaging.rocketmq.message.group")
+
+ // MessagingRocketMQMessageKeysKey is the attribute Key conforming to the
+ // "messaging.rocketmq.message.keys" semantic conventions. It represents the
+ // key(s) of message, another way to mark message besides message id.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "keyA", "keyB"
+ MessagingRocketMQMessageKeysKey = attribute.Key("messaging.rocketmq.message.keys")
+
+ // MessagingRocketMQMessageTagKey is the attribute Key conforming to the
+ // "messaging.rocketmq.message.tag" semantic conventions. It represents the
+ // secondary classifier of message besides topic.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: tagA
+ MessagingRocketMQMessageTagKey = attribute.Key("messaging.rocketmq.message.tag")
+
+ // MessagingRocketMQMessageTypeKey is the attribute Key conforming to the
+ // "messaging.rocketmq.message.type" semantic conventions. It represents the
+ // type of message.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ MessagingRocketMQMessageTypeKey = attribute.Key("messaging.rocketmq.message.type")
+
+ // MessagingRocketMQNamespaceKey is the attribute Key conforming to the
+ // "messaging.rocketmq.namespace" semantic conventions. It represents the
+ // namespace of RocketMQ resources, resources in different namespaces are
+ // individual.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: myNamespace
+ MessagingRocketMQNamespaceKey = attribute.Key("messaging.rocketmq.namespace")
+
+ // MessagingServiceBusDispositionStatusKey is the attribute Key conforming to
+ // the "messaging.servicebus.disposition_status" semantic conventions. It
+ // represents the describes the [settlement type].
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ //
+ // [settlement type]: https://learn.microsoft.com/azure/service-bus-messaging/message-transfers-locks-settlement#peeklock
+ MessagingServiceBusDispositionStatusKey = attribute.Key("messaging.servicebus.disposition_status")
+
+ // MessagingServiceBusMessageDeliveryCountKey is the attribute Key conforming to
+ // the "messaging.servicebus.message.delivery_count" semantic conventions. It
+ // represents the number of deliveries that have been attempted for this
+ // message.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ MessagingServiceBusMessageDeliveryCountKey = attribute.Key("messaging.servicebus.message.delivery_count")
+
+ // MessagingServiceBusMessageEnqueuedTimeKey is the attribute Key conforming to
+ // the "messaging.servicebus.message.enqueued_time" semantic conventions. It
+ // represents the UTC epoch seconds at which the message has been accepted and
+ // stored in the entity.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ MessagingServiceBusMessageEnqueuedTimeKey = attribute.Key("messaging.servicebus.message.enqueued_time")
+
+ // MessagingSystemKey is the attribute Key conforming to the "messaging.system"
+ // semantic conventions. It represents the messaging system as identified by the
+ // client instrumentation.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // Note: The actual messaging system may differ from the one known by the
+ // client. For example, when using Kafka client libraries to communicate with
+ // Azure Event Hubs, the `messaging.system` is set to `kafka` based on the
+ // instrumentation's best knowledge.
+ MessagingSystemKey = attribute.Key("messaging.system")
+)
+
+// MessagingBatchMessageCount returns an attribute KeyValue conforming to the
+// "messaging.batch.message_count" semantic conventions. It represents the number
+// of messages sent, received, or processed in the scope of the batching
+// operation.
+func MessagingBatchMessageCount(val int) attribute.KeyValue {
+ return MessagingBatchMessageCountKey.Int(val)
+}
+
+// MessagingClientID returns an attribute KeyValue conforming to the
+// "messaging.client.id" semantic conventions. It represents a unique identifier
+// for the client that consumes or produces a message.
+func MessagingClientID(val string) attribute.KeyValue {
+ return MessagingClientIDKey.String(val)
+}
+
+// MessagingConsumerGroupName returns an attribute KeyValue conforming to the
+// "messaging.consumer.group.name" semantic conventions. It represents the name
+// of the consumer group with which a consumer is associated.
+func MessagingConsumerGroupName(val string) attribute.KeyValue {
+ return MessagingConsumerGroupNameKey.String(val)
+}
+
+// MessagingDestinationAnonymous returns an attribute KeyValue conforming to the
+// "messaging.destination.anonymous" semantic conventions. It represents a
+// boolean that is true if the message destination is anonymous (could be unnamed
+// or have auto-generated name).
+func MessagingDestinationAnonymous(val bool) attribute.KeyValue {
+ return MessagingDestinationAnonymousKey.Bool(val)
+}
+
+// MessagingDestinationName returns an attribute KeyValue conforming to the
+// "messaging.destination.name" semantic conventions. It represents the message
+// destination name.
+func MessagingDestinationName(val string) attribute.KeyValue {
+ return MessagingDestinationNameKey.String(val)
+}
+
+// MessagingDestinationPartitionID returns an attribute KeyValue conforming to
+// the "messaging.destination.partition.id" semantic conventions. It represents
+// the identifier of the partition messages are sent to or received from, unique
+// within the `messaging.destination.name`.
+func MessagingDestinationPartitionID(val string) attribute.KeyValue {
+ return MessagingDestinationPartitionIDKey.String(val)
+}
+
+// MessagingDestinationSubscriptionName returns an attribute KeyValue conforming
+// to the "messaging.destination.subscription.name" semantic conventions. It
+// represents the name of the destination subscription from which a message is
+// consumed.
+func MessagingDestinationSubscriptionName(val string) attribute.KeyValue {
+ return MessagingDestinationSubscriptionNameKey.String(val)
+}
+
+// MessagingDestinationTemplate returns an attribute KeyValue conforming to the
+// "messaging.destination.template" semantic conventions. It represents the low
+// cardinality representation of the messaging destination name.
+func MessagingDestinationTemplate(val string) attribute.KeyValue {
+ return MessagingDestinationTemplateKey.String(val)
+}
+
+// MessagingDestinationTemporary returns an attribute KeyValue conforming to the
+// "messaging.destination.temporary" semantic conventions. It represents a
+// boolean that is true if the message destination is temporary and might not
+// exist anymore after messages are processed.
+func MessagingDestinationTemporary(val bool) attribute.KeyValue {
+ return MessagingDestinationTemporaryKey.Bool(val)
+}
+
+// MessagingEventHubsMessageEnqueuedTime returns an attribute KeyValue conforming
+// to the "messaging.eventhubs.message.enqueued_time" semantic conventions. It
+// represents the UTC epoch seconds at which the message has been accepted and
+// stored in the entity.
+func MessagingEventHubsMessageEnqueuedTime(val int) attribute.KeyValue {
+ return MessagingEventHubsMessageEnqueuedTimeKey.Int(val)
+}
+
+// MessagingGCPPubSubMessageAckDeadline returns an attribute KeyValue conforming
+// to the "messaging.gcp_pubsub.message.ack_deadline" semantic conventions. It
+// represents the ack deadline in seconds set for the modify ack deadline
+// request.
+func MessagingGCPPubSubMessageAckDeadline(val int) attribute.KeyValue {
+ return MessagingGCPPubSubMessageAckDeadlineKey.Int(val)
+}
+
+// MessagingGCPPubSubMessageAckID returns an attribute KeyValue conforming to the
+// "messaging.gcp_pubsub.message.ack_id" semantic conventions. It represents the
+// ack id for a given message.
+func MessagingGCPPubSubMessageAckID(val string) attribute.KeyValue {
+ return MessagingGCPPubSubMessageAckIDKey.String(val)
+}
+
+// MessagingGCPPubSubMessageDeliveryAttempt returns an attribute KeyValue
+// conforming to the "messaging.gcp_pubsub.message.delivery_attempt" semantic
+// conventions. It represents the delivery attempt for a given message.
+func MessagingGCPPubSubMessageDeliveryAttempt(val int) attribute.KeyValue {
+ return MessagingGCPPubSubMessageDeliveryAttemptKey.Int(val)
+}
+
+// MessagingGCPPubSubMessageOrderingKey returns an attribute KeyValue conforming
+// to the "messaging.gcp_pubsub.message.ordering_key" semantic conventions. It
+// represents the ordering key for a given message. If the attribute is not
+// present, the message does not have an ordering key.
+func MessagingGCPPubSubMessageOrderingKey(val string) attribute.KeyValue {
+ return MessagingGCPPubSubMessageOrderingKeyKey.String(val)
+}
+
+// MessagingKafkaMessageKey returns an attribute KeyValue conforming to the
+// "messaging.kafka.message.key" semantic conventions. It represents the message
+// keys in Kafka are used for grouping alike messages to ensure they're processed
+// on the same partition. They differ from `messaging.message.id` in that they're
+// not unique. If the key is `null`, the attribute MUST NOT be set.
+func MessagingKafkaMessageKey(val string) attribute.KeyValue {
+ return MessagingKafkaMessageKeyKey.String(val)
+}
+
+// MessagingKafkaMessageTombstone returns an attribute KeyValue conforming to the
+// "messaging.kafka.message.tombstone" semantic conventions. It represents a
+// boolean that is true if the message is a tombstone.
+func MessagingKafkaMessageTombstone(val bool) attribute.KeyValue {
+ return MessagingKafkaMessageTombstoneKey.Bool(val)
+}
+
+// MessagingKafkaOffset returns an attribute KeyValue conforming to the
+// "messaging.kafka.offset" semantic conventions. It represents the offset of a
+// record in the corresponding Kafka partition.
+func MessagingKafkaOffset(val int) attribute.KeyValue {
+ return MessagingKafkaOffsetKey.Int(val)
+}
+
+// MessagingMessageBodySize returns an attribute KeyValue conforming to the
+// "messaging.message.body.size" semantic conventions. It represents the size of
+// the message body in bytes.
+func MessagingMessageBodySize(val int) attribute.KeyValue {
+ return MessagingMessageBodySizeKey.Int(val)
+}
+
+// MessagingMessageConversationID returns an attribute KeyValue conforming to the
+// "messaging.message.conversation_id" semantic conventions. It represents the
+// conversation ID identifying the conversation to which the message belongs,
+// represented as a string. Sometimes called "Correlation ID".
+func MessagingMessageConversationID(val string) attribute.KeyValue {
+ return MessagingMessageConversationIDKey.String(val)
+}
+
+// MessagingMessageEnvelopeSize returns an attribute KeyValue conforming to the
+// "messaging.message.envelope.size" semantic conventions. It represents the size
+// of the message body and metadata in bytes.
+func MessagingMessageEnvelopeSize(val int) attribute.KeyValue {
+ return MessagingMessageEnvelopeSizeKey.Int(val)
+}
+
+// MessagingMessageID returns an attribute KeyValue conforming to the
+// "messaging.message.id" semantic conventions. It represents a value used by the
+// messaging system as an identifier for the message, represented as a string.
+func MessagingMessageID(val string) attribute.KeyValue {
+ return MessagingMessageIDKey.String(val)
+}
+
+// MessagingOperationName returns an attribute KeyValue conforming to the
+// "messaging.operation.name" semantic conventions. It represents the
+// system-specific name of the messaging operation.
+func MessagingOperationName(val string) attribute.KeyValue {
+ return MessagingOperationNameKey.String(val)
+}
+
+// MessagingRabbitMQDestinationRoutingKey returns an attribute KeyValue
+// conforming to the "messaging.rabbitmq.destination.routing_key" semantic
+// conventions. It represents the rabbitMQ message routing key.
+func MessagingRabbitMQDestinationRoutingKey(val string) attribute.KeyValue {
+ return MessagingRabbitMQDestinationRoutingKeyKey.String(val)
+}
+
+// MessagingRabbitMQMessageDeliveryTag returns an attribute KeyValue conforming
+// to the "messaging.rabbitmq.message.delivery_tag" semantic conventions. It
+// represents the rabbitMQ message delivery tag.
+func MessagingRabbitMQMessageDeliveryTag(val int) attribute.KeyValue {
+ return MessagingRabbitMQMessageDeliveryTagKey.Int(val)
+}
+
+// MessagingRocketMQMessageDelayTimeLevel returns an attribute KeyValue
+// conforming to the "messaging.rocketmq.message.delay_time_level" semantic
+// conventions. It represents the delay time level for delay message, which
+// determines the message delay time.
+func MessagingRocketMQMessageDelayTimeLevel(val int) attribute.KeyValue {
+ return MessagingRocketMQMessageDelayTimeLevelKey.Int(val)
+}
+
+// MessagingRocketMQMessageDeliveryTimestamp returns an attribute KeyValue
+// conforming to the "messaging.rocketmq.message.delivery_timestamp" semantic
+// conventions. It represents the timestamp in milliseconds that the delay
+// message is expected to be delivered to consumer.
+func MessagingRocketMQMessageDeliveryTimestamp(val int) attribute.KeyValue {
+ return MessagingRocketMQMessageDeliveryTimestampKey.Int(val)
+}
+
+// MessagingRocketMQMessageGroup returns an attribute KeyValue conforming to the
+// "messaging.rocketmq.message.group" semantic conventions. It represents the it
+// is essential for FIFO message. Messages that belong to the same message group
+// are always processed one by one within the same consumer group.
+func MessagingRocketMQMessageGroup(val string) attribute.KeyValue {
+ return MessagingRocketMQMessageGroupKey.String(val)
+}
+
+// MessagingRocketMQMessageKeys returns an attribute KeyValue conforming to the
+// "messaging.rocketmq.message.keys" semantic conventions. It represents the
+// key(s) of message, another way to mark message besides message id.
+func MessagingRocketMQMessageKeys(val ...string) attribute.KeyValue {
+ return MessagingRocketMQMessageKeysKey.StringSlice(val)
+}
+
+// MessagingRocketMQMessageTag returns an attribute KeyValue conforming to the
+// "messaging.rocketmq.message.tag" semantic conventions. It represents the
+// secondary classifier of message besides topic.
+func MessagingRocketMQMessageTag(val string) attribute.KeyValue {
+ return MessagingRocketMQMessageTagKey.String(val)
+}
+
+// MessagingRocketMQNamespace returns an attribute KeyValue conforming to the
+// "messaging.rocketmq.namespace" semantic conventions. It represents the
+// namespace of RocketMQ resources, resources in different namespaces are
+// individual.
+func MessagingRocketMQNamespace(val string) attribute.KeyValue {
+ return MessagingRocketMQNamespaceKey.String(val)
+}
+
+// MessagingServiceBusMessageDeliveryCount returns an attribute KeyValue
+// conforming to the "messaging.servicebus.message.delivery_count" semantic
+// conventions. It represents the number of deliveries that have been attempted
+// for this message.
+func MessagingServiceBusMessageDeliveryCount(val int) attribute.KeyValue {
+ return MessagingServiceBusMessageDeliveryCountKey.Int(val)
+}
+
+// MessagingServiceBusMessageEnqueuedTime returns an attribute KeyValue
+// conforming to the "messaging.servicebus.message.enqueued_time" semantic
+// conventions. It represents the UTC epoch seconds at which the message has been
+// accepted and stored in the entity.
+func MessagingServiceBusMessageEnqueuedTime(val int) attribute.KeyValue {
+ return MessagingServiceBusMessageEnqueuedTimeKey.Int(val)
+}
+
+// Enum values for messaging.operation.type
+var (
+ // A message is created. "Create" spans always refer to a single message and are
+ // used to provide a unique creation context for messages in batch sending
+ // scenarios.
+ //
+ // Stability: development
+ MessagingOperationTypeCreate = MessagingOperationTypeKey.String("create")
+ // One or more messages are provided for sending to an intermediary. If a single
+ // message is sent, the context of the "Send" span can be used as the creation
+ // context and no "Create" span needs to be created.
+ //
+ // Stability: development
+ MessagingOperationTypeSend = MessagingOperationTypeKey.String("send")
+ // One or more messages are requested by a consumer. This operation refers to
+ // pull-based scenarios, where consumers explicitly call methods of messaging
+ // SDKs to receive messages.
+ //
+ // Stability: development
+ MessagingOperationTypeReceive = MessagingOperationTypeKey.String("receive")
+ // One or more messages are processed by a consumer.
+ //
+ // Stability: development
+ MessagingOperationTypeProcess = MessagingOperationTypeKey.String("process")
+ // One or more messages are settled.
+ //
+ // Stability: development
+ MessagingOperationTypeSettle = MessagingOperationTypeKey.String("settle")
+)
+
+// Enum values for messaging.rocketmq.consumption_model
+var (
+ // Clustering consumption model
+ // Stability: development
+ MessagingRocketMQConsumptionModelClustering = MessagingRocketMQConsumptionModelKey.String("clustering")
+ // Broadcasting consumption model
+ // Stability: development
+ MessagingRocketMQConsumptionModelBroadcasting = MessagingRocketMQConsumptionModelKey.String("broadcasting")
+)
+
+// Enum values for messaging.rocketmq.message.type
+var (
+ // Normal message
+ // Stability: development
+ MessagingRocketMQMessageTypeNormal = MessagingRocketMQMessageTypeKey.String("normal")
+ // FIFO message
+ // Stability: development
+ MessagingRocketMQMessageTypeFifo = MessagingRocketMQMessageTypeKey.String("fifo")
+ // Delay message
+ // Stability: development
+ MessagingRocketMQMessageTypeDelay = MessagingRocketMQMessageTypeKey.String("delay")
+ // Transaction message
+ // Stability: development
+ MessagingRocketMQMessageTypeTransaction = MessagingRocketMQMessageTypeKey.String("transaction")
+)
+
+// Enum values for messaging.servicebus.disposition_status
+var (
+ // Message is completed
+ // Stability: development
+ MessagingServiceBusDispositionStatusComplete = MessagingServiceBusDispositionStatusKey.String("complete")
+ // Message is abandoned
+ // Stability: development
+ MessagingServiceBusDispositionStatusAbandon = MessagingServiceBusDispositionStatusKey.String("abandon")
+ // Message is sent to dead letter queue
+ // Stability: development
+ MessagingServiceBusDispositionStatusDeadLetter = MessagingServiceBusDispositionStatusKey.String("dead_letter")
+ // Message is deferred
+ // Stability: development
+ MessagingServiceBusDispositionStatusDefer = MessagingServiceBusDispositionStatusKey.String("defer")
+)
+
+// Enum values for messaging.system
+var (
+ // Apache ActiveMQ
+ // Stability: development
+ MessagingSystemActiveMQ = MessagingSystemKey.String("activemq")
+ // Amazon Simple Notification Service (SNS)
+ // Stability: development
+ MessagingSystemAWSSNS = MessagingSystemKey.String("aws.sns")
+ // Amazon Simple Queue Service (SQS)
+ // Stability: development
+ MessagingSystemAWSSQS = MessagingSystemKey.String("aws_sqs")
+ // Azure Event Grid
+ // Stability: development
+ MessagingSystemEventGrid = MessagingSystemKey.String("eventgrid")
+ // Azure Event Hubs
+ // Stability: development
+ MessagingSystemEventHubs = MessagingSystemKey.String("eventhubs")
+ // Azure Service Bus
+ // Stability: development
+ MessagingSystemServiceBus = MessagingSystemKey.String("servicebus")
+ // Google Cloud Pub/Sub
+ // Stability: development
+ MessagingSystemGCPPubSub = MessagingSystemKey.String("gcp_pubsub")
+ // Java Message Service
+ // Stability: development
+ MessagingSystemJMS = MessagingSystemKey.String("jms")
+ // Apache Kafka
+ // Stability: development
+ MessagingSystemKafka = MessagingSystemKey.String("kafka")
+ // RabbitMQ
+ // Stability: development
+ MessagingSystemRabbitMQ = MessagingSystemKey.String("rabbitmq")
+ // Apache RocketMQ
+ // Stability: development
+ MessagingSystemRocketMQ = MessagingSystemKey.String("rocketmq")
+ // Apache Pulsar
+ // Stability: development
+ MessagingSystemPulsar = MessagingSystemKey.String("pulsar")
+)
+
+// Namespace: network
+const (
+ // NetworkCarrierICCKey is the attribute Key conforming to the
+ // "network.carrier.icc" semantic conventions. It represents the ISO 3166-1
+ // alpha-2 2-character country code associated with the mobile carrier network.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: DE
+ NetworkCarrierICCKey = attribute.Key("network.carrier.icc")
+
+ // NetworkCarrierMCCKey is the attribute Key conforming to the
+ // "network.carrier.mcc" semantic conventions. It represents the mobile carrier
+ // country code.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 310
+ NetworkCarrierMCCKey = attribute.Key("network.carrier.mcc")
+
+ // NetworkCarrierMNCKey is the attribute Key conforming to the
+ // "network.carrier.mnc" semantic conventions. It represents the mobile carrier
+ // network code.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 001
+ NetworkCarrierMNCKey = attribute.Key("network.carrier.mnc")
+
+ // NetworkCarrierNameKey is the attribute Key conforming to the
+ // "network.carrier.name" semantic conventions. It represents the name of the
+ // mobile carrier.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: sprint
+ NetworkCarrierNameKey = attribute.Key("network.carrier.name")
+
+ // NetworkConnectionStateKey is the attribute Key conforming to the
+ // "network.connection.state" semantic conventions. It represents the state of
+ // network connection.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "close_wait"
+ // Note: Connection states are defined as part of the [rfc9293]
+ //
+ // [rfc9293]: https://datatracker.ietf.org/doc/html/rfc9293#section-3.3.2
+ NetworkConnectionStateKey = attribute.Key("network.connection.state")
+
+ // NetworkConnectionSubtypeKey is the attribute Key conforming to the
+ // "network.connection.subtype" semantic conventions. It represents the this
+ // describes more details regarding the connection.type. It may be the type of
+ // cell technology connection, but it could be used for describing details about
+ // a wifi connection.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: LTE
+ NetworkConnectionSubtypeKey = attribute.Key("network.connection.subtype")
+
+ // NetworkConnectionTypeKey is the attribute Key conforming to the
+ // "network.connection.type" semantic conventions. It represents the internet
+ // connection type.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: wifi
+ NetworkConnectionTypeKey = attribute.Key("network.connection.type")
+
+ // NetworkInterfaceNameKey is the attribute Key conforming to the
+ // "network.interface.name" semantic conventions. It represents the network
+ // interface name.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "lo", "eth0"
+ NetworkInterfaceNameKey = attribute.Key("network.interface.name")
+
+ // NetworkIODirectionKey is the attribute Key conforming to the
+ // "network.io.direction" semantic conventions. It represents the network IO
+ // operation direction.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "transmit"
+ NetworkIODirectionKey = attribute.Key("network.io.direction")
+
+ // NetworkLocalAddressKey is the attribute Key conforming to the
+ // "network.local.address" semantic conventions. It represents the local address
+ // of the network connection - IP address or Unix domain socket name.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "10.1.2.80", "/tmp/my.sock"
+ NetworkLocalAddressKey = attribute.Key("network.local.address")
+
+ // NetworkLocalPortKey is the attribute Key conforming to the
+ // "network.local.port" semantic conventions. It represents the local port
+ // number of the network connection.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: 65123
+ NetworkLocalPortKey = attribute.Key("network.local.port")
+
+ // NetworkPeerAddressKey is the attribute Key conforming to the
+ // "network.peer.address" semantic conventions. It represents the peer address
+ // of the network connection - IP address or Unix domain socket name.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "10.1.2.80", "/tmp/my.sock"
+ NetworkPeerAddressKey = attribute.Key("network.peer.address")
+
+ // NetworkPeerPortKey is the attribute Key conforming to the "network.peer.port"
+ // semantic conventions. It represents the peer port number of the network
+ // connection.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: 65123
+ NetworkPeerPortKey = attribute.Key("network.peer.port")
+
+ // NetworkProtocolNameKey is the attribute Key conforming to the
+ // "network.protocol.name" semantic conventions. It represents the
+ // [OSI application layer] or non-OSI equivalent.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "amqp", "http", "mqtt"
+ // Note: The value SHOULD be normalized to lowercase.
+ //
+ // [OSI application layer]: https://wikipedia.org/wiki/Application_layer
+ NetworkProtocolNameKey = attribute.Key("network.protocol.name")
+
+ // NetworkProtocolVersionKey is the attribute Key conforming to the
+ // "network.protocol.version" semantic conventions. It represents the actual
+ // version of the protocol used for network communication.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "1.1", "2"
+ // Note: If protocol version is subject to negotiation (for example using [ALPN]
+ // ), this attribute SHOULD be set to the negotiated version. If the actual
+ // protocol version is not known, this attribute SHOULD NOT be set.
+ //
+ // [ALPN]: https://www.rfc-editor.org/rfc/rfc7301.html
+ NetworkProtocolVersionKey = attribute.Key("network.protocol.version")
+
+ // NetworkTransportKey is the attribute Key conforming to the
+ // "network.transport" semantic conventions. It represents the
+ // [OSI transport layer] or [inter-process communication method].
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "tcp", "udp"
+ // Note: The value SHOULD be normalized to lowercase.
+ //
+ // Consider always setting the transport when setting a port number, since
+ // a port number is ambiguous without knowing the transport. For example
+ // different processes could be listening on TCP port 12345 and UDP port 12345.
+ //
+ // [OSI transport layer]: https://wikipedia.org/wiki/Transport_layer
+ // [inter-process communication method]: https://wikipedia.org/wiki/Inter-process_communication
+ NetworkTransportKey = attribute.Key("network.transport")
+
+ // NetworkTypeKey is the attribute Key conforming to the "network.type" semantic
+ // conventions. It represents the [OSI network layer] or non-OSI equivalent.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "ipv4", "ipv6"
+ // Note: The value SHOULD be normalized to lowercase.
+ //
+ // [OSI network layer]: https://wikipedia.org/wiki/Network_layer
+ NetworkTypeKey = attribute.Key("network.type")
+)
+
+// NetworkCarrierICC returns an attribute KeyValue conforming to the
+// "network.carrier.icc" semantic conventions. It represents the ISO 3166-1
+// alpha-2 2-character country code associated with the mobile carrier network.
+func NetworkCarrierICC(val string) attribute.KeyValue {
+ return NetworkCarrierICCKey.String(val)
+}
+
+// NetworkCarrierMCC returns an attribute KeyValue conforming to the
+// "network.carrier.mcc" semantic conventions. It represents the mobile carrier
+// country code.
+func NetworkCarrierMCC(val string) attribute.KeyValue {
+ return NetworkCarrierMCCKey.String(val)
+}
+
+// NetworkCarrierMNC returns an attribute KeyValue conforming to the
+// "network.carrier.mnc" semantic conventions. It represents the mobile carrier
+// network code.
+func NetworkCarrierMNC(val string) attribute.KeyValue {
+ return NetworkCarrierMNCKey.String(val)
+}
+
+// NetworkCarrierName returns an attribute KeyValue conforming to the
+// "network.carrier.name" semantic conventions. It represents the name of the
+// mobile carrier.
+func NetworkCarrierName(val string) attribute.KeyValue {
+ return NetworkCarrierNameKey.String(val)
+}
+
+// NetworkInterfaceName returns an attribute KeyValue conforming to the
+// "network.interface.name" semantic conventions. It represents the network
+// interface name.
+func NetworkInterfaceName(val string) attribute.KeyValue {
+ return NetworkInterfaceNameKey.String(val)
+}
+
+// NetworkLocalAddress returns an attribute KeyValue conforming to the
+// "network.local.address" semantic conventions. It represents the local address
+// of the network connection - IP address or Unix domain socket name.
+func NetworkLocalAddress(val string) attribute.KeyValue {
+ return NetworkLocalAddressKey.String(val)
+}
+
+// NetworkLocalPort returns an attribute KeyValue conforming to the
+// "network.local.port" semantic conventions. It represents the local port number
+// of the network connection.
+func NetworkLocalPort(val int) attribute.KeyValue {
+ return NetworkLocalPortKey.Int(val)
+}
+
+// NetworkPeerAddress returns an attribute KeyValue conforming to the
+// "network.peer.address" semantic conventions. It represents the peer address of
+// the network connection - IP address or Unix domain socket name.
+func NetworkPeerAddress(val string) attribute.KeyValue {
+ return NetworkPeerAddressKey.String(val)
+}
+
+// NetworkPeerPort returns an attribute KeyValue conforming to the
+// "network.peer.port" semantic conventions. It represents the peer port number
+// of the network connection.
+func NetworkPeerPort(val int) attribute.KeyValue {
+ return NetworkPeerPortKey.Int(val)
+}
+
+// NetworkProtocolName returns an attribute KeyValue conforming to the
+// "network.protocol.name" semantic conventions. It represents the
+// [OSI application layer] or non-OSI equivalent.
+//
+// [OSI application layer]: https://wikipedia.org/wiki/Application_layer
+func NetworkProtocolName(val string) attribute.KeyValue {
+ return NetworkProtocolNameKey.String(val)
+}
+
+// NetworkProtocolVersion returns an attribute KeyValue conforming to the
+// "network.protocol.version" semantic conventions. It represents the actual
+// version of the protocol used for network communication.
+func NetworkProtocolVersion(val string) attribute.KeyValue {
+ return NetworkProtocolVersionKey.String(val)
+}
+
+// Enum values for network.connection.state
+var (
+ // closed
+ // Stability: development
+ NetworkConnectionStateClosed = NetworkConnectionStateKey.String("closed")
+ // close_wait
+ // Stability: development
+ NetworkConnectionStateCloseWait = NetworkConnectionStateKey.String("close_wait")
+ // closing
+ // Stability: development
+ NetworkConnectionStateClosing = NetworkConnectionStateKey.String("closing")
+ // established
+ // Stability: development
+ NetworkConnectionStateEstablished = NetworkConnectionStateKey.String("established")
+ // fin_wait_1
+ // Stability: development
+ NetworkConnectionStateFinWait1 = NetworkConnectionStateKey.String("fin_wait_1")
+ // fin_wait_2
+ // Stability: development
+ NetworkConnectionStateFinWait2 = NetworkConnectionStateKey.String("fin_wait_2")
+ // last_ack
+ // Stability: development
+ NetworkConnectionStateLastAck = NetworkConnectionStateKey.String("last_ack")
+ // listen
+ // Stability: development
+ NetworkConnectionStateListen = NetworkConnectionStateKey.String("listen")
+ // syn_received
+ // Stability: development
+ NetworkConnectionStateSynReceived = NetworkConnectionStateKey.String("syn_received")
+ // syn_sent
+ // Stability: development
+ NetworkConnectionStateSynSent = NetworkConnectionStateKey.String("syn_sent")
+ // time_wait
+ // Stability: development
+ NetworkConnectionStateTimeWait = NetworkConnectionStateKey.String("time_wait")
+)
+
+// Enum values for network.connection.subtype
+var (
+ // GPRS
+ // Stability: development
+ NetworkConnectionSubtypeGprs = NetworkConnectionSubtypeKey.String("gprs")
+ // EDGE
+ // Stability: development
+ NetworkConnectionSubtypeEdge = NetworkConnectionSubtypeKey.String("edge")
+ // UMTS
+ // Stability: development
+ NetworkConnectionSubtypeUmts = NetworkConnectionSubtypeKey.String("umts")
+ // CDMA
+ // Stability: development
+ NetworkConnectionSubtypeCdma = NetworkConnectionSubtypeKey.String("cdma")
+ // EVDO Rel. 0
+ // Stability: development
+ NetworkConnectionSubtypeEvdo0 = NetworkConnectionSubtypeKey.String("evdo_0")
+ // EVDO Rev. A
+ // Stability: development
+ NetworkConnectionSubtypeEvdoA = NetworkConnectionSubtypeKey.String("evdo_a")
+ // CDMA2000 1XRTT
+ // Stability: development
+ NetworkConnectionSubtypeCdma20001xrtt = NetworkConnectionSubtypeKey.String("cdma2000_1xrtt")
+ // HSDPA
+ // Stability: development
+ NetworkConnectionSubtypeHsdpa = NetworkConnectionSubtypeKey.String("hsdpa")
+ // HSUPA
+ // Stability: development
+ NetworkConnectionSubtypeHsupa = NetworkConnectionSubtypeKey.String("hsupa")
+ // HSPA
+ // Stability: development
+ NetworkConnectionSubtypeHspa = NetworkConnectionSubtypeKey.String("hspa")
+ // IDEN
+ // Stability: development
+ NetworkConnectionSubtypeIden = NetworkConnectionSubtypeKey.String("iden")
+ // EVDO Rev. B
+ // Stability: development
+ NetworkConnectionSubtypeEvdoB = NetworkConnectionSubtypeKey.String("evdo_b")
+ // LTE
+ // Stability: development
+ NetworkConnectionSubtypeLte = NetworkConnectionSubtypeKey.String("lte")
+ // EHRPD
+ // Stability: development
+ NetworkConnectionSubtypeEhrpd = NetworkConnectionSubtypeKey.String("ehrpd")
+ // HSPAP
+ // Stability: development
+ NetworkConnectionSubtypeHspap = NetworkConnectionSubtypeKey.String("hspap")
+ // GSM
+ // Stability: development
+ NetworkConnectionSubtypeGsm = NetworkConnectionSubtypeKey.String("gsm")
+ // TD-SCDMA
+ // Stability: development
+ NetworkConnectionSubtypeTdScdma = NetworkConnectionSubtypeKey.String("td_scdma")
+ // IWLAN
+ // Stability: development
+ NetworkConnectionSubtypeIwlan = NetworkConnectionSubtypeKey.String("iwlan")
+ // 5G NR (New Radio)
+ // Stability: development
+ NetworkConnectionSubtypeNr = NetworkConnectionSubtypeKey.String("nr")
+ // 5G NRNSA (New Radio Non-Standalone)
+ // Stability: development
+ NetworkConnectionSubtypeNrnsa = NetworkConnectionSubtypeKey.String("nrnsa")
+ // LTE CA
+ // Stability: development
+ NetworkConnectionSubtypeLteCa = NetworkConnectionSubtypeKey.String("lte_ca")
+)
+
+// Enum values for network.connection.type
+var (
+ // wifi
+ // Stability: development
+ NetworkConnectionTypeWifi = NetworkConnectionTypeKey.String("wifi")
+ // wired
+ // Stability: development
+ NetworkConnectionTypeWired = NetworkConnectionTypeKey.String("wired")
+ // cell
+ // Stability: development
+ NetworkConnectionTypeCell = NetworkConnectionTypeKey.String("cell")
+ // unavailable
+ // Stability: development
+ NetworkConnectionTypeUnavailable = NetworkConnectionTypeKey.String("unavailable")
+ // unknown
+ // Stability: development
+ NetworkConnectionTypeUnknown = NetworkConnectionTypeKey.String("unknown")
+)
+
+// Enum values for network.io.direction
+var (
+ // transmit
+ // Stability: development
+ NetworkIODirectionTransmit = NetworkIODirectionKey.String("transmit")
+ // receive
+ // Stability: development
+ NetworkIODirectionReceive = NetworkIODirectionKey.String("receive")
+)
+
+// Enum values for network.transport
+var (
+ // TCP
+ // Stability: stable
+ NetworkTransportTCP = NetworkTransportKey.String("tcp")
+ // UDP
+ // Stability: stable
+ NetworkTransportUDP = NetworkTransportKey.String("udp")
+ // Named or anonymous pipe.
+ // Stability: stable
+ NetworkTransportPipe = NetworkTransportKey.String("pipe")
+ // Unix domain socket
+ // Stability: stable
+ NetworkTransportUnix = NetworkTransportKey.String("unix")
+ // QUIC
+ // Stability: stable
+ NetworkTransportQUIC = NetworkTransportKey.String("quic")
+)
+
+// Enum values for network.type
+var (
+ // IPv4
+ // Stability: stable
+ NetworkTypeIPv4 = NetworkTypeKey.String("ipv4")
+ // IPv6
+ // Stability: stable
+ NetworkTypeIPv6 = NetworkTypeKey.String("ipv6")
+)
+
+// Namespace: oci
+const (
+ // OCIManifestDigestKey is the attribute Key conforming to the
+ // "oci.manifest.digest" semantic conventions. It represents the digest of the
+ // OCI image manifest. For container images specifically is the digest by which
+ // the container image is known.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // "sha256:e4ca62c0d62f3e886e684806dfe9d4e0cda60d54986898173c1083856cfda0f4"
+ // Note: Follows [OCI Image Manifest Specification], and specifically the
+ // [Digest property].
+ // An example can be found in [Example Image Manifest].
+ //
+ // [OCI Image Manifest Specification]: https://github.com/opencontainers/image-spec/blob/main/manifest.md
+ // [Digest property]: https://github.com/opencontainers/image-spec/blob/main/descriptor.md#digests
+ // [Example Image Manifest]: https://github.com/opencontainers/image-spec/blob/main/manifest.md#example-image-manifest
+ OCIManifestDigestKey = attribute.Key("oci.manifest.digest")
+)
+
+// OCIManifestDigest returns an attribute KeyValue conforming to the
+// "oci.manifest.digest" semantic conventions. It represents the digest of the
+// OCI image manifest. For container images specifically is the digest by which
+// the container image is known.
+func OCIManifestDigest(val string) attribute.KeyValue {
+ return OCIManifestDigestKey.String(val)
+}
+
+// Namespace: openai
+const (
+ // OpenAIRequestServiceTierKey is the attribute Key conforming to the
+ // "openai.request.service_tier" semantic conventions. It represents the service
+ // tier requested. May be a specific tier, default, or auto.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "auto", "default"
+ OpenAIRequestServiceTierKey = attribute.Key("openai.request.service_tier")
+
+ // OpenAIResponseServiceTierKey is the attribute Key conforming to the
+ // "openai.response.service_tier" semantic conventions. It represents the
+ // service tier used for the response.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "scale", "default"
+ OpenAIResponseServiceTierKey = attribute.Key("openai.response.service_tier")
+
+ // OpenAIResponseSystemFingerprintKey is the attribute Key conforming to the
+ // "openai.response.system_fingerprint" semantic conventions. It represents a
+ // fingerprint to track any eventual change in the Generative AI environment.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "fp_44709d6fcb"
+ OpenAIResponseSystemFingerprintKey = attribute.Key("openai.response.system_fingerprint")
+)
+
+// OpenAIResponseServiceTier returns an attribute KeyValue conforming to the
+// "openai.response.service_tier" semantic conventions. It represents the service
+// tier used for the response.
+func OpenAIResponseServiceTier(val string) attribute.KeyValue {
+ return OpenAIResponseServiceTierKey.String(val)
+}
+
+// OpenAIResponseSystemFingerprint returns an attribute KeyValue conforming to
+// the "openai.response.system_fingerprint" semantic conventions. It represents a
+// fingerprint to track any eventual change in the Generative AI environment.
+func OpenAIResponseSystemFingerprint(val string) attribute.KeyValue {
+ return OpenAIResponseSystemFingerprintKey.String(val)
+}
+
+// Enum values for openai.request.service_tier
+var (
+ // The system will utilize scale tier credits until they are exhausted.
+ // Stability: development
+ OpenAIRequestServiceTierAuto = OpenAIRequestServiceTierKey.String("auto")
+ // The system will utilize the default scale tier.
+ // Stability: development
+ OpenAIRequestServiceTierDefault = OpenAIRequestServiceTierKey.String("default")
+)
+
+// Namespace: opentracing
+const (
+ // OpenTracingRefTypeKey is the attribute Key conforming to the
+ // "opentracing.ref_type" semantic conventions. It represents the parent-child
+ // Reference type.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // Note: The causal relationship between a child Span and a parent Span.
+ OpenTracingRefTypeKey = attribute.Key("opentracing.ref_type")
+)
+
+// Enum values for opentracing.ref_type
+var (
+ // The parent Span depends on the child Span in some capacity
+ // Stability: development
+ OpenTracingRefTypeChildOf = OpenTracingRefTypeKey.String("child_of")
+ // The parent Span doesn't depend in any way on the result of the child Span
+ // Stability: development
+ OpenTracingRefTypeFollowsFrom = OpenTracingRefTypeKey.String("follows_from")
+)
+
+// Namespace: os
+const (
+ // OSBuildIDKey is the attribute Key conforming to the "os.build_id" semantic
+ // conventions. It represents the unique identifier for a particular build or
+ // compilation of the operating system.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "TQ3C.230805.001.B2", "20E247", "22621"
+ OSBuildIDKey = attribute.Key("os.build_id")
+
+ // OSDescriptionKey is the attribute Key conforming to the "os.description"
+ // semantic conventions. It represents the human readable (not intended to be
+ // parsed) OS version information, like e.g. reported by `ver` or
+ // `lsb_release -a` commands.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Microsoft Windows [Version 10.0.18363.778]", "Ubuntu 18.04.1 LTS"
+ OSDescriptionKey = attribute.Key("os.description")
+
+ // OSNameKey is the attribute Key conforming to the "os.name" semantic
+ // conventions. It represents the human readable operating system name.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "iOS", "Android", "Ubuntu"
+ OSNameKey = attribute.Key("os.name")
+
+ // OSTypeKey is the attribute Key conforming to the "os.type" semantic
+ // conventions. It represents the operating system type.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ OSTypeKey = attribute.Key("os.type")
+
+ // OSVersionKey is the attribute Key conforming to the "os.version" semantic
+ // conventions. It represents the version string of the operating system as
+ // defined in [Version Attributes].
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "14.2.1", "18.04.1"
+ //
+ // [Version Attributes]: /docs/resource/README.md#version-attributes
+ OSVersionKey = attribute.Key("os.version")
+)
+
+// OSBuildID returns an attribute KeyValue conforming to the "os.build_id"
+// semantic conventions. It represents the unique identifier for a particular
+// build or compilation of the operating system.
+func OSBuildID(val string) attribute.KeyValue {
+ return OSBuildIDKey.String(val)
+}
+
+// OSDescription returns an attribute KeyValue conforming to the "os.description"
+// semantic conventions. It represents the human readable (not intended to be
+// parsed) OS version information, like e.g. reported by `ver` or
+// `lsb_release -a` commands.
+func OSDescription(val string) attribute.KeyValue {
+ return OSDescriptionKey.String(val)
+}
+
+// OSName returns an attribute KeyValue conforming to the "os.name" semantic
+// conventions. It represents the human readable operating system name.
+func OSName(val string) attribute.KeyValue {
+ return OSNameKey.String(val)
+}
+
+// OSVersion returns an attribute KeyValue conforming to the "os.version"
+// semantic conventions. It represents the version string of the operating system
+// as defined in [Version Attributes].
+//
+// [Version Attributes]: /docs/resource/README.md#version-attributes
+func OSVersion(val string) attribute.KeyValue {
+ return OSVersionKey.String(val)
+}
+
+// Enum values for os.type
+var (
+ // Microsoft Windows
+ // Stability: development
+ OSTypeWindows = OSTypeKey.String("windows")
+ // Linux
+ // Stability: development
+ OSTypeLinux = OSTypeKey.String("linux")
+ // Apple Darwin
+ // Stability: development
+ OSTypeDarwin = OSTypeKey.String("darwin")
+ // FreeBSD
+ // Stability: development
+ OSTypeFreeBSD = OSTypeKey.String("freebsd")
+ // NetBSD
+ // Stability: development
+ OSTypeNetBSD = OSTypeKey.String("netbsd")
+ // OpenBSD
+ // Stability: development
+ OSTypeOpenBSD = OSTypeKey.String("openbsd")
+ // DragonFly BSD
+ // Stability: development
+ OSTypeDragonflyBSD = OSTypeKey.String("dragonflybsd")
+ // HP-UX (Hewlett Packard Unix)
+ // Stability: development
+ OSTypeHPUX = OSTypeKey.String("hpux")
+ // AIX (Advanced Interactive eXecutive)
+ // Stability: development
+ OSTypeAIX = OSTypeKey.String("aix")
+ // SunOS, Oracle Solaris
+ // Stability: development
+ OSTypeSolaris = OSTypeKey.String("solaris")
+ // IBM z/OS
+ // Stability: development
+ OSTypeZOS = OSTypeKey.String("zos")
+)
+
+// Namespace: otel
+const (
+ // OTelComponentNameKey is the attribute Key conforming to the
+ // "otel.component.name" semantic conventions. It represents a name uniquely
+ // identifying the instance of the OpenTelemetry component within its containing
+ // SDK instance.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "otlp_grpc_span_exporter/0", "custom-name"
+ // Note: Implementations SHOULD ensure a low cardinality for this attribute,
+ // even across application or SDK restarts.
+ // E.g. implementations MUST NOT use UUIDs as values for this attribute.
+ //
+ // Implementations MAY achieve these goals by following a
+ // `/` pattern, e.g.
+ // `batching_span_processor/0`.
+ // Hereby `otel.component.type` refers to the corresponding attribute value of
+ // the component.
+ //
+ // The value of `instance-counter` MAY be automatically assigned by the
+ // component and uniqueness within the enclosing SDK instance MUST be
+ // guaranteed.
+ // For example, `` MAY be implemented by using a monotonically
+ // increasing counter (starting with `0`), which is incremented every time an
+ // instance of the given component type is started.
+ //
+ // With this implementation, for example the first Batching Span Processor would
+ // have `batching_span_processor/0`
+ // as `otel.component.name`, the second one `batching_span_processor/1` and so
+ // on.
+ // These values will therefore be reused in the case of an application restart.
+ OTelComponentNameKey = attribute.Key("otel.component.name")
+
+ // OTelComponentTypeKey is the attribute Key conforming to the
+ // "otel.component.type" semantic conventions. It represents a name identifying
+ // the type of the OpenTelemetry component.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "batching_span_processor", "com.example.MySpanExporter"
+ // Note: If none of the standardized values apply, implementations SHOULD use
+ // the language-defined name of the type.
+ // E.g. for Java the fully qualified classname SHOULD be used in this case.
+ OTelComponentTypeKey = attribute.Key("otel.component.type")
+
+ // OTelScopeNameKey is the attribute Key conforming to the "otel.scope.name"
+ // semantic conventions. It represents the name of the instrumentation scope - (
+ // `InstrumentationScope.Name` in OTLP).
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "io.opentelemetry.contrib.mongodb"
+ OTelScopeNameKey = attribute.Key("otel.scope.name")
+
+ // OTelScopeSchemaURLKey is the attribute Key conforming to the
+ // "otel.scope.schema_url" semantic conventions. It represents the schema URL of
+ // the instrumentation scope.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "https://opentelemetry.io/schemas/1.31.0"
+ OTelScopeSchemaURLKey = attribute.Key("otel.scope.schema_url")
+
+ // OTelScopeVersionKey is the attribute Key conforming to the
+ // "otel.scope.version" semantic conventions. It represents the version of the
+ // instrumentation scope - (`InstrumentationScope.Version` in OTLP).
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "1.0.0"
+ OTelScopeVersionKey = attribute.Key("otel.scope.version")
+
+ // OTelSpanParentOriginKey is the attribute Key conforming to the
+ // "otel.span.parent.origin" semantic conventions. It represents the determines
+ // whether the span has a parent span, and if so,
+ // [whether it is a remote parent].
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ //
+ // [whether it is a remote parent]: https://opentelemetry.io/docs/specs/otel/trace/api/#isremote
+ OTelSpanParentOriginKey = attribute.Key("otel.span.parent.origin")
+
+ // OTelSpanSamplingResultKey is the attribute Key conforming to the
+ // "otel.span.sampling_result" semantic conventions. It represents the result
+ // value of the sampler for this span.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ OTelSpanSamplingResultKey = attribute.Key("otel.span.sampling_result")
+
+ // OTelStatusCodeKey is the attribute Key conforming to the "otel.status_code"
+ // semantic conventions. It represents the name of the code, either "OK" or
+ // "ERROR". MUST NOT be set if the status code is UNSET.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples:
+ OTelStatusCodeKey = attribute.Key("otel.status_code")
+
+ // OTelStatusDescriptionKey is the attribute Key conforming to the
+ // "otel.status_description" semantic conventions. It represents the description
+ // of the Status if it has a value, otherwise not set.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "resource not found"
+ OTelStatusDescriptionKey = attribute.Key("otel.status_description")
+)
+
+// OTelComponentName returns an attribute KeyValue conforming to the
+// "otel.component.name" semantic conventions. It represents a name uniquely
+// identifying the instance of the OpenTelemetry component within its containing
+// SDK instance.
+func OTelComponentName(val string) attribute.KeyValue {
+ return OTelComponentNameKey.String(val)
+}
+
+// OTelScopeName returns an attribute KeyValue conforming to the
+// "otel.scope.name" semantic conventions. It represents the name of the
+// instrumentation scope - (`InstrumentationScope.Name` in OTLP).
+func OTelScopeName(val string) attribute.KeyValue {
+ return OTelScopeNameKey.String(val)
+}
+
+// OTelScopeSchemaURL returns an attribute KeyValue conforming to the
+// "otel.scope.schema_url" semantic conventions. It represents the schema URL of
+// the instrumentation scope.
+func OTelScopeSchemaURL(val string) attribute.KeyValue {
+ return OTelScopeSchemaURLKey.String(val)
+}
+
+// OTelScopeVersion returns an attribute KeyValue conforming to the
+// "otel.scope.version" semantic conventions. It represents the version of the
+// instrumentation scope - (`InstrumentationScope.Version` in OTLP).
+func OTelScopeVersion(val string) attribute.KeyValue {
+ return OTelScopeVersionKey.String(val)
+}
+
+// OTelStatusDescription returns an attribute KeyValue conforming to the
+// "otel.status_description" semantic conventions. It represents the description
+// of the Status if it has a value, otherwise not set.
+func OTelStatusDescription(val string) attribute.KeyValue {
+ return OTelStatusDescriptionKey.String(val)
+}
+
+// Enum values for otel.component.type
+var (
+ // The builtin SDK batching span processor
+ //
+ // Stability: development
+ OTelComponentTypeBatchingSpanProcessor = OTelComponentTypeKey.String("batching_span_processor")
+ // The builtin SDK simple span processor
+ //
+ // Stability: development
+ OTelComponentTypeSimpleSpanProcessor = OTelComponentTypeKey.String("simple_span_processor")
+ // The builtin SDK batching log record processor
+ //
+ // Stability: development
+ OTelComponentTypeBatchingLogProcessor = OTelComponentTypeKey.String("batching_log_processor")
+ // The builtin SDK simple log record processor
+ //
+ // Stability: development
+ OTelComponentTypeSimpleLogProcessor = OTelComponentTypeKey.String("simple_log_processor")
+ // OTLP span exporter over gRPC with protobuf serialization
+ //
+ // Stability: development
+ OTelComponentTypeOtlpGRPCSpanExporter = OTelComponentTypeKey.String("otlp_grpc_span_exporter")
+ // OTLP span exporter over HTTP with protobuf serialization
+ //
+ // Stability: development
+ OTelComponentTypeOtlpHTTPSpanExporter = OTelComponentTypeKey.String("otlp_http_span_exporter")
+ // OTLP span exporter over HTTP with JSON serialization
+ //
+ // Stability: development
+ OTelComponentTypeOtlpHTTPJSONSpanExporter = OTelComponentTypeKey.String("otlp_http_json_span_exporter")
+ // Zipkin span exporter over HTTP
+ //
+ // Stability: development
+ OTelComponentTypeZipkinHTTPSpanExporter = OTelComponentTypeKey.String("zipkin_http_span_exporter")
+ // OTLP log record exporter over gRPC with protobuf serialization
+ //
+ // Stability: development
+ OTelComponentTypeOtlpGRPCLogExporter = OTelComponentTypeKey.String("otlp_grpc_log_exporter")
+ // OTLP log record exporter over HTTP with protobuf serialization
+ //
+ // Stability: development
+ OTelComponentTypeOtlpHTTPLogExporter = OTelComponentTypeKey.String("otlp_http_log_exporter")
+ // OTLP log record exporter over HTTP with JSON serialization
+ //
+ // Stability: development
+ OTelComponentTypeOtlpHTTPJSONLogExporter = OTelComponentTypeKey.String("otlp_http_json_log_exporter")
+ // The builtin SDK periodically exporting metric reader
+ //
+ // Stability: development
+ OTelComponentTypePeriodicMetricReader = OTelComponentTypeKey.String("periodic_metric_reader")
+ // OTLP metric exporter over gRPC with protobuf serialization
+ //
+ // Stability: development
+ OTelComponentTypeOtlpGRPCMetricExporter = OTelComponentTypeKey.String("otlp_grpc_metric_exporter")
+ // OTLP metric exporter over HTTP with protobuf serialization
+ //
+ // Stability: development
+ OTelComponentTypeOtlpHTTPMetricExporter = OTelComponentTypeKey.String("otlp_http_metric_exporter")
+ // OTLP metric exporter over HTTP with JSON serialization
+ //
+ // Stability: development
+ OTelComponentTypeOtlpHTTPJSONMetricExporter = OTelComponentTypeKey.String("otlp_http_json_metric_exporter")
+ // Prometheus metric exporter over HTTP with the default text-based format
+ //
+ // Stability: development
+ OTelComponentTypePrometheusHTTPTextMetricExporter = OTelComponentTypeKey.String("prometheus_http_text_metric_exporter")
+)
+
+// Enum values for otel.span.parent.origin
+var (
+ // The span does not have a parent, it is a root span
+ // Stability: development
+ OTelSpanParentOriginNone = OTelSpanParentOriginKey.String("none")
+ // The span has a parent and the parent's span context [isRemote()] is false
+ // Stability: development
+ //
+ // [isRemote()]: https://opentelemetry.io/docs/specs/otel/trace/api/#isremote
+ OTelSpanParentOriginLocal = OTelSpanParentOriginKey.String("local")
+ // The span has a parent and the parent's span context [isRemote()] is true
+ // Stability: development
+ //
+ // [isRemote()]: https://opentelemetry.io/docs/specs/otel/trace/api/#isremote
+ OTelSpanParentOriginRemote = OTelSpanParentOriginKey.String("remote")
+)
+
+// Enum values for otel.span.sampling_result
+var (
+ // The span is not sampled and not recording
+ // Stability: development
+ OTelSpanSamplingResultDrop = OTelSpanSamplingResultKey.String("DROP")
+ // The span is not sampled, but recording
+ // Stability: development
+ OTelSpanSamplingResultRecordOnly = OTelSpanSamplingResultKey.String("RECORD_ONLY")
+ // The span is sampled and recording
+ // Stability: development
+ OTelSpanSamplingResultRecordAndSample = OTelSpanSamplingResultKey.String("RECORD_AND_SAMPLE")
+)
+
+// Enum values for otel.status_code
+var (
+ // The operation has been validated by an Application developer or Operator to
+ // have completed successfully.
+ // Stability: stable
+ OTelStatusCodeOk = OTelStatusCodeKey.String("OK")
+ // The operation contains an error.
+ // Stability: stable
+ OTelStatusCodeError = OTelStatusCodeKey.String("ERROR")
+)
+
+// Namespace: peer
+const (
+ // PeerServiceKey is the attribute Key conforming to the "peer.service" semantic
+ // conventions. It represents the [`service.name`] of the remote service. SHOULD
+ // be equal to the actual `service.name` resource attribute of the remote
+ // service if any.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: AuthTokenCache
+ //
+ // [`service.name`]: /docs/resource/README.md#service
+ PeerServiceKey = attribute.Key("peer.service")
+)
+
+// PeerService returns an attribute KeyValue conforming to the "peer.service"
+// semantic conventions. It represents the [`service.name`] of the remote
+// service. SHOULD be equal to the actual `service.name` resource attribute of
+// the remote service if any.
+//
+// [`service.name`]: /docs/resource/README.md#service
+func PeerService(val string) attribute.KeyValue {
+ return PeerServiceKey.String(val)
+}
+
+// Namespace: process
+const (
+ // ProcessArgsCountKey is the attribute Key conforming to the
+ // "process.args_count" semantic conventions. It represents the length of the
+ // process.command_args array.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 4
+ // Note: This field can be useful for querying or performing bucket analysis on
+ // how many arguments were provided to start a process. More arguments may be an
+ // indication of suspicious activity.
+ ProcessArgsCountKey = attribute.Key("process.args_count")
+
+ // ProcessCommandKey is the attribute Key conforming to the "process.command"
+ // semantic conventions. It represents the command used to launch the process
+ // (i.e. the command name). On Linux based systems, can be set to the zeroth
+ // string in `proc/[pid]/cmdline`. On Windows, can be set to the first parameter
+ // extracted from `GetCommandLineW`.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "cmd/otelcol"
+ ProcessCommandKey = attribute.Key("process.command")
+
+ // ProcessCommandArgsKey is the attribute Key conforming to the
+ // "process.command_args" semantic conventions. It represents the all the
+ // command arguments (including the command/executable itself) as received by
+ // the process. On Linux-based systems (and some other Unixoid systems
+ // supporting procfs), can be set according to the list of null-delimited
+ // strings extracted from `proc/[pid]/cmdline`. For libc-based executables, this
+ // would be the full argv vector passed to `main`. SHOULD NOT be collected by
+ // default unless there is sanitization that excludes sensitive data.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "cmd/otecol", "--config=config.yaml"
+ ProcessCommandArgsKey = attribute.Key("process.command_args")
+
+ // ProcessCommandLineKey is the attribute Key conforming to the
+ // "process.command_line" semantic conventions. It represents the full command
+ // used to launch the process as a single string representing the full command.
+ // On Windows, can be set to the result of `GetCommandLineW`. Do not set this if
+ // you have to assemble it just for monitoring; use `process.command_args`
+ // instead. SHOULD NOT be collected by default unless there is sanitization that
+ // excludes sensitive data.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "C:\cmd\otecol --config="my directory\config.yaml""
+ ProcessCommandLineKey = attribute.Key("process.command_line")
+
+ // ProcessContextSwitchTypeKey is the attribute Key conforming to the
+ // "process.context_switch_type" semantic conventions. It represents the
+ // specifies whether the context switches for this data point were voluntary or
+ // involuntary.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ ProcessContextSwitchTypeKey = attribute.Key("process.context_switch_type")
+
+ // ProcessCreationTimeKey is the attribute Key conforming to the
+ // "process.creation.time" semantic conventions. It represents the date and time
+ // the process was created, in ISO 8601 format.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "2023-11-21T09:25:34.853Z"
+ ProcessCreationTimeKey = attribute.Key("process.creation.time")
+
+ // ProcessExecutableBuildIDGNUKey is the attribute Key conforming to the
+ // "process.executable.build_id.gnu" semantic conventions. It represents the GNU
+ // build ID as found in the `.note.gnu.build-id` ELF section (hex string).
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "c89b11207f6479603b0d49bf291c092c2b719293"
+ ProcessExecutableBuildIDGNUKey = attribute.Key("process.executable.build_id.gnu")
+
+ // ProcessExecutableBuildIDGoKey is the attribute Key conforming to the
+ // "process.executable.build_id.go" semantic conventions. It represents the Go
+ // build ID as retrieved by `go tool buildid `.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // "foh3mEXu7BLZjsN9pOwG/kATcXlYVCDEFouRMQed_/WwRFB1hPo9LBkekthSPG/x8hMC8emW2cCjXD0_1aY"
+ ProcessExecutableBuildIDGoKey = attribute.Key("process.executable.build_id.go")
+
+ // ProcessExecutableBuildIDHtlhashKey is the attribute Key conforming to the
+ // "process.executable.build_id.htlhash" semantic conventions. It represents the
+ // profiling specific build ID for executables. See the OTel specification for
+ // Profiles for more information.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "600DCAFE4A110000F2BF38C493F5FB92"
+ ProcessExecutableBuildIDHtlhashKey = attribute.Key("process.executable.build_id.htlhash")
+
+ // ProcessExecutableNameKey is the attribute Key conforming to the
+ // "process.executable.name" semantic conventions. It represents the name of the
+ // process executable. On Linux based systems, this SHOULD be set to the base
+ // name of the target of `/proc/[pid]/exe`. On Windows, this SHOULD be set to
+ // the base name of `GetProcessImageFileNameW`.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "otelcol"
+ ProcessExecutableNameKey = attribute.Key("process.executable.name")
+
+ // ProcessExecutablePathKey is the attribute Key conforming to the
+ // "process.executable.path" semantic conventions. It represents the full path
+ // to the process executable. On Linux based systems, can be set to the target
+ // of `proc/[pid]/exe`. On Windows, can be set to the result of
+ // `GetProcessImageFileNameW`.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "/usr/bin/cmd/otelcol"
+ ProcessExecutablePathKey = attribute.Key("process.executable.path")
+
+ // ProcessExitCodeKey is the attribute Key conforming to the "process.exit.code"
+ // semantic conventions. It represents the exit code of the process.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 127
+ ProcessExitCodeKey = attribute.Key("process.exit.code")
+
+ // ProcessExitTimeKey is the attribute Key conforming to the "process.exit.time"
+ // semantic conventions. It represents the date and time the process exited, in
+ // ISO 8601 format.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "2023-11-21T09:26:12.315Z"
+ ProcessExitTimeKey = attribute.Key("process.exit.time")
+
+ // ProcessGroupLeaderPIDKey is the attribute Key conforming to the
+ // "process.group_leader.pid" semantic conventions. It represents the PID of the
+ // process's group leader. This is also the process group ID (PGID) of the
+ // process.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 23
+ ProcessGroupLeaderPIDKey = attribute.Key("process.group_leader.pid")
+
+ // ProcessInteractiveKey is the attribute Key conforming to the
+ // "process.interactive" semantic conventions. It represents the whether the
+ // process is connected to an interactive shell.
+ //
+ // Type: boolean
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ ProcessInteractiveKey = attribute.Key("process.interactive")
+
+ // ProcessLinuxCgroupKey is the attribute Key conforming to the
+ // "process.linux.cgroup" semantic conventions. It represents the control group
+ // associated with the process.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "1:name=systemd:/user.slice/user-1000.slice/session-3.scope",
+ // "0::/user.slice/user-1000.slice/user@1000.service/tmux-spawn-0267755b-4639-4a27-90ed-f19f88e53748.scope"
+ // Note: Control groups (cgroups) are a kernel feature used to organize and
+ // manage process resources. This attribute provides the path(s) to the
+ // cgroup(s) associated with the process, which should match the contents of the
+ // [/proc/[PID]/cgroup] file.
+ //
+ // [/proc/[PID]/cgroup]: https://man7.org/linux/man-pages/man7/cgroups.7.html
+ ProcessLinuxCgroupKey = attribute.Key("process.linux.cgroup")
+
+ // ProcessOwnerKey is the attribute Key conforming to the "process.owner"
+ // semantic conventions. It represents the username of the user that owns the
+ // process.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "root"
+ ProcessOwnerKey = attribute.Key("process.owner")
+
+ // ProcessPagingFaultTypeKey is the attribute Key conforming to the
+ // "process.paging.fault_type" semantic conventions. It represents the type of
+ // page fault for this data point. Type `major` is for major/hard page faults,
+ // and `minor` is for minor/soft page faults.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ ProcessPagingFaultTypeKey = attribute.Key("process.paging.fault_type")
+
+ // ProcessParentPIDKey is the attribute Key conforming to the
+ // "process.parent_pid" semantic conventions. It represents the parent Process
+ // identifier (PPID).
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 111
+ ProcessParentPIDKey = attribute.Key("process.parent_pid")
+
+ // ProcessPIDKey is the attribute Key conforming to the "process.pid" semantic
+ // conventions. It represents the process identifier (PID).
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 1234
+ ProcessPIDKey = attribute.Key("process.pid")
+
+ // ProcessRealUserIDKey is the attribute Key conforming to the
+ // "process.real_user.id" semantic conventions. It represents the real user ID
+ // (RUID) of the process.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 1000
+ ProcessRealUserIDKey = attribute.Key("process.real_user.id")
+
+ // ProcessRealUserNameKey is the attribute Key conforming to the
+ // "process.real_user.name" semantic conventions. It represents the username of
+ // the real user of the process.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "operator"
+ ProcessRealUserNameKey = attribute.Key("process.real_user.name")
+
+ // ProcessRuntimeDescriptionKey is the attribute Key conforming to the
+ // "process.runtime.description" semantic conventions. It represents an
+ // additional description about the runtime of the process, for example a
+ // specific vendor customization of the runtime environment.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: Eclipse OpenJ9 Eclipse OpenJ9 VM openj9-0.21.0
+ ProcessRuntimeDescriptionKey = attribute.Key("process.runtime.description")
+
+ // ProcessRuntimeNameKey is the attribute Key conforming to the
+ // "process.runtime.name" semantic conventions. It represents the name of the
+ // runtime of this process.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "OpenJDK Runtime Environment"
+ ProcessRuntimeNameKey = attribute.Key("process.runtime.name")
+
+ // ProcessRuntimeVersionKey is the attribute Key conforming to the
+ // "process.runtime.version" semantic conventions. It represents the version of
+ // the runtime of this process, as returned by the runtime without modification.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 14.0.2
+ ProcessRuntimeVersionKey = attribute.Key("process.runtime.version")
+
+ // ProcessSavedUserIDKey is the attribute Key conforming to the
+ // "process.saved_user.id" semantic conventions. It represents the saved user ID
+ // (SUID) of the process.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 1002
+ ProcessSavedUserIDKey = attribute.Key("process.saved_user.id")
+
+ // ProcessSavedUserNameKey is the attribute Key conforming to the
+ // "process.saved_user.name" semantic conventions. It represents the username of
+ // the saved user.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "operator"
+ ProcessSavedUserNameKey = attribute.Key("process.saved_user.name")
+
+ // ProcessSessionLeaderPIDKey is the attribute Key conforming to the
+ // "process.session_leader.pid" semantic conventions. It represents the PID of
+ // the process's session leader. This is also the session ID (SID) of the
+ // process.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 14
+ ProcessSessionLeaderPIDKey = attribute.Key("process.session_leader.pid")
+
+ // ProcessTitleKey is the attribute Key conforming to the "process.title"
+ // semantic conventions. It represents the process title (proctitle).
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "cat /etc/hostname", "xfce4-session", "bash"
+ // Note: In many Unix-like systems, process title (proctitle), is the string
+ // that represents the name or command line of a running process, displayed by
+ // system monitoring tools like ps, top, and htop.
+ ProcessTitleKey = attribute.Key("process.title")
+
+ // ProcessUserIDKey is the attribute Key conforming to the "process.user.id"
+ // semantic conventions. It represents the effective user ID (EUID) of the
+ // process.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 1001
+ ProcessUserIDKey = attribute.Key("process.user.id")
+
+ // ProcessUserNameKey is the attribute Key conforming to the "process.user.name"
+ // semantic conventions. It represents the username of the effective user of the
+ // process.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "root"
+ ProcessUserNameKey = attribute.Key("process.user.name")
+
+ // ProcessVpidKey is the attribute Key conforming to the "process.vpid" semantic
+ // conventions. It represents the virtual process identifier.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 12
+ // Note: The process ID within a PID namespace. This is not necessarily unique
+ // across all processes on the host but it is unique within the process
+ // namespace that the process exists within.
+ ProcessVpidKey = attribute.Key("process.vpid")
+
+ // ProcessWorkingDirectoryKey is the attribute Key conforming to the
+ // "process.working_directory" semantic conventions. It represents the working
+ // directory of the process.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "/root"
+ ProcessWorkingDirectoryKey = attribute.Key("process.working_directory")
+)
+
+// ProcessArgsCount returns an attribute KeyValue conforming to the
+// "process.args_count" semantic conventions. It represents the length of the
+// process.command_args array.
+func ProcessArgsCount(val int) attribute.KeyValue {
+ return ProcessArgsCountKey.Int(val)
+}
+
+// ProcessCommand returns an attribute KeyValue conforming to the
+// "process.command" semantic conventions. It represents the command used to
+// launch the process (i.e. the command name). On Linux based systems, can be set
+// to the zeroth string in `proc/[pid]/cmdline`. On Windows, can be set to the
+// first parameter extracted from `GetCommandLineW`.
+func ProcessCommand(val string) attribute.KeyValue {
+ return ProcessCommandKey.String(val)
+}
+
+// ProcessCommandArgs returns an attribute KeyValue conforming to the
+// "process.command_args" semantic conventions. It represents the all the command
+// arguments (including the command/executable itself) as received by the
+// process. On Linux-based systems (and some other Unixoid systems supporting
+// procfs), can be set according to the list of null-delimited strings extracted
+// from `proc/[pid]/cmdline`. For libc-based executables, this would be the full
+// argv vector passed to `main`. SHOULD NOT be collected by default unless there
+// is sanitization that excludes sensitive data.
+func ProcessCommandArgs(val ...string) attribute.KeyValue {
+ return ProcessCommandArgsKey.StringSlice(val)
+}
+
+// ProcessCommandLine returns an attribute KeyValue conforming to the
+// "process.command_line" semantic conventions. It represents the full command
+// used to launch the process as a single string representing the full command.
+// On Windows, can be set to the result of `GetCommandLineW`. Do not set this if
+// you have to assemble it just for monitoring; use `process.command_args`
+// instead. SHOULD NOT be collected by default unless there is sanitization that
+// excludes sensitive data.
+func ProcessCommandLine(val string) attribute.KeyValue {
+ return ProcessCommandLineKey.String(val)
+}
+
+// ProcessCreationTime returns an attribute KeyValue conforming to the
+// "process.creation.time" semantic conventions. It represents the date and time
+// the process was created, in ISO 8601 format.
+func ProcessCreationTime(val string) attribute.KeyValue {
+ return ProcessCreationTimeKey.String(val)
+}
+
+// ProcessEnvironmentVariable returns an attribute KeyValue conforming to the
+// "process.environment_variable" semantic conventions. It represents the process
+// environment variables, `` being the environment variable name, the value
+// being the environment variable value.
+func ProcessEnvironmentVariable(key string, val string) attribute.KeyValue {
+ return attribute.String("process.environment_variable."+key, val)
+}
+
+// ProcessExecutableBuildIDGNU returns an attribute KeyValue conforming to the
+// "process.executable.build_id.gnu" semantic conventions. It represents the GNU
+// build ID as found in the `.note.gnu.build-id` ELF section (hex string).
+func ProcessExecutableBuildIDGNU(val string) attribute.KeyValue {
+ return ProcessExecutableBuildIDGNUKey.String(val)
+}
+
+// ProcessExecutableBuildIDGo returns an attribute KeyValue conforming to the
+// "process.executable.build_id.go" semantic conventions. It represents the Go
+// build ID as retrieved by `go tool buildid `.
+func ProcessExecutableBuildIDGo(val string) attribute.KeyValue {
+ return ProcessExecutableBuildIDGoKey.String(val)
+}
+
+// ProcessExecutableBuildIDHtlhash returns an attribute KeyValue conforming to
+// the "process.executable.build_id.htlhash" semantic conventions. It represents
+// the profiling specific build ID for executables. See the OTel specification
+// for Profiles for more information.
+func ProcessExecutableBuildIDHtlhash(val string) attribute.KeyValue {
+ return ProcessExecutableBuildIDHtlhashKey.String(val)
+}
+
+// ProcessExecutableName returns an attribute KeyValue conforming to the
+// "process.executable.name" semantic conventions. It represents the name of the
+// process executable. On Linux based systems, this SHOULD be set to the base
+// name of the target of `/proc/[pid]/exe`. On Windows, this SHOULD be set to the
+// base name of `GetProcessImageFileNameW`.
+func ProcessExecutableName(val string) attribute.KeyValue {
+ return ProcessExecutableNameKey.String(val)
+}
+
+// ProcessExecutablePath returns an attribute KeyValue conforming to the
+// "process.executable.path" semantic conventions. It represents the full path to
+// the process executable. On Linux based systems, can be set to the target of
+// `proc/[pid]/exe`. On Windows, can be set to the result of
+// `GetProcessImageFileNameW`.
+func ProcessExecutablePath(val string) attribute.KeyValue {
+ return ProcessExecutablePathKey.String(val)
+}
+
+// ProcessExitCode returns an attribute KeyValue conforming to the
+// "process.exit.code" semantic conventions. It represents the exit code of the
+// process.
+func ProcessExitCode(val int) attribute.KeyValue {
+ return ProcessExitCodeKey.Int(val)
+}
+
+// ProcessExitTime returns an attribute KeyValue conforming to the
+// "process.exit.time" semantic conventions. It represents the date and time the
+// process exited, in ISO 8601 format.
+func ProcessExitTime(val string) attribute.KeyValue {
+ return ProcessExitTimeKey.String(val)
+}
+
+// ProcessGroupLeaderPID returns an attribute KeyValue conforming to the
+// "process.group_leader.pid" semantic conventions. It represents the PID of the
+// process's group leader. This is also the process group ID (PGID) of the
+// process.
+func ProcessGroupLeaderPID(val int) attribute.KeyValue {
+ return ProcessGroupLeaderPIDKey.Int(val)
+}
+
+// ProcessInteractive returns an attribute KeyValue conforming to the
+// "process.interactive" semantic conventions. It represents the whether the
+// process is connected to an interactive shell.
+func ProcessInteractive(val bool) attribute.KeyValue {
+ return ProcessInteractiveKey.Bool(val)
+}
+
+// ProcessLinuxCgroup returns an attribute KeyValue conforming to the
+// "process.linux.cgroup" semantic conventions. It represents the control group
+// associated with the process.
+func ProcessLinuxCgroup(val string) attribute.KeyValue {
+ return ProcessLinuxCgroupKey.String(val)
+}
+
+// ProcessOwner returns an attribute KeyValue conforming to the "process.owner"
+// semantic conventions. It represents the username of the user that owns the
+// process.
+func ProcessOwner(val string) attribute.KeyValue {
+ return ProcessOwnerKey.String(val)
+}
+
+// ProcessParentPID returns an attribute KeyValue conforming to the
+// "process.parent_pid" semantic conventions. It represents the parent Process
+// identifier (PPID).
+func ProcessParentPID(val int) attribute.KeyValue {
+ return ProcessParentPIDKey.Int(val)
+}
+
+// ProcessPID returns an attribute KeyValue conforming to the "process.pid"
+// semantic conventions. It represents the process identifier (PID).
+func ProcessPID(val int) attribute.KeyValue {
+ return ProcessPIDKey.Int(val)
+}
+
+// ProcessRealUserID returns an attribute KeyValue conforming to the
+// "process.real_user.id" semantic conventions. It represents the real user ID
+// (RUID) of the process.
+func ProcessRealUserID(val int) attribute.KeyValue {
+ return ProcessRealUserIDKey.Int(val)
+}
+
+// ProcessRealUserName returns an attribute KeyValue conforming to the
+// "process.real_user.name" semantic conventions. It represents the username of
+// the real user of the process.
+func ProcessRealUserName(val string) attribute.KeyValue {
+ return ProcessRealUserNameKey.String(val)
+}
+
+// ProcessRuntimeDescription returns an attribute KeyValue conforming to the
+// "process.runtime.description" semantic conventions. It represents an
+// additional description about the runtime of the process, for example a
+// specific vendor customization of the runtime environment.
+func ProcessRuntimeDescription(val string) attribute.KeyValue {
+ return ProcessRuntimeDescriptionKey.String(val)
+}
+
+// ProcessRuntimeName returns an attribute KeyValue conforming to the
+// "process.runtime.name" semantic conventions. It represents the name of the
+// runtime of this process.
+func ProcessRuntimeName(val string) attribute.KeyValue {
+ return ProcessRuntimeNameKey.String(val)
+}
+
+// ProcessRuntimeVersion returns an attribute KeyValue conforming to the
+// "process.runtime.version" semantic conventions. It represents the version of
+// the runtime of this process, as returned by the runtime without modification.
+func ProcessRuntimeVersion(val string) attribute.KeyValue {
+ return ProcessRuntimeVersionKey.String(val)
+}
+
+// ProcessSavedUserID returns an attribute KeyValue conforming to the
+// "process.saved_user.id" semantic conventions. It represents the saved user ID
+// (SUID) of the process.
+func ProcessSavedUserID(val int) attribute.KeyValue {
+ return ProcessSavedUserIDKey.Int(val)
+}
+
+// ProcessSavedUserName returns an attribute KeyValue conforming to the
+// "process.saved_user.name" semantic conventions. It represents the username of
+// the saved user.
+func ProcessSavedUserName(val string) attribute.KeyValue {
+ return ProcessSavedUserNameKey.String(val)
+}
+
+// ProcessSessionLeaderPID returns an attribute KeyValue conforming to the
+// "process.session_leader.pid" semantic conventions. It represents the PID of
+// the process's session leader. This is also the session ID (SID) of the
+// process.
+func ProcessSessionLeaderPID(val int) attribute.KeyValue {
+ return ProcessSessionLeaderPIDKey.Int(val)
+}
+
+// ProcessTitle returns an attribute KeyValue conforming to the "process.title"
+// semantic conventions. It represents the process title (proctitle).
+func ProcessTitle(val string) attribute.KeyValue {
+ return ProcessTitleKey.String(val)
+}
+
+// ProcessUserID returns an attribute KeyValue conforming to the
+// "process.user.id" semantic conventions. It represents the effective user ID
+// (EUID) of the process.
+func ProcessUserID(val int) attribute.KeyValue {
+ return ProcessUserIDKey.Int(val)
+}
+
+// ProcessUserName returns an attribute KeyValue conforming to the
+// "process.user.name" semantic conventions. It represents the username of the
+// effective user of the process.
+func ProcessUserName(val string) attribute.KeyValue {
+ return ProcessUserNameKey.String(val)
+}
+
+// ProcessVpid returns an attribute KeyValue conforming to the "process.vpid"
+// semantic conventions. It represents the virtual process identifier.
+func ProcessVpid(val int) attribute.KeyValue {
+ return ProcessVpidKey.Int(val)
+}
+
+// ProcessWorkingDirectory returns an attribute KeyValue conforming to the
+// "process.working_directory" semantic conventions. It represents the working
+// directory of the process.
+func ProcessWorkingDirectory(val string) attribute.KeyValue {
+ return ProcessWorkingDirectoryKey.String(val)
+}
+
+// Enum values for process.context_switch_type
+var (
+ // voluntary
+ // Stability: development
+ ProcessContextSwitchTypeVoluntary = ProcessContextSwitchTypeKey.String("voluntary")
+ // involuntary
+ // Stability: development
+ ProcessContextSwitchTypeInvoluntary = ProcessContextSwitchTypeKey.String("involuntary")
+)
+
+// Enum values for process.paging.fault_type
+var (
+ // major
+ // Stability: development
+ ProcessPagingFaultTypeMajor = ProcessPagingFaultTypeKey.String("major")
+ // minor
+ // Stability: development
+ ProcessPagingFaultTypeMinor = ProcessPagingFaultTypeKey.String("minor")
+)
+
+// Namespace: profile
+const (
+ // ProfileFrameTypeKey is the attribute Key conforming to the
+ // "profile.frame.type" semantic conventions. It represents the describes the
+ // interpreter or compiler of a single frame.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "cpython"
+ ProfileFrameTypeKey = attribute.Key("profile.frame.type")
+)
+
+// Enum values for profile.frame.type
+var (
+ // [.NET]
+ //
+ // Stability: development
+ //
+ // [.NET]: https://wikipedia.org/wiki/.NET
+ ProfileFrameTypeDotnet = ProfileFrameTypeKey.String("dotnet")
+ // [JVM]
+ //
+ // Stability: development
+ //
+ // [JVM]: https://wikipedia.org/wiki/Java_virtual_machine
+ ProfileFrameTypeJVM = ProfileFrameTypeKey.String("jvm")
+ // [Kernel]
+ //
+ // Stability: development
+ //
+ // [Kernel]: https://wikipedia.org/wiki/Kernel_(operating_system)
+ ProfileFrameTypeKernel = ProfileFrameTypeKey.String("kernel")
+ // Can be one of but not limited to [C], [C++], [Go] or [Rust]. If possible, a
+ // more precise value MUST be used.
+ //
+ // Stability: development
+ //
+ // [C]: https://wikipedia.org/wiki/C_(programming_language)
+ // [C++]: https://wikipedia.org/wiki/C%2B%2B
+ // [Go]: https://wikipedia.org/wiki/Go_(programming_language)
+ // [Rust]: https://wikipedia.org/wiki/Rust_(programming_language)
+ ProfileFrameTypeNative = ProfileFrameTypeKey.String("native")
+ // [Perl]
+ //
+ // Stability: development
+ //
+ // [Perl]: https://wikipedia.org/wiki/Perl
+ ProfileFrameTypePerl = ProfileFrameTypeKey.String("perl")
+ // [PHP]
+ //
+ // Stability: development
+ //
+ // [PHP]: https://wikipedia.org/wiki/PHP
+ ProfileFrameTypePHP = ProfileFrameTypeKey.String("php")
+ // [Python]
+ //
+ // Stability: development
+ //
+ // [Python]: https://wikipedia.org/wiki/Python_(programming_language)
+ ProfileFrameTypeCpython = ProfileFrameTypeKey.String("cpython")
+ // [Ruby]
+ //
+ // Stability: development
+ //
+ // [Ruby]: https://wikipedia.org/wiki/Ruby_(programming_language)
+ ProfileFrameTypeRuby = ProfileFrameTypeKey.String("ruby")
+ // [V8JS]
+ //
+ // Stability: development
+ //
+ // [V8JS]: https://wikipedia.org/wiki/V8_(JavaScript_engine)
+ ProfileFrameTypeV8JS = ProfileFrameTypeKey.String("v8js")
+ // [Erlang]
+ //
+ // Stability: development
+ //
+ // [Erlang]: https://en.wikipedia.org/wiki/BEAM_(Erlang_virtual_machine)
+ ProfileFrameTypeBeam = ProfileFrameTypeKey.String("beam")
+ // [Go],
+ //
+ // Stability: development
+ //
+ // [Go]: https://wikipedia.org/wiki/Go_(programming_language)
+ ProfileFrameTypeGo = ProfileFrameTypeKey.String("go")
+ // [Rust]
+ //
+ // Stability: development
+ //
+ // [Rust]: https://wikipedia.org/wiki/Rust_(programming_language)
+ ProfileFrameTypeRust = ProfileFrameTypeKey.String("rust")
+)
+
+// Namespace: rpc
+const (
+ // RPCConnectRPCErrorCodeKey is the attribute Key conforming to the
+ // "rpc.connect_rpc.error_code" semantic conventions. It represents the
+ // [error codes] of the Connect request. Error codes are always string values.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ //
+ // [error codes]: https://connectrpc.com//docs/protocol/#error-codes
+ RPCConnectRPCErrorCodeKey = attribute.Key("rpc.connect_rpc.error_code")
+
+ // RPCGRPCStatusCodeKey is the attribute Key conforming to the
+ // "rpc.grpc.status_code" semantic conventions. It represents the
+ // [numeric status code] of the gRPC request.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ //
+ // [numeric status code]: https://github.com/grpc/grpc/blob/v1.33.2/doc/statuscodes.md
+ RPCGRPCStatusCodeKey = attribute.Key("rpc.grpc.status_code")
+
+ // RPCJSONRPCErrorCodeKey is the attribute Key conforming to the
+ // "rpc.jsonrpc.error_code" semantic conventions. It represents the `error.code`
+ // property of response if it is an error response.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: -32700, 100
+ RPCJSONRPCErrorCodeKey = attribute.Key("rpc.jsonrpc.error_code")
+
+ // RPCJSONRPCErrorMessageKey is the attribute Key conforming to the
+ // "rpc.jsonrpc.error_message" semantic conventions. It represents the
+ // `error.message` property of response if it is an error response.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Parse error", "User already exists"
+ RPCJSONRPCErrorMessageKey = attribute.Key("rpc.jsonrpc.error_message")
+
+ // RPCJSONRPCRequestIDKey is the attribute Key conforming to the
+ // "rpc.jsonrpc.request_id" semantic conventions. It represents the `id`
+ // property of request or response. Since protocol allows id to be int, string,
+ // `null` or missing (for notifications), value is expected to be cast to string
+ // for simplicity. Use empty string in case of `null` value. Omit entirely if
+ // this is a notification.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "10", "request-7", ""
+ RPCJSONRPCRequestIDKey = attribute.Key("rpc.jsonrpc.request_id")
+
+ // RPCJSONRPCVersionKey is the attribute Key conforming to the
+ // "rpc.jsonrpc.version" semantic conventions. It represents the protocol
+ // version as in `jsonrpc` property of request/response. Since JSON-RPC 1.0
+ // doesn't specify this, the value can be omitted.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "2.0", "1.0"
+ RPCJSONRPCVersionKey = attribute.Key("rpc.jsonrpc.version")
+
+ // RPCMessageCompressedSizeKey is the attribute Key conforming to the
+ // "rpc.message.compressed_size" semantic conventions. It represents the
+ // compressed size of the message in bytes.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ RPCMessageCompressedSizeKey = attribute.Key("rpc.message.compressed_size")
+
+ // RPCMessageIDKey is the attribute Key conforming to the "rpc.message.id"
+ // semantic conventions. It MUST be calculated as two different counters
+ // starting from `1` one for sent messages and one for received message..
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // Note: This way we guarantee that the values will be consistent between
+ // different implementations.
+ RPCMessageIDKey = attribute.Key("rpc.message.id")
+
+ // RPCMessageTypeKey is the attribute Key conforming to the "rpc.message.type"
+ // semantic conventions. It represents the whether this is a received or sent
+ // message.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ RPCMessageTypeKey = attribute.Key("rpc.message.type")
+
+ // RPCMessageUncompressedSizeKey is the attribute Key conforming to the
+ // "rpc.message.uncompressed_size" semantic conventions. It represents the
+ // uncompressed size of the message in bytes.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ RPCMessageUncompressedSizeKey = attribute.Key("rpc.message.uncompressed_size")
+
+ // RPCMethodKey is the attribute Key conforming to the "rpc.method" semantic
+ // conventions. It represents the name of the (logical) method being called,
+ // must be equal to the $method part in the span name.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: exampleMethod
+ // Note: This is the logical name of the method from the RPC interface
+ // perspective, which can be different from the name of any implementing
+ // method/function. The `code.function.name` attribute may be used to store the
+ // latter (e.g., method actually executing the call on the server side, RPC
+ // client stub method on the client side).
+ RPCMethodKey = attribute.Key("rpc.method")
+
+ // RPCServiceKey is the attribute Key conforming to the "rpc.service" semantic
+ // conventions. It represents the full (logical) name of the service being
+ // called, including its package name, if applicable.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: myservice.EchoService
+ // Note: This is the logical name of the service from the RPC interface
+ // perspective, which can be different from the name of any implementing class.
+ // The `code.namespace` attribute may be used to store the latter (despite the
+ // attribute name, it may include a class name; e.g., class with method actually
+ // executing the call on the server side, RPC client stub class on the client
+ // side).
+ RPCServiceKey = attribute.Key("rpc.service")
+
+ // RPCSystemKey is the attribute Key conforming to the "rpc.system" semantic
+ // conventions. It represents a string identifying the remoting system. See
+ // below for a list of well-known identifiers.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ RPCSystemKey = attribute.Key("rpc.system")
+)
+
+// RPCConnectRPCRequestMetadata returns an attribute KeyValue conforming to the
+// "rpc.connect_rpc.request.metadata" semantic conventions. It represents the
+// connect request metadata, `` being the normalized Connect Metadata key
+// (lowercase), the value being the metadata values.
+func RPCConnectRPCRequestMetadata(key string, val ...string) attribute.KeyValue {
+ return attribute.StringSlice("rpc.connect_rpc.request.metadata."+key, val)
+}
+
+// RPCConnectRPCResponseMetadata returns an attribute KeyValue conforming to the
+// "rpc.connect_rpc.response.metadata" semantic conventions. It represents the
+// connect response metadata, `` being the normalized Connect Metadata key
+// (lowercase), the value being the metadata values.
+func RPCConnectRPCResponseMetadata(key string, val ...string) attribute.KeyValue {
+ return attribute.StringSlice("rpc.connect_rpc.response.metadata."+key, val)
+}
+
+// RPCGRPCRequestMetadata returns an attribute KeyValue conforming to the
+// "rpc.grpc.request.metadata" semantic conventions. It represents the gRPC
+// request metadata, `` being the normalized gRPC Metadata key (lowercase),
+// the value being the metadata values.
+func RPCGRPCRequestMetadata(key string, val ...string) attribute.KeyValue {
+ return attribute.StringSlice("rpc.grpc.request.metadata."+key, val)
+}
+
+// RPCGRPCResponseMetadata returns an attribute KeyValue conforming to the
+// "rpc.grpc.response.metadata" semantic conventions. It represents the gRPC
+// response metadata, `` being the normalized gRPC Metadata key (lowercase),
+// the value being the metadata values.
+func RPCGRPCResponseMetadata(key string, val ...string) attribute.KeyValue {
+ return attribute.StringSlice("rpc.grpc.response.metadata."+key, val)
+}
+
+// RPCJSONRPCErrorCode returns an attribute KeyValue conforming to the
+// "rpc.jsonrpc.error_code" semantic conventions. It represents the `error.code`
+// property of response if it is an error response.
+func RPCJSONRPCErrorCode(val int) attribute.KeyValue {
+ return RPCJSONRPCErrorCodeKey.Int(val)
+}
+
+// RPCJSONRPCErrorMessage returns an attribute KeyValue conforming to the
+// "rpc.jsonrpc.error_message" semantic conventions. It represents the
+// `error.message` property of response if it is an error response.
+func RPCJSONRPCErrorMessage(val string) attribute.KeyValue {
+ return RPCJSONRPCErrorMessageKey.String(val)
+}
+
+// RPCJSONRPCRequestID returns an attribute KeyValue conforming to the
+// "rpc.jsonrpc.request_id" semantic conventions. It represents the `id` property
+// of request or response. Since protocol allows id to be int, string, `null` or
+// missing (for notifications), value is expected to be cast to string for
+// simplicity. Use empty string in case of `null` value. Omit entirely if this is
+// a notification.
+func RPCJSONRPCRequestID(val string) attribute.KeyValue {
+ return RPCJSONRPCRequestIDKey.String(val)
+}
+
+// RPCJSONRPCVersion returns an attribute KeyValue conforming to the
+// "rpc.jsonrpc.version" semantic conventions. It represents the protocol version
+// as in `jsonrpc` property of request/response. Since JSON-RPC 1.0 doesn't
+// specify this, the value can be omitted.
+func RPCJSONRPCVersion(val string) attribute.KeyValue {
+ return RPCJSONRPCVersionKey.String(val)
+}
+
+// RPCMessageCompressedSize returns an attribute KeyValue conforming to the
+// "rpc.message.compressed_size" semantic conventions. It represents the
+// compressed size of the message in bytes.
+func RPCMessageCompressedSize(val int) attribute.KeyValue {
+ return RPCMessageCompressedSizeKey.Int(val)
+}
+
+// RPCMessageID returns an attribute KeyValue conforming to the "rpc.message.id"
+// semantic conventions. It MUST be calculated as two different counters starting
+// from `1` one for sent messages and one for received message..
+func RPCMessageID(val int) attribute.KeyValue {
+ return RPCMessageIDKey.Int(val)
+}
+
+// RPCMessageUncompressedSize returns an attribute KeyValue conforming to the
+// "rpc.message.uncompressed_size" semantic conventions. It represents the
+// uncompressed size of the message in bytes.
+func RPCMessageUncompressedSize(val int) attribute.KeyValue {
+ return RPCMessageUncompressedSizeKey.Int(val)
+}
+
+// RPCMethod returns an attribute KeyValue conforming to the "rpc.method"
+// semantic conventions. It represents the name of the (logical) method being
+// called, must be equal to the $method part in the span name.
+func RPCMethod(val string) attribute.KeyValue {
+ return RPCMethodKey.String(val)
+}
+
+// RPCService returns an attribute KeyValue conforming to the "rpc.service"
+// semantic conventions. It represents the full (logical) name of the service
+// being called, including its package name, if applicable.
+func RPCService(val string) attribute.KeyValue {
+ return RPCServiceKey.String(val)
+}
+
+// Enum values for rpc.connect_rpc.error_code
+var (
+ // cancelled
+ // Stability: development
+ RPCConnectRPCErrorCodeCancelled = RPCConnectRPCErrorCodeKey.String("cancelled")
+ // unknown
+ // Stability: development
+ RPCConnectRPCErrorCodeUnknown = RPCConnectRPCErrorCodeKey.String("unknown")
+ // invalid_argument
+ // Stability: development
+ RPCConnectRPCErrorCodeInvalidArgument = RPCConnectRPCErrorCodeKey.String("invalid_argument")
+ // deadline_exceeded
+ // Stability: development
+ RPCConnectRPCErrorCodeDeadlineExceeded = RPCConnectRPCErrorCodeKey.String("deadline_exceeded")
+ // not_found
+ // Stability: development
+ RPCConnectRPCErrorCodeNotFound = RPCConnectRPCErrorCodeKey.String("not_found")
+ // already_exists
+ // Stability: development
+ RPCConnectRPCErrorCodeAlreadyExists = RPCConnectRPCErrorCodeKey.String("already_exists")
+ // permission_denied
+ // Stability: development
+ RPCConnectRPCErrorCodePermissionDenied = RPCConnectRPCErrorCodeKey.String("permission_denied")
+ // resource_exhausted
+ // Stability: development
+ RPCConnectRPCErrorCodeResourceExhausted = RPCConnectRPCErrorCodeKey.String("resource_exhausted")
+ // failed_precondition
+ // Stability: development
+ RPCConnectRPCErrorCodeFailedPrecondition = RPCConnectRPCErrorCodeKey.String("failed_precondition")
+ // aborted
+ // Stability: development
+ RPCConnectRPCErrorCodeAborted = RPCConnectRPCErrorCodeKey.String("aborted")
+ // out_of_range
+ // Stability: development
+ RPCConnectRPCErrorCodeOutOfRange = RPCConnectRPCErrorCodeKey.String("out_of_range")
+ // unimplemented
+ // Stability: development
+ RPCConnectRPCErrorCodeUnimplemented = RPCConnectRPCErrorCodeKey.String("unimplemented")
+ // internal
+ // Stability: development
+ RPCConnectRPCErrorCodeInternal = RPCConnectRPCErrorCodeKey.String("internal")
+ // unavailable
+ // Stability: development
+ RPCConnectRPCErrorCodeUnavailable = RPCConnectRPCErrorCodeKey.String("unavailable")
+ // data_loss
+ // Stability: development
+ RPCConnectRPCErrorCodeDataLoss = RPCConnectRPCErrorCodeKey.String("data_loss")
+ // unauthenticated
+ // Stability: development
+ RPCConnectRPCErrorCodeUnauthenticated = RPCConnectRPCErrorCodeKey.String("unauthenticated")
+)
+
+// Enum values for rpc.grpc.status_code
+var (
+ // OK
+ // Stability: development
+ RPCGRPCStatusCodeOk = RPCGRPCStatusCodeKey.Int(0)
+ // CANCELLED
+ // Stability: development
+ RPCGRPCStatusCodeCancelled = RPCGRPCStatusCodeKey.Int(1)
+ // UNKNOWN
+ // Stability: development
+ RPCGRPCStatusCodeUnknown = RPCGRPCStatusCodeKey.Int(2)
+ // INVALID_ARGUMENT
+ // Stability: development
+ RPCGRPCStatusCodeInvalidArgument = RPCGRPCStatusCodeKey.Int(3)
+ // DEADLINE_EXCEEDED
+ // Stability: development
+ RPCGRPCStatusCodeDeadlineExceeded = RPCGRPCStatusCodeKey.Int(4)
+ // NOT_FOUND
+ // Stability: development
+ RPCGRPCStatusCodeNotFound = RPCGRPCStatusCodeKey.Int(5)
+ // ALREADY_EXISTS
+ // Stability: development
+ RPCGRPCStatusCodeAlreadyExists = RPCGRPCStatusCodeKey.Int(6)
+ // PERMISSION_DENIED
+ // Stability: development
+ RPCGRPCStatusCodePermissionDenied = RPCGRPCStatusCodeKey.Int(7)
+ // RESOURCE_EXHAUSTED
+ // Stability: development
+ RPCGRPCStatusCodeResourceExhausted = RPCGRPCStatusCodeKey.Int(8)
+ // FAILED_PRECONDITION
+ // Stability: development
+ RPCGRPCStatusCodeFailedPrecondition = RPCGRPCStatusCodeKey.Int(9)
+ // ABORTED
+ // Stability: development
+ RPCGRPCStatusCodeAborted = RPCGRPCStatusCodeKey.Int(10)
+ // OUT_OF_RANGE
+ // Stability: development
+ RPCGRPCStatusCodeOutOfRange = RPCGRPCStatusCodeKey.Int(11)
+ // UNIMPLEMENTED
+ // Stability: development
+ RPCGRPCStatusCodeUnimplemented = RPCGRPCStatusCodeKey.Int(12)
+ // INTERNAL
+ // Stability: development
+ RPCGRPCStatusCodeInternal = RPCGRPCStatusCodeKey.Int(13)
+ // UNAVAILABLE
+ // Stability: development
+ RPCGRPCStatusCodeUnavailable = RPCGRPCStatusCodeKey.Int(14)
+ // DATA_LOSS
+ // Stability: development
+ RPCGRPCStatusCodeDataLoss = RPCGRPCStatusCodeKey.Int(15)
+ // UNAUTHENTICATED
+ // Stability: development
+ RPCGRPCStatusCodeUnauthenticated = RPCGRPCStatusCodeKey.Int(16)
+)
+
+// Enum values for rpc.message.type
+var (
+ // sent
+ // Stability: development
+ RPCMessageTypeSent = RPCMessageTypeKey.String("SENT")
+ // received
+ // Stability: development
+ RPCMessageTypeReceived = RPCMessageTypeKey.String("RECEIVED")
+)
+
+// Enum values for rpc.system
+var (
+ // gRPC
+ // Stability: development
+ RPCSystemGRPC = RPCSystemKey.String("grpc")
+ // Java RMI
+ // Stability: development
+ RPCSystemJavaRmi = RPCSystemKey.String("java_rmi")
+ // .NET WCF
+ // Stability: development
+ RPCSystemDotnetWcf = RPCSystemKey.String("dotnet_wcf")
+ // Apache Dubbo
+ // Stability: development
+ RPCSystemApacheDubbo = RPCSystemKey.String("apache_dubbo")
+ // Connect RPC
+ // Stability: development
+ RPCSystemConnectRPC = RPCSystemKey.String("connect_rpc")
+)
+
+// Namespace: security_rule
+const (
+ // SecurityRuleCategoryKey is the attribute Key conforming to the
+ // "security_rule.category" semantic conventions. It represents a categorization
+ // value keyword used by the entity using the rule for detection of this event.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Attempted Information Leak"
+ SecurityRuleCategoryKey = attribute.Key("security_rule.category")
+
+ // SecurityRuleDescriptionKey is the attribute Key conforming to the
+ // "security_rule.description" semantic conventions. It represents the
+ // description of the rule generating the event.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Block requests to public DNS over HTTPS / TLS protocols"
+ SecurityRuleDescriptionKey = attribute.Key("security_rule.description")
+
+ // SecurityRuleLicenseKey is the attribute Key conforming to the
+ // "security_rule.license" semantic conventions. It represents the name of the
+ // license under which the rule used to generate this event is made available.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Apache 2.0"
+ SecurityRuleLicenseKey = attribute.Key("security_rule.license")
+
+ // SecurityRuleNameKey is the attribute Key conforming to the
+ // "security_rule.name" semantic conventions. It represents the name of the rule
+ // or signature generating the event.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "BLOCK_DNS_over_TLS"
+ SecurityRuleNameKey = attribute.Key("security_rule.name")
+
+ // SecurityRuleReferenceKey is the attribute Key conforming to the
+ // "security_rule.reference" semantic conventions. It represents the reference
+ // URL to additional information about the rule used to generate this event.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "https://en.wikipedia.org/wiki/DNS_over_TLS"
+ // Note: The URL can point to the vendor’s documentation about the rule. If
+ // that’s not available, it can also be a link to a more general page
+ // describing this type of alert.
+ SecurityRuleReferenceKey = attribute.Key("security_rule.reference")
+
+ // SecurityRuleRulesetNameKey is the attribute Key conforming to the
+ // "security_rule.ruleset.name" semantic conventions. It represents the name of
+ // the ruleset, policy, group, or parent category in which the rule used to
+ // generate this event is a member.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Standard_Protocol_Filters"
+ SecurityRuleRulesetNameKey = attribute.Key("security_rule.ruleset.name")
+
+ // SecurityRuleUUIDKey is the attribute Key conforming to the
+ // "security_rule.uuid" semantic conventions. It represents a rule ID that is
+ // unique within the scope of a set or group of agents, observers, or other
+ // entities using the rule for detection of this event.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "550e8400-e29b-41d4-a716-446655440000", "1100110011"
+ SecurityRuleUUIDKey = attribute.Key("security_rule.uuid")
+
+ // SecurityRuleVersionKey is the attribute Key conforming to the
+ // "security_rule.version" semantic conventions. It represents the version /
+ // revision of the rule being used for analysis.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "1.0.0"
+ SecurityRuleVersionKey = attribute.Key("security_rule.version")
+)
+
+// SecurityRuleCategory returns an attribute KeyValue conforming to the
+// "security_rule.category" semantic conventions. It represents a categorization
+// value keyword used by the entity using the rule for detection of this event.
+func SecurityRuleCategory(val string) attribute.KeyValue {
+ return SecurityRuleCategoryKey.String(val)
+}
+
+// SecurityRuleDescription returns an attribute KeyValue conforming to the
+// "security_rule.description" semantic conventions. It represents the
+// description of the rule generating the event.
+func SecurityRuleDescription(val string) attribute.KeyValue {
+ return SecurityRuleDescriptionKey.String(val)
+}
+
+// SecurityRuleLicense returns an attribute KeyValue conforming to the
+// "security_rule.license" semantic conventions. It represents the name of the
+// license under which the rule used to generate this event is made available.
+func SecurityRuleLicense(val string) attribute.KeyValue {
+ return SecurityRuleLicenseKey.String(val)
+}
+
+// SecurityRuleName returns an attribute KeyValue conforming to the
+// "security_rule.name" semantic conventions. It represents the name of the rule
+// or signature generating the event.
+func SecurityRuleName(val string) attribute.KeyValue {
+ return SecurityRuleNameKey.String(val)
+}
+
+// SecurityRuleReference returns an attribute KeyValue conforming to the
+// "security_rule.reference" semantic conventions. It represents the reference
+// URL to additional information about the rule used to generate this event.
+func SecurityRuleReference(val string) attribute.KeyValue {
+ return SecurityRuleReferenceKey.String(val)
+}
+
+// SecurityRuleRulesetName returns an attribute KeyValue conforming to the
+// "security_rule.ruleset.name" semantic conventions. It represents the name of
+// the ruleset, policy, group, or parent category in which the rule used to
+// generate this event is a member.
+func SecurityRuleRulesetName(val string) attribute.KeyValue {
+ return SecurityRuleRulesetNameKey.String(val)
+}
+
+// SecurityRuleUUID returns an attribute KeyValue conforming to the
+// "security_rule.uuid" semantic conventions. It represents a rule ID that is
+// unique within the scope of a set or group of agents, observers, or other
+// entities using the rule for detection of this event.
+func SecurityRuleUUID(val string) attribute.KeyValue {
+ return SecurityRuleUUIDKey.String(val)
+}
+
+// SecurityRuleVersion returns an attribute KeyValue conforming to the
+// "security_rule.version" semantic conventions. It represents the version /
+// revision of the rule being used for analysis.
+func SecurityRuleVersion(val string) attribute.KeyValue {
+ return SecurityRuleVersionKey.String(val)
+}
+
+// Namespace: server
+const (
+ // ServerAddressKey is the attribute Key conforming to the "server.address"
+ // semantic conventions. It represents the server domain name if available
+ // without reverse DNS lookup; otherwise, IP address or Unix domain socket name.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "example.com", "10.1.2.80", "/tmp/my.sock"
+ // Note: When observed from the client side, and when communicating through an
+ // intermediary, `server.address` SHOULD represent the server address behind any
+ // intermediaries, for example proxies, if it's available.
+ ServerAddressKey = attribute.Key("server.address")
+
+ // ServerPortKey is the attribute Key conforming to the "server.port" semantic
+ // conventions. It represents the server port number.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: 80, 8080, 443
+ // Note: When observed from the client side, and when communicating through an
+ // intermediary, `server.port` SHOULD represent the server port behind any
+ // intermediaries, for example proxies, if it's available.
+ ServerPortKey = attribute.Key("server.port")
+)
+
+// ServerAddress returns an attribute KeyValue conforming to the "server.address"
+// semantic conventions. It represents the server domain name if available
+// without reverse DNS lookup; otherwise, IP address or Unix domain socket name.
+func ServerAddress(val string) attribute.KeyValue {
+ return ServerAddressKey.String(val)
+}
+
+// ServerPort returns an attribute KeyValue conforming to the "server.port"
+// semantic conventions. It represents the server port number.
+func ServerPort(val int) attribute.KeyValue {
+ return ServerPortKey.Int(val)
+}
+
+// Namespace: service
+const (
+ // ServiceInstanceIDKey is the attribute Key conforming to the
+ // "service.instance.id" semantic conventions. It represents the string ID of
+ // the service instance.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "627cc493-f310-47de-96bd-71410b7dec09"
+ // Note: MUST be unique for each instance of the same
+ // `service.namespace,service.name` pair (in other words
+ // `service.namespace,service.name,service.instance.id` triplet MUST be globally
+ // unique). The ID helps to
+ // distinguish instances of the same service that exist at the same time (e.g.
+ // instances of a horizontally scaled
+ // service).
+ //
+ // Implementations, such as SDKs, are recommended to generate a random Version 1
+ // or Version 4 [RFC
+ // 4122] UUID, but are free to use an inherent unique ID as
+ // the source of
+ // this value if stability is desirable. In that case, the ID SHOULD be used as
+ // source of a UUID Version 5 and
+ // SHOULD use the following UUID as the namespace:
+ // `4d63009a-8d0f-11ee-aad7-4c796ed8e320`.
+ //
+ // UUIDs are typically recommended, as only an opaque value for the purposes of
+ // identifying a service instance is
+ // needed. Similar to what can be seen in the man page for the
+ // [`/etc/machine-id`] file, the underlying
+ // data, such as pod name and namespace should be treated as confidential, being
+ // the user's choice to expose it
+ // or not via another resource attribute.
+ //
+ // For applications running behind an application server (like unicorn), we do
+ // not recommend using one identifier
+ // for all processes participating in the application. Instead, it's recommended
+ // each division (e.g. a worker
+ // thread in unicorn) to have its own instance.id.
+ //
+ // It's not recommended for a Collector to set `service.instance.id` if it can't
+ // unambiguously determine the
+ // service instance that is generating that telemetry. For instance, creating an
+ // UUID based on `pod.name` will
+ // likely be wrong, as the Collector might not know from which container within
+ // that pod the telemetry originated.
+ // However, Collectors can set the `service.instance.id` if they can
+ // unambiguously determine the service instance
+ // for that telemetry. This is typically the case for scraping receivers, as
+ // they know the target address and
+ // port.
+ //
+ // [RFC
+ // 4122]: https://www.ietf.org/rfc/rfc4122.txt
+ // [`/etc/machine-id`]: https://www.freedesktop.org/software/systemd/man/latest/machine-id.html
+ ServiceInstanceIDKey = attribute.Key("service.instance.id")
+
+ // ServiceNameKey is the attribute Key conforming to the "service.name" semantic
+ // conventions. It represents the logical name of the service.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "shoppingcart"
+ // Note: MUST be the same for all instances of horizontally scaled services. If
+ // the value was not specified, SDKs MUST fallback to `unknown_service:`
+ // concatenated with [`process.executable.name`], e.g. `unknown_service:bash`.
+ // If `process.executable.name` is not available, the value MUST be set to
+ // `unknown_service`.
+ //
+ // [`process.executable.name`]: process.md
+ ServiceNameKey = attribute.Key("service.name")
+
+ // ServiceNamespaceKey is the attribute Key conforming to the
+ // "service.namespace" semantic conventions. It represents a namespace for
+ // `service.name`.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Shop"
+ // Note: A string value having a meaning that helps to distinguish a group of
+ // services, for example the team name that owns a group of services.
+ // `service.name` is expected to be unique within the same namespace. If
+ // `service.namespace` is not specified in the Resource then `service.name` is
+ // expected to be unique for all services that have no explicit namespace
+ // defined (so the empty/unspecified namespace is simply one more valid
+ // namespace). Zero-length namespace string is assumed equal to unspecified
+ // namespace.
+ ServiceNamespaceKey = attribute.Key("service.namespace")
+
+ // ServiceVersionKey is the attribute Key conforming to the "service.version"
+ // semantic conventions. It represents the version string of the service API or
+ // implementation. The format is not defined by these conventions.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "2.0.0", "a01dbef8a"
+ ServiceVersionKey = attribute.Key("service.version")
+)
+
+// ServiceInstanceID returns an attribute KeyValue conforming to the
+// "service.instance.id" semantic conventions. It represents the string ID of the
+// service instance.
+func ServiceInstanceID(val string) attribute.KeyValue {
+ return ServiceInstanceIDKey.String(val)
+}
+
+// ServiceName returns an attribute KeyValue conforming to the "service.name"
+// semantic conventions. It represents the logical name of the service.
+func ServiceName(val string) attribute.KeyValue {
+ return ServiceNameKey.String(val)
+}
+
+// ServiceNamespace returns an attribute KeyValue conforming to the
+// "service.namespace" semantic conventions. It represents a namespace for
+// `service.name`.
+func ServiceNamespace(val string) attribute.KeyValue {
+ return ServiceNamespaceKey.String(val)
+}
+
+// ServiceVersion returns an attribute KeyValue conforming to the
+// "service.version" semantic conventions. It represents the version string of
+// the service API or implementation. The format is not defined by these
+// conventions.
+func ServiceVersion(val string) attribute.KeyValue {
+ return ServiceVersionKey.String(val)
+}
+
+// Namespace: session
+const (
+ // SessionIDKey is the attribute Key conforming to the "session.id" semantic
+ // conventions. It represents a unique id to identify a session.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 00112233-4455-6677-8899-aabbccddeeff
+ SessionIDKey = attribute.Key("session.id")
+
+ // SessionPreviousIDKey is the attribute Key conforming to the
+ // "session.previous_id" semantic conventions. It represents the previous
+ // `session.id` for this user, when known.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 00112233-4455-6677-8899-aabbccddeeff
+ SessionPreviousIDKey = attribute.Key("session.previous_id")
+)
+
+// SessionID returns an attribute KeyValue conforming to the "session.id"
+// semantic conventions. It represents a unique id to identify a session.
+func SessionID(val string) attribute.KeyValue {
+ return SessionIDKey.String(val)
+}
+
+// SessionPreviousID returns an attribute KeyValue conforming to the
+// "session.previous_id" semantic conventions. It represents the previous
+// `session.id` for this user, when known.
+func SessionPreviousID(val string) attribute.KeyValue {
+ return SessionPreviousIDKey.String(val)
+}
+
+// Namespace: signalr
+const (
+ // SignalRConnectionStatusKey is the attribute Key conforming to the
+ // "signalr.connection.status" semantic conventions. It represents the signalR
+ // HTTP connection closure status.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "app_shutdown", "timeout"
+ SignalRConnectionStatusKey = attribute.Key("signalr.connection.status")
+
+ // SignalRTransportKey is the attribute Key conforming to the
+ // "signalr.transport" semantic conventions. It represents the
+ // [SignalR transport type].
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "web_sockets", "long_polling"
+ //
+ // [SignalR transport type]: https://github.com/dotnet/aspnetcore/blob/main/src/SignalR/docs/specs/TransportProtocols.md
+ SignalRTransportKey = attribute.Key("signalr.transport")
+)
+
+// Enum values for signalr.connection.status
+var (
+ // The connection was closed normally.
+ // Stability: stable
+ SignalRConnectionStatusNormalClosure = SignalRConnectionStatusKey.String("normal_closure")
+ // The connection was closed due to a timeout.
+ // Stability: stable
+ SignalRConnectionStatusTimeout = SignalRConnectionStatusKey.String("timeout")
+ // The connection was closed because the app is shutting down.
+ // Stability: stable
+ SignalRConnectionStatusAppShutdown = SignalRConnectionStatusKey.String("app_shutdown")
+)
+
+// Enum values for signalr.transport
+var (
+ // ServerSentEvents protocol
+ // Stability: stable
+ SignalRTransportServerSentEvents = SignalRTransportKey.String("server_sent_events")
+ // LongPolling protocol
+ // Stability: stable
+ SignalRTransportLongPolling = SignalRTransportKey.String("long_polling")
+ // WebSockets protocol
+ // Stability: stable
+ SignalRTransportWebSockets = SignalRTransportKey.String("web_sockets")
+)
+
+// Namespace: source
+const (
+ // SourceAddressKey is the attribute Key conforming to the "source.address"
+ // semantic conventions. It represents the source address - domain name if
+ // available without reverse DNS lookup; otherwise, IP address or Unix domain
+ // socket name.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "source.example.com", "10.1.2.80", "/tmp/my.sock"
+ // Note: When observed from the destination side, and when communicating through
+ // an intermediary, `source.address` SHOULD represent the source address behind
+ // any intermediaries, for example proxies, if it's available.
+ SourceAddressKey = attribute.Key("source.address")
+
+ // SourcePortKey is the attribute Key conforming to the "source.port" semantic
+ // conventions. It represents the source port number.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 3389, 2888
+ SourcePortKey = attribute.Key("source.port")
+)
+
+// SourceAddress returns an attribute KeyValue conforming to the "source.address"
+// semantic conventions. It represents the source address - domain name if
+// available without reverse DNS lookup; otherwise, IP address or Unix domain
+// socket name.
+func SourceAddress(val string) attribute.KeyValue {
+ return SourceAddressKey.String(val)
+}
+
+// SourcePort returns an attribute KeyValue conforming to the "source.port"
+// semantic conventions. It represents the source port number.
+func SourcePort(val int) attribute.KeyValue {
+ return SourcePortKey.Int(val)
+}
+
+// Namespace: system
+const (
+ // SystemCPULogicalNumberKey is the attribute Key conforming to the
+ // "system.cpu.logical_number" semantic conventions. It represents the
+ // deprecated, use `cpu.logical_number` instead.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 1
+ SystemCPULogicalNumberKey = attribute.Key("system.cpu.logical_number")
+
+ // SystemDeviceKey is the attribute Key conforming to the "system.device"
+ // semantic conventions. It represents the device identifier.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "(identifier)"
+ SystemDeviceKey = attribute.Key("system.device")
+
+ // SystemFilesystemModeKey is the attribute Key conforming to the
+ // "system.filesystem.mode" semantic conventions. It represents the filesystem
+ // mode.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "rw, ro"
+ SystemFilesystemModeKey = attribute.Key("system.filesystem.mode")
+
+ // SystemFilesystemMountpointKey is the attribute Key conforming to the
+ // "system.filesystem.mountpoint" semantic conventions. It represents the
+ // filesystem mount path.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "/mnt/data"
+ SystemFilesystemMountpointKey = attribute.Key("system.filesystem.mountpoint")
+
+ // SystemFilesystemStateKey is the attribute Key conforming to the
+ // "system.filesystem.state" semantic conventions. It represents the filesystem
+ // state.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "used"
+ SystemFilesystemStateKey = attribute.Key("system.filesystem.state")
+
+ // SystemFilesystemTypeKey is the attribute Key conforming to the
+ // "system.filesystem.type" semantic conventions. It represents the filesystem
+ // type.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "ext4"
+ SystemFilesystemTypeKey = attribute.Key("system.filesystem.type")
+
+ // SystemMemoryStateKey is the attribute Key conforming to the
+ // "system.memory.state" semantic conventions. It represents the memory state.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "free", "cached"
+ SystemMemoryStateKey = attribute.Key("system.memory.state")
+
+ // SystemPagingDirectionKey is the attribute Key conforming to the
+ // "system.paging.direction" semantic conventions. It represents the paging
+ // access direction.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "in"
+ SystemPagingDirectionKey = attribute.Key("system.paging.direction")
+
+ // SystemPagingStateKey is the attribute Key conforming to the
+ // "system.paging.state" semantic conventions. It represents the memory paging
+ // state.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "free"
+ SystemPagingStateKey = attribute.Key("system.paging.state")
+
+ // SystemPagingTypeKey is the attribute Key conforming to the
+ // "system.paging.type" semantic conventions. It represents the memory paging
+ // type.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "minor"
+ SystemPagingTypeKey = attribute.Key("system.paging.type")
+
+ // SystemProcessStatusKey is the attribute Key conforming to the
+ // "system.process.status" semantic conventions. It represents the process
+ // state, e.g., [Linux Process State Codes].
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "running"
+ //
+ // [Linux Process State Codes]: https://man7.org/linux/man-pages/man1/ps.1.html#PROCESS_STATE_CODES
+ SystemProcessStatusKey = attribute.Key("system.process.status")
+)
+
+// SystemCPULogicalNumber returns an attribute KeyValue conforming to the
+// "system.cpu.logical_number" semantic conventions. It represents the
+// deprecated, use `cpu.logical_number` instead.
+func SystemCPULogicalNumber(val int) attribute.KeyValue {
+ return SystemCPULogicalNumberKey.Int(val)
+}
+
+// SystemDevice returns an attribute KeyValue conforming to the "system.device"
+// semantic conventions. It represents the device identifier.
+func SystemDevice(val string) attribute.KeyValue {
+ return SystemDeviceKey.String(val)
+}
+
+// SystemFilesystemMode returns an attribute KeyValue conforming to the
+// "system.filesystem.mode" semantic conventions. It represents the filesystem
+// mode.
+func SystemFilesystemMode(val string) attribute.KeyValue {
+ return SystemFilesystemModeKey.String(val)
+}
+
+// SystemFilesystemMountpoint returns an attribute KeyValue conforming to the
+// "system.filesystem.mountpoint" semantic conventions. It represents the
+// filesystem mount path.
+func SystemFilesystemMountpoint(val string) attribute.KeyValue {
+ return SystemFilesystemMountpointKey.String(val)
+}
+
+// Enum values for system.filesystem.state
+var (
+ // used
+ // Stability: development
+ SystemFilesystemStateUsed = SystemFilesystemStateKey.String("used")
+ // free
+ // Stability: development
+ SystemFilesystemStateFree = SystemFilesystemStateKey.String("free")
+ // reserved
+ // Stability: development
+ SystemFilesystemStateReserved = SystemFilesystemStateKey.String("reserved")
+)
+
+// Enum values for system.filesystem.type
+var (
+ // fat32
+ // Stability: development
+ SystemFilesystemTypeFat32 = SystemFilesystemTypeKey.String("fat32")
+ // exfat
+ // Stability: development
+ SystemFilesystemTypeExfat = SystemFilesystemTypeKey.String("exfat")
+ // ntfs
+ // Stability: development
+ SystemFilesystemTypeNtfs = SystemFilesystemTypeKey.String("ntfs")
+ // refs
+ // Stability: development
+ SystemFilesystemTypeRefs = SystemFilesystemTypeKey.String("refs")
+ // hfsplus
+ // Stability: development
+ SystemFilesystemTypeHfsplus = SystemFilesystemTypeKey.String("hfsplus")
+ // ext4
+ // Stability: development
+ SystemFilesystemTypeExt4 = SystemFilesystemTypeKey.String("ext4")
+)
+
+// Enum values for system.memory.state
+var (
+ // Actual used virtual memory in bytes.
+ // Stability: development
+ SystemMemoryStateUsed = SystemMemoryStateKey.String("used")
+ // free
+ // Stability: development
+ SystemMemoryStateFree = SystemMemoryStateKey.String("free")
+ // buffers
+ // Stability: development
+ SystemMemoryStateBuffers = SystemMemoryStateKey.String("buffers")
+ // cached
+ // Stability: development
+ SystemMemoryStateCached = SystemMemoryStateKey.String("cached")
+)
+
+// Enum values for system.paging.direction
+var (
+ // in
+ // Stability: development
+ SystemPagingDirectionIn = SystemPagingDirectionKey.String("in")
+ // out
+ // Stability: development
+ SystemPagingDirectionOut = SystemPagingDirectionKey.String("out")
+)
+
+// Enum values for system.paging.state
+var (
+ // used
+ // Stability: development
+ SystemPagingStateUsed = SystemPagingStateKey.String("used")
+ // free
+ // Stability: development
+ SystemPagingStateFree = SystemPagingStateKey.String("free")
+)
+
+// Enum values for system.paging.type
+var (
+ // major
+ // Stability: development
+ SystemPagingTypeMajor = SystemPagingTypeKey.String("major")
+ // minor
+ // Stability: development
+ SystemPagingTypeMinor = SystemPagingTypeKey.String("minor")
+)
+
+// Enum values for system.process.status
+var (
+ // running
+ // Stability: development
+ SystemProcessStatusRunning = SystemProcessStatusKey.String("running")
+ // sleeping
+ // Stability: development
+ SystemProcessStatusSleeping = SystemProcessStatusKey.String("sleeping")
+ // stopped
+ // Stability: development
+ SystemProcessStatusStopped = SystemProcessStatusKey.String("stopped")
+ // defunct
+ // Stability: development
+ SystemProcessStatusDefunct = SystemProcessStatusKey.String("defunct")
+)
+
+// Namespace: telemetry
+const (
+ // TelemetryDistroNameKey is the attribute Key conforming to the
+ // "telemetry.distro.name" semantic conventions. It represents the name of the
+ // auto instrumentation agent or distribution, if used.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "parts-unlimited-java"
+ // Note: Official auto instrumentation agents and distributions SHOULD set the
+ // `telemetry.distro.name` attribute to
+ // a string starting with `opentelemetry-`, e.g.
+ // `opentelemetry-java-instrumentation`.
+ TelemetryDistroNameKey = attribute.Key("telemetry.distro.name")
+
+ // TelemetryDistroVersionKey is the attribute Key conforming to the
+ // "telemetry.distro.version" semantic conventions. It represents the version
+ // string of the auto instrumentation agent or distribution, if used.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "1.2.3"
+ TelemetryDistroVersionKey = attribute.Key("telemetry.distro.version")
+
+ // TelemetrySDKLanguageKey is the attribute Key conforming to the
+ // "telemetry.sdk.language" semantic conventions. It represents the language of
+ // the telemetry SDK.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples:
+ TelemetrySDKLanguageKey = attribute.Key("telemetry.sdk.language")
+
+ // TelemetrySDKNameKey is the attribute Key conforming to the
+ // "telemetry.sdk.name" semantic conventions. It represents the name of the
+ // telemetry SDK as defined above.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "opentelemetry"
+ // Note: The OpenTelemetry SDK MUST set the `telemetry.sdk.name` attribute to
+ // `opentelemetry`.
+ // If another SDK, like a fork or a vendor-provided implementation, is used,
+ // this SDK MUST set the
+ // `telemetry.sdk.name` attribute to the fully-qualified class or module name of
+ // this SDK's main entry point
+ // or another suitable identifier depending on the language.
+ // The identifier `opentelemetry` is reserved and MUST NOT be used in this case.
+ // All custom identifiers SHOULD be stable across different versions of an
+ // implementation.
+ TelemetrySDKNameKey = attribute.Key("telemetry.sdk.name")
+
+ // TelemetrySDKVersionKey is the attribute Key conforming to the
+ // "telemetry.sdk.version" semantic conventions. It represents the version
+ // string of the telemetry SDK.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "1.2.3"
+ TelemetrySDKVersionKey = attribute.Key("telemetry.sdk.version")
+)
+
+// TelemetryDistroName returns an attribute KeyValue conforming to the
+// "telemetry.distro.name" semantic conventions. It represents the name of the
+// auto instrumentation agent or distribution, if used.
+func TelemetryDistroName(val string) attribute.KeyValue {
+ return TelemetryDistroNameKey.String(val)
+}
+
+// TelemetryDistroVersion returns an attribute KeyValue conforming to the
+// "telemetry.distro.version" semantic conventions. It represents the version
+// string of the auto instrumentation agent or distribution, if used.
+func TelemetryDistroVersion(val string) attribute.KeyValue {
+ return TelemetryDistroVersionKey.String(val)
+}
+
+// TelemetrySDKName returns an attribute KeyValue conforming to the
+// "telemetry.sdk.name" semantic conventions. It represents the name of the
+// telemetry SDK as defined above.
+func TelemetrySDKName(val string) attribute.KeyValue {
+ return TelemetrySDKNameKey.String(val)
+}
+
+// TelemetrySDKVersion returns an attribute KeyValue conforming to the
+// "telemetry.sdk.version" semantic conventions. It represents the version string
+// of the telemetry SDK.
+func TelemetrySDKVersion(val string) attribute.KeyValue {
+ return TelemetrySDKVersionKey.String(val)
+}
+
+// Enum values for telemetry.sdk.language
+var (
+ // cpp
+ // Stability: stable
+ TelemetrySDKLanguageCPP = TelemetrySDKLanguageKey.String("cpp")
+ // dotnet
+ // Stability: stable
+ TelemetrySDKLanguageDotnet = TelemetrySDKLanguageKey.String("dotnet")
+ // erlang
+ // Stability: stable
+ TelemetrySDKLanguageErlang = TelemetrySDKLanguageKey.String("erlang")
+ // go
+ // Stability: stable
+ TelemetrySDKLanguageGo = TelemetrySDKLanguageKey.String("go")
+ // java
+ // Stability: stable
+ TelemetrySDKLanguageJava = TelemetrySDKLanguageKey.String("java")
+ // nodejs
+ // Stability: stable
+ TelemetrySDKLanguageNodejs = TelemetrySDKLanguageKey.String("nodejs")
+ // php
+ // Stability: stable
+ TelemetrySDKLanguagePHP = TelemetrySDKLanguageKey.String("php")
+ // python
+ // Stability: stable
+ TelemetrySDKLanguagePython = TelemetrySDKLanguageKey.String("python")
+ // ruby
+ // Stability: stable
+ TelemetrySDKLanguageRuby = TelemetrySDKLanguageKey.String("ruby")
+ // rust
+ // Stability: stable
+ TelemetrySDKLanguageRust = TelemetrySDKLanguageKey.String("rust")
+ // swift
+ // Stability: stable
+ TelemetrySDKLanguageSwift = TelemetrySDKLanguageKey.String("swift")
+ // webjs
+ // Stability: stable
+ TelemetrySDKLanguageWebJS = TelemetrySDKLanguageKey.String("webjs")
+)
+
+// Namespace: test
+const (
+ // TestCaseNameKey is the attribute Key conforming to the "test.case.name"
+ // semantic conventions. It represents the fully qualified human readable name
+ // of the [test case].
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "org.example.TestCase1.test1", "example/tests/TestCase1.test1",
+ // "ExampleTestCase1_test1"
+ //
+ // [test case]: https://wikipedia.org/wiki/Test_case
+ TestCaseNameKey = attribute.Key("test.case.name")
+
+ // TestCaseResultStatusKey is the attribute Key conforming to the
+ // "test.case.result.status" semantic conventions. It represents the status of
+ // the actual test case result from test execution.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "pass", "fail"
+ TestCaseResultStatusKey = attribute.Key("test.case.result.status")
+
+ // TestSuiteNameKey is the attribute Key conforming to the "test.suite.name"
+ // semantic conventions. It represents the human readable name of a [test suite]
+ // .
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "TestSuite1"
+ //
+ // [test suite]: https://wikipedia.org/wiki/Test_suite
+ TestSuiteNameKey = attribute.Key("test.suite.name")
+
+ // TestSuiteRunStatusKey is the attribute Key conforming to the
+ // "test.suite.run.status" semantic conventions. It represents the status of the
+ // test suite run.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "success", "failure", "skipped", "aborted", "timed_out",
+ // "in_progress"
+ TestSuiteRunStatusKey = attribute.Key("test.suite.run.status")
+)
+
+// TestCaseName returns an attribute KeyValue conforming to the "test.case.name"
+// semantic conventions. It represents the fully qualified human readable name of
+// the [test case].
+//
+// [test case]: https://wikipedia.org/wiki/Test_case
+func TestCaseName(val string) attribute.KeyValue {
+ return TestCaseNameKey.String(val)
+}
+
+// TestSuiteName returns an attribute KeyValue conforming to the
+// "test.suite.name" semantic conventions. It represents the human readable name
+// of a [test suite].
+//
+// [test suite]: https://wikipedia.org/wiki/Test_suite
+func TestSuiteName(val string) attribute.KeyValue {
+ return TestSuiteNameKey.String(val)
+}
+
+// Enum values for test.case.result.status
+var (
+ // pass
+ // Stability: development
+ TestCaseResultStatusPass = TestCaseResultStatusKey.String("pass")
+ // fail
+ // Stability: development
+ TestCaseResultStatusFail = TestCaseResultStatusKey.String("fail")
+)
+
+// Enum values for test.suite.run.status
+var (
+ // success
+ // Stability: development
+ TestSuiteRunStatusSuccess = TestSuiteRunStatusKey.String("success")
+ // failure
+ // Stability: development
+ TestSuiteRunStatusFailure = TestSuiteRunStatusKey.String("failure")
+ // skipped
+ // Stability: development
+ TestSuiteRunStatusSkipped = TestSuiteRunStatusKey.String("skipped")
+ // aborted
+ // Stability: development
+ TestSuiteRunStatusAborted = TestSuiteRunStatusKey.String("aborted")
+ // timed_out
+ // Stability: development
+ TestSuiteRunStatusTimedOut = TestSuiteRunStatusKey.String("timed_out")
+ // in_progress
+ // Stability: development
+ TestSuiteRunStatusInProgress = TestSuiteRunStatusKey.String("in_progress")
+)
+
+// Namespace: thread
+const (
+ // ThreadIDKey is the attribute Key conforming to the "thread.id" semantic
+ // conventions. It represents the current "managed" thread ID (as opposed to OS
+ // thread ID).
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ ThreadIDKey = attribute.Key("thread.id")
+
+ // ThreadNameKey is the attribute Key conforming to the "thread.name" semantic
+ // conventions. It represents the current thread name.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: main
+ ThreadNameKey = attribute.Key("thread.name")
+)
+
+// ThreadID returns an attribute KeyValue conforming to the "thread.id" semantic
+// conventions. It represents the current "managed" thread ID (as opposed to OS
+// thread ID).
+func ThreadID(val int) attribute.KeyValue {
+ return ThreadIDKey.Int(val)
+}
+
+// ThreadName returns an attribute KeyValue conforming to the "thread.name"
+// semantic conventions. It represents the current thread name.
+func ThreadName(val string) attribute.KeyValue {
+ return ThreadNameKey.String(val)
+}
+
+// Namespace: tls
+const (
+ // TLSCipherKey is the attribute Key conforming to the "tls.cipher" semantic
+ // conventions. It represents the string indicating the [cipher] used during the
+ // current connection.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "TLS_RSA_WITH_3DES_EDE_CBC_SHA",
+ // "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256"
+ // Note: The values allowed for `tls.cipher` MUST be one of the `Descriptions`
+ // of the [registered TLS Cipher Suits].
+ //
+ // [cipher]: https://datatracker.ietf.org/doc/html/rfc5246#appendix-A.5
+ // [registered TLS Cipher Suits]: https://www.iana.org/assignments/tls-parameters/tls-parameters.xhtml#table-tls-parameters-4
+ TLSCipherKey = attribute.Key("tls.cipher")
+
+ // TLSClientCertificateKey is the attribute Key conforming to the
+ // "tls.client.certificate" semantic conventions. It represents the PEM-encoded
+ // stand-alone certificate offered by the client. This is usually
+ // mutually-exclusive of `client.certificate_chain` since this value also exists
+ // in that list.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "MII..."
+ TLSClientCertificateKey = attribute.Key("tls.client.certificate")
+
+ // TLSClientCertificateChainKey is the attribute Key conforming to the
+ // "tls.client.certificate_chain" semantic conventions. It represents the array
+ // of PEM-encoded certificates that make up the certificate chain offered by the
+ // client. This is usually mutually-exclusive of `client.certificate` since that
+ // value should be the first certificate in the chain.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "MII...", "MI..."
+ TLSClientCertificateChainKey = attribute.Key("tls.client.certificate_chain")
+
+ // TLSClientHashMd5Key is the attribute Key conforming to the
+ // "tls.client.hash.md5" semantic conventions. It represents the certificate
+ // fingerprint using the MD5 digest of DER-encoded version of certificate
+ // offered by the client. For consistency with other hash values, this value
+ // should be formatted as an uppercase hash.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "0F76C7F2C55BFD7D8E8B8F4BFBF0C9EC"
+ TLSClientHashMd5Key = attribute.Key("tls.client.hash.md5")
+
+ // TLSClientHashSha1Key is the attribute Key conforming to the
+ // "tls.client.hash.sha1" semantic conventions. It represents the certificate
+ // fingerprint using the SHA1 digest of DER-encoded version of certificate
+ // offered by the client. For consistency with other hash values, this value
+ // should be formatted as an uppercase hash.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "9E393D93138888D288266C2D915214D1D1CCEB2A"
+ TLSClientHashSha1Key = attribute.Key("tls.client.hash.sha1")
+
+ // TLSClientHashSha256Key is the attribute Key conforming to the
+ // "tls.client.hash.sha256" semantic conventions. It represents the certificate
+ // fingerprint using the SHA256 digest of DER-encoded version of certificate
+ // offered by the client. For consistency with other hash values, this value
+ // should be formatted as an uppercase hash.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "0687F666A054EF17A08E2F2162EAB4CBC0D265E1D7875BE74BF3C712CA92DAF0"
+ TLSClientHashSha256Key = attribute.Key("tls.client.hash.sha256")
+
+ // TLSClientIssuerKey is the attribute Key conforming to the "tls.client.issuer"
+ // semantic conventions. It represents the distinguished name of [subject] of
+ // the issuer of the x.509 certificate presented by the client.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "CN=Example Root CA, OU=Infrastructure Team, DC=example, DC=com"
+ //
+ // [subject]: https://datatracker.ietf.org/doc/html/rfc5280#section-4.1.2.6
+ TLSClientIssuerKey = attribute.Key("tls.client.issuer")
+
+ // TLSClientJa3Key is the attribute Key conforming to the "tls.client.ja3"
+ // semantic conventions. It represents a hash that identifies clients based on
+ // how they perform an SSL/TLS handshake.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "d4e5b18d6b55c71272893221c96ba240"
+ TLSClientJa3Key = attribute.Key("tls.client.ja3")
+
+ // TLSClientNotAfterKey is the attribute Key conforming to the
+ // "tls.client.not_after" semantic conventions. It represents the date/Time
+ // indicating when client certificate is no longer considered valid.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "2021-01-01T00:00:00.000Z"
+ TLSClientNotAfterKey = attribute.Key("tls.client.not_after")
+
+ // TLSClientNotBeforeKey is the attribute Key conforming to the
+ // "tls.client.not_before" semantic conventions. It represents the date/Time
+ // indicating when client certificate is first considered valid.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "1970-01-01T00:00:00.000Z"
+ TLSClientNotBeforeKey = attribute.Key("tls.client.not_before")
+
+ // TLSClientSubjectKey is the attribute Key conforming to the
+ // "tls.client.subject" semantic conventions. It represents the distinguished
+ // name of subject of the x.509 certificate presented by the client.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "CN=myclient, OU=Documentation Team, DC=example, DC=com"
+ TLSClientSubjectKey = attribute.Key("tls.client.subject")
+
+ // TLSClientSupportedCiphersKey is the attribute Key conforming to the
+ // "tls.client.supported_ciphers" semantic conventions. It represents the array
+ // of ciphers offered by the client during the client hello.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384",
+ // "TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384"
+ TLSClientSupportedCiphersKey = attribute.Key("tls.client.supported_ciphers")
+
+ // TLSCurveKey is the attribute Key conforming to the "tls.curve" semantic
+ // conventions. It represents the string indicating the curve used for the given
+ // cipher, when applicable.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "secp256r1"
+ TLSCurveKey = attribute.Key("tls.curve")
+
+ // TLSEstablishedKey is the attribute Key conforming to the "tls.established"
+ // semantic conventions. It represents the boolean flag indicating if the TLS
+ // negotiation was successful and transitioned to an encrypted tunnel.
+ //
+ // Type: boolean
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: true
+ TLSEstablishedKey = attribute.Key("tls.established")
+
+ // TLSNextProtocolKey is the attribute Key conforming to the "tls.next_protocol"
+ // semantic conventions. It represents the string indicating the protocol being
+ // tunneled. Per the values in the [IANA registry], this string should be lower
+ // case.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "http/1.1"
+ //
+ // [IANA registry]: https://www.iana.org/assignments/tls-extensiontype-values/tls-extensiontype-values.xhtml#alpn-protocol-ids
+ TLSNextProtocolKey = attribute.Key("tls.next_protocol")
+
+ // TLSProtocolNameKey is the attribute Key conforming to the "tls.protocol.name"
+ // semantic conventions. It represents the normalized lowercase protocol name
+ // parsed from original string of the negotiated [SSL/TLS protocol version].
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ //
+ // [SSL/TLS protocol version]: https://docs.openssl.org/1.1.1/man3/SSL_get_version/#return-values
+ TLSProtocolNameKey = attribute.Key("tls.protocol.name")
+
+ // TLSProtocolVersionKey is the attribute Key conforming to the
+ // "tls.protocol.version" semantic conventions. It represents the numeric part
+ // of the version parsed from the original string of the negotiated
+ // [SSL/TLS protocol version].
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "1.2", "3"
+ //
+ // [SSL/TLS protocol version]: https://docs.openssl.org/1.1.1/man3/SSL_get_version/#return-values
+ TLSProtocolVersionKey = attribute.Key("tls.protocol.version")
+
+ // TLSResumedKey is the attribute Key conforming to the "tls.resumed" semantic
+ // conventions. It represents the boolean flag indicating if this TLS connection
+ // was resumed from an existing TLS negotiation.
+ //
+ // Type: boolean
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: true
+ TLSResumedKey = attribute.Key("tls.resumed")
+
+ // TLSServerCertificateKey is the attribute Key conforming to the
+ // "tls.server.certificate" semantic conventions. It represents the PEM-encoded
+ // stand-alone certificate offered by the server. This is usually
+ // mutually-exclusive of `server.certificate_chain` since this value also exists
+ // in that list.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "MII..."
+ TLSServerCertificateKey = attribute.Key("tls.server.certificate")
+
+ // TLSServerCertificateChainKey is the attribute Key conforming to the
+ // "tls.server.certificate_chain" semantic conventions. It represents the array
+ // of PEM-encoded certificates that make up the certificate chain offered by the
+ // server. This is usually mutually-exclusive of `server.certificate` since that
+ // value should be the first certificate in the chain.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "MII...", "MI..."
+ TLSServerCertificateChainKey = attribute.Key("tls.server.certificate_chain")
+
+ // TLSServerHashMd5Key is the attribute Key conforming to the
+ // "tls.server.hash.md5" semantic conventions. It represents the certificate
+ // fingerprint using the MD5 digest of DER-encoded version of certificate
+ // offered by the server. For consistency with other hash values, this value
+ // should be formatted as an uppercase hash.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "0F76C7F2C55BFD7D8E8B8F4BFBF0C9EC"
+ TLSServerHashMd5Key = attribute.Key("tls.server.hash.md5")
+
+ // TLSServerHashSha1Key is the attribute Key conforming to the
+ // "tls.server.hash.sha1" semantic conventions. It represents the certificate
+ // fingerprint using the SHA1 digest of DER-encoded version of certificate
+ // offered by the server. For consistency with other hash values, this value
+ // should be formatted as an uppercase hash.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "9E393D93138888D288266C2D915214D1D1CCEB2A"
+ TLSServerHashSha1Key = attribute.Key("tls.server.hash.sha1")
+
+ // TLSServerHashSha256Key is the attribute Key conforming to the
+ // "tls.server.hash.sha256" semantic conventions. It represents the certificate
+ // fingerprint using the SHA256 digest of DER-encoded version of certificate
+ // offered by the server. For consistency with other hash values, this value
+ // should be formatted as an uppercase hash.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "0687F666A054EF17A08E2F2162EAB4CBC0D265E1D7875BE74BF3C712CA92DAF0"
+ TLSServerHashSha256Key = attribute.Key("tls.server.hash.sha256")
+
+ // TLSServerIssuerKey is the attribute Key conforming to the "tls.server.issuer"
+ // semantic conventions. It represents the distinguished name of [subject] of
+ // the issuer of the x.509 certificate presented by the client.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "CN=Example Root CA, OU=Infrastructure Team, DC=example, DC=com"
+ //
+ // [subject]: https://datatracker.ietf.org/doc/html/rfc5280#section-4.1.2.6
+ TLSServerIssuerKey = attribute.Key("tls.server.issuer")
+
+ // TLSServerJa3sKey is the attribute Key conforming to the "tls.server.ja3s"
+ // semantic conventions. It represents a hash that identifies servers based on
+ // how they perform an SSL/TLS handshake.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "d4e5b18d6b55c71272893221c96ba240"
+ TLSServerJa3sKey = attribute.Key("tls.server.ja3s")
+
+ // TLSServerNotAfterKey is the attribute Key conforming to the
+ // "tls.server.not_after" semantic conventions. It represents the date/Time
+ // indicating when server certificate is no longer considered valid.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "2021-01-01T00:00:00.000Z"
+ TLSServerNotAfterKey = attribute.Key("tls.server.not_after")
+
+ // TLSServerNotBeforeKey is the attribute Key conforming to the
+ // "tls.server.not_before" semantic conventions. It represents the date/Time
+ // indicating when server certificate is first considered valid.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "1970-01-01T00:00:00.000Z"
+ TLSServerNotBeforeKey = attribute.Key("tls.server.not_before")
+
+ // TLSServerSubjectKey is the attribute Key conforming to the
+ // "tls.server.subject" semantic conventions. It represents the distinguished
+ // name of subject of the x.509 certificate presented by the server.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "CN=myserver, OU=Documentation Team, DC=example, DC=com"
+ TLSServerSubjectKey = attribute.Key("tls.server.subject")
+)
+
+// TLSCipher returns an attribute KeyValue conforming to the "tls.cipher"
+// semantic conventions. It represents the string indicating the [cipher] used
+// during the current connection.
+//
+// [cipher]: https://datatracker.ietf.org/doc/html/rfc5246#appendix-A.5
+func TLSCipher(val string) attribute.KeyValue {
+ return TLSCipherKey.String(val)
+}
+
+// TLSClientCertificate returns an attribute KeyValue conforming to the
+// "tls.client.certificate" semantic conventions. It represents the PEM-encoded
+// stand-alone certificate offered by the client. This is usually
+// mutually-exclusive of `client.certificate_chain` since this value also exists
+// in that list.
+func TLSClientCertificate(val string) attribute.KeyValue {
+ return TLSClientCertificateKey.String(val)
+}
+
+// TLSClientCertificateChain returns an attribute KeyValue conforming to the
+// "tls.client.certificate_chain" semantic conventions. It represents the array
+// of PEM-encoded certificates that make up the certificate chain offered by the
+// client. This is usually mutually-exclusive of `client.certificate` since that
+// value should be the first certificate in the chain.
+func TLSClientCertificateChain(val ...string) attribute.KeyValue {
+ return TLSClientCertificateChainKey.StringSlice(val)
+}
+
+// TLSClientHashMd5 returns an attribute KeyValue conforming to the
+// "tls.client.hash.md5" semantic conventions. It represents the certificate
+// fingerprint using the MD5 digest of DER-encoded version of certificate offered
+// by the client. For consistency with other hash values, this value should be
+// formatted as an uppercase hash.
+func TLSClientHashMd5(val string) attribute.KeyValue {
+ return TLSClientHashMd5Key.String(val)
+}
+
+// TLSClientHashSha1 returns an attribute KeyValue conforming to the
+// "tls.client.hash.sha1" semantic conventions. It represents the certificate
+// fingerprint using the SHA1 digest of DER-encoded version of certificate
+// offered by the client. For consistency with other hash values, this value
+// should be formatted as an uppercase hash.
+func TLSClientHashSha1(val string) attribute.KeyValue {
+ return TLSClientHashSha1Key.String(val)
+}
+
+// TLSClientHashSha256 returns an attribute KeyValue conforming to the
+// "tls.client.hash.sha256" semantic conventions. It represents the certificate
+// fingerprint using the SHA256 digest of DER-encoded version of certificate
+// offered by the client. For consistency with other hash values, this value
+// should be formatted as an uppercase hash.
+func TLSClientHashSha256(val string) attribute.KeyValue {
+ return TLSClientHashSha256Key.String(val)
+}
+
+// TLSClientIssuer returns an attribute KeyValue conforming to the
+// "tls.client.issuer" semantic conventions. It represents the distinguished name
+// of [subject] of the issuer of the x.509 certificate presented by the client.
+//
+// [subject]: https://datatracker.ietf.org/doc/html/rfc5280#section-4.1.2.6
+func TLSClientIssuer(val string) attribute.KeyValue {
+ return TLSClientIssuerKey.String(val)
+}
+
+// TLSClientJa3 returns an attribute KeyValue conforming to the "tls.client.ja3"
+// semantic conventions. It represents a hash that identifies clients based on
+// how they perform an SSL/TLS handshake.
+func TLSClientJa3(val string) attribute.KeyValue {
+ return TLSClientJa3Key.String(val)
+}
+
+// TLSClientNotAfter returns an attribute KeyValue conforming to the
+// "tls.client.not_after" semantic conventions. It represents the date/Time
+// indicating when client certificate is no longer considered valid.
+func TLSClientNotAfter(val string) attribute.KeyValue {
+ return TLSClientNotAfterKey.String(val)
+}
+
+// TLSClientNotBefore returns an attribute KeyValue conforming to the
+// "tls.client.not_before" semantic conventions. It represents the date/Time
+// indicating when client certificate is first considered valid.
+func TLSClientNotBefore(val string) attribute.KeyValue {
+ return TLSClientNotBeforeKey.String(val)
+}
+
+// TLSClientSubject returns an attribute KeyValue conforming to the
+// "tls.client.subject" semantic conventions. It represents the distinguished
+// name of subject of the x.509 certificate presented by the client.
+func TLSClientSubject(val string) attribute.KeyValue {
+ return TLSClientSubjectKey.String(val)
+}
+
+// TLSClientSupportedCiphers returns an attribute KeyValue conforming to the
+// "tls.client.supported_ciphers" semantic conventions. It represents the array
+// of ciphers offered by the client during the client hello.
+func TLSClientSupportedCiphers(val ...string) attribute.KeyValue {
+ return TLSClientSupportedCiphersKey.StringSlice(val)
+}
+
+// TLSCurve returns an attribute KeyValue conforming to the "tls.curve" semantic
+// conventions. It represents the string indicating the curve used for the given
+// cipher, when applicable.
+func TLSCurve(val string) attribute.KeyValue {
+ return TLSCurveKey.String(val)
+}
+
+// TLSEstablished returns an attribute KeyValue conforming to the
+// "tls.established" semantic conventions. It represents the boolean flag
+// indicating if the TLS negotiation was successful and transitioned to an
+// encrypted tunnel.
+func TLSEstablished(val bool) attribute.KeyValue {
+ return TLSEstablishedKey.Bool(val)
+}
+
+// TLSNextProtocol returns an attribute KeyValue conforming to the
+// "tls.next_protocol" semantic conventions. It represents the string indicating
+// the protocol being tunneled. Per the values in the [IANA registry], this
+// string should be lower case.
+//
+// [IANA registry]: https://www.iana.org/assignments/tls-extensiontype-values/tls-extensiontype-values.xhtml#alpn-protocol-ids
+func TLSNextProtocol(val string) attribute.KeyValue {
+ return TLSNextProtocolKey.String(val)
+}
+
+// TLSProtocolVersion returns an attribute KeyValue conforming to the
+// "tls.protocol.version" semantic conventions. It represents the numeric part of
+// the version parsed from the original string of the negotiated
+// [SSL/TLS protocol version].
+//
+// [SSL/TLS protocol version]: https://docs.openssl.org/1.1.1/man3/SSL_get_version/#return-values
+func TLSProtocolVersion(val string) attribute.KeyValue {
+ return TLSProtocolVersionKey.String(val)
+}
+
+// TLSResumed returns an attribute KeyValue conforming to the "tls.resumed"
+// semantic conventions. It represents the boolean flag indicating if this TLS
+// connection was resumed from an existing TLS negotiation.
+func TLSResumed(val bool) attribute.KeyValue {
+ return TLSResumedKey.Bool(val)
+}
+
+// TLSServerCertificate returns an attribute KeyValue conforming to the
+// "tls.server.certificate" semantic conventions. It represents the PEM-encoded
+// stand-alone certificate offered by the server. This is usually
+// mutually-exclusive of `server.certificate_chain` since this value also exists
+// in that list.
+func TLSServerCertificate(val string) attribute.KeyValue {
+ return TLSServerCertificateKey.String(val)
+}
+
+// TLSServerCertificateChain returns an attribute KeyValue conforming to the
+// "tls.server.certificate_chain" semantic conventions. It represents the array
+// of PEM-encoded certificates that make up the certificate chain offered by the
+// server. This is usually mutually-exclusive of `server.certificate` since that
+// value should be the first certificate in the chain.
+func TLSServerCertificateChain(val ...string) attribute.KeyValue {
+ return TLSServerCertificateChainKey.StringSlice(val)
+}
+
+// TLSServerHashMd5 returns an attribute KeyValue conforming to the
+// "tls.server.hash.md5" semantic conventions. It represents the certificate
+// fingerprint using the MD5 digest of DER-encoded version of certificate offered
+// by the server. For consistency with other hash values, this value should be
+// formatted as an uppercase hash.
+func TLSServerHashMd5(val string) attribute.KeyValue {
+ return TLSServerHashMd5Key.String(val)
+}
+
+// TLSServerHashSha1 returns an attribute KeyValue conforming to the
+// "tls.server.hash.sha1" semantic conventions. It represents the certificate
+// fingerprint using the SHA1 digest of DER-encoded version of certificate
+// offered by the server. For consistency with other hash values, this value
+// should be formatted as an uppercase hash.
+func TLSServerHashSha1(val string) attribute.KeyValue {
+ return TLSServerHashSha1Key.String(val)
+}
+
+// TLSServerHashSha256 returns an attribute KeyValue conforming to the
+// "tls.server.hash.sha256" semantic conventions. It represents the certificate
+// fingerprint using the SHA256 digest of DER-encoded version of certificate
+// offered by the server. For consistency with other hash values, this value
+// should be formatted as an uppercase hash.
+func TLSServerHashSha256(val string) attribute.KeyValue {
+ return TLSServerHashSha256Key.String(val)
+}
+
+// TLSServerIssuer returns an attribute KeyValue conforming to the
+// "tls.server.issuer" semantic conventions. It represents the distinguished name
+// of [subject] of the issuer of the x.509 certificate presented by the client.
+//
+// [subject]: https://datatracker.ietf.org/doc/html/rfc5280#section-4.1.2.6
+func TLSServerIssuer(val string) attribute.KeyValue {
+ return TLSServerIssuerKey.String(val)
+}
+
+// TLSServerJa3s returns an attribute KeyValue conforming to the
+// "tls.server.ja3s" semantic conventions. It represents a hash that identifies
+// servers based on how they perform an SSL/TLS handshake.
+func TLSServerJa3s(val string) attribute.KeyValue {
+ return TLSServerJa3sKey.String(val)
+}
+
+// TLSServerNotAfter returns an attribute KeyValue conforming to the
+// "tls.server.not_after" semantic conventions. It represents the date/Time
+// indicating when server certificate is no longer considered valid.
+func TLSServerNotAfter(val string) attribute.KeyValue {
+ return TLSServerNotAfterKey.String(val)
+}
+
+// TLSServerNotBefore returns an attribute KeyValue conforming to the
+// "tls.server.not_before" semantic conventions. It represents the date/Time
+// indicating when server certificate is first considered valid.
+func TLSServerNotBefore(val string) attribute.KeyValue {
+ return TLSServerNotBeforeKey.String(val)
+}
+
+// TLSServerSubject returns an attribute KeyValue conforming to the
+// "tls.server.subject" semantic conventions. It represents the distinguished
+// name of subject of the x.509 certificate presented by the server.
+func TLSServerSubject(val string) attribute.KeyValue {
+ return TLSServerSubjectKey.String(val)
+}
+
+// Enum values for tls.protocol.name
+var (
+ // ssl
+ // Stability: development
+ TLSProtocolNameSsl = TLSProtocolNameKey.String("ssl")
+ // tls
+ // Stability: development
+ TLSProtocolNameTLS = TLSProtocolNameKey.String("tls")
+)
+
+// Namespace: url
+const (
+ // URLDomainKey is the attribute Key conforming to the "url.domain" semantic
+ // conventions. It represents the domain extracted from the `url.full`, such as
+ // "opentelemetry.io".
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "www.foo.bar", "opentelemetry.io", "3.12.167.2",
+ // "[1080:0:0:0:8:800:200C:417A]"
+ // Note: In some cases a URL may refer to an IP and/or port directly, without a
+ // domain name. In this case, the IP address would go to the domain field. If
+ // the URL contains a [literal IPv6 address] enclosed by `[` and `]`, the `[`
+ // and `]` characters should also be captured in the domain field.
+ //
+ // [literal IPv6 address]: https://www.rfc-editor.org/rfc/rfc2732#section-2
+ URLDomainKey = attribute.Key("url.domain")
+
+ // URLExtensionKey is the attribute Key conforming to the "url.extension"
+ // semantic conventions. It represents the file extension extracted from the
+ // `url.full`, excluding the leading dot.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "png", "gz"
+ // Note: The file extension is only set if it exists, as not every url has a
+ // file extension. When the file name has multiple extensions `example.tar.gz`,
+ // only the last one should be captured `gz`, not `tar.gz`.
+ URLExtensionKey = attribute.Key("url.extension")
+
+ // URLFragmentKey is the attribute Key conforming to the "url.fragment" semantic
+ // conventions. It represents the [URI fragment] component.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "SemConv"
+ //
+ // [URI fragment]: https://www.rfc-editor.org/rfc/rfc3986#section-3.5
+ URLFragmentKey = attribute.Key("url.fragment")
+
+ // URLFullKey is the attribute Key conforming to the "url.full" semantic
+ // conventions. It represents the absolute URL describing a network resource
+ // according to [RFC3986].
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "https://www.foo.bar/search?q=OpenTelemetry#SemConv", "//localhost"
+ // Note: For network calls, URL usually has
+ // `scheme://host[:port][path][?query][#fragment]` format, where the fragment
+ // is not transmitted over HTTP, but if it is known, it SHOULD be included
+ // nevertheless.
+ //
+ // `url.full` MUST NOT contain credentials passed via URL in form of
+ // `https://username:password@www.example.com/`.
+ // In such case username and password SHOULD be redacted and attribute's value
+ // SHOULD be `https://REDACTED:REDACTED@www.example.com/`.
+ //
+ // `url.full` SHOULD capture the absolute URL when it is available (or can be
+ // reconstructed).
+ //
+ // Sensitive content provided in `url.full` SHOULD be scrubbed when
+ // instrumentations can identify it.
+ //
+ //
+ // Query string values for the following keys SHOULD be redacted by default and
+ // replaced by the
+ // value `REDACTED`:
+ //
+ // - [`AWSAccessKeyId`]
+ // - [`Signature`]
+ // - [`sig`]
+ // - [`X-Goog-Signature`]
+ //
+ // This list is subject to change over time.
+ //
+ // When a query string value is redacted, the query string key SHOULD still be
+ // preserved, e.g.
+ // `https://www.example.com/path?color=blue&sig=REDACTED`.
+ //
+ // [RFC3986]: https://www.rfc-editor.org/rfc/rfc3986
+ // [`AWSAccessKeyId`]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/RESTAuthentication.html#RESTAuthenticationQueryStringAuth
+ // [`Signature`]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/RESTAuthentication.html#RESTAuthenticationQueryStringAuth
+ // [`sig`]: https://learn.microsoft.com/azure/storage/common/storage-sas-overview#sas-token
+ // [`X-Goog-Signature`]: https://cloud.google.com/storage/docs/access-control/signed-urls
+ URLFullKey = attribute.Key("url.full")
+
+ // URLOriginalKey is the attribute Key conforming to the "url.original" semantic
+ // conventions. It represents the unmodified original URL as seen in the event
+ // source.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "https://www.foo.bar/search?q=OpenTelemetry#SemConv",
+ // "search?q=OpenTelemetry"
+ // Note: In network monitoring, the observed URL may be a full URL, whereas in
+ // access logs, the URL is often just represented as a path. This field is meant
+ // to represent the URL as it was observed, complete or not.
+ // `url.original` might contain credentials passed via URL in form of
+ // `https://username:password@www.example.com/`. In such case password and
+ // username SHOULD NOT be redacted and attribute's value SHOULD remain the same.
+ URLOriginalKey = attribute.Key("url.original")
+
+ // URLPathKey is the attribute Key conforming to the "url.path" semantic
+ // conventions. It represents the [URI path] component.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "/search"
+ // Note: Sensitive content provided in `url.path` SHOULD be scrubbed when
+ // instrumentations can identify it.
+ //
+ // [URI path]: https://www.rfc-editor.org/rfc/rfc3986#section-3.3
+ URLPathKey = attribute.Key("url.path")
+
+ // URLPortKey is the attribute Key conforming to the "url.port" semantic
+ // conventions. It represents the port extracted from the `url.full`.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 443
+ URLPortKey = attribute.Key("url.port")
+
+ // URLQueryKey is the attribute Key conforming to the "url.query" semantic
+ // conventions. It represents the [URI query] component.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "q=OpenTelemetry"
+ // Note: Sensitive content provided in `url.query` SHOULD be scrubbed when
+ // instrumentations can identify it.
+ //
+ //
+ // Query string values for the following keys SHOULD be redacted by default and
+ // replaced by the value `REDACTED`:
+ //
+ // - [`AWSAccessKeyId`]
+ // - [`Signature`]
+ // - [`sig`]
+ // - [`X-Goog-Signature`]
+ //
+ // This list is subject to change over time.
+ //
+ // When a query string value is redacted, the query string key SHOULD still be
+ // preserved, e.g.
+ // `q=OpenTelemetry&sig=REDACTED`.
+ //
+ // [URI query]: https://www.rfc-editor.org/rfc/rfc3986#section-3.4
+ // [`AWSAccessKeyId`]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/RESTAuthentication.html#RESTAuthenticationQueryStringAuth
+ // [`Signature`]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/RESTAuthentication.html#RESTAuthenticationQueryStringAuth
+ // [`sig`]: https://learn.microsoft.com/azure/storage/common/storage-sas-overview#sas-token
+ // [`X-Goog-Signature`]: https://cloud.google.com/storage/docs/access-control/signed-urls
+ URLQueryKey = attribute.Key("url.query")
+
+ // URLRegisteredDomainKey is the attribute Key conforming to the
+ // "url.registered_domain" semantic conventions. It represents the highest
+ // registered url domain, stripped of the subdomain.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "example.com", "foo.co.uk"
+ // Note: This value can be determined precisely with the [public suffix list].
+ // For example, the registered domain for `foo.example.com` is `example.com`.
+ // Trying to approximate this by simply taking the last two labels will not work
+ // well for TLDs such as `co.uk`.
+ //
+ // [public suffix list]: https://publicsuffix.org/
+ URLRegisteredDomainKey = attribute.Key("url.registered_domain")
+
+ // URLSchemeKey is the attribute Key conforming to the "url.scheme" semantic
+ // conventions. It represents the [URI scheme] component identifying the used
+ // protocol.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "https", "ftp", "telnet"
+ //
+ // [URI scheme]: https://www.rfc-editor.org/rfc/rfc3986#section-3.1
+ URLSchemeKey = attribute.Key("url.scheme")
+
+ // URLSubdomainKey is the attribute Key conforming to the "url.subdomain"
+ // semantic conventions. It represents the subdomain portion of a fully
+ // qualified domain name includes all of the names except the host name under
+ // the registered_domain. In a partially qualified domain, or if the
+ // qualification level of the full name cannot be determined, subdomain contains
+ // all of the names below the registered domain.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "east", "sub2.sub1"
+ // Note: The subdomain portion of `www.east.mydomain.co.uk` is `east`. If the
+ // domain has multiple levels of subdomain, such as `sub2.sub1.example.com`, the
+ // subdomain field should contain `sub2.sub1`, with no trailing period.
+ URLSubdomainKey = attribute.Key("url.subdomain")
+
+ // URLTemplateKey is the attribute Key conforming to the "url.template" semantic
+ // conventions. It represents the low-cardinality template of an
+ // [absolute path reference].
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "/users/{id}", "/users/:id", "/users?id={id}"
+ //
+ // [absolute path reference]: https://www.rfc-editor.org/rfc/rfc3986#section-4.2
+ URLTemplateKey = attribute.Key("url.template")
+
+ // URLTopLevelDomainKey is the attribute Key conforming to the
+ // "url.top_level_domain" semantic conventions. It represents the effective top
+ // level domain (eTLD), also known as the domain suffix, is the last part of the
+ // domain name. For example, the top level domain for example.com is `com`.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "com", "co.uk"
+ // Note: This value can be determined precisely with the [public suffix list].
+ //
+ // [public suffix list]: https://publicsuffix.org/
+ URLTopLevelDomainKey = attribute.Key("url.top_level_domain")
+)
+
+// URLDomain returns an attribute KeyValue conforming to the "url.domain"
+// semantic conventions. It represents the domain extracted from the `url.full`,
+// such as "opentelemetry.io".
+func URLDomain(val string) attribute.KeyValue {
+ return URLDomainKey.String(val)
+}
+
+// URLExtension returns an attribute KeyValue conforming to the "url.extension"
+// semantic conventions. It represents the file extension extracted from the
+// `url.full`, excluding the leading dot.
+func URLExtension(val string) attribute.KeyValue {
+ return URLExtensionKey.String(val)
+}
+
+// URLFragment returns an attribute KeyValue conforming to the "url.fragment"
+// semantic conventions. It represents the [URI fragment] component.
+//
+// [URI fragment]: https://www.rfc-editor.org/rfc/rfc3986#section-3.5
+func URLFragment(val string) attribute.KeyValue {
+ return URLFragmentKey.String(val)
+}
+
+// URLFull returns an attribute KeyValue conforming to the "url.full" semantic
+// conventions. It represents the absolute URL describing a network resource
+// according to [RFC3986].
+//
+// [RFC3986]: https://www.rfc-editor.org/rfc/rfc3986
+func URLFull(val string) attribute.KeyValue {
+ return URLFullKey.String(val)
+}
+
+// URLOriginal returns an attribute KeyValue conforming to the "url.original"
+// semantic conventions. It represents the unmodified original URL as seen in the
+// event source.
+func URLOriginal(val string) attribute.KeyValue {
+ return URLOriginalKey.String(val)
+}
+
+// URLPath returns an attribute KeyValue conforming to the "url.path" semantic
+// conventions. It represents the [URI path] component.
+//
+// [URI path]: https://www.rfc-editor.org/rfc/rfc3986#section-3.3
+func URLPath(val string) attribute.KeyValue {
+ return URLPathKey.String(val)
+}
+
+// URLPort returns an attribute KeyValue conforming to the "url.port" semantic
+// conventions. It represents the port extracted from the `url.full`.
+func URLPort(val int) attribute.KeyValue {
+ return URLPortKey.Int(val)
+}
+
+// URLQuery returns an attribute KeyValue conforming to the "url.query" semantic
+// conventions. It represents the [URI query] component.
+//
+// [URI query]: https://www.rfc-editor.org/rfc/rfc3986#section-3.4
+func URLQuery(val string) attribute.KeyValue {
+ return URLQueryKey.String(val)
+}
+
+// URLRegisteredDomain returns an attribute KeyValue conforming to the
+// "url.registered_domain" semantic conventions. It represents the highest
+// registered url domain, stripped of the subdomain.
+func URLRegisteredDomain(val string) attribute.KeyValue {
+ return URLRegisteredDomainKey.String(val)
+}
+
+// URLScheme returns an attribute KeyValue conforming to the "url.scheme"
+// semantic conventions. It represents the [URI scheme] component identifying the
+// used protocol.
+//
+// [URI scheme]: https://www.rfc-editor.org/rfc/rfc3986#section-3.1
+func URLScheme(val string) attribute.KeyValue {
+ return URLSchemeKey.String(val)
+}
+
+// URLSubdomain returns an attribute KeyValue conforming to the "url.subdomain"
+// semantic conventions. It represents the subdomain portion of a fully qualified
+// domain name includes all of the names except the host name under the
+// registered_domain. In a partially qualified domain, or if the qualification
+// level of the full name cannot be determined, subdomain contains all of the
+// names below the registered domain.
+func URLSubdomain(val string) attribute.KeyValue {
+ return URLSubdomainKey.String(val)
+}
+
+// URLTemplate returns an attribute KeyValue conforming to the "url.template"
+// semantic conventions. It represents the low-cardinality template of an
+// [absolute path reference].
+//
+// [absolute path reference]: https://www.rfc-editor.org/rfc/rfc3986#section-4.2
+func URLTemplate(val string) attribute.KeyValue {
+ return URLTemplateKey.String(val)
+}
+
+// URLTopLevelDomain returns an attribute KeyValue conforming to the
+// "url.top_level_domain" semantic conventions. It represents the effective top
+// level domain (eTLD), also known as the domain suffix, is the last part of the
+// domain name. For example, the top level domain for example.com is `com`.
+func URLTopLevelDomain(val string) attribute.KeyValue {
+ return URLTopLevelDomainKey.String(val)
+}
+
+// Namespace: user
+const (
+ // UserEmailKey is the attribute Key conforming to the "user.email" semantic
+ // conventions. It represents the user email address.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "a.einstein@example.com"
+ UserEmailKey = attribute.Key("user.email")
+
+ // UserFullNameKey is the attribute Key conforming to the "user.full_name"
+ // semantic conventions. It represents the user's full name.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Albert Einstein"
+ UserFullNameKey = attribute.Key("user.full_name")
+
+ // UserHashKey is the attribute Key conforming to the "user.hash" semantic
+ // conventions. It represents the unique user hash to correlate information for
+ // a user in anonymized form.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "364fc68eaf4c8acec74a4e52d7d1feaa"
+ // Note: Useful if `user.id` or `user.name` contain confidential information and
+ // cannot be used.
+ UserHashKey = attribute.Key("user.hash")
+
+ // UserIDKey is the attribute Key conforming to the "user.id" semantic
+ // conventions. It represents the unique identifier of the user.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "S-1-5-21-202424912787-2692429404-2351956786-1000"
+ UserIDKey = attribute.Key("user.id")
+
+ // UserNameKey is the attribute Key conforming to the "user.name" semantic
+ // conventions. It represents the short name or login/username of the user.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "a.einstein"
+ UserNameKey = attribute.Key("user.name")
+
+ // UserRolesKey is the attribute Key conforming to the "user.roles" semantic
+ // conventions. It represents the array of user roles at the time of the event.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "admin", "reporting_user"
+ UserRolesKey = attribute.Key("user.roles")
+)
+
+// UserEmail returns an attribute KeyValue conforming to the "user.email"
+// semantic conventions. It represents the user email address.
+func UserEmail(val string) attribute.KeyValue {
+ return UserEmailKey.String(val)
+}
+
+// UserFullName returns an attribute KeyValue conforming to the "user.full_name"
+// semantic conventions. It represents the user's full name.
+func UserFullName(val string) attribute.KeyValue {
+ return UserFullNameKey.String(val)
+}
+
+// UserHash returns an attribute KeyValue conforming to the "user.hash" semantic
+// conventions. It represents the unique user hash to correlate information for a
+// user in anonymized form.
+func UserHash(val string) attribute.KeyValue {
+ return UserHashKey.String(val)
+}
+
+// UserID returns an attribute KeyValue conforming to the "user.id" semantic
+// conventions. It represents the unique identifier of the user.
+func UserID(val string) attribute.KeyValue {
+ return UserIDKey.String(val)
+}
+
+// UserName returns an attribute KeyValue conforming to the "user.name" semantic
+// conventions. It represents the short name or login/username of the user.
+func UserName(val string) attribute.KeyValue {
+ return UserNameKey.String(val)
+}
+
+// UserRoles returns an attribute KeyValue conforming to the "user.roles"
+// semantic conventions. It represents the array of user roles at the time of the
+// event.
+func UserRoles(val ...string) attribute.KeyValue {
+ return UserRolesKey.StringSlice(val)
+}
+
+// Namespace: user_agent
+const (
+ // UserAgentNameKey is the attribute Key conforming to the "user_agent.name"
+ // semantic conventions. It represents the name of the user-agent extracted from
+ // original. Usually refers to the browser's name.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Safari", "YourApp"
+ // Note: [Example] of extracting browser's name from original string. In the
+ // case of using a user-agent for non-browser products, such as microservices
+ // with multiple names/versions inside the `user_agent.original`, the most
+ // significant name SHOULD be selected. In such a scenario it should align with
+ // `user_agent.version`
+ //
+ // [Example]: https://www.whatsmyua.info
+ UserAgentNameKey = attribute.Key("user_agent.name")
+
+ // UserAgentOriginalKey is the attribute Key conforming to the
+ // "user_agent.original" semantic conventions. It represents the value of the
+ // [HTTP User-Agent] header sent by the client.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "CERN-LineMode/2.15 libwww/2.17b3", "Mozilla/5.0 (iPhone; CPU
+ // iPhone OS 14_7_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko)
+ // Version/14.1.2 Mobile/15E148 Safari/604.1", "YourApp/1.0.0
+ // grpc-java-okhttp/1.27.2"
+ //
+ // [HTTP User-Agent]: https://www.rfc-editor.org/rfc/rfc9110.html#field.user-agent
+ UserAgentOriginalKey = attribute.Key("user_agent.original")
+
+ // UserAgentOSNameKey is the attribute Key conforming to the
+ // "user_agent.os.name" semantic conventions. It represents the human readable
+ // operating system name.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "iOS", "Android", "Ubuntu"
+ // Note: For mapping user agent strings to OS names, libraries such as
+ // [ua-parser] can be utilized.
+ //
+ // [ua-parser]: https://github.com/ua-parser
+ UserAgentOSNameKey = attribute.Key("user_agent.os.name")
+
+ // UserAgentOSVersionKey is the attribute Key conforming to the
+ // "user_agent.os.version" semantic conventions. It represents the version
+ // string of the operating system as defined in [Version Attributes].
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "14.2.1", "18.04.1"
+ // Note: For mapping user agent strings to OS versions, libraries such as
+ // [ua-parser] can be utilized.
+ //
+ // [Version Attributes]: /docs/resource/README.md#version-attributes
+ // [ua-parser]: https://github.com/ua-parser
+ UserAgentOSVersionKey = attribute.Key("user_agent.os.version")
+
+ // UserAgentSyntheticTypeKey is the attribute Key conforming to the
+ // "user_agent.synthetic.type" semantic conventions. It represents the specifies
+ // the category of synthetic traffic, such as tests or bots.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // Note: This attribute MAY be derived from the contents of the
+ // `user_agent.original` attribute. Components that populate the attribute are
+ // responsible for determining what they consider to be synthetic bot or test
+ // traffic. This attribute can either be set for self-identification purposes,
+ // or on telemetry detected to be generated as a result of a synthetic request.
+ // This attribute is useful for distinguishing between genuine client traffic
+ // and synthetic traffic generated by bots or tests.
+ UserAgentSyntheticTypeKey = attribute.Key("user_agent.synthetic.type")
+
+ // UserAgentVersionKey is the attribute Key conforming to the
+ // "user_agent.version" semantic conventions. It represents the version of the
+ // user-agent extracted from original. Usually refers to the browser's version.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "14.1.2", "1.0.0"
+ // Note: [Example] of extracting browser's version from original string. In the
+ // case of using a user-agent for non-browser products, such as microservices
+ // with multiple names/versions inside the `user_agent.original`, the most
+ // significant version SHOULD be selected. In such a scenario it should align
+ // with `user_agent.name`
+ //
+ // [Example]: https://www.whatsmyua.info
+ UserAgentVersionKey = attribute.Key("user_agent.version")
+)
+
+// UserAgentName returns an attribute KeyValue conforming to the
+// "user_agent.name" semantic conventions. It represents the name of the
+// user-agent extracted from original. Usually refers to the browser's name.
+func UserAgentName(val string) attribute.KeyValue {
+ return UserAgentNameKey.String(val)
+}
+
+// UserAgentOriginal returns an attribute KeyValue conforming to the
+// "user_agent.original" semantic conventions. It represents the value of the
+// [HTTP User-Agent] header sent by the client.
+//
+// [HTTP User-Agent]: https://www.rfc-editor.org/rfc/rfc9110.html#field.user-agent
+func UserAgentOriginal(val string) attribute.KeyValue {
+ return UserAgentOriginalKey.String(val)
+}
+
+// UserAgentOSName returns an attribute KeyValue conforming to the
+// "user_agent.os.name" semantic conventions. It represents the human readable
+// operating system name.
+func UserAgentOSName(val string) attribute.KeyValue {
+ return UserAgentOSNameKey.String(val)
+}
+
+// UserAgentOSVersion returns an attribute KeyValue conforming to the
+// "user_agent.os.version" semantic conventions. It represents the version string
+// of the operating system as defined in [Version Attributes].
+//
+// [Version Attributes]: /docs/resource/README.md#version-attributes
+func UserAgentOSVersion(val string) attribute.KeyValue {
+ return UserAgentOSVersionKey.String(val)
+}
+
+// UserAgentVersion returns an attribute KeyValue conforming to the
+// "user_agent.version" semantic conventions. It represents the version of the
+// user-agent extracted from original. Usually refers to the browser's version.
+func UserAgentVersion(val string) attribute.KeyValue {
+ return UserAgentVersionKey.String(val)
+}
+
+// Enum values for user_agent.synthetic.type
+var (
+ // Bot source.
+ // Stability: development
+ UserAgentSyntheticTypeBot = UserAgentSyntheticTypeKey.String("bot")
+ // Synthetic test source.
+ // Stability: development
+ UserAgentSyntheticTypeTest = UserAgentSyntheticTypeKey.String("test")
+)
+
+// Namespace: vcs
+const (
+ // VCSChangeIDKey is the attribute Key conforming to the "vcs.change.id"
+ // semantic conventions. It represents the ID of the change (pull request/merge
+ // request/changelist) if applicable. This is usually a unique (within
+ // repository) identifier generated by the VCS system.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "123"
+ VCSChangeIDKey = attribute.Key("vcs.change.id")
+
+ // VCSChangeStateKey is the attribute Key conforming to the "vcs.change.state"
+ // semantic conventions. It represents the state of the change (pull
+ // request/merge request/changelist).
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "open", "closed", "merged"
+ VCSChangeStateKey = attribute.Key("vcs.change.state")
+
+ // VCSChangeTitleKey is the attribute Key conforming to the "vcs.change.title"
+ // semantic conventions. It represents the human readable title of the change
+ // (pull request/merge request/changelist). This title is often a brief summary
+ // of the change and may get merged in to a ref as the commit summary.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Fixes broken thing", "feat: add my new feature", "[chore] update
+ // dependency"
+ VCSChangeTitleKey = attribute.Key("vcs.change.title")
+
+ // VCSLineChangeTypeKey is the attribute Key conforming to the
+ // "vcs.line_change.type" semantic conventions. It represents the type of line
+ // change being measured on a branch or change.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "added", "removed"
+ VCSLineChangeTypeKey = attribute.Key("vcs.line_change.type")
+
+ // VCSOwnerNameKey is the attribute Key conforming to the "vcs.owner.name"
+ // semantic conventions. It represents the group owner within the version
+ // control system.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "my-org", "myteam", "business-unit"
+ VCSOwnerNameKey = attribute.Key("vcs.owner.name")
+
+ // VCSProviderNameKey is the attribute Key conforming to the "vcs.provider.name"
+ // semantic conventions. It represents the name of the version control system
+ // provider.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "github", "gitlab", "gitea", "bitbucket"
+ VCSProviderNameKey = attribute.Key("vcs.provider.name")
+
+ // VCSRefBaseNameKey is the attribute Key conforming to the "vcs.ref.base.name"
+ // semantic conventions. It represents the name of the [reference] such as
+ // **branch** or **tag** in the repository.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "my-feature-branch", "tag-1-test"
+ // Note: `base` refers to the starting point of a change. For example, `main`
+ // would be the base reference of type branch if you've created a new
+ // reference of type branch from it and created new commits.
+ //
+ // [reference]: https://git-scm.com/docs/gitglossary#def_ref
+ VCSRefBaseNameKey = attribute.Key("vcs.ref.base.name")
+
+ // VCSRefBaseRevisionKey is the attribute Key conforming to the
+ // "vcs.ref.base.revision" semantic conventions. It represents the revision,
+ // literally [revised version], The revision most often refers to a commit
+ // object in Git, or a revision number in SVN.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "9d59409acf479dfa0df1aa568182e43e43df8bbe28d60fcf2bc52e30068802cc",
+ // "main", "123", "HEAD"
+ // Note: `base` refers to the starting point of a change. For example, `main`
+ // would be the base reference of type branch if you've created a new
+ // reference of type branch from it and created new commits. The
+ // revision can be a full [hash value (see
+ // glossary)],
+ // of the recorded change to a ref within a repository pointing to a
+ // commit [commit] object. It does
+ // not necessarily have to be a hash; it can simply define a [revision
+ // number]
+ // which is an integer that is monotonically increasing. In cases where
+ // it is identical to the `ref.base.name`, it SHOULD still be included.
+ // It is up to the implementer to decide which value to set as the
+ // revision based on the VCS system and situational context.
+ //
+ // [revised version]: https://www.merriam-webster.com/dictionary/revision
+ // [hash value (see
+ // glossary)]: https://nvlpubs.nist.gov/nistpubs/FIPS/NIST.FIPS.186-5.pdf
+ // [commit]: https://git-scm.com/docs/git-commit
+ // [revision
+ // number]: https://svnbook.red-bean.com/en/1.7/svn.tour.revs.specifiers.html
+ VCSRefBaseRevisionKey = attribute.Key("vcs.ref.base.revision")
+
+ // VCSRefBaseTypeKey is the attribute Key conforming to the "vcs.ref.base.type"
+ // semantic conventions. It represents the type of the [reference] in the
+ // repository.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "branch", "tag"
+ // Note: `base` refers to the starting point of a change. For example, `main`
+ // would be the base reference of type branch if you've created a new
+ // reference of type branch from it and created new commits.
+ //
+ // [reference]: https://git-scm.com/docs/gitglossary#def_ref
+ VCSRefBaseTypeKey = attribute.Key("vcs.ref.base.type")
+
+ // VCSRefHeadNameKey is the attribute Key conforming to the "vcs.ref.head.name"
+ // semantic conventions. It represents the name of the [reference] such as
+ // **branch** or **tag** in the repository.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "my-feature-branch", "tag-1-test"
+ // Note: `head` refers to where you are right now; the current reference at a
+ // given time.
+ //
+ // [reference]: https://git-scm.com/docs/gitglossary#def_ref
+ VCSRefHeadNameKey = attribute.Key("vcs.ref.head.name")
+
+ // VCSRefHeadRevisionKey is the attribute Key conforming to the
+ // "vcs.ref.head.revision" semantic conventions. It represents the revision,
+ // literally [revised version], The revision most often refers to a commit
+ // object in Git, or a revision number in SVN.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "9d59409acf479dfa0df1aa568182e43e43df8bbe28d60fcf2bc52e30068802cc",
+ // "main", "123", "HEAD"
+ // Note: `head` refers to where you are right now; the current reference at a
+ // given time.The revision can be a full [hash value (see
+ // glossary)],
+ // of the recorded change to a ref within a repository pointing to a
+ // commit [commit] object. It does
+ // not necessarily have to be a hash; it can simply define a [revision
+ // number]
+ // which is an integer that is monotonically increasing. In cases where
+ // it is identical to the `ref.head.name`, it SHOULD still be included.
+ // It is up to the implementer to decide which value to set as the
+ // revision based on the VCS system and situational context.
+ //
+ // [revised version]: https://www.merriam-webster.com/dictionary/revision
+ // [hash value (see
+ // glossary)]: https://nvlpubs.nist.gov/nistpubs/FIPS/NIST.FIPS.186-5.pdf
+ // [commit]: https://git-scm.com/docs/git-commit
+ // [revision
+ // number]: https://svnbook.red-bean.com/en/1.7/svn.tour.revs.specifiers.html
+ VCSRefHeadRevisionKey = attribute.Key("vcs.ref.head.revision")
+
+ // VCSRefHeadTypeKey is the attribute Key conforming to the "vcs.ref.head.type"
+ // semantic conventions. It represents the type of the [reference] in the
+ // repository.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "branch", "tag"
+ // Note: `head` refers to where you are right now; the current reference at a
+ // given time.
+ //
+ // [reference]: https://git-scm.com/docs/gitglossary#def_ref
+ VCSRefHeadTypeKey = attribute.Key("vcs.ref.head.type")
+
+ // VCSRefTypeKey is the attribute Key conforming to the "vcs.ref.type" semantic
+ // conventions. It represents the type of the [reference] in the repository.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "branch", "tag"
+ //
+ // [reference]: https://git-scm.com/docs/gitglossary#def_ref
+ VCSRefTypeKey = attribute.Key("vcs.ref.type")
+
+ // VCSRepositoryNameKey is the attribute Key conforming to the
+ // "vcs.repository.name" semantic conventions. It represents the human readable
+ // name of the repository. It SHOULD NOT include any additional identifier like
+ // Group/SubGroup in GitLab or organization in GitHub.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "semantic-conventions", "my-cool-repo"
+ // Note: Due to it only being the name, it can clash with forks of the same
+ // repository if collecting telemetry across multiple orgs or groups in
+ // the same backends.
+ VCSRepositoryNameKey = attribute.Key("vcs.repository.name")
+
+ // VCSRepositoryURLFullKey is the attribute Key conforming to the
+ // "vcs.repository.url.full" semantic conventions. It represents the
+ // [canonical URL] of the repository providing the complete HTTP(S) address in
+ // order to locate and identify the repository through a browser.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // "https://github.com/opentelemetry/open-telemetry-collector-contrib",
+ // "https://gitlab.com/my-org/my-project/my-projects-project/repo"
+ // Note: In Git Version Control Systems, the canonical URL SHOULD NOT include
+ // the `.git` extension.
+ //
+ // [canonical URL]: https://support.google.com/webmasters/answer/10347851?hl=en#:~:text=A%20canonical%20URL%20is%20the,Google%20chooses%20one%20as%20canonical.
+ VCSRepositoryURLFullKey = attribute.Key("vcs.repository.url.full")
+
+ // VCSRevisionDeltaDirectionKey is the attribute Key conforming to the
+ // "vcs.revision_delta.direction" semantic conventions. It represents the type
+ // of revision comparison.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "ahead", "behind"
+ VCSRevisionDeltaDirectionKey = attribute.Key("vcs.revision_delta.direction")
+)
+
+// VCSChangeID returns an attribute KeyValue conforming to the "vcs.change.id"
+// semantic conventions. It represents the ID of the change (pull request/merge
+// request/changelist) if applicable. This is usually a unique (within
+// repository) identifier generated by the VCS system.
+func VCSChangeID(val string) attribute.KeyValue {
+ return VCSChangeIDKey.String(val)
+}
+
+// VCSChangeTitle returns an attribute KeyValue conforming to the
+// "vcs.change.title" semantic conventions. It represents the human readable
+// title of the change (pull request/merge request/changelist). This title is
+// often a brief summary of the change and may get merged in to a ref as the
+// commit summary.
+func VCSChangeTitle(val string) attribute.KeyValue {
+ return VCSChangeTitleKey.String(val)
+}
+
+// VCSOwnerName returns an attribute KeyValue conforming to the "vcs.owner.name"
+// semantic conventions. It represents the group owner within the version control
+// system.
+func VCSOwnerName(val string) attribute.KeyValue {
+ return VCSOwnerNameKey.String(val)
+}
+
+// VCSRefBaseName returns an attribute KeyValue conforming to the
+// "vcs.ref.base.name" semantic conventions. It represents the name of the
+// [reference] such as **branch** or **tag** in the repository.
+//
+// [reference]: https://git-scm.com/docs/gitglossary#def_ref
+func VCSRefBaseName(val string) attribute.KeyValue {
+ return VCSRefBaseNameKey.String(val)
+}
+
+// VCSRefBaseRevision returns an attribute KeyValue conforming to the
+// "vcs.ref.base.revision" semantic conventions. It represents the revision,
+// literally [revised version], The revision most often refers to a commit object
+// in Git, or a revision number in SVN.
+//
+// [revised version]: https://www.merriam-webster.com/dictionary/revision
+func VCSRefBaseRevision(val string) attribute.KeyValue {
+ return VCSRefBaseRevisionKey.String(val)
+}
+
+// VCSRefHeadName returns an attribute KeyValue conforming to the
+// "vcs.ref.head.name" semantic conventions. It represents the name of the
+// [reference] such as **branch** or **tag** in the repository.
+//
+// [reference]: https://git-scm.com/docs/gitglossary#def_ref
+func VCSRefHeadName(val string) attribute.KeyValue {
+ return VCSRefHeadNameKey.String(val)
+}
+
+// VCSRefHeadRevision returns an attribute KeyValue conforming to the
+// "vcs.ref.head.revision" semantic conventions. It represents the revision,
+// literally [revised version], The revision most often refers to a commit object
+// in Git, or a revision number in SVN.
+//
+// [revised version]: https://www.merriam-webster.com/dictionary/revision
+func VCSRefHeadRevision(val string) attribute.KeyValue {
+ return VCSRefHeadRevisionKey.String(val)
+}
+
+// VCSRepositoryName returns an attribute KeyValue conforming to the
+// "vcs.repository.name" semantic conventions. It represents the human readable
+// name of the repository. It SHOULD NOT include any additional identifier like
+// Group/SubGroup in GitLab or organization in GitHub.
+func VCSRepositoryName(val string) attribute.KeyValue {
+ return VCSRepositoryNameKey.String(val)
+}
+
+// VCSRepositoryURLFull returns an attribute KeyValue conforming to the
+// "vcs.repository.url.full" semantic conventions. It represents the
+// [canonical URL] of the repository providing the complete HTTP(S) address in
+// order to locate and identify the repository through a browser.
+//
+// [canonical URL]: https://support.google.com/webmasters/answer/10347851?hl=en#:~:text=A%20canonical%20URL%20is%20the,Google%20chooses%20one%20as%20canonical.
+func VCSRepositoryURLFull(val string) attribute.KeyValue {
+ return VCSRepositoryURLFullKey.String(val)
+}
+
+// Enum values for vcs.change.state
+var (
+ // Open means the change is currently active and under review. It hasn't been
+ // merged into the target branch yet, and it's still possible to make changes or
+ // add comments.
+ // Stability: development
+ VCSChangeStateOpen = VCSChangeStateKey.String("open")
+ // WIP (work-in-progress, draft) means the change is still in progress and not
+ // yet ready for a full review. It might still undergo significant changes.
+ // Stability: development
+ VCSChangeStateWip = VCSChangeStateKey.String("wip")
+ // Closed means the merge request has been closed without merging. This can
+ // happen for various reasons, such as the changes being deemed unnecessary, the
+ // issue being resolved in another way, or the author deciding to withdraw the
+ // request.
+ // Stability: development
+ VCSChangeStateClosed = VCSChangeStateKey.String("closed")
+ // Merged indicates that the change has been successfully integrated into the
+ // target codebase.
+ // Stability: development
+ VCSChangeStateMerged = VCSChangeStateKey.String("merged")
+)
+
+// Enum values for vcs.line_change.type
+var (
+ // How many lines were added.
+ // Stability: development
+ VCSLineChangeTypeAdded = VCSLineChangeTypeKey.String("added")
+ // How many lines were removed.
+ // Stability: development
+ VCSLineChangeTypeRemoved = VCSLineChangeTypeKey.String("removed")
+)
+
+// Enum values for vcs.provider.name
+var (
+ // [GitHub]
+ // Stability: development
+ //
+ // [GitHub]: https://github.com
+ VCSProviderNameGithub = VCSProviderNameKey.String("github")
+ // [GitLab]
+ // Stability: development
+ //
+ // [GitLab]: https://gitlab.com
+ VCSProviderNameGitlab = VCSProviderNameKey.String("gitlab")
+ // [Gitea]
+ // Stability: development
+ //
+ // [Gitea]: https://gitea.io
+ VCSProviderNameGitea = VCSProviderNameKey.String("gitea")
+ // [Bitbucket]
+ // Stability: development
+ //
+ // [Bitbucket]: https://bitbucket.org
+ VCSProviderNameBitbucket = VCSProviderNameKey.String("bitbucket")
+)
+
+// Enum values for vcs.ref.base.type
+var (
+ // [branch]
+ // Stability: development
+ //
+ // [branch]: https://git-scm.com/docs/gitglossary#Documentation/gitglossary.txt-aiddefbranchabranch
+ VCSRefBaseTypeBranch = VCSRefBaseTypeKey.String("branch")
+ // [tag]
+ // Stability: development
+ //
+ // [tag]: https://git-scm.com/docs/gitglossary#Documentation/gitglossary.txt-aiddeftagatag
+ VCSRefBaseTypeTag = VCSRefBaseTypeKey.String("tag")
+)
+
+// Enum values for vcs.ref.head.type
+var (
+ // [branch]
+ // Stability: development
+ //
+ // [branch]: https://git-scm.com/docs/gitglossary#Documentation/gitglossary.txt-aiddefbranchabranch
+ VCSRefHeadTypeBranch = VCSRefHeadTypeKey.String("branch")
+ // [tag]
+ // Stability: development
+ //
+ // [tag]: https://git-scm.com/docs/gitglossary#Documentation/gitglossary.txt-aiddeftagatag
+ VCSRefHeadTypeTag = VCSRefHeadTypeKey.String("tag")
+)
+
+// Enum values for vcs.ref.type
+var (
+ // [branch]
+ // Stability: development
+ //
+ // [branch]: https://git-scm.com/docs/gitglossary#Documentation/gitglossary.txt-aiddefbranchabranch
+ VCSRefTypeBranch = VCSRefTypeKey.String("branch")
+ // [tag]
+ // Stability: development
+ //
+ // [tag]: https://git-scm.com/docs/gitglossary#Documentation/gitglossary.txt-aiddeftagatag
+ VCSRefTypeTag = VCSRefTypeKey.String("tag")
+)
+
+// Enum values for vcs.revision_delta.direction
+var (
+ // How many revisions the change is behind the target ref.
+ // Stability: development
+ VCSRevisionDeltaDirectionBehind = VCSRevisionDeltaDirectionKey.String("behind")
+ // How many revisions the change is ahead of the target ref.
+ // Stability: development
+ VCSRevisionDeltaDirectionAhead = VCSRevisionDeltaDirectionKey.String("ahead")
+)
+
+// Namespace: webengine
+const (
+ // WebEngineDescriptionKey is the attribute Key conforming to the
+ // "webengine.description" semantic conventions. It represents the additional
+ // description of the web engine (e.g. detailed version and edition
+ // information).
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "WildFly Full 21.0.0.Final (WildFly Core 13.0.1.Final) -
+ // 2.2.2.Final"
+ WebEngineDescriptionKey = attribute.Key("webengine.description")
+
+ // WebEngineNameKey is the attribute Key conforming to the "webengine.name"
+ // semantic conventions. It represents the name of the web engine.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "WildFly"
+ WebEngineNameKey = attribute.Key("webengine.name")
+
+ // WebEngineVersionKey is the attribute Key conforming to the
+ // "webengine.version" semantic conventions. It represents the version of the
+ // web engine.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "21.0.0"
+ WebEngineVersionKey = attribute.Key("webengine.version")
+)
+
+// WebEngineDescription returns an attribute KeyValue conforming to the
+// "webengine.description" semantic conventions. It represents the additional
+// description of the web engine (e.g. detailed version and edition information).
+func WebEngineDescription(val string) attribute.KeyValue {
+ return WebEngineDescriptionKey.String(val)
+}
+
+// WebEngineName returns an attribute KeyValue conforming to the "webengine.name"
+// semantic conventions. It represents the name of the web engine.
+func WebEngineName(val string) attribute.KeyValue {
+ return WebEngineNameKey.String(val)
+}
+
+// WebEngineVersion returns an attribute KeyValue conforming to the
+// "webengine.version" semantic conventions. It represents the version of the web
+// engine.
+func WebEngineVersion(val string) attribute.KeyValue {
+ return WebEngineVersionKey.String(val)
+}
+
+// Namespace: zos
+const (
+ // ZOSSmfIDKey is the attribute Key conforming to the "zos.smf.id" semantic
+ // conventions. It represents the System Management Facility (SMF) Identifier
+ // uniquely identified a z/OS system within a SYSPLEX or mainframe environment
+ // and is used for system and performance analysis.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "SYS1"
+ ZOSSmfIDKey = attribute.Key("zos.smf.id")
+
+ // ZOSSysplexNameKey is the attribute Key conforming to the "zos.sysplex.name"
+ // semantic conventions. It represents the name of the SYSPLEX to which the z/OS
+ // system belongs too.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "SYSPLEX1"
+ ZOSSysplexNameKey = attribute.Key("zos.sysplex.name")
+)
+
+// ZOSSmfID returns an attribute KeyValue conforming to the "zos.smf.id" semantic
+// conventions. It represents the System Management Facility (SMF) Identifier
+// uniquely identified a z/OS system within a SYSPLEX or mainframe environment
+// and is used for system and performance analysis.
+func ZOSSmfID(val string) attribute.KeyValue {
+ return ZOSSmfIDKey.String(val)
+}
+
+// ZOSSysplexName returns an attribute KeyValue conforming to the
+// "zos.sysplex.name" semantic conventions. It represents the name of the SYSPLEX
+// to which the z/OS system belongs too.
+func ZOSSysplexName(val string) attribute.KeyValue {
+ return ZOSSysplexNameKey.String(val)
+}
\ No newline at end of file
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.37.0/doc.go b/vendor/go.opentelemetry.io/otel/semconv/v1.37.0/doc.go
new file mode 100644
index 0000000000..1110103210
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/semconv/v1.37.0/doc.go
@@ -0,0 +1,9 @@
+// Copyright The OpenTelemetry Authors
+// SPDX-License-Identifier: Apache-2.0
+
+// Package semconv implements OpenTelemetry semantic conventions.
+//
+// OpenTelemetry semantic conventions are agreed standardized naming
+// patterns for OpenTelemetry things. This package represents the v1.37.0
+// version of the OpenTelemetry semantic conventions.
+package semconv // import "go.opentelemetry.io/otel/semconv/v1.37.0"
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.37.0/error_type.go b/vendor/go.opentelemetry.io/otel/semconv/v1.37.0/error_type.go
new file mode 100644
index 0000000000..267979c051
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/semconv/v1.37.0/error_type.go
@@ -0,0 +1,56 @@
+// Copyright The OpenTelemetry Authors
+// SPDX-License-Identifier: Apache-2.0
+
+package semconv // import "go.opentelemetry.io/otel/semconv/v1.37.0"
+
+import (
+ "reflect"
+
+ "go.opentelemetry.io/otel/attribute"
+)
+
+// ErrorType returns an [attribute.KeyValue] identifying the error type of err.
+//
+// If err is nil, the returned attribute has the default value
+// [ErrorTypeOther].
+//
+// If err's type has the method
+//
+// ErrorType() string
+//
+// then the returned attribute has the value of err.ErrorType(). Otherwise, the
+// returned attribute has a value derived from the concrete type of err.
+//
+// The key of the returned attribute is [ErrorTypeKey].
+func ErrorType(err error) attribute.KeyValue {
+ if err == nil {
+ return ErrorTypeOther
+ }
+
+ return ErrorTypeKey.String(errorType(err))
+}
+
+func errorType(err error) string {
+ var s string
+ if et, ok := err.(interface{ ErrorType() string }); ok {
+ // Prioritize the ErrorType method if available.
+ s = et.ErrorType()
+ }
+ if s == "" {
+ // Fallback to reflection if the ErrorType method is not supported or
+ // returns an empty value.
+
+ t := reflect.TypeOf(err)
+ pkg, name := t.PkgPath(), t.Name()
+ if pkg != "" && name != "" {
+ s = pkg + "." + name
+ } else {
+ // The type has no package path or name (predeclared, not-defined,
+ // or alias for a not-defined type).
+ //
+ // This is not guaranteed to be unique, but is a best effort.
+ s = t.String()
+ }
+ }
+ return s
+}
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.37.0/exception.go b/vendor/go.opentelemetry.io/otel/semconv/v1.37.0/exception.go
new file mode 100644
index 0000000000..e67469a4f6
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/semconv/v1.37.0/exception.go
@@ -0,0 +1,9 @@
+// Copyright The OpenTelemetry Authors
+// SPDX-License-Identifier: Apache-2.0
+
+package semconv // import "go.opentelemetry.io/otel/semconv/v1.37.0"
+
+const (
+ // ExceptionEventName is the name of the Span event representing an exception.
+ ExceptionEventName = "exception"
+)
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.37.0/schema.go b/vendor/go.opentelemetry.io/otel/semconv/v1.37.0/schema.go
new file mode 100644
index 0000000000..f8a0b70441
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/semconv/v1.37.0/schema.go
@@ -0,0 +1,9 @@
+// Copyright The OpenTelemetry Authors
+// SPDX-License-Identifier: Apache-2.0
+
+package semconv // import "go.opentelemetry.io/otel/semconv/v1.37.0"
+
+// SchemaURL is the schema URL that matches the version of the semantic conventions
+// that this package defines. Semconv packages starting from v1.4.0 must declare
+// non-empty schema URL in the form https://opentelemetry.io/schemas/
+const SchemaURL = "https://opentelemetry.io/schemas/1.37.0"
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.39.0/MIGRATION.md b/vendor/go.opentelemetry.io/otel/semconv/v1.39.0/MIGRATION.md
new file mode 100644
index 0000000000..fed7013e6f
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/semconv/v1.39.0/MIGRATION.md
@@ -0,0 +1,78 @@
+
+# Migration from v1.38.0 to v1.39.0
+
+The `go.opentelemetry.io/otel/semconv/v1.39.0` package should be a drop-in replacement for `go.opentelemetry.io/otel/semconv/v1.38.0` with the following exceptions.
+
+## Removed
+
+The following declarations have been removed.
+Refer to the [OpenTelemetry Semantic Conventions documentation] for deprecation instructions.
+
+If the type is not listed in the documentation as deprecated, it has been removed in this version due to lack of applicability or use.
+If you use any of these non-deprecated declarations in your Go application, please [open an issue] describing your use-case.
+
+- `LinuxMemorySlabStateKey`
+- `LinuxMemorySlabStateReclaimable`
+- `LinuxMemorySlabStateUnreclaimable`
+- `PeerService`
+- `PeerServiceKey`
+- `RPCConnectRPCErrorCodeAborted`
+- `RPCConnectRPCErrorCodeAlreadyExists`
+- `RPCConnectRPCErrorCodeCancelled`
+- `RPCConnectRPCErrorCodeDataLoss`
+- `RPCConnectRPCErrorCodeDeadlineExceeded`
+- `RPCConnectRPCErrorCodeFailedPrecondition`
+- `RPCConnectRPCErrorCodeInternal`
+- `RPCConnectRPCErrorCodeInvalidArgument`
+- `RPCConnectRPCErrorCodeKey`
+- `RPCConnectRPCErrorCodeNotFound`
+- `RPCConnectRPCErrorCodeOutOfRange`
+- `RPCConnectRPCErrorCodePermissionDenied`
+- `RPCConnectRPCErrorCodeResourceExhausted`
+- `RPCConnectRPCErrorCodeUnauthenticated`
+- `RPCConnectRPCErrorCodeUnavailable`
+- `RPCConnectRPCErrorCodeUnimplemented`
+- `RPCConnectRPCErrorCodeUnknown`
+- `RPCConnectRPCRequestMetadata`
+- `RPCConnectRPCResponseMetadata`
+- `RPCGRPCRequestMetadata`
+- `RPCGRPCResponseMetadata`
+- `RPCGRPCStatusCodeAborted`
+- `RPCGRPCStatusCodeAlreadyExists`
+- `RPCGRPCStatusCodeCancelled`
+- `RPCGRPCStatusCodeDataLoss`
+- `RPCGRPCStatusCodeDeadlineExceeded`
+- `RPCGRPCStatusCodeFailedPrecondition`
+- `RPCGRPCStatusCodeInternal`
+- `RPCGRPCStatusCodeInvalidArgument`
+- `RPCGRPCStatusCodeKey`
+- `RPCGRPCStatusCodeNotFound`
+- `RPCGRPCStatusCodeOk`
+- `RPCGRPCStatusCodeOutOfRange`
+- `RPCGRPCStatusCodePermissionDenied`
+- `RPCGRPCStatusCodeResourceExhausted`
+- `RPCGRPCStatusCodeUnauthenticated`
+- `RPCGRPCStatusCodeUnavailable`
+- `RPCGRPCStatusCodeUnimplemented`
+- `RPCGRPCStatusCodeUnknown`
+- `RPCJSONRPCErrorCode`
+- `RPCJSONRPCErrorCodeKey`
+- `RPCJSONRPCErrorMessage`
+- `RPCJSONRPCErrorMessageKey`
+- `RPCJSONRPCRequestID`
+- `RPCJSONRPCRequestIDKey`
+- `RPCJSONRPCVersion`
+- `RPCJSONRPCVersionKey`
+- `RPCService`
+- `RPCServiceKey`
+- `RPCSystemApacheDubbo`
+- `RPCSystemConnectRPC`
+- `RPCSystemDotnetWcf`
+- `RPCSystemGRPC`
+- `RPCSystemJSONRPC`
+- `RPCSystemJavaRmi`
+- `RPCSystemKey`
+- `RPCSystemOncRPC`
+
+[OpenTelemetry Semantic Conventions documentation]: https://github.com/open-telemetry/semantic-conventions
+[open an issue]: https://github.com/open-telemetry/opentelemetry-go/issues/new?template=Blank+issue
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.39.0/README.md b/vendor/go.opentelemetry.io/otel/semconv/v1.39.0/README.md
new file mode 100644
index 0000000000..4b0e6f7f3e
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/semconv/v1.39.0/README.md
@@ -0,0 +1,3 @@
+# Semconv v1.39.0
+
+[](https://pkg.go.dev/go.opentelemetry.io/otel/semconv/v1.39.0)
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.39.0/attribute_group.go b/vendor/go.opentelemetry.io/otel/semconv/v1.39.0/attribute_group.go
new file mode 100644
index 0000000000..080365fc19
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/semconv/v1.39.0/attribute_group.go
@@ -0,0 +1,16239 @@
+// Copyright The OpenTelemetry Authors
+// SPDX-License-Identifier: Apache-2.0
+
+// Code generated from semantic convention specification. DO NOT EDIT.
+
+package semconv // import "go.opentelemetry.io/otel/semconv/v1.39.0"
+
+import "go.opentelemetry.io/otel/attribute"
+
+// Namespace: android
+const (
+ // AndroidAppStateKey is the attribute Key conforming to the "android.app.state"
+ // semantic conventions. It represents the this attribute represents the state
+ // of the application.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "created"
+ // Note: The Android lifecycle states are defined in
+ // [Activity lifecycle callbacks], and from which the `OS identifiers` are
+ // derived.
+ //
+ // [Activity lifecycle callbacks]: https://developer.android.com/guide/components/activities/activity-lifecycle#lc
+ AndroidAppStateKey = attribute.Key("android.app.state")
+
+ // AndroidOSAPILevelKey is the attribute Key conforming to the
+ // "android.os.api_level" semantic conventions. It represents the uniquely
+ // identifies the framework API revision offered by a version (`os.version`) of
+ // the android operating system. More information can be found in the
+ // [Android API levels documentation].
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "33", "32"
+ //
+ // [Android API levels documentation]: https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels
+ AndroidOSAPILevelKey = attribute.Key("android.os.api_level")
+)
+
+// AndroidOSAPILevel returns an attribute KeyValue conforming to the
+// "android.os.api_level" semantic conventions. It represents the uniquely
+// identifies the framework API revision offered by a version (`os.version`) of
+// the android operating system. More information can be found in the
+// [Android API levels documentation].
+//
+// [Android API levels documentation]: https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels
+func AndroidOSAPILevel(val string) attribute.KeyValue {
+ return AndroidOSAPILevelKey.String(val)
+}
+
+// Enum values for android.app.state
+var (
+ // Any time before Activity.onResume() or, if the app has no Activity,
+ // Context.startService() has been called in the app for the first time.
+ //
+ // Stability: development
+ AndroidAppStateCreated = AndroidAppStateKey.String("created")
+ // Any time after Activity.onPause() or, if the app has no Activity,
+ // Context.stopService() has been called when the app was in the foreground
+ // state.
+ //
+ // Stability: development
+ AndroidAppStateBackground = AndroidAppStateKey.String("background")
+ // Any time after Activity.onResume() or, if the app has no Activity,
+ // Context.startService() has been called when the app was in either the created
+ // or background states.
+ //
+ // Stability: development
+ AndroidAppStateForeground = AndroidAppStateKey.String("foreground")
+)
+
+// Namespace: app
+const (
+ // AppBuildIDKey is the attribute Key conforming to the "app.build_id" semantic
+ // conventions. It represents the unique identifier for a particular build or
+ // compilation of the application.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "6cff0a7e-cefc-4668-96f5-1273d8b334d0",
+ // "9f2b833506aa6973a92fde9733e6271f", "my-app-1.0.0-code-123"
+ AppBuildIDKey = attribute.Key("app.build_id")
+
+ // AppInstallationIDKey is the attribute Key conforming to the
+ // "app.installation.id" semantic conventions. It represents a unique identifier
+ // representing the installation of an application on a specific device.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "2ab2916d-a51f-4ac8-80ee-45ac31a28092"
+ // Note: Its value SHOULD persist across launches of the same application
+ // installation, including through application upgrades.
+ // It SHOULD change if the application is uninstalled or if all applications of
+ // the vendor are uninstalled.
+ // Additionally, users might be able to reset this value (e.g. by clearing
+ // application data).
+ // If an app is installed multiple times on the same device (e.g. in different
+ // accounts on Android), each `app.installation.id` SHOULD have a different
+ // value.
+ // If multiple OpenTelemetry SDKs are used within the same application, they
+ // SHOULD use the same value for `app.installation.id`.
+ // Hardware IDs (e.g. serial number, IMEI, MAC address) MUST NOT be used as the
+ // `app.installation.id`.
+ //
+ // For iOS, this value SHOULD be equal to the [vendor identifier].
+ //
+ // For Android, examples of `app.installation.id` implementations include:
+ //
+ // - [Firebase Installation ID].
+ // - A globally unique UUID which is persisted across sessions in your
+ // application.
+ // - [App set ID].
+ // - [`Settings.getString(Settings.Secure.ANDROID_ID)`].
+ //
+ // More information about Android identifier best practices can be found in the
+ // [Android user data IDs guide].
+ //
+ // [vendor identifier]: https://developer.apple.com/documentation/uikit/uidevice/identifierforvendor
+ // [Firebase Installation ID]: https://firebase.google.com/docs/projects/manage-installations
+ // [App set ID]: https://developer.android.com/identity/app-set-id
+ // [`Settings.getString(Settings.Secure.ANDROID_ID)`]: https://developer.android.com/reference/android/provider/Settings.Secure#ANDROID_ID
+ // [Android user data IDs guide]: https://developer.android.com/training/articles/user-data-ids
+ AppInstallationIDKey = attribute.Key("app.installation.id")
+
+ // AppJankFrameCountKey is the attribute Key conforming to the
+ // "app.jank.frame_count" semantic conventions. It represents a number of frame
+ // renders that experienced jank.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 9, 42
+ // Note: Depending on platform limitations, the value provided MAY be
+ // approximation.
+ AppJankFrameCountKey = attribute.Key("app.jank.frame_count")
+
+ // AppJankPeriodKey is the attribute Key conforming to the "app.jank.period"
+ // semantic conventions. It represents the time period, in seconds, for which
+ // this jank is being reported.
+ //
+ // Type: double
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 1.0, 5.0, 10.24
+ AppJankPeriodKey = attribute.Key("app.jank.period")
+
+ // AppJankThresholdKey is the attribute Key conforming to the
+ // "app.jank.threshold" semantic conventions. It represents the minimum
+ // rendering threshold for this jank, in seconds.
+ //
+ // Type: double
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 0.016, 0.7, 1.024
+ AppJankThresholdKey = attribute.Key("app.jank.threshold")
+
+ // AppScreenCoordinateXKey is the attribute Key conforming to the
+ // "app.screen.coordinate.x" semantic conventions. It represents the x
+ // (horizontal) coordinate of a screen coordinate, in screen pixels.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 0, 131
+ AppScreenCoordinateXKey = attribute.Key("app.screen.coordinate.x")
+
+ // AppScreenCoordinateYKey is the attribute Key conforming to the
+ // "app.screen.coordinate.y" semantic conventions. It represents the y
+ // (vertical) component of a screen coordinate, in screen pixels.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 12, 99
+ AppScreenCoordinateYKey = attribute.Key("app.screen.coordinate.y")
+
+ // AppScreenIDKey is the attribute Key conforming to the "app.screen.id"
+ // semantic conventions. It represents an identifier that uniquely
+ // differentiates this screen from other screens in the same application.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "f9bc787d-ff05-48ad-90e1-fca1d46130b3",
+ // "com.example.app.MainActivity", "com.example.shop.ProductDetailFragment",
+ // "MyApp.ProfileView", "MyApp.ProfileViewController"
+ // Note: A screen represents only the part of the device display drawn by the
+ // app. It typically contains multiple widgets or UI components and is larger in
+ // scope than individual widgets. Multiple screens can coexist on the same
+ // display simultaneously (e.g., split view on tablets).
+ AppScreenIDKey = attribute.Key("app.screen.id")
+
+ // AppScreenNameKey is the attribute Key conforming to the "app.screen.name"
+ // semantic conventions. It represents the name of an application screen.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "MainActivity", "ProductDetailFragment", "ProfileView",
+ // "ProfileViewController"
+ // Note: A screen represents only the part of the device display drawn by the
+ // app. It typically contains multiple widgets or UI components and is larger in
+ // scope than individual widgets. Multiple screens can coexist on the same
+ // display simultaneously (e.g., split view on tablets).
+ AppScreenNameKey = attribute.Key("app.screen.name")
+
+ // AppWidgetIDKey is the attribute Key conforming to the "app.widget.id"
+ // semantic conventions. It represents an identifier that uniquely
+ // differentiates this widget from other widgets in the same application.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "f9bc787d-ff05-48ad-90e1-fca1d46130b3", "submit_order_1829"
+ // Note: A widget is an application component, typically an on-screen visual GUI
+ // element.
+ AppWidgetIDKey = attribute.Key("app.widget.id")
+
+ // AppWidgetNameKey is the attribute Key conforming to the "app.widget.name"
+ // semantic conventions. It represents the name of an application widget.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "submit", "attack", "Clear Cart"
+ // Note: A widget is an application component, typically an on-screen visual GUI
+ // element.
+ AppWidgetNameKey = attribute.Key("app.widget.name")
+)
+
+// AppBuildID returns an attribute KeyValue conforming to the "app.build_id"
+// semantic conventions. It represents the unique identifier for a particular
+// build or compilation of the application.
+func AppBuildID(val string) attribute.KeyValue {
+ return AppBuildIDKey.String(val)
+}
+
+// AppInstallationID returns an attribute KeyValue conforming to the
+// "app.installation.id" semantic conventions. It represents a unique identifier
+// representing the installation of an application on a specific device.
+func AppInstallationID(val string) attribute.KeyValue {
+ return AppInstallationIDKey.String(val)
+}
+
+// AppJankFrameCount returns an attribute KeyValue conforming to the
+// "app.jank.frame_count" semantic conventions. It represents a number of frame
+// renders that experienced jank.
+func AppJankFrameCount(val int) attribute.KeyValue {
+ return AppJankFrameCountKey.Int(val)
+}
+
+// AppJankPeriod returns an attribute KeyValue conforming to the
+// "app.jank.period" semantic conventions. It represents the time period, in
+// seconds, for which this jank is being reported.
+func AppJankPeriod(val float64) attribute.KeyValue {
+ return AppJankPeriodKey.Float64(val)
+}
+
+// AppJankThreshold returns an attribute KeyValue conforming to the
+// "app.jank.threshold" semantic conventions. It represents the minimum rendering
+// threshold for this jank, in seconds.
+func AppJankThreshold(val float64) attribute.KeyValue {
+ return AppJankThresholdKey.Float64(val)
+}
+
+// AppScreenCoordinateX returns an attribute KeyValue conforming to the
+// "app.screen.coordinate.x" semantic conventions. It represents the x
+// (horizontal) coordinate of a screen coordinate, in screen pixels.
+func AppScreenCoordinateX(val int) attribute.KeyValue {
+ return AppScreenCoordinateXKey.Int(val)
+}
+
+// AppScreenCoordinateY returns an attribute KeyValue conforming to the
+// "app.screen.coordinate.y" semantic conventions. It represents the y (vertical)
+// component of a screen coordinate, in screen pixels.
+func AppScreenCoordinateY(val int) attribute.KeyValue {
+ return AppScreenCoordinateYKey.Int(val)
+}
+
+// AppScreenID returns an attribute KeyValue conforming to the "app.screen.id"
+// semantic conventions. It represents an identifier that uniquely differentiates
+// this screen from other screens in the same application.
+func AppScreenID(val string) attribute.KeyValue {
+ return AppScreenIDKey.String(val)
+}
+
+// AppScreenName returns an attribute KeyValue conforming to the
+// "app.screen.name" semantic conventions. It represents the name of an
+// application screen.
+func AppScreenName(val string) attribute.KeyValue {
+ return AppScreenNameKey.String(val)
+}
+
+// AppWidgetID returns an attribute KeyValue conforming to the "app.widget.id"
+// semantic conventions. It represents an identifier that uniquely differentiates
+// this widget from other widgets in the same application.
+func AppWidgetID(val string) attribute.KeyValue {
+ return AppWidgetIDKey.String(val)
+}
+
+// AppWidgetName returns an attribute KeyValue conforming to the
+// "app.widget.name" semantic conventions. It represents the name of an
+// application widget.
+func AppWidgetName(val string) attribute.KeyValue {
+ return AppWidgetNameKey.String(val)
+}
+
+// Namespace: artifact
+const (
+ // ArtifactAttestationFilenameKey is the attribute Key conforming to the
+ // "artifact.attestation.filename" semantic conventions. It represents the
+ // provenance filename of the built attestation which directly relates to the
+ // build artifact filename. This filename SHOULD accompany the artifact at
+ // publish time. See the [SLSA Relationship] specification for more information.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "golang-binary-amd64-v0.1.0.attestation",
+ // "docker-image-amd64-v0.1.0.intoto.json1", "release-1.tar.gz.attestation",
+ // "file-name-package.tar.gz.intoto.json1"
+ //
+ // [SLSA Relationship]: https://slsa.dev/spec/v1.0/distributing-provenance#relationship-between-artifacts-and-attestations
+ ArtifactAttestationFilenameKey = attribute.Key("artifact.attestation.filename")
+
+ // ArtifactAttestationHashKey is the attribute Key conforming to the
+ // "artifact.attestation.hash" semantic conventions. It represents the full
+ // [hash value (see glossary)], of the built attestation. Some envelopes in the
+ // [software attestation space] also refer to this as the **digest**.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "1b31dfcd5b7f9267bf2ff47651df1cfb9147b9e4df1f335accf65b4cda498408"
+ //
+ // [hash value (see glossary)]: https://nvlpubs.nist.gov/nistpubs/FIPS/NIST.FIPS.186-5.pdf
+ // [software attestation space]: https://github.com/in-toto/attestation/tree/main/spec
+ ArtifactAttestationHashKey = attribute.Key("artifact.attestation.hash")
+
+ // ArtifactAttestationIDKey is the attribute Key conforming to the
+ // "artifact.attestation.id" semantic conventions. It represents the id of the
+ // build [software attestation].
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "123"
+ //
+ // [software attestation]: https://slsa.dev/attestation-model
+ ArtifactAttestationIDKey = attribute.Key("artifact.attestation.id")
+
+ // ArtifactFilenameKey is the attribute Key conforming to the
+ // "artifact.filename" semantic conventions. It represents the human readable
+ // file name of the artifact, typically generated during build and release
+ // processes. Often includes the package name and version in the file name.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "golang-binary-amd64-v0.1.0", "docker-image-amd64-v0.1.0",
+ // "release-1.tar.gz", "file-name-package.tar.gz"
+ // Note: This file name can also act as the [Package Name]
+ // in cases where the package ecosystem maps accordingly.
+ // Additionally, the artifact [can be published]
+ // for others, but that is not a guarantee.
+ //
+ // [Package Name]: https://slsa.dev/spec/v1.0/terminology#package-model
+ // [can be published]: https://slsa.dev/spec/v1.0/terminology#software-supply-chain
+ ArtifactFilenameKey = attribute.Key("artifact.filename")
+
+ // ArtifactHashKey is the attribute Key conforming to the "artifact.hash"
+ // semantic conventions. It represents the full [hash value (see glossary)],
+ // often found in checksum.txt on a release of the artifact and used to verify
+ // package integrity.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "9ff4c52759e2c4ac70b7d517bc7fcdc1cda631ca0045271ddd1b192544f8a3e9"
+ // Note: The specific algorithm used to create the cryptographic hash value is
+ // not defined. In situations where an artifact has multiple
+ // cryptographic hashes, it is up to the implementer to choose which
+ // hash value to set here; this should be the most secure hash algorithm
+ // that is suitable for the situation and consistent with the
+ // corresponding attestation. The implementer can then provide the other
+ // hash values through an additional set of attribute extensions as they
+ // deem necessary.
+ //
+ // [hash value (see glossary)]: https://nvlpubs.nist.gov/nistpubs/FIPS/NIST.FIPS.186-5.pdf
+ ArtifactHashKey = attribute.Key("artifact.hash")
+
+ // ArtifactPurlKey is the attribute Key conforming to the "artifact.purl"
+ // semantic conventions. It represents the [Package URL] of the
+ // [package artifact] provides a standard way to identify and locate the
+ // packaged artifact.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "pkg:github/package-url/purl-spec@1209109710924",
+ // "pkg:npm/foo@12.12.3"
+ //
+ // [Package URL]: https://github.com/package-url/purl-spec
+ // [package artifact]: https://slsa.dev/spec/v1.0/terminology#package-model
+ ArtifactPurlKey = attribute.Key("artifact.purl")
+
+ // ArtifactVersionKey is the attribute Key conforming to the "artifact.version"
+ // semantic conventions. It represents the version of the artifact.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "v0.1.0", "1.2.1", "122691-build"
+ ArtifactVersionKey = attribute.Key("artifact.version")
+)
+
+// ArtifactAttestationFilename returns an attribute KeyValue conforming to the
+// "artifact.attestation.filename" semantic conventions. It represents the
+// provenance filename of the built attestation which directly relates to the
+// build artifact filename. This filename SHOULD accompany the artifact at
+// publish time. See the [SLSA Relationship] specification for more information.
+//
+// [SLSA Relationship]: https://slsa.dev/spec/v1.0/distributing-provenance#relationship-between-artifacts-and-attestations
+func ArtifactAttestationFilename(val string) attribute.KeyValue {
+ return ArtifactAttestationFilenameKey.String(val)
+}
+
+// ArtifactAttestationHash returns an attribute KeyValue conforming to the
+// "artifact.attestation.hash" semantic conventions. It represents the full
+// [hash value (see glossary)], of the built attestation. Some envelopes in the
+// [software attestation space] also refer to this as the **digest**.
+//
+// [hash value (see glossary)]: https://nvlpubs.nist.gov/nistpubs/FIPS/NIST.FIPS.186-5.pdf
+// [software attestation space]: https://github.com/in-toto/attestation/tree/main/spec
+func ArtifactAttestationHash(val string) attribute.KeyValue {
+ return ArtifactAttestationHashKey.String(val)
+}
+
+// ArtifactAttestationID returns an attribute KeyValue conforming to the
+// "artifact.attestation.id" semantic conventions. It represents the id of the
+// build [software attestation].
+//
+// [software attestation]: https://slsa.dev/attestation-model
+func ArtifactAttestationID(val string) attribute.KeyValue {
+ return ArtifactAttestationIDKey.String(val)
+}
+
+// ArtifactFilename returns an attribute KeyValue conforming to the
+// "artifact.filename" semantic conventions. It represents the human readable
+// file name of the artifact, typically generated during build and release
+// processes. Often includes the package name and version in the file name.
+func ArtifactFilename(val string) attribute.KeyValue {
+ return ArtifactFilenameKey.String(val)
+}
+
+// ArtifactHash returns an attribute KeyValue conforming to the "artifact.hash"
+// semantic conventions. It represents the full [hash value (see glossary)],
+// often found in checksum.txt on a release of the artifact and used to verify
+// package integrity.
+//
+// [hash value (see glossary)]: https://nvlpubs.nist.gov/nistpubs/FIPS/NIST.FIPS.186-5.pdf
+func ArtifactHash(val string) attribute.KeyValue {
+ return ArtifactHashKey.String(val)
+}
+
+// ArtifactPurl returns an attribute KeyValue conforming to the "artifact.purl"
+// semantic conventions. It represents the [Package URL] of the
+// [package artifact] provides a standard way to identify and locate the packaged
+// artifact.
+//
+// [Package URL]: https://github.com/package-url/purl-spec
+// [package artifact]: https://slsa.dev/spec/v1.0/terminology#package-model
+func ArtifactPurl(val string) attribute.KeyValue {
+ return ArtifactPurlKey.String(val)
+}
+
+// ArtifactVersion returns an attribute KeyValue conforming to the
+// "artifact.version" semantic conventions. It represents the version of the
+// artifact.
+func ArtifactVersion(val string) attribute.KeyValue {
+ return ArtifactVersionKey.String(val)
+}
+
+// Namespace: aws
+const (
+ // AWSBedrockGuardrailIDKey is the attribute Key conforming to the
+ // "aws.bedrock.guardrail.id" semantic conventions. It represents the unique
+ // identifier of the AWS Bedrock Guardrail. A [guardrail] helps safeguard and
+ // prevent unwanted behavior from model responses or user messages.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "sgi5gkybzqak"
+ //
+ // [guardrail]: https://docs.aws.amazon.com/bedrock/latest/userguide/guardrails.html
+ AWSBedrockGuardrailIDKey = attribute.Key("aws.bedrock.guardrail.id")
+
+ // AWSBedrockKnowledgeBaseIDKey is the attribute Key conforming to the
+ // "aws.bedrock.knowledge_base.id" semantic conventions. It represents the
+ // unique identifier of the AWS Bedrock Knowledge base. A [knowledge base] is a
+ // bank of information that can be queried by models to generate more relevant
+ // responses and augment prompts.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "XFWUPB9PAW"
+ //
+ // [knowledge base]: https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base.html
+ AWSBedrockKnowledgeBaseIDKey = attribute.Key("aws.bedrock.knowledge_base.id")
+
+ // AWSDynamoDBAttributeDefinitionsKey is the attribute Key conforming to the
+ // "aws.dynamodb.attribute_definitions" semantic conventions. It represents the
+ // JSON-serialized value of each item in the `AttributeDefinitions` request
+ // field.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "{ "AttributeName": "string", "AttributeType": "string" }"
+ AWSDynamoDBAttributeDefinitionsKey = attribute.Key("aws.dynamodb.attribute_definitions")
+
+ // AWSDynamoDBAttributesToGetKey is the attribute Key conforming to the
+ // "aws.dynamodb.attributes_to_get" semantic conventions. It represents the
+ // value of the `AttributesToGet` request parameter.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "lives", "id"
+ AWSDynamoDBAttributesToGetKey = attribute.Key("aws.dynamodb.attributes_to_get")
+
+ // AWSDynamoDBConsistentReadKey is the attribute Key conforming to the
+ // "aws.dynamodb.consistent_read" semantic conventions. It represents the value
+ // of the `ConsistentRead` request parameter.
+ //
+ // Type: boolean
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ AWSDynamoDBConsistentReadKey = attribute.Key("aws.dynamodb.consistent_read")
+
+ // AWSDynamoDBConsumedCapacityKey is the attribute Key conforming to the
+ // "aws.dynamodb.consumed_capacity" semantic conventions. It represents the
+ // JSON-serialized value of each item in the `ConsumedCapacity` response field.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "{ "CapacityUnits": number, "GlobalSecondaryIndexes": { "string" :
+ // { "CapacityUnits": number, "ReadCapacityUnits": number, "WriteCapacityUnits":
+ // number } }, "LocalSecondaryIndexes": { "string" : { "CapacityUnits": number,
+ // "ReadCapacityUnits": number, "WriteCapacityUnits": number } },
+ // "ReadCapacityUnits": number, "Table": { "CapacityUnits": number,
+ // "ReadCapacityUnits": number, "WriteCapacityUnits": number }, "TableName":
+ // "string", "WriteCapacityUnits": number }"
+ AWSDynamoDBConsumedCapacityKey = attribute.Key("aws.dynamodb.consumed_capacity")
+
+ // AWSDynamoDBCountKey is the attribute Key conforming to the
+ // "aws.dynamodb.count" semantic conventions. It represents the value of the
+ // `Count` response parameter.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 10
+ AWSDynamoDBCountKey = attribute.Key("aws.dynamodb.count")
+
+ // AWSDynamoDBExclusiveStartTableKey is the attribute Key conforming to the
+ // "aws.dynamodb.exclusive_start_table" semantic conventions. It represents the
+ // value of the `ExclusiveStartTableName` request parameter.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Users", "CatsTable"
+ AWSDynamoDBExclusiveStartTableKey = attribute.Key("aws.dynamodb.exclusive_start_table")
+
+ // AWSDynamoDBGlobalSecondaryIndexUpdatesKey is the attribute Key conforming to
+ // the "aws.dynamodb.global_secondary_index_updates" semantic conventions. It
+ // represents the JSON-serialized value of each item in the
+ // `GlobalSecondaryIndexUpdates` request field.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "{ "Create": { "IndexName": "string", "KeySchema": [ {
+ // "AttributeName": "string", "KeyType": "string" } ], "Projection": {
+ // "NonKeyAttributes": [ "string" ], "ProjectionType": "string" },
+ // "ProvisionedThroughput": { "ReadCapacityUnits": number, "WriteCapacityUnits":
+ // number } }"
+ AWSDynamoDBGlobalSecondaryIndexUpdatesKey = attribute.Key("aws.dynamodb.global_secondary_index_updates")
+
+ // AWSDynamoDBGlobalSecondaryIndexesKey is the attribute Key conforming to the
+ // "aws.dynamodb.global_secondary_indexes" semantic conventions. It represents
+ // the JSON-serialized value of each item of the `GlobalSecondaryIndexes`
+ // request field.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "{ "IndexName": "string", "KeySchema": [ { "AttributeName":
+ // "string", "KeyType": "string" } ], "Projection": { "NonKeyAttributes": [
+ // "string" ], "ProjectionType": "string" }, "ProvisionedThroughput": {
+ // "ReadCapacityUnits": number, "WriteCapacityUnits": number } }"
+ AWSDynamoDBGlobalSecondaryIndexesKey = attribute.Key("aws.dynamodb.global_secondary_indexes")
+
+ // AWSDynamoDBIndexNameKey is the attribute Key conforming to the
+ // "aws.dynamodb.index_name" semantic conventions. It represents the value of
+ // the `IndexName` request parameter.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "name_to_group"
+ AWSDynamoDBIndexNameKey = attribute.Key("aws.dynamodb.index_name")
+
+ // AWSDynamoDBItemCollectionMetricsKey is the attribute Key conforming to the
+ // "aws.dynamodb.item_collection_metrics" semantic conventions. It represents
+ // the JSON-serialized value of the `ItemCollectionMetrics` response field.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "{ "string" : [ { "ItemCollectionKey": { "string" : { "B": blob,
+ // "BOOL": boolean, "BS": [ blob ], "L": [ "AttributeValue" ], "M": { "string" :
+ // "AttributeValue" }, "N": "string", "NS": [ "string" ], "NULL": boolean, "S":
+ // "string", "SS": [ "string" ] } }, "SizeEstimateRangeGB": [ number ] } ] }"
+ AWSDynamoDBItemCollectionMetricsKey = attribute.Key("aws.dynamodb.item_collection_metrics")
+
+ // AWSDynamoDBLimitKey is the attribute Key conforming to the
+ // "aws.dynamodb.limit" semantic conventions. It represents the value of the
+ // `Limit` request parameter.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 10
+ AWSDynamoDBLimitKey = attribute.Key("aws.dynamodb.limit")
+
+ // AWSDynamoDBLocalSecondaryIndexesKey is the attribute Key conforming to the
+ // "aws.dynamodb.local_secondary_indexes" semantic conventions. It represents
+ // the JSON-serialized value of each item of the `LocalSecondaryIndexes` request
+ // field.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "{ "IndexArn": "string", "IndexName": "string", "IndexSizeBytes":
+ // number, "ItemCount": number, "KeySchema": [ { "AttributeName": "string",
+ // "KeyType": "string" } ], "Projection": { "NonKeyAttributes": [ "string" ],
+ // "ProjectionType": "string" } }"
+ AWSDynamoDBLocalSecondaryIndexesKey = attribute.Key("aws.dynamodb.local_secondary_indexes")
+
+ // AWSDynamoDBProjectionKey is the attribute Key conforming to the
+ // "aws.dynamodb.projection" semantic conventions. It represents the value of
+ // the `ProjectionExpression` request parameter.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Title", "Title, Price, Color", "Title, Description, RelatedItems,
+ // ProductReviews"
+ AWSDynamoDBProjectionKey = attribute.Key("aws.dynamodb.projection")
+
+ // AWSDynamoDBProvisionedReadCapacityKey is the attribute Key conforming to the
+ // "aws.dynamodb.provisioned_read_capacity" semantic conventions. It represents
+ // the value of the `ProvisionedThroughput.ReadCapacityUnits` request parameter.
+ //
+ // Type: double
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 1.0, 2.0
+ AWSDynamoDBProvisionedReadCapacityKey = attribute.Key("aws.dynamodb.provisioned_read_capacity")
+
+ // AWSDynamoDBProvisionedWriteCapacityKey is the attribute Key conforming to the
+ // "aws.dynamodb.provisioned_write_capacity" semantic conventions. It represents
+ // the value of the `ProvisionedThroughput.WriteCapacityUnits` request
+ // parameter.
+ //
+ // Type: double
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 1.0, 2.0
+ AWSDynamoDBProvisionedWriteCapacityKey = attribute.Key("aws.dynamodb.provisioned_write_capacity")
+
+ // AWSDynamoDBScanForwardKey is the attribute Key conforming to the
+ // "aws.dynamodb.scan_forward" semantic conventions. It represents the value of
+ // the `ScanIndexForward` request parameter.
+ //
+ // Type: boolean
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ AWSDynamoDBScanForwardKey = attribute.Key("aws.dynamodb.scan_forward")
+
+ // AWSDynamoDBScannedCountKey is the attribute Key conforming to the
+ // "aws.dynamodb.scanned_count" semantic conventions. It represents the value of
+ // the `ScannedCount` response parameter.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 50
+ AWSDynamoDBScannedCountKey = attribute.Key("aws.dynamodb.scanned_count")
+
+ // AWSDynamoDBSegmentKey is the attribute Key conforming to the
+ // "aws.dynamodb.segment" semantic conventions. It represents the value of the
+ // `Segment` request parameter.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 10
+ AWSDynamoDBSegmentKey = attribute.Key("aws.dynamodb.segment")
+
+ // AWSDynamoDBSelectKey is the attribute Key conforming to the
+ // "aws.dynamodb.select" semantic conventions. It represents the value of the
+ // `Select` request parameter.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "ALL_ATTRIBUTES", "COUNT"
+ AWSDynamoDBSelectKey = attribute.Key("aws.dynamodb.select")
+
+ // AWSDynamoDBTableCountKey is the attribute Key conforming to the
+ // "aws.dynamodb.table_count" semantic conventions. It represents the number of
+ // items in the `TableNames` response parameter.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 20
+ AWSDynamoDBTableCountKey = attribute.Key("aws.dynamodb.table_count")
+
+ // AWSDynamoDBTableNamesKey is the attribute Key conforming to the
+ // "aws.dynamodb.table_names" semantic conventions. It represents the keys in
+ // the `RequestItems` object field.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Users", "Cats"
+ AWSDynamoDBTableNamesKey = attribute.Key("aws.dynamodb.table_names")
+
+ // AWSDynamoDBTotalSegmentsKey is the attribute Key conforming to the
+ // "aws.dynamodb.total_segments" semantic conventions. It represents the value
+ // of the `TotalSegments` request parameter.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 100
+ AWSDynamoDBTotalSegmentsKey = attribute.Key("aws.dynamodb.total_segments")
+
+ // AWSECSClusterARNKey is the attribute Key conforming to the
+ // "aws.ecs.cluster.arn" semantic conventions. It represents the ARN of an
+ // [ECS cluster].
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "arn:aws:ecs:us-west-2:123456789123:cluster/my-cluster"
+ //
+ // [ECS cluster]: https://docs.aws.amazon.com/AmazonECS/latest/developerguide/clusters.html
+ AWSECSClusterARNKey = attribute.Key("aws.ecs.cluster.arn")
+
+ // AWSECSContainerARNKey is the attribute Key conforming to the
+ // "aws.ecs.container.arn" semantic conventions. It represents the Amazon
+ // Resource Name (ARN) of an [ECS container instance].
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // "arn:aws:ecs:us-west-1:123456789123:container/32624152-9086-4f0e-acae-1a75b14fe4d9"
+ //
+ // [ECS container instance]: https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ECS_instances.html
+ AWSECSContainerARNKey = attribute.Key("aws.ecs.container.arn")
+
+ // AWSECSLaunchtypeKey is the attribute Key conforming to the
+ // "aws.ecs.launchtype" semantic conventions. It represents the [launch type]
+ // for an ECS task.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ //
+ // [launch type]: https://docs.aws.amazon.com/AmazonECS/latest/developerguide/launch_types.html
+ AWSECSLaunchtypeKey = attribute.Key("aws.ecs.launchtype")
+
+ // AWSECSTaskARNKey is the attribute Key conforming to the "aws.ecs.task.arn"
+ // semantic conventions. It represents the ARN of a running [ECS task].
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // "arn:aws:ecs:us-west-1:123456789123:task/10838bed-421f-43ef-870a-f43feacbbb5b",
+ // "arn:aws:ecs:us-west-1:123456789123:task/my-cluster/task-id/23ebb8ac-c18f-46c6-8bbe-d55d0e37cfbd"
+ //
+ // [ECS task]: https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ecs-account-settings.html#ecs-resource-ids
+ AWSECSTaskARNKey = attribute.Key("aws.ecs.task.arn")
+
+ // AWSECSTaskFamilyKey is the attribute Key conforming to the
+ // "aws.ecs.task.family" semantic conventions. It represents the family name of
+ // the [ECS task definition] used to create the ECS task.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "opentelemetry-family"
+ //
+ // [ECS task definition]: https://docs.aws.amazon.com/AmazonECS/latest/developerguide/task_definitions.html
+ AWSECSTaskFamilyKey = attribute.Key("aws.ecs.task.family")
+
+ // AWSECSTaskIDKey is the attribute Key conforming to the "aws.ecs.task.id"
+ // semantic conventions. It represents the ID of a running ECS task. The ID MUST
+ // be extracted from `task.arn`.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "10838bed-421f-43ef-870a-f43feacbbb5b",
+ // "23ebb8ac-c18f-46c6-8bbe-d55d0e37cfbd"
+ AWSECSTaskIDKey = attribute.Key("aws.ecs.task.id")
+
+ // AWSECSTaskRevisionKey is the attribute Key conforming to the
+ // "aws.ecs.task.revision" semantic conventions. It represents the revision for
+ // the task definition used to create the ECS task.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "8", "26"
+ AWSECSTaskRevisionKey = attribute.Key("aws.ecs.task.revision")
+
+ // AWSEKSClusterARNKey is the attribute Key conforming to the
+ // "aws.eks.cluster.arn" semantic conventions. It represents the ARN of an EKS
+ // cluster.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "arn:aws:ecs:us-west-2:123456789123:cluster/my-cluster"
+ AWSEKSClusterARNKey = attribute.Key("aws.eks.cluster.arn")
+
+ // AWSExtendedRequestIDKey is the attribute Key conforming to the
+ // "aws.extended_request_id" semantic conventions. It represents the AWS
+ // extended request ID as returned in the response header `x-amz-id-2`.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // "wzHcyEWfmOGDIE5QOhTAqFDoDWP3y8IUvpNINCwL9N4TEHbUw0/gZJ+VZTmCNCWR7fezEN3eCiQ="
+ AWSExtendedRequestIDKey = attribute.Key("aws.extended_request_id")
+
+ // AWSKinesisStreamNameKey is the attribute Key conforming to the
+ // "aws.kinesis.stream_name" semantic conventions. It represents the name of the
+ // AWS Kinesis [stream] the request refers to. Corresponds to the
+ // `--stream-name` parameter of the Kinesis [describe-stream] operation.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "some-stream-name"
+ //
+ // [stream]: https://docs.aws.amazon.com/streams/latest/dev/introduction.html
+ // [describe-stream]: https://docs.aws.amazon.com/cli/latest/reference/kinesis/describe-stream.html
+ AWSKinesisStreamNameKey = attribute.Key("aws.kinesis.stream_name")
+
+ // AWSLambdaInvokedARNKey is the attribute Key conforming to the
+ // "aws.lambda.invoked_arn" semantic conventions. It represents the full invoked
+ // ARN as provided on the `Context` passed to the function (
+ // `Lambda-Runtime-Invoked-Function-Arn` header on the
+ // `/runtime/invocation/next` applicable).
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "arn:aws:lambda:us-east-1:123456:function:myfunction:myalias"
+ // Note: This may be different from `cloud.resource_id` if an alias is involved.
+ AWSLambdaInvokedARNKey = attribute.Key("aws.lambda.invoked_arn")
+
+ // AWSLambdaResourceMappingIDKey is the attribute Key conforming to the
+ // "aws.lambda.resource_mapping.id" semantic conventions. It represents the UUID
+ // of the [AWS Lambda EvenSource Mapping]. An event source is mapped to a lambda
+ // function. It's contents are read by Lambda and used to trigger a function.
+ // This isn't available in the lambda execution context or the lambda runtime
+ // environtment. This is going to be populated by the AWS SDK for each language
+ // when that UUID is present. Some of these operations are
+ // Create/Delete/Get/List/Update EventSourceMapping.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "587ad24b-03b9-4413-8202-bbd56b36e5b7"
+ //
+ // [AWS Lambda EvenSource Mapping]: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-lambda-eventsourcemapping.html
+ AWSLambdaResourceMappingIDKey = attribute.Key("aws.lambda.resource_mapping.id")
+
+ // AWSLogGroupARNsKey is the attribute Key conforming to the
+ // "aws.log.group.arns" semantic conventions. It represents the Amazon Resource
+ // Name(s) (ARN) of the AWS log group(s).
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "arn:aws:logs:us-west-1:123456789012:log-group:/aws/my/group:*"
+ // Note: See the [log group ARN format documentation].
+ //
+ // [log group ARN format documentation]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/iam-access-control-overview-cwl.html#CWL_ARN_Format
+ AWSLogGroupARNsKey = attribute.Key("aws.log.group.arns")
+
+ // AWSLogGroupNamesKey is the attribute Key conforming to the
+ // "aws.log.group.names" semantic conventions. It represents the name(s) of the
+ // AWS log group(s) an application is writing to.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "/aws/lambda/my-function", "opentelemetry-service"
+ // Note: Multiple log groups must be supported for cases like multi-container
+ // applications, where a single application has sidecar containers, and each
+ // write to their own log group.
+ AWSLogGroupNamesKey = attribute.Key("aws.log.group.names")
+
+ // AWSLogStreamARNsKey is the attribute Key conforming to the
+ // "aws.log.stream.arns" semantic conventions. It represents the ARN(s) of the
+ // AWS log stream(s).
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // "arn:aws:logs:us-west-1:123456789012:log-group:/aws/my/group:log-stream:logs/main/10838bed-421f-43ef-870a-f43feacbbb5b"
+ // Note: See the [log stream ARN format documentation]. One log group can
+ // contain several log streams, so these ARNs necessarily identify both a log
+ // group and a log stream.
+ //
+ // [log stream ARN format documentation]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/iam-access-control-overview-cwl.html#CWL_ARN_Format
+ AWSLogStreamARNsKey = attribute.Key("aws.log.stream.arns")
+
+ // AWSLogStreamNamesKey is the attribute Key conforming to the
+ // "aws.log.stream.names" semantic conventions. It represents the name(s) of the
+ // AWS log stream(s) an application is writing to.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "logs/main/10838bed-421f-43ef-870a-f43feacbbb5b"
+ AWSLogStreamNamesKey = attribute.Key("aws.log.stream.names")
+
+ // AWSRequestIDKey is the attribute Key conforming to the "aws.request_id"
+ // semantic conventions. It represents the AWS request ID as returned in the
+ // response headers `x-amzn-requestid`, `x-amzn-request-id` or
+ // `x-amz-request-id`.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "79b9da39-b7ae-508a-a6bc-864b2829c622", "C9ER4AJX75574TDJ"
+ AWSRequestIDKey = attribute.Key("aws.request_id")
+
+ // AWSS3BucketKey is the attribute Key conforming to the "aws.s3.bucket"
+ // semantic conventions. It represents the S3 bucket name the request refers to.
+ // Corresponds to the `--bucket` parameter of the [S3 API] operations.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "some-bucket-name"
+ // Note: The `bucket` attribute is applicable to all S3 operations that
+ // reference a bucket, i.e. that require the bucket name as a mandatory
+ // parameter.
+ // This applies to almost all S3 operations except `list-buckets`.
+ //
+ // [S3 API]: https://docs.aws.amazon.com/cli/latest/reference/s3api/index.html
+ AWSS3BucketKey = attribute.Key("aws.s3.bucket")
+
+ // AWSS3CopySourceKey is the attribute Key conforming to the
+ // "aws.s3.copy_source" semantic conventions. It represents the source object
+ // (in the form `bucket`/`key`) for the copy operation.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "someFile.yml"
+ // Note: The `copy_source` attribute applies to S3 copy operations and
+ // corresponds to the `--copy-source` parameter
+ // of the [copy-object operation within the S3 API].
+ // This applies in particular to the following operations:
+ //
+ // - [copy-object]
+ // - [upload-part-copy]
+ //
+ //
+ // [copy-object operation within the S3 API]: https://docs.aws.amazon.com/cli/latest/reference/s3api/copy-object.html
+ // [copy-object]: https://docs.aws.amazon.com/cli/latest/reference/s3api/copy-object.html
+ // [upload-part-copy]: https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part-copy.html
+ AWSS3CopySourceKey = attribute.Key("aws.s3.copy_source")
+
+ // AWSS3DeleteKey is the attribute Key conforming to the "aws.s3.delete"
+ // semantic conventions. It represents the delete request container that
+ // specifies the objects to be deleted.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // "Objects=[{Key=string,VersionId=string},{Key=string,VersionId=string}],Quiet=boolean"
+ // Note: The `delete` attribute is only applicable to the [delete-object]
+ // operation.
+ // The `delete` attribute corresponds to the `--delete` parameter of the
+ // [delete-objects operation within the S3 API].
+ //
+ // [delete-object]: https://docs.aws.amazon.com/cli/latest/reference/s3api/delete-object.html
+ // [delete-objects operation within the S3 API]: https://docs.aws.amazon.com/cli/latest/reference/s3api/delete-objects.html
+ AWSS3DeleteKey = attribute.Key("aws.s3.delete")
+
+ // AWSS3KeyKey is the attribute Key conforming to the "aws.s3.key" semantic
+ // conventions. It represents the S3 object key the request refers to.
+ // Corresponds to the `--key` parameter of the [S3 API] operations.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "someFile.yml"
+ // Note: The `key` attribute is applicable to all object-related S3 operations,
+ // i.e. that require the object key as a mandatory parameter.
+ // This applies in particular to the following operations:
+ //
+ // - [copy-object]
+ // - [delete-object]
+ // - [get-object]
+ // - [head-object]
+ // - [put-object]
+ // - [restore-object]
+ // - [select-object-content]
+ // - [abort-multipart-upload]
+ // - [complete-multipart-upload]
+ // - [create-multipart-upload]
+ // - [list-parts]
+ // - [upload-part]
+ // - [upload-part-copy]
+ //
+ //
+ // [S3 API]: https://docs.aws.amazon.com/cli/latest/reference/s3api/index.html
+ // [copy-object]: https://docs.aws.amazon.com/cli/latest/reference/s3api/copy-object.html
+ // [delete-object]: https://docs.aws.amazon.com/cli/latest/reference/s3api/delete-object.html
+ // [get-object]: https://docs.aws.amazon.com/cli/latest/reference/s3api/get-object.html
+ // [head-object]: https://docs.aws.amazon.com/cli/latest/reference/s3api/head-object.html
+ // [put-object]: https://docs.aws.amazon.com/cli/latest/reference/s3api/put-object.html
+ // [restore-object]: https://docs.aws.amazon.com/cli/latest/reference/s3api/restore-object.html
+ // [select-object-content]: https://docs.aws.amazon.com/cli/latest/reference/s3api/select-object-content.html
+ // [abort-multipart-upload]: https://docs.aws.amazon.com/cli/latest/reference/s3api/abort-multipart-upload.html
+ // [complete-multipart-upload]: https://docs.aws.amazon.com/cli/latest/reference/s3api/complete-multipart-upload.html
+ // [create-multipart-upload]: https://docs.aws.amazon.com/cli/latest/reference/s3api/create-multipart-upload.html
+ // [list-parts]: https://docs.aws.amazon.com/cli/latest/reference/s3api/list-parts.html
+ // [upload-part]: https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part.html
+ // [upload-part-copy]: https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part-copy.html
+ AWSS3KeyKey = attribute.Key("aws.s3.key")
+
+ // AWSS3PartNumberKey is the attribute Key conforming to the
+ // "aws.s3.part_number" semantic conventions. It represents the part number of
+ // the part being uploaded in a multipart-upload operation. This is a positive
+ // integer between 1 and 10,000.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 3456
+ // Note: The `part_number` attribute is only applicable to the [upload-part]
+ // and [upload-part-copy] operations.
+ // The `part_number` attribute corresponds to the `--part-number` parameter of
+ // the
+ // [upload-part operation within the S3 API].
+ //
+ // [upload-part]: https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part.html
+ // [upload-part-copy]: https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part-copy.html
+ // [upload-part operation within the S3 API]: https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part.html
+ AWSS3PartNumberKey = attribute.Key("aws.s3.part_number")
+
+ // AWSS3UploadIDKey is the attribute Key conforming to the "aws.s3.upload_id"
+ // semantic conventions. It represents the upload ID that identifies the
+ // multipart upload.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "dfRtDYWFbkRONycy.Yxwh66Yjlx.cph0gtNBtJ"
+ // Note: The `upload_id` attribute applies to S3 multipart-upload operations and
+ // corresponds to the `--upload-id` parameter
+ // of the [S3 API] multipart operations.
+ // This applies in particular to the following operations:
+ //
+ // - [abort-multipart-upload]
+ // - [complete-multipart-upload]
+ // - [list-parts]
+ // - [upload-part]
+ // - [upload-part-copy]
+ //
+ //
+ // [S3 API]: https://docs.aws.amazon.com/cli/latest/reference/s3api/index.html
+ // [abort-multipart-upload]: https://docs.aws.amazon.com/cli/latest/reference/s3api/abort-multipart-upload.html
+ // [complete-multipart-upload]: https://docs.aws.amazon.com/cli/latest/reference/s3api/complete-multipart-upload.html
+ // [list-parts]: https://docs.aws.amazon.com/cli/latest/reference/s3api/list-parts.html
+ // [upload-part]: https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part.html
+ // [upload-part-copy]: https://docs.aws.amazon.com/cli/latest/reference/s3api/upload-part-copy.html
+ AWSS3UploadIDKey = attribute.Key("aws.s3.upload_id")
+
+ // AWSSecretsmanagerSecretARNKey is the attribute Key conforming to the
+ // "aws.secretsmanager.secret.arn" semantic conventions. It represents the ARN
+ // of the Secret stored in the Secrets Mangger.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // "arn:aws:secretsmanager:us-east-1:123456789012:secret:SecretName-6RandomCharacters"
+ AWSSecretsmanagerSecretARNKey = attribute.Key("aws.secretsmanager.secret.arn")
+
+ // AWSSNSTopicARNKey is the attribute Key conforming to the "aws.sns.topic.arn"
+ // semantic conventions. It represents the ARN of the AWS SNS Topic. An Amazon
+ // SNS [topic] is a logical access point that acts as a communication channel.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "arn:aws:sns:us-east-1:123456789012:mystack-mytopic-NZJ5JSMVGFIE"
+ //
+ // [topic]: https://docs.aws.amazon.com/sns/latest/dg/sns-create-topic.html
+ AWSSNSTopicARNKey = attribute.Key("aws.sns.topic.arn")
+
+ // AWSSQSQueueURLKey is the attribute Key conforming to the "aws.sqs.queue.url"
+ // semantic conventions. It represents the URL of the AWS SQS Queue. It's a
+ // unique identifier for a queue in Amazon Simple Queue Service (SQS) and is
+ // used to access the queue and perform actions on it.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "https://sqs.us-east-1.amazonaws.com/123456789012/MyQueue"
+ AWSSQSQueueURLKey = attribute.Key("aws.sqs.queue.url")
+
+ // AWSStepFunctionsActivityARNKey is the attribute Key conforming to the
+ // "aws.step_functions.activity.arn" semantic conventions. It represents the ARN
+ // of the AWS Step Functions Activity.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "arn:aws:states:us-east-1:123456789012:activity:get-greeting"
+ AWSStepFunctionsActivityARNKey = attribute.Key("aws.step_functions.activity.arn")
+
+ // AWSStepFunctionsStateMachineARNKey is the attribute Key conforming to the
+ // "aws.step_functions.state_machine.arn" semantic conventions. It represents
+ // the ARN of the AWS Step Functions State Machine.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // "arn:aws:states:us-east-1:123456789012:stateMachine:myStateMachine:1"
+ AWSStepFunctionsStateMachineARNKey = attribute.Key("aws.step_functions.state_machine.arn")
+)
+
+// AWSBedrockGuardrailID returns an attribute KeyValue conforming to the
+// "aws.bedrock.guardrail.id" semantic conventions. It represents the unique
+// identifier of the AWS Bedrock Guardrail. A [guardrail] helps safeguard and
+// prevent unwanted behavior from model responses or user messages.
+//
+// [guardrail]: https://docs.aws.amazon.com/bedrock/latest/userguide/guardrails.html
+func AWSBedrockGuardrailID(val string) attribute.KeyValue {
+ return AWSBedrockGuardrailIDKey.String(val)
+}
+
+// AWSBedrockKnowledgeBaseID returns an attribute KeyValue conforming to the
+// "aws.bedrock.knowledge_base.id" semantic conventions. It represents the unique
+// identifier of the AWS Bedrock Knowledge base. A [knowledge base] is a bank of
+// information that can be queried by models to generate more relevant responses
+// and augment prompts.
+//
+// [knowledge base]: https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base.html
+func AWSBedrockKnowledgeBaseID(val string) attribute.KeyValue {
+ return AWSBedrockKnowledgeBaseIDKey.String(val)
+}
+
+// AWSDynamoDBAttributeDefinitions returns an attribute KeyValue conforming to
+// the "aws.dynamodb.attribute_definitions" semantic conventions. It represents
+// the JSON-serialized value of each item in the `AttributeDefinitions` request
+// field.
+func AWSDynamoDBAttributeDefinitions(val ...string) attribute.KeyValue {
+ return AWSDynamoDBAttributeDefinitionsKey.StringSlice(val)
+}
+
+// AWSDynamoDBAttributesToGet returns an attribute KeyValue conforming to the
+// "aws.dynamodb.attributes_to_get" semantic conventions. It represents the value
+// of the `AttributesToGet` request parameter.
+func AWSDynamoDBAttributesToGet(val ...string) attribute.KeyValue {
+ return AWSDynamoDBAttributesToGetKey.StringSlice(val)
+}
+
+// AWSDynamoDBConsistentRead returns an attribute KeyValue conforming to the
+// "aws.dynamodb.consistent_read" semantic conventions. It represents the value
+// of the `ConsistentRead` request parameter.
+func AWSDynamoDBConsistentRead(val bool) attribute.KeyValue {
+ return AWSDynamoDBConsistentReadKey.Bool(val)
+}
+
+// AWSDynamoDBConsumedCapacity returns an attribute KeyValue conforming to the
+// "aws.dynamodb.consumed_capacity" semantic conventions. It represents the
+// JSON-serialized value of each item in the `ConsumedCapacity` response field.
+func AWSDynamoDBConsumedCapacity(val ...string) attribute.KeyValue {
+ return AWSDynamoDBConsumedCapacityKey.StringSlice(val)
+}
+
+// AWSDynamoDBCount returns an attribute KeyValue conforming to the
+// "aws.dynamodb.count" semantic conventions. It represents the value of the
+// `Count` response parameter.
+func AWSDynamoDBCount(val int) attribute.KeyValue {
+ return AWSDynamoDBCountKey.Int(val)
+}
+
+// AWSDynamoDBExclusiveStartTable returns an attribute KeyValue conforming to the
+// "aws.dynamodb.exclusive_start_table" semantic conventions. It represents the
+// value of the `ExclusiveStartTableName` request parameter.
+func AWSDynamoDBExclusiveStartTable(val string) attribute.KeyValue {
+ return AWSDynamoDBExclusiveStartTableKey.String(val)
+}
+
+// AWSDynamoDBGlobalSecondaryIndexUpdates returns an attribute KeyValue
+// conforming to the "aws.dynamodb.global_secondary_index_updates" semantic
+// conventions. It represents the JSON-serialized value of each item in the
+// `GlobalSecondaryIndexUpdates` request field.
+func AWSDynamoDBGlobalSecondaryIndexUpdates(val ...string) attribute.KeyValue {
+ return AWSDynamoDBGlobalSecondaryIndexUpdatesKey.StringSlice(val)
+}
+
+// AWSDynamoDBGlobalSecondaryIndexes returns an attribute KeyValue conforming to
+// the "aws.dynamodb.global_secondary_indexes" semantic conventions. It
+// represents the JSON-serialized value of each item of the
+// `GlobalSecondaryIndexes` request field.
+func AWSDynamoDBGlobalSecondaryIndexes(val ...string) attribute.KeyValue {
+ return AWSDynamoDBGlobalSecondaryIndexesKey.StringSlice(val)
+}
+
+// AWSDynamoDBIndexName returns an attribute KeyValue conforming to the
+// "aws.dynamodb.index_name" semantic conventions. It represents the value of the
+// `IndexName` request parameter.
+func AWSDynamoDBIndexName(val string) attribute.KeyValue {
+ return AWSDynamoDBIndexNameKey.String(val)
+}
+
+// AWSDynamoDBItemCollectionMetrics returns an attribute KeyValue conforming to
+// the "aws.dynamodb.item_collection_metrics" semantic conventions. It represents
+// the JSON-serialized value of the `ItemCollectionMetrics` response field.
+func AWSDynamoDBItemCollectionMetrics(val string) attribute.KeyValue {
+ return AWSDynamoDBItemCollectionMetricsKey.String(val)
+}
+
+// AWSDynamoDBLimit returns an attribute KeyValue conforming to the
+// "aws.dynamodb.limit" semantic conventions. It represents the value of the
+// `Limit` request parameter.
+func AWSDynamoDBLimit(val int) attribute.KeyValue {
+ return AWSDynamoDBLimitKey.Int(val)
+}
+
+// AWSDynamoDBLocalSecondaryIndexes returns an attribute KeyValue conforming to
+// the "aws.dynamodb.local_secondary_indexes" semantic conventions. It represents
+// the JSON-serialized value of each item of the `LocalSecondaryIndexes` request
+// field.
+func AWSDynamoDBLocalSecondaryIndexes(val ...string) attribute.KeyValue {
+ return AWSDynamoDBLocalSecondaryIndexesKey.StringSlice(val)
+}
+
+// AWSDynamoDBProjection returns an attribute KeyValue conforming to the
+// "aws.dynamodb.projection" semantic conventions. It represents the value of the
+// `ProjectionExpression` request parameter.
+func AWSDynamoDBProjection(val string) attribute.KeyValue {
+ return AWSDynamoDBProjectionKey.String(val)
+}
+
+// AWSDynamoDBProvisionedReadCapacity returns an attribute KeyValue conforming to
+// the "aws.dynamodb.provisioned_read_capacity" semantic conventions. It
+// represents the value of the `ProvisionedThroughput.ReadCapacityUnits` request
+// parameter.
+func AWSDynamoDBProvisionedReadCapacity(val float64) attribute.KeyValue {
+ return AWSDynamoDBProvisionedReadCapacityKey.Float64(val)
+}
+
+// AWSDynamoDBProvisionedWriteCapacity returns an attribute KeyValue conforming
+// to the "aws.dynamodb.provisioned_write_capacity" semantic conventions. It
+// represents the value of the `ProvisionedThroughput.WriteCapacityUnits` request
+// parameter.
+func AWSDynamoDBProvisionedWriteCapacity(val float64) attribute.KeyValue {
+ return AWSDynamoDBProvisionedWriteCapacityKey.Float64(val)
+}
+
+// AWSDynamoDBScanForward returns an attribute KeyValue conforming to the
+// "aws.dynamodb.scan_forward" semantic conventions. It represents the value of
+// the `ScanIndexForward` request parameter.
+func AWSDynamoDBScanForward(val bool) attribute.KeyValue {
+ return AWSDynamoDBScanForwardKey.Bool(val)
+}
+
+// AWSDynamoDBScannedCount returns an attribute KeyValue conforming to the
+// "aws.dynamodb.scanned_count" semantic conventions. It represents the value of
+// the `ScannedCount` response parameter.
+func AWSDynamoDBScannedCount(val int) attribute.KeyValue {
+ return AWSDynamoDBScannedCountKey.Int(val)
+}
+
+// AWSDynamoDBSegment returns an attribute KeyValue conforming to the
+// "aws.dynamodb.segment" semantic conventions. It represents the value of the
+// `Segment` request parameter.
+func AWSDynamoDBSegment(val int) attribute.KeyValue {
+ return AWSDynamoDBSegmentKey.Int(val)
+}
+
+// AWSDynamoDBSelect returns an attribute KeyValue conforming to the
+// "aws.dynamodb.select" semantic conventions. It represents the value of the
+// `Select` request parameter.
+func AWSDynamoDBSelect(val string) attribute.KeyValue {
+ return AWSDynamoDBSelectKey.String(val)
+}
+
+// AWSDynamoDBTableCount returns an attribute KeyValue conforming to the
+// "aws.dynamodb.table_count" semantic conventions. It represents the number of
+// items in the `TableNames` response parameter.
+func AWSDynamoDBTableCount(val int) attribute.KeyValue {
+ return AWSDynamoDBTableCountKey.Int(val)
+}
+
+// AWSDynamoDBTableNames returns an attribute KeyValue conforming to the
+// "aws.dynamodb.table_names" semantic conventions. It represents the keys in the
+// `RequestItems` object field.
+func AWSDynamoDBTableNames(val ...string) attribute.KeyValue {
+ return AWSDynamoDBTableNamesKey.StringSlice(val)
+}
+
+// AWSDynamoDBTotalSegments returns an attribute KeyValue conforming to the
+// "aws.dynamodb.total_segments" semantic conventions. It represents the value of
+// the `TotalSegments` request parameter.
+func AWSDynamoDBTotalSegments(val int) attribute.KeyValue {
+ return AWSDynamoDBTotalSegmentsKey.Int(val)
+}
+
+// AWSECSClusterARN returns an attribute KeyValue conforming to the
+// "aws.ecs.cluster.arn" semantic conventions. It represents the ARN of an
+// [ECS cluster].
+//
+// [ECS cluster]: https://docs.aws.amazon.com/AmazonECS/latest/developerguide/clusters.html
+func AWSECSClusterARN(val string) attribute.KeyValue {
+ return AWSECSClusterARNKey.String(val)
+}
+
+// AWSECSContainerARN returns an attribute KeyValue conforming to the
+// "aws.ecs.container.arn" semantic conventions. It represents the Amazon
+// Resource Name (ARN) of an [ECS container instance].
+//
+// [ECS container instance]: https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ECS_instances.html
+func AWSECSContainerARN(val string) attribute.KeyValue {
+ return AWSECSContainerARNKey.String(val)
+}
+
+// AWSECSTaskARN returns an attribute KeyValue conforming to the
+// "aws.ecs.task.arn" semantic conventions. It represents the ARN of a running
+// [ECS task].
+//
+// [ECS task]: https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ecs-account-settings.html#ecs-resource-ids
+func AWSECSTaskARN(val string) attribute.KeyValue {
+ return AWSECSTaskARNKey.String(val)
+}
+
+// AWSECSTaskFamily returns an attribute KeyValue conforming to the
+// "aws.ecs.task.family" semantic conventions. It represents the family name of
+// the [ECS task definition] used to create the ECS task.
+//
+// [ECS task definition]: https://docs.aws.amazon.com/AmazonECS/latest/developerguide/task_definitions.html
+func AWSECSTaskFamily(val string) attribute.KeyValue {
+ return AWSECSTaskFamilyKey.String(val)
+}
+
+// AWSECSTaskID returns an attribute KeyValue conforming to the "aws.ecs.task.id"
+// semantic conventions. It represents the ID of a running ECS task. The ID MUST
+// be extracted from `task.arn`.
+func AWSECSTaskID(val string) attribute.KeyValue {
+ return AWSECSTaskIDKey.String(val)
+}
+
+// AWSECSTaskRevision returns an attribute KeyValue conforming to the
+// "aws.ecs.task.revision" semantic conventions. It represents the revision for
+// the task definition used to create the ECS task.
+func AWSECSTaskRevision(val string) attribute.KeyValue {
+ return AWSECSTaskRevisionKey.String(val)
+}
+
+// AWSEKSClusterARN returns an attribute KeyValue conforming to the
+// "aws.eks.cluster.arn" semantic conventions. It represents the ARN of an EKS
+// cluster.
+func AWSEKSClusterARN(val string) attribute.KeyValue {
+ return AWSEKSClusterARNKey.String(val)
+}
+
+// AWSExtendedRequestID returns an attribute KeyValue conforming to the
+// "aws.extended_request_id" semantic conventions. It represents the AWS extended
+// request ID as returned in the response header `x-amz-id-2`.
+func AWSExtendedRequestID(val string) attribute.KeyValue {
+ return AWSExtendedRequestIDKey.String(val)
+}
+
+// AWSKinesisStreamName returns an attribute KeyValue conforming to the
+// "aws.kinesis.stream_name" semantic conventions. It represents the name of the
+// AWS Kinesis [stream] the request refers to. Corresponds to the `--stream-name`
+// parameter of the Kinesis [describe-stream] operation.
+//
+// [stream]: https://docs.aws.amazon.com/streams/latest/dev/introduction.html
+// [describe-stream]: https://docs.aws.amazon.com/cli/latest/reference/kinesis/describe-stream.html
+func AWSKinesisStreamName(val string) attribute.KeyValue {
+ return AWSKinesisStreamNameKey.String(val)
+}
+
+// AWSLambdaInvokedARN returns an attribute KeyValue conforming to the
+// "aws.lambda.invoked_arn" semantic conventions. It represents the full invoked
+// ARN as provided on the `Context` passed to the function (
+// `Lambda-Runtime-Invoked-Function-Arn` header on the `/runtime/invocation/next`
+// applicable).
+func AWSLambdaInvokedARN(val string) attribute.KeyValue {
+ return AWSLambdaInvokedARNKey.String(val)
+}
+
+// AWSLambdaResourceMappingID returns an attribute KeyValue conforming to the
+// "aws.lambda.resource_mapping.id" semantic conventions. It represents the UUID
+// of the [AWS Lambda EvenSource Mapping]. An event source is mapped to a lambda
+// function. It's contents are read by Lambda and used to trigger a function.
+// This isn't available in the lambda execution context or the lambda runtime
+// environtment. This is going to be populated by the AWS SDK for each language
+// when that UUID is present. Some of these operations are
+// Create/Delete/Get/List/Update EventSourceMapping.
+//
+// [AWS Lambda EvenSource Mapping]: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-lambda-eventsourcemapping.html
+func AWSLambdaResourceMappingID(val string) attribute.KeyValue {
+ return AWSLambdaResourceMappingIDKey.String(val)
+}
+
+// AWSLogGroupARNs returns an attribute KeyValue conforming to the
+// "aws.log.group.arns" semantic conventions. It represents the Amazon Resource
+// Name(s) (ARN) of the AWS log group(s).
+func AWSLogGroupARNs(val ...string) attribute.KeyValue {
+ return AWSLogGroupARNsKey.StringSlice(val)
+}
+
+// AWSLogGroupNames returns an attribute KeyValue conforming to the
+// "aws.log.group.names" semantic conventions. It represents the name(s) of the
+// AWS log group(s) an application is writing to.
+func AWSLogGroupNames(val ...string) attribute.KeyValue {
+ return AWSLogGroupNamesKey.StringSlice(val)
+}
+
+// AWSLogStreamARNs returns an attribute KeyValue conforming to the
+// "aws.log.stream.arns" semantic conventions. It represents the ARN(s) of the
+// AWS log stream(s).
+func AWSLogStreamARNs(val ...string) attribute.KeyValue {
+ return AWSLogStreamARNsKey.StringSlice(val)
+}
+
+// AWSLogStreamNames returns an attribute KeyValue conforming to the
+// "aws.log.stream.names" semantic conventions. It represents the name(s) of the
+// AWS log stream(s) an application is writing to.
+func AWSLogStreamNames(val ...string) attribute.KeyValue {
+ return AWSLogStreamNamesKey.StringSlice(val)
+}
+
+// AWSRequestID returns an attribute KeyValue conforming to the "aws.request_id"
+// semantic conventions. It represents the AWS request ID as returned in the
+// response headers `x-amzn-requestid`, `x-amzn-request-id` or `x-amz-request-id`
+// .
+func AWSRequestID(val string) attribute.KeyValue {
+ return AWSRequestIDKey.String(val)
+}
+
+// AWSS3Bucket returns an attribute KeyValue conforming to the "aws.s3.bucket"
+// semantic conventions. It represents the S3 bucket name the request refers to.
+// Corresponds to the `--bucket` parameter of the [S3 API] operations.
+//
+// [S3 API]: https://docs.aws.amazon.com/cli/latest/reference/s3api/index.html
+func AWSS3Bucket(val string) attribute.KeyValue {
+ return AWSS3BucketKey.String(val)
+}
+
+// AWSS3CopySource returns an attribute KeyValue conforming to the
+// "aws.s3.copy_source" semantic conventions. It represents the source object (in
+// the form `bucket`/`key`) for the copy operation.
+func AWSS3CopySource(val string) attribute.KeyValue {
+ return AWSS3CopySourceKey.String(val)
+}
+
+// AWSS3Delete returns an attribute KeyValue conforming to the "aws.s3.delete"
+// semantic conventions. It represents the delete request container that
+// specifies the objects to be deleted.
+func AWSS3Delete(val string) attribute.KeyValue {
+ return AWSS3DeleteKey.String(val)
+}
+
+// AWSS3Key returns an attribute KeyValue conforming to the "aws.s3.key" semantic
+// conventions. It represents the S3 object key the request refers to.
+// Corresponds to the `--key` parameter of the [S3 API] operations.
+//
+// [S3 API]: https://docs.aws.amazon.com/cli/latest/reference/s3api/index.html
+func AWSS3Key(val string) attribute.KeyValue {
+ return AWSS3KeyKey.String(val)
+}
+
+// AWSS3PartNumber returns an attribute KeyValue conforming to the
+// "aws.s3.part_number" semantic conventions. It represents the part number of
+// the part being uploaded in a multipart-upload operation. This is a positive
+// integer between 1 and 10,000.
+func AWSS3PartNumber(val int) attribute.KeyValue {
+ return AWSS3PartNumberKey.Int(val)
+}
+
+// AWSS3UploadID returns an attribute KeyValue conforming to the
+// "aws.s3.upload_id" semantic conventions. It represents the upload ID that
+// identifies the multipart upload.
+func AWSS3UploadID(val string) attribute.KeyValue {
+ return AWSS3UploadIDKey.String(val)
+}
+
+// AWSSecretsmanagerSecretARN returns an attribute KeyValue conforming to the
+// "aws.secretsmanager.secret.arn" semantic conventions. It represents the ARN of
+// the Secret stored in the Secrets Mangger.
+func AWSSecretsmanagerSecretARN(val string) attribute.KeyValue {
+ return AWSSecretsmanagerSecretARNKey.String(val)
+}
+
+// AWSSNSTopicARN returns an attribute KeyValue conforming to the
+// "aws.sns.topic.arn" semantic conventions. It represents the ARN of the AWS SNS
+// Topic. An Amazon SNS [topic] is a logical access point that acts as a
+// communication channel.
+//
+// [topic]: https://docs.aws.amazon.com/sns/latest/dg/sns-create-topic.html
+func AWSSNSTopicARN(val string) attribute.KeyValue {
+ return AWSSNSTopicARNKey.String(val)
+}
+
+// AWSSQSQueueURL returns an attribute KeyValue conforming to the
+// "aws.sqs.queue.url" semantic conventions. It represents the URL of the AWS SQS
+// Queue. It's a unique identifier for a queue in Amazon Simple Queue Service
+// (SQS) and is used to access the queue and perform actions on it.
+func AWSSQSQueueURL(val string) attribute.KeyValue {
+ return AWSSQSQueueURLKey.String(val)
+}
+
+// AWSStepFunctionsActivityARN returns an attribute KeyValue conforming to the
+// "aws.step_functions.activity.arn" semantic conventions. It represents the ARN
+// of the AWS Step Functions Activity.
+func AWSStepFunctionsActivityARN(val string) attribute.KeyValue {
+ return AWSStepFunctionsActivityARNKey.String(val)
+}
+
+// AWSStepFunctionsStateMachineARN returns an attribute KeyValue conforming to
+// the "aws.step_functions.state_machine.arn" semantic conventions. It represents
+// the ARN of the AWS Step Functions State Machine.
+func AWSStepFunctionsStateMachineARN(val string) attribute.KeyValue {
+ return AWSStepFunctionsStateMachineARNKey.String(val)
+}
+
+// Enum values for aws.ecs.launchtype
+var (
+ // Amazon EC2
+ // Stability: development
+ AWSECSLaunchtypeEC2 = AWSECSLaunchtypeKey.String("ec2")
+ // Amazon Fargate
+ // Stability: development
+ AWSECSLaunchtypeFargate = AWSECSLaunchtypeKey.String("fargate")
+)
+
+// Namespace: azure
+const (
+ // AzureClientIDKey is the attribute Key conforming to the "azure.client.id"
+ // semantic conventions. It represents the unique identifier of the client
+ // instance.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "3ba4827d-4422-483f-b59f-85b74211c11d", "storage-client-1"
+ AzureClientIDKey = attribute.Key("azure.client.id")
+
+ // AzureCosmosDBConnectionModeKey is the attribute Key conforming to the
+ // "azure.cosmosdb.connection.mode" semantic conventions. It represents the
+ // cosmos client connection mode.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ AzureCosmosDBConnectionModeKey = attribute.Key("azure.cosmosdb.connection.mode")
+
+ // AzureCosmosDBConsistencyLevelKey is the attribute Key conforming to the
+ // "azure.cosmosdb.consistency.level" semantic conventions. It represents the
+ // account or request [consistency level].
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Eventual", "ConsistentPrefix", "BoundedStaleness", "Strong",
+ // "Session"
+ //
+ // [consistency level]: https://learn.microsoft.com/azure/cosmos-db/consistency-levels
+ AzureCosmosDBConsistencyLevelKey = attribute.Key("azure.cosmosdb.consistency.level")
+
+ // AzureCosmosDBOperationContactedRegionsKey is the attribute Key conforming to
+ // the "azure.cosmosdb.operation.contacted_regions" semantic conventions. It
+ // represents the list of regions contacted during operation in the order that
+ // they were contacted. If there is more than one region listed, it indicates
+ // that the operation was performed on multiple regions i.e. cross-regional
+ // call.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "North Central US", "Australia East", "Australia Southeast"
+ // Note: Region name matches the format of `displayName` in [Azure Location API]
+ //
+ // [Azure Location API]: https://learn.microsoft.com/rest/api/resources/subscriptions/list-locations
+ AzureCosmosDBOperationContactedRegionsKey = attribute.Key("azure.cosmosdb.operation.contacted_regions")
+
+ // AzureCosmosDBOperationRequestChargeKey is the attribute Key conforming to the
+ // "azure.cosmosdb.operation.request_charge" semantic conventions. It represents
+ // the number of request units consumed by the operation.
+ //
+ // Type: double
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 46.18, 1.0
+ AzureCosmosDBOperationRequestChargeKey = attribute.Key("azure.cosmosdb.operation.request_charge")
+
+ // AzureCosmosDBRequestBodySizeKey is the attribute Key conforming to the
+ // "azure.cosmosdb.request.body.size" semantic conventions. It represents the
+ // request payload size in bytes.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ AzureCosmosDBRequestBodySizeKey = attribute.Key("azure.cosmosdb.request.body.size")
+
+ // AzureCosmosDBResponseSubStatusCodeKey is the attribute Key conforming to the
+ // "azure.cosmosdb.response.sub_status_code" semantic conventions. It represents
+ // the cosmos DB sub status code.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 1000, 1002
+ AzureCosmosDBResponseSubStatusCodeKey = attribute.Key("azure.cosmosdb.response.sub_status_code")
+
+ // AzureResourceProviderNamespaceKey is the attribute Key conforming to the
+ // "azure.resource_provider.namespace" semantic conventions. It represents the
+ // [Azure Resource Provider Namespace] as recognized by the client.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Microsoft.Storage", "Microsoft.KeyVault", "Microsoft.ServiceBus"
+ //
+ // [Azure Resource Provider Namespace]: https://learn.microsoft.com/azure/azure-resource-manager/management/azure-services-resource-providers
+ AzureResourceProviderNamespaceKey = attribute.Key("azure.resource_provider.namespace")
+
+ // AzureServiceRequestIDKey is the attribute Key conforming to the
+ // "azure.service.request.id" semantic conventions. It represents the unique
+ // identifier of the service request. It's generated by the Azure service and
+ // returned with the response.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "00000000-0000-0000-0000-000000000000"
+ AzureServiceRequestIDKey = attribute.Key("azure.service.request.id")
+)
+
+// AzureClientID returns an attribute KeyValue conforming to the
+// "azure.client.id" semantic conventions. It represents the unique identifier of
+// the client instance.
+func AzureClientID(val string) attribute.KeyValue {
+ return AzureClientIDKey.String(val)
+}
+
+// AzureCosmosDBOperationContactedRegions returns an attribute KeyValue
+// conforming to the "azure.cosmosdb.operation.contacted_regions" semantic
+// conventions. It represents the list of regions contacted during operation in
+// the order that they were contacted. If there is more than one region listed,
+// it indicates that the operation was performed on multiple regions i.e.
+// cross-regional call.
+func AzureCosmosDBOperationContactedRegions(val ...string) attribute.KeyValue {
+ return AzureCosmosDBOperationContactedRegionsKey.StringSlice(val)
+}
+
+// AzureCosmosDBOperationRequestCharge returns an attribute KeyValue conforming
+// to the "azure.cosmosdb.operation.request_charge" semantic conventions. It
+// represents the number of request units consumed by the operation.
+func AzureCosmosDBOperationRequestCharge(val float64) attribute.KeyValue {
+ return AzureCosmosDBOperationRequestChargeKey.Float64(val)
+}
+
+// AzureCosmosDBRequestBodySize returns an attribute KeyValue conforming to the
+// "azure.cosmosdb.request.body.size" semantic conventions. It represents the
+// request payload size in bytes.
+func AzureCosmosDBRequestBodySize(val int) attribute.KeyValue {
+ return AzureCosmosDBRequestBodySizeKey.Int(val)
+}
+
+// AzureCosmosDBResponseSubStatusCode returns an attribute KeyValue conforming to
+// the "azure.cosmosdb.response.sub_status_code" semantic conventions. It
+// represents the cosmos DB sub status code.
+func AzureCosmosDBResponseSubStatusCode(val int) attribute.KeyValue {
+ return AzureCosmosDBResponseSubStatusCodeKey.Int(val)
+}
+
+// AzureResourceProviderNamespace returns an attribute KeyValue conforming to the
+// "azure.resource_provider.namespace" semantic conventions. It represents the
+// [Azure Resource Provider Namespace] as recognized by the client.
+//
+// [Azure Resource Provider Namespace]: https://learn.microsoft.com/azure/azure-resource-manager/management/azure-services-resource-providers
+func AzureResourceProviderNamespace(val string) attribute.KeyValue {
+ return AzureResourceProviderNamespaceKey.String(val)
+}
+
+// AzureServiceRequestID returns an attribute KeyValue conforming to the
+// "azure.service.request.id" semantic conventions. It represents the unique
+// identifier of the service request. It's generated by the Azure service and
+// returned with the response.
+func AzureServiceRequestID(val string) attribute.KeyValue {
+ return AzureServiceRequestIDKey.String(val)
+}
+
+// Enum values for azure.cosmosdb.connection.mode
+var (
+ // Gateway (HTTP) connection.
+ // Stability: development
+ AzureCosmosDBConnectionModeGateway = AzureCosmosDBConnectionModeKey.String("gateway")
+ // Direct connection.
+ // Stability: development
+ AzureCosmosDBConnectionModeDirect = AzureCosmosDBConnectionModeKey.String("direct")
+)
+
+// Enum values for azure.cosmosdb.consistency.level
+var (
+ // Strong
+ // Stability: development
+ AzureCosmosDBConsistencyLevelStrong = AzureCosmosDBConsistencyLevelKey.String("Strong")
+ // Bounded Staleness
+ // Stability: development
+ AzureCosmosDBConsistencyLevelBoundedStaleness = AzureCosmosDBConsistencyLevelKey.String("BoundedStaleness")
+ // Session
+ // Stability: development
+ AzureCosmosDBConsistencyLevelSession = AzureCosmosDBConsistencyLevelKey.String("Session")
+ // Eventual
+ // Stability: development
+ AzureCosmosDBConsistencyLevelEventual = AzureCosmosDBConsistencyLevelKey.String("Eventual")
+ // Consistent Prefix
+ // Stability: development
+ AzureCosmosDBConsistencyLevelConsistentPrefix = AzureCosmosDBConsistencyLevelKey.String("ConsistentPrefix")
+)
+
+// Namespace: browser
+const (
+ // BrowserBrandsKey is the attribute Key conforming to the "browser.brands"
+ // semantic conventions. It represents the array of brand name and version
+ // separated by a space.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: " Not A;Brand 99", "Chromium 99", "Chrome 99"
+ // Note: This value is intended to be taken from the [UA client hints API] (
+ // `navigator.userAgentData.brands`).
+ //
+ // [UA client hints API]: https://wicg.github.io/ua-client-hints/#interface
+ BrowserBrandsKey = attribute.Key("browser.brands")
+
+ // BrowserLanguageKey is the attribute Key conforming to the "browser.language"
+ // semantic conventions. It represents the preferred language of the user using
+ // the browser.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "en", "en-US", "fr", "fr-FR"
+ // Note: This value is intended to be taken from the Navigator API
+ // `navigator.language`.
+ BrowserLanguageKey = attribute.Key("browser.language")
+
+ // BrowserMobileKey is the attribute Key conforming to the "browser.mobile"
+ // semantic conventions. It represents a boolean that is true if the browser is
+ // running on a mobile device.
+ //
+ // Type: boolean
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // Note: This value is intended to be taken from the [UA client hints API] (
+ // `navigator.userAgentData.mobile`). If unavailable, this attribute SHOULD be
+ // left unset.
+ //
+ // [UA client hints API]: https://wicg.github.io/ua-client-hints/#interface
+ BrowserMobileKey = attribute.Key("browser.mobile")
+
+ // BrowserPlatformKey is the attribute Key conforming to the "browser.platform"
+ // semantic conventions. It represents the platform on which the browser is
+ // running.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Windows", "macOS", "Android"
+ // Note: This value is intended to be taken from the [UA client hints API] (
+ // `navigator.userAgentData.platform`). If unavailable, the legacy
+ // `navigator.platform` API SHOULD NOT be used instead and this attribute SHOULD
+ // be left unset in order for the values to be consistent.
+ // The list of possible values is defined in the
+ // [W3C User-Agent Client Hints specification]. Note that some (but not all) of
+ // these values can overlap with values in the
+ // [`os.type` and `os.name` attributes]. However, for consistency, the values in
+ // the `browser.platform` attribute should capture the exact value that the user
+ // agent provides.
+ //
+ // [UA client hints API]: https://wicg.github.io/ua-client-hints/#interface
+ // [W3C User-Agent Client Hints specification]: https://wicg.github.io/ua-client-hints/#sec-ch-ua-platform
+ // [`os.type` and `os.name` attributes]: ./os.md
+ BrowserPlatformKey = attribute.Key("browser.platform")
+)
+
+// BrowserBrands returns an attribute KeyValue conforming to the "browser.brands"
+// semantic conventions. It represents the array of brand name and version
+// separated by a space.
+func BrowserBrands(val ...string) attribute.KeyValue {
+ return BrowserBrandsKey.StringSlice(val)
+}
+
+// BrowserLanguage returns an attribute KeyValue conforming to the
+// "browser.language" semantic conventions. It represents the preferred language
+// of the user using the browser.
+func BrowserLanguage(val string) attribute.KeyValue {
+ return BrowserLanguageKey.String(val)
+}
+
+// BrowserMobile returns an attribute KeyValue conforming to the "browser.mobile"
+// semantic conventions. It represents a boolean that is true if the browser is
+// running on a mobile device.
+func BrowserMobile(val bool) attribute.KeyValue {
+ return BrowserMobileKey.Bool(val)
+}
+
+// BrowserPlatform returns an attribute KeyValue conforming to the
+// "browser.platform" semantic conventions. It represents the platform on which
+// the browser is running.
+func BrowserPlatform(val string) attribute.KeyValue {
+ return BrowserPlatformKey.String(val)
+}
+
+// Namespace: cassandra
+const (
+ // CassandraConsistencyLevelKey is the attribute Key conforming to the
+ // "cassandra.consistency.level" semantic conventions. It represents the
+ // consistency level of the query. Based on consistency values from [CQL].
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ //
+ // [CQL]: https://docs.datastax.com/en/cassandra-oss/3.0/cassandra/dml/dmlConfigConsistency.html
+ CassandraConsistencyLevelKey = attribute.Key("cassandra.consistency.level")
+
+ // CassandraCoordinatorDCKey is the attribute Key conforming to the
+ // "cassandra.coordinator.dc" semantic conventions. It represents the data
+ // center of the coordinating node for a query.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: us-west-2
+ CassandraCoordinatorDCKey = attribute.Key("cassandra.coordinator.dc")
+
+ // CassandraCoordinatorIDKey is the attribute Key conforming to the
+ // "cassandra.coordinator.id" semantic conventions. It represents the ID of the
+ // coordinating node for a query.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: be13faa2-8574-4d71-926d-27f16cf8a7af
+ CassandraCoordinatorIDKey = attribute.Key("cassandra.coordinator.id")
+
+ // CassandraPageSizeKey is the attribute Key conforming to the
+ // "cassandra.page.size" semantic conventions. It represents the fetch size used
+ // for paging, i.e. how many rows will be returned at once.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 5000
+ CassandraPageSizeKey = attribute.Key("cassandra.page.size")
+
+ // CassandraQueryIdempotentKey is the attribute Key conforming to the
+ // "cassandra.query.idempotent" semantic conventions. It represents the whether
+ // or not the query is idempotent.
+ //
+ // Type: boolean
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ CassandraQueryIdempotentKey = attribute.Key("cassandra.query.idempotent")
+
+ // CassandraSpeculativeExecutionCountKey is the attribute Key conforming to the
+ // "cassandra.speculative_execution.count" semantic conventions. It represents
+ // the number of times a query was speculatively executed. Not set or `0` if the
+ // query was not executed speculatively.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 0, 2
+ CassandraSpeculativeExecutionCountKey = attribute.Key("cassandra.speculative_execution.count")
+)
+
+// CassandraCoordinatorDC returns an attribute KeyValue conforming to the
+// "cassandra.coordinator.dc" semantic conventions. It represents the data center
+// of the coordinating node for a query.
+func CassandraCoordinatorDC(val string) attribute.KeyValue {
+ return CassandraCoordinatorDCKey.String(val)
+}
+
+// CassandraCoordinatorID returns an attribute KeyValue conforming to the
+// "cassandra.coordinator.id" semantic conventions. It represents the ID of the
+// coordinating node for a query.
+func CassandraCoordinatorID(val string) attribute.KeyValue {
+ return CassandraCoordinatorIDKey.String(val)
+}
+
+// CassandraPageSize returns an attribute KeyValue conforming to the
+// "cassandra.page.size" semantic conventions. It represents the fetch size used
+// for paging, i.e. how many rows will be returned at once.
+func CassandraPageSize(val int) attribute.KeyValue {
+ return CassandraPageSizeKey.Int(val)
+}
+
+// CassandraQueryIdempotent returns an attribute KeyValue conforming to the
+// "cassandra.query.idempotent" semantic conventions. It represents the whether
+// or not the query is idempotent.
+func CassandraQueryIdempotent(val bool) attribute.KeyValue {
+ return CassandraQueryIdempotentKey.Bool(val)
+}
+
+// CassandraSpeculativeExecutionCount returns an attribute KeyValue conforming to
+// the "cassandra.speculative_execution.count" semantic conventions. It
+// represents the number of times a query was speculatively executed. Not set or
+// `0` if the query was not executed speculatively.
+func CassandraSpeculativeExecutionCount(val int) attribute.KeyValue {
+ return CassandraSpeculativeExecutionCountKey.Int(val)
+}
+
+// Enum values for cassandra.consistency.level
+var (
+ // All
+ // Stability: development
+ CassandraConsistencyLevelAll = CassandraConsistencyLevelKey.String("all")
+ // Each Quorum
+ // Stability: development
+ CassandraConsistencyLevelEachQuorum = CassandraConsistencyLevelKey.String("each_quorum")
+ // Quorum
+ // Stability: development
+ CassandraConsistencyLevelQuorum = CassandraConsistencyLevelKey.String("quorum")
+ // Local Quorum
+ // Stability: development
+ CassandraConsistencyLevelLocalQuorum = CassandraConsistencyLevelKey.String("local_quorum")
+ // One
+ // Stability: development
+ CassandraConsistencyLevelOne = CassandraConsistencyLevelKey.String("one")
+ // Two
+ // Stability: development
+ CassandraConsistencyLevelTwo = CassandraConsistencyLevelKey.String("two")
+ // Three
+ // Stability: development
+ CassandraConsistencyLevelThree = CassandraConsistencyLevelKey.String("three")
+ // Local One
+ // Stability: development
+ CassandraConsistencyLevelLocalOne = CassandraConsistencyLevelKey.String("local_one")
+ // Any
+ // Stability: development
+ CassandraConsistencyLevelAny = CassandraConsistencyLevelKey.String("any")
+ // Serial
+ // Stability: development
+ CassandraConsistencyLevelSerial = CassandraConsistencyLevelKey.String("serial")
+ // Local Serial
+ // Stability: development
+ CassandraConsistencyLevelLocalSerial = CassandraConsistencyLevelKey.String("local_serial")
+)
+
+// Namespace: cicd
+const (
+ // CICDPipelineActionNameKey is the attribute Key conforming to the
+ // "cicd.pipeline.action.name" semantic conventions. It represents the kind of
+ // action a pipeline run is performing.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "BUILD", "RUN", "SYNC"
+ CICDPipelineActionNameKey = attribute.Key("cicd.pipeline.action.name")
+
+ // CICDPipelineNameKey is the attribute Key conforming to the
+ // "cicd.pipeline.name" semantic conventions. It represents the human readable
+ // name of the pipeline within a CI/CD system.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Build and Test", "Lint", "Deploy Go Project",
+ // "deploy_to_environment"
+ CICDPipelineNameKey = attribute.Key("cicd.pipeline.name")
+
+ // CICDPipelineResultKey is the attribute Key conforming to the
+ // "cicd.pipeline.result" semantic conventions. It represents the result of a
+ // pipeline run.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "success", "failure", "timeout", "skipped"
+ CICDPipelineResultKey = attribute.Key("cicd.pipeline.result")
+
+ // CICDPipelineRunIDKey is the attribute Key conforming to the
+ // "cicd.pipeline.run.id" semantic conventions. It represents the unique
+ // identifier of a pipeline run within a CI/CD system.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "120912"
+ CICDPipelineRunIDKey = attribute.Key("cicd.pipeline.run.id")
+
+ // CICDPipelineRunStateKey is the attribute Key conforming to the
+ // "cicd.pipeline.run.state" semantic conventions. It represents the pipeline
+ // run goes through these states during its lifecycle.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "pending", "executing", "finalizing"
+ CICDPipelineRunStateKey = attribute.Key("cicd.pipeline.run.state")
+
+ // CICDPipelineRunURLFullKey is the attribute Key conforming to the
+ // "cicd.pipeline.run.url.full" semantic conventions. It represents the [URL] of
+ // the pipeline run, providing the complete address in order to locate and
+ // identify the pipeline run.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // "https://github.com/open-telemetry/semantic-conventions/actions/runs/9753949763?pr=1075"
+ //
+ // [URL]: https://wikipedia.org/wiki/URL
+ CICDPipelineRunURLFullKey = attribute.Key("cicd.pipeline.run.url.full")
+
+ // CICDPipelineTaskNameKey is the attribute Key conforming to the
+ // "cicd.pipeline.task.name" semantic conventions. It represents the human
+ // readable name of a task within a pipeline. Task here most closely aligns with
+ // a [computing process] in a pipeline. Other terms for tasks include commands,
+ // steps, and procedures.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Run GoLang Linter", "Go Build", "go-test", "deploy_binary"
+ //
+ // [computing process]: https://wikipedia.org/wiki/Pipeline_(computing)
+ CICDPipelineTaskNameKey = attribute.Key("cicd.pipeline.task.name")
+
+ // CICDPipelineTaskRunIDKey is the attribute Key conforming to the
+ // "cicd.pipeline.task.run.id" semantic conventions. It represents the unique
+ // identifier of a task run within a pipeline.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "12097"
+ CICDPipelineTaskRunIDKey = attribute.Key("cicd.pipeline.task.run.id")
+
+ // CICDPipelineTaskRunResultKey is the attribute Key conforming to the
+ // "cicd.pipeline.task.run.result" semantic conventions. It represents the
+ // result of a task run.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "success", "failure", "timeout", "skipped"
+ CICDPipelineTaskRunResultKey = attribute.Key("cicd.pipeline.task.run.result")
+
+ // CICDPipelineTaskRunURLFullKey is the attribute Key conforming to the
+ // "cicd.pipeline.task.run.url.full" semantic conventions. It represents the
+ // [URL] of the pipeline task run, providing the complete address in order to
+ // locate and identify the pipeline task run.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // "https://github.com/open-telemetry/semantic-conventions/actions/runs/9753949763/job/26920038674?pr=1075"
+ //
+ // [URL]: https://wikipedia.org/wiki/URL
+ CICDPipelineTaskRunURLFullKey = attribute.Key("cicd.pipeline.task.run.url.full")
+
+ // CICDPipelineTaskTypeKey is the attribute Key conforming to the
+ // "cicd.pipeline.task.type" semantic conventions. It represents the type of the
+ // task within a pipeline.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "build", "test", "deploy"
+ CICDPipelineTaskTypeKey = attribute.Key("cicd.pipeline.task.type")
+
+ // CICDSystemComponentKey is the attribute Key conforming to the
+ // "cicd.system.component" semantic conventions. It represents the name of a
+ // component of the CICD system.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "controller", "scheduler", "agent"
+ CICDSystemComponentKey = attribute.Key("cicd.system.component")
+
+ // CICDWorkerIDKey is the attribute Key conforming to the "cicd.worker.id"
+ // semantic conventions. It represents the unique identifier of a worker within
+ // a CICD system.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "abc123", "10.0.1.2", "controller"
+ CICDWorkerIDKey = attribute.Key("cicd.worker.id")
+
+ // CICDWorkerNameKey is the attribute Key conforming to the "cicd.worker.name"
+ // semantic conventions. It represents the name of a worker within a CICD
+ // system.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "agent-abc", "controller", "Ubuntu LTS"
+ CICDWorkerNameKey = attribute.Key("cicd.worker.name")
+
+ // CICDWorkerStateKey is the attribute Key conforming to the "cicd.worker.state"
+ // semantic conventions. It represents the state of a CICD worker / agent.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "idle", "busy", "down"
+ CICDWorkerStateKey = attribute.Key("cicd.worker.state")
+
+ // CICDWorkerURLFullKey is the attribute Key conforming to the
+ // "cicd.worker.url.full" semantic conventions. It represents the [URL] of the
+ // worker, providing the complete address in order to locate and identify the
+ // worker.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "https://cicd.example.org/worker/abc123"
+ //
+ // [URL]: https://wikipedia.org/wiki/URL
+ CICDWorkerURLFullKey = attribute.Key("cicd.worker.url.full")
+)
+
+// CICDPipelineName returns an attribute KeyValue conforming to the
+// "cicd.pipeline.name" semantic conventions. It represents the human readable
+// name of the pipeline within a CI/CD system.
+func CICDPipelineName(val string) attribute.KeyValue {
+ return CICDPipelineNameKey.String(val)
+}
+
+// CICDPipelineRunID returns an attribute KeyValue conforming to the
+// "cicd.pipeline.run.id" semantic conventions. It represents the unique
+// identifier of a pipeline run within a CI/CD system.
+func CICDPipelineRunID(val string) attribute.KeyValue {
+ return CICDPipelineRunIDKey.String(val)
+}
+
+// CICDPipelineRunURLFull returns an attribute KeyValue conforming to the
+// "cicd.pipeline.run.url.full" semantic conventions. It represents the [URL] of
+// the pipeline run, providing the complete address in order to locate and
+// identify the pipeline run.
+//
+// [URL]: https://wikipedia.org/wiki/URL
+func CICDPipelineRunURLFull(val string) attribute.KeyValue {
+ return CICDPipelineRunURLFullKey.String(val)
+}
+
+// CICDPipelineTaskName returns an attribute KeyValue conforming to the
+// "cicd.pipeline.task.name" semantic conventions. It represents the human
+// readable name of a task within a pipeline. Task here most closely aligns with
+// a [computing process] in a pipeline. Other terms for tasks include commands,
+// steps, and procedures.
+//
+// [computing process]: https://wikipedia.org/wiki/Pipeline_(computing)
+func CICDPipelineTaskName(val string) attribute.KeyValue {
+ return CICDPipelineTaskNameKey.String(val)
+}
+
+// CICDPipelineTaskRunID returns an attribute KeyValue conforming to the
+// "cicd.pipeline.task.run.id" semantic conventions. It represents the unique
+// identifier of a task run within a pipeline.
+func CICDPipelineTaskRunID(val string) attribute.KeyValue {
+ return CICDPipelineTaskRunIDKey.String(val)
+}
+
+// CICDPipelineTaskRunURLFull returns an attribute KeyValue conforming to the
+// "cicd.pipeline.task.run.url.full" semantic conventions. It represents the
+// [URL] of the pipeline task run, providing the complete address in order to
+// locate and identify the pipeline task run.
+//
+// [URL]: https://wikipedia.org/wiki/URL
+func CICDPipelineTaskRunURLFull(val string) attribute.KeyValue {
+ return CICDPipelineTaskRunURLFullKey.String(val)
+}
+
+// CICDSystemComponent returns an attribute KeyValue conforming to the
+// "cicd.system.component" semantic conventions. It represents the name of a
+// component of the CICD system.
+func CICDSystemComponent(val string) attribute.KeyValue {
+ return CICDSystemComponentKey.String(val)
+}
+
+// CICDWorkerID returns an attribute KeyValue conforming to the "cicd.worker.id"
+// semantic conventions. It represents the unique identifier of a worker within a
+// CICD system.
+func CICDWorkerID(val string) attribute.KeyValue {
+ return CICDWorkerIDKey.String(val)
+}
+
+// CICDWorkerName returns an attribute KeyValue conforming to the
+// "cicd.worker.name" semantic conventions. It represents the name of a worker
+// within a CICD system.
+func CICDWorkerName(val string) attribute.KeyValue {
+ return CICDWorkerNameKey.String(val)
+}
+
+// CICDWorkerURLFull returns an attribute KeyValue conforming to the
+// "cicd.worker.url.full" semantic conventions. It represents the [URL] of the
+// worker, providing the complete address in order to locate and identify the
+// worker.
+//
+// [URL]: https://wikipedia.org/wiki/URL
+func CICDWorkerURLFull(val string) attribute.KeyValue {
+ return CICDWorkerURLFullKey.String(val)
+}
+
+// Enum values for cicd.pipeline.action.name
+var (
+ // The pipeline run is executing a build.
+ // Stability: development
+ CICDPipelineActionNameBuild = CICDPipelineActionNameKey.String("BUILD")
+ // The pipeline run is executing.
+ // Stability: development
+ CICDPipelineActionNameRun = CICDPipelineActionNameKey.String("RUN")
+ // The pipeline run is executing a sync.
+ // Stability: development
+ CICDPipelineActionNameSync = CICDPipelineActionNameKey.String("SYNC")
+)
+
+// Enum values for cicd.pipeline.result
+var (
+ // The pipeline run finished successfully.
+ // Stability: development
+ CICDPipelineResultSuccess = CICDPipelineResultKey.String("success")
+ // The pipeline run did not finish successfully, eg. due to a compile error or a
+ // failing test. Such failures are usually detected by non-zero exit codes of
+ // the tools executed in the pipeline run.
+ // Stability: development
+ CICDPipelineResultFailure = CICDPipelineResultKey.String("failure")
+ // The pipeline run failed due to an error in the CICD system, eg. due to the
+ // worker being killed.
+ // Stability: development
+ CICDPipelineResultError = CICDPipelineResultKey.String("error")
+ // A timeout caused the pipeline run to be interrupted.
+ // Stability: development
+ CICDPipelineResultTimeout = CICDPipelineResultKey.String("timeout")
+ // The pipeline run was cancelled, eg. by a user manually cancelling the
+ // pipeline run.
+ // Stability: development
+ CICDPipelineResultCancellation = CICDPipelineResultKey.String("cancellation")
+ // The pipeline run was skipped, eg. due to a precondition not being met.
+ // Stability: development
+ CICDPipelineResultSkip = CICDPipelineResultKey.String("skip")
+)
+
+// Enum values for cicd.pipeline.run.state
+var (
+ // The run pending state spans from the event triggering the pipeline run until
+ // the execution of the run starts (eg. time spent in a queue, provisioning
+ // agents, creating run resources).
+ //
+ // Stability: development
+ CICDPipelineRunStatePending = CICDPipelineRunStateKey.String("pending")
+ // The executing state spans the execution of any run tasks (eg. build, test).
+ // Stability: development
+ CICDPipelineRunStateExecuting = CICDPipelineRunStateKey.String("executing")
+ // The finalizing state spans from when the run has finished executing (eg.
+ // cleanup of run resources).
+ // Stability: development
+ CICDPipelineRunStateFinalizing = CICDPipelineRunStateKey.String("finalizing")
+)
+
+// Enum values for cicd.pipeline.task.run.result
+var (
+ // The task run finished successfully.
+ // Stability: development
+ CICDPipelineTaskRunResultSuccess = CICDPipelineTaskRunResultKey.String("success")
+ // The task run did not finish successfully, eg. due to a compile error or a
+ // failing test. Such failures are usually detected by non-zero exit codes of
+ // the tools executed in the task run.
+ // Stability: development
+ CICDPipelineTaskRunResultFailure = CICDPipelineTaskRunResultKey.String("failure")
+ // The task run failed due to an error in the CICD system, eg. due to the worker
+ // being killed.
+ // Stability: development
+ CICDPipelineTaskRunResultError = CICDPipelineTaskRunResultKey.String("error")
+ // A timeout caused the task run to be interrupted.
+ // Stability: development
+ CICDPipelineTaskRunResultTimeout = CICDPipelineTaskRunResultKey.String("timeout")
+ // The task run was cancelled, eg. by a user manually cancelling the task run.
+ // Stability: development
+ CICDPipelineTaskRunResultCancellation = CICDPipelineTaskRunResultKey.String("cancellation")
+ // The task run was skipped, eg. due to a precondition not being met.
+ // Stability: development
+ CICDPipelineTaskRunResultSkip = CICDPipelineTaskRunResultKey.String("skip")
+)
+
+// Enum values for cicd.pipeline.task.type
+var (
+ // build
+ // Stability: development
+ CICDPipelineTaskTypeBuild = CICDPipelineTaskTypeKey.String("build")
+ // test
+ // Stability: development
+ CICDPipelineTaskTypeTest = CICDPipelineTaskTypeKey.String("test")
+ // deploy
+ // Stability: development
+ CICDPipelineTaskTypeDeploy = CICDPipelineTaskTypeKey.String("deploy")
+)
+
+// Enum values for cicd.worker.state
+var (
+ // The worker is not performing work for the CICD system. It is available to the
+ // CICD system to perform work on (online / idle).
+ // Stability: development
+ CICDWorkerStateAvailable = CICDWorkerStateKey.String("available")
+ // The worker is performing work for the CICD system.
+ // Stability: development
+ CICDWorkerStateBusy = CICDWorkerStateKey.String("busy")
+ // The worker is not available to the CICD system (disconnected / down).
+ // Stability: development
+ CICDWorkerStateOffline = CICDWorkerStateKey.String("offline")
+)
+
+// Namespace: client
+const (
+ // ClientAddressKey is the attribute Key conforming to the "client.address"
+ // semantic conventions. It represents the client address - domain name if
+ // available without reverse DNS lookup; otherwise, IP address or Unix domain
+ // socket name.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "client.example.com", "10.1.2.80", "/tmp/my.sock"
+ // Note: When observed from the server side, and when communicating through an
+ // intermediary, `client.address` SHOULD represent the client address behind any
+ // intermediaries, for example proxies, if it's available.
+ ClientAddressKey = attribute.Key("client.address")
+
+ // ClientPortKey is the attribute Key conforming to the "client.port" semantic
+ // conventions. It represents the client port number.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: 65123
+ // Note: When observed from the server side, and when communicating through an
+ // intermediary, `client.port` SHOULD represent the client port behind any
+ // intermediaries, for example proxies, if it's available.
+ ClientPortKey = attribute.Key("client.port")
+)
+
+// ClientAddress returns an attribute KeyValue conforming to the "client.address"
+// semantic conventions. It represents the client address - domain name if
+// available without reverse DNS lookup; otherwise, IP address or Unix domain
+// socket name.
+func ClientAddress(val string) attribute.KeyValue {
+ return ClientAddressKey.String(val)
+}
+
+// ClientPort returns an attribute KeyValue conforming to the "client.port"
+// semantic conventions. It represents the client port number.
+func ClientPort(val int) attribute.KeyValue {
+ return ClientPortKey.Int(val)
+}
+
+// Namespace: cloud
+const (
+ // CloudAccountIDKey is the attribute Key conforming to the "cloud.account.id"
+ // semantic conventions. It represents the cloud account ID the resource is
+ // assigned to.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "111111111111", "opentelemetry"
+ CloudAccountIDKey = attribute.Key("cloud.account.id")
+
+ // CloudAvailabilityZoneKey is the attribute Key conforming to the
+ // "cloud.availability_zone" semantic conventions. It represents the cloud
+ // regions often have multiple, isolated locations known as zones to increase
+ // availability. Availability zone represents the zone where the resource is
+ // running.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "us-east-1c"
+ // Note: Availability zones are called "zones" on Alibaba Cloud and Google
+ // Cloud.
+ CloudAvailabilityZoneKey = attribute.Key("cloud.availability_zone")
+
+ // CloudPlatformKey is the attribute Key conforming to the "cloud.platform"
+ // semantic conventions. It represents the cloud platform in use.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // Note: The prefix of the service SHOULD match the one specified in
+ // `cloud.provider`.
+ CloudPlatformKey = attribute.Key("cloud.platform")
+
+ // CloudProviderKey is the attribute Key conforming to the "cloud.provider"
+ // semantic conventions. It represents the name of the cloud provider.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ CloudProviderKey = attribute.Key("cloud.provider")
+
+ // CloudRegionKey is the attribute Key conforming to the "cloud.region" semantic
+ // conventions. It represents the geographical region within a cloud provider.
+ // When associated with a resource, this attribute specifies the region where
+ // the resource operates. When calling services or APIs deployed on a cloud,
+ // this attribute identifies the region where the called destination is
+ // deployed.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "us-central1", "us-east-1"
+ // Note: Refer to your provider's docs to see the available regions, for example
+ // [Alibaba Cloud regions], [AWS regions], [Azure regions],
+ // [Google Cloud regions], or [Tencent Cloud regions].
+ //
+ // [Alibaba Cloud regions]: https://www.alibabacloud.com/help/doc-detail/40654.htm
+ // [AWS regions]: https://aws.amazon.com/about-aws/global-infrastructure/regions_az/
+ // [Azure regions]: https://azure.microsoft.com/global-infrastructure/geographies/
+ // [Google Cloud regions]: https://cloud.google.com/about/locations
+ // [Tencent Cloud regions]: https://www.tencentcloud.com/document/product/213/6091
+ CloudRegionKey = attribute.Key("cloud.region")
+
+ // CloudResourceIDKey is the attribute Key conforming to the "cloud.resource_id"
+ // semantic conventions. It represents the cloud provider-specific native
+ // identifier of the monitored cloud resource (e.g. an [ARN] on AWS, a
+ // [fully qualified resource ID] on Azure, a [full resource name] on GCP).
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "arn:aws:lambda:REGION:ACCOUNT_ID:function:my-function",
+ // "//run.googleapis.com/projects/PROJECT_ID/locations/LOCATION_ID/services/SERVICE_ID",
+ // "/subscriptions//resourceGroups/
+ // /providers/Microsoft.Web/sites//functions/"
+ // Note: On some cloud providers, it may not be possible to determine the full
+ // ID at startup,
+ // so it may be necessary to set `cloud.resource_id` as a span attribute
+ // instead.
+ //
+ // The exact value to use for `cloud.resource_id` depends on the cloud provider.
+ // The following well-known definitions MUST be used if you set this attribute
+ // and they apply:
+ //
+ // - **AWS Lambda:** The function [ARN].
+ // Take care not to use the "invoked ARN" directly but replace any
+ // [alias suffix]
+ // with the resolved function version, as the same runtime instance may be
+ // invocable with
+ // multiple different aliases.
+ // - **GCP:** The [URI of the resource]
+ // - **Azure:** The [Fully Qualified Resource ID] of the invoked function,
+ // *not* the function app, having the form
+ //
+ // `/subscriptions//resourceGroups//providers/Microsoft.Web/sites//functions/`
+ // .
+ // This means that a span attribute MUST be used, as an Azure function app
+ // can host multiple functions that would usually share
+ // a TracerProvider.
+ //
+ //
+ // [ARN]: https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html
+ // [fully qualified resource ID]: https://learn.microsoft.com/rest/api/resources/resources/get-by-id
+ // [full resource name]: https://google.aip.dev/122#full-resource-names
+ // [ARN]: https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html
+ // [alias suffix]: https://docs.aws.amazon.com/lambda/latest/dg/configuration-aliases.html
+ // [URI of the resource]: https://cloud.google.com/iam/docs/full-resource-names
+ // [Fully Qualified Resource ID]: https://learn.microsoft.com/rest/api/resources/resources/get-by-id
+ CloudResourceIDKey = attribute.Key("cloud.resource_id")
+)
+
+// CloudAccountID returns an attribute KeyValue conforming to the
+// "cloud.account.id" semantic conventions. It represents the cloud account ID
+// the resource is assigned to.
+func CloudAccountID(val string) attribute.KeyValue {
+ return CloudAccountIDKey.String(val)
+}
+
+// CloudAvailabilityZone returns an attribute KeyValue conforming to the
+// "cloud.availability_zone" semantic conventions. It represents the cloud
+// regions often have multiple, isolated locations known as zones to increase
+// availability. Availability zone represents the zone where the resource is
+// running.
+func CloudAvailabilityZone(val string) attribute.KeyValue {
+ return CloudAvailabilityZoneKey.String(val)
+}
+
+// CloudRegion returns an attribute KeyValue conforming to the "cloud.region"
+// semantic conventions. It represents the geographical region within a cloud
+// provider. When associated with a resource, this attribute specifies the region
+// where the resource operates. When calling services or APIs deployed on a
+// cloud, this attribute identifies the region where the called destination is
+// deployed.
+func CloudRegion(val string) attribute.KeyValue {
+ return CloudRegionKey.String(val)
+}
+
+// CloudResourceID returns an attribute KeyValue conforming to the
+// "cloud.resource_id" semantic conventions. It represents the cloud
+// provider-specific native identifier of the monitored cloud resource (e.g. an
+// [ARN] on AWS, a [fully qualified resource ID] on Azure, a [full resource name]
+// on GCP).
+//
+// [ARN]: https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html
+// [fully qualified resource ID]: https://learn.microsoft.com/rest/api/resources/resources/get-by-id
+// [full resource name]: https://google.aip.dev/122#full-resource-names
+func CloudResourceID(val string) attribute.KeyValue {
+ return CloudResourceIDKey.String(val)
+}
+
+// Enum values for cloud.platform
+var (
+ // Akamai Cloud Compute
+ // Stability: development
+ CloudPlatformAkamaiCloudCompute = CloudPlatformKey.String("akamai_cloud.compute")
+ // Alibaba Cloud Elastic Compute Service
+ // Stability: development
+ CloudPlatformAlibabaCloudECS = CloudPlatformKey.String("alibaba_cloud_ecs")
+ // Alibaba Cloud Function Compute
+ // Stability: development
+ CloudPlatformAlibabaCloudFC = CloudPlatformKey.String("alibaba_cloud_fc")
+ // Red Hat OpenShift on Alibaba Cloud
+ // Stability: development
+ CloudPlatformAlibabaCloudOpenShift = CloudPlatformKey.String("alibaba_cloud_openshift")
+ // AWS Elastic Compute Cloud
+ // Stability: development
+ CloudPlatformAWSEC2 = CloudPlatformKey.String("aws_ec2")
+ // AWS Elastic Container Service
+ // Stability: development
+ CloudPlatformAWSECS = CloudPlatformKey.String("aws_ecs")
+ // AWS Elastic Kubernetes Service
+ // Stability: development
+ CloudPlatformAWSEKS = CloudPlatformKey.String("aws_eks")
+ // AWS Lambda
+ // Stability: development
+ CloudPlatformAWSLambda = CloudPlatformKey.String("aws_lambda")
+ // AWS Elastic Beanstalk
+ // Stability: development
+ CloudPlatformAWSElasticBeanstalk = CloudPlatformKey.String("aws_elastic_beanstalk")
+ // AWS App Runner
+ // Stability: development
+ CloudPlatformAWSAppRunner = CloudPlatformKey.String("aws_app_runner")
+ // Red Hat OpenShift on AWS (ROSA)
+ // Stability: development
+ CloudPlatformAWSOpenShift = CloudPlatformKey.String("aws_openshift")
+ // Azure Virtual Machines
+ // Stability: development
+ CloudPlatformAzureVM = CloudPlatformKey.String("azure.vm")
+ // Azure Container Apps
+ // Stability: development
+ CloudPlatformAzureContainerApps = CloudPlatformKey.String("azure.container_apps")
+ // Azure Container Instances
+ // Stability: development
+ CloudPlatformAzureContainerInstances = CloudPlatformKey.String("azure.container_instances")
+ // Azure Kubernetes Service
+ // Stability: development
+ CloudPlatformAzureAKS = CloudPlatformKey.String("azure.aks")
+ // Azure Functions
+ // Stability: development
+ CloudPlatformAzureFunctions = CloudPlatformKey.String("azure.functions")
+ // Azure App Service
+ // Stability: development
+ CloudPlatformAzureAppService = CloudPlatformKey.String("azure.app_service")
+ // Azure Red Hat OpenShift
+ // Stability: development
+ CloudPlatformAzureOpenShift = CloudPlatformKey.String("azure.openshift")
+ // Google Vertex AI Agent Engine
+ // Stability: development
+ CloudPlatformGCPAgentEngine = CloudPlatformKey.String("gcp.agent_engine")
+ // Google Bare Metal Solution (BMS)
+ // Stability: development
+ CloudPlatformGCPBareMetalSolution = CloudPlatformKey.String("gcp_bare_metal_solution")
+ // Google Cloud Compute Engine (GCE)
+ // Stability: development
+ CloudPlatformGCPComputeEngine = CloudPlatformKey.String("gcp_compute_engine")
+ // Google Cloud Run
+ // Stability: development
+ CloudPlatformGCPCloudRun = CloudPlatformKey.String("gcp_cloud_run")
+ // Google Cloud Kubernetes Engine (GKE)
+ // Stability: development
+ CloudPlatformGCPKubernetesEngine = CloudPlatformKey.String("gcp_kubernetes_engine")
+ // Google Cloud Functions (GCF)
+ // Stability: development
+ CloudPlatformGCPCloudFunctions = CloudPlatformKey.String("gcp_cloud_functions")
+ // Google Cloud App Engine (GAE)
+ // Stability: development
+ CloudPlatformGCPAppEngine = CloudPlatformKey.String("gcp_app_engine")
+ // Red Hat OpenShift on Google Cloud
+ // Stability: development
+ CloudPlatformGCPOpenShift = CloudPlatformKey.String("gcp_openshift")
+ // Server on Hetzner Cloud
+ // Stability: development
+ CloudPlatformHetznerCloudServer = CloudPlatformKey.String("hetzner.cloud_server")
+ // Red Hat OpenShift on IBM Cloud
+ // Stability: development
+ CloudPlatformIBMCloudOpenShift = CloudPlatformKey.String("ibm_cloud_openshift")
+ // Compute on Oracle Cloud Infrastructure (OCI)
+ // Stability: development
+ CloudPlatformOracleCloudCompute = CloudPlatformKey.String("oracle_cloud_compute")
+ // Kubernetes Engine (OKE) on Oracle Cloud Infrastructure (OCI)
+ // Stability: development
+ CloudPlatformOracleCloudOKE = CloudPlatformKey.String("oracle_cloud_oke")
+ // Tencent Cloud Cloud Virtual Machine (CVM)
+ // Stability: development
+ CloudPlatformTencentCloudCVM = CloudPlatformKey.String("tencent_cloud_cvm")
+ // Tencent Cloud Elastic Kubernetes Service (EKS)
+ // Stability: development
+ CloudPlatformTencentCloudEKS = CloudPlatformKey.String("tencent_cloud_eks")
+ // Tencent Cloud Serverless Cloud Function (SCF)
+ // Stability: development
+ CloudPlatformTencentCloudSCF = CloudPlatformKey.String("tencent_cloud_scf")
+ // Vultr Cloud Compute
+ // Stability: development
+ CloudPlatformVultrCloudCompute = CloudPlatformKey.String("vultr.cloud_compute")
+)
+
+// Enum values for cloud.provider
+var (
+ // Akamai Cloud
+ // Stability: development
+ CloudProviderAkamaiCloud = CloudProviderKey.String("akamai_cloud")
+ // Alibaba Cloud
+ // Stability: development
+ CloudProviderAlibabaCloud = CloudProviderKey.String("alibaba_cloud")
+ // Amazon Web Services
+ // Stability: development
+ CloudProviderAWS = CloudProviderKey.String("aws")
+ // Microsoft Azure
+ // Stability: development
+ CloudProviderAzure = CloudProviderKey.String("azure")
+ // Google Cloud Platform
+ // Stability: development
+ CloudProviderGCP = CloudProviderKey.String("gcp")
+ // Heroku Platform as a Service
+ // Stability: development
+ CloudProviderHeroku = CloudProviderKey.String("heroku")
+ // Hetzner
+ // Stability: development
+ CloudProviderHetzner = CloudProviderKey.String("hetzner")
+ // IBM Cloud
+ // Stability: development
+ CloudProviderIBMCloud = CloudProviderKey.String("ibm_cloud")
+ // Oracle Cloud Infrastructure (OCI)
+ // Stability: development
+ CloudProviderOracleCloud = CloudProviderKey.String("oracle_cloud")
+ // Tencent Cloud
+ // Stability: development
+ CloudProviderTencentCloud = CloudProviderKey.String("tencent_cloud")
+ // Vultr
+ // Stability: development
+ CloudProviderVultr = CloudProviderKey.String("vultr")
+)
+
+// Namespace: cloudevents
+const (
+ // CloudEventsEventIDKey is the attribute Key conforming to the
+ // "cloudevents.event_id" semantic conventions. It represents the [event_id]
+ // uniquely identifies the event.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "123e4567-e89b-12d3-a456-426614174000", "0001"
+ //
+ // [event_id]: https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#id
+ CloudEventsEventIDKey = attribute.Key("cloudevents.event_id")
+
+ // CloudEventsEventSourceKey is the attribute Key conforming to the
+ // "cloudevents.event_source" semantic conventions. It represents the [source]
+ // identifies the context in which an event happened.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "https://github.com/cloudevents", "/cloudevents/spec/pull/123",
+ // "my-service"
+ //
+ // [source]: https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#source-1
+ CloudEventsEventSourceKey = attribute.Key("cloudevents.event_source")
+
+ // CloudEventsEventSpecVersionKey is the attribute Key conforming to the
+ // "cloudevents.event_spec_version" semantic conventions. It represents the
+ // [version of the CloudEvents specification] which the event uses.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 1.0
+ //
+ // [version of the CloudEvents specification]: https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#specversion
+ CloudEventsEventSpecVersionKey = attribute.Key("cloudevents.event_spec_version")
+
+ // CloudEventsEventSubjectKey is the attribute Key conforming to the
+ // "cloudevents.event_subject" semantic conventions. It represents the [subject]
+ // of the event in the context of the event producer (identified by source).
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: mynewfile.jpg
+ //
+ // [subject]: https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#subject
+ CloudEventsEventSubjectKey = attribute.Key("cloudevents.event_subject")
+
+ // CloudEventsEventTypeKey is the attribute Key conforming to the
+ // "cloudevents.event_type" semantic conventions. It represents the [event_type]
+ // contains a value describing the type of event related to the originating
+ // occurrence.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "com.github.pull_request.opened", "com.example.object.deleted.v2"
+ //
+ // [event_type]: https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#type
+ CloudEventsEventTypeKey = attribute.Key("cloudevents.event_type")
+)
+
+// CloudEventsEventID returns an attribute KeyValue conforming to the
+// "cloudevents.event_id" semantic conventions. It represents the [event_id]
+// uniquely identifies the event.
+//
+// [event_id]: https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#id
+func CloudEventsEventID(val string) attribute.KeyValue {
+ return CloudEventsEventIDKey.String(val)
+}
+
+// CloudEventsEventSource returns an attribute KeyValue conforming to the
+// "cloudevents.event_source" semantic conventions. It represents the [source]
+// identifies the context in which an event happened.
+//
+// [source]: https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#source-1
+func CloudEventsEventSource(val string) attribute.KeyValue {
+ return CloudEventsEventSourceKey.String(val)
+}
+
+// CloudEventsEventSpecVersion returns an attribute KeyValue conforming to the
+// "cloudevents.event_spec_version" semantic conventions. It represents the
+// [version of the CloudEvents specification] which the event uses.
+//
+// [version of the CloudEvents specification]: https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#specversion
+func CloudEventsEventSpecVersion(val string) attribute.KeyValue {
+ return CloudEventsEventSpecVersionKey.String(val)
+}
+
+// CloudEventsEventSubject returns an attribute KeyValue conforming to the
+// "cloudevents.event_subject" semantic conventions. It represents the [subject]
+// of the event in the context of the event producer (identified by source).
+//
+// [subject]: https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#subject
+func CloudEventsEventSubject(val string) attribute.KeyValue {
+ return CloudEventsEventSubjectKey.String(val)
+}
+
+// CloudEventsEventType returns an attribute KeyValue conforming to the
+// "cloudevents.event_type" semantic conventions. It represents the [event_type]
+// contains a value describing the type of event related to the originating
+// occurrence.
+//
+// [event_type]: https://github.com/cloudevents/spec/blob/v1.0.2/cloudevents/spec.md#type
+func CloudEventsEventType(val string) attribute.KeyValue {
+ return CloudEventsEventTypeKey.String(val)
+}
+
+// Namespace: cloudfoundry
+const (
+ // CloudFoundryAppIDKey is the attribute Key conforming to the
+ // "cloudfoundry.app.id" semantic conventions. It represents the guid of the
+ // application.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "218fc5a9-a5f1-4b54-aa05-46717d0ab26d"
+ // Note: Application instrumentation should use the value from environment
+ // variable `VCAP_APPLICATION.application_id`. This is the same value as
+ // reported by `cf app --guid`.
+ CloudFoundryAppIDKey = attribute.Key("cloudfoundry.app.id")
+
+ // CloudFoundryAppInstanceIDKey is the attribute Key conforming to the
+ // "cloudfoundry.app.instance.id" semantic conventions. It represents the index
+ // of the application instance. 0 when just one instance is active.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "0", "1"
+ // Note: CloudFoundry defines the `instance_id` in the [Loggregator v2 envelope]
+ // .
+ // It is used for logs and metrics emitted by CloudFoundry. It is
+ // supposed to contain the application instance index for applications
+ // deployed on the runtime.
+ //
+ // Application instrumentation should use the value from environment
+ // variable `CF_INSTANCE_INDEX`.
+ //
+ // [Loggregator v2 envelope]: https://github.com/cloudfoundry/loggregator-api#v2-envelope
+ CloudFoundryAppInstanceIDKey = attribute.Key("cloudfoundry.app.instance.id")
+
+ // CloudFoundryAppNameKey is the attribute Key conforming to the
+ // "cloudfoundry.app.name" semantic conventions. It represents the name of the
+ // application.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "my-app-name"
+ // Note: Application instrumentation should use the value from environment
+ // variable `VCAP_APPLICATION.application_name`. This is the same value
+ // as reported by `cf apps`.
+ CloudFoundryAppNameKey = attribute.Key("cloudfoundry.app.name")
+
+ // CloudFoundryOrgIDKey is the attribute Key conforming to the
+ // "cloudfoundry.org.id" semantic conventions. It represents the guid of the
+ // CloudFoundry org the application is running in.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "218fc5a9-a5f1-4b54-aa05-46717d0ab26d"
+ // Note: Application instrumentation should use the value from environment
+ // variable `VCAP_APPLICATION.org_id`. This is the same value as
+ // reported by `cf org --guid`.
+ CloudFoundryOrgIDKey = attribute.Key("cloudfoundry.org.id")
+
+ // CloudFoundryOrgNameKey is the attribute Key conforming to the
+ // "cloudfoundry.org.name" semantic conventions. It represents the name of the
+ // CloudFoundry organization the app is running in.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "my-org-name"
+ // Note: Application instrumentation should use the value from environment
+ // variable `VCAP_APPLICATION.org_name`. This is the same value as
+ // reported by `cf orgs`.
+ CloudFoundryOrgNameKey = attribute.Key("cloudfoundry.org.name")
+
+ // CloudFoundryProcessIDKey is the attribute Key conforming to the
+ // "cloudfoundry.process.id" semantic conventions. It represents the UID
+ // identifying the process.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "218fc5a9-a5f1-4b54-aa05-46717d0ab26d"
+ // Note: Application instrumentation should use the value from environment
+ // variable `VCAP_APPLICATION.process_id`. It is supposed to be equal to
+ // `VCAP_APPLICATION.app_id` for applications deployed to the runtime.
+ // For system components, this could be the actual PID.
+ CloudFoundryProcessIDKey = attribute.Key("cloudfoundry.process.id")
+
+ // CloudFoundryProcessTypeKey is the attribute Key conforming to the
+ // "cloudfoundry.process.type" semantic conventions. It represents the type of
+ // process.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "web"
+ // Note: CloudFoundry applications can consist of multiple jobs. Usually the
+ // main process will be of type `web`. There can be additional background
+ // tasks or side-cars with different process types.
+ CloudFoundryProcessTypeKey = attribute.Key("cloudfoundry.process.type")
+
+ // CloudFoundrySpaceIDKey is the attribute Key conforming to the
+ // "cloudfoundry.space.id" semantic conventions. It represents the guid of the
+ // CloudFoundry space the application is running in.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "218fc5a9-a5f1-4b54-aa05-46717d0ab26d"
+ // Note: Application instrumentation should use the value from environment
+ // variable `VCAP_APPLICATION.space_id`. This is the same value as
+ // reported by `cf space --guid`.
+ CloudFoundrySpaceIDKey = attribute.Key("cloudfoundry.space.id")
+
+ // CloudFoundrySpaceNameKey is the attribute Key conforming to the
+ // "cloudfoundry.space.name" semantic conventions. It represents the name of the
+ // CloudFoundry space the application is running in.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "my-space-name"
+ // Note: Application instrumentation should use the value from environment
+ // variable `VCAP_APPLICATION.space_name`. This is the same value as
+ // reported by `cf spaces`.
+ CloudFoundrySpaceNameKey = attribute.Key("cloudfoundry.space.name")
+
+ // CloudFoundrySystemIDKey is the attribute Key conforming to the
+ // "cloudfoundry.system.id" semantic conventions. It represents a guid or
+ // another name describing the event source.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "cf/gorouter"
+ // Note: CloudFoundry defines the `source_id` in the [Loggregator v2 envelope].
+ // It is used for logs and metrics emitted by CloudFoundry. It is
+ // supposed to contain the component name, e.g. "gorouter", for
+ // CloudFoundry components.
+ //
+ // When system components are instrumented, values from the
+ // [Bosh spec]
+ // should be used. The `system.id` should be set to
+ // `spec.deployment/spec.name`.
+ //
+ // [Loggregator v2 envelope]: https://github.com/cloudfoundry/loggregator-api#v2-envelope
+ // [Bosh spec]: https://bosh.io/docs/jobs/#properties-spec
+ CloudFoundrySystemIDKey = attribute.Key("cloudfoundry.system.id")
+
+ // CloudFoundrySystemInstanceIDKey is the attribute Key conforming to the
+ // "cloudfoundry.system.instance.id" semantic conventions. It represents a guid
+ // describing the concrete instance of the event source.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "218fc5a9-a5f1-4b54-aa05-46717d0ab26d"
+ // Note: CloudFoundry defines the `instance_id` in the [Loggregator v2 envelope]
+ // .
+ // It is used for logs and metrics emitted by CloudFoundry. It is
+ // supposed to contain the vm id for CloudFoundry components.
+ //
+ // When system components are instrumented, values from the
+ // [Bosh spec]
+ // should be used. The `system.instance.id` should be set to `spec.id`.
+ //
+ // [Loggregator v2 envelope]: https://github.com/cloudfoundry/loggregator-api#v2-envelope
+ // [Bosh spec]: https://bosh.io/docs/jobs/#properties-spec
+ CloudFoundrySystemInstanceIDKey = attribute.Key("cloudfoundry.system.instance.id")
+)
+
+// CloudFoundryAppID returns an attribute KeyValue conforming to the
+// "cloudfoundry.app.id" semantic conventions. It represents the guid of the
+// application.
+func CloudFoundryAppID(val string) attribute.KeyValue {
+ return CloudFoundryAppIDKey.String(val)
+}
+
+// CloudFoundryAppInstanceID returns an attribute KeyValue conforming to the
+// "cloudfoundry.app.instance.id" semantic conventions. It represents the index
+// of the application instance. 0 when just one instance is active.
+func CloudFoundryAppInstanceID(val string) attribute.KeyValue {
+ return CloudFoundryAppInstanceIDKey.String(val)
+}
+
+// CloudFoundryAppName returns an attribute KeyValue conforming to the
+// "cloudfoundry.app.name" semantic conventions. It represents the name of the
+// application.
+func CloudFoundryAppName(val string) attribute.KeyValue {
+ return CloudFoundryAppNameKey.String(val)
+}
+
+// CloudFoundryOrgID returns an attribute KeyValue conforming to the
+// "cloudfoundry.org.id" semantic conventions. It represents the guid of the
+// CloudFoundry org the application is running in.
+func CloudFoundryOrgID(val string) attribute.KeyValue {
+ return CloudFoundryOrgIDKey.String(val)
+}
+
+// CloudFoundryOrgName returns an attribute KeyValue conforming to the
+// "cloudfoundry.org.name" semantic conventions. It represents the name of the
+// CloudFoundry organization the app is running in.
+func CloudFoundryOrgName(val string) attribute.KeyValue {
+ return CloudFoundryOrgNameKey.String(val)
+}
+
+// CloudFoundryProcessID returns an attribute KeyValue conforming to the
+// "cloudfoundry.process.id" semantic conventions. It represents the UID
+// identifying the process.
+func CloudFoundryProcessID(val string) attribute.KeyValue {
+ return CloudFoundryProcessIDKey.String(val)
+}
+
+// CloudFoundryProcessType returns an attribute KeyValue conforming to the
+// "cloudfoundry.process.type" semantic conventions. It represents the type of
+// process.
+func CloudFoundryProcessType(val string) attribute.KeyValue {
+ return CloudFoundryProcessTypeKey.String(val)
+}
+
+// CloudFoundrySpaceID returns an attribute KeyValue conforming to the
+// "cloudfoundry.space.id" semantic conventions. It represents the guid of the
+// CloudFoundry space the application is running in.
+func CloudFoundrySpaceID(val string) attribute.KeyValue {
+ return CloudFoundrySpaceIDKey.String(val)
+}
+
+// CloudFoundrySpaceName returns an attribute KeyValue conforming to the
+// "cloudfoundry.space.name" semantic conventions. It represents the name of the
+// CloudFoundry space the application is running in.
+func CloudFoundrySpaceName(val string) attribute.KeyValue {
+ return CloudFoundrySpaceNameKey.String(val)
+}
+
+// CloudFoundrySystemID returns an attribute KeyValue conforming to the
+// "cloudfoundry.system.id" semantic conventions. It represents a guid or another
+// name describing the event source.
+func CloudFoundrySystemID(val string) attribute.KeyValue {
+ return CloudFoundrySystemIDKey.String(val)
+}
+
+// CloudFoundrySystemInstanceID returns an attribute KeyValue conforming to the
+// "cloudfoundry.system.instance.id" semantic conventions. It represents a guid
+// describing the concrete instance of the event source.
+func CloudFoundrySystemInstanceID(val string) attribute.KeyValue {
+ return CloudFoundrySystemInstanceIDKey.String(val)
+}
+
+// Namespace: code
+const (
+ // CodeColumnNumberKey is the attribute Key conforming to the
+ // "code.column.number" semantic conventions. It represents the column number in
+ // `code.file.path` best representing the operation. It SHOULD point within the
+ // code unit named in `code.function.name`. This attribute MUST NOT be used on
+ // the Profile signal since the data is already captured in 'message Line'. This
+ // constraint is imposed to prevent redundancy and maintain data integrity.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ CodeColumnNumberKey = attribute.Key("code.column.number")
+
+ // CodeFilePathKey is the attribute Key conforming to the "code.file.path"
+ // semantic conventions. It represents the source code file name that identifies
+ // the code unit as uniquely as possible (preferably an absolute file path).
+ // This attribute MUST NOT be used on the Profile signal since the data is
+ // already captured in 'message Function'. This constraint is imposed to prevent
+ // redundancy and maintain data integrity.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: /usr/local/MyApplication/content_root/app/index.php
+ CodeFilePathKey = attribute.Key("code.file.path")
+
+ // CodeFunctionNameKey is the attribute Key conforming to the
+ // "code.function.name" semantic conventions. It represents the method or
+ // function fully-qualified name without arguments. The value should fit the
+ // natural representation of the language runtime, which is also likely the same
+ // used within `code.stacktrace` attribute value. This attribute MUST NOT be
+ // used on the Profile signal since the data is already captured in 'message
+ // Function'. This constraint is imposed to prevent redundancy and maintain data
+ // integrity.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "com.example.MyHttpService.serveRequest",
+ // "GuzzleHttp\Client::transfer", "fopen"
+ // Note: Values and format depends on each language runtime, thus it is
+ // impossible to provide an exhaustive list of examples.
+ // The values are usually the same (or prefixes of) the ones found in native
+ // stack trace representation stored in
+ // `code.stacktrace` without information on arguments.
+ //
+ // Examples:
+ //
+ // - Java method: `com.example.MyHttpService.serveRequest`
+ // - Java anonymous class method: `com.mycompany.Main$1.myMethod`
+ // - Java lambda method:
+ // `com.mycompany.Main$$Lambda/0x0000748ae4149c00.myMethod`
+ // - PHP function: `GuzzleHttp\Client::transfer`
+ // - Go function: `github.com/my/repo/pkg.foo.func5`
+ // - Elixir: `OpenTelemetry.Ctx.new`
+ // - Erlang: `opentelemetry_ctx:new`
+ // - Rust: `playground::my_module::my_cool_func`
+ // - C function: `fopen`
+ CodeFunctionNameKey = attribute.Key("code.function.name")
+
+ // CodeLineNumberKey is the attribute Key conforming to the "code.line.number"
+ // semantic conventions. It represents the line number in `code.file.path` best
+ // representing the operation. It SHOULD point within the code unit named in
+ // `code.function.name`. This attribute MUST NOT be used on the Profile signal
+ // since the data is already captured in 'message Line'. This constraint is
+ // imposed to prevent redundancy and maintain data integrity.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ CodeLineNumberKey = attribute.Key("code.line.number")
+
+ // CodeStacktraceKey is the attribute Key conforming to the "code.stacktrace"
+ // semantic conventions. It represents a stacktrace as a string in the natural
+ // representation for the language runtime. The representation is identical to
+ // [`exception.stacktrace`]. This attribute MUST NOT be used on the Profile
+ // signal since the data is already captured in 'message Location'. This
+ // constraint is imposed to prevent redundancy and maintain data integrity.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: at com.example.GenerateTrace.methodB(GenerateTrace.java:13)\n at
+ // com.example.GenerateTrace.methodA(GenerateTrace.java:9)\n at
+ // com.example.GenerateTrace.main(GenerateTrace.java:5)
+ //
+ // [`exception.stacktrace`]: /docs/exceptions/exceptions-spans.md#stacktrace-representation
+ CodeStacktraceKey = attribute.Key("code.stacktrace")
+)
+
+// CodeColumnNumber returns an attribute KeyValue conforming to the
+// "code.column.number" semantic conventions. It represents the column number in
+// `code.file.path` best representing the operation. It SHOULD point within the
+// code unit named in `code.function.name`. This attribute MUST NOT be used on
+// the Profile signal since the data is already captured in 'message Line'. This
+// constraint is imposed to prevent redundancy and maintain data integrity.
+func CodeColumnNumber(val int) attribute.KeyValue {
+ return CodeColumnNumberKey.Int(val)
+}
+
+// CodeFilePath returns an attribute KeyValue conforming to the "code.file.path"
+// semantic conventions. It represents the source code file name that identifies
+// the code unit as uniquely as possible (preferably an absolute file path). This
+// attribute MUST NOT be used on the Profile signal since the data is already
+// captured in 'message Function'. This constraint is imposed to prevent
+// redundancy and maintain data integrity.
+func CodeFilePath(val string) attribute.KeyValue {
+ return CodeFilePathKey.String(val)
+}
+
+// CodeFunctionName returns an attribute KeyValue conforming to the
+// "code.function.name" semantic conventions. It represents the method or
+// function fully-qualified name without arguments. The value should fit the
+// natural representation of the language runtime, which is also likely the same
+// used within `code.stacktrace` attribute value. This attribute MUST NOT be used
+// on the Profile signal since the data is already captured in 'message
+// Function'. This constraint is imposed to prevent redundancy and maintain data
+// integrity.
+func CodeFunctionName(val string) attribute.KeyValue {
+ return CodeFunctionNameKey.String(val)
+}
+
+// CodeLineNumber returns an attribute KeyValue conforming to the
+// "code.line.number" semantic conventions. It represents the line number in
+// `code.file.path` best representing the operation. It SHOULD point within the
+// code unit named in `code.function.name`. This attribute MUST NOT be used on
+// the Profile signal since the data is already captured in 'message Line'. This
+// constraint is imposed to prevent redundancy and maintain data integrity.
+func CodeLineNumber(val int) attribute.KeyValue {
+ return CodeLineNumberKey.Int(val)
+}
+
+// CodeStacktrace returns an attribute KeyValue conforming to the
+// "code.stacktrace" semantic conventions. It represents a stacktrace as a string
+// in the natural representation for the language runtime. The representation is
+// identical to [`exception.stacktrace`]. This attribute MUST NOT be used on the
+// Profile signal since the data is already captured in 'message Location'. This
+// constraint is imposed to prevent redundancy and maintain data integrity.
+//
+// [`exception.stacktrace`]: /docs/exceptions/exceptions-spans.md#stacktrace-representation
+func CodeStacktrace(val string) attribute.KeyValue {
+ return CodeStacktraceKey.String(val)
+}
+
+// Namespace: container
+const (
+ // ContainerCommandKey is the attribute Key conforming to the
+ // "container.command" semantic conventions. It represents the command used to
+ // run the container (i.e. the command name).
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "otelcontribcol"
+ // Note: If using embedded credentials or sensitive data, it is recommended to
+ // remove them to prevent potential leakage.
+ ContainerCommandKey = attribute.Key("container.command")
+
+ // ContainerCommandArgsKey is the attribute Key conforming to the
+ // "container.command_args" semantic conventions. It represents the all the
+ // command arguments (including the command/executable itself) run by the
+ // container.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "otelcontribcol", "--config", "config.yaml"
+ ContainerCommandArgsKey = attribute.Key("container.command_args")
+
+ // ContainerCommandLineKey is the attribute Key conforming to the
+ // "container.command_line" semantic conventions. It represents the full command
+ // run by the container as a single string representing the full command.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "otelcontribcol --config config.yaml"
+ ContainerCommandLineKey = attribute.Key("container.command_line")
+
+ // ContainerCSIPluginNameKey is the attribute Key conforming to the
+ // "container.csi.plugin.name" semantic conventions. It represents the name of
+ // the CSI ([Container Storage Interface]) plugin used by the volume.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "pd.csi.storage.gke.io"
+ // Note: This can sometimes be referred to as a "driver" in CSI implementations.
+ // This should represent the `name` field of the GetPluginInfo RPC.
+ //
+ // [Container Storage Interface]: https://github.com/container-storage-interface/spec
+ ContainerCSIPluginNameKey = attribute.Key("container.csi.plugin.name")
+
+ // ContainerCSIVolumeIDKey is the attribute Key conforming to the
+ // "container.csi.volume.id" semantic conventions. It represents the unique
+ // volume ID returned by the CSI ([Container Storage Interface]) plugin.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "projects/my-gcp-project/zones/my-gcp-zone/disks/my-gcp-disk"
+ // Note: This can sometimes be referred to as a "volume handle" in CSI
+ // implementations. This should represent the `Volume.volume_id` field in CSI
+ // spec.
+ //
+ // [Container Storage Interface]: https://github.com/container-storage-interface/spec
+ ContainerCSIVolumeIDKey = attribute.Key("container.csi.volume.id")
+
+ // ContainerIDKey is the attribute Key conforming to the "container.id" semantic
+ // conventions. It represents the container ID. Usually a UUID, as for example
+ // used to [identify Docker containers]. The UUID might be abbreviated.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Alpha
+ //
+ // Examples: "a3bf90e006b2"
+ //
+ // [identify Docker containers]: https://docs.docker.com/engine/containers/run/#container-identification
+ ContainerIDKey = attribute.Key("container.id")
+
+ // ContainerImageIDKey is the attribute Key conforming to the
+ // "container.image.id" semantic conventions. It represents the runtime specific
+ // image identifier. Usually a hash algorithm followed by a UUID.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ // "sha256:19c92d0a00d1b66d897bceaa7319bee0dd38a10a851c60bcec9474aa3f01e50f"
+ // Note: Docker defines a sha256 of the image id; `container.image.id`
+ // corresponds to the `Image` field from the Docker container inspect [API]
+ // endpoint.
+ // K8s defines a link to the container registry repository with digest
+ // `"imageID": "registry.azurecr.io /namespace/service/dockerfile@sha256:bdeabd40c3a8a492eaf9e8e44d0ebbb84bac7ee25ac0cf8a7159d25f62555625"`
+ // .
+ // The ID is assigned by the container runtime and can vary in different
+ // environments. Consider using `oci.manifest.digest` if it is important to
+ // identify the same image in different environments/runtimes.
+ //
+ // [API]: https://docs.docker.com/reference/api/engine/version/v1.52/#tag/Container/operation/ContainerInspect
+ ContainerImageIDKey = attribute.Key("container.image.id")
+
+ // ContainerImageNameKey is the attribute Key conforming to the
+ // "container.image.name" semantic conventions. It represents the name of the
+ // image the container was built on.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Alpha
+ //
+ // Examples: "gcr.io/opentelemetry/operator"
+ ContainerImageNameKey = attribute.Key("container.image.name")
+
+ // ContainerImageRepoDigestsKey is the attribute Key conforming to the
+ // "container.image.repo_digests" semantic conventions. It represents the repo
+ // digests of the container image as provided by the container runtime.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Alpha
+ //
+ // Examples:
+ // "example@sha256:afcc7f1ac1b49db317a7196c902e61c6c3c4607d63599ee1a82d702d249a0ccb",
+ // "internal.registry.example.com:5000/example@sha256:b69959407d21e8a062e0416bf13405bb2b71ed7a84dde4158ebafacfa06f5578"
+ // Note: [Docker] and [CRI] report those under the `RepoDigests` field.
+ //
+ // [Docker]: https://docs.docker.com/reference/api/engine/version/v1.52/#tag/Image/operation/ImageInspect
+ // [CRI]: https://github.com/kubernetes/cri-api/blob/c75ef5b473bbe2d0a4fc92f82235efd665ea8e9f/pkg/apis/runtime/v1/api.proto#L1237-L1238
+ ContainerImageRepoDigestsKey = attribute.Key("container.image.repo_digests")
+
+ // ContainerImageTagsKey is the attribute Key conforming to the
+ // "container.image.tags" semantic conventions. It represents the container
+ // image tags. An example can be found in [Docker Image Inspect]. Should be only
+ // the `` section of the full name for example from
+ // `registry.example.com/my-org/my-image:`.
+ //
+ // Type: string[]
+ // RequirementLevel: Recommended
+ // Stability: Alpha
+ //
+ // Examples: "v1.27.1", "3.5.7-0"
+ //
+ // [Docker Image Inspect]: https://docs.docker.com/reference/api/engine/version/v1.52/#tag/Image/operation/ImageInspect
+ ContainerImageTagsKey = attribute.Key("container.image.tags")
+
+ // ContainerNameKey is the attribute Key conforming to the "container.name"
+ // semantic conventions. It represents the container name used by container
+ // runtime.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "opentelemetry-autoconf"
+ ContainerNameKey = attribute.Key("container.name")
+
+ // ContainerRuntimeDescriptionKey is the attribute Key conforming to the
+ // "container.runtime.description" semantic conventions. It represents a
+ // description about the runtime which could include, for example details about
+ // the CRI/API version being used or other customisations.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "docker://19.3.1 - CRI: 1.22.0"
+ ContainerRuntimeDescriptionKey = attribute.Key("container.runtime.description")
+
+ // ContainerRuntimeNameKey is the attribute Key conforming to the
+ // "container.runtime.name" semantic conventions. It represents the container
+ // runtime managing this container.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "docker", "containerd", "rkt"
+ ContainerRuntimeNameKey = attribute.Key("container.runtime.name")
+
+ // ContainerRuntimeVersionKey is the attribute Key conforming to the
+ // "container.runtime.version" semantic conventions. It represents the version
+ // of the runtime of this process, as returned by the runtime without
+ // modification.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 1.0.0
+ ContainerRuntimeVersionKey = attribute.Key("container.runtime.version")
+)
+
+// ContainerCommand returns an attribute KeyValue conforming to the
+// "container.command" semantic conventions. It represents the command used to
+// run the container (i.e. the command name).
+func ContainerCommand(val string) attribute.KeyValue {
+ return ContainerCommandKey.String(val)
+}
+
+// ContainerCommandArgs returns an attribute KeyValue conforming to the
+// "container.command_args" semantic conventions. It represents the all the
+// command arguments (including the command/executable itself) run by the
+// container.
+func ContainerCommandArgs(val ...string) attribute.KeyValue {
+ return ContainerCommandArgsKey.StringSlice(val)
+}
+
+// ContainerCommandLine returns an attribute KeyValue conforming to the
+// "container.command_line" semantic conventions. It represents the full command
+// run by the container as a single string representing the full command.
+func ContainerCommandLine(val string) attribute.KeyValue {
+ return ContainerCommandLineKey.String(val)
+}
+
+// ContainerCSIPluginName returns an attribute KeyValue conforming to the
+// "container.csi.plugin.name" semantic conventions. It represents the name of
+// the CSI ([Container Storage Interface]) plugin used by the volume.
+//
+// [Container Storage Interface]: https://github.com/container-storage-interface/spec
+func ContainerCSIPluginName(val string) attribute.KeyValue {
+ return ContainerCSIPluginNameKey.String(val)
+}
+
+// ContainerCSIVolumeID returns an attribute KeyValue conforming to the
+// "container.csi.volume.id" semantic conventions. It represents the unique
+// volume ID returned by the CSI ([Container Storage Interface]) plugin.
+//
+// [Container Storage Interface]: https://github.com/container-storage-interface/spec
+func ContainerCSIVolumeID(val string) attribute.KeyValue {
+ return ContainerCSIVolumeIDKey.String(val)
+}
+
+// ContainerID returns an attribute KeyValue conforming to the "container.id"
+// semantic conventions. It represents the container ID. Usually a UUID, as for
+// example used to [identify Docker containers]. The UUID might be abbreviated.
+//
+// [identify Docker containers]: https://docs.docker.com/engine/containers/run/#container-identification
+func ContainerID(val string) attribute.KeyValue {
+ return ContainerIDKey.String(val)
+}
+
+// ContainerImageID returns an attribute KeyValue conforming to the
+// "container.image.id" semantic conventions. It represents the runtime specific
+// image identifier. Usually a hash algorithm followed by a UUID.
+func ContainerImageID(val string) attribute.KeyValue {
+ return ContainerImageIDKey.String(val)
+}
+
+// ContainerImageName returns an attribute KeyValue conforming to the
+// "container.image.name" semantic conventions. It represents the name of the
+// image the container was built on.
+func ContainerImageName(val string) attribute.KeyValue {
+ return ContainerImageNameKey.String(val)
+}
+
+// ContainerImageRepoDigests returns an attribute KeyValue conforming to the
+// "container.image.repo_digests" semantic conventions. It represents the repo
+// digests of the container image as provided by the container runtime.
+func ContainerImageRepoDigests(val ...string) attribute.KeyValue {
+ return ContainerImageRepoDigestsKey.StringSlice(val)
+}
+
+// ContainerImageTags returns an attribute KeyValue conforming to the
+// "container.image.tags" semantic conventions. It represents the container image
+// tags. An example can be found in [Docker Image Inspect]. Should be only the
+// `` section of the full name for example from
+// `registry.example.com/my-org/my-image:`.
+//
+// [Docker Image Inspect]: https://docs.docker.com/reference/api/engine/version/v1.52/#tag/Image/operation/ImageInspect
+func ContainerImageTags(val ...string) attribute.KeyValue {
+ return ContainerImageTagsKey.StringSlice(val)
+}
+
+// ContainerLabel returns an attribute KeyValue conforming to the
+// "container.label" semantic conventions. It represents the container labels,
+// `` being the label name, the value being the label value.
+func ContainerLabel(key string, val string) attribute.KeyValue {
+ return attribute.String("container.label."+key, val)
+}
+
+// ContainerName returns an attribute KeyValue conforming to the "container.name"
+// semantic conventions. It represents the container name used by container
+// runtime.
+func ContainerName(val string) attribute.KeyValue {
+ return ContainerNameKey.String(val)
+}
+
+// ContainerRuntimeDescription returns an attribute KeyValue conforming to the
+// "container.runtime.description" semantic conventions. It represents a
+// description about the runtime which could include, for example details about
+// the CRI/API version being used or other customisations.
+func ContainerRuntimeDescription(val string) attribute.KeyValue {
+ return ContainerRuntimeDescriptionKey.String(val)
+}
+
+// ContainerRuntimeName returns an attribute KeyValue conforming to the
+// "container.runtime.name" semantic conventions. It represents the container
+// runtime managing this container.
+func ContainerRuntimeName(val string) attribute.KeyValue {
+ return ContainerRuntimeNameKey.String(val)
+}
+
+// ContainerRuntimeVersion returns an attribute KeyValue conforming to the
+// "container.runtime.version" semantic conventions. It represents the version of
+// the runtime of this process, as returned by the runtime without modification.
+func ContainerRuntimeVersion(val string) attribute.KeyValue {
+ return ContainerRuntimeVersionKey.String(val)
+}
+
+// Namespace: cpu
+const (
+ // CPULogicalNumberKey is the attribute Key conforming to the
+ // "cpu.logical_number" semantic conventions. It represents the logical CPU
+ // number [0..n-1].
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 1
+ CPULogicalNumberKey = attribute.Key("cpu.logical_number")
+
+ // CPUModeKey is the attribute Key conforming to the "cpu.mode" semantic
+ // conventions. It represents the mode of the CPU.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "user", "system"
+ CPUModeKey = attribute.Key("cpu.mode")
+)
+
+// CPULogicalNumber returns an attribute KeyValue conforming to the
+// "cpu.logical_number" semantic conventions. It represents the logical CPU
+// number [0..n-1].
+func CPULogicalNumber(val int) attribute.KeyValue {
+ return CPULogicalNumberKey.Int(val)
+}
+
+// Enum values for cpu.mode
+var (
+ // User
+ // Stability: development
+ CPUModeUser = CPUModeKey.String("user")
+ // System
+ // Stability: development
+ CPUModeSystem = CPUModeKey.String("system")
+ // Nice
+ // Stability: development
+ CPUModeNice = CPUModeKey.String("nice")
+ // Idle
+ // Stability: development
+ CPUModeIdle = CPUModeKey.String("idle")
+ // IO Wait
+ // Stability: development
+ CPUModeIOWait = CPUModeKey.String("iowait")
+ // Interrupt
+ // Stability: development
+ CPUModeInterrupt = CPUModeKey.String("interrupt")
+ // Steal
+ // Stability: development
+ CPUModeSteal = CPUModeKey.String("steal")
+ // Kernel
+ // Stability: development
+ CPUModeKernel = CPUModeKey.String("kernel")
+)
+
+// Namespace: db
+const (
+ // DBClientConnectionPoolNameKey is the attribute Key conforming to the
+ // "db.client.connection.pool.name" semantic conventions. It represents the name
+ // of the connection pool; unique within the instrumented application. In case
+ // the connection pool implementation doesn't provide a name, instrumentation
+ // SHOULD use a combination of parameters that would make the name unique, for
+ // example, combining attributes `server.address`, `server.port`, and
+ // `db.namespace`, formatted as `server.address:server.port/db.namespace`.
+ // Instrumentations that generate connection pool name following different
+ // patterns SHOULD document it.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "myDataSource"
+ DBClientConnectionPoolNameKey = attribute.Key("db.client.connection.pool.name")
+
+ // DBClientConnectionStateKey is the attribute Key conforming to the
+ // "db.client.connection.state" semantic conventions. It represents the state of
+ // a connection in the pool.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "idle"
+ DBClientConnectionStateKey = attribute.Key("db.client.connection.state")
+
+ // DBCollectionNameKey is the attribute Key conforming to the
+ // "db.collection.name" semantic conventions. It represents the name of a
+ // collection (table, container) within the database.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "public.users", "customers"
+ // Note: It is RECOMMENDED to capture the value as provided by the application
+ // without attempting to do any case normalization.
+ //
+ // The collection name SHOULD NOT be extracted from `db.query.text`,
+ // when the database system supports query text with multiple collections
+ // in non-batch operations.
+ //
+ // For batch operations, if the individual operations are known to have the same
+ // collection name then that collection name SHOULD be used.
+ DBCollectionNameKey = attribute.Key("db.collection.name")
+
+ // DBNamespaceKey is the attribute Key conforming to the "db.namespace" semantic
+ // conventions. It represents the name of the database, fully qualified within
+ // the server address and port.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "customers", "test.users"
+ // Note: If a database system has multiple namespace components, they SHOULD be
+ // concatenated from the most general to the most specific namespace component,
+ // using `|` as a separator between the components. Any missing components (and
+ // their associated separators) SHOULD be omitted.
+ // Semantic conventions for individual database systems SHOULD document what
+ // `db.namespace` means in the context of that system.
+ // It is RECOMMENDED to capture the value as provided by the application without
+ // attempting to do any case normalization.
+ DBNamespaceKey = attribute.Key("db.namespace")
+
+ // DBOperationBatchSizeKey is the attribute Key conforming to the
+ // "db.operation.batch.size" semantic conventions. It represents the number of
+ // queries included in a batch operation.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: 2, 3, 4
+ // Note: Operations are only considered batches when they contain two or more
+ // operations, and so `db.operation.batch.size` SHOULD never be `1`.
+ DBOperationBatchSizeKey = attribute.Key("db.operation.batch.size")
+
+ // DBOperationNameKey is the attribute Key conforming to the "db.operation.name"
+ // semantic conventions. It represents the name of the operation or command
+ // being executed.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "findAndModify", "HMSET", "SELECT"
+ // Note: It is RECOMMENDED to capture the value as provided by the application
+ // without attempting to do any case normalization.
+ //
+ // The operation name SHOULD NOT be extracted from `db.query.text`,
+ // when the database system supports query text with multiple operations
+ // in non-batch operations.
+ //
+ // If spaces can occur in the operation name, multiple consecutive spaces
+ // SHOULD be normalized to a single space.
+ //
+ // For batch operations, if the individual operations are known to have the same
+ // operation name
+ // then that operation name SHOULD be used prepended by `BATCH `,
+ // otherwise `db.operation.name` SHOULD be `BATCH` or some other database
+ // system specific term if more applicable.
+ DBOperationNameKey = attribute.Key("db.operation.name")
+
+ // DBQuerySummaryKey is the attribute Key conforming to the "db.query.summary"
+ // semantic conventions. It represents the low cardinality summary of a database
+ // query.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "SELECT wuser_table", "INSERT shipping_details SELECT orders", "get
+ // user by id"
+ // Note: The query summary describes a class of database queries and is useful
+ // as a grouping key, especially when analyzing telemetry for database
+ // calls involving complex queries.
+ //
+ // Summary may be available to the instrumentation through
+ // instrumentation hooks or other means. If it is not available,
+ // instrumentations
+ // that support query parsing SHOULD generate a summary following
+ // [Generating query summary]
+ // section.
+ //
+ // [Generating query summary]: /docs/db/database-spans.md#generating-a-summary-of-the-query
+ DBQuerySummaryKey = attribute.Key("db.query.summary")
+
+ // DBQueryTextKey is the attribute Key conforming to the "db.query.text"
+ // semantic conventions. It represents the database query being executed.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "SELECT * FROM wuser_table where username = ?", "SET mykey ?"
+ // Note: For sanitization see [Sanitization of `db.query.text`].
+ // For batch operations, if the individual operations are known to have the same
+ // query text then that query text SHOULD be used, otherwise all of the
+ // individual query texts SHOULD be concatenated with separator `; ` or some
+ // other database system specific separator if more applicable.
+ // Parameterized query text SHOULD NOT be sanitized. Even though parameterized
+ // query text can potentially have sensitive data, by using a parameterized
+ // query the user is giving a strong signal that any sensitive data will be
+ // passed as parameter values, and the benefit to observability of capturing the
+ // static part of the query text by default outweighs the risk.
+ //
+ // [Sanitization of `db.query.text`]: /docs/db/database-spans.md#sanitization-of-dbquerytext
+ DBQueryTextKey = attribute.Key("db.query.text")
+
+ // DBResponseReturnedRowsKey is the attribute Key conforming to the
+ // "db.response.returned_rows" semantic conventions. It represents the number of
+ // rows returned by the operation.
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 10, 30, 1000
+ DBResponseReturnedRowsKey = attribute.Key("db.response.returned_rows")
+
+ // DBResponseStatusCodeKey is the attribute Key conforming to the
+ // "db.response.status_code" semantic conventions. It represents the database
+ // response status code.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "102", "ORA-17002", "08P01", "404"
+ // Note: The status code returned by the database. Usually it represents an
+ // error code, but may also represent partial success, warning, or differentiate
+ // between various types of successful outcomes.
+ // Semantic conventions for individual database systems SHOULD document what
+ // `db.response.status_code` means in the context of that system.
+ DBResponseStatusCodeKey = attribute.Key("db.response.status_code")
+
+ // DBStoredProcedureNameKey is the attribute Key conforming to the
+ // "db.stored_procedure.name" semantic conventions. It represents the name of a
+ // stored procedure within the database.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples: "GetCustomer"
+ // Note: It is RECOMMENDED to capture the value as provided by the application
+ // without attempting to do any case normalization.
+ //
+ // For batch operations, if the individual operations are known to have the same
+ // stored procedure name then that stored procedure name SHOULD be used.
+ DBStoredProcedureNameKey = attribute.Key("db.stored_procedure.name")
+
+ // DBSystemNameKey is the attribute Key conforming to the "db.system.name"
+ // semantic conventions. It represents the database management system (DBMS)
+ // product as identified by the client instrumentation.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Stable
+ //
+ // Examples:
+ // Note: The actual DBMS may differ from the one identified by the client. For
+ // example, when using PostgreSQL client libraries to connect to a CockroachDB,
+ // the `db.system.name` is set to `postgresql` based on the instrumentation's
+ // best knowledge.
+ DBSystemNameKey = attribute.Key("db.system.name")
+)
+
+// DBClientConnectionPoolName returns an attribute KeyValue conforming to the
+// "db.client.connection.pool.name" semantic conventions. It represents the name
+// of the connection pool; unique within the instrumented application. In case
+// the connection pool implementation doesn't provide a name, instrumentation
+// SHOULD use a combination of parameters that would make the name unique, for
+// example, combining attributes `server.address`, `server.port`, and
+// `db.namespace`, formatted as `server.address:server.port/db.namespace`.
+// Instrumentations that generate connection pool name following different
+// patterns SHOULD document it.
+func DBClientConnectionPoolName(val string) attribute.KeyValue {
+ return DBClientConnectionPoolNameKey.String(val)
+}
+
+// DBCollectionName returns an attribute KeyValue conforming to the
+// "db.collection.name" semantic conventions. It represents the name of a
+// collection (table, container) within the database.
+func DBCollectionName(val string) attribute.KeyValue {
+ return DBCollectionNameKey.String(val)
+}
+
+// DBNamespace returns an attribute KeyValue conforming to the "db.namespace"
+// semantic conventions. It represents the name of the database, fully qualified
+// within the server address and port.
+func DBNamespace(val string) attribute.KeyValue {
+ return DBNamespaceKey.String(val)
+}
+
+// DBOperationBatchSize returns an attribute KeyValue conforming to the
+// "db.operation.batch.size" semantic conventions. It represents the number of
+// queries included in a batch operation.
+func DBOperationBatchSize(val int) attribute.KeyValue {
+ return DBOperationBatchSizeKey.Int(val)
+}
+
+// DBOperationName returns an attribute KeyValue conforming to the
+// "db.operation.name" semantic conventions. It represents the name of the
+// operation or command being executed.
+func DBOperationName(val string) attribute.KeyValue {
+ return DBOperationNameKey.String(val)
+}
+
+// DBOperationParameter returns an attribute KeyValue conforming to the
+// "db.operation.parameter" semantic conventions. It represents a database
+// operation parameter, with `