diff --git a/.mk/local.mk b/.mk/local.mk
index d84cc78454..6f74740c45 100644
--- a/.mk/local.mk
+++ b/.mk/local.mk
@@ -7,6 +7,7 @@ IMAGE_FOR_HELM := $(word 1,$(subst :, ,${IMAGE}))
VERSION_FOR_HELM := $(word 2,$(subst :, ,${IMAGE}))
.PHONY: helm-install
helm-install: prereqs-helm ## Install the operator and its pre-requisites to a running cluster, using Helm
+ cd helm && helm dependency update --skip-refresh ; cd ..
helm repo add cert-manager https://charts.jetstack.io
helm upgrade --install cert-manager -n cert-manager --create-namespace cert-manager/cert-manager --set crds.enabled=true
helm upgrade --install trust-manager -n cert-manager oci://quay.io/jetstack/charts/trust-manager --wait
diff --git a/api/flowcollector/v1beta2/flowcollector_types.go b/api/flowcollector/v1beta2/flowcollector_types.go
index 5e1a575bdd..e0cd615214 100644
--- a/api/flowcollector/v1beta2/flowcollector_types.go
+++ b/api/flowcollector/v1beta2/flowcollector_types.go
@@ -1395,18 +1395,20 @@ type AdvancedProcessorConfig struct {
//+kubebuilder:validation:Maximum=65535
//+kubebuilder:default:=8080
//+optional
- // `healthPort` is a collector HTTP port in the Pod that exposes the health check API
+ // `healthPort` is a collector HTTP port in the Pod that exposes the health check API.
HealthPort *int32 `json:"healthPort,omitempty"`
//+kubebuilder:validation:Minimum=0
//+kubebuilder:validation:Maximum=65535
//+optional
- // `profilePort` allows setting up a Go pprof profiler listening to this port
+ // `profilePort` allows setting up a Go pprof profiler listening to this port.
+ // This is for debugging purpose only. This port should not be exposed, you can
+ // access it through local port-forwarding.
ProfilePort *int32 `json:"profilePort,omitempty"`
//+kubebuilder:default:=true
//+optional
- // `enableKubeProbes` is a flag to enable or disable Kubernetes liveness and readiness probes
+ // `enableKubeProbes` is a flag to enable or disable Kubernetes liveness and readiness probes.
EnableKubeProbes *bool `json:"enableKubeProbes,omitempty"`
//+kubebuilder:default:=true
@@ -1416,7 +1418,7 @@ type AdvancedProcessorConfig struct {
//+kubebuilder:default:="30s"
//+optional
- // `conversationHeartbeatInterval` is the time to wait between "tick" events of a conversation
+ // `conversationHeartbeatInterval` is the time to wait between "tick" events of a conversation.
ConversationHeartbeatInterval *metav1.Duration `json:"conversationHeartbeatInterval,omitempty"`
//+kubebuilder:default:="10s"
diff --git a/api/flowcollector/v1beta2/flowcollector_validation_webhook.go b/api/flowcollector/v1beta2/flowcollector_validation_webhook.go
index 26205d80d1..5205094db9 100644
--- a/api/flowcollector/v1beta2/flowcollector_validation_webhook.go
+++ b/api/flowcollector/v1beta2/flowcollector_validation_webhook.go
@@ -68,6 +68,7 @@ func (r *FlowCollector) Validate(_ context.Context, fc *FlowCollector) (admissio
v.validateAgent()
v.validateFLP()
v.warnLogLevels()
+ v.warnProfiling()
v.warnLokiDemo()
return v.warnings, errors.Join(v.errors...)
}
@@ -87,6 +88,21 @@ func (v *validator) warnLogLevels() {
}
}
+func (v *validator) warnProfiling() {
+ warning := "This is for debugging purpose only. The profiling port should not be exposed, you can access it through local port-forwarding."
+ if v.fc.Agent.EBPF.Advanced != nil {
+ if env, ok := v.fc.Agent.EBPF.Advanced.Env["PPROF_ADDR"]; ok && env != "" {
+ v.warnings = append(v.warnings, "Profiling is enabled on the eBPF agent. "+warning)
+ if strings.HasPrefix(env, ":") || strings.HasPrefix(env, "0.0.0.0:") {
+ v.warnings = append(v.warnings, "Profiling is enabled for all network interfaces, make sure access is restricted e.g. with a network policy.")
+ }
+ }
+ }
+ if v.fc.Processor.Advanced != nil && v.fc.Processor.Advanced.ProfilePort != nil && *v.fc.Processor.Advanced.ProfilePort > 0 {
+ v.warnings = append(v.warnings, "Profiling is enabled on flowlogs-pipeline. "+warning)
+ }
+}
+
func (v *validator) warnLokiDemo() {
if v.fc.Loki.Mode == LokiModeMonolithic && v.fc.Loki.Monolithic.InstallDemoLoki != nil && *v.fc.Loki.Monolithic.InstallDemoLoki {
v.warnings = append(v.warnings, "InstallDemoLoki option is enabled. This is useful for development and demo purposes but should not be used in production.")
diff --git a/bundle/manifests/flows.netobserv.io_flowcollectors.yaml b/bundle/manifests/flows.netobserv.io_flowcollectors.yaml
index e128840551..64e316df59 100644
--- a/bundle/manifests/flows.netobserv.io_flowcollectors.yaml
+++ b/bundle/manifests/flows.netobserv.io_flowcollectors.yaml
@@ -4378,7 +4378,7 @@ spec:
conversationHeartbeatInterval:
default: 30s
description: '`conversationHeartbeatInterval` is the time
- to wait between "tick" events of a conversation'
+ to wait between "tick" events of a conversation.'
type: string
conversationTerminatingTimeout:
default: 5s
@@ -4394,7 +4394,7 @@ spec:
enableKubeProbes:
default: true
description: '`enableKubeProbes` is a flag to enable or disable
- Kubernetes liveness and readiness probes'
+ Kubernetes liveness and readiness probes.'
type: boolean
env:
additionalProperties:
@@ -4408,7 +4408,7 @@ spec:
healthPort:
default: 8080
description: '`healthPort` is a collector HTTP port in the
- Pod that exposes the health check API'
+ Pod that exposes the health check API.'
format: int32
maximum: 65535
minimum: 1
@@ -4424,8 +4424,10 @@ spec:
minimum: 1025
type: integer
profilePort:
- description: '`profilePort` allows setting up a Go pprof profiler
- listening to this port'
+ description: |-
+ `profilePort` allows setting up a Go pprof profiler listening to this port.
+ This is for debugging purpose only. This port should not be exposed, you can
+ access it through local port-forwarding.
format: int32
maximum: 65535
minimum: 0
diff --git a/config/crd/bases/flows.netobserv.io_flowcollectors.yaml b/config/crd/bases/flows.netobserv.io_flowcollectors.yaml
index 43f1be5584..c3e589a28d 100644
--- a/config/crd/bases/flows.netobserv.io_flowcollectors.yaml
+++ b/config/crd/bases/flows.netobserv.io_flowcollectors.yaml
@@ -4029,7 +4029,7 @@ spec:
type: string
conversationHeartbeatInterval:
default: 30s
- description: '`conversationHeartbeatInterval` is the time to wait between "tick" events of a conversation'
+ description: '`conversationHeartbeatInterval` is the time to wait between "tick" events of a conversation.'
type: string
conversationTerminatingTimeout:
default: 5s
@@ -4041,7 +4041,7 @@ spec:
type: boolean
enableKubeProbes:
default: true
- description: '`enableKubeProbes` is a flag to enable or disable Kubernetes liveness and readiness probes'
+ description: '`enableKubeProbes` is a flag to enable or disable Kubernetes liveness and readiness probes.'
type: boolean
env:
additionalProperties:
@@ -4054,7 +4054,7 @@ spec:
type: object
healthPort:
default: 8080
- description: '`healthPort` is a collector HTTP port in the Pod that exposes the health check API'
+ description: '`healthPort` is a collector HTTP port in the Pod that exposes the health check API.'
format: int32
maximum: 65535
minimum: 1
@@ -4070,7 +4070,10 @@ spec:
minimum: 1025
type: integer
profilePort:
- description: '`profilePort` allows setting up a Go pprof profiler listening to this port'
+ description: |-
+ `profilePort` allows setting up a Go pprof profiler listening to this port.
+ This is for debugging purpose only. This port should not be exposed, you can
+ access it through local port-forwarding.
format: int32
maximum: 65535
minimum: 0
diff --git a/docs/FlowCollector.md b/docs/FlowCollector.md
index 869338d1e0..476205b1f7 100644
--- a/docs/FlowCollector.md
+++ b/docs/FlowCollector.md
@@ -8711,7 +8711,7 @@ This delay is ignored when a FIN packet is collected for TCP flows (see `convers
conversationHeartbeatInterval |
string |
- `conversationHeartbeatInterval` is the time to wait between "tick" events of a conversation
+ `conversationHeartbeatInterval` is the time to wait between "tick" events of a conversation.
Default: 30s
|
@@ -8738,7 +8738,7 @@ This delay is ignored when a FIN packet is collected for TCP flows (see `convers
enableKubeProbes |
boolean |
- `enableKubeProbes` is a flag to enable or disable Kubernetes liveness and readiness probes
+ `enableKubeProbes` is a flag to enable or disable Kubernetes liveness and readiness probes.
Default: true
|
@@ -8757,7 +8757,7 @@ in edge debug or support scenarios.
healthPort |
integer |
- `healthPort` is a collector HTTP port in the Pod that exposes the health check API
+ `healthPort` is a collector HTTP port in the Pod that exposes the health check API.
Format: int32
Default: 8080
@@ -8783,7 +8783,9 @@ By convention, some values are forbidden. It must be greater than 1024 and diffe
| profilePort |
integer |
- `profilePort` allows setting up a Go pprof profiler listening to this port
+ `profilePort` allows setting up a Go pprof profiler listening to this port.
+This is for debugging purpose only. This port should not be exposed, you can
+access it through local port-forwarding.
Format: int32
Minimum: 0
diff --git a/go.mod b/go.mod
index 43375b1dbd..1c4ce2a665 100644
--- a/go.mod
+++ b/go.mod
@@ -7,8 +7,8 @@ require (
github.com/coreos/go-semver v0.3.1
github.com/google/go-cmp v0.7.0
github.com/grafana/loki/operator/apis/loki v0.0.0-20241021105923-5e970e50b166
- github.com/netobserv/flowlogs-pipeline v1.11.4-community.0.20260521155724-7ee2fbbc7651
- github.com/netobserv/netobserv-ebpf-agent v1.11.3-community.0.20260505134559-24f8cbea14ad
+ github.com/netobserv/flowlogs-pipeline v1.11.5-community.0.20260625083056-0aefbc7d051e
+ github.com/netobserv/netobserv-ebpf-agent v1.11.5-community.0.20260625084536-cd2c2a1fa4fb
github.com/onsi/ginkgo/v2 v2.31.0
github.com/onsi/gomega v1.41.0
github.com/openshift/api v0.0.0-20250707164913-2cd5821c9080
@@ -42,7 +42,7 @@ require (
github.com/evanphx/json-patch v5.9.11+incompatible // indirect
github.com/evanphx/json-patch/v5 v5.9.11 // indirect
github.com/felixge/httpsnoop v1.0.4 // indirect
- github.com/fsnotify/fsnotify v1.9.0 // indirect
+ github.com/fsnotify/fsnotify v1.10.1 // indirect
github.com/fxamacker/cbor/v2 v2.9.0 // indirect
github.com/go-logr/logr v1.4.3 // indirect
github.com/go-logr/stdr v1.2.2 // indirect
@@ -69,7 +69,7 @@ require (
github.com/google/gnostic-models v0.7.1 // indirect
github.com/google/pprof v0.0.0-20260402051712-545e8a4df936 // indirect
github.com/google/uuid v1.6.0 // indirect
- github.com/grpc-ecosystem/grpc-gateway/v2 v2.28.0 // indirect
+ github.com/grpc-ecosystem/grpc-gateway/v2 v2.29.0 // indirect
github.com/inconshreveable/mousetrap v1.1.0 // indirect
github.com/jpillora/backoff v1.0.0 // indirect
github.com/json-iterator/go v1.1.12 // indirect
@@ -87,12 +87,12 @@ require (
github.com/x448/float16 v0.8.4 // indirect
go.opentelemetry.io/auto/sdk v1.2.1 // indirect
go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.65.0 // indirect
- go.opentelemetry.io/otel v1.43.0 // indirect
- go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.43.0 // indirect
- go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.43.0 // indirect
- go.opentelemetry.io/otel/metric v1.43.0 // indirect
- go.opentelemetry.io/otel/sdk v1.43.0 // indirect
- go.opentelemetry.io/otel/trace v1.43.0 // indirect
+ go.opentelemetry.io/otel v1.44.0 // indirect
+ go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.44.0 // indirect
+ go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.44.0 // indirect
+ go.opentelemetry.io/otel/metric v1.44.0 // indirect
+ go.opentelemetry.io/otel/sdk v1.44.0 // indirect
+ go.opentelemetry.io/otel/trace v1.44.0 // indirect
go.opentelemetry.io/proto/otlp v1.10.0 // indirect
go.uber.org/multierr v1.11.0 // indirect
go.yaml.in/yaml/v2 v2.4.4 // indirect
@@ -102,14 +102,14 @@ require (
golang.org/x/net v0.55.0 // indirect
golang.org/x/oauth2 v0.36.0 // indirect
golang.org/x/sync v0.20.0 // indirect
- golang.org/x/sys v0.45.0 // indirect
+ golang.org/x/sys v0.46.0 // indirect
golang.org/x/term v0.43.0 // indirect
golang.org/x/text v0.37.0 // indirect
golang.org/x/time v0.15.0 // indirect
golang.org/x/tools v0.44.0 // indirect
gomodules.xyz/jsonpatch/v2 v2.5.0 // indirect
- google.golang.org/genproto/googleapis/api v0.0.0-20260401024825-9d38bb4040a9 // indirect
- google.golang.org/genproto/googleapis/rpc v0.0.0-20260401024825-9d38bb4040a9 // indirect
+ google.golang.org/genproto/googleapis/api v0.0.0-20260526163538-3dc84a4a5aaa // indirect
+ google.golang.org/genproto/googleapis/rpc v0.0.0-20260526163538-3dc84a4a5aaa // indirect
google.golang.org/grpc v1.81.1 // indirect
google.golang.org/protobuf v1.36.11 // indirect
gopkg.in/evanphx/json-patch.v4 v4.13.0 // indirect
diff --git a/go.sum b/go.sum
index a29cf7ecaa..5bb2f2d381 100644
--- a/go.sum
+++ b/go.sum
@@ -31,8 +31,8 @@ github.com/evanphx/json-patch/v5 v5.9.11 h1:/8HVnzMq13/3x9TPvjG08wUGqBTmZBsCWzjT
github.com/evanphx/json-patch/v5 v5.9.11/go.mod h1:3j+LviiESTElxA4p3EMKAB9HXj3/XEtnUf6OZxqIQTM=
github.com/felixge/httpsnoop v1.0.4 h1:NFTV2Zj1bL4mc9sqWACXbQFVBBg2W3GPvqp8/ESS2Wg=
github.com/felixge/httpsnoop v1.0.4/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U=
-github.com/fsnotify/fsnotify v1.9.0 h1:2Ml+OJNzbYCTzsxtv8vKSFD9PbJjmhYF14k/jKC7S9k=
-github.com/fsnotify/fsnotify v1.9.0/go.mod h1:8jBTzvmWwFyi3Pb8djgCCO5IBqzKJ/Jwo8TRcHyHii0=
+github.com/fsnotify/fsnotify v1.10.1 h1:b0/UzAf9yR5rhf3RPm9gf3ehBPpf0oZKIjtpKrx59Ho=
+github.com/fsnotify/fsnotify v1.10.1/go.mod h1:TLheqan6HD6GBK6PrDWyDPBaEV8LspOxvPSjC+bVfgo=
github.com/fxamacker/cbor/v2 v2.9.0 h1:NpKPmjDBgUfBms6tr6JZkTHtfFGcMKsw3eGcmD/sapM=
github.com/fxamacker/cbor/v2 v2.9.0/go.mod h1:vM4b+DJCtHn+zz7h3FFp/hDAI9WNWCsZj23V5ytsSxQ=
github.com/gkampitakis/ciinfo v0.3.2 h1:JcuOPk8ZU7nZQjdUhctuhQofk7BGHuIy0c9Ez8BNhXs=
@@ -111,8 +111,8 @@ 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=
github.com/grafana/loki/operator/apis/loki v0.0.0-20241021105923-5e970e50b166 h1:cmG5fwmF+0PsyerLecb7CU4bzNRg5+tDgO3PiNxskKo=
github.com/grafana/loki/operator/apis/loki v0.0.0-20241021105923-5e970e50b166/go.mod h1:QggEReYyQzjnwTlj9hMeRaI2M/w3UPAwrMOXYzIyonc=
-github.com/grpc-ecosystem/grpc-gateway/v2 v2.28.0 h1:HWRh5R2+9EifMyIHV7ZV+MIZqgz+PMpZ14Jynv3O2Zs=
-github.com/grpc-ecosystem/grpc-gateway/v2 v2.28.0/go.mod h1:JfhWUomR1baixubs02l85lZYYOm7LV6om4ceouMv45c=
+github.com/grpc-ecosystem/grpc-gateway/v2 v2.29.0 h1:5VipnvEpbqr2gA2VbM+nYVbkIF28c5ZQfqCBQ5g2xfk=
+github.com/grpc-ecosystem/grpc-gateway/v2 v2.29.0/go.mod h1:Hyl3n6Twe1hvtd9XUXDec4pTvgMSEixRuQKPTMH2bNs=
github.com/inconshreveable/mousetrap v1.1.0 h1:wN+x4NVGpMsO7ErUn/mUI3vEoE6Jt13X2s0bqwp9tc8=
github.com/inconshreveable/mousetrap v1.1.0/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw=
github.com/joshdk/go-junit v1.0.0 h1:S86cUKIdwBHWwA6xCmFlf3RTLfVXYQfvanM5Uh+K6GE=
@@ -123,8 +123,8 @@ github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnr
github.com/json-iterator/go v1.1.12/go.mod h1:e30LSqwooZae/UwlEbR2852Gd8hjQvJoHmT4TnhNGBo=
github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8=
github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck=
-github.com/klauspost/compress v1.18.5 h1:/h1gH5Ce+VWNLSWqPzOVn6XBO+vJbCNGvjoaGBFW2IE=
-github.com/klauspost/compress v1.18.5/go.mod h1:cwPg85FWrGar70rWktvGQj8/hthj3wpl0PGDogxkrSQ=
+github.com/klauspost/compress v1.18.6 h1:2jupLlAwFm95+YDR+NwD2MEfFO9d4z4Prjl1XXDjuao=
+github.com/klauspost/compress v1.18.6/go.mod h1:cwPg85FWrGar70rWktvGQj8/hthj3wpl0PGDogxkrSQ=
github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE=
github.com/kr/pretty v0.3.1/go.mod h1:hoEshYVHaxMs3cyo3Yncou5ZscifuDolrwPKZanG3xk=
github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY=
@@ -145,10 +145,10 @@ github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 h1:C3w9PqII01/Oq
github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ=
github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f h1:KUppIJq7/+SVif2QVs3tOP0zanoHgBEVAwHxUSIzRqU=
github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U=
-github.com/netobserv/flowlogs-pipeline v1.11.4-community.0.20260521155724-7ee2fbbc7651 h1:tnreTWG+d9ojmczyhdX9gpzRThAKiu63UBdY+oMJFyk=
-github.com/netobserv/flowlogs-pipeline v1.11.4-community.0.20260521155724-7ee2fbbc7651/go.mod h1:iZYYJIMSaPd24fjZ+mcXH0NPt+ueDA797POWNOaiN2M=
-github.com/netobserv/netobserv-ebpf-agent v1.11.3-community.0.20260505134559-24f8cbea14ad h1:7yx3IMcPtcVyOvMcBhazFyLwdGx62Y73DzmNfYbIwZ4=
-github.com/netobserv/netobserv-ebpf-agent v1.11.3-community.0.20260505134559-24f8cbea14ad/go.mod h1:kWzhlhwQ5nPdgYwWmOisXZuxsA5f5qWt27hiCQfrH0s=
+github.com/netobserv/flowlogs-pipeline v1.11.5-community.0.20260625083056-0aefbc7d051e h1:Tq3imgc9eiYMBnb695A4OztuMGrCpTbJvggR6QiMNhw=
+github.com/netobserv/flowlogs-pipeline v1.11.5-community.0.20260625083056-0aefbc7d051e/go.mod h1:RNGkTvF3w+epkBmtbKqj+M4h6f9VNwVkTB2Smy2OvCc=
+github.com/netobserv/netobserv-ebpf-agent v1.11.5-community.0.20260625084536-cd2c2a1fa4fb h1:KNMbRuD5wtb8UQhdXRQi+DKl9Y5TPCF2vwExBay3k2o=
+github.com/netobserv/netobserv-ebpf-agent v1.11.5-community.0.20260625084536-cd2c2a1fa4fb/go.mod h1:NXh7mtzpv7mLu6H7q+hKCfM8ETVjYu8EgxFX2RLoFQg=
github.com/onsi/ginkgo/v2 v2.31.0 h1:GtuJos5DFUV9EerYJo8RhYxosYNGvOdDE5haKq6Grfs=
github.com/onsi/ginkgo/v2 v2.31.0/go.mod h1:+aXOY+vzZ5mu2iI2HpTZUPmM//oQfsNFX6gU9kNcA44=
github.com/onsi/gomega v1.41.0 h1:OwKp4pXNgVxf6sCplzYo794OFNuoL2q2SBMU5NSWOjA=
@@ -157,8 +157,8 @@ github.com/openshift/api v0.0.0-20250707164913-2cd5821c9080 h1:WIcPdcyEm4eaUz9fS
github.com/openshift/api v0.0.0-20250707164913-2cd5821c9080/go.mod h1:yk60tHAmHhtVpJQo3TwVYq2zpuP70iJIFDCmeKMIzPw=
github.com/operator-framework/api v0.42.0 h1:rkc5V3zW8RxZMjePAe12jdL7Co/hwsYo1pLnkkhuR7s=
github.com/operator-framework/api v0.42.0/go.mod h1:bMEj+wl/8tGqcGNtxt38cLUYagu9chNsbYzb/5HQaUQ=
-github.com/pelletier/go-toml/v2 v2.2.4 h1:mye9XuhQ6gvn5h28+VilKrrPoQVanw5PMw/TB0t5Ec4=
-github.com/pelletier/go-toml/v2 v2.2.4/go.mod h1:2gIqNv+qfxSVS7cM2xJQKtLSTLUE9V8t9Stt+h56mCY=
+github.com/pelletier/go-toml/v2 v2.3.1 h1:MYEvvGnQjeNkRF1qUuGolNtNExTDwct51yp7olPtrEc=
+github.com/pelletier/go-toml/v2 v2.3.1/go.mod h1:2gIqNv+qfxSVS7cM2xJQKtLSTLUE9V8t9Stt+h56mCY=
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 h1:Jamvg5psRIccs7FGNTlIRMkT8wgtp5eCXdBlqhYGL6U=
github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
@@ -216,20 +216,20 @@ go.opentelemetry.io/auto/sdk v1.2.1 h1:jXsnJ4Lmnqd11kwkBV2LgLoFMZKizbCi5fNZ/ipaZ
go.opentelemetry.io/auto/sdk v1.2.1/go.mod h1:KRTj+aOaElaLi+wW1kO/DZRXwkF4C5xPbEe3ZiIhN7Y=
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.43.0 h1:mYIM03dnh5zfN7HautFE4ieIig9amkNANT+xcVxAj9I=
-go.opentelemetry.io/otel v1.43.0/go.mod h1:JuG+u74mvjvcm8vj8pI5XiHy1zDeoCS2LB1spIq7Ay0=
-go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.43.0 h1:88Y4s2C8oTui1LGM6bTWkw0ICGcOLCAI5l6zsD1j20k=
-go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.43.0/go.mod h1:Vl1/iaggsuRlrHf/hfPJPvVag77kKyvrLeD10kpMl+A=
-go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.43.0 h1:RAE+JPfvEmvy+0LzyUA25/SGawPwIUbZ6u0Wug54sLc=
-go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.43.0/go.mod h1:AGmbycVGEsRx9mXMZ75CsOyhSP6MFIcj/6dnG+vhVjk=
-go.opentelemetry.io/otel/metric v1.43.0 h1:d7638QeInOnuwOONPp4JAOGfbCEpYb+K6DVWvdxGzgM=
-go.opentelemetry.io/otel/metric v1.43.0/go.mod h1:RDnPtIxvqlgO8GRW18W6Z/4P462ldprJtfxHxyKd2PY=
-go.opentelemetry.io/otel/sdk v1.43.0 h1:pi5mE86i5rTeLXqoF/hhiBtUNcrAGHLKQdhg4h4V9Dg=
-go.opentelemetry.io/otel/sdk v1.43.0/go.mod h1:P+IkVU3iWukmiit/Yf9AWvpyRDlUeBaRg6Y+C58QHzg=
-go.opentelemetry.io/otel/sdk/metric v1.43.0 h1:S88dyqXjJkuBNLeMcVPRFXpRw2fuwdvfCGLEo89fDkw=
-go.opentelemetry.io/otel/sdk/metric v1.43.0/go.mod h1:C/RJtwSEJ5hzTiUz5pXF1kILHStzb9zFlIEe85bhj6A=
-go.opentelemetry.io/otel/trace v1.43.0 h1:BkNrHpup+4k4w+ZZ86CZoHHEkohws8AY+WTX09nk+3A=
-go.opentelemetry.io/otel/trace v1.43.0/go.mod h1:/QJhyVBUUswCphDVxq+8mld+AvhXZLhe+8WVFxiFff0=
+go.opentelemetry.io/otel v1.44.0 h1:JjwHmHpA4iZ3wBxluu2fbbE7j4kqlE8jXyAyPXH7HqU=
+go.opentelemetry.io/otel v1.44.0/go.mod h1:BMgjTHL9WPRlRjL2oZCBTL4whCGtXch2H4BhOPIAyYc=
+go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.44.0 h1:4YsVu3B8+3qtWYYrsUYgn0OG78pN0rnNPRGX4SbokQI=
+go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.44.0/go.mod h1:+wnlSn0mD1ADVMe3v9Z/WIaiz6q6gL2J/ejaAmdmv80=
+go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.44.0 h1:qazEJlUOQzhCpzQpFETGby7EdqjI1wsd0W+6Gg1SCTU=
+go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.44.0/go.mod h1:fOD2Yefuxixkx3ahVNf0O/PERb6r4OlbxfATVnYvzCo=
+go.opentelemetry.io/otel/metric v1.44.0 h1:1w0gILTcHdr3YI+ixLyjemwrVnsMURbTZFrSYCdDdmc=
+go.opentelemetry.io/otel/metric v1.44.0/go.mod h1:8O7hanEPBNgEMmybD3s2VBKcgWOCsA6tzHBPODAiquo=
+go.opentelemetry.io/otel/sdk v1.44.0 h1:nHYwb9lK+fJPU/dnT6s7W7Z8itMWyqrnVfbheVYrZ58=
+go.opentelemetry.io/otel/sdk v1.44.0/go.mod h1:Osuydd3Se74nqjAKxid74N5eC+jfEqfTegHRnq58oK0=
+go.opentelemetry.io/otel/sdk/metric v1.44.0 h1:3LlKgI+VjbVsjNRFZJZAJ30WjXC5VkNRks6si09iEfI=
+go.opentelemetry.io/otel/sdk/metric v1.44.0/go.mod h1:5B5pMARnXxKhltooO4xUuCBorl65a4EpnTalObqOigA=
+go.opentelemetry.io/otel/trace v1.44.0 h1:jxF5CsGYCe74MCRx2X4g7WsY/VBKRqqpNvXlX/6gtIk=
+go.opentelemetry.io/otel/trace v1.44.0/go.mod h1:oLl1jrMQAVo6v3GAggN+1VH9VIz9iUSvW53sW1Q8PIE=
go.opentelemetry.io/proto/otlp v1.10.0 h1:IQRWgT5srOCYfiWnpqUYz9CVmbO8bFmKcwYxpuCSL2g=
go.opentelemetry.io/proto/otlp v1.10.0/go.mod h1:/CV4QoCR/S9yaPj8utp3lvQPoqMtxXdzn7ozvvozVqk=
go.uber.org/goleak v1.3.0 h1:2K3zAYmnTNqV73imy9J1T3WC+gmCePx2hEGkimedGto=
@@ -267,8 +267,8 @@ golang.org/x/sync v0.20.0/go.mod h1:9xrNwdLfx4jkKbNva9FpL6vEN7evnE43NNNJQ2LF3+0=
golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.45.0 h1:dO4czNzziLiiXplLQgBCEpCvXQ3dnkn0SdaZSYdQ+FY=
-golang.org/x/sys v0.45.0/go.mod h1:4GL1E5IUh+htKOUEOaiffhrAeqysfVGipDYzABqnCmw=
+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.43.0 h1:S4RLU2sB31O/NCl+zFN9Aru9A/Cq2aqKpTZJ6B+DwT4=
golang.org/x/term v0.43.0/go.mod h1:lrhlHNdQJHO+1qVYiHfFKVuVioJIheAc3fBSMFYEIsk=
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
@@ -291,10 +291,10 @@ gomodules.xyz/jsonpatch/v2 v2.5.0 h1:JELs8RLM12qJGXU4u/TO3V25KW8GreMKl9pdkk14RM0
gomodules.xyz/jsonpatch/v2 v2.5.0/go.mod h1:AH3dM2RI6uoBZxn3LVrfvJ3E0/9dG4cSrbuBJT4moAY=
gonum.org/v1/gonum v0.17.0 h1:VbpOemQlsSMrYmn7T2OUvQ4dqxQXU+ouZFQsZOx50z4=
gonum.org/v1/gonum v0.17.0/go.mod h1:El3tOrEuMpv2UdMrbNlKEh9vd86bmQ6vqIcDwxEOc1E=
-google.golang.org/genproto/googleapis/api v0.0.0-20260401024825-9d38bb4040a9 h1:VPWxll4HlMw1Vs/qXtN7BvhZqsS9cdAittCNvVENElA=
-google.golang.org/genproto/googleapis/api v0.0.0-20260401024825-9d38bb4040a9/go.mod h1:7QBABkRtR8z+TEnmXTqIqwJLlzrZKVfAUm7tY3yGv0M=
-google.golang.org/genproto/googleapis/rpc v0.0.0-20260401024825-9d38bb4040a9 h1:m8qni9SQFH0tJc1X0vmnpw/0t+AImlSvp30sEupozUg=
-google.golang.org/genproto/googleapis/rpc v0.0.0-20260401024825-9d38bb4040a9/go.mod h1:4Hqkh8ycfw05ld/3BWL7rJOSfebL2Q+DVDeRgYgxUU8=
+google.golang.org/genproto/googleapis/api v0.0.0-20260526163538-3dc84a4a5aaa h1:Kjn0N0tCrDgiAFW+lGO4JZ3ck44CehvJQMAwj9QF0G8=
+google.golang.org/genproto/googleapis/api v0.0.0-20260526163538-3dc84a4a5aaa/go.mod h1:q4lMZS6kskjT5HvCPrnnypcDPVJqT/f4nfxmkE7gryY=
+google.golang.org/genproto/googleapis/rpc v0.0.0-20260526163538-3dc84a4a5aaa h1:mZHHdPZl0dbGHCflZgAq/Q468DWVFcU2whhB2KAo8fk=
+google.golang.org/genproto/googleapis/rpc v0.0.0-20260526163538-3dc84a4a5aaa/go.mod h1:4Hqkh8ycfw05ld/3BWL7rJOSfebL2Q+DVDeRgYgxUU8=
google.golang.org/grpc v1.81.1 h1:VnnIIZ88UzOOKLukQi+ImGz8O1Wdp8nAGGnvOfEIWQQ=
google.golang.org/grpc v1.81.1/go.mod h1:xGH9GfzOyMTGIOXBJmXt+BX/V0kcdQbdcuwQ/zNw42I=
google.golang.org/protobuf v1.36.11 h1:fV6ZwhNocDyBLK0dj+fg8ektcVegBBuEolpbTQyBNVE=
diff --git a/helm/crds/flows.netobserv.io_flowcollectors.yaml b/helm/crds/flows.netobserv.io_flowcollectors.yaml
index e14db1d37c..a6450ee75e 100644
--- a/helm/crds/flows.netobserv.io_flowcollectors.yaml
+++ b/helm/crds/flows.netobserv.io_flowcollectors.yaml
@@ -4033,7 +4033,7 @@ spec:
type: string
conversationHeartbeatInterval:
default: 30s
- description: '`conversationHeartbeatInterval` is the time to wait between "tick" events of a conversation'
+ description: '`conversationHeartbeatInterval` is the time to wait between "tick" events of a conversation.'
type: string
conversationTerminatingTimeout:
default: 5s
@@ -4045,7 +4045,7 @@ spec:
type: boolean
enableKubeProbes:
default: true
- description: '`enableKubeProbes` is a flag to enable or disable Kubernetes liveness and readiness probes'
+ description: '`enableKubeProbes` is a flag to enable or disable Kubernetes liveness and readiness probes.'
type: boolean
env:
additionalProperties:
@@ -4058,7 +4058,7 @@ spec:
type: object
healthPort:
default: 8080
- description: '`healthPort` is a collector HTTP port in the Pod that exposes the health check API'
+ description: '`healthPort` is a collector HTTP port in the Pod that exposes the health check API.'
format: int32
maximum: 65535
minimum: 1
@@ -4074,7 +4074,10 @@ spec:
minimum: 1025
type: integer
profilePort:
- description: '`profilePort` allows setting up a Go pprof profiler listening to this port'
+ description: |-
+ `profilePort` allows setting up a Go pprof profiler listening to this port.
+ This is for debugging purpose only. This port should not be exposed, you can
+ access it through local port-forwarding.
format: int32
maximum: 65535
minimum: 0
diff --git a/internal/controller/ebpf/agent_controller_test.go b/internal/controller/ebpf/agent_controller_test.go
index c9e72fb5bf..9aa1c88c19 100644
--- a/internal/controller/ebpf/agent_controller_test.go
+++ b/internal/controller/ebpf/agent_controller_test.go
@@ -218,7 +218,7 @@ func TestBpfmanConfig(t *testing.T) {
assert.Equal(t, corev1.EnvVar{Name: "EBPF_PROGRAM_MANAGER_MODE", Value: "true"}, ds.Spec.Template.Spec.Containers[0].Env[0])
assert.Equal(t, "bpfman-maps", ds.Spec.Template.Spec.Volumes[1].Name)
assert.Equal(t, map[string]string{
- "csi.bpfman.io/maps": "direct_flows,aggregated_flows,aggregated_flows_dns,aggregated_flows_pkt_drop,aggregated_flows_network_events,aggregated_flows_xlat,additional_flow_metrics,packet_record,dns_flows,global_counters,filter_map,peer_filter_map,ipsec_ingress_map,ipsec_egress_map,ssl_data_event_map,dns_name_map",
+ "csi.bpfman.io/maps": "direct_flows,aggregated_flows,aggregated_flows_dns,aggregated_flows_pkt_drop,aggregated_flows_network_events,aggregated_flows_xlat,additional_flow_metrics,packet_record,dns_flows,global_counters,filter_map,peer_filter_map,ipsec_ingress_map,ipsec_egress_map,ssl_data_event_map,dns_name_map,quic_flows",
"csi.bpfman.io/program": "netobserv",
}, ds.Spec.Template.Spec.Volumes[1].CSI.VolumeAttributes)
}
diff --git a/internal/controller/flp/flp_common_objects.go b/internal/controller/flp/flp_common_objects.go
index 3a3f10b63b..a88a1fdc5c 100644
--- a/internal/controller/flp/flp_common_objects.go
+++ b/internal/controller/flp/flp_common_objects.go
@@ -120,16 +120,18 @@ func podTemplate(
case pull:
// does not listen for flows => no port
}
- ports = append(ports, corev1.ContainerPort{
- Name: healthPortName,
- ContainerPort: *advancedConfig.HealthPort,
- })
+ if advancedConfig.HealthPort != nil && *advancedConfig.HealthPort > 0 {
+ ports = append(ports, corev1.ContainerPort{
+ Name: healthPortName,
+ ContainerPort: *advancedConfig.HealthPort,
+ })
+ }
ports = append(ports, corev1.ContainerPort{
Name: prometheusPortName,
ContainerPort: desired.Processor.GetMetricsPort(),
})
- if advancedConfig.ProfilePort != nil {
+ if advancedConfig.ProfilePort != nil && *advancedConfig.ProfilePort > 0 {
ports = append(ports, corev1.ContainerPort{
Name: profilePortName,
ContainerPort: *advancedConfig.ProfilePort,
@@ -272,10 +274,7 @@ func getJSONConfigs(desired *flowslatest.FlowCollectorSpec, vol *volumes.Builder
advancedConfig := helper.GetAdvancedProcessorConfig(desired)
static, dynamic := pipeline.GetSplitStageParams()
config := map[string]interface{}{
- "log-level": desired.Processor.LogLevel,
- "health": map[string]interface{}{
- "port": *advancedConfig.HealthPort,
- },
+ "log-level": desired.Processor.LogLevel,
"pipeline": pipeline.GetStages(),
"parameters": static,
"metricsSettings": metricsSettings,
@@ -285,10 +284,12 @@ func getJSONConfigs(desired *flowslatest.FlowCollectorSpec, vol *volumes.Builder
FileName: configFile,
},
}
- if advancedConfig.ProfilePort != nil {
- config["profile"] = map[string]interface{}{
- "port": *advancedConfig.ProfilePort,
- }
+ if advancedConfig.HealthPort != nil && *advancedConfig.HealthPort != 0 {
+ config["healthAddr"] = fmt.Sprintf(":%d", *advancedConfig.HealthPort)
+ }
+ if advancedConfig.ProfilePort != nil && *advancedConfig.ProfilePort != 0 {
+ // Use "localhost" for ipv4+ipv6 cases, restricted to the local loop
+ config["pprofAddr"] = fmt.Sprintf("localhost:%d", *advancedConfig.ProfilePort)
}
jsonStatic, err := json.Marshal(config)
if err != nil {
diff --git a/internal/pkg/helper/flowcollector.go b/internal/pkg/helper/flowcollector.go
index 10f1f7fc1e..cda0b4f7bf 100644
--- a/internal/pkg/helper/flowcollector.go
+++ b/internal/pkg/helper/flowcollector.go
@@ -153,10 +153,10 @@ func GetAdvancedProcessorConfig(spec *flowslatest.FlowCollectorSpec) flowslatest
if specConfig.Port != nil && *specConfig.Port > 0 {
cfg.Port = specConfig.Port
}
- if specConfig.HealthPort != nil && *specConfig.HealthPort > 0 {
+ if specConfig.HealthPort != nil {
cfg.HealthPort = specConfig.HealthPort
}
- if specConfig.ProfilePort != nil && *specConfig.ProfilePort > 0 {
+ if specConfig.ProfilePort != nil {
cfg.ProfilePort = specConfig.ProfilePort
}
if specConfig.EnableKubeProbes != nil {
diff --git a/vendor/github.com/fsnotify/fsnotify/.cirrus.yml b/vendor/github.com/fsnotify/fsnotify/.cirrus.yml
deleted file mode 100644
index 7f257e99ac..0000000000
--- a/vendor/github.com/fsnotify/fsnotify/.cirrus.yml
+++ /dev/null
@@ -1,14 +0,0 @@
-freebsd_task:
- name: 'FreeBSD'
- freebsd_instance:
- image_family: freebsd-14-2
- install_script:
- - pkg update -f
- - pkg install -y go
- test_script:
- # run tests as user "cirrus" instead of root
- - pw useradd cirrus -m
- - chown -R cirrus:cirrus .
- - FSNOTIFY_BUFFER=4096 sudo --preserve-env=FSNOTIFY_BUFFER -u cirrus go test -parallel 1 -race ./...
- - sudo --preserve-env=FSNOTIFY_BUFFER -u cirrus go test -parallel 1 -race ./...
- - FSNOTIFY_DEBUG=1 sudo --preserve-env=FSNOTIFY_BUFFER -u cirrus go test -parallel 1 -race -v ./...
diff --git a/vendor/github.com/fsnotify/fsnotify/CHANGELOG.md b/vendor/github.com/fsnotify/fsnotify/CHANGELOG.md
index 6468d2cf40..3027f3c67a 100644
--- a/vendor/github.com/fsnotify/fsnotify/CHANGELOG.md
+++ b/vendor/github.com/fsnotify/fsnotify/CHANGELOG.md
@@ -1,5 +1,54 @@
# Changelog
+1.10.1 2026-05-04
+-----------------
+
+### Changes and fixes
+
+- inotify: don't remove sibling watches sharing a path prefix ([#754])
+
+- inotify, windows: don't rename sibling watches sharing a path prefix
+ ([#755])
+
+
+[#754]: https://github.com/fsnotify/fsnotify/pull/754
+[#755]: https://github.com/fsnotify/fsnotify/pull/755
+
+
+1.10.0 2026-04-30
+-----------------
+This version of fsnotify needs Go 1.23.
+
+### Changes and fixes
+
+- inotify: improve initialization error message ([#731])
+
+- inotify: send Rename event if recursive watch is renamed ([#696])
+
+- inotify: avoid copying event buffers when reading names ([#741])
+
+- kqueue: skip dangling symlinks (ENOENT) in watchDirectoryFiles, so a
+ bad entry no longer aborts Watcher.Add for the whole directory ([#748])
+
+- kqueue: drop watches directly in Close() to fix a file descriptor leak
+ when recycling watchers ([#740])
+
+- windows: fix nil pointer dereference in remWatch ([#736])
+
+- windows: lock watch field updates against concurrent WatchList to fix
+ a race introduced in v1.9.0 ([#709], [#749])
+
+
+[#696]: https://github.com/fsnotify/fsnotify/pull/696
+[#709]: https://github.com/fsnotify/fsnotify/pull/709
+[#731]: https://github.com/fsnotify/fsnotify/pull/731
+[#736]: https://github.com/fsnotify/fsnotify/pull/736
+[#740]: https://github.com/fsnotify/fsnotify/pull/740
+[#741]: https://github.com/fsnotify/fsnotify/pull/741
+[#748]: https://github.com/fsnotify/fsnotify/pull/748
+[#749]: https://github.com/fsnotify/fsnotify/pull/749
+
+
1.9.0 2024-04-04
----------------
diff --git a/vendor/github.com/fsnotify/fsnotify/CONTRIBUTING.md b/vendor/github.com/fsnotify/fsnotify/CONTRIBUTING.md
index 4cc40fa597..cd0ee612da 100644
--- a/vendor/github.com/fsnotify/fsnotify/CONTRIBUTING.md
+++ b/vendor/github.com/fsnotify/fsnotify/CONTRIBUTING.md
@@ -77,6 +77,8 @@ End-of-line escapes with `\` are not supported.
debug [yes/no] # Enable/disable FSNOTIFY_DEBUG (tests are run in
parallel by default, so -parallel=1 is probably a good
idea).
+ state # Print internal state to stderr (exact output differs
+ # per backend).
print [any strings] # Print text to stdout; for debugging.
touch path
diff --git a/vendor/github.com/fsnotify/fsnotify/README.md b/vendor/github.com/fsnotify/fsnotify/README.md
index 1f4eb583d5..2e56ef4c9a 100644
--- a/vendor/github.com/fsnotify/fsnotify/README.md
+++ b/vendor/github.com/fsnotify/fsnotify/README.md
@@ -1,7 +1,7 @@
fsnotify is a Go library to provide cross-platform filesystem notifications on
Windows, Linux, macOS, BSD, and illumos.
-Go 1.17 or newer is required; the full documentation is at
+Go 1.23 or newer is required; the full documentation is at
https://pkg.go.dev/github.com/fsnotify/fsnotify
---
@@ -12,7 +12,7 @@ Platform support:
| :-------------------- | :--------- | :------------------------------------------------------------------------ |
| inotify | Linux | Supported |
| kqueue | BSD, macOS | Supported |
-| ReadDirectoryChangesW | Windows | Supported |
+| ReadDirectoryChangesW | Windows | Supported ([excluding `Chmod` operations][#487]) |
| FEN | illumos | Supported |
| fanotify | Linux 5.9+ | [Not yet](https://github.com/fsnotify/fsnotify/issues/114) |
| FSEvents | macOS | [Needs support in x/sys/unix][fsevents] |
@@ -22,6 +22,7 @@ Platform support:
Linux and illumos should include Android and Solaris, but these are currently
untested.
+[#487]: https://github.com/fsnotify/fsnotify/issues/487
[fsevents]: https://github.com/fsnotify/fsnotify/issues/11#issuecomment-1279133120
[usn]: https://github.com/fsnotify/fsnotify/issues/53#issuecomment-1279829847
@@ -126,7 +127,7 @@ settings* until we have a native FSEvents implementation (see [#11]).
### Watching a file doesn't work well
Watching individual files (rather than directories) is generally not recommended
as many programs (especially editors) update files atomically: it will write to
-a temporary file which is then moved to to destination, overwriting the original
+a temporary file which is then moved to a destination, overwriting the original
(or some variant thereof). The watcher on the original file is now lost, as that
no longer exists.
@@ -151,26 +152,57 @@ This is the event that inotify sends, so not much can be changed about this.
The `fs.inotify.max_user_watches` sysctl variable specifies the upper limit for
the number of watches per user, and `fs.inotify.max_user_instances` specifies
the maximum number of inotify instances per user. Every Watcher you create is an
-"instance", and every path you add is a "watch".
+"instance", and every path you add is a "watch". Reaching the limit will result
+in a "no space left on device" or "too many open files" error.
These are also exposed in `/proc` as `/proc/sys/fs/inotify/max_user_watches` and
-`/proc/sys/fs/inotify/max_user_instances`
+`/proc/sys/fs/inotify/max_user_instances`. The default values differ per distro
+and available memory.
To increase them you can use `sysctl` or write the value to proc file:
- # The default values on Linux 5.18
- sysctl fs.inotify.max_user_watches=124983
- sysctl fs.inotify.max_user_instances=128
+ sysctl fs.inotify.max_user_watches=200000
+ sysctl fs.inotify.max_user_instances=256
To make the changes persist on reboot edit `/etc/sysctl.conf` or
`/usr/lib/sysctl.d/50-default.conf` (details differ per Linux distro; check your
distro's documentation):
- fs.inotify.max_user_watches=124983
- fs.inotify.max_user_instances=128
+ fs.inotify.max_user_watches=200000
+ fs.inotify.max_user_instances=256
+
+### Windows
+Recursive watching is not currently enabled through fsnotify's public API
+(see the FAQ "Are subdirectories watched?" above). The notes below
+describe Windows backend behavior observed when recursive watching is
+enabled internally (for example, in fsnotify's own tests). They are kept
+here as a reference for maintainers and contributors who encounter the
+behavior, since the recursive code path still exists in the backend.
+
+When recursive watching is enabled and you watch a directory, you may
+receive a `Write` event for an intermediate directory whenever a child
+entry inside it is created, renamed, or removed. For example, with a
+recursive watch on `/a` and a new file `/a/b/c`, you will receive
+`Create /a/b/c` and may also receive `Write /a/b`.
+
+This happens because, on NTFS-backed volumes, modifying the entries of a
+directory updates that directory's last-write time, and the Windows
+backend requests `FILE_NOTIFY_CHANGE_LAST_WRITE` to support `Write` events
+on files. The same `Write` filter therefore picks up the directory's
+metadata update.
+
+kqueue has the same "directory `Write` = directory contents changed"
+semantics, so portable code that treats `Write` on a directory as
+"something inside it changed" works on Windows and BSD/macOS, but not on
+Linux (inotify uses `Write` only for file-content changes). If you only
+care about file content, filter out `Write` events whose path refers to a
+directory.
+
+Whether the directory `Write` is actually delivered alongside the child
+events is not guaranteed: it depends on `ReadDirectoryChangesW` buffering,
+NTFS metadata update timing, and event coalescing, none of which fsnotify
+controls.
-Reaching the limit will result in a "no space left on device" or "too many open
-files" error.
### kqueue (macOS, all BSD systems)
kqueue requires opening a file descriptor for every file that's being watched;
diff --git a/vendor/github.com/fsnotify/fsnotify/backend_fen.go b/vendor/github.com/fsnotify/fsnotify/backend_fen.go
index 57fc692848..e43c6d088c 100644
--- a/vendor/github.com/fsnotify/fsnotify/backend_fen.go
+++ b/vendor/github.com/fsnotify/fsnotify/backend_fen.go
@@ -158,7 +158,9 @@ func (w *fen) readEvents() {
pevents := make([]unix.PortEvent, 8)
for {
- count, err := w.port.Get(pevents, 1, nil)
+ count, err := internal.IgnoringEINTR(func() (int, error) {
+ return w.port.Get(pevents, 1, nil)
+ })
if err != nil && err != unix.ETIME {
// Interrupted system call (count should be 0) ignore and continue
if errors.Is(err, unix.EINTR) && count == 0 {
diff --git a/vendor/github.com/fsnotify/fsnotify/backend_inotify.go b/vendor/github.com/fsnotify/fsnotify/backend_inotify.go
index a36cb89d73..4c3f6f7c28 100644
--- a/vendor/github.com/fsnotify/fsnotify/backend_inotify.go
+++ b/vendor/github.com/fsnotify/fsnotify/backend_inotify.go
@@ -55,10 +55,10 @@ type (
path map[string]uint32 // pathname → wd
}
watch struct {
- wd uint32 // Watch descriptor (as returned by the inotify_add_watch() syscall)
- flags uint32 // inotify flags of this watch (see inotify(7) for the list of valid flags)
- path string // Watch path.
- recurse bool // Recursion with ./...?
+ wd uint32 // Watch descriptor (as returned by the inotify_add_watch() syscall)
+ flags uint32 // inotify flags of this watch (see inotify(7) for the list of valid flags)
+ path string // Watch path.
+ watchFlags watchFlag
}
koekje struct {
cookie uint32
@@ -66,6 +66,9 @@ type (
}
)
+func (w watch) byUser() bool { return w.watchFlags&flagByUser != 0 }
+func (w watch) recurse() bool { return w.watchFlags&flagRecurse != 0 }
+
func newWatches() *watches {
return &watches{
wd: make(map[uint32]*watch),
@@ -79,6 +82,13 @@ func (w *watches) len() int { return len(w.wd) }
func (w *watches) add(ww *watch) { w.wd[ww.wd] = ww; w.path[ww.path] = ww.wd }
func (w *watches) remove(watch *watch) { delete(w.path, watch.path); delete(w.wd, watch.wd) }
+func isSameOrDescendantPath(path, root string) bool {
+ if path == root {
+ return true
+ }
+ return strings.HasPrefix(path, root+string(os.PathSeparator))
+}
+
func (w *watches) removePath(path string) ([]uint32, error) {
path, recurse := recursivePath(path)
wd, ok := w.path[path]
@@ -87,20 +97,20 @@ func (w *watches) removePath(path string) ([]uint32, error) {
}
watch := w.wd[wd]
- if recurse && !watch.recurse {
+ if recurse && !watch.recurse() {
return nil, fmt.Errorf("can't use /... with non-recursive watch %q", path)
}
delete(w.path, path)
delete(w.wd, wd)
- if !watch.recurse {
+ if !watch.recurse() {
return []uint32{wd}, nil
}
wds := make([]uint32, 0, 8)
wds = append(wds, wd)
for p, rwd := range w.path {
- if strings.HasPrefix(p, path) {
+ if isSameOrDescendantPath(p, path) {
delete(w.path, p)
delete(w.wd, rwd)
wds = append(wds, rwd)
@@ -139,7 +149,7 @@ func newBackend(ev chan Event, errs chan error) (backend, error) {
// I/O operations won't terminate on close.
fd, errno := unix.InotifyInit1(unix.IN_CLOEXEC | unix.IN_NONBLOCK)
if fd == -1 {
- return nil, errno
+ return nil, fmt.Errorf("couldn't initialize inotify: %w", errno)
}
w := &inotify{
@@ -188,11 +198,8 @@ func (w *inotify) AddWith(path string, opts ...addOpt) error {
return fmt.Errorf("%w: %s", xErrUnsupported, with.op)
}
- add := func(path string, with withOpts, recurse bool) error {
+ add := func(path string, with withOpts, wf watchFlag) error {
var flags uint32
- if with.noFollow {
- flags |= unix.IN_DONT_FOLLOW
- }
if with.op.Has(Create) {
flags |= unix.IN_CREATE
}
@@ -220,7 +227,7 @@ func (w *inotify) AddWith(path string, opts ...addOpt) error {
if with.op.Has(xUnportableCloseRead) {
flags |= unix.IN_CLOSE_NOWRITE
}
- return w.register(path, flags, recurse)
+ return w.register(path, flags, wf)
}
w.mu.Lock()
@@ -248,14 +255,18 @@ func (w *inotify) AddWith(path string, opts ...addOpt) error {
w.sendEvent(Event{Name: root, Op: Create})
}
- return add(root, with, true)
+ wf := flagRecurse
+ if root == path {
+ wf |= flagByUser
+ }
+ return add(root, with, wf)
})
}
- return add(path, with, false)
+ return add(path, with, 0)
}
-func (w *inotify) register(path string, flags uint32, recurse bool) error {
+func (w *inotify) register(path string, flags uint32, wf watchFlag) error {
return w.watches.updatePath(path, func(existing *watch) (*watch, error) {
if existing != nil {
flags |= existing.flags | unix.IN_MASK_ADD
@@ -272,10 +283,10 @@ func (w *inotify) register(path string, flags uint32, recurse bool) error {
if existing == nil {
return &watch{
- wd: uint32(wd),
- path: path,
- flags: flags,
- recurse: recurse,
+ wd: uint32(wd),
+ path: path,
+ flags: flags,
+ watchFlags: wf,
}, nil
}
@@ -425,11 +436,7 @@ func (w *inotify) handleEvent(inEvent *unix.InotifyEvent, buf *[65536]byte, offs
nameLen = uint32(inEvent.Len)
)
if nameLen > 0 {
- /// Point "bytes" at the first byte of the filename
- bb := *buf
- bytes := (*[unix.PathMax]byte)(unsafe.Pointer(&bb[offset+unix.SizeofInotifyEvent]))[:nameLen:nameLen]
- /// The filename is padded with NULL bytes. TrimRight() gets rid of those.
- name += "/" + strings.TrimRight(string(bytes[0:nameLen]), "\x00")
+ name += "/" + inotifyEventName(buf, offset, nameLen)
}
if debug {
@@ -450,7 +457,9 @@ func (w *inotify) handleEvent(inEvent *unix.InotifyEvent, buf *[65536]byte, offs
// We can't really update the state when a watched path is moved; only
// IN_MOVE_SELF is sent and not IN_MOVED_{FROM,TO}. So remove the watch.
if inEvent.Mask&unix.IN_MOVE_SELF == unix.IN_MOVE_SELF {
- if watch.recurse { // Do nothing
+ // Watch is set up as part of recurse: do nothing as the move gets
+ // registered from the parent directory.
+ if watch.recurse() && !watch.byUser() {
return Event{}, true
}
@@ -460,6 +469,10 @@ func (w *inotify) handleEvent(inEvent *unix.InotifyEvent, buf *[65536]byte, offs
return Event{}, false
}
}
+
+ if watch.recurse() {
+ return Event{Name: watch.path, Op: Rename}, true
+ }
}
/// Skip if we're watching both this path and the parent; the parent will
@@ -473,11 +486,11 @@ func (w *inotify) handleEvent(inEvent *unix.InotifyEvent, buf *[65536]byte, offs
ev := w.newEvent(name, inEvent.Mask, inEvent.Cookie)
// Need to update watch path for recurse.
- if watch.recurse {
+ if watch.recurse() {
isDir := inEvent.Mask&unix.IN_ISDIR == unix.IN_ISDIR
/// New directory created: set up watch on it.
if isDir && ev.Has(Create) {
- err := w.register(ev.Name, watch.flags, true)
+ err := w.register(ev.Name, watch.flags, flagRecurse)
if !w.sendError(err) {
return Event{}, false
}
@@ -495,7 +508,7 @@ func (w *inotify) handleEvent(inEvent *unix.InotifyEvent, buf *[65536]byte, offs
if k == watch.wd || ww.path == ev.Name {
continue
}
- if strings.HasPrefix(ww.path, ev.renamedFrom) {
+ if isSameOrDescendantPath(ww.path, ev.renamedFrom) {
ww.path = strings.Replace(ww.path, ev.renamedFrom, ev.Name, 1)
w.watches.wd[k] = ww
}
@@ -507,12 +520,13 @@ func (w *inotify) handleEvent(inEvent *unix.InotifyEvent, buf *[65536]byte, offs
return ev, true
}
-func (w *inotify) isRecursive(path string) bool {
- ww := w.watches.byPath(path)
- if ww == nil { // path could be a file, so also check the Dir.
- ww = w.watches.byPath(filepath.Dir(path))
+func inotifyEventName(buf *[65536]byte, offset, nameLen uint32) string {
+ start := int(offset + unix.SizeofInotifyEvent)
+ bytes := (*[unix.PathMax]byte)(unsafe.Pointer(&buf[start]))[:nameLen:nameLen]
+ for nameLen > 0 && bytes[nameLen-1] == 0 {
+ nameLen--
}
- return ww != nil && ww.recurse
+ return string(bytes[:nameLen])
}
func (w *inotify) newEvent(name string, mask, cookie uint32) Event {
@@ -578,6 +592,6 @@ func (w *inotify) state() {
w.mu.Lock()
defer w.mu.Unlock()
for wd, ww := range w.watches.wd {
- fmt.Fprintf(os.Stderr, "%4d: recurse=%t %q\n", wd, ww.recurse, ww.path)
+ fmt.Fprintf(os.Stderr, "%4d: %q watchFlags=0x%x\n", wd, ww.path, ww.watchFlags)
}
}
diff --git a/vendor/github.com/fsnotify/fsnotify/backend_kqueue.go b/vendor/github.com/fsnotify/fsnotify/backend_kqueue.go
index 340aeec061..d2c8cfb6c6 100644
--- a/vendor/github.com/fsnotify/fsnotify/backend_kqueue.go
+++ b/vendor/github.com/fsnotify/fsnotify/backend_kqueue.go
@@ -8,6 +8,7 @@ import (
"os"
"path/filepath"
"runtime"
+ "sort"
"sync"
"time"
@@ -245,9 +246,26 @@ func (w *kqueue) Close() error {
return nil
}
+ // Snapshot and drop all watches directly. w.Remove -> w.remove
+ // short-circuits on isClosed() (which is already true after
+ // w.shared.close() above), so calling Remove here in the happy path
+ // leaked every watched directory + file descriptor. On macOS a
+ // single directory watch opens an fd for every file in the dir, so
+ // long-running processes that recreate watchers (hot-reload dev
+ // servers, etc.) ran out of fds with EMFILE (#732).
pathsToRemove := w.watches.listPaths(false)
for _, name := range pathsToRemove {
- w.Remove(name)
+ info, ok := w.watches.byPath(name)
+ if !ok {
+ // w.path has an entry for name but w.wd doesn't --
+ // drop the stale lookup entry so the map state is
+ // consistent after Close.
+ w.watches.remove(0, name)
+ continue
+ }
+ _ = w.register([]int{info.wd}, unix.EV_DELETE, 0)
+ unix.Close(info.wd)
+ w.watches.remove(info.wd, name)
}
unix.Close(w.closepipe[1]) // Send "quit" message to readEvents
@@ -376,19 +394,12 @@ func (w *kqueue) addWatch(name string, flags uint32, listDir bool) (string, erro
}
}
- // Retry on EINTR; open() can return EINTR in practice on macOS.
- // See #354, and Go issues 11180 and 39237.
- for {
- info.wd, err = unix.Open(name, openMode, 0)
- if err == nil {
- break
- }
- if errors.Is(err, unix.EINTR) {
- continue
- }
+ info.wd, err = internal.IgnoringEINTR(func() (int, error) {
+ return unix.Open(name, openMode, 0)
+ })
+ if err != nil {
return "", err
}
-
info.isDir = fi.IsDir()
}
@@ -436,9 +447,10 @@ func (w *kqueue) readEvents() {
eventBuffer := make([]unix.Kevent_t, 10)
for {
- kevents, err := w.read(eventBuffer)
- // EINTR is okay, the syscall was interrupted before timeout expired.
- if err != nil && err != unix.EINTR {
+ kevents, err := internal.IgnoringEINTR(func() ([]unix.Kevent_t, error) {
+ return w.read(eventBuffer)
+ })
+ if err != nil {
if !w.sendError(fmt.Errorf("fsnotify.readEvents: %w", err)) {
return
}
@@ -583,12 +595,14 @@ func (w *kqueue) watchDirectoryFiles(dirPath string) error {
cleanPath, err := w.internalWatch(path, fi)
if err != nil {
- // No permission to read the file; that's not a problem: just skip.
- // But do add it to w.fileExists to prevent it from being picked up
- // as a "new" file later (it still shows up in the directory
+ // No permission, or the entry resolved to a missing target
+ // (e.g. a dangling symlink): not a problem, just skip. But
+ // do mark it as seen to prevent it from being picked up as
+ // a "new" file later (it still shows up in the directory
// listing).
switch {
- case errors.Is(err, unix.EACCES) || errors.Is(err, unix.EPERM):
+ case errors.Is(err, unix.EACCES) || errors.Is(err, unix.EPERM) ||
+ errors.Is(err, os.ErrNotExist):
cleanPath = filepath.Clean(path)
default:
return fmt.Errorf("%q: %w", path, err)
@@ -703,3 +717,19 @@ func (w *kqueue) xSupports(op Op) bool {
}
return true
}
+
+func (w *kqueue) state() {
+ w.watches.mu.Lock()
+ defer w.watches.mu.Unlock()
+
+ all := make([]int, 0, len(w.watches.wd))
+ for wd := range w.watches.wd {
+ all = append(all, wd)
+ }
+ sort.Ints(all)
+
+ for _, wd := range all {
+ ww := w.watches.wd[wd]
+ fmt.Fprintf(os.Stderr, "%4d %q linkname=%q\n", wd, ww.name, ww.linkName)
+ }
+}
diff --git a/vendor/github.com/fsnotify/fsnotify/backend_windows.go b/vendor/github.com/fsnotify/fsnotify/backend_windows.go
index 3433642d64..fb9210f24e 100644
--- a/vendor/github.com/fsnotify/fsnotify/backend_windows.go
+++ b/vendor/github.com/fsnotify/fsnotify/backend_windows.go
@@ -11,7 +11,6 @@ import (
"fmt"
"os"
"path/filepath"
- "reflect"
"runtime"
"strings"
"sync"
@@ -37,6 +36,13 @@ type readDirChangesW struct {
var defaultBufferSize = 50
+func isSameOrDescendantPath(path, root string) bool {
+ if path == root {
+ return true
+ }
+ return strings.HasPrefix(path, root+string(os.PathSeparator))
+}
+
func newBackend(ev chan Event, errs chan error) (backend, error) {
port, err := windows.CreateIoCompletionPort(windows.InvalidHandle, 0, 0, 0)
if err != nil {
@@ -359,22 +365,26 @@ func (w *readDirChangesW) addWatch(pathname string, flags uint64, bufsize int) e
} else {
windows.CloseHandle(ino.handle)
}
+ w.mu.Lock()
if pathname == dir {
watchEntry.mask |= flags
} else {
watchEntry.names[filepath.Base(pathname)] |= flags
}
+ w.mu.Unlock()
err = w.startRead(watchEntry)
if err != nil {
return err
}
+ w.mu.Lock()
if pathname == dir {
watchEntry.mask &= ^provisional
} else {
watchEntry.names[filepath.Base(pathname)] &= ^provisional
}
+ w.mu.Unlock()
return nil
}
@@ -394,8 +404,13 @@ func (w *readDirChangesW) remWatch(pathname string) error {
w.mu.Lock()
watch := w.watches.get(ino)
w.mu.Unlock()
+ if watch == nil {
+ windows.CloseHandle(ino.handle)
+ return fmt.Errorf("%w: %s", ErrNonExistentWatch, pathname)
+ }
if recurse && !watch.recurse {
+ windows.CloseHandle(ino.handle)
return fmt.Errorf("can't use \\... with non-recursive watch %q", pathname)
}
@@ -403,16 +418,19 @@ func (w *readDirChangesW) remWatch(pathname string) error {
if err != nil {
w.sendError(os.NewSyscallError("CloseHandle", err))
}
- if watch == nil {
- return fmt.Errorf("%w: %s", ErrNonExistentWatch, pathname)
- }
if pathname == dir {
- w.sendEvent(watch.path, "", watch.mask&sysFSIGNORED)
+ w.mu.Lock()
+ mask := watch.mask
watch.mask = 0
+ w.mu.Unlock()
+ w.sendEvent(watch.path, "", mask&sysFSIGNORED)
} else {
name := filepath.Base(pathname)
- w.sendEvent(filepath.Join(watch.path, name), "", watch.names[name]&sysFSIGNORED)
+ w.mu.Lock()
+ mask := watch.names[name]
delete(watch.names, name)
+ w.mu.Unlock()
+ w.sendEvent(filepath.Join(watch.path, name), "", mask&sysFSIGNORED)
}
return w.startRead(watch)
@@ -420,17 +438,23 @@ func (w *readDirChangesW) remWatch(pathname string) error {
// Must run within the I/O thread.
func (w *readDirChangesW) deleteWatch(watch *watch) {
- for name, mask := range watch.names {
- if mask&provisional == 0 {
- w.sendEvent(filepath.Join(watch.path, name), "", mask&sysFSIGNORED)
+ // Snapshot+clear under the lock so concurrent WatchList() readers see a
+ // consistent state. sendEvent must run outside the lock since it can
+ // block on the user-facing Events channel.
+ w.mu.Lock()
+ names := watch.names
+ watch.names = make(map[string]uint64)
+ mask := watch.mask
+ watch.mask = 0
+ w.mu.Unlock()
+
+ for name, m := range names {
+ if m&provisional == 0 {
+ w.sendEvent(filepath.Join(watch.path, name), "", m&sysFSIGNORED)
}
- delete(watch.names, name)
}
- if watch.mask != 0 {
- if watch.mask&provisional == 0 {
- w.sendEvent(watch.path, "", watch.mask&sysFSIGNORED)
- }
- watch.mask = 0
+ if mask != 0 && mask&provisional == 0 {
+ w.sendEvent(watch.path, "", mask&sysFSIGNORED)
}
}
@@ -457,9 +481,8 @@ func (w *readDirChangesW) startRead(watch *watch) error {
}
// We need to pass the array, rather than the slice.
- hdr := (*reflect.SliceHeader)(unsafe.Pointer(&watch.buf))
rdErr := windows.ReadDirectoryChanges(watch.ino.handle,
- (*byte)(unsafe.Pointer(hdr.Data)), uint32(hdr.Len),
+ unsafe.SliceData(watch.buf), uint32(len(watch.buf)),
watch.recurse, mask, nil, &watch.ov, 0)
if rdErr != nil {
err := os.NewSyscallError("ReadDirectoryChanges", rdErr)
@@ -565,12 +588,7 @@ func (w *readDirChangesW) readEvents() {
// Create a buf that is the size of the path name
size := int(raw.FileNameLength / 2)
- var buf []uint16
- // TODO: Use unsafe.Slice in Go 1.17; https://stackoverflow.com/questions/51187973
- sh := (*reflect.SliceHeader)(unsafe.Pointer(&buf))
- sh.Data = uintptr(unsafe.Pointer(&raw.FileName))
- sh.Len = size
- sh.Cap = size
+ buf := unsafe.Slice(&raw.FileName, size)
name := windows.UTF16ToString(buf)
fullname := filepath.Join(watch.path, name)
@@ -587,31 +605,35 @@ func (w *readDirChangesW) readEvents() {
case windows.FILE_ACTION_RENAMED_OLD_NAME:
watch.rename = name
case windows.FILE_ACTION_RENAMED_NEW_NAME:
- // Update saved path of all sub-watches.
+ // Update saved path of all sub-watches and rename the
+ // names entry under the lock so WatchList() can't observe
+ // a torn state.
old := filepath.Join(watch.path, watch.rename)
w.mu.Lock()
for _, watchMap := range w.watches {
for _, ww := range watchMap {
- if strings.HasPrefix(ww.path, old) {
+ if isSameOrDescendantPath(ww.path, old) {
ww.path = filepath.Join(fullname, strings.TrimPrefix(ww.path, old))
}
}
}
- w.mu.Unlock()
-
if watch.names[watch.rename] != 0 {
watch.names[name] |= watch.names[watch.rename]
delete(watch.names, watch.rename)
mask = sysFSMOVESELF
}
+ w.mu.Unlock()
}
if raw.Action != windows.FILE_ACTION_RENAMED_NEW_NAME {
w.sendEvent(fullname, "", watch.names[name]&mask)
}
if raw.Action == windows.FILE_ACTION_REMOVED {
- w.sendEvent(fullname, "", watch.names[name]&sysFSIGNORED)
+ w.mu.Lock()
+ ignored := watch.names[name] & sysFSIGNORED
delete(watch.names, name)
+ w.mu.Unlock()
+ w.sendEvent(fullname, "", ignored)
}
if watch.rename != "" && raw.Action == windows.FILE_ACTION_RENAMED_NEW_NAME {
diff --git a/vendor/github.com/fsnotify/fsnotify/fsnotify.go b/vendor/github.com/fsnotify/fsnotify/fsnotify.go
index f64be4bf98..38cb4dd481 100644
--- a/vendor/github.com/fsnotify/fsnotify/fsnotify.go
+++ b/vendor/github.com/fsnotify/fsnotify/fsnotify.go
@@ -51,26 +51,25 @@ import (
// The fs.inotify.max_user_watches sysctl variable specifies the upper limit
// for the number of watches per user, and fs.inotify.max_user_instances
// specifies the maximum number of inotify instances per user. Every Watcher you
-// create is an "instance", and every path you add is a "watch".
+// create is an "instance", and every path you add is a "watch". Reaching the
+// limit will result in a "no space left on device" or "too many open files"
+// error.
//
// These are also exposed in /proc as /proc/sys/fs/inotify/max_user_watches and
-// /proc/sys/fs/inotify/max_user_instances
+// /proc/sys/fs/inotify/max_user_instances. The default values differ per distro
+// and available memory.
//
// To increase them you can use sysctl or write the value to the /proc file:
//
-// # Default values on Linux 5.18
-// sysctl fs.inotify.max_user_watches=124983
-// sysctl fs.inotify.max_user_instances=128
+// sysctl fs.inotify.max_user_watches=200000
+// sysctl fs.inotify.max_user_instances=256
//
// To make the changes persist on reboot edit /etc/sysctl.conf or
// /usr/lib/sysctl.d/50-default.conf (details differ per Linux distro; check
// your distro's documentation):
//
-// fs.inotify.max_user_watches=124983
-// fs.inotify.max_user_instances=128
-//
-// Reaching the limit will result in a "no space left on device" or "too many open
-// files" error.
+// fs.inotify.max_user_watches=200000
+// fs.inotify.max_user_instances=256
//
// # kqueue notes (macOS, BSD)
//
@@ -93,6 +92,28 @@ import (
// Sometimes it will send events for all files, sometimes it will send no
// events, and often only for some files.
//
+// Recursive watching is not currently enabled through fsnotify's public
+// API; the recursive code path is gated and only exercised by fsnotify's
+// own tests. The note below describes backend behavior observed when
+// recursive watching is enabled internally, and is kept here as a
+// reference for maintainers and contributors who encounter it.
+//
+// When recursive watching is enabled and you watch a directory, you may
+// receive a Write event for an intermediate directory whenever a child
+// entry inside it is created, renamed, or removed. For example, with a
+// recursive watch on /a and a new file /a/b/c, you will receive
+// Create /a/b/c and may also receive Write /a/b.
+//
+// This happens because, on NTFS-backed volumes, modifying the entries of a
+// directory updates that directory's last-write time, and the Windows
+// backend requests FILE_NOTIFY_CHANGE_LAST_WRITE to support Write events
+// on files. The same Write filter therefore picks up the directory's
+// metadata update.
+//
+// Whether the directory Write is actually delivered alongside the child
+// events is not guaranteed; it depends on ReadDirectoryChangesW buffering,
+// NTFS metadata update timing, and event coalescing.
+//
// The default ReadDirectoryChangesW() buffer size is 64K, which is the largest
// value that is guaranteed to work with SMB filesystems. If you have many
// events in quick succession this may not be enough, and you will have to use
@@ -129,8 +150,12 @@ type Watcher struct {
// want to wait until you've stopped receiving them
// (see the dedup example in cmd/fsnotify).
//
- // Some systems may send Write event for directories
- // when the directory content changes.
+ // Some systems also send Write events for directories
+ // when the directory contents change. This is the
+ // case for kqueue, and on Windows for the directory
+ // that contains a created, renamed, or removed child
+ // entry. It does not happen on inotify. See the
+ // per-platform notes on [Watcher].
//
// fsnotify.Chmod Attributes were changed. On Linux this is also sent
// when a file is removed (or more accurately, when a
@@ -179,7 +204,9 @@ const (
Create Op = 1 << iota
// The pathname was written to; this does *not* mean the write has finished,
- // and a write can be followed by more writes.
+ // and a write can be followed by more writes. On Windows and kqueue, a
+ // Write on a directory can also indicate that its contents changed; see
+ // the per-platform notes on [Watcher].
Write
// The path was removed; any watches on it will be removed. Some "remove"
@@ -220,7 +247,7 @@ const (
// File opened for reading was closed.
//
- // Only works on Linux and FreeBSD.
+ // Only works on Linux.
xUnportableCloseRead
)
@@ -410,7 +437,6 @@ type (
withOpts struct {
bufsize int
op Op
- noFollow bool
sendCreate bool
}
)
@@ -469,12 +495,6 @@ func withOps(op Op) addOpt {
return func(opt *withOpts) { opt.op = op }
}
-// WithNoFollow disables following symlinks, so the symlinks themselves are
-// watched.
-func withNoFollow() addOpt {
- return func(opt *withOpts) { opt.noFollow = true }
-}
-
// "Internal" option for recursive watches on inotify.
func withCreate() addOpt {
return func(opt *withOpts) { opt.sendCreate = true }
@@ -494,3 +514,13 @@ func recursivePath(path string) (string, bool) {
}
return path, false
}
+
+type watchFlag uint8
+
+const (
+ // Added by user with Add(), rather than an internal watch.
+ flagByUser = watchFlag(0x01)
+ // Part of recursive watch; as the top-level path added by the user or an
+ // "internal" watch.
+ flagRecurse = watchFlag(0x02)
+)
diff --git a/vendor/github.com/fsnotify/fsnotify/internal/darwin.go b/vendor/github.com/fsnotify/fsnotify/internal/darwin.go
index 0b01bc182a..6721aa6096 100644
--- a/vendor/github.com/fsnotify/fsnotify/internal/darwin.go
+++ b/vendor/github.com/fsnotify/fsnotify/internal/darwin.go
@@ -15,25 +15,6 @@ var (
var maxfiles uint64
-func SetRlimit() {
- // Go 1.19 will do this automatically: https://go-review.googlesource.com/c/go/+/393354/
- var l syscall.Rlimit
- err := syscall.Getrlimit(syscall.RLIMIT_NOFILE, &l)
- if err == nil && l.Cur != l.Max {
- l.Cur = l.Max
- syscall.Setrlimit(syscall.RLIMIT_NOFILE, &l)
- }
- maxfiles = l.Cur
-
- if n, err := syscall.SysctlUint32("kern.maxfiles"); err == nil && uint64(n) < maxfiles {
- maxfiles = uint64(n)
- }
-
- if n, err := syscall.SysctlUint32("kern.maxfilesperproc"); err == nil && uint64(n) < maxfiles {
- maxfiles = uint64(n)
- }
-}
-
func Maxfiles() uint64 { return maxfiles }
func Mkfifo(path string, mode uint32) error { return unix.Mkfifo(path, mode) }
func Mknod(path string, mode uint32, dev int) error { return unix.Mknod(path, mode, dev) }
diff --git a/vendor/github.com/fsnotify/fsnotify/internal/debug_darwin.go b/vendor/github.com/fsnotify/fsnotify/internal/debug_darwin.go
index 928319fb09..7600180742 100644
--- a/vendor/github.com/fsnotify/fsnotify/internal/debug_darwin.go
+++ b/vendor/github.com/fsnotify/fsnotify/internal/debug_darwin.go
@@ -6,52 +6,10 @@ var names = []struct {
n string
m uint32
}{
- {"NOTE_ABSOLUTE", unix.NOTE_ABSOLUTE},
{"NOTE_ATTRIB", unix.NOTE_ATTRIB},
- {"NOTE_BACKGROUND", unix.NOTE_BACKGROUND},
- {"NOTE_CHILD", unix.NOTE_CHILD},
- {"NOTE_CRITICAL", unix.NOTE_CRITICAL},
{"NOTE_DELETE", unix.NOTE_DELETE},
- {"NOTE_EXEC", unix.NOTE_EXEC},
- {"NOTE_EXIT", unix.NOTE_EXIT},
- {"NOTE_EXITSTATUS", unix.NOTE_EXITSTATUS},
- {"NOTE_EXIT_CSERROR", unix.NOTE_EXIT_CSERROR},
- {"NOTE_EXIT_DECRYPTFAIL", unix.NOTE_EXIT_DECRYPTFAIL},
- {"NOTE_EXIT_DETAIL", unix.NOTE_EXIT_DETAIL},
- {"NOTE_EXIT_DETAIL_MASK", unix.NOTE_EXIT_DETAIL_MASK},
- {"NOTE_EXIT_MEMORY", unix.NOTE_EXIT_MEMORY},
- {"NOTE_EXIT_REPARENTED", unix.NOTE_EXIT_REPARENTED},
{"NOTE_EXTEND", unix.NOTE_EXTEND},
- {"NOTE_FFAND", unix.NOTE_FFAND},
- {"NOTE_FFCOPY", unix.NOTE_FFCOPY},
- {"NOTE_FFCTRLMASK", unix.NOTE_FFCTRLMASK},
- {"NOTE_FFLAGSMASK", unix.NOTE_FFLAGSMASK},
- {"NOTE_FFNOP", unix.NOTE_FFNOP},
- {"NOTE_FFOR", unix.NOTE_FFOR},
- {"NOTE_FORK", unix.NOTE_FORK},
- {"NOTE_FUNLOCK", unix.NOTE_FUNLOCK},
- {"NOTE_LEEWAY", unix.NOTE_LEEWAY},
{"NOTE_LINK", unix.NOTE_LINK},
- {"NOTE_LOWAT", unix.NOTE_LOWAT},
- {"NOTE_MACHTIME", unix.NOTE_MACHTIME},
- {"NOTE_MACH_CONTINUOUS_TIME", unix.NOTE_MACH_CONTINUOUS_TIME},
- {"NOTE_NONE", unix.NOTE_NONE},
- {"NOTE_NSECONDS", unix.NOTE_NSECONDS},
- {"NOTE_OOB", unix.NOTE_OOB},
- //{"NOTE_PCTRLMASK", unix.NOTE_PCTRLMASK}, -0x100000 (?!)
- {"NOTE_PDATAMASK", unix.NOTE_PDATAMASK},
- {"NOTE_REAP", unix.NOTE_REAP},
{"NOTE_RENAME", unix.NOTE_RENAME},
- {"NOTE_REVOKE", unix.NOTE_REVOKE},
- {"NOTE_SECONDS", unix.NOTE_SECONDS},
- {"NOTE_SIGNAL", unix.NOTE_SIGNAL},
- {"NOTE_TRACK", unix.NOTE_TRACK},
- {"NOTE_TRACKERR", unix.NOTE_TRACKERR},
- {"NOTE_TRIGGER", unix.NOTE_TRIGGER},
- {"NOTE_USECONDS", unix.NOTE_USECONDS},
- {"NOTE_VM_ERROR", unix.NOTE_VM_ERROR},
- {"NOTE_VM_PRESSURE", unix.NOTE_VM_PRESSURE},
- {"NOTE_VM_PRESSURE_SUDDEN_TERMINATE", unix.NOTE_VM_PRESSURE_SUDDEN_TERMINATE},
- {"NOTE_VM_PRESSURE_TERMINATE", unix.NOTE_VM_PRESSURE_TERMINATE},
{"NOTE_WRITE", unix.NOTE_WRITE},
}
diff --git a/vendor/github.com/fsnotify/fsnotify/internal/debug_dragonfly.go b/vendor/github.com/fsnotify/fsnotify/internal/debug_dragonfly.go
index 3186b0c349..7600180742 100644
--- a/vendor/github.com/fsnotify/fsnotify/internal/debug_dragonfly.go
+++ b/vendor/github.com/fsnotify/fsnotify/internal/debug_dragonfly.go
@@ -7,27 +7,9 @@ var names = []struct {
m uint32
}{
{"NOTE_ATTRIB", unix.NOTE_ATTRIB},
- {"NOTE_CHILD", unix.NOTE_CHILD},
{"NOTE_DELETE", unix.NOTE_DELETE},
- {"NOTE_EXEC", unix.NOTE_EXEC},
- {"NOTE_EXIT", unix.NOTE_EXIT},
{"NOTE_EXTEND", unix.NOTE_EXTEND},
- {"NOTE_FFAND", unix.NOTE_FFAND},
- {"NOTE_FFCOPY", unix.NOTE_FFCOPY},
- {"NOTE_FFCTRLMASK", unix.NOTE_FFCTRLMASK},
- {"NOTE_FFLAGSMASK", unix.NOTE_FFLAGSMASK},
- {"NOTE_FFNOP", unix.NOTE_FFNOP},
- {"NOTE_FFOR", unix.NOTE_FFOR},
- {"NOTE_FORK", unix.NOTE_FORK},
{"NOTE_LINK", unix.NOTE_LINK},
- {"NOTE_LOWAT", unix.NOTE_LOWAT},
- {"NOTE_OOB", unix.NOTE_OOB},
- {"NOTE_PCTRLMASK", unix.NOTE_PCTRLMASK},
- {"NOTE_PDATAMASK", unix.NOTE_PDATAMASK},
{"NOTE_RENAME", unix.NOTE_RENAME},
- {"NOTE_REVOKE", unix.NOTE_REVOKE},
- {"NOTE_TRACK", unix.NOTE_TRACK},
- {"NOTE_TRACKERR", unix.NOTE_TRACKERR},
- {"NOTE_TRIGGER", unix.NOTE_TRIGGER},
{"NOTE_WRITE", unix.NOTE_WRITE},
}
diff --git a/vendor/github.com/fsnotify/fsnotify/internal/debug_freebsd.go b/vendor/github.com/fsnotify/fsnotify/internal/debug_freebsd.go
index f69fdb930f..b9e45f5551 100644
--- a/vendor/github.com/fsnotify/fsnotify/internal/debug_freebsd.go
+++ b/vendor/github.com/fsnotify/fsnotify/internal/debug_freebsd.go
@@ -6,37 +6,15 @@ var names = []struct {
n string
m uint32
}{
- {"NOTE_ABSTIME", unix.NOTE_ABSTIME},
- {"NOTE_ATTRIB", unix.NOTE_ATTRIB},
- {"NOTE_CHILD", unix.NOTE_CHILD},
- {"NOTE_CLOSE", unix.NOTE_CLOSE},
- {"NOTE_CLOSE_WRITE", unix.NOTE_CLOSE_WRITE},
{"NOTE_DELETE", unix.NOTE_DELETE},
- {"NOTE_EXEC", unix.NOTE_EXEC},
- {"NOTE_EXIT", unix.NOTE_EXIT},
+ {"NOTE_WRITE", unix.NOTE_WRITE},
{"NOTE_EXTEND", unix.NOTE_EXTEND},
- {"NOTE_FFAND", unix.NOTE_FFAND},
- {"NOTE_FFCOPY", unix.NOTE_FFCOPY},
- {"NOTE_FFCTRLMASK", unix.NOTE_FFCTRLMASK},
- {"NOTE_FFLAGSMASK", unix.NOTE_FFLAGSMASK},
- {"NOTE_FFNOP", unix.NOTE_FFNOP},
- {"NOTE_FFOR", unix.NOTE_FFOR},
- {"NOTE_FILE_POLL", unix.NOTE_FILE_POLL},
- {"NOTE_FORK", unix.NOTE_FORK},
+ {"NOTE_ATTRIB", unix.NOTE_ATTRIB},
{"NOTE_LINK", unix.NOTE_LINK},
- {"NOTE_LOWAT", unix.NOTE_LOWAT},
- {"NOTE_MSECONDS", unix.NOTE_MSECONDS},
- {"NOTE_NSECONDS", unix.NOTE_NSECONDS},
- {"NOTE_OPEN", unix.NOTE_OPEN},
- {"NOTE_PCTRLMASK", unix.NOTE_PCTRLMASK},
- {"NOTE_PDATAMASK", unix.NOTE_PDATAMASK},
- {"NOTE_READ", unix.NOTE_READ},
{"NOTE_RENAME", unix.NOTE_RENAME},
{"NOTE_REVOKE", unix.NOTE_REVOKE},
- {"NOTE_SECONDS", unix.NOTE_SECONDS},
- {"NOTE_TRACK", unix.NOTE_TRACK},
- {"NOTE_TRACKERR", unix.NOTE_TRACKERR},
- {"NOTE_TRIGGER", unix.NOTE_TRIGGER},
- {"NOTE_USECONDS", unix.NOTE_USECONDS},
- {"NOTE_WRITE", unix.NOTE_WRITE},
+ {"NOTE_OPEN", unix.NOTE_OPEN},
+ {"NOTE_CLOSE", unix.NOTE_CLOSE},
+ {"NOTE_CLOSE_WRITE", unix.NOTE_CLOSE_WRITE},
+ {"NOTE_READ", unix.NOTE_READ},
}
diff --git a/vendor/github.com/fsnotify/fsnotify/internal/debug_kqueue.go b/vendor/github.com/fsnotify/fsnotify/internal/debug_kqueue.go
index 607e683bd7..5d8116436d 100644
--- a/vendor/github.com/fsnotify/fsnotify/internal/debug_kqueue.go
+++ b/vendor/github.com/fsnotify/fsnotify/internal/debug_kqueue.go
@@ -27,6 +27,6 @@ func Debug(name string, kevent *unix.Kevent_t) {
if unknown > 0 {
l = append(l, fmt.Sprintf("0x%x", unknown))
}
- fmt.Fprintf(os.Stderr, "FSNOTIFY_DEBUG: %s %10d:%-60s → %q\n",
+ fmt.Fprintf(os.Stderr, "FSNOTIFY_DEBUG: %s %10d:%-20s → %q\n",
time.Now().Format("15:04:05.000000000"), mask, strings.Join(l, " | "), name)
}
diff --git a/vendor/github.com/fsnotify/fsnotify/internal/debug_netbsd.go b/vendor/github.com/fsnotify/fsnotify/internal/debug_netbsd.go
index e5b3b6f694..7600180742 100644
--- a/vendor/github.com/fsnotify/fsnotify/internal/debug_netbsd.go
+++ b/vendor/github.com/fsnotify/fsnotify/internal/debug_netbsd.go
@@ -7,19 +7,9 @@ var names = []struct {
m uint32
}{
{"NOTE_ATTRIB", unix.NOTE_ATTRIB},
- {"NOTE_CHILD", unix.NOTE_CHILD},
{"NOTE_DELETE", unix.NOTE_DELETE},
- {"NOTE_EXEC", unix.NOTE_EXEC},
- {"NOTE_EXIT", unix.NOTE_EXIT},
{"NOTE_EXTEND", unix.NOTE_EXTEND},
- {"NOTE_FORK", unix.NOTE_FORK},
{"NOTE_LINK", unix.NOTE_LINK},
- {"NOTE_LOWAT", unix.NOTE_LOWAT},
- {"NOTE_PCTRLMASK", unix.NOTE_PCTRLMASK},
- {"NOTE_PDATAMASK", unix.NOTE_PDATAMASK},
{"NOTE_RENAME", unix.NOTE_RENAME},
- {"NOTE_REVOKE", unix.NOTE_REVOKE},
- {"NOTE_TRACK", unix.NOTE_TRACK},
- {"NOTE_TRACKERR", unix.NOTE_TRACKERR},
{"NOTE_WRITE", unix.NOTE_WRITE},
}
diff --git a/vendor/github.com/fsnotify/fsnotify/internal/debug_openbsd.go b/vendor/github.com/fsnotify/fsnotify/internal/debug_openbsd.go
index 1dd455bc5a..871766d699 100644
--- a/vendor/github.com/fsnotify/fsnotify/internal/debug_openbsd.go
+++ b/vendor/github.com/fsnotify/fsnotify/internal/debug_openbsd.go
@@ -7,22 +7,10 @@ var names = []struct {
m uint32
}{
{"NOTE_ATTRIB", unix.NOTE_ATTRIB},
- // {"NOTE_CHANGE", unix.NOTE_CHANGE}, // Not on 386?
- {"NOTE_CHILD", unix.NOTE_CHILD},
{"NOTE_DELETE", unix.NOTE_DELETE},
- {"NOTE_EOF", unix.NOTE_EOF},
- {"NOTE_EXEC", unix.NOTE_EXEC},
- {"NOTE_EXIT", unix.NOTE_EXIT},
{"NOTE_EXTEND", unix.NOTE_EXTEND},
- {"NOTE_FORK", unix.NOTE_FORK},
{"NOTE_LINK", unix.NOTE_LINK},
- {"NOTE_LOWAT", unix.NOTE_LOWAT},
- {"NOTE_PCTRLMASK", unix.NOTE_PCTRLMASK},
- {"NOTE_PDATAMASK", unix.NOTE_PDATAMASK},
{"NOTE_RENAME", unix.NOTE_RENAME},
- {"NOTE_REVOKE", unix.NOTE_REVOKE},
- {"NOTE_TRACK", unix.NOTE_TRACK},
- {"NOTE_TRACKERR", unix.NOTE_TRACKERR},
{"NOTE_TRUNCATE", unix.NOTE_TRUNCATE},
{"NOTE_WRITE", unix.NOTE_WRITE},
}
diff --git a/vendor/github.com/fsnotify/fsnotify/internal/freebsd.go b/vendor/github.com/fsnotify/fsnotify/internal/freebsd.go
index 5ac8b50797..758a249052 100644
--- a/vendor/github.com/fsnotify/fsnotify/internal/freebsd.go
+++ b/vendor/github.com/fsnotify/fsnotify/internal/freebsd.go
@@ -15,17 +15,6 @@ var (
var maxfiles uint64
-func SetRlimit() {
- // Go 1.19 will do this automatically: https://go-review.googlesource.com/c/go/+/393354/
- var l syscall.Rlimit
- err := syscall.Getrlimit(syscall.RLIMIT_NOFILE, &l)
- if err == nil && l.Cur != l.Max {
- l.Cur = l.Max
- syscall.Setrlimit(syscall.RLIMIT_NOFILE, &l)
- }
- maxfiles = uint64(l.Cur)
-}
-
func Maxfiles() uint64 { return maxfiles }
func Mkfifo(path string, mode uint32) error { return unix.Mkfifo(path, mode) }
func Mknod(path string, mode uint32, dev int) error { return unix.Mknod(path, mode, uint64(dev)) }
diff --git a/vendor/github.com/fsnotify/fsnotify/internal/unix.go b/vendor/github.com/fsnotify/fsnotify/internal/unix.go
index b251fb8038..9c66f5d30d 100644
--- a/vendor/github.com/fsnotify/fsnotify/internal/unix.go
+++ b/vendor/github.com/fsnotify/fsnotify/internal/unix.go
@@ -15,17 +15,6 @@ var (
var maxfiles uint64
-func SetRlimit() {
- // Go 1.19 will do this automatically: https://go-review.googlesource.com/c/go/+/393354/
- var l syscall.Rlimit
- err := syscall.Getrlimit(syscall.RLIMIT_NOFILE, &l)
- if err == nil && l.Cur != l.Max {
- l.Cur = l.Max
- syscall.Setrlimit(syscall.RLIMIT_NOFILE, &l)
- }
- maxfiles = uint64(l.Cur)
-}
-
func Maxfiles() uint64 { return maxfiles }
func Mkfifo(path string, mode uint32) error { return unix.Mkfifo(path, mode) }
func Mknod(path string, mode uint32, dev int) error { return unix.Mknod(path, mode, dev) }
diff --git a/vendor/github.com/fsnotify/fsnotify/internal/unix2.go b/vendor/github.com/fsnotify/fsnotify/internal/unix2.go
index 37dfeddc28..b2d89592f7 100644
--- a/vendor/github.com/fsnotify/fsnotify/internal/unix2.go
+++ b/vendor/github.com/fsnotify/fsnotify/internal/unix2.go
@@ -2,6 +2,24 @@
package internal
+import "syscall"
+
func HasPrivilegesForSymlink() bool {
return true
}
+
+// IgnoringEINTR makes a function call and repeats it if it returns an
+// EINTR error. This appears to be required even though we install all
+// signal handlers with SA_RESTART: see #22838, #38033, #38836, #40846.
+// Also #20400 and #36644 are issues in which a signal handler is
+// installed without setting SA_RESTART. None of these are the common case,
+// but there are enough of them that it seems that we can't avoid
+// an EINTR loop.
+func IgnoringEINTR[T any](fn func() (T, error)) (T, error) {
+ for {
+ v, err := fn()
+ if err != syscall.EINTR {
+ return v, err
+ }
+ }
+}
diff --git a/vendor/github.com/fsnotify/fsnotify/internal/windows.go b/vendor/github.com/fsnotify/fsnotify/internal/windows.go
index 896bc2e5a2..e24d569264 100644
--- a/vendor/github.com/fsnotify/fsnotify/internal/windows.go
+++ b/vendor/github.com/fsnotify/fsnotify/internal/windows.go
@@ -14,7 +14,6 @@ var (
ErrUnixEACCES = errors.New("dummy")
)
-func SetRlimit() {}
func Maxfiles() uint64 { return 1<<64 - 1 }
func Mkfifo(path string, mode uint32) error { return errors.New("no FIFOs on Windows") }
func Mknod(path string, mode uint32, dev int) error { return errors.New("no device nodes on Windows") }
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 4e684c7de6..69edf5eff8 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
@@ -71,6 +71,7 @@ type ServeMux struct {
streamErrorHandler StreamErrorHandlerFunc
routingErrorHandler RoutingErrorHandlerFunc
disablePathLengthFallback bool
+ disableHTTPMethodOverride bool
unescapingMode UnescapingMode
writeContentLength bool
disableChunkedEncoding bool
@@ -271,6 +272,19 @@ func WithDisablePathLengthFallback() ServeMuxOption {
}
}
+// WithDisableHTTPMethodOverride returns a ServeMuxOption that disables the
+// X-HTTP-Method-Override header handling.
+//
+// When this option is used, the mux will no longer allow POST requests with
+// the X-HTTP-Method-Override header to override the HTTP method. The path
+// length fallback (POST with application/x-www-form-urlencoded falling back
+// to a matching GET handler) is not affected by this option.
+func WithDisableHTTPMethodOverride() ServeMuxOption {
+ return func(serveMux *ServeMux) {
+ serveMux.disableHTTPMethodOverride = true
+ }
+}
+
// WithWriteContentLength returns a ServeMuxOption to enable writing content length on non-streaming responses
func WithWriteContentLength() ServeMuxOption {
return func(serveMux *ServeMux) {
@@ -405,7 +419,7 @@ func (s *ServeMux) ServeHTTP(w http.ResponseWriter, r *http.Request) {
path = r.URL.RawPath
}
- if override := r.Header.Get("X-HTTP-Method-Override"); override != "" && s.isPathLengthFallback(r) {
+ if override := r.Header.Get("X-HTTP-Method-Override"); override != "" && !s.disableHTTPMethodOverride && s.isPathLengthFallback(r) {
if err := r.ParseForm(); err != nil {
_, outboundMarshaler := MarshalerForRequest(s, r)
sterr := status.Error(codes.InvalidArgument, err.Error())
@@ -467,6 +481,7 @@ func (s *ServeMux) ServeHTTP(w http.ResponseWriter, r *http.Request) {
HTTPStatus: http.StatusBadRequest,
Err: mse,
})
+ return
}
continue
}
@@ -509,6 +524,7 @@ func (s *ServeMux) ServeHTTP(w http.ResponseWriter, r *http.Request) {
HTTPStatus: http.StatusBadRequest,
Err: mse,
})
+ return
}
continue
}
diff --git a/vendor/github.com/netobserv/flowlogs-pipeline/pkg/api/encode_s3.go b/vendor/github.com/netobserv/flowlogs-pipeline/pkg/api/encode_s3.go
index 71cc6d6fb8..36ec4ab16b 100644
--- a/vendor/github.com/netobserv/flowlogs-pipeline/pkg/api/encode_s3.go
+++ b/vendor/github.com/netobserv/flowlogs-pipeline/pkg/api/encode_s3.go
@@ -21,7 +21,7 @@ type EncodeS3 struct {
Account string `yaml:"account" json:"account" doc:"tenant id for this flow collector"`
Endpoint string `yaml:"endpoint" json:"endpoint" doc:"address of s3 server"`
AccessKeyID string `yaml:"accessKeyId" json:"accessKeyId" doc:"username to connect to server"`
- SecretAccessKey string `yaml:"secretAccessKey" json:"secretAccessKey" doc:"password to connect to server"`
+ SecretAccessKey RedactedText `yaml:"secretAccessKey" json:"secretAccessKey" doc:"password to connect to server"`
Bucket string `yaml:"bucket" json:"bucket" doc:"bucket into which to store objects"`
WriteTimeout Duration `yaml:"writeTimeout,omitempty" json:"writeTimeout,omitempty" doc:"timeout (in seconds) for write operation"`
BatchSize int `yaml:"batchSize,omitempty" json:"batchSize,omitempty" doc:"limit on how many flows will be buffered before being sent to an object"`
diff --git a/vendor/github.com/netobserv/flowlogs-pipeline/pkg/api/redacted.go b/vendor/github.com/netobserv/flowlogs-pipeline/pkg/api/redacted.go
new file mode 100644
index 0000000000..45f5808307
--- /dev/null
+++ b/vendor/github.com/netobserv/flowlogs-pipeline/pkg/api/redacted.go
@@ -0,0 +1,16 @@
+package api
+
+import (
+ "fmt"
+ "log/slog"
+)
+
+type RedactedText string
+
+func (RedactedText) Format(f fmt.State, _ rune) {
+ _, _ = f.Write([]byte("[REDACTED]"))
+}
+
+func (RedactedText) LogValue() slog.Value {
+ return slog.StringValue("[REDACTED]")
+}
diff --git a/vendor/github.com/netobserv/flowlogs-pipeline/pkg/config/config.go b/vendor/github.com/netobserv/flowlogs-pipeline/pkg/config/config.go
index 444f278f57..a9a6aab125 100644
--- a/vendor/github.com/netobserv/flowlogs-pipeline/pkg/config/config.go
+++ b/vendor/github.com/netobserv/flowlogs-pipeline/pkg/config/config.go
@@ -31,8 +31,8 @@ type Options struct {
Parameters string
DynamicParameters string
MetricsSettings string
- Health Health
- Profile Profile
+ HealthAddr string
+ PprofAddr string
}
type Root struct {
@@ -55,15 +55,6 @@ type HotReloadStruct struct {
Parameters []StageParam `yaml:"parameters,omitempty" json:"parameters,omitempty"`
}
-type Health struct {
- Address string
- Port int
-}
-
-type Profile struct {
- Port int
-}
-
// MetricsSettings is similar to api.PromEncode, but is global to the application, ie. it also works with operational metrics.
// Also, currently FLP doesn't support defining more than one PromEncode stage. If this feature is added later, these global settings
// will help configuring common setting for all PromEncode stages - PromEncode settings would then act as overrides.
diff --git a/vendor/github.com/netobserv/netobserv-ebpf-agent/pkg/config/config.go b/vendor/github.com/netobserv/netobserv-ebpf-agent/pkg/config/config.go
index 7920d1c7bb..e86908af7f 100644
--- a/vendor/github.com/netobserv/netobserv-ebpf-agent/pkg/config/config.go
+++ b/vendor/github.com/netobserv/netobserv-ebpf-agent/pkg/config/config.go
@@ -218,8 +218,8 @@ type Agent struct {
KafkaSASLClientIDPath string `env:"KAFKA_SASL_CLIENT_ID_PATH"`
// KafkaSASLClientSecretPath is the path to the client secret (password) for SASL auth
KafkaSASLClientSecretPath string `env:"KAFKA_SASL_CLIENT_SECRET_PATH"`
- // ProfilePort sets the listening port for Go's Pprof tool. If it is not set, profile is disabled
- ProfilePort int `env:"PROFILE_PORT"`
+ // PPROF_ADDR sets the listening address (such as 127.0.0.1:6060) for Go's Pprof tool. Do not expose publicly. If it is not set, profiling is disabled.
+ PprofAddr string `env:"PPROF_ADDR"`
// Flowlogs-pipeline configuration as YAML or JSON, used when export is "direct-flp". Cf https://github.com/netobserv/flowlogs-pipeline
// The "ingest" stage must be omitted from this configuration, since it is handled internally by the agent. The first stage should follow "preset-ingester".
// E.g: {"pipeline":[{"name": "writer","follows": "preset-ingester"}],"parameters":[{"name": "writer","write": {"type": "stdout"}}]}.
@@ -289,6 +289,12 @@ type Agent struct {
// EnableTLSTracking allow tracking TLS usage per flow (version, cipher suite, ...)
EnableTLSTracking bool `env:"ENABLE_TLS_TRACKING" envDefault:"false"`
+ // QUICTrackingMode configures QUIC parsing in eBPF:
+ // - 0: disabled
+ // - 1: enabled (UDP/443 only)
+ // - 2: enabled (any UDP port)
+ QUICTrackingMode int `env:"QUIC_TRACKING_MODE" envDefault:"0"`
+
/* Deprecated configs are listed below this line
* See manageDeprecatedConfigs function for details
*/
diff --git a/vendor/github.com/netobserv/netobserv-ebpf-agent/pkg/maps/maps.go b/vendor/github.com/netobserv/netobserv-ebpf-agent/pkg/maps/maps.go
index a2dbb3bfa3..89dd834bc2 100644
--- a/vendor/github.com/netobserv/netobserv-ebpf-agent/pkg/maps/maps.go
+++ b/vendor/github.com/netobserv/netobserv-ebpf-agent/pkg/maps/maps.go
@@ -18,4 +18,5 @@ var Maps = []string{
"ipsec_egress_map",
"ssl_data_event_map",
"dns_name_map",
+ "quic_flows",
}
diff --git a/vendor/go.opentelemetry.io/otel/.golangci.yml b/vendor/go.opentelemetry.io/otel/.golangci.yml
index db1f55101c..645c7e6af1 100644
--- a/vendor/go.opentelemetry.io/otel/.golangci.yml
+++ b/vendor/go.opentelemetry.io/otel/.golangci.yml
@@ -96,9 +96,9 @@ linters:
- "!**/exporters/zipkin/**"
deny:
- pkg: go.opentelemetry.io/otel/semconv
- desc: "Use go.opentelemetry.io/otel/semconv/v1.40.0 instead. If a newer semconv version has been released, update the depguard rule."
+ desc: "Use go.opentelemetry.io/otel/semconv/v1.41.0 instead. If a newer semconv version has been released, update the depguard rule."
allow:
- - go.opentelemetry.io/otel/semconv/v1.40.0
+ - go.opentelemetry.io/otel/semconv/v1.41.0
gocritic:
disabled-checks:
- appendAssign
@@ -134,13 +134,16 @@ linters:
strconcat: true
revive:
confidence: 0.01
+ enable-all-rules: false
+ enable-default-rules: true
+ max-open-files: 2048
rules:
- name: blank-imports
- name: bool-literal-in-expr
- name: constant-logical-expr
- name: context-as-argument
arguments:
- - allowTypesBefore: '*testing.T'
+ - allow-types-before: '*testing.T'
disabled: true
- name: context-keys-type
- name: deep-exit
@@ -152,7 +155,7 @@ linters:
- name: duplicated-imports
- name: early-return
arguments:
- - preserveScope
+ - preserve-scope
- name: empty-block
- name: empty-lines
- name: error-naming
@@ -161,7 +164,7 @@ linters:
- name: errorf
- name: exported
arguments:
- - sayRepetitiveInsteadOfStutters
+ - say-repetitive-instead-of-stutters
- name: flag-parameter
- name: identical-branches
- name: if-return
@@ -169,11 +172,12 @@ linters:
- name: increment-decrement
- name: indent-error-flow
arguments:
- - preserveScope
+ - preserve-scope
- name: package-comments
- name: range
- name: range-val-in-closure
- name: range-val-address
+ - name: receiver-naming
- name: redefines-builtin-id
- name: string-format
arguments:
@@ -183,7 +187,7 @@ linters:
- name: struct-tag
- name: superfluous-else
arguments:
- - preserveScope
+ - preserve-scope
- name: time-equal
- name: unconditional-recursion
- name: unexported-return
diff --git a/vendor/go.opentelemetry.io/otel/AGENTS.md b/vendor/go.opentelemetry.io/otel/AGENTS.md
new file mode 100644
index 0000000000..26c0fc4ddb
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/AGENTS.md
@@ -0,0 +1,109 @@
+# Agent Guide for opentelemetry-go
+
+This file contains active, task-oriented instructions for autonomous and semi-autonomous coding agents working in this repository.
+
+Before starting any task, read `.github/copilot-instructions.md`, `CONTRIBUTING.md`, and this file.
+Treat `.github/copilot-instructions.md` as global passive guidance for every task, including docs-only and review-only work.
+
+## Core expectations
+
+- Preserve OpenTelemetry specification compliance, API stability, and idiomatic Go.
+- Prefer minimal, surgical changes over broad refactors or speculative cleanup.
+- Read the package you are editing and match its existing naming, option types, error handling, comments, tests, and concurrency patterns.
+- Keep public APIs backward compatible unless the task explicitly requires a breaking change.
+- Keep telemetry resilient and loosely coupled. Do not introduce behavior that can unexpectedly interfere with host applications.
+- Inspect boundaries carefully: input validation, resource limits, cancellation, shutdown, error propagation, concurrency, and memory growth.
+- Prefer fail-safe behavior and explicit invariants over implicit assumptions.
+- Keep dependencies minimal and justified.
+- Preserve host-application safety: telemetry should not panic, block indefinitely, or amplify attacker-controlled input.
+- Be conservative on hot paths. Avoid unnecessary allocations, reflection, interface churn, blocking, global state, and high-cardinality telemetry.
+- Write comments only for intent, invariants, and non-obvious constraints. Do not add comments that restate the code.
+
+## Default workflow
+
+For new features and behavior changes, use this order unless the task explicitly says otherwise:
+
+1. Read the relevant package, its tests, and any package docs or `README.md`.
+2. Add or update a failing unit test that captures the required behavior or regression.
+3. Implement the smallest change that makes the test pass.
+4. Refactor only after the behavior is locked in, and only if the refactor keeps the diff focused.
+5. If the changed code is on a hot path or performance-sensitive, inspect existing benchmarks and run them. Add a benchmark if coverage is missing.
+6. Update documentation artifacts as needed while the context is fresh. Follow the documentation and changelog conventions below for the specific updates required.
+7. Run `make precommit` each time before considering the work complete.
+
+For docs-only, test-only, or review-only tasks, still start with the required repository guidance above, then skip the workflow steps that do not apply while keeping the same discipline around scope, verification, and repository conventions.
+
+## Verification
+
+- Use `make` as the canonical repository verification command. The default target is `precommit`.
+- `make precommit` is the expected final verification step for linting, generation, README checks, module checks, and tests.
+- During iteration, targeted commands are fine for fast feedback, but do not stop there if the task changes code.
+- If you touch performance-sensitive code, run focused benchmarks and compare the results using `benchstat` in addition to `make`.
+
+## Documentation and changelog
+
+- Non-internal, non-test packages should have Go doc comments, usually in `doc.go`.
+- Non-internal, non-test, non-documentation packages should also have a `README.md` with at least a title and a `pkg.go.dev` badge.
+- Prefer examples over long code snippets in GoDoc when practical.
+- Keep docs aligned with actual behavior. Do not leave stale comments, stale examples, or stale package documentation behind.
+- For user-visible changes, update `CHANGELOG.md` under the appropriate `Added`, `Changed`, `Deprecated`, `Fixed`, or `Removed` section within `## [Unreleased]`.
+
+## Repository habits
+
+- Prefer focused diffs. Avoid drive-by cleanup.
+- Follow existing option patterns and exported API conventions instead of inventing new abstractions.
+- Generated files are checked in. If your change affects generation, keep generated output up to date.
+- Prefer fast local search tools such as `rg` when exploring the repository.
+- When changing behavior, make the invariants explicit in tests.
+
+## Personas
+
+### Feature Agent
+
+Use this persona for new behavior, new API surface, or spec-driven feature work.
+
+- Start with a failing unit test.
+- Confirm the expected behavior against the spec, existing package behavior, and public API compatibility.
+- Implement the smallest viable change.
+- Update GoDoc, examples, `README.md`, and `CHANGELOG.md` when the change is user-visible.
+- If the feature touches a hot path, check benchmarks and add one if the coverage is missing.
+
+### Refactoring Agent
+
+Use this persona when improving structure without intentionally changing behavior.
+
+- Treat behavior preservation as the default contract.
+- Add or tighten tests before moving code if current behavior is not already pinned down.
+- Avoid broad rewrites, clever abstractions, or package-wide cleanup unless explicitly requested.
+- If a refactor touches a hot path, benchmark before and after.
+- Keep API shape, semantics, concurrency guarantees, and failure modes unchanged unless the task says otherwise.
+
+### Test Agent
+
+Use this persona when adding missing coverage, reproducing bugs, or hardening regressions.
+
+- Reproduce the bug or missing behavior with the smallest failing test you can.
+- Prefer testing public behavior and externally visible invariants.
+- Add targeted regression tests before changing production code.
+- Only change production code when it is required to make the tested behavior correct or testable.
+- Keep tests deterministic, readable, and aligned with package patterns.
+
+### Performance Agent
+
+Use this persona for hot-path work, allocation reduction, or throughput and latency improvements.
+
+- Benchmark first to establish a baseline.
+- Prefer changes that reduce allocations, copying, interface churn, and unnecessary synchronization.
+- Do not trade away correctness, spec compliance, or API stability for micro-optimizations.
+- Add or update benchmarks when performance-sensitive coverage is missing.
+- If you materially change a hot path, capture before-and-after results, preferably with `benchstat`.
+
+### Review Agent
+
+Use this persona when asked to review code, patches, or pull requests.
+
+- Lead with findings, not summaries.
+- Order findings by severity and include precise file and line references when available.
+- Focus on correctness, spec compliance, API compatibility, concurrency safety, resilience, performance regressions, missing tests, missing benchmarks, documentation gaps, and changelog gaps.
+- Call out when a diff is broader than necessary.
+- If you find no issues, say that explicitly and note any residual risks or verification gaps.
diff --git a/vendor/go.opentelemetry.io/otel/CHANGELOG.md b/vendor/go.opentelemetry.io/otel/CHANGELOG.md
index 20edda4418..6a90451f52 100644
--- a/vendor/go.opentelemetry.io/otel/CHANGELOG.md
+++ b/vendor/go.opentelemetry.io/otel/CHANGELOG.md
@@ -11,6 +11,100 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm
+## [1.44.0/0.66.0/0.20.0/0.0.17] 2026-05-27
+
+### Added
+
+- Add `ByteSlice` and `ByteSliceValue` functions for new `BYTESLICE` attribute type in `go.opentelemetry.io/otel/attribute`. (#7948)
+- Apply attribute value limit to the `KindBytes` attribute type in `go.opentelemetry.io/otel/sdk/log`. (#7990)
+- Apply attribute value limit to the `BYTESLICE` attribute type in `go.opentelemetry.io/otel/sdk/trace`. (#7990)
+- Support `BYTESLICE` attributes in `go.opentelemetry.io/otel/trace`. (#8153)
+- Support `BYTESLICE` attributes in `go.opentelemetry.io/otel/exporters/otlp/otlptrace`. (#8153)
+- Support `BYTESLICE` attributes in `go.opentelemetry.io/otel/exporters/otlp/otlplog`. (#8153)
+- Support `BYTESLICE` attributes in `go.opentelemetry.io/otel/exporters/otlp/otlpmetric`. (#8153)
+- Support `BYTESLICE` attributes in `go.opentelemetry.io/otel/exporters/zipkin`. (#8153)
+- Add `String` method for `Value` type in `go.opentelemetry.io/otel/attribute`. (#8142)
+- Add `Slice` and `SliceValue` functions for new `SLICE` attribute type in `go.opentelemetry.io/otel/attribute`. (#8166)
+- Support `SLICE` attributes in `go.opentelemetry.io/otel/exporters/otlp/otlptrace`. (#8216)
+- Support `SLICE` attributes in `go.opentelemetry.io/otel/exporters/otlp/otlplog`. (#8216)
+- Support `SLICE` attributes in `go.opentelemetry.io/otel/exporters/otlp/otlpmetric`. (#8216)
+- Support `SLICE` attributes in `go.opentelemetry.io/otel/exporters/zipkin`. (#8216)
+- Apply `AttributeValueLengthLimit` to `attribute.SLICE` type attribute values in `go.opentelemetry.io/otel/sdk/trace`, recursively truncating contained string values. (#8217)
+- Add `Error` field on `Record` type in `go.opentelemetry.io/otel/log/logtest`. (#8148)
+- Add `WithMaxRequestSize` option in `go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc`. (#8157)
+- Add `WithMaxRequestSize` option in `go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp`. (#8157)
+- Add `WithMaxRequestSize` option in `go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetricgrpc`. (#8157)
+- Add `WithMaxRequestSize` option in `go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp`. (#8157)
+- Add `WithMaxRequestSize` option in `go.opentelemetry.io/otel/exporters/otlp/otlplog/otlploggrpc`. (#8157)
+- Add `WithMaxRequestSize` option in `go.opentelemetry.io/otel/exporters/otlp/otlplog/otlploghttp`. (#8157)
+- Add `Settable` to `go.opentelemetry.io/otel/metric/x` to allow reusing attribute options. (#8178)
+- Add experimental support for splitting metric data across multiple batches in `go.opentelemetry.io/otel/sdk/metric`.
+ Set `OTEL_GO_X_METRIC_EXPORT_BATCH_SIZE=` to enable for all periodic readers.
+ See `go.opentelemetry.io/otel/sdk/metric/internal/x` for feature documentation. (#8071)
+- Add experimental self-observability metrics in `go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetricgrpc`.
+ Enable with `OTEL_GO_X_SELF_OBSERVABILITY=true` environment variable.
+ See `go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetricgrpc/internal/x` for feature documentation. (#8192)
+- Add experimental self-observability metrics in `go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp`.
+ Enable with `OTEL_GO_X_SELF_OBSERVABILITY=true` environment variable.
+ See `go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp/internal/x` for feature documentation. (#8194)
+- Add experimental self-observability metrics in `go.opentelemetry.io/otel/exporters/stdout/stdoutlog`.
+ Enable with `OTEL_GO_X_SELF_OBSERVABILITY=true` environment variable.
+ See `go.opentelemetry.io/otel/stdout/stdoutlog/internal/x` for feature documentation. (#8263)
+- Add `WithDefaultAttributes` to `go.opentelemetry.io/otel/metric/x` to support setting default attributes on instruments. (#8135)
+- Add `go.opentelemetry.io/otel/semconv/v1.41.0` package.
+ The package contains semantic conventions from the `v1.41.0` version of the OpenTelemetry Semantic Conventions.
+ See the [migration documentation](./semconv/v1.41.0/MIGRATION.md) for information on how to upgrade from `go.opentelemetry.io/otel/semconv/v1.40.0`. (#8324)
+- Add Observable variants of instruments to `go.opentelemetry.io/otel/semconv/v1.41.0` package. (#8350)
+- Generate explicit histogram bucket boundaries from weaver configuration for HTTP and RPC duration instruments in `go.opentelemetry.io/otel/semconv/v1.41.0`. (#8002)
+
+### Changed
+
+- ⚠️ **Breaking Change:** `go.opentelemetry.io/otel/sdk/metric` now applies a default cardinality limit of 2000 to comply with the Metrics SDK specification recommendation.
+ New attribute sets are dropped when the cardinality limit is reached. The measurement of these sets are aggregated into a special attribute set containing `attribute.Bool("otel.metric.overflow", true)`.
+ This can break users who relied on the previous unlimited default.
+ Set `WithCardinalityLimit(0)` or the deprecated `OTEL_GO_X_CARDINALITY_LIMIT=0` environment variable to preserve unlimited cardinality.
+ Note that support for `OTEL_GO_X_CARDINALITY_LIMIT` may be removed in a future release. (#8247)
+- `ErrorType` in `go.opentelemetry.io/otel/semconv` now unwraps errors created with `fmt.Errorf` when deriving the `error.type` attribute. (#8133)
+- `go.opentelemetry.io/otel/sdk/log` now unwraps error chains created with `fmt.Errorf` when deriving the `error.type` attribute from errors on log records. (#8133)
+- `Set.MarshalLog` method in `go.opentelemetry.io/otel/attribute` now uses `Value.String` formatting following the [OpenTelemetry AnyValue representation for non-OTLP protocols](https://opentelemetry.io/docs/specs/otel/common/#anyvalue). (#8169)
+- Optimize `go.opentelemetry.io/otel/sdk/metric` to return a drop reservoir and short-circuit `Offer` calls to the exemplar reservoir when `exemplar.AlwaysOffFilter` is configured. (#8211) (#8267)
+- Optimize `go.opentelemetry.io/otel/sdk/metric` to return a drop reservoir for asynchronous instruments when `exemplar.TraceBasedFilter` is configured. (#8286)
+
+### Deprecated
+
+- Deprecate `Value.Emit` method in `go.opentelemetry.io/otel/attribute`.
+ Use `Value.String` instead. (#8176)
+
+### Fixed
+
+- Limit OTLP request size to 64 MiB by default in `go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc`.
+ The limit applies before compression, oversized requests are treated as non-retryable errors, and the limit can be configured with the new `WithMaxRequestSize` option. (#8157, #8365)
+- Limit OTLP request size to 64 MiB by default in `go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp`.
+ The limit applies before compression, oversized requests are treated as non-retryable errors, and the limit can be configured with the new `WithMaxRequestSize` option. (#8157, #8365)
+- Limit OTLP request size to 64 MiB by default in `go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetricgrpc`.
+ The limit applies before compression, oversized requests are treated as non-retryable errors, and the limit can be configured with the new `WithMaxRequestSize` option. (#8157, #8365)
+- Limit OTLP request size to 64 MiB by default in `go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp`.
+ The limit applies before compression, oversized requests are treated as non-retryable errors, and the limit can be configured with the new `WithMaxRequestSize` option. (#8157, #8365)
+- Limit OTLP request size to 64 MiB by default in `go.opentelemetry.io/otel/exporters/otlp/otlplog/otlploggrpc`.
+ The limit applies before compression, oversized requests are treated as non-retryable errors, and the limit can be configured with the new `WithMaxRequestSize` option. (#8157, #8365)
+- Limit OTLP request size to 64 MiB by default in `go.opentelemetry.io/otel/exporters/otlp/otlplog/otlploghttp`.
+ The limit applies before compression, oversized requests are treated as non-retryable errors, and the limit can be configured with the new `WithMaxRequestSize` option. (#8157, #8365)
+- Fix gzipped request body replay on redirect in `go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp`. (#8135)
+- Fix gzipped request body replay on redirect in `go.opentelemetry.io/otel/exporters/otlp/otlplog/otlploghttp`. (#8152)
+- `go.opentelemetry.io/otel/exporters/prometheus` now uses `Value.String` formatting for label values following the [OpenTelemetry AnyValue representation for non-OTLP protocols](https://opentelemetry.io/docs/specs/otel/common/#anyvalue). (#8170)
+- Propagate errors from the exporter when calling `Shutdown` on `BatchSpanProcessor` in `go.opentelemetry.io/otel/sdk/trace`. (#8197)
+- Fix stale status code reporting on self-observability metrics in `go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp` and `go.opentelemetry.io/otel/exporters/otlp/otlplog/otlploghttp`. (#8226)
+- Fix a concurrent `Collect` data race and potential panic in `go.opentelemetry.io/otel/exporters/prometheus` when `WithResourceAsConstantLabels` option is used. (#8227)
+- Fix race condition in `FixedSizeReservoir` in `go.opentelemetry.io/otel/sdk/metric/exemplar` by reverting #7447. (#8249)
+- Fix `FixedSizeReservoir` in `go.opentelemetry.io/otel/sdk/metric/exemplar` to safely handle zero size.
+ A capacity check in the constructor initializes the reservoir safely and skips initialization for zero-cap; early returns in `Offer()` and `Collect()` ensure no-op behavior. (#8295)
+- Fix counting of spans and logs in self-observability metrics in `go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc`, `go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp`, `go.opentelemetry.io/otel/exporters/otlp/otlplog/otlploggrpc`, and `go.opentelemetry.io/otel/exporters/otlp/otlplog/otlploghttp`. (#8254)
+- Drop conflicting scope attributes named `name`, `version`, or `schema_url` from metric labels in `go.opentelemetry.io/otel/exporters/prometheus`, preserving the dedicated `otel_scope_name`, `otel_scope_version`, and `otel_scope_schema_url` labels. (#8264)
+- Close schema files opened by `ParseFile` in `go.opentelemetry.io/otel/schema/v1.0` and `go.opentelemetry.io/otel/schema/v1.1`. ([GHSA-995v-fvrw-c78m](https://github.com/open-telemetry/opentelemetry-go/security/advisories/GHSA-995v-fvrw-c78m))
+- Enforce the 8192-byte baggage size limit during extraction/parsing, changing behavior when the limit is exceeded in `go.opentelemetry.io/otel/baggage` and `go.opentelemetry.io/otel/propagation`. (#8222)
+- Fix `go.opentelemetry.io/otel/semconv/v1.41.0` to include `Attr*` helper methods for required attributes on observable instruments. (#8361)
+- Limit baggage extraction error reporting in `go.opentelemetry.io/otel/propagation` to prevent malformed or oversized baggage headers from flooding logs. ([GHSA-5wrp-cwcj-q835](https://github.com/open-telemetry/opentelemetry-go/security/advisories/GHSA-5wrp-cwcj-q835))
+
## [1.43.0/0.65.0/0.19.0] 2026-04-02
### Added
@@ -3619,7 +3713,8 @@ 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.43.0...HEAD
+[Unreleased]: https://github.com/open-telemetry/opentelemetry-go/compare/v1.44.0...HEAD
+[1.44.0/0.66.0/0.20.0/0.0.17]: https://github.com/open-telemetry/opentelemetry-go/releases/tag/v1.44.0
[1.43.0/0.65.0/0.19.0]: https://github.com/open-telemetry/opentelemetry-go/releases/tag/v1.43.0
[1.42.0/0.64.0/0.18.0/0.0.16]: https://github.com/open-telemetry/opentelemetry-go/releases/tag/v1.42.0
[1.41.0/0.63.0/0.17.0/0.0.15]: https://github.com/open-telemetry/opentelemetry-go/releases/tag/v1.41.0
diff --git a/vendor/go.opentelemetry.io/otel/CLAUDE.md b/vendor/go.opentelemetry.io/otel/CLAUDE.md
new file mode 100644
index 0000000000..dd3c4594fc
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/CLAUDE.md
@@ -0,0 +1,3 @@
+# Instructions for Claude Code
+
+@AGENTS.md
diff --git a/vendor/go.opentelemetry.io/otel/CONTRIBUTING.md b/vendor/go.opentelemetry.io/otel/CONTRIBUTING.md
index 12de3607a3..3ec17d6832 100644
--- a/vendor/go.opentelemetry.io/otel/CONTRIBUTING.md
+++ b/vendor/go.opentelemetry.io/otel/CONTRIBUTING.md
@@ -11,6 +11,12 @@ for a summary description of past meetings. To request edit access,
join the meeting or get in touch on
[Slack](https://cloud-native.slack.com/archives/C01NPAXACKT).
+The meeting is open for all to join. We invite everyone to join our
+meeting, regardless of your experience level. Whether you're a
+seasoned OpenTelemetry developer, just starting your journey, or
+simply curious about the work we do, you're more than welcome to
+participate!
+
## Development
You can view and edit the source code by cloning this repository:
@@ -746,8 +752,8 @@ Encapsulate setup in constructor functions, ensuring clear ownership and scope:
import (
"errors"
- semconv "go.opentelemetry.io/otel/semconv/v1.40.0"
- "go.opentelemetry.io/otel/semconv/v1.40.0/otelconv"
+ semconv "go.opentelemetry.io/otel/semconv/v1.41.0"
+ "go.opentelemetry.io/otel/semconv/v1.41.0/otelconv"
)
type SDKComponent struct {
@@ -808,11 +814,11 @@ func (c *Component) initObservability() {
#### Performance
-When observability is disabled there should be little to no overhead.
+When observability is disabled or the instrument is not `Enabled`, there should be little to no overhead.
```go
func (e *Exporter) ExportSpans(ctx context.Context, spans []trace.ReadOnlySpan) error {
- if e.inst != nil {
+ if e.inst != nil && e.inst.Enabled(ctx) {
attrs := expensiveOperation()
e.inst.recordSpanInflight(ctx, int64(len(spans)), attrs...)
}
@@ -829,7 +835,7 @@ func (e *Exporter) ExportSpans(ctx context.Context, spans []trace.ReadOnlySpan)
}
func (i *instrumentation) recordSpanInflight(ctx context.Context, count int64, attrs ...attribute.KeyValue) {
- if i == nil || i.inflight == nil {
+ if i == nil || i.inflight == nil || !i.inflight.Enabled(ctx) {
return
}
i.inflight.Add(ctx, count, metric.WithAttributes(attrs...))
@@ -865,8 +871,12 @@ var (
)
func (i *instrumentation) record(ctx context.Context, value int64, baseAttrs ...attribute.KeyValue) {
+ if !i.counter.Enabled(ctx) {
+ return
+ }
attrs := attrPool.Get().(*[]attribute.KeyValue)
defer func() {
+ clear(*attrs) // Clear references to strings/etc to let GC collect them.
*attrs = (*attrs)[:0] // Reset.
attrPool.Put(attrs)
}()
@@ -877,6 +887,7 @@ func (i *instrumentation) record(ctx context.Context, value int64, baseAttrs ...
addOpt := addOptPool.Get().(*[]metric.AddOption)
defer func() {
+ clear(*addOpt)
*addOpt = (*addOpt)[:0]
addOptPool.Put(addOpt)
}()
@@ -1007,16 +1018,20 @@ Ensure observability measurements receive the correct context, especially for tr
```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))
+ if e.inst.Enabled(ctx) {
+ 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))
+ if e.inst.Enabled(ctx) {
+ if err != nil {
+ e.inst.recordSpanExportFailed(ctx, len(spans), err)
+ } else {
+ e.inst.recordSpanExportSucceeded(ctx, len(spans))
+ }
}
-
+
return err
}
```
@@ -1039,7 +1054,7 @@ func (e *Exporter) ExportSpans(ctx context.Context, spans []trace.ReadOnlySpan)
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.40.0/otelconv/metric.go).
+Use the metric semantic conventions convenience package [otelconv](./semconv/v1.41.0/otelconv/metric.go).
##### Component Identification
@@ -1109,6 +1124,68 @@ func TestObservability(t *testing.T) {
Test order should not affect results.
Ensure that any global state (e.g. component ID counters) is reset between tests.
+### Experimental Features
+
+To support the development of new features in the specification, we use the following patterns to implement in-development features without adding new public artifacts in stable modules.
+
+#### Experimental behavior with no API artifacts
+
+Features that change behavior without changing the API (e.g., exemplar collection, auto-generation of identifiers) are implemented behind a feature gate.
+The implementation resides in an `/internal/x` package and is activated through environment variables with the `OTEL_GO_X_` prefix (e.g., `OTEL_GO_X_OBSERVABILITY`).
+The feature must be documented in a `README.md` file in the `/internal/x` package.
+
+#### Experimental methods on SDK-only interfaces
+
+Features that require new methods on SDK interfaces are defined as a new interface in an experimental module (e.g., `go.opentelemetry.io/otel/sdk/x`).
+The SDK uses type assertions (without importing the unstable package) to check if passing types implement these experimental interfaces.
+The SDK must not depend on the experimental module.
+
+#### Experimental structs, functions, or interfaces
+
+Features that don't need any changes to the existing stable package are implemented in an experimental module (e.g., `go.opentelemetry.io/otel/sdk/x`).
+
+#### Experimental signals and components
+
+New telemetry signals (e.g., Logs before stabilization) and components (e.g. bridges) are hosted in new, unstable modules (e.g., `go.opentelemetry.io/otel/log` before 1.0.0).
+The package should have the final name it will use once stabilized (i.e. not `/x`), and is released at a v0.x.y version to indicate it is not stable.
+Most new components are hosted in [opentelemetry-go-contrib](https://github.com/open-telemetry/opentelemetry-go-contrib).
+
+#### Experimental options for API or SDK functions
+
+Experimental Options functions are implemented in an experimental module (e.g., `go.opentelemetry.io/otel/sdk/x`).
+The return type of the Option function must embed the option's type (e.g. `metric.InstrumentOption`), and have an `Experimental()` method to prevent the API from panicking when the option is used.
+The SDK uses type assertions (without importing the unstable package) to check if passing types implement these experimental interfaces.
+The SDK must not depend on the experimental module.
+
+For example:
+
+```go
+type myOption struct {
+ // Embed the stable option type.
+ metric.InstrumentOption
+ value string
+}
+
+// Experimental prevents the API from panicking when the option is used.
+func (o myOption) Experimental() {}
+
+// The SDK can use type assertions to use this function.
+func (o myOption) Value() string { return o.value }
+
+func WithMyOption(value string) metric.InstrumentOption {
+ return myOption{value: value}
+}
+```
+
+#### Not Supported
+
+The following kinds of experimental features are **not currently supported** on stable interfaces:
+
+- Experimental methods on API interfaces
+- Experimental fields for API or SDK exported structs
+
+In some cases forks or long-lived branches may be used for prototyping these features.
+
## Approvers and Maintainers
### Maintainers
diff --git a/vendor/go.opentelemetry.io/otel/Makefile b/vendor/go.opentelemetry.io/otel/Makefile
index 42466f2d6a..de63a5e9bc 100644
--- a/vendor/go.opentelemetry.io/otel/Makefile
+++ b/vendor/go.opentelemetry.io/otel/Makefile
@@ -191,8 +191,16 @@ benchmark: $(OTEL_GO_MOD_DIRS:%=benchmark/%)
benchmark/%:
cd $* && $(GO) test -run='^$$' -bench=. $(ARGS) ./...
+# sdk/metric is split into two shards to work around CodSpeed limitations.
+# See https://github.com/CodSpeedHQ/codspeed-go/issues/56
+BENCHMARK_SHARDS := $(filter-out ./sdk/metric,$(OTEL_GO_MOD_DIRS)) ./sdk/metric/root ./sdk/metric/internal
+benchmark/./sdk/metric/root:
+ cd ./sdk/metric && $(GO) test -run='^$$' -bench=. $(ARGS) . ./exemplar/...
+benchmark/./sdk/metric/internal:
+ cd ./sdk/metric && $(GO) test -run='^$$' -bench=. $(ARGS) ./internal/...
+
print-sharded-benchmarks:
- @echo $(OTEL_GO_MOD_DIRS) | jq -cR 'split(" ")'
+ @echo $(BENCHMARK_SHARDS) | jq -cR 'split(" ")'
.PHONY: golangci-lint golangci-lint-fix
golangci-lint-fix: ARGS=--fix
diff --git a/vendor/go.opentelemetry.io/otel/attribute/encoder.go b/vendor/go.opentelemetry.io/otel/attribute/encoder.go
index 771dd69c55..ca186d8ac2 100644
--- a/vendor/go.opentelemetry.io/otel/attribute/encoder.go
+++ b/vendor/go.opentelemetry.io/otel/attribute/encoder.go
@@ -105,7 +105,9 @@ func (d *defaultAttrEncoder) Encode(iter Iterator) string {
if keyValue.Value.Type() == STRING {
copyAndEscape(buf, keyValue.Value.AsString())
} else {
- _, _ = buf.WriteString(keyValue.Value.Emit())
+ _, _ = buf.WriteString(
+ keyValue.Value.Emit(),
+ ) //nolint:staticcheck // Preserve the existing default encoder output.
}
}
return buf.String()
diff --git a/vendor/go.opentelemetry.io/otel/attribute/hash.go b/vendor/go.opentelemetry.io/otel/attribute/hash.go
index b09caaa6d7..92f39ffe7b 100644
--- a/vendor/go.opentelemetry.io/otel/attribute/hash.go
+++ b/vendor/go.opentelemetry.io/otel/attribute/hash.go
@@ -27,6 +27,8 @@ const (
int64SliceID uint64 = 3762322556277578591 // "_[]int64" (little endian)
float64SliceID uint64 = 7308324551835016539 // "[]double" (little endian)
stringSliceID uint64 = 7453010373645655387 // "[]string" (little endian)
+ byteSliceID uint64 = 6874028470941080415 // "_[]byte_" (little endian)
+ sliceID uint64 = 7883494272577650031 // "__slice_" (little endian)
emptyID uint64 = 7305809155345288421 // "__empty_" (little endian)
)
@@ -42,53 +44,87 @@ func hashKVs(kvs []KeyValue) uint64 {
// 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))
+ return hashValue(h, kv.Value)
+}
- switch kv.Value.Type() {
+func hashValue(h xxhash.Hash, v Value) xxhash.Hash {
+ switch v.Type() {
case BOOL:
h = h.Uint64(boolID)
- h = h.Uint64(kv.Value.numeric)
+ h = h.Uint64(v.numeric)
case INT64:
h = h.Uint64(int64ID)
- h = h.Uint64(kv.Value.numeric)
+ h = h.Uint64(v.numeric)
case FLOAT64:
h = h.Uint64(float64ID)
// Assumes numeric stored with math.Float64bits.
- h = h.Uint64(kv.Value.numeric)
+ h = h.Uint64(v.numeric)
case STRING:
h = h.Uint64(stringID)
- h = h.String(kv.Value.stringly)
+ h = h.String(v.stringly)
case BOOLSLICE:
h = h.Uint64(boolSliceID)
- rv := reflect.ValueOf(kv.Value.slice)
+ rv := reflect.ValueOf(v.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)
+ rv := reflect.ValueOf(v.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)
+ rv := reflect.ValueOf(v.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)
+ rv := reflect.ValueOf(v.slice)
for i := 0; i < rv.Len(); i++ {
h = h.String(rv.Index(i).String())
}
+ case BYTESLICE:
+ h = h.Uint64(byteSliceID)
+ h = h.String(v.stringly)
+ case SLICE:
+ h = h.Uint64(sliceID)
+ switch vals := v.slice.(type) {
+ case [0]Value:
+ // No values to hash, but the type identifier is still hashed above.
+ case [1]Value:
+ h = hashValueSlice(h, vals[:])
+ case [2]Value:
+ h = hashValueSlice(h, vals[:])
+ case [3]Value:
+ h = hashValueSlice(h, vals[:])
+ case [4]Value:
+ h = hashValueSlice(h, vals[:])
+ case [5]Value:
+ h = hashValueSlice(h, vals[:])
+ default:
+ rv := reflect.ValueOf(v.slice)
+ for i := 0; i < rv.Len(); i++ {
+ h = hashValue(h, rv.Index(i).Interface().(Value))
+ }
+ }
case EMPTY:
h = h.Uint64(emptyID)
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)
+ val := v.AsInterface()
+ msg := fmt.Sprintf("unknown value type: %[1]v (%[1]T)", val)
panic(msg)
}
return h
}
+
+func hashValueSlice(h xxhash.Hash, vals []Value) xxhash.Hash {
+ for _, v := range vals {
+ h = hashValue(h, v)
+ }
+ return h
+}
diff --git a/vendor/go.opentelemetry.io/otel/attribute/key.go b/vendor/go.opentelemetry.io/otel/attribute/key.go
index 80a9e5643f..cdc7089e82 100644
--- a/vendor/go.opentelemetry.io/otel/attribute/key.go
+++ b/vendor/go.opentelemetry.io/otel/attribute/key.go
@@ -117,6 +117,28 @@ func (k Key) StringSlice(v []string) KeyValue {
}
}
+// ByteSlice creates a KeyValue instance with a BYTESLICE Value.
+//
+// If creating both a key and value at the same time, use the provided
+// convenience function instead -- ByteSlice(name, value).
+func (k Key) ByteSlice(v []byte) KeyValue {
+ return KeyValue{
+ Key: k,
+ Value: ByteSliceValue(v),
+ }
+}
+
+// Slice creates a KeyValue instance with a SLICE Value.
+//
+// If creating both a key and value at the same time, use the provided
+// convenience function instead -- Slice(name, values...).
+func (k Key) Slice(v ...Value) KeyValue {
+ return KeyValue{
+ Key: k,
+ Value: SliceValue(v...),
+ }
+}
+
// 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 0cc368018b..eeb76a1348 100644
--- a/vendor/go.opentelemetry.io/otel/attribute/kv.go
+++ b/vendor/go.opentelemetry.io/otel/attribute/kv.go
@@ -68,6 +68,16 @@ func StringSlice(k string, v []string) KeyValue {
return Key(k).StringSlice(v)
}
+// ByteSlice creates a KeyValue with a BYTESLICE Value type.
+func ByteSlice(k string, v []byte) KeyValue {
+ return Key(k).ByteSlice(v)
+}
+
+// Slice creates a KeyValue with a SLICE Value type.
+func Slice(k string, v ...Value) KeyValue {
+ return Key(k).Slice(v...)
+}
+
// Stringer creates a new key-value pair with a passed name and a string
// value generated by the passed Stringer interface.
func Stringer(k string, v fmt.Stringer) KeyValue {
diff --git a/vendor/go.opentelemetry.io/otel/attribute/set.go b/vendor/go.opentelemetry.io/otel/attribute/set.go
index 6572c98b12..a4b6ce81de 100644
--- a/vendor/go.opentelemetry.io/otel/attribute/set.go
+++ b/vendor/go.opentelemetry.io/otel/attribute/set.go
@@ -401,7 +401,7 @@ func computeDataFixed(kvs []KeyValue) any {
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
+ *at.Index(i).Addr().Interface().(*KeyValue) = keyValue
}
return at.Interface()
}
@@ -415,7 +415,7 @@ func (l *Set) MarshalJSON() ([]byte, error) {
func (l Set) MarshalLog() any {
kvs := make(map[string]string)
for _, kv := range l.ToSlice() {
- kvs[string(kv.Key)] = kv.Value.Emit()
+ kvs[string(kv.Key)] = kv.Value.String()
}
return kvs
}
diff --git a/vendor/go.opentelemetry.io/otel/attribute/type_string.go b/vendor/go.opentelemetry.io/otel/attribute/type_string.go
index 6c04448d6f..dbc01d3247 100644
--- a/vendor/go.opentelemetry.io/otel/attribute/type_string.go
+++ b/vendor/go.opentelemetry.io/otel/attribute/type_string.go
@@ -17,11 +17,13 @@ func _() {
_ = x[INT64SLICE-6]
_ = x[FLOAT64SLICE-7]
_ = x[STRINGSLICE-8]
+ _ = x[BYTESLICE-9]
+ _ = x[SLICE-10]
}
-const _Type_name = "EMPTYBOOLINT64FLOAT64STRINGBOOLSLICEINT64SLICEFLOAT64SLICESTRINGSLICE"
+const _Type_name = "EMPTYBOOLINT64FLOAT64STRINGBOOLSLICEINT64SLICEFLOAT64SLICESTRINGSLICEBYTESLICESLICE"
-var _Type_index = [...]uint8{0, 5, 9, 14, 21, 27, 36, 46, 58, 69}
+var _Type_index = [...]uint8{0, 5, 9, 14, 21, 27, 36, 46, 58, 69, 78, 83}
func (i Type) String() string {
idx := int(i) - 0
diff --git a/vendor/go.opentelemetry.io/otel/attribute/value.go b/vendor/go.opentelemetry.io/otel/attribute/value.go
index db04b1326c..0529fefae2 100644
--- a/vendor/go.opentelemetry.io/otel/attribute/value.go
+++ b/vendor/go.opentelemetry.io/otel/attribute/value.go
@@ -4,9 +4,14 @@
package attribute // import "go.opentelemetry.io/otel/attribute"
import (
+ "encoding/base64"
"encoding/json"
"fmt"
+ "math"
+ "reflect"
"strconv"
+ "strings"
+ "unicode/utf8"
attribute "go.opentelemetry.io/otel/attribute/internal"
)
@@ -45,6 +50,10 @@ const (
FLOAT64SLICE
// STRINGSLICE is a slice of strings Type Value.
STRINGSLICE
+ // BYTESLICE is a slice of bytes Type Value.
+ BYTESLICE
+ // SLICE is a slice of Value Type values.
+ SLICE
// INVALID is used for a Value with no value set.
//
// Deprecated: Use EMPTY instead as an empty value is a valid value.
@@ -134,6 +143,19 @@ func StringSliceValue(v []string) Value {
return Value{vtype: STRINGSLICE, slice: attribute.SliceValue(v)}
}
+// ByteSliceValue creates a BYTESLICE Value.
+func ByteSliceValue(v []byte) Value {
+ return Value{
+ vtype: BYTESLICE,
+ stringly: string(v),
+ }
+}
+
+// SliceValue creates a SLICE Value.
+func SliceValue(v ...Value) Value {
+ return Value{vtype: SLICE, slice: sliceValue(v)}
+}
+
// Type returns a type of the Value.
func (v Value) Type() Type {
return v.vtype
@@ -215,6 +237,59 @@ func (v Value) asStringSlice() []string {
return attribute.AsSlice[string](v.slice)
}
+// AsSlice returns the []Value value. Make sure that the Value's type is
+// SLICE.
+func (v Value) AsSlice() []Value {
+ if v.vtype != SLICE {
+ return nil
+ }
+ return v.asSlice()
+}
+
+func (v Value) asSlice() []Value {
+ switch vals := v.slice.(type) {
+ case [0]Value:
+ return []Value{}
+ case [1]Value:
+ return []Value{vals[0]}
+ case [2]Value:
+ return []Value{vals[0], vals[1]}
+ case [3]Value:
+ return []Value{vals[0], vals[1], vals[2]}
+ case [4]Value:
+ return []Value{vals[0], vals[1], vals[2], vals[3]}
+ case [5]Value:
+ return []Value{vals[0], vals[1], vals[2], vals[3], vals[4]}
+ default:
+ return asValueSliceReflect(v.slice)
+ }
+}
+
+func asValueSliceReflect(v any) []Value {
+ rv := reflect.ValueOf(v)
+ if !rv.IsValid() || rv.Kind() != reflect.Array || rv.Type().Elem() != reflect.TypeFor[Value]() {
+ return nil
+ }
+ cpy := make([]Value, rv.Len())
+ if len(cpy) > 0 {
+ _ = reflect.Copy(reflect.ValueOf(cpy), rv)
+ }
+ return cpy
+}
+
+// AsByteSlice returns the bytes value. Make sure that the Value's type
+// is BYTESLICE.
+func (v Value) AsByteSlice() []byte {
+ if v.vtype != BYTESLICE {
+ return nil
+ }
+ return v.asByteSlice()
+}
+
+func (v Value) asByteSlice() []byte {
+ return []byte(v.stringly)
+}
+
type unknownValueType struct{}
// AsInterface returns Value's data as any.
@@ -236,13 +311,60 @@ func (v Value) AsInterface() any {
return v.stringly
case STRINGSLICE:
return v.asStringSlice()
+ case BYTESLICE:
+ return v.asByteSlice()
+ case SLICE:
+ return v.asSlice()
case EMPTY:
return nil
}
return unknownValueType{}
}
+// String returns a string representation of Value using the
+// [OpenTelemetry AnyValue representation for non-OTLP protocols] rules.
+//
+// Strings are returned as-is without JSON quoting, booleans and integers use
+// JSON literals, floating-point values use JSON numbers except that NaN and
+// ±Inf are rendered as NaN, Infinity, and -Infinity, byte slices are
+// base64-encoded, empty values are the empty string, and slices are encoded as
+// JSON arrays. String, byte, and special floating-point values inside arrays
+// are encoded as JSON strings, and empty values inside arrays are encoded as
+// null.
+//
+// [OpenTelemetry AnyValue representation for non-OTLP protocols]: https://opentelemetry.io/docs/specs/otel/common/#anyvalue-representation-for-non-otlp-protocols
+func (v Value) String() string {
+ switch v.Type() {
+ case BOOL:
+ return strconv.FormatBool(v.AsBool())
+ case BOOLSLICE:
+ return formatBoolSliceValue(v.slice)
+ case INT64:
+ return strconv.FormatInt(v.AsInt64(), 10)
+ case INT64SLICE:
+ return formatInt64SliceValue(v.slice)
+ case FLOAT64:
+ return formatFloat64(v.AsFloat64())
+ case FLOAT64SLICE:
+ return formatFloat64SliceValue(v.slice)
+ case STRING:
+ return v.stringly
+ case STRINGSLICE:
+ return formatStringSliceValue(v.slice)
+ case BYTESLICE:
+ return formatByteSlice(v.stringly)
+ case SLICE:
+ return formatValueSliceValue(v.slice)
+ case EMPTY:
+ return ""
+ default:
+ return "unknown"
+ }
+}
+
// Emit returns a string representation of Value's data.
+//
+// Deprecated: Use [Value.String] instead.
func (v Value) Emit() string {
switch v.Type() {
case BOOLSLICE:
@@ -273,6 +395,10 @@ func (v Value) Emit() string {
return string(j)
case STRING:
return v.stringly
+ case BYTESLICE:
+ return formatByteSlice(v.stringly)
+ case SLICE:
+ return formatValueSliceValue(v.slice)
case EMPTY:
return ""
default:
@@ -280,6 +406,622 @@ func (v Value) Emit() string {
}
}
+const (
+ jsonArrayBracketsLen = len("[]")
+ boolArrayElemMaxLen = len("false")
+ int64ArrayElemMaxLen = len("-9223372036854775808")
+ float64ArrayElemMaxLen = len("-1.7976931348623157e+308")
+ commaLen = len(",")
+)
+
+func sliceValue(v []Value) any {
+ switch len(v) {
+ case 0:
+ return [0]Value{}
+ case 1:
+ return [1]Value{v[0]}
+ case 2:
+ return [2]Value{v[0], v[1]}
+ case 3:
+ return [3]Value{v[0], v[1], v[2]}
+ case 4:
+ return [4]Value{v[0], v[1], v[2], v[3]}
+ case 5:
+ return [5]Value{v[0], v[1], v[2], v[3], v[4]}
+ default:
+ return sliceValueReflect(v)
+ }
+}
+
+func sliceValueReflect(v []Value) any {
+ cp := reflect.New(reflect.ArrayOf(len(v), reflect.TypeFor[Value]())).Elem()
+ reflect.Copy(cp, reflect.ValueOf(v))
+ return cp.Interface()
+}
+
+func formatBoolSliceValue(v any) string {
+ switch vals := v.(type) {
+ case [0]bool:
+ return "[]"
+ case [1]bool:
+ return formatBoolSlice(vals[:])
+ case [2]bool:
+ return formatBoolSlice(vals[:])
+ case [3]bool:
+ return formatBoolSlice(vals[:])
+ default:
+ return formatBoolSliceReflect(v)
+ }
+}
+
+func formatBoolSlice(vals []bool) string {
+ var b strings.Builder
+ appendBoolSlice(&b, vals)
+ return b.String()
+}
+
+func formatBoolSliceReflect(v any) string {
+ var b strings.Builder
+ appendBoolSliceReflect(&b, reflect.ValueOf(v))
+ return b.String()
+}
+
+func appendBoolSliceValue(dst *strings.Builder, v any) {
+ switch vals := v.(type) {
+ case [0]bool:
+ _, _ = dst.WriteString("[]")
+ case [1]bool:
+ appendBoolSlice(dst, vals[:])
+ case [2]bool:
+ appendBoolSlice(dst, vals[:])
+ case [3]bool:
+ appendBoolSlice(dst, vals[:])
+ default:
+ appendBoolSliceReflect(dst, reflect.ValueOf(v))
+ }
+}
+
+func appendBoolSlice(dst *strings.Builder, vals []bool) {
+ dst.Grow(jsonArrayBracketsLen + len(vals)*(boolArrayElemMaxLen+commaLen))
+ _ = dst.WriteByte('[')
+ for i, val := range vals {
+ if i > 0 {
+ _ = dst.WriteByte(',')
+ }
+ if val {
+ _, _ = dst.WriteString("true")
+ } else {
+ _, _ = dst.WriteString("false")
+ }
+ }
+ _ = dst.WriteByte(']')
+}
+
+func appendBoolSliceReflect(dst *strings.Builder, rv reflect.Value) {
+ dst.Grow(jsonArrayBracketsLen + rv.Len()*(boolArrayElemMaxLen+commaLen))
+ _ = dst.WriteByte('[')
+ for i := 0; i < rv.Len(); i++ {
+ if i > 0 {
+ _ = dst.WriteByte(',')
+ }
+ if rv.Index(i).Bool() {
+ _, _ = dst.WriteString("true")
+ } else {
+ _, _ = dst.WriteString("false")
+ }
+ }
+ _ = dst.WriteByte(']')
+}
+
+func formatInt64SliceValue(v any) string {
+ switch vals := v.(type) {
+ case [0]int64:
+ return "[]"
+ case [1]int64:
+ return formatInt64Slice(vals[:])
+ case [2]int64:
+ return formatInt64Slice(vals[:])
+ case [3]int64:
+ return formatInt64Slice(vals[:])
+ default:
+ return formatInt64SliceReflect(v)
+ }
+}
+
+func formatInt64Slice(vals []int64) string {
+ var b strings.Builder
+ appendInt64Slice(&b, vals)
+ return b.String()
+}
+
+func formatInt64SliceReflect(v any) string {
+ var b strings.Builder
+ appendInt64SliceReflect(&b, reflect.ValueOf(v))
+ return b.String()
+}
+
+func appendInt64SliceValue(dst *strings.Builder, v any) {
+ switch vals := v.(type) {
+ case [0]int64:
+ _, _ = dst.WriteString("[]")
+ case [1]int64:
+ appendInt64Slice(dst, vals[:])
+ case [2]int64:
+ appendInt64Slice(dst, vals[:])
+ case [3]int64:
+ appendInt64Slice(dst, vals[:])
+ default:
+ appendInt64SliceReflect(dst, reflect.ValueOf(v))
+ }
+}
+
+func appendInt64Slice(dst *strings.Builder, vals []int64) {
+ dst.Grow(jsonArrayBracketsLen + len(vals)*(int64ArrayElemMaxLen+commaLen))
+ _ = dst.WriteByte('[')
+
+ var buf [int64ArrayElemMaxLen]byte
+ for i, val := range vals {
+ if i > 0 {
+ _ = dst.WriteByte(',')
+ }
+ out := strconv.AppendInt(buf[:0], val, 10)
+ _, _ = dst.Write(out)
+ }
+
+ _ = dst.WriteByte(']')
+}
+
+func appendInt64SliceReflect(dst *strings.Builder, rv reflect.Value) {
+ dst.Grow(jsonArrayBracketsLen + rv.Len()*(int64ArrayElemMaxLen+commaLen))
+ _ = dst.WriteByte('[')
+
+ var scratch [int64ArrayElemMaxLen]byte
+ for i := 0; i < rv.Len(); i++ {
+ if i > 0 {
+ _ = dst.WriteByte(',')
+ }
+ out := strconv.AppendInt(scratch[:0], rv.Index(i).Int(), 10)
+ _, _ = dst.Write(out)
+ }
+
+ _ = dst.WriteByte(']')
+}
+
+func formatFloat64(v float64) string {
+ switch {
+ case math.IsNaN(v):
+ return "NaN"
+ case math.IsInf(v, 1):
+ return "Infinity"
+ case math.IsInf(v, -1):
+ return "-Infinity"
+ default:
+ return strconv.FormatFloat(v, 'g', -1, 64)
+ }
+}
+
+func formatFloat64SliceValue(v any) string {
+ switch vals := v.(type) {
+ case [0]float64:
+ return "[]"
+ case [1]float64:
+ return formatFloat64Slice(vals[:])
+ case [2]float64:
+ return formatFloat64Slice(vals[:])
+ case [3]float64:
+ return formatFloat64Slice(vals[:])
+ default:
+ return formatFloat64SliceReflect(v)
+ }
+}
+
+func formatFloat64Slice(vals []float64) string {
+ var b strings.Builder
+ appendFloat64Slice(&b, vals)
+ return b.String()
+}
+
+func formatFloat64SliceReflect(v any) string {
+ var b strings.Builder
+ appendFloat64SliceReflect(&b, reflect.ValueOf(v))
+ return b.String()
+}
+
+func appendFloat64SliceValue(dst *strings.Builder, v any) {
+ switch vals := v.(type) {
+ case [0]float64:
+ _, _ = dst.WriteString("[]")
+ case [1]float64:
+ appendFloat64Slice(dst, vals[:])
+ case [2]float64:
+ appendFloat64Slice(dst, vals[:])
+ case [3]float64:
+ appendFloat64Slice(dst, vals[:])
+ default:
+ appendFloat64SliceReflect(dst, reflect.ValueOf(v))
+ }
+}
+
+func appendFloat64Slice(dst *strings.Builder, vals []float64) {
+ dst.Grow(jsonArrayBracketsLen + len(vals)*(float64ArrayElemMaxLen+commaLen))
+ _ = dst.WriteByte('[')
+
+ var buf [float64ArrayElemMaxLen]byte
+ for i, val := range vals {
+ if i > 0 {
+ _ = dst.WriteByte(',')
+ }
+
+ switch {
+ case math.IsNaN(val):
+ _, _ = dst.WriteString(`"NaN"`)
+ case math.IsInf(val, 1):
+ _, _ = dst.WriteString(`"Infinity"`)
+ case math.IsInf(val, -1):
+ _, _ = dst.WriteString(`"-Infinity"`)
+ default:
+ out := strconv.AppendFloat(buf[:0], val, 'g', -1, 64)
+ _, _ = dst.Write(out)
+ }
+ }
+
+ _ = dst.WriteByte(']')
+}
+
+func appendFloat64SliceReflect(dst *strings.Builder, rv reflect.Value) {
+ dst.Grow(jsonArrayBracketsLen + rv.Len()*(float64ArrayElemMaxLen+commaLen))
+ _ = dst.WriteByte('[')
+
+ var scratch [float64ArrayElemMaxLen]byte
+ for i := 0; i < rv.Len(); i++ {
+ if i > 0 {
+ _ = dst.WriteByte(',')
+ }
+ val := rv.Index(i).Float()
+ switch {
+ case math.IsNaN(val):
+ _, _ = dst.WriteString(`"NaN"`)
+ case math.IsInf(val, 1):
+ _, _ = dst.WriteString(`"Infinity"`)
+ case math.IsInf(val, -1):
+ _, _ = dst.WriteString(`"-Infinity"`)
+ default:
+ out := strconv.AppendFloat(scratch[:0], val, 'g', -1, 64)
+ _, _ = dst.Write(out)
+ }
+ }
+
+ _ = dst.WriteByte(']')
+}
+
+func formatStringSliceValue(v any) string {
+ switch vals := v.(type) {
+ case [0]string:
+ return "[]"
+ case [1]string:
+ return formatStringSlice(vals[:])
+ case [2]string:
+ return formatStringSlice(vals[:])
+ case [3]string:
+ return formatStringSlice(vals[:])
+ default:
+ return formatStringSliceReflect(v)
+ }
+}
+
+func formatStringSlice(vals []string) string {
+ var b strings.Builder
+ appendStringSlice(&b, vals)
+ return b.String()
+}
+
+func formatStringSliceReflect(v any) string {
+ var b strings.Builder
+ appendStringSliceReflect(&b, reflect.ValueOf(v))
+ return b.String()
+}
+
+func appendStringSliceValue(dst *strings.Builder, v any) {
+ switch vals := v.(type) {
+ case [0]string:
+ _, _ = dst.WriteString("[]")
+ case [1]string:
+ appendStringSlice(dst, vals[:])
+ case [2]string:
+ appendStringSlice(dst, vals[:])
+ case [3]string:
+ appendStringSlice(dst, vals[:])
+ default:
+ appendStringSliceReflect(dst, reflect.ValueOf(v))
+ }
+}
+
+func appendStringSlice(dst *strings.Builder, vals []string) {
+ size := jsonArrayBracketsLen
+ for _, val := range vals {
+ size += len(val) + commaLen + 2 // Account for JSON string quotes and comma.
+ }
+
+ dst.Grow(size)
+ _ = dst.WriteByte('[')
+ for i, val := range vals {
+ if i > 0 {
+ _ = dst.WriteByte(',')
+ }
+ appendJSONString(dst, val)
+ }
+ _ = dst.WriteByte(']')
+}
+
+func appendStringSliceReflect(dst *strings.Builder, rv reflect.Value) {
+ size := jsonArrayBracketsLen
+ for i := 0; i < rv.Len(); i++ {
+ size += len(rv.Index(i).String()) + commaLen + 2 // Account for JSON string quotes and comma.
+ }
+
+ dst.Grow(size)
+ _ = dst.WriteByte('[')
+ for i := 0; i < rv.Len(); i++ {
+ if i > 0 {
+ _ = dst.WriteByte(',')
+ }
+ appendJSONString(dst, rv.Index(i).String())
+ }
+ _ = dst.WriteByte(']')
+}
+
+func formatByteSlice(v string) string {
+ var b strings.Builder
+ appendBase64(&b, v)
+ return b.String()
+}
+
+func formatValueSliceValue(v any) string {
+ switch vals := v.(type) {
+ case [0]Value:
+ return "[]"
+ case [1]Value:
+ return formatValueSlice(vals[:])
+ case [2]Value:
+ return formatValueSlice(vals[:])
+ case [3]Value:
+ return formatValueSlice(vals[:])
+ case [4]Value:
+ return formatValueSlice(vals[:])
+ case [5]Value:
+ return formatValueSlice(vals[:])
+ default:
+ return formatValueSliceReflect(v)
+ }
+}
+
+func formatValueSlice(vals []Value) string {
+ var b strings.Builder
+ appendValueSlice(&b, vals)
+ return b.String()
+}
+
+func formatValueSliceReflect(v any) string {
+ var b strings.Builder
+ appendValueSliceReflect(&b, reflect.ValueOf(v))
+ return b.String()
+}
+
+func appendValueSliceValue(dst *strings.Builder, v any) {
+ switch vals := v.(type) {
+ case [0]Value:
+ _, _ = dst.WriteString("[]")
+ case [1]Value:
+ appendValueSlice(dst, vals[:])
+ case [2]Value:
+ appendValueSlice(dst, vals[:])
+ case [3]Value:
+ appendValueSlice(dst, vals[:])
+ case [4]Value:
+ appendValueSlice(dst, vals[:])
+ case [5]Value:
+ appendValueSlice(dst, vals[:])
+ default:
+ appendValueSliceReflect(dst, reflect.ValueOf(v))
+ }
+}
+
+func appendValueSlice(dst *strings.Builder, vals []Value) {
+ // Estimate 10 bytes per value for small values and commas.
+ dst.Grow(jsonArrayBracketsLen + len(vals)*commaLen + len(vals)*10)
+ _ = dst.WriteByte('[')
+ for i, val := range vals {
+ if i > 0 {
+ _ = dst.WriteByte(',')
+ }
+ appendJSONValue(dst, val)
+ }
+ _ = dst.WriteByte(']')
+}
+
+func appendValueSliceReflect(dst *strings.Builder, rv reflect.Value) {
+ // Estimate 10 bytes per value for small values and commas.
+ dst.Grow(jsonArrayBracketsLen + rv.Len()*commaLen + rv.Len()*10)
+ _ = dst.WriteByte('[')
+ for i := 0; i < rv.Len(); i++ {
+ if i > 0 {
+ _ = dst.WriteByte(',')
+ }
+ appendJSONValue(dst, rv.Index(i).Interface().(Value))
+ }
+ _ = dst.WriteByte(']')
+}
+
+func appendJSONValue(dst *strings.Builder, v Value) {
+ switch v.Type() {
+ case BOOL:
+ if v.AsBool() {
+ _, _ = dst.WriteString("true")
+ } else {
+ _, _ = dst.WriteString("false")
+ }
+ case BOOLSLICE:
+ appendBoolSliceValue(dst, v.slice)
+ case INT64:
+ var buf [int64ArrayElemMaxLen]byte
+ out := strconv.AppendInt(buf[:0], v.AsInt64(), 10)
+ _, _ = dst.Write(out)
+ case INT64SLICE:
+ appendInt64SliceValue(dst, v.slice)
+ case FLOAT64:
+ val := v.AsFloat64()
+ switch {
+ case math.IsNaN(val):
+ appendJSONString(dst, "NaN")
+ case math.IsInf(val, 1):
+ appendJSONString(dst, "Infinity")
+ case math.IsInf(val, -1):
+ appendJSONString(dst, "-Infinity")
+ default:
+ var buf [float64ArrayElemMaxLen]byte
+ out := strconv.AppendFloat(buf[:0], val, 'g', -1, 64)
+ _, _ = dst.Write(out)
+ }
+ case FLOAT64SLICE:
+ appendFloat64SliceValue(dst, v.slice)
+ case STRING:
+ appendJSONString(dst, v.stringly)
+ case STRINGSLICE:
+ appendStringSliceValue(dst, v.slice)
+ case BYTESLICE:
+ _ = dst.WriteByte('"')
+ appendBase64(dst, v.stringly)
+ _ = dst.WriteByte('"')
+ case SLICE:
+ appendValueSliceValue(dst, v.slice)
+ case EMPTY:
+ _, _ = dst.WriteString("null")
+ default:
+ appendJSONString(dst, "unknown")
+ }
+}
+
+// appendJSONString appends s to dst as a JSON string literal.
+//
+// This is adapted from the Go standard library's encoding/json
+// [appendString implementation]. It keeps the same escaping behavior we need
+// here, but writes directly into a strings.Builder and intentionally does not
+// apply HTML escaping because the OpenTelemetry non-OTLP AnyValue representation
+// only requires JSON array string encoding. We inline this instead of using
+// encoding/json so slice formatting avoids allocations and reflection.
+//
+// [appendString implementation]: https://github.com/golang/go/blob/3b5954c6349d31465dca409b45ab6597e0942d9f/src/encoding/json/encode.go#L998-L1064
+func appendJSONString(dst *strings.Builder, s string) {
+ const hex = "0123456789abcdef" // For escaping bytes to hex.
+
+ _ = dst.WriteByte('"')
+ start := 0
+
+ for i := 0; i < len(s); {
+ if c := s[i]; c < utf8.RuneSelf {
+ if c >= 0x20 && c != '\\' && c != '"' {
+ i++
+ continue
+ }
+
+ if start < i {
+ _, _ = dst.WriteString(s[start:i])
+ }
+
+ switch c {
+ case '\\', '"':
+ _ = dst.WriteByte('\\')
+ _ = dst.WriteByte(c)
+ case '\b':
+ _, _ = dst.WriteString(`\b`)
+ case '\f':
+ _, _ = dst.WriteString(`\f`)
+ case '\n':
+ _, _ = dst.WriteString(`\n`)
+ case '\r':
+ _, _ = dst.WriteString(`\r`)
+ case '\t':
+ _, _ = dst.WriteString(`\t`)
+ default:
+ _, _ = dst.WriteString(`\u00`)
+ _ = dst.WriteByte(hex[c>>4])
+ _ = dst.WriteByte(hex[c&0x0f])
+ }
+
+ i++
+ start = i
+ continue
+ }
+
+ r, size := utf8.DecodeRuneInString(s[i:])
+ if r == utf8.RuneError && size == 1 {
+ if start < i {
+ _, _ = dst.WriteString(s[start:i])
+ }
+ // Match encoding/json by replacing invalid UTF-8 with U+FFFD.
+ _, _ = dst.WriteString(`\ufffd`)
+ i++
+ start = i
+ continue
+ }
+
+ if r == '\u2028' || r == '\u2029' {
+ if start < i {
+ _, _ = dst.WriteString(s[start:i])
+ }
+ // Escape JSONP-sensitive separators unconditionally, like encoding/json.
+ _, _ = dst.WriteString(`\u202`)
+ _ = dst.WriteByte(hex[r&0x0f])
+ i += size
+ start = i
+ continue
+ }
+
+ i += size
+ }
+
+ if start < len(s) {
+ _, _ = dst.WriteString(s[start:])
+ }
+ _ = dst.WriteByte('"')
+}
+
+// This is adapted from the Go standard library's encoding/base64
+// [Encoding.Encode implementation]. It keeps the same encoding behavior we need
+// here, but writes directly into a strings.Builder. We inline this instead of using
+// encoding/base64 to avoid allocations.
+//
+// [Encoding.Encode implementation]: https://github.com/golang/go/blob/3b5954c6349d31465dca409b45ab6597e0942d9f/src/encoding/base64/base64.go#L139-L189
+func appendBase64(dst *strings.Builder, s string) {
+ const encode = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"
+
+ dst.Grow(base64.StdEncoding.EncodedLen(len(s)))
+
+ i := 0
+ for ; i+2 < len(s); i += 3 {
+ n := uint32(s[i])<<16 | uint32(s[i+1])<<8 | uint32(s[i+2])
+ _ = dst.WriteByte(encode[n>>18&0x3f])
+ _ = dst.WriteByte(encode[n>>12&0x3f])
+ _ = dst.WriteByte(encode[n>>6&0x3f])
+ _ = dst.WriteByte(encode[n&0x3f])
+ }
+
+ switch len(s) - i {
+ case 1:
+ n := uint32(s[i]) << 16
+ _ = dst.WriteByte(encode[n>>18&0x3f])
+ _ = dst.WriteByte(encode[n>>12&0x3f])
+ _ = dst.WriteByte('=')
+ _ = dst.WriteByte('=')
+ case 2:
+ n := uint32(s[i])<<16 | uint32(s[i+1])<<8
+ _ = dst.WriteByte(encode[n>>18&0x3f])
+ _ = dst.WriteByte(encode[n>>12&0x3f])
+ _ = dst.WriteByte(encode[n>>6&0x3f])
+ _ = dst.WriteByte('=')
+ }
+}
+
// MarshalJSON returns the JSON encoding of the Value.
func (v Value) MarshalJSON() ([]byte, error) {
var jsonVal struct {
diff --git a/vendor/go.opentelemetry.io/otel/baggage/baggage.go b/vendor/go.opentelemetry.io/otel/baggage/baggage.go
index 878ffbe43a..b290c6d6cc 100644
--- a/vendor/go.opentelemetry.io/otel/baggage/baggage.go
+++ b/vendor/go.opentelemetry.io/otel/baggage/baggage.go
@@ -14,6 +14,10 @@ import (
)
const (
+ maxParseErrors = 5
+
+ // W3C Baggage specification limits.
+ // https://www.w3.org/TR/baggage/#limits
maxMembers = 64
maxBytesPerBaggageString = 8192
@@ -493,9 +497,15 @@ func New(members ...Member) (Baggage, error) {
// 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.
+// If the raw baggage-string exceeds the maximum allowed bytes (8192), an
+// empty Baggage and an error are returned.
+//
+// Otherwise, members are parsed left-to-right and accumulated until one of
+// the following conditions is reached, at which point parsing stops and an
+// error is returned alongside the partial result:
+// - accepting the next member would cause the encoded baggage to exceed
+// 8192 bytes, or
+// - the baggage already contains 64 distinct keys.
//
// Invalid members are skipped and the error is returned along with the
// partial result containing the valid members.
@@ -504,9 +514,14 @@ func Parse(bStr string) (Baggage, error) {
return Baggage{}, nil
}
+ if n := len(bStr); n > maxBytesPerBaggageString {
+ return Baggage{}, fmt.Errorf("%w: %d", errBaggageBytes, n)
+ }
+
b := make(baggage.List)
sizes := make(map[string]int) // Track per-key byte sizes
var totalBytes int
+ var parseErrors int
var truncateErr error
for memberStr := range strings.SplitSeq(bStr, listDelimiter) {
// Check member count limit.
@@ -517,7 +532,10 @@ func Parse(bStr string) (Baggage, error) {
m, err := parseMember(memberStr)
if err != nil {
- truncateErr = errors.Join(truncateErr, err)
+ parseErrors++
+ if parseErrors <= maxParseErrors {
+ truncateErr = errors.Join(truncateErr, err)
+ }
continue // skip invalid member, keep processing
}
@@ -553,6 +571,10 @@ func Parse(bStr string) (Baggage, error) {
totalBytes = newTotalBytes
}
+ if dropped := parseErrors - maxParseErrors; dropped > 0 {
+ truncateErr = errors.Join(truncateErr, fmt.Errorf("and %d more invalid member(s)", dropped))
+ }
+
if len(b) == 0 {
return Baggage{}, truncateErr
}
diff --git a/vendor/go.opentelemetry.io/otel/dependencies.Dockerfile b/vendor/go.opentelemetry.io/otel/dependencies.Dockerfile
index 7a9b3c0559..74fa510bc8 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.6-slim-bullseye@sha256:e98b521460ee75bca92175c16247bdf7275637a8faaeb2bcfa19d879ae5c4b9a AS python
-FROM otel/weaver:v0.22.1@sha256:33ae522ae4b71c1c562563c1d81f46aa0f79f088a0873199143a1f11ac30e5c9 AS weaver
+FROM otel/weaver:v0.23.0@sha256:7984ecb55b859eb3034ae9d836c4eeda137e2bdd0873b7ba2bb6c3d24d6ff457 AS weaver
FROM avtodev/markdown-lint:v1@sha256:6aeedc2f49138ce7a1cd0adffc1b1c0321b841dc2102408967d9301c031949ee AS markdown
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 12e243e042..0d43a5dc5b 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
@@ -87,6 +87,16 @@ func Value(v attribute.Value) *commonpb.AnyValue {
av.Value = &commonpb.AnyValue_StringValue{
StringValue: v.AsString(),
}
+ case attribute.BYTESLICE:
+ av.Value = &commonpb.AnyValue_BytesValue{
+ BytesValue: v.AsByteSlice(),
+ }
+ case attribute.SLICE:
+ av.Value = &commonpb.AnyValue_ArrayValue{
+ ArrayValue: &commonpb.ArrayValue{
+ Values: values(v.AsSlice()),
+ },
+ }
case attribute.STRINGSLICE:
av.Value = &commonpb.AnyValue_ArrayValue{
ArrayValue: &commonpb.ArrayValue{
@@ -149,3 +159,11 @@ func stringSliceValues(vals []string) []*commonpb.AnyValue {
}
return converted
}
+
+func values(vals []attribute.Value) []*commonpb.AnyValue {
+ converted := make([]*commonpb.AnyValue, len(vals))
+ for i, v := range vals {
+ converted[i] = Value(v)
+ }
+ return converted
+}
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 258d0ca6a5..e8b33d3fa5 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
@@ -6,6 +6,7 @@ package otlptracegrpc // import "go.opentelemetry.io/otel/exporters/otlp/otlptra
import (
"context"
"errors"
+ "fmt"
"sync"
"time"
@@ -16,6 +17,7 @@ import (
"google.golang.org/grpc/codes"
"google.golang.org/grpc/metadata"
"google.golang.org/grpc/status"
+ "google.golang.org/protobuf/proto"
"go.opentelemetry.io/otel/exporters/otlp/otlptrace"
"go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc/internal"
@@ -26,11 +28,12 @@ import (
)
type client struct {
- endpoint string
- dialOpts []grpc.DialOption
- metadata metadata.MD
- exportTimeout time.Duration
- requestFunc retry.RequestFunc
+ endpoint string
+ dialOpts []grpc.DialOption
+ metadata metadata.MD
+ exportTimeout time.Duration
+ maxRequestSize int
+ requestFunc retry.RequestFunc
// stopCtx is used as a parent context for all exports. Therefore, when it
// is canceled with the stopFunc all exports are canceled.
@@ -65,14 +68,15 @@ func newClient(opts ...Option) *client {
ctx, cancel := context.WithCancel(context.Background()) //nolint:gosec // cancel called in client shutdown.
c := &client{
- endpoint: cfg.Traces.Endpoint,
- exportTimeout: cfg.Traces.Timeout,
- requestFunc: cfg.RetryConfig.RequestFunc(retryable),
- dialOpts: cfg.DialOptions,
- stopCtx: ctx,
- stopFunc: cancel,
- conn: cfg.GRPCConn,
- instID: counter.NextExporterID(),
+ endpoint: cfg.Traces.Endpoint,
+ exportTimeout: cfg.Traces.Timeout,
+ maxRequestSize: cfg.Traces.MaxRequestSize,
+ requestFunc: cfg.RetryConfig.RequestFunc(retryable),
+ dialOpts: cfg.DialOptions,
+ stopCtx: ctx,
+ stopFunc: cancel,
+ conn: cfg.GRPCConn,
+ instID: counter.NextExporterID(),
}
if len(cfg.Traces.Headers) > 0 {
@@ -205,16 +209,28 @@ func (c *client) UploadTraces(ctx context.Context, protoSpans []*tracepb.Resourc
ctx, cancel := c.exportContext(ctx)
defer cancel()
- var code codes.Code
+ pbRequest := &coltracepb.ExportTraceServiceRequest{
+ ResourceSpans: protoSpans,
+ }
+
+ code := codes.Unknown
if c.inst != nil {
- op := c.inst.ExportSpans(ctx, len(protoSpans))
+ var spanCount int
+ for _, rs := range protoSpans {
+ for _, ss := range rs.ScopeSpans {
+ spanCount += len(ss.Spans)
+ }
+ }
+ op := c.inst.ExportSpans(ctx, spanCount)
defer func() { op.End(uploadErr, code) }()
}
+ if maxSize := c.maxRequestSize; maxSize > 0 && proto.Size(pbRequest) > maxSize {
+ return fmt.Errorf("request message too large: exceeded %d bytes", maxSize)
+ }
+
return c.requestFunc(ctx, func(iCtx context.Context) error {
- resp, err := c.tsc.Export(iCtx, &coltracepb.ExportTraceServiceRequest{
- ResourceSpans: protoSpans,
- })
+ resp, err := c.tsc.Export(iCtx, pbRequest)
if resp != nil && resp.PartialSuccess != nil {
msg := resp.PartialSuccess.GetErrorMessage()
n := resp.PartialSuccess.GetRejectedSpans()
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
index a84733174e..676a93514b 100644
--- 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
@@ -18,8 +18,8 @@ import (
"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.40.0"
- "go.opentelemetry.io/otel/semconv/v1.40.0/otelconv"
+ semconv "go.opentelemetry.io/otel/semconv/v1.41.0"
+ "go.opentelemetry.io/otel/semconv/v1.41.0/otelconv"
)
const (
@@ -72,6 +72,7 @@ var (
func get[T any](p *sync.Pool) *[]T { return p.Get().(*[]T) }
func put[T any](p *sync.Pool, s *[]T) {
+ clear(*s) // erase elements to allow GC to collect what they refer to.
*s = (*s)[:0] // Reset.
p.Put(s)
}
@@ -339,7 +340,10 @@ var errPartialPool = &sync.Pool{
// the provided non-nil err.
func rejected(n int64, err error) int64 {
ps := errPartialPool.Get().(*internal.PartialSuccess)
- defer errPartialPool.Put(ps)
+ defer func() {
+ *ps = internal.PartialSuccess{} // erase fields to allow GC to collect them.
+ errPartialPool.Put(ps)
+ }()
// Check for partial success.
if errors.As(err, ps) {
// Bound RejectedItems to [0, n]. This should not be needed,
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 4f47117a58..d940b67625 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
@@ -31,6 +31,9 @@ const (
// DefaultTracesPath is a default URL path for endpoint that
// receives spans.
DefaultTracesPath string = "/v1/traces"
+ // DefaultMaxRequestSize is the default maximum size of a serialized export
+ // request, before compression.
+ DefaultMaxRequestSize int = 64 * 1024 * 1024
// DefaultTimeout is a default max waiting time for the backend to process
// each span batch.
DefaultTimeout time.Duration = 10 * time.Second
@@ -42,13 +45,14 @@ type (
HTTPTransportProxyFunc func(*http.Request) (*url.URL, error)
SignalConfig struct {
- Endpoint string
- Insecure bool
- TLSCfg *tls.Config
- Headers map[string]string
- Compression Compression
- Timeout time.Duration
- URLPath string
+ Endpoint string
+ Insecure bool
+ TLSCfg *tls.Config
+ Headers map[string]string
+ Compression Compression
+ MaxRequestSize int
+ Timeout time.Duration
+ URLPath string
// gRPC configurations
GRPCCredentials credentials.TransportCredentials
@@ -77,10 +81,11 @@ type (
func NewHTTPConfig(opts ...HTTPOption) Config {
cfg := Config{
Traces: SignalConfig{
- Endpoint: fmt.Sprintf("%s:%d", DefaultCollectorHost, DefaultCollectorHTTPPort),
- URLPath: DefaultTracesPath,
- Compression: NoCompression,
- Timeout: DefaultTimeout,
+ Endpoint: fmt.Sprintf("%s:%d", DefaultCollectorHost, DefaultCollectorHTTPPort),
+ URLPath: DefaultTracesPath,
+ Compression: NoCompression,
+ MaxRequestSize: DefaultMaxRequestSize,
+ Timeout: DefaultTimeout,
},
RetryConfig: retry.DefaultConfig,
}
@@ -111,10 +116,11 @@ func NewGRPCConfig(opts ...GRPCOption) Config {
userAgent := "OTel OTLP Exporter Go/" + otlptrace.Version()
cfg := Config{
Traces: SignalConfig{
- Endpoint: fmt.Sprintf("%s:%d", DefaultCollectorHost, DefaultCollectorGRPCPort),
- URLPath: DefaultTracesPath,
- Compression: NoCompression,
- Timeout: DefaultTimeout,
+ Endpoint: fmt.Sprintf("%s:%d", DefaultCollectorHost, DefaultCollectorGRPCPort),
+ URLPath: DefaultTracesPath,
+ Compression: NoCompression,
+ MaxRequestSize: DefaultMaxRequestSize,
+ Timeout: DefaultTimeout,
},
RetryConfig: retry.DefaultConfig,
DialOptions: []grpc.DialOption{grpc.WithUserAgent(userAgent)},
@@ -345,6 +351,13 @@ func WithTimeout(duration time.Duration) GenericOption {
})
}
+func WithMaxRequestSize(size int) GenericOption {
+ return newGenericOption(func(cfg Config) Config {
+ cfg.Traces.MaxRequestSize = size
+ return cfg
+ })
+}
+
func WithProxy(pf HTTPTransportProxyFunc) GenericOption {
return newGenericOption(func(cfg Config) Config {
cfg.Traces.Proxy = pf
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
index 7a1c420ecb..28e51e443f 100644
--- 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
@@ -5,4 +5,4 @@ package internal // import "go.opentelemetry.io/otel/exporters/otlp/otlptrace/ot
// Version is the current release version of the OpenTelemetry OTLP gRPC trace
// exporter in use.
-const Version = "1.43.0"
+const Version = "1.44.0"
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 2da2298701..b320060525 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
@@ -192,6 +192,16 @@ func WithTimeout(duration time.Duration) Option {
return wrappedOption{otlpconfig.WithTimeout(duration)}
}
+// WithMaxRequestSize sets the maximum size, in bytes, of a serialized export
+// request, before compression, that the exporter will send.
+//
+// If size is less than or equal to zero, no request-size limit is applied.
+// Disabling the limit is not recommended because it can lead to excessive
+// resource consumption or abuse.
+func WithMaxRequestSize(size int) Option {
+ return wrappedOption{otlpconfig.WithMaxRequestSize(size)}
+}
+
// WithRetry sets the retry policy for transient retryable errors that may be
// returned by the target endpoint when exporting a batch of spans.
//
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 087e95f7b8..d847210dba 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.43.0"
+ return "1.44.0"
}
diff --git a/vendor/go.opentelemetry.io/otel/metric/asyncfloat64.go b/vendor/go.opentelemetry.io/otel/metric/asyncfloat64.go
index 466812d343..1d21e2eb75 100644
--- a/vendor/go.opentelemetry.io/otel/metric/asyncfloat64.go
+++ b/vendor/go.opentelemetry.io/otel/metric/asyncfloat64.go
@@ -51,6 +51,9 @@ type Float64ObservableCounterConfig struct {
func NewFloat64ObservableCounterConfig(opts ...Float64ObservableCounterOption) Float64ObservableCounterConfig {
var config Float64ObservableCounterConfig
for _, o := range opts {
+ if _, ok := o.(experimentalOption); ok {
+ continue
+ }
config = o.applyFloat64ObservableCounter(config)
}
return config
@@ -111,6 +114,9 @@ func NewFloat64ObservableUpDownCounterConfig(
) Float64ObservableUpDownCounterConfig {
var config Float64ObservableUpDownCounterConfig
for _, o := range opts {
+ if _, ok := o.(experimentalOption); ok {
+ continue
+ }
config = o.applyFloat64ObservableUpDownCounter(config)
}
return config
@@ -168,6 +174,9 @@ type Float64ObservableGaugeConfig struct {
func NewFloat64ObservableGaugeConfig(opts ...Float64ObservableGaugeOption) Float64ObservableGaugeConfig {
var config Float64ObservableGaugeConfig
for _, o := range opts {
+ if _, ok := o.(experimentalOption); ok {
+ continue
+ }
config = o.applyFloat64ObservableGauge(config)
}
return config
diff --git a/vendor/go.opentelemetry.io/otel/metric/asyncint64.go b/vendor/go.opentelemetry.io/otel/metric/asyncint64.go
index 66c971bd8a..9d45a4d416 100644
--- a/vendor/go.opentelemetry.io/otel/metric/asyncint64.go
+++ b/vendor/go.opentelemetry.io/otel/metric/asyncint64.go
@@ -50,6 +50,9 @@ type Int64ObservableCounterConfig struct {
func NewInt64ObservableCounterConfig(opts ...Int64ObservableCounterOption) Int64ObservableCounterConfig {
var config Int64ObservableCounterConfig
for _, o := range opts {
+ if _, ok := o.(experimentalOption); ok {
+ continue
+ }
config = o.applyInt64ObservableCounter(config)
}
return config
@@ -110,6 +113,9 @@ func NewInt64ObservableUpDownCounterConfig(
) Int64ObservableUpDownCounterConfig {
var config Int64ObservableUpDownCounterConfig
for _, o := range opts {
+ if _, ok := o.(experimentalOption); ok {
+ continue
+ }
config = o.applyInt64ObservableUpDownCounter(config)
}
return config
@@ -167,6 +173,9 @@ type Int64ObservableGaugeConfig struct {
func NewInt64ObservableGaugeConfig(opts ...Int64ObservableGaugeOption) Int64ObservableGaugeConfig {
var config Int64ObservableGaugeConfig
for _, o := range opts {
+ if _, ok := o.(experimentalOption); ok {
+ continue
+ }
config = o.applyInt64ObservableGauge(config)
}
return config
diff --git a/vendor/go.opentelemetry.io/otel/metric/config.go b/vendor/go.opentelemetry.io/otel/metric/config.go
index e42dd6e70a..889545e235 100644
--- a/vendor/go.opentelemetry.io/otel/metric/config.go
+++ b/vendor/go.opentelemetry.io/otel/metric/config.go
@@ -42,11 +42,18 @@ type MeterOption interface {
applyMeter(MeterConfig) MeterConfig
}
+type experimentalOption interface {
+ Experimental()
+}
+
// NewMeterConfig creates a new MeterConfig and applies
// all the given options.
func NewMeterConfig(opts ...MeterOption) MeterConfig {
var config MeterConfig
for _, o := range opts {
+ if _, ok := o.(experimentalOption); ok {
+ continue
+ }
config = o.applyMeter(config)
}
return config
diff --git a/vendor/go.opentelemetry.io/otel/metric/doc.go b/vendor/go.opentelemetry.io/otel/metric/doc.go
index f153745b00..794e1a8bae 100644
--- a/vendor/go.opentelemetry.io/otel/metric/doc.go
+++ b/vendor/go.opentelemetry.io/otel/metric/doc.go
@@ -24,10 +24,10 @@ all instruments fall into two overlapping logical categories: asynchronous or
synchronous, and int64 or float64.
All synchronous instruments ([Int64Counter], [Int64UpDownCounter],
-[Int64Histogram], [Float64Counter], [Float64UpDownCounter], and
-[Float64Histogram]) are used to measure the operation and performance of source
-code during the source code execution. These instruments only make measurements
-when the source code they instrument is run.
+[Int64Histogram], [Int64Gauge], [Float64Counter], [Float64UpDownCounter],
+[Float64Histogram], and [Float64Gauge]) are used to measure the operation and
+performance of source code during the source code execution. These instruments
+only make measurements when the source code they instrument is run.
All asynchronous instruments ([Int64ObservableCounter],
[Int64ObservableUpDownCounter], [Int64ObservableGauge],
@@ -50,9 +50,11 @@ incrementally increase in value. UpDownCounters ([Int64UpDownCounter],
values that can increase and decrease. When more information needs to be
conveyed about all the synchronous measurements made during a collection cycle,
a Histogram ([Int64Histogram] and [Float64Histogram]) should be used. Finally,
-when just the most recent measurement needs to be conveyed about an
-asynchronous measurement, a Gauge ([Int64ObservableGauge] and
-[Float64ObservableGauge]) should be used.
+when just the most recent measurement needs to be conveyed, a Gauge
+([Int64Gauge], [Float64Gauge], [Int64ObservableGauge], and
+[Float64ObservableGauge]) should be used: the synchronous variants record an
+instantaneous value at a specific point in code, while the observable variants
+sample the value via a callback once per collection cycle.
See the [OpenTelemetry documentation] for more information about instruments
and their intended use.
@@ -80,11 +82,11 @@ Measurements are made by recording values and information about the values with
an instrument. How these measurements are recorded depends on the instrument.
Measurements for synchronous instruments ([Int64Counter], [Int64UpDownCounter],
-[Int64Histogram], [Float64Counter], [Float64UpDownCounter], and
-[Float64Histogram]) are recorded using the instrument methods directly. All
-counter instruments have an Add method that is used to measure an increment
-value, and all histogram instruments have a Record method to measure a data
-point.
+[Int64Histogram], [Int64Gauge], [Float64Counter], [Float64UpDownCounter],
+[Float64Histogram], and [Float64Gauge]) are recorded using the instrument
+methods directly. All counter instruments have an Add method that is used to
+measure an increment value, and all histogram and synchronous gauge
+instruments have a Record method to measure a data point.
Asynchronous instruments ([Int64ObservableCounter],
[Int64ObservableUpDownCounter], [Int64ObservableGauge],
@@ -107,6 +109,31 @@ respectively):
If the criteria are not met, use the RegisterCallback method of the [Meter] that
created the instrument to register a [Callback].
+# Avoiding Expensive Computations
+
+All synchronous instruments provide an Enabled method that reports whether the
+instrument will process measurements for the given context. When no SDK is
+registered or the instrument is otherwise disabled, Enabled returns false. This
+can be used to avoid expensive measurement work when a measurement will not be
+recorded:
+
+ if counter.Enabled(ctx) {
+ counter.Add(ctx, 1, metric.WithAttributes(expensiveAttributes()...))
+ }
+
+This is especially valuable when computing attributes is expensive.
+[WithAttributes] performs non-trivial work on every call to build an
+[attribute.Set] from the provided attributes, and that work is wasted if the
+measurement is not recorded.
+
+For performance sensitive code where the same attribute set is used repeatedly,
+prefer [WithAttributeSet]. It accepts a pre-built [attribute.Set], letting you
+pay the construction cost once and reuse it across many measurements:
+
+ attrs := attribute.NewSet(attribute.String("key", "val"))
+ // ... later, on each call:
+ counter.Add(ctx, 1, metric.WithAttributeSet(attrs))
+
# API Implementations
This package does not conform to the standard Go versioning policy, all of its
diff --git a/vendor/go.opentelemetry.io/otel/metric/instrument.go b/vendor/go.opentelemetry.io/otel/metric/instrument.go
index 9f48d5f117..2e79ab5683 100644
--- a/vendor/go.opentelemetry.io/otel/metric/instrument.go
+++ b/vendor/go.opentelemetry.io/otel/metric/instrument.go
@@ -3,7 +3,9 @@
package metric // import "go.opentelemetry.io/otel/metric"
-import "go.opentelemetry.io/otel/attribute"
+import (
+ "go.opentelemetry.io/otel/attribute"
+)
// Observable is used as a grouping mechanism for all instruments that are
// updated within a Callback.
@@ -228,6 +230,9 @@ type AddConfig struct {
func NewAddConfig(opts []AddOption) AddConfig {
config := AddConfig{attrs: *attribute.EmptySet()}
for _, o := range opts {
+ if _, ok := o.(experimentalOption); ok {
+ continue
+ }
config = o.applyAdd(config)
}
return config
@@ -253,6 +258,9 @@ type RecordConfig struct {
func NewRecordConfig(opts []RecordOption) RecordConfig {
config := RecordConfig{attrs: *attribute.EmptySet()}
for _, o := range opts {
+ if _, ok := o.(experimentalOption); ok {
+ continue
+ }
config = o.applyRecord(config)
}
return config
@@ -278,6 +286,9 @@ type ObserveConfig struct {
func NewObserveConfig(opts []ObserveOption) ObserveConfig {
config := ObserveConfig{attrs: *attribute.EmptySet()}
for _, o := range opts {
+ if _, ok := o.(experimentalOption); ok {
+ continue
+ }
config = o.applyObserve(config)
}
return config
@@ -299,6 +310,10 @@ type attrOpt struct {
set attribute.Set
}
+func (o *attrOpt) Set(set attribute.Set) {
+ o.set = set
+}
+
// mergeSets returns the union of keys between a and b. Any duplicate keys will
// use the value associated with b.
func mergeSets(a, b attribute.Set) attribute.Set {
@@ -311,7 +326,7 @@ func mergeSets(a, b attribute.Set) attribute.Set {
return attribute.NewSet(merged...)
}
-func (o attrOpt) applyAdd(c AddConfig) AddConfig {
+func (o *attrOpt) applyAdd(c AddConfig) AddConfig {
switch {
case o.set.Len() == 0:
case c.attrs.Len() == 0:
@@ -322,7 +337,7 @@ func (o attrOpt) applyAdd(c AddConfig) AddConfig {
return c
}
-func (o attrOpt) applyRecord(c RecordConfig) RecordConfig {
+func (o *attrOpt) applyRecord(c RecordConfig) RecordConfig {
switch {
case o.set.Len() == 0:
case c.attrs.Len() == 0:
@@ -333,7 +348,7 @@ func (o attrOpt) applyRecord(c RecordConfig) RecordConfig {
return c
}
-func (o attrOpt) applyObserve(c ObserveConfig) ObserveConfig {
+func (o *attrOpt) applyObserve(c ObserveConfig) ObserveConfig {
switch {
case o.set.Len() == 0:
case c.attrs.Len() == 0:
@@ -350,8 +365,14 @@ func (o attrOpt) applyObserve(c ObserveConfig) ObserveConfig {
// If multiple WithAttributeSet or WithAttributes 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.
+//
+// Experimental: The returned option may implement
+// [go.opentelemetry.io/otel/metric/x.Settable][attribute.Set], which can be
+// used to replace the option's attribute set and reuse the option without
+// additional allocations. This behavior is experimental and may be changed or
+// removed in a future release without notice.
func WithAttributeSet(attributes attribute.Set) MeasurementOption {
- return attrOpt{set: attributes}
+ return &attrOpt{set: attributes}
}
// WithAttributes converts attributes into an attribute Set and sets the Set to
@@ -369,8 +390,14 @@ func WithAttributeSet(attributes attribute.Set) MeasurementOption {
//
// See [WithAttributeSet] for information about how multiple WithAttributes are
// merged.
+//
+// Experimental: The returned option may implement
+// [go.opentelemetry.io/otel/metric/x.Settable][[]attribute.KeyValue], which can be
+// used to replace the option's attributes and reuse the option without
+// additional allocations. This behavior is experimental and may be changed or
+// removed in a future release without notice.
func WithAttributes(attributes ...attribute.KeyValue) MeasurementOption {
cp := make([]attribute.KeyValue, len(attributes))
copy(cp, attributes)
- return attrOpt{set: attribute.NewSet(cp...)}
+ return &attrOpt{set: attribute.NewSet(cp...)}
}
diff --git a/vendor/go.opentelemetry.io/otel/metric/syncfloat64.go b/vendor/go.opentelemetry.io/otel/metric/syncfloat64.go
index abb3051d7f..2101f686ae 100644
--- a/vendor/go.opentelemetry.io/otel/metric/syncfloat64.go
+++ b/vendor/go.opentelemetry.io/otel/metric/syncfloat64.go
@@ -51,6 +51,9 @@ type Float64CounterConfig struct {
func NewFloat64CounterConfig(opts ...Float64CounterOption) Float64CounterConfig {
var config Float64CounterConfig
for _, o := range opts {
+ if _, ok := o.(experimentalOption); ok {
+ continue
+ }
config = o.applyFloat64Counter(config)
}
return config
@@ -116,6 +119,9 @@ type Float64UpDownCounterConfig struct {
func NewFloat64UpDownCounterConfig(opts ...Float64UpDownCounterOption) Float64UpDownCounterConfig {
var config Float64UpDownCounterConfig
for _, o := range opts {
+ if _, ok := o.(experimentalOption); ok {
+ continue
+ }
config = o.applyFloat64UpDownCounter(config)
}
return config
@@ -182,6 +188,9 @@ type Float64HistogramConfig struct {
func NewFloat64HistogramConfig(opts ...Float64HistogramOption) Float64HistogramConfig {
var config Float64HistogramConfig
for _, o := range opts {
+ if _, ok := o.(experimentalOption); ok {
+ continue
+ }
config = o.applyFloat64Histogram(config)
}
return config
@@ -251,6 +260,9 @@ type Float64GaugeConfig struct {
func NewFloat64GaugeConfig(opts ...Float64GaugeOption) Float64GaugeConfig {
var config Float64GaugeConfig
for _, o := range opts {
+ if _, ok := o.(experimentalOption); ok {
+ continue
+ }
config = o.applyFloat64Gauge(config)
}
return config
diff --git a/vendor/go.opentelemetry.io/otel/metric/syncint64.go b/vendor/go.opentelemetry.io/otel/metric/syncint64.go
index 5bbfaf0397..425c1a0d51 100644
--- a/vendor/go.opentelemetry.io/otel/metric/syncint64.go
+++ b/vendor/go.opentelemetry.io/otel/metric/syncint64.go
@@ -51,6 +51,9 @@ type Int64CounterConfig struct {
func NewInt64CounterConfig(opts ...Int64CounterOption) Int64CounterConfig {
var config Int64CounterConfig
for _, o := range opts {
+ if _, ok := o.(experimentalOption); ok {
+ continue
+ }
config = o.applyInt64Counter(config)
}
return config
@@ -116,6 +119,9 @@ type Int64UpDownCounterConfig struct {
func NewInt64UpDownCounterConfig(opts ...Int64UpDownCounterOption) Int64UpDownCounterConfig {
var config Int64UpDownCounterConfig
for _, o := range opts {
+ if _, ok := o.(experimentalOption); ok {
+ continue
+ }
config = o.applyInt64UpDownCounter(config)
}
return config
@@ -182,6 +188,9 @@ type Int64HistogramConfig struct {
func NewInt64HistogramConfig(opts ...Int64HistogramOption) Int64HistogramConfig {
var config Int64HistogramConfig
for _, o := range opts {
+ if _, ok := o.(experimentalOption); ok {
+ continue
+ }
config = o.applyInt64Histogram(config)
}
return config
@@ -251,6 +260,9 @@ type Int64GaugeConfig struct {
func NewInt64GaugeConfig(opts ...Int64GaugeOption) Int64GaugeConfig {
var config Int64GaugeConfig
for _, o := range opts {
+ if _, ok := o.(experimentalOption); ok {
+ continue
+ }
config = o.applyInt64Gauge(config)
}
return config
diff --git a/vendor/go.opentelemetry.io/otel/propagation/baggage.go b/vendor/go.opentelemetry.io/otel/propagation/baggage.go
index 2ecca3fed1..d81b709a2c 100644
--- a/vendor/go.opentelemetry.io/otel/propagation/baggage.go
+++ b/vendor/go.opentelemetry.io/otel/propagation/baggage.go
@@ -5,6 +5,9 @@ package propagation // import "go.opentelemetry.io/otel/propagation"
import (
"context"
+ "errors"
+ "fmt"
+ "sync"
"go.opentelemetry.io/otel/baggage"
"go.opentelemetry.io/otel/internal/errorhandler"
@@ -13,11 +16,18 @@ import (
const (
baggageHeader = "baggage"
+ maxParseErrors = 5
+
// W3C Baggage specification limits.
// https://www.w3.org/TR/baggage/#limits
- maxMembers = 64
+ maxMembers = 64
+ maxBytesPerBaggageString = 8192
)
+// handleExtractErrOnce limits error reporting for attacker-controlled baggage headers
+// to one process-wide emission, preventing repeated extraction from flooding logs.
+var handleExtractErrOnce sync.Once
+
// Baggage is a propagator that supports the W3C Baggage format.
//
// This propagates user-defined baggage associated with a trace. The complete
@@ -57,7 +67,9 @@ func extractSingleBaggage(parent context.Context, carrier TextMapCarrier) contex
bag, err := baggage.Parse(bStr)
if err != nil {
- errorhandler.GetErrorHandler().Handle(err)
+ handleExtractErrOnce.Do(func() {
+ errorhandler.GetErrorHandler().Handle(err)
+ })
}
if bag.Len() == 0 {
return parent
@@ -72,24 +84,60 @@ func extractMultiBaggage(parent context.Context, carrier ValuesGetter) context.C
}
var members []baggage.Member
- for _, bStr := range bVals {
- currBag, err := baggage.Parse(bStr)
- if err != nil {
- errorhandler.GetErrorHandler().Handle(err)
+ var totalBytes int
+ var parseErrors int
+ var truncateErr error
+ for i, bStr := range bVals {
+ if i > 0 {
+ totalBytes++ // comma separator between combined header values
}
- if currBag.Len() == 0 {
- continue
+ totalBytes += len(bStr)
+ if totalBytes > maxBytesPerBaggageString {
+ // Per the W3C Baggage spec, the byte limit applies to the
+ // combination of all baggage headers, not each header
+ // individually. Mirror the single-header behavior of
+ // reporting the error and returning the parent context
+ // with no baggage attached.
+ handleExtractErrOnce.Do(func() {
+ errorhandler.GetErrorHandler().Handle(fmt.Errorf(
+ "baggage: aggregate header size %d exceeds %d byte limit",
+ totalBytes,
+ maxBytesPerBaggageString,
+ ))
+ })
+ return parent
}
- members = append(members, currBag.Members()...)
- if len(members) >= maxMembers {
- break
+
+ // If members exceed the limit, stop parsing baggage.
+ if len(members) <= maxMembers {
+ currBag, err := baggage.Parse(bStr)
+ if err != nil {
+ parseErrors++
+ if parseErrors <= maxParseErrors {
+ truncateErr = errors.Join(truncateErr, err)
+ }
+ }
+ if currBag.Len() == 0 {
+ continue
+ }
+ members = append(members, currBag.Members()...)
}
}
+ if dropped := parseErrors - maxParseErrors; dropped > 0 {
+ truncateErr = errors.Join(truncateErr, fmt.Errorf("and %d more error(s)", dropped))
+ }
+
b, err := baggage.New(members...)
if err != nil {
- errorhandler.GetErrorHandler().Handle(err)
+ truncateErr = errors.Join(truncateErr, err)
}
+ if truncateErr != nil {
+ handleExtractErrOnce.Do(func() {
+ errorhandler.GetErrorHandler().Handle(truncateErr)
+ })
+ }
+
if b.Len() == 0 {
return parent
}
diff --git a/vendor/go.opentelemetry.io/otel/sdk/resource/builtin.go b/vendor/go.opentelemetry.io/otel/sdk/resource/builtin.go
index 04f15fcd21..28823edd53 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.40.0"
+ semconv "go.opentelemetry.io/otel/semconv/v1.41.0"
)
type (
@@ -79,7 +79,7 @@ func (sd stringDetector) Detect(context.Context) (*Resource, error) {
}
a := sd.K.String(value)
if !a.Valid() {
- return nil, fmt.Errorf("invalid attribute: %q -> %q", a.Key, a.Value.Emit())
+ return nil, fmt.Errorf("invalid attribute: %q -> %q", a.Key, a.Value.String())
}
return NewWithAttributes(sd.schemaURL, sd.K.String(value)), nil
}
diff --git a/vendor/go.opentelemetry.io/otel/sdk/resource/container.go b/vendor/go.opentelemetry.io/otel/sdk/resource/container.go
index e977ff1c48..ce03e24c41 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.40.0"
+ semconv "go.opentelemetry.io/otel/semconv/v1.41.0"
)
type containerIDProvider func() (string, error)
diff --git a/vendor/go.opentelemetry.io/otel/sdk/resource/env.go b/vendor/go.opentelemetry.io/otel/sdk/resource/env.go
index bc0e5c19e3..ac5691c08d 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.40.0"
+ semconv "go.opentelemetry.io/otel/semconv/v1.41.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 755c082427..cb38fa1a8b 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.40.0"
+ semconv "go.opentelemetry.io/otel/semconv/v1.41.0"
)
type hostIDProvider func() (string, error)
diff --git a/vendor/go.opentelemetry.io/otel/sdk/resource/host_id_exec.go b/vendor/go.opentelemetry.io/otel/sdk/resource/host_id_exec.go
index d9e5d1a8ff..e239ead028 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/resource/host_id_exec.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/resource/host_id_exec.go
@@ -5,10 +5,13 @@
package resource // import "go.opentelemetry.io/otel/sdk/resource"
-import "os/exec"
+import (
+ "context"
+ "os/exec"
+)
func execCommand(name string, arg ...string) (string, error) {
- cmd := exec.Command(name, arg...)
+ cmd := exec.CommandContext(context.Background(), name, arg...)
b, err := cmd.Output()
if err != nil {
return "", err
diff --git a/vendor/go.opentelemetry.io/otel/sdk/resource/os.go b/vendor/go.opentelemetry.io/otel/sdk/resource/os.go
index f5682cad41..4c0def4148 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.40.0"
+ semconv "go.opentelemetry.io/otel/semconv/v1.41.0"
)
type osDescriptionProvider func() (string, error)
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 6c50ab6867..1cd87c3983 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/resource/os_unix.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/resource/os_unix.go
@@ -55,7 +55,8 @@ func uname() (string, error) {
return "", err
}
- return fmt.Sprintf("%s %s %s %s %s",
+ return fmt.Sprintf(
+ "%s %s %s %s %s",
unix.ByteSliceToString(utsName.Sysname[:]),
unix.ByteSliceToString(utsName.Nodename[:]),
unix.ByteSliceToString(utsName.Release[:]),
diff --git a/vendor/go.opentelemetry.io/otel/sdk/resource/os_windows.go b/vendor/go.opentelemetry.io/otel/sdk/resource/os_windows.go
index a6a5a53c0e..ebd50826d6 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/resource/os_windows.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/resource/os_windows.go
@@ -16,7 +16,8 @@ import (
// resembles the one displayed by the Version Reporter Applet (winver.exe).
func platformOSDescription() (string, error) {
k, err := registry.OpenKey(
- registry.LOCAL_MACHINE, `SOFTWARE\Microsoft\Windows NT\CurrentVersion`, registry.QUERY_VALUE)
+ registry.LOCAL_MACHINE, `SOFTWARE\Microsoft\Windows NT\CurrentVersion`, registry.QUERY_VALUE,
+ )
if err != nil {
return "", err
}
@@ -37,7 +38,8 @@ func platformOSDescription() (string, error) {
displayVersion += " "
}
- return fmt.Sprintf("%s %s(%s) [Version %s.%s.%s.%s]",
+ return fmt.Sprintf(
+ "%s %s(%s) [Version %s.%s.%s.%s]",
productName,
displayVersion,
releaseID,
diff --git a/vendor/go.opentelemetry.io/otel/sdk/resource/process.go b/vendor/go.opentelemetry.io/otel/sdk/resource/process.go
index 99dce64f6d..b015f8233c 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.40.0"
+ semconv "go.opentelemetry.io/otel/semconv/v1.41.0"
)
type (
@@ -164,7 +164,8 @@ func (processRuntimeVersionDetector) Detect(context.Context) (*Resource, error)
// Detect returns a *Resource that describes the runtime of this process.
func (processRuntimeDescriptionDetector) Detect(context.Context) (*Resource, error) {
runtimeDescription := fmt.Sprintf(
- "go version %s %s/%s", runtimeVersion(), runtimeOS(), runtimeArch())
+ "go version %s %s/%s", runtimeVersion(), runtimeOS(), runtimeArch(),
+ )
return NewWithAttributes(
semconv.SchemaURL,
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 32854b14a3..f9f2a6c2c8 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
@@ -163,19 +163,21 @@ func (bsp *batchSpanProcessor) Shutdown(ctx context.Context) error {
bsp.stopOnce.Do(func() {
bsp.stopped.Store(true)
wait := make(chan struct{})
+ // exportErr is written by the goroutine before closing wait.
+ // It is only read in the <-wait case, so there is no race.
+ var exportErr error
go func() {
close(bsp.stopCh)
bsp.stopWait.Wait()
if bsp.e != nil {
- if err := bsp.e.Shutdown(ctx); err != nil {
- otel.Handle(err)
- }
+ exportErr = bsp.e.Shutdown(ctx)
}
close(wait)
}()
- // Wait until the wait group is done or the context is cancelled
+ // Wait until the channel is ready or the context is canceled.
select {
case <-wait:
+ err = exportErr
case <-ctx.Done():
err = ctx.Err()
}
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
index c31e03aa0a..c725ebf372 100644
--- 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
@@ -13,8 +13,8 @@ import (
"go.opentelemetry.io/otel/metric"
"go.opentelemetry.io/otel/sdk"
"go.opentelemetry.io/otel/sdk/internal/x"
- semconv "go.opentelemetry.io/otel/semconv/v1.40.0"
- "go.opentelemetry.io/otel/semconv/v1.40.0/otelconv"
+ semconv "go.opentelemetry.io/otel/semconv/v1.41.0"
+ "go.opentelemetry.io/otel/semconv/v1.41.0/otelconv"
)
const (
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
index 0e77cd9537..cf4b5d481f 100644
--- 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
@@ -13,8 +13,8 @@ import (
"go.opentelemetry.io/otel/metric"
"go.opentelemetry.io/otel/sdk"
"go.opentelemetry.io/otel/sdk/internal/x"
- semconv "go.opentelemetry.io/otel/semconv/v1.40.0"
- "go.opentelemetry.io/otel/semconv/v1.40.0/otelconv"
+ semconv "go.opentelemetry.io/otel/semconv/v1.41.0"
+ "go.opentelemetry.io/otel/semconv/v1.41.0/otelconv"
)
var measureAttrsPool = sync.Pool{
@@ -86,6 +86,7 @@ func (ssp *SSP) addOption(err error) []metric.AddOption {
}
attrs := measureAttrsPool.Get().(*[]attribute.KeyValue)
defer func() {
+ clear(*attrs)
*attrs = (*attrs)[:0] // reset the slice for reuse
measureAttrsPool.Put(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
index 560d316f2f..5aae89e883 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/trace/internal/observ/tracer.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/trace/internal/observ/tracer.go
@@ -13,7 +13,7 @@ import (
"go.opentelemetry.io/otel/metric"
"go.opentelemetry.io/otel/sdk"
"go.opentelemetry.io/otel/sdk/internal/x"
- "go.opentelemetry.io/otel/semconv/v1.40.0/otelconv"
+ "go.opentelemetry.io/otel/semconv/v1.41.0/otelconv"
"go.opentelemetry.io/otel/trace"
)
diff --git a/vendor/go.opentelemetry.io/otel/sdk/trace/provider.go b/vendor/go.opentelemetry.io/otel/sdk/trace/provider.go
index cd40d299d6..9d90c2eda5 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/trace/provider.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/trace/provider.go
@@ -82,6 +82,10 @@ type TracerProvider struct {
var _ trace.TracerProvider = &TracerProvider{}
+type experimentalOption interface {
+ Experimental()
+}
+
// NewTracerProvider returns a new and configured TracerProvider.
//
// By default the returned TracerProvider is configured with:
@@ -99,6 +103,9 @@ func NewTracerProvider(opts ...TracerProviderOption) *TracerProvider {
o = applyTracerProviderEnvConfigs(o)
for _, opt := range opts {
+ if _, ok := opt.(experimentalOption); ok {
+ continue
+ }
o = opt.apply(o)
}
@@ -310,7 +317,7 @@ func (p *TracerProvider) Shutdown(ctx context.Context) error {
}
func (p *TracerProvider) getSpanProcessors() spanProcessorStates {
- return *(p.spanProcessors.Load())
+ return *p.spanProcessors.Load()
}
// TracerProviderOption configures a TracerProvider.
diff --git a/vendor/go.opentelemetry.io/otel/sdk/trace/sampling.go b/vendor/go.opentelemetry.io/otel/sdk/trace/sampling.go
index 845e292c2b..5a4c74318b 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/trace/sampling.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/trace/sampling.go
@@ -297,8 +297,9 @@ func (pb parentBased) ShouldSample(p SamplingParameters) SamplingResult {
}
func (pb parentBased) Description() string {
- return fmt.Sprintf("ParentBased{root:%s,remoteParentSampled:%s,"+
- "remoteParentNotSampled:%s,localParentSampled:%s,localParentNotSampled:%s}",
+ return fmt.Sprintf(
+ "ParentBased{root:%s,remoteParentSampled:%s,"+
+ "remoteParentNotSampled:%s,localParentSampled:%s,localParentNotSampled:%s}",
pb.root.Description(),
pb.config.remoteParentSampled.Description(),
pb.config.remoteParentNotSampled.Description(),
diff --git a/vendor/go.opentelemetry.io/otel/sdk/trace/span.go b/vendor/go.opentelemetry.io/otel/sdk/trace/span.go
index 7d55ce1dc2..d1d9af29d7 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.40.0"
+ semconv "go.opentelemetry.io/otel/semconv/v1.41.0"
"go.opentelemetry.io/otel/trace"
"go.opentelemetry.io/otel/trace/embedded"
)
@@ -346,10 +346,12 @@ func (s *recordingSpan) addOverCapAttrs(limit int, attrs []attribute.KeyValue) {
}
}
-// truncateAttr returns a truncated version of attr. Only string and string
-// slice attribute values are truncated. String values are truncated to at
-// most a length of limit. Each string slice value is truncated in this fashion
-// (the slice length itself is unaffected).
+// truncateAttr returns a truncated version of attr. Only string, string
+// slice, byte slice, and slice attribute values are truncated. String values are truncated
+// to at most a length of limit. Each string slice value is truncated in this
+// fashion (the slice length itself is unaffected), and byte slice values are truncated to at most
+// limit bytes. For slice attribute values, the limit is applied to each
+// element recursively.
//
// No truncation is performed for a negative limit.
func truncateAttr(limit int, attr attribute.KeyValue) attribute.KeyValue {
@@ -366,10 +368,95 @@ func truncateAttr(limit int, attr attribute.KeyValue) attribute.KeyValue {
v[i] = truncate(limit, v[i])
}
return attr.Key.StringSlice(v)
+ case attribute.BYTESLICE:
+ v := attr.Value.AsString()
+ if len(v) > limit {
+ return attr.Key.ByteSlice([]byte(v[:limit]))
+ }
+ return attr
+ case attribute.SLICE:
+ v := attr.Value.AsSlice()
+ if !slices.ContainsFunc(v, func(e attribute.Value) bool { return needsTruncation(limit, e) }) {
+ return attr
+ }
+ newV := make([]attribute.Value, len(v))
+ for i, elem := range v {
+ newV[i] = truncateValue(limit, elem)
+ }
+ return attr.Key.Slice(newV...)
}
return attr
}
+// truncateValue returns a truncated version of v. Only string, string slice,
+// byte slice, and (recursively) slice values are modified.
+//
+// No truncation is performed for a negative limit.
+func truncateValue(limit int, v attribute.Value) attribute.Value {
+ switch v.Type() {
+ case attribute.STRING:
+ return attribute.StringValue(truncate(limit, v.AsString()))
+ case attribute.STRINGSLICE:
+ ss := v.AsStringSlice()
+ for i := range ss {
+ ss[i] = truncate(limit, ss[i])
+ }
+ return attribute.StringSliceValue(ss)
+
+ case attribute.BYTESLICE:
+ // len(v.AsString()) is identical to len(v.AsByteSlice()) but
+ // avoids allocating the full slice before truncation.
+ s := v.AsString()
+ if limit >= 0 && len(s) > limit {
+ return attribute.ByteSliceValue([]byte(s[:limit]))
+ }
+ case attribute.SLICE:
+ sl := v.AsSlice()
+ if !slices.ContainsFunc(sl, func(e attribute.Value) bool { return needsTruncation(limit, e) }) {
+ return v
+ }
+ newSl := make([]attribute.Value, len(sl))
+ for i, elem := range sl {
+ newSl[i] = truncateValue(limit, elem)
+ }
+ return attribute.SliceValue(newSl...)
+ }
+ return v
+}
+
+// stringNeedsTruncation reports whether s would be modified by truncate for the
+// given limit.
+func stringNeedsTruncation(limit int, s string) bool {
+ if limit < 0 || len(s) <= limit {
+ return false
+ }
+ return utf8.RuneCountInString(s) > limit || !utf8.ValidString(s)
+}
+
+// needsTruncation reports whether v would be modified by truncateValue for the
+// given limit.
+func needsTruncation(limit int, v attribute.Value) bool {
+ switch v.Type() {
+ case attribute.STRING:
+ return stringNeedsTruncation(limit, v.AsString())
+ case attribute.BYTESLICE:
+ // len(v.AsString()) is identical to len(v.AsByteSlice()) but
+ // avoids memory allocation.
+ if limit >= 0 && len(v.AsString()) > limit {
+ return true
+ }
+ case attribute.STRINGSLICE:
+ for _, s := range v.AsStringSlice() {
+ if stringNeedsTruncation(limit, s) {
+ return true
+ }
+ }
+ case attribute.SLICE:
+ return slices.ContainsFunc(v.AsSlice(), func(e attribute.Value) bool { return needsTruncation(limit, e) })
+ }
+ return false
+}
+
// truncate returns a truncated version of s such that it contains less than
// the limit number of characters. Truncation is applied by returning the limit
// number of valid characters contained in s.
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 321d974305..348ee0e808 100644
--- a/vendor/go.opentelemetry.io/otel/sdk/trace/span_limits.go
+++ b/vendor/go.opentelemetry.io/otel/sdk/trace/span_limits.go
@@ -35,8 +35,10 @@ const (
type SpanLimits struct {
// AttributeValueLengthLimit is the maximum allowed attribute value length.
//
- // This limit only applies to string and string slice attribute values.
- // Any string longer than this value will be truncated to this length.
+ // This limit only applies to string, string slice, byte slice, and slice attribute
+ // values. Any string and byte slice longer than this value will be truncated to this
+ // length. For slice attribute values, the limit is applied to each string and byte slice
+ // element recursively.
//
// Setting this to a negative value means no limit is applied.
AttributeValueLengthLimit int
diff --git a/vendor/go.opentelemetry.io/otel/sdk/version.go b/vendor/go.opentelemetry.io/otel/sdk/version.go
index 766731dd25..218dce1f56 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.43.0"
+ return "1.44.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
index b6b27498f2..2fcab24352 100644
--- 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
@@ -1447,9 +1447,11 @@ func AWSExtendedRequestID(val string) attribute.KeyValue {
// 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.
+//
+// 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)
@@ -1459,7 +1461,8 @@ func AWSKinesisStreamName(val string) attribute.KeyValue {
// "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).
+//
+// applicable).
func AWSLambdaInvokedARN(val string) attribute.KeyValue {
return AWSLambdaInvokedARNKey.String(val)
}
@@ -2635,7 +2638,8 @@ func CloudRegion(val string) attribute.KeyValue {
// "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).
+//
+// 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
@@ -15190,4 +15194,4 @@ func ZOSSmfID(val string) attribute.KeyValue {
// 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.39.0/attribute_group.go b/vendor/go.opentelemetry.io/otel/semconv/v1.39.0/attribute_group.go
index 080365fc19..dfcee964a6 100644
--- 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
@@ -1493,9 +1493,11 @@ func AWSExtendedRequestID(val string) attribute.KeyValue {
// 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.
+//
+// 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)
@@ -1505,7 +1507,8 @@ func AWSKinesisStreamName(val string) attribute.KeyValue {
// "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).
+//
+// applicable).
func AWSLambdaInvokedARN(val string) attribute.KeyValue {
return AWSLambdaInvokedARNKey.String(val)
}
@@ -2681,7 +2684,8 @@ func CloudRegion(val string) attribute.KeyValue {
// "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).
+//
+// 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
@@ -16236,4 +16240,4 @@ func ZOSSmfID(val string) attribute.KeyValue {
// 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.39.0/httpconv/metric.go b/vendor/go.opentelemetry.io/otel/semconv/v1.39.0/httpconv/metric.go
index d6ad8735a9..fa67d19717 100644
--- a/vendor/go.opentelemetry.io/otel/semconv/v1.39.0/httpconv/metric.go
+++ b/vendor/go.opentelemetry.io/otel/semconv/v1.39.0/httpconv/metric.go
@@ -26,11 +26,9 @@ var (
// with.
type ErrorTypeAttr string
-var (
- // ErrorTypeOther is a fallback error value to be used when the instrumentation
- // doesn't define a custom value.
- ErrorTypeOther ErrorTypeAttr = "_OTHER"
-)
+// ErrorTypeOther is a fallback error value to be used when the instrumentation
+// doesn't define a custom value.
+var ErrorTypeOther ErrorTypeAttr = "_OTHER"
// ConnectionStateAttr is an attribute conforming to the http.connection.state
// semantic conventions. It represents the state of the HTTP connection in the
@@ -1264,13 +1262,12 @@ func (ServerRequestBodySize) Description() string {
//
// All additional attrs passed are included in the recorded value.
//
-// [URI scheme]: https://www.rfc-editor.org/rfc/rfc3986#section-3.1
-//
// 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.
//
+// [URI scheme]: https://www.rfc-editor.org/rfc/rfc3986#section-3.1
// [Content-Length]: https://www.rfc-editor.org/rfc/rfc9110.html#field.content-length
func (m ServerRequestBodySize) Record(
ctx context.Context,
@@ -1638,13 +1635,12 @@ func (ServerResponseBodySize) Description() string {
//
// All additional attrs passed are included in the recorded value.
//
-// [URI scheme]: https://www.rfc-editor.org/rfc/rfc3986#section-3.1
-//
// 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.
//
+// [URI scheme]: https://www.rfc-editor.org/rfc/rfc3986#section-3.1
// [Content-Length]: https://www.rfc-editor.org/rfc/rfc9110.html#field.content-length
func (m ServerResponseBodySize) Record(
ctx context.Context,
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.40.0/README.md b/vendor/go.opentelemetry.io/otel/semconv/v1.40.0/README.md
deleted file mode 100644
index c51b7fb7b0..0000000000
--- a/vendor/go.opentelemetry.io/otel/semconv/v1.40.0/README.md
+++ /dev/null
@@ -1,3 +0,0 @@
-# Semconv v1.40.0
-
-[](https://pkg.go.dev/go.opentelemetry.io/otel/semconv/v1.40.0)
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.40.0/MIGRATION.md b/vendor/go.opentelemetry.io/otel/semconv/v1.41.0/MIGRATION.md
similarity index 63%
rename from vendor/go.opentelemetry.io/otel/semconv/v1.40.0/MIGRATION.md
rename to vendor/go.opentelemetry.io/otel/semconv/v1.41.0/MIGRATION.md
index e246b1692d..ba52cadf71 100644
--- a/vendor/go.opentelemetry.io/otel/semconv/v1.40.0/MIGRATION.md
+++ b/vendor/go.opentelemetry.io/otel/semconv/v1.41.0/MIGRATION.md
@@ -1,7 +1,7 @@
-# Migration from v1.39.0 to v1.40.0
+# Migration from v1.40.0 to v1.41.0
-The `go.opentelemetry.io/otel/semconv/v1.40.0` package should be a drop-in replacement for `go.opentelemetry.io/otel/semconv/v1.39.0` with the following exceptions.
+The `go.opentelemetry.io/otel/semconv/v1.41.0` package should be a drop-in replacement for `go.opentelemetry.io/otel/semconv/v1.40.0` with the following exceptions.
## Removed
@@ -11,17 +11,7 @@ Refer to the [OpenTelemetry Semantic Conventions documentation] for deprecation
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.
-- `ErrorMessage`
-- `ErrorMessageKey`
-- `RPCMessageCompressedSize`
-- `RPCMessageCompressedSizeKey`
-- `RPCMessageID`
-- `RPCMessageIDKey`
-- `RPCMessageTypeKey`
-- `RPCMessageTypeReceived`
-- `RPCMessageTypeSent`
-- `RPCMessageUncompressedSize`
-- `RPCMessageUncompressedSizeKey`
+- `DeploymentEnvironmentName`
[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.41.0/README.md b/vendor/go.opentelemetry.io/otel/semconv/v1.41.0/README.md
new file mode 100644
index 0000000000..8353bb7152
--- /dev/null
+++ b/vendor/go.opentelemetry.io/otel/semconv/v1.41.0/README.md
@@ -0,0 +1,3 @@
+# Semconv v1.41.0
+
+[](https://pkg.go.dev/go.opentelemetry.io/otel/semconv/v1.41.0)
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.40.0/attribute_group.go b/vendor/go.opentelemetry.io/otel/semconv/v1.41.0/attribute_group.go
similarity index 96%
rename from vendor/go.opentelemetry.io/otel/semconv/v1.40.0/attribute_group.go
rename to vendor/go.opentelemetry.io/otel/semconv/v1.41.0/attribute_group.go
index ee6b1f79d6..7cee086802 100644
--- a/vendor/go.opentelemetry.io/otel/semconv/v1.40.0/attribute_group.go
+++ b/vendor/go.opentelemetry.io/otel/semconv/v1.41.0/attribute_group.go
@@ -3,7 +3,7 @@
// Code generated from semantic convention specification. DO NOT EDIT.
-package semconv // import "go.opentelemetry.io/otel/semconv/v1.40.0"
+package semconv // import "go.opentelemetry.io/otel/semconv/v1.41.0"
import "go.opentelemetry.io/otel/attribute"
@@ -950,7 +950,7 @@ const (
// 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
+ // environment. 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.
//
@@ -1186,7 +1186,7 @@ const (
// 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.
+ // of the Secret stored in the Secrets Manager.
//
// Type: string
// RequirementLevel: Recommended
@@ -1515,7 +1515,7 @@ func AWSLambdaInvokedARN(val string) attribute.KeyValue {
// 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
+// environment. 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.
//
@@ -1609,7 +1609,7 @@ func AWSS3UploadID(val string) attribute.KeyValue {
// 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.
+// the Secret stored in the Secrets Manager.
func AWSSecretsmanagerSecretARN(val string) attribute.KeyValue {
return AWSSecretsmanagerSecretARNKey.String(val)
}
@@ -2196,6 +2196,11 @@ const (
// Stability: Development
//
// Examples: "12097"
+ // Note: For a given pipeline run and task, the `cicd.pipeline.task.run.id` MUST
+ // be unique within that run. For the same task across different runs of the
+ // same pipeline, the `cicd.pipeline.task.run.id` MAY remain the same, enabling
+ // correlation of `cicd.pipeline.task.run.result` values across multiple
+ // pipeline runs.
CICDPipelineTaskRunIDKey = attribute.Key("cicd.pipeline.task.run.id")
// CICDPipelineTaskRunResultKey is the attribute Key conforming to the
@@ -3431,7 +3436,7 @@ const (
//
// Type: string
// RequirementLevel: Recommended
- // Stability: Beta
+ // Stability: Release_Candidate
//
// Examples: "a3bf90e006b2"
//
@@ -3467,7 +3472,7 @@ const (
//
// Type: string
// RequirementLevel: Recommended
- // Stability: Beta
+ // Stability: Release_Candidate
//
// Examples: "gcr.io/opentelemetry/operator"
ContainerImageNameKey = attribute.Key("container.image.name")
@@ -3478,7 +3483,7 @@ const (
//
// Type: string[]
// RequirementLevel: Recommended
- // Stability: Beta
+ // Stability: Release_Candidate
//
// Examples:
// "example@sha256:afcc7f1ac1b49db317a7196c902e61c6c3c4607d63599ee1a82d702d249a0ccb",
@@ -3497,7 +3502,7 @@ const (
//
// Type: string[]
// RequirementLevel: Recommended
- // Stability: Beta
+ // Stability: Release_Candidate
//
// Examples: "v1.27.1", "3.5.7-0"
//
@@ -3518,7 +3523,7 @@ const (
// 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.
+ // the CRI/API version being used or other customizations.
//
// Type: string
// RequirementLevel: Recommended
@@ -3649,7 +3654,7 @@ func ContainerName(val string) attribute.KeyValue {
// 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.
+// the CRI/API version being used or other customizations.
func ContainerRuntimeDescription(val string) attribute.KeyValue {
return ContainerRuntimeDescriptionKey.String(val)
}
@@ -4260,9 +4265,9 @@ const (
// "deployment.environment.name" semantic conventions. It represents the name of
// the [deployment environment] (aka deployment tier).
//
- // Type: string
+ // Type: Enum
// RequirementLevel: Recommended
- // Stability: Development
+ // Stability: Stable
//
// Examples: "staging", "production"
// Note: `deployment.environment.name` does not affect the uniqueness
@@ -4312,15 +4317,6 @@ const (
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 {
@@ -4334,6 +4330,22 @@ func DeploymentName(val string) attribute.KeyValue {
return DeploymentNameKey.String(val)
}
+// Enum values for deployment.environment.name
+var (
+ // Production environment
+ // Stability: stable
+ DeploymentEnvironmentNameProduction = DeploymentEnvironmentNameKey.String("production")
+ // Staging environment
+ // Stability: stable
+ DeploymentEnvironmentNameStaging = DeploymentEnvironmentNameKey.String("staging")
+ // Testing environment
+ // Stability: stable
+ DeploymentEnvironmentNameTest = DeploymentEnvironmentNameKey.String("test")
+ // Development environment
+ // Stability: stable
+ DeploymentEnvironmentNameDevelopment = DeploymentEnvironmentNameKey.String("development")
+)
+
// Enum values for deployment.status
var (
// failed
@@ -4645,6 +4657,12 @@ const (
// 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.
//
+ // If the recorded error type is a wrapper that is not meaningful for
+ // failure classification, instrumentation MAY use the type of the inner
+ // error instead. For example, in Go, errors created with `fmt.Errorf`
+ // using `%w` MAY be unwrapped when the wrapper type does not help
+ // classify the failure.
+ //
// Instrumentations SHOULD document the list of errors they report.
//
// The cardinality of `error.type` within one instrumentation library SHOULD be
@@ -4718,6 +4736,11 @@ const (
// Stability: Stable
//
// Examples: "java.net.ConnectException", "OSError"
+ // Note: If the recorded exception type is a wrapper that is not meaningful for
+ // failure classification, instrumentation MAY use the type of the inner
+ // exception instead. For example, in Go, errors created with `fmt.Errorf`
+ // using `%w` MAY be unwrapped when the wrapper type does not help
+ // classify the failure.
ExceptionTypeKey = attribute.Key("exception.type")
)
@@ -6667,6 +6690,17 @@ const (
// Examples: "forest", "lived"
GenAIRequestStopSequencesKey = attribute.Key("gen_ai.request.stop_sequences")
+ // GenAIRequestStreamKey is the attribute Key conforming to the
+ // "gen_ai.request.stream" semantic conventions. It represents the indicates
+ // whether the GenAI request was made in streaming mode.
+ //
+ // Type: boolean
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples:
+ GenAIRequestStreamKey = attribute.Key("gen_ai.request.stream")
+
// GenAIRequestTemperatureKey is the attribute Key conforming to the
// "gen_ai.request.temperature" semantic conventions. It represents the
// temperature setting for the GenAI request.
@@ -6734,6 +6768,19 @@ const (
// Examples: "gpt-4-0613"
GenAIResponseModelKey = attribute.Key("gen_ai.response.model")
+ // GenAIResponseTimeToFirstChunkKey is the attribute Key conforming to the
+ // "gen_ai.response.time_to_first_chunk" semantic conventions. It represents the
+ // time to first chunk in a streaming response, measured from request issuance,
+ // in seconds. The value is measured from when the client issues the generation
+ // request to when the first chunk is received in the response stream.
+ //
+ // Type: double
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 0.5, 1.2
+ GenAIResponseTimeToFirstChunkKey = attribute.Key("gen_ai.response.time_to_first_chunk")
+
// GenAIRetrievalDocumentsKey is the attribute Key conforming to the
// "gen_ai.retrieval.documents" semantic conventions. It represents the
// documents retrieved.
@@ -6875,7 +6922,7 @@ const (
// GenAIToolDefinitionsKey is the attribute Key conforming to the
// "gen_ai.tool.definitions" semantic conventions. It represents the list of
- // source system tool definitions available to the GenAI agent or model.
+ // tool definitions available to the GenAI agent or model.
//
// Type: any
// RequirementLevel: Recommended
@@ -6887,19 +6934,18 @@ const (
// "description": "The city and state, e.g. San Francisco, CA"\n },\n "unit":
// {\n "type": "string",\n "enum": [\n "celsius",\n "fahrenheit"\n ]\n }\n },\n
// "required": [\n "location",\n "unit"\n ]\n }\n }\n]\n"
- // Note: The value of this attribute matches source system tool definition
- // format.
+ // Note: Instrumentations MUST follow [Tool Definitions JSON Schema].
//
- // It's expected to be an array of objects where each object represents a tool
- // definition. In case a serialized string is available
- // to the instrumentation, the instrumentation SHOULD do the best effort to
- // deserialize it to an array. 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.
+ // 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.
//
// Since this attribute could be large, it's NOT RECOMMENDED to populate
- // it by default. Instrumentations MAY provide a way to enable
- // populating this attribute.
+ // non-required properties by default. Instrumentations MAY provide a way
+ // to enable populating optional properties.
+ //
+ // [Tool Definitions JSON Schema]: /docs/gen-ai/gen-ai-tool-definitions.json
GenAIToolDefinitionsKey = attribute.Key("gen_ai.tool.definitions")
// GenAIToolDescriptionKey is the attribute Key conforming to the
@@ -6997,6 +7043,32 @@ const (
//
// Examples: 180
GenAIUsageOutputTokensKey = attribute.Key("gen_ai.usage.output_tokens")
+
+ // GenAIUsageReasoningOutputTokensKey is the attribute Key conforming to the
+ // "gen_ai.usage.reasoning.output_tokens" semantic conventions. It represents
+ // the number of output tokens used for reasoning (e.g. chain-of-thought,
+ // extended thinking).
+ //
+ // Type: int
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: 50
+ // Note: The value SHOULD be included in `gen_ai.usage.output_tokens`.
+ GenAIUsageReasoningOutputTokensKey = attribute.Key("gen_ai.usage.reasoning.output_tokens")
+
+ // GenAIWorkflowNameKey is the attribute Key conforming to the
+ // "gen_ai.workflow.name" semantic conventions. It represents the human-readable
+ // name of the GenAI workflow provided by the application.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "multi_agent_rag", "customer_support_pipeline"
+ // Note: This attribute can be populated in different frameworks eg: name of the
+ // first chain in LangChain OR name of the crew in CrewAI.
+ GenAIWorkflowNameKey = attribute.Key("gen_ai.workflow.name")
)
// GenAIAgentDescription returns an attribute KeyValue conforming to the
@@ -7139,6 +7211,13 @@ func GenAIRequestStopSequences(val ...string) attribute.KeyValue {
return GenAIRequestStopSequencesKey.StringSlice(val)
}
+// GenAIRequestStream returns an attribute KeyValue conforming to the
+// "gen_ai.request.stream" semantic conventions. It represents the indicates
+// whether the GenAI request was made in streaming mode.
+func GenAIRequestStream(val bool) attribute.KeyValue {
+ return GenAIRequestStreamKey.Bool(val)
+}
+
// GenAIRequestTemperature returns an attribute KeyValue conforming to the
// "gen_ai.request.temperature" semantic conventions. It represents the
// temperature setting for the GenAI request.
@@ -7182,6 +7261,15 @@ func GenAIResponseModel(val string) attribute.KeyValue {
return GenAIResponseModelKey.String(val)
}
+// GenAIResponseTimeToFirstChunk returns an attribute KeyValue conforming to the
+// "gen_ai.response.time_to_first_chunk" semantic conventions. It represents the
+// time to first chunk in a streaming response, measured from request issuance,
+// in seconds. The value is measured from when the client issues the generation
+// request to when the first chunk is received in the response stream.
+func GenAIResponseTimeToFirstChunk(val float64) attribute.KeyValue {
+ return GenAIResponseTimeToFirstChunkKey.Float64(val)
+}
+
// GenAIRetrievalQueryText returns an attribute KeyValue conforming to the
// "gen_ai.retrieval.query.text" semantic conventions. It represents the query
// text used for retrieval.
@@ -7245,6 +7333,21 @@ func GenAIUsageOutputTokens(val int) attribute.KeyValue {
return GenAIUsageOutputTokensKey.Int(val)
}
+// GenAIUsageReasoningOutputTokens returns an attribute KeyValue conforming to
+// the "gen_ai.usage.reasoning.output_tokens" semantic conventions. It represents
+// the number of output tokens used for reasoning (e.g. chain-of-thought,
+// extended thinking).
+func GenAIUsageReasoningOutputTokens(val int) attribute.KeyValue {
+ return GenAIUsageReasoningOutputTokensKey.Int(val)
+}
+
+// GenAIWorkflowName returns an attribute KeyValue conforming to the
+// "gen_ai.workflow.name" semantic conventions. It represents the human-readable
+// name of the GenAI workflow provided by the application.
+func GenAIWorkflowName(val string) attribute.KeyValue {
+ return GenAIWorkflowNameKey.String(val)
+}
+
// Enum values for gen_ai.operation.name
var (
// Chat completion operation such as [OpenAI Chat API]
@@ -7281,6 +7384,9 @@ var (
// Execute a tool
// Stability: development
GenAIOperationNameExecuteTool = GenAIOperationNameKey.String("execute_tool")
+ // Invoke GenAI workflow
+ // Stability: development
+ GenAIOperationNameInvokeWorkflow = GenAIOperationNameKey.String("invoke_workflow")
)
// Enum values for gen_ai.output.type
@@ -7335,7 +7441,7 @@ var (
// [Azure OpenAI]
// Stability: development
//
- // [Azure OpenAI]: https://azure.microsoft.com/products/ai-services/openai-service/
+ // [Azure OpenAI]: https://learn.microsoft.com/en-us/azure/ai-services/openai/overview
GenAIProviderNameAzureAIOpenAI = GenAIProviderNameKey.String("azure.ai.openai")
// [IBM Watsonx AI]
// Stability: development
@@ -7551,6 +7657,44 @@ var (
// Namespace: go
const (
+ // GoCPUDetailedStateKey is the attribute Key conforming to the
+ // "go.cpu.detailed_state" semantic conventions. It represents the detailed
+ // state of the CPU.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "gc/pause", "gc/mark/assist"
+ // Note: Value SHOULD match the specific CPU class reported by the Go runtime
+ // under `/cpu/classes/...`. The list of possible values is subject to change
+ // with the Go version used.
+ GoCPUDetailedStateKey = attribute.Key("go.cpu.detailed_state")
+
+ // GoCPUStateKey is the attribute Key conforming to the "go.cpu.state" semantic
+ // conventions. It represents the state of the CPU.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "user", "gc"
+ GoCPUStateKey = attribute.Key("go.cpu.state")
+
+ // GoMemoryDetailedTypeKey is the attribute Key conforming to the
+ // "go.memory.detailed_type" semantic conventions. It represents the detailed
+ // type of memory.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "heap/objects", "heap/free"
+ // Note: Value SHOULD match the specific memory class reported by the Go runtime
+ // under `/memory/classes/...`. The list of possible values is subject to change
+ // with the Go version used.
+ GoMemoryDetailedTypeKey = attribute.Key("go.memory.detailed_type")
+
// GoMemoryTypeKey is the attribute Key conforming to the "go.memory.type"
// semantic conventions. It represents the type of memory.
//
@@ -7562,6 +7706,36 @@ const (
GoMemoryTypeKey = attribute.Key("go.memory.type")
)
+// GoCPUDetailedState returns an attribute KeyValue conforming to the
+// "go.cpu.detailed_state" semantic conventions. It represents the detailed state
+// of the CPU.
+func GoCPUDetailedState(val string) attribute.KeyValue {
+ return GoCPUDetailedStateKey.String(val)
+}
+
+// GoMemoryDetailedType returns an attribute KeyValue conforming to the
+// "go.memory.detailed_type" semantic conventions. It represents the detailed
+// type of memory.
+func GoMemoryDetailedType(val string) attribute.KeyValue {
+ return GoMemoryDetailedTypeKey.String(val)
+}
+
+// Enum values for go.cpu.state
+var (
+ // CPU time spent running user Go code.
+ // Stability: development
+ GoCPUStateUser = GoCPUStateKey.String("user")
+ // CPU time spent performing garbage collection tasks.
+ // Stability: development
+ GoCPUStateGC = GoCPUStateKey.String("gc")
+ // CPU time spent returning unused memory to the underlying platform.
+ // Stability: development
+ GoCPUStateScavenge = GoCPUStateKey.String("scavenge")
+ // Available CPU time not spent executing any Go or Go runtime code.
+ // Stability: development
+ GoCPUStateIdle = GoCPUStateKey.String("idle")
+)
+
// Enum values for go.memory.type
var (
// Memory allocated from the heap that is reserved for stack space, whether or
@@ -7584,7 +7758,8 @@ const (
// Stability: Development
//
// Examples: query findBookById { bookById(id: ?) { name } }
- // Note: The value may be sanitized to exclude sensitive information.
+ // Note: If instrumentation can reliably identify and redact sensitive
+ // information it SHOULD do it.
GraphQLDocumentKey = attribute.Key("graphql.document")
// GraphQLOperationNameKey is the attribute Key conforming to the
@@ -8335,7 +8510,7 @@ var (
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.
+ // in Watts-hours or Ampere-hours.
//
// Type: string
// RequirementLevel: Recommended
@@ -8637,7 +8812,7 @@ const (
// HwBatteryCapacity returns an attribute KeyValue conforming to the
// "hw.battery.capacity" semantic conventions. It represents the design capacity
-// in Watts-hours or Amper-hours.
+// in Watts-hours or Ampere-hours.
func HwBatteryCapacity(val string) attribute.KeyValue {
return HwBatteryCapacityKey.String(val)
}
@@ -9026,7 +9201,7 @@ const (
//
// Type: string
// RequirementLevel: Recommended
- // Stability: Beta
+ // Stability: Release_Candidate
//
// Examples: "opentelemetry-cluster"
K8SClusterNameKey = attribute.Key("k8s.cluster.name")
@@ -9037,7 +9212,7 @@ const (
//
// Type: string
// RequirementLevel: Recommended
- // Stability: Beta
+ // Stability: Release_Candidate
//
// Examples: "218fc5a9-a5f1-4b54-aa05-46717d0ab26d"
// Note: K8s doesn't have support for obtaining a cluster ID. If this is ever
@@ -9073,7 +9248,7 @@ const (
//
// Type: string
// RequirementLevel: Recommended
- // Stability: Beta
+ // Stability: Release_Candidate
//
// Examples: "redis"
K8SContainerNameKey = attribute.Key("k8s.container.name")
@@ -9085,7 +9260,7 @@ const (
//
// Type: int
// RequirementLevel: Recommended
- // Stability: Beta
+ // Stability: Release_Candidate
//
// Examples:
K8SContainerRestartCountKey = attribute.Key("k8s.container.restart_count")
@@ -9136,7 +9311,7 @@ const (
//
// Type: string
// RequirementLevel: Recommended
- // Stability: Beta
+ // Stability: Release_Candidate
//
// Examples: "opentelemetry"
K8SCronJobNameKey = attribute.Key("k8s.cronjob.name")
@@ -9146,7 +9321,7 @@ const (
//
// Type: string
// RequirementLevel: Recommended
- // Stability: Beta
+ // Stability: Release_Candidate
//
// Examples: "275ecb36-5aa8-4c2a-9c47-d8bb681b9aff"
K8SCronJobUIDKey = attribute.Key("k8s.cronjob.uid")
@@ -9157,7 +9332,7 @@ const (
//
// Type: string
// RequirementLevel: Recommended
- // Stability: Beta
+ // Stability: Release_Candidate
//
// Examples: "opentelemetry"
K8SDaemonSetNameKey = attribute.Key("k8s.daemonset.name")
@@ -9167,7 +9342,7 @@ const (
//
// Type: string
// RequirementLevel: Recommended
- // Stability: Beta
+ // Stability: Release_Candidate
//
// Examples: "275ecb36-5aa8-4c2a-9c47-d8bb681b9aff"
K8SDaemonSetUIDKey = attribute.Key("k8s.daemonset.uid")
@@ -9178,7 +9353,7 @@ const (
//
// Type: string
// RequirementLevel: Recommended
- // Stability: Beta
+ // Stability: Release_Candidate
//
// Examples: "opentelemetry"
K8SDeploymentNameKey = attribute.Key("k8s.deployment.name")
@@ -9189,7 +9364,7 @@ const (
//
// Type: string
// RequirementLevel: Recommended
- // Stability: Beta
+ // Stability: Release_Candidate
//
// Examples: "275ecb36-5aa8-4c2a-9c47-d8bb681b9aff"
K8SDeploymentUIDKey = attribute.Key("k8s.deployment.uid")
@@ -9279,7 +9454,7 @@ const (
//
// Type: string
// RequirementLevel: Recommended
- // Stability: Beta
+ // Stability: Release_Candidate
//
// Examples: "opentelemetry"
K8SJobNameKey = attribute.Key("k8s.job.name")
@@ -9289,7 +9464,7 @@ const (
//
// Type: string
// RequirementLevel: Recommended
- // Stability: Beta
+ // Stability: Release_Candidate
//
// Examples: "275ecb36-5aa8-4c2a-9c47-d8bb681b9aff"
K8SJobUIDKey = attribute.Key("k8s.job.uid")
@@ -9300,7 +9475,7 @@ const (
//
// Type: string
// RequirementLevel: Recommended
- // Stability: Beta
+ // Stability: Release_Candidate
//
// Examples: "default"
K8SNamespaceNameKey = attribute.Key("k8s.namespace.name")
@@ -9365,27 +9540,128 @@ const (
//
// Type: string
// RequirementLevel: Recommended
- // Stability: Beta
+ // Stability: Release_Candidate
//
// Examples: "node-1"
K8SNodeNameKey = attribute.Key("k8s.node.name")
+ // K8SNodeSystemContainerNameKey is the attribute Key conforming to the
+ // "k8s.node.system_container.name" semantic conventions. It represents the name
+ // of the system container running on the K8s Node.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "kubelet", "runtime", "pods", "misc"
+ K8SNodeSystemContainerNameKey = attribute.Key("k8s.node.system_container.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: Beta
+ // Stability: Release_Candidate
//
// Examples: "1eb3a0c6-0477-4080-a9cb-0cb7db65c6a2"
K8SNodeUIDKey = attribute.Key("k8s.node.uid")
+ // K8SPersistentvolumeNameKey is the attribute Key conforming to the
+ // "k8s.persistentvolume.name" semantic conventions. It represents the name of
+ // the PersistentVolume.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "pv-data-01"
+ K8SPersistentvolumeNameKey = attribute.Key("k8s.persistentvolume.name")
+
+ // K8SPersistentvolumeReclaimPolicyKey is the attribute Key conforming to the
+ // "k8s.persistentvolume.reclaim_policy" semantic conventions. It represents the
+ // reclaim policy of the PersistentVolume.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Delete", "Retain", "Recycle"
+ // Note: This attribute aligns with the `persistentVolumeReclaimPolicy` field of
+ // the
+ // [K8s PersistentVolumeSpec].
+ //
+ // [K8s PersistentVolumeSpec]: https://kubernetes.io/docs/reference/kubernetes-api/config-and-storage-resources/persistent-volume-v1/#PersistentVolumeSpec
+ K8SPersistentvolumeReclaimPolicyKey = attribute.Key("k8s.persistentvolume.reclaim_policy")
+
+ // K8SPersistentvolumeStatusPhaseKey is the attribute Key conforming to the
+ // "k8s.persistentvolume.status.phase" semantic conventions. It represents the
+ // phase of the PersistentVolume.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Pending", "Available", "Bound", "Released", "Failed"
+ // Note: This attribute aligns with the `phase` field of the
+ // [K8s PersistentVolumeStatus].
+ //
+ // [K8s PersistentVolumeStatus]: https://kubernetes.io/docs/reference/kubernetes-api/config-and-storage-resources/persistent-volume-v1/#PersistentVolumeStatus
+ K8SPersistentvolumeStatusPhaseKey = attribute.Key("k8s.persistentvolume.status.phase")
+
+ // K8SPersistentvolumeUIDKey is the attribute Key conforming to the
+ // "k8s.persistentvolume.uid" semantic conventions. It represents the UID of the
+ // PersistentVolume.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "275ecb36-5aa8-4c2a-9c47-d8bb681b9aff"
+ K8SPersistentvolumeUIDKey = attribute.Key("k8s.persistentvolume.uid")
+
+ // K8SPersistentvolumeclaimNameKey is the attribute Key conforming to the
+ // "k8s.persistentvolumeclaim.name" semantic conventions. It represents the name
+ // of the PersistentVolumeClaim.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "pvc-data-01"
+ K8SPersistentvolumeclaimNameKey = attribute.Key("k8s.persistentvolumeclaim.name")
+
+ // K8SPersistentvolumeclaimStatusPhaseKey is the attribute Key conforming to the
+ // "k8s.persistentvolumeclaim.status.phase" semantic conventions. It represents
+ // the phase of the PersistentVolumeClaim.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "Pending", "Bound", "Lost"
+ // Note: This attribute aligns with the `phase` field of the
+ // [K8s PersistentVolumeClaimStatus].
+ //
+ // [K8s PersistentVolumeClaimStatus]: https://kubernetes.io/docs/reference/kubernetes-api/config-and-storage-resources/persistent-volume-claim-v1/#PersistentVolumeClaimStatus
+ K8SPersistentvolumeclaimStatusPhaseKey = attribute.Key("k8s.persistentvolumeclaim.status.phase")
+
+ // K8SPersistentvolumeclaimUIDKey is the attribute Key conforming to the
+ // "k8s.persistentvolumeclaim.uid" semantic conventions. It represents the UID
+ // of the PersistentVolumeClaim.
+ //
+ // Type: string
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "275ecb36-5aa8-4c2a-9c47-d8bb681b9aff"
+ K8SPersistentvolumeclaimUIDKey = attribute.Key("k8s.persistentvolumeclaim.uid")
+
// K8SPodHostnameKey is the attribute Key conforming to the "k8s.pod.hostname"
// semantic conventions. It represents the specifies the hostname of the Pod.
//
// Type: string
// RequirementLevel: Recommended
- // Stability: Beta
+ // Stability: Release_Candidate
//
// Examples: "collector-gateway"
// Note: The K8s Pod spec has an optional hostname field, which can be used to
@@ -9405,7 +9681,7 @@ const (
//
// Type: string
// RequirementLevel: Recommended
- // Stability: Beta
+ // Stability: Release_Candidate
//
// Examples: "172.18.0.2"
// Note: This attribute aligns with the `podIP` field of the
@@ -9419,7 +9695,7 @@ const (
//
// Type: string
// RequirementLevel: Recommended
- // Stability: Beta
+ // Stability: Release_Candidate
//
// Examples: "opentelemetry-pod-autoconf"
K8SPodNameKey = attribute.Key("k8s.pod.name")
@@ -9430,7 +9706,7 @@ const (
//
// Type: string
// RequirementLevel: Recommended
- // Stability: Beta
+ // Stability: Release_Candidate
//
// Examples: "2025-12-04T08:41:03Z"
// Note: Date and time at which the object was acknowledged by the Kubelet.
@@ -9474,7 +9750,7 @@ const (
//
// Type: string
// RequirementLevel: Recommended
- // Stability: Beta
+ // Stability: Release_Candidate
//
// Examples: "275ecb36-5aa8-4c2a-9c47-d8bb681b9aff"
K8SPodUIDKey = attribute.Key("k8s.pod.uid")
@@ -9485,7 +9761,7 @@ const (
//
// Type: string
// RequirementLevel: Recommended
- // Stability: Beta
+ // Stability: Release_Candidate
//
// Examples: "opentelemetry"
K8SReplicaSetNameKey = attribute.Key("k8s.replicaset.name")
@@ -9496,7 +9772,7 @@ const (
//
// Type: string
// RequirementLevel: Recommended
- // Stability: Beta
+ // Stability: Release_Candidate
//
// Examples: "275ecb36-5aa8-4c2a-9c47-d8bb681b9aff"
K8SReplicaSetUIDKey = attribute.Key("k8s.replicaset.uid")
@@ -9709,7 +9985,7 @@ const (
//
// Type: string
// RequirementLevel: Recommended
- // Stability: Beta
+ // Stability: Release_Candidate
//
// Examples: "opentelemetry"
K8SStatefulSetNameKey = attribute.Key("k8s.statefulset.name")
@@ -9720,7 +9996,7 @@ const (
//
// Type: string
// RequirementLevel: Recommended
- // Stability: Beta
+ // Stability: Release_Candidate
//
// Examples: "275ecb36-5aa8-4c2a-9c47-d8bb681b9aff"
K8SStatefulSetUIDKey = attribute.Key("k8s.statefulset.uid")
@@ -10005,12 +10281,80 @@ func K8SNodeName(val string) attribute.KeyValue {
return K8SNodeNameKey.String(val)
}
+// K8SNodeSystemContainerName returns an attribute KeyValue conforming to the
+// "k8s.node.system_container.name" semantic conventions. It represents the name
+// of the system container running on the K8s Node.
+func K8SNodeSystemContainerName(val string) attribute.KeyValue {
+ return K8SNodeSystemContainerNameKey.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)
}
+// K8SPersistentvolumeAnnotation returns an attribute KeyValue conforming to the
+// "k8s.persistentvolume.annotation" semantic conventions. It represents the
+// annotation placed on the PersistentVolume, the `` being the annotation
+// name, the value being the annotation value, even if the value is empty.
+func K8SPersistentvolumeAnnotation(key string, val string) attribute.KeyValue {
+ return attribute.String("k8s.persistentvolume.annotation."+key, val)
+}
+
+// K8SPersistentvolumeLabel returns an attribute KeyValue conforming to the
+// "k8s.persistentvolume.label" semantic conventions. It represents the label
+// placed on the PersistentVolume, the `` being the label name, the value
+// being the label value, even if the value is empty.
+func K8SPersistentvolumeLabel(key string, val string) attribute.KeyValue {
+ return attribute.String("k8s.persistentvolume.label."+key, val)
+}
+
+// K8SPersistentvolumeName returns an attribute KeyValue conforming to the
+// "k8s.persistentvolume.name" semantic conventions. It represents the name of
+// the PersistentVolume.
+func K8SPersistentvolumeName(val string) attribute.KeyValue {
+ return K8SPersistentvolumeNameKey.String(val)
+}
+
+// K8SPersistentvolumeUID returns an attribute KeyValue conforming to the
+// "k8s.persistentvolume.uid" semantic conventions. It represents the UID of the
+// PersistentVolume.
+func K8SPersistentvolumeUID(val string) attribute.KeyValue {
+ return K8SPersistentvolumeUIDKey.String(val)
+}
+
+// K8SPersistentvolumeclaimAnnotation returns an attribute KeyValue conforming to
+// the "k8s.persistentvolumeclaim.annotation" semantic conventions. It represents
+// the annotation placed on the PersistentVolumeClaim, the `` being the
+// annotation name, the value being the annotation value, even if the value is
+// empty.
+func K8SPersistentvolumeclaimAnnotation(key string, val string) attribute.KeyValue {
+ return attribute.String("k8s.persistentvolumeclaim.annotation."+key, val)
+}
+
+// K8SPersistentvolumeclaimLabel returns an attribute KeyValue conforming to the
+// "k8s.persistentvolumeclaim.label" semantic conventions. It represents the
+// label placed on the PersistentVolumeClaim, the `` being the label name,
+// the value being the label value, even if the value is empty.
+func K8SPersistentvolumeclaimLabel(key string, val string) attribute.KeyValue {
+ return attribute.String("k8s.persistentvolumeclaim.label."+key, val)
+}
+
+// K8SPersistentvolumeclaimName returns an attribute KeyValue conforming to the
+// "k8s.persistentvolumeclaim.name" semantic conventions. It represents the name
+// of the PersistentVolumeClaim.
+func K8SPersistentvolumeclaimName(val string) attribute.KeyValue {
+ return K8SPersistentvolumeclaimNameKey.String(val)
+}
+
+// K8SPersistentvolumeclaimUID returns an attribute KeyValue conforming to the
+// "k8s.persistentvolumeclaim.uid" semantic conventions. It represents the UID of
+// the PersistentVolumeClaim.
+func K8SPersistentvolumeclaimUID(val string) attribute.KeyValue {
+ return K8SPersistentvolumeclaimUIDKey.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
@@ -10318,6 +10662,51 @@ var (
K8SNodeConditionTypeNetworkUnavailable = K8SNodeConditionTypeKey.String("NetworkUnavailable")
)
+// Enum values for k8s.persistentvolume.reclaim_policy
+var (
+ // The volume will be deleted when released from its claim.
+ // Stability: development
+ K8SPersistentvolumeReclaimPolicyDelete = K8SPersistentvolumeReclaimPolicyKey.String("Delete")
+ // The volume will be recycled (basic scrub) when released from its claim.
+ // Stability: development
+ K8SPersistentvolumeReclaimPolicyRecycle = K8SPersistentvolumeReclaimPolicyKey.String("Recycle")
+ // The volume will be retained when released from its claim.
+ // Stability: development
+ K8SPersistentvolumeReclaimPolicyRetain = K8SPersistentvolumeReclaimPolicyKey.String("Retain")
+)
+
+// Enum values for k8s.persistentvolume.status.phase
+var (
+ // The volume is available and not yet bound to a claim.
+ // Stability: development
+ K8SPersistentvolumeStatusPhaseAvailable = K8SPersistentvolumeStatusPhaseKey.String("Available")
+ // The volume is bound to a claim.
+ // Stability: development
+ K8SPersistentvolumeStatusPhaseBound = K8SPersistentvolumeStatusPhaseKey.String("Bound")
+ // The volume has failed its automatic reclamation.
+ // Stability: development
+ K8SPersistentvolumeStatusPhaseFailed = K8SPersistentvolumeStatusPhaseKey.String("Failed")
+ // The volume is being provisioned.
+ // Stability: development
+ K8SPersistentvolumeStatusPhasePending = K8SPersistentvolumeStatusPhaseKey.String("Pending")
+ // The claim has been deleted but the volume is not yet available.
+ // Stability: development
+ K8SPersistentvolumeStatusPhaseReleased = K8SPersistentvolumeStatusPhaseKey.String("Released")
+)
+
+// Enum values for k8s.persistentvolumeclaim.status.phase
+var (
+ // The claim is bound to a volume.
+ // Stability: development
+ K8SPersistentvolumeclaimStatusPhaseBound = K8SPersistentvolumeclaimStatusPhaseKey.String("Bound")
+ // The claim has lost its underlying volume (the volume does not exist anymore).
+ // Stability: development
+ K8SPersistentvolumeclaimStatusPhaseLost = K8SPersistentvolumeclaimStatusPhaseKey.String("Lost")
+ // The claim has not yet been bound to a volume.
+ // Stability: development
+ K8SPersistentvolumeclaimStatusPhasePending = K8SPersistentvolumeclaimStatusPhaseKey.String("Pending")
+)
+
// Enum values for k8s.pod.status.phase
var (
// The pod has been accepted by the system, but one or more of the containers
@@ -12669,7 +13058,7 @@ const (
//
// Type: string
// RequirementLevel: Recommended
- // Stability: Development
+ // Stability: Stable
//
// Examples: "browser.mouse.click", "device.app.lifecycle"
// Note: This attribute SHOULD be used by non-OTLP exporters when destination
@@ -13240,14 +13629,27 @@ const (
// 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.
+ // deterministic build ID for executables.
//
// Type: string
// RequirementLevel: Recommended
// Stability: Development
//
// Examples: "600DCAFE4A110000F2BF38C493F5FB92"
+ // Note: GNU and Go build IDs may be stripped or unavailable in some
+ // environments
+ // (e.g., Alpine Linux, Docker images). This attribute provides a deterministic
+ // build ID computed by hashing the first and last 4096 bytes of the file
+ // along with its length:
+ //
+ // ```
+ // Input ← Concat(File[:4096], File[-4096:], BigEndianUInt64(Len(File)))
+ // Digest ← SHA256(Input)
+ // BuildID ← Digest[:16]
+ // ```
+ //
+ // The result is the first 16 bytes (128 bits) of the SHA256 digest,
+ // represented as a hex string.
ProcessExecutableBuildIDHtlhashKey = attribute.Key("process.executable.build_id.htlhash")
// ProcessExecutableNameKey is the attribute Key conforming to the
@@ -13603,8 +14005,7 @@ func ProcessExecutableBuildIDGo(val string) attribute.KeyValue {
// 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.
+// the deterministic build ID for executables.
func ProcessExecutableBuildIDHtlhash(val string) attribute.KeyValue {
return ProcessExecutableBuildIDHtlhashKey.String(val)
}
@@ -14317,9 +14718,11 @@ const (
// 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
+ // concatenated with the process executable name, e.g. `unknown_service:bash`.
+ // If the process executable name is not available, the value MUST be set to
// `unknown_service`.
+ // The process executable name is the name of the process executable, the same
+ // value as described by the [`process.executable.name`] resource attribute.
//
// [`process.executable.name`]: process.md
ServiceNameKey = attribute.Key("service.name")
@@ -14643,6 +15046,17 @@ const (
// Examples: "ext4"
SystemFilesystemTypeKey = attribute.Key("system.filesystem.type")
+ // SystemMemoryLinuxHugepagesStateKey is the attribute Key conforming to the
+ // "system.memory.linux.hugepages.state" semantic conventions. It represents the
+ // Linux HugePages memory state.
+ //
+ // Type: Enum
+ // RequirementLevel: Recommended
+ // Stability: Development
+ //
+ // Examples: "free", "used"
+ SystemMemoryLinuxHugepagesStateKey = attribute.Key("system.memory.linux.hugepages.state")
+
// SystemMemoryLinuxSlabStateKey is the attribute Key conforming to the
// "system.memory.linux.slab.state" semantic conventions. It represents the
// Linux Slab memory state.
@@ -14753,6 +15167,16 @@ var (
SystemFilesystemTypeExt4 = SystemFilesystemTypeKey.String("ext4")
)
+// Enum values for system.memory.linux.hugepages.state
+var (
+ // free
+ // Stability: development
+ SystemMemoryLinuxHugepagesStateFree = SystemMemoryLinuxHugepagesStateKey.String("free")
+ // used
+ // Stability: development
+ SystemMemoryLinuxHugepagesStateUsed = SystemMemoryLinuxHugepagesStateKey.String("used")
+)
+
// Enum values for system.memory.linux.slab.state
var (
// reclaimable
@@ -14817,7 +15241,7 @@ const (
//
// Type: string
// RequirementLevel: Recommended
- // Stability: Development
+ // Stability: Stable
//
// Examples: "parts-unlimited-java"
// Note: Official auto instrumentation agents and distributions SHOULD set the
@@ -14832,7 +15256,7 @@ const (
//
// Type: string
// RequirementLevel: Recommended
- // Stability: Development
+ // Stability: Stable
//
// Examples: "1.2.3"
TelemetryDistroVersionKey = attribute.Key("telemetry.distro.version")
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.40.0/doc.go b/vendor/go.opentelemetry.io/otel/semconv/v1.41.0/doc.go
similarity index 82%
rename from vendor/go.opentelemetry.io/otel/semconv/v1.40.0/doc.go
rename to vendor/go.opentelemetry.io/otel/semconv/v1.41.0/doc.go
index c5c41e4d27..a45d424d88 100644
--- a/vendor/go.opentelemetry.io/otel/semconv/v1.40.0/doc.go
+++ b/vendor/go.opentelemetry.io/otel/semconv/v1.41.0/doc.go
@@ -1,9 +1,11 @@
+// Code generated from semantic convention specification. DO NOT EDIT.
+
// 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.40.0
+// patterns for OpenTelemetry things. This package represents the v1.41.0
// version of the OpenTelemetry semantic conventions.
-package semconv // import "go.opentelemetry.io/otel/semconv/v1.40.0"
+package semconv // import "go.opentelemetry.io/otel/semconv/v1.41.0"
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.40.0/error_type.go b/vendor/go.opentelemetry.io/otel/semconv/v1.41.0/error_type.go
similarity index 75%
rename from vendor/go.opentelemetry.io/otel/semconv/v1.40.0/error_type.go
rename to vendor/go.opentelemetry.io/otel/semconv/v1.41.0/error_type.go
index 6d26e52821..0b13f0de8e 100644
--- a/vendor/go.opentelemetry.io/otel/semconv/v1.40.0/error_type.go
+++ b/vendor/go.opentelemetry.io/otel/semconv/v1.41.0/error_type.go
@@ -1,10 +1,13 @@
+// Code generated from semantic convention specification. DO NOT EDIT.
+
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0
-package semconv // import "go.opentelemetry.io/otel/semconv/v1.40.0"
+package semconv // import "go.opentelemetry.io/otel/semconv/v1.41.0"
import (
"errors"
+ "fmt"
"reflect"
"go.opentelemetry.io/otel/attribute"
@@ -22,7 +25,8 @@ import (
// the returned attribute has that method's return value. If multiple errors in
// the chain implement this method, the value from the first match found by
// [errors.As] is used. Otherwise, the returned attribute has a value derived
-// from the concrete type of err.
+// from the concrete type of err after unwrapping any wrappers created with
+// [fmt.Errorf].
//
// The key of the returned attribute is [ErrorTypeKey].
func ErrorType(err error) attribute.KeyValue {
@@ -50,7 +54,7 @@ func errorType(err error) string {
// Fallback to reflection if the ErrorType method is not supported or
// returns an empty value.
- t := reflect.TypeOf(err)
+ t := reflect.TypeOf(unwrapFmtWrapped(err))
pkg, name := t.PkgPath(), t.Name()
if pkg != "" && name != "" {
s = pkg + "." + name
@@ -64,3 +68,16 @@ func errorType(err error) string {
}
return s
}
+
+var fmtWrapErrorType = reflect.TypeOf(fmt.Errorf("wrapped: %w", errors.New("err")))
+
+func unwrapFmtWrapped(err error) error {
+ for reflect.TypeOf(err) == fmtWrapErrorType {
+ u := errors.Unwrap(err)
+ if u == nil {
+ return err // When the wrapped error is nil, use the concrete type of the wrapper.
+ }
+ err = u
+ }
+ return err
+}
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.40.0/exception.go b/vendor/go.opentelemetry.io/otel/semconv/v1.41.0/exception.go
similarity index 77%
rename from vendor/go.opentelemetry.io/otel/semconv/v1.40.0/exception.go
rename to vendor/go.opentelemetry.io/otel/semconv/v1.41.0/exception.go
index 6a26231a1a..5f0151affa 100644
--- a/vendor/go.opentelemetry.io/otel/semconv/v1.40.0/exception.go
+++ b/vendor/go.opentelemetry.io/otel/semconv/v1.41.0/exception.go
@@ -1,7 +1,9 @@
+// Code generated from semantic convention specification. DO NOT EDIT.
+
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0
-package semconv // import "go.opentelemetry.io/otel/semconv/v1.40.0"
+package semconv // import "go.opentelemetry.io/otel/semconv/v1.41.0"
const (
// ExceptionEventName is the name of the Span event representing an exception.
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.40.0/otelconv/metric.go b/vendor/go.opentelemetry.io/otel/semconv/v1.41.0/otelconv/metric.go
similarity index 66%
rename from vendor/go.opentelemetry.io/otel/semconv/v1.40.0/otelconv/metric.go
rename to vendor/go.opentelemetry.io/otel/semconv/v1.41.0/otelconv/metric.go
index 901da86985..d50e198493 100644
--- a/vendor/go.opentelemetry.io/otel/semconv/v1.40.0/otelconv/metric.go
+++ b/vendor/go.opentelemetry.io/otel/semconv/v1.41.0/otelconv/metric.go
@@ -197,6 +197,9 @@ func (m SDKExporterLogExported) Add(
incr int64,
attrs ...attribute.KeyValue,
) {
+ if !m.Int64Counter.Enabled(ctx) {
+ return
+ }
if len(attrs) == 0 {
m.Int64Counter.Add(ctx, incr)
return
@@ -204,6 +207,7 @@ func (m SDKExporterLogExported) Add(
o := addOptPool.Get().(*[]metric.AddOption)
defer func() {
+ clear(*o)
*o = (*o)[:0]
addOptPool.Put(o)
}()
@@ -228,6 +232,9 @@ func (m SDKExporterLogExported) Add(
// If no rejection reason is available, `rejected` SHOULD be used as value for
// `error.type`.
func (m SDKExporterLogExported) AddSet(ctx context.Context, incr int64, set attribute.Set) {
+ if !m.Int64Counter.Enabled(ctx) {
+ return
+ }
if set.Len() == 0 {
m.Int64Counter.Add(ctx, incr)
return
@@ -235,6 +242,7 @@ func (m SDKExporterLogExported) AddSet(ctx context.Context, incr int64, set attr
o := addOptPool.Get().(*[]metric.AddOption)
defer func() {
+ clear(*o)
*o = (*o)[:0]
addOptPool.Put(o)
}()
@@ -277,6 +285,100 @@ func (SDKExporterLogExported) AttrServerPort(val int) attribute.KeyValue {
return attribute.Int("server.port", val)
}
+// SDKExporterLogExportedObservable is an instrument used to record metric values
+// conforming to the "otel.sdk.exporter.log.exported" semantic conventions. It
+// represents the number of log records for which the export has finished, either
+// successful or failed.
+type SDKExporterLogExportedObservable struct {
+ metric.Int64ObservableCounter
+}
+
+var newSDKExporterLogExportedObservableOpts = []metric.Int64ObservableCounterOption{
+ metric.WithDescription("The number of log records for which the export has finished, either successful or failed."),
+ metric.WithUnit("{log_record}"),
+}
+
+// NewSDKExporterLogExportedObservable returns a new
+// SDKExporterLogExportedObservable instrument.
+func NewSDKExporterLogExportedObservable(
+ m metric.Meter,
+ opt ...metric.Int64ObservableCounterOption,
+) (SDKExporterLogExportedObservable, error) {
+ // Check if the meter is nil.
+ if m == nil {
+ return SDKExporterLogExportedObservable{noop.Int64ObservableCounter{}}, nil
+ }
+
+ if len(opt) == 0 {
+ opt = newSDKExporterLogExportedObservableOpts
+ } else {
+ opt = append(opt, newSDKExporterLogExportedObservableOpts...)
+ }
+
+ i, err := m.Int64ObservableCounter(
+ "otel.sdk.exporter.log.exported",
+ opt...,
+ )
+ if err != nil {
+ return SDKExporterLogExportedObservable{noop.Int64ObservableCounter{}}, err
+ }
+ return SDKExporterLogExportedObservable{i}, nil
+}
+
+// Inst returns the underlying metric instrument.
+func (m SDKExporterLogExportedObservable) Inst() metric.Int64ObservableCounter {
+ return m.Int64ObservableCounter
+}
+
+// Name returns the semantic convention name of the instrument.
+func (SDKExporterLogExportedObservable) Name() string {
+ return "otel.sdk.exporter.log.exported"
+}
+
+// Unit returns the semantic convention unit of the instrument
+func (SDKExporterLogExportedObservable) Unit() string {
+ return "{log_record}"
+}
+
+// Description returns the semantic convention description of the instrument
+func (SDKExporterLogExportedObservable) Description() string {
+ return "The number of log records for which the export has finished, either successful or failed."
+}
+
+// AttrErrorType returns an optional attribute for the "error.type" semantic
+// convention. It represents the describes a class of error the operation ended
+// with.
+func (SDKExporterLogExportedObservable) AttrErrorType(val ErrorTypeAttr) attribute.KeyValue {
+ return attribute.String("error.type", string(val))
+}
+
+// AttrComponentName returns an optional attribute for the "otel.component.name"
+// semantic convention. It represents a name uniquely identifying the instance of
+// the OpenTelemetry component within its containing SDK instance.
+func (SDKExporterLogExportedObservable) AttrComponentName(val string) attribute.KeyValue {
+ return attribute.String("otel.component.name", val)
+}
+
+// AttrComponentType returns an optional attribute for the "otel.component.type"
+// semantic convention. It represents a name identifying the type of the
+// OpenTelemetry component.
+func (SDKExporterLogExportedObservable) AttrComponentType(val ComponentTypeAttr) attribute.KeyValue {
+ return attribute.String("otel.component.type", string(val))
+}
+
+// AttrServerAddress returns an optional attribute for the "server.address"
+// semantic convention. It represents the server domain name if available without
+// reverse DNS lookup; otherwise, IP address or Unix domain socket name.
+func (SDKExporterLogExportedObservable) AttrServerAddress(val string) attribute.KeyValue {
+ return attribute.String("server.address", val)
+}
+
+// AttrServerPort returns an optional attribute for the "server.port" semantic
+// convention. It represents the server port number.
+func (SDKExporterLogExportedObservable) AttrServerPort(val int) attribute.KeyValue {
+ return attribute.Int("server.port", val)
+}
+
// SDKExporterLogInflight is an instrument used to record metric values
// conforming to the "otel.sdk.exporter.log.inflight" semantic conventions. It
// represents the number of log records which were passed to the exporter, but
@@ -347,6 +449,9 @@ func (m SDKExporterLogInflight) Add(
incr int64,
attrs ...attribute.KeyValue,
) {
+ if !m.Int64UpDownCounter.Enabled(ctx) {
+ return
+ }
if len(attrs) == 0 {
m.Int64UpDownCounter.Add(ctx, incr)
return
@@ -354,6 +459,7 @@ func (m SDKExporterLogInflight) Add(
o := addOptPool.Get().(*[]metric.AddOption)
defer func() {
+ clear(*o)
*o = (*o)[:0]
addOptPool.Put(o)
}()
@@ -373,6 +479,9 @@ func (m SDKExporterLogInflight) Add(
// For successful exports, `error.type` MUST NOT be set. For failed exports,
// `error.type` MUST contain the failure cause.
func (m SDKExporterLogInflight) AddSet(ctx context.Context, incr int64, set attribute.Set) {
+ if !m.Int64UpDownCounter.Enabled(ctx) {
+ return
+ }
if set.Len() == 0 {
m.Int64UpDownCounter.Add(ctx, incr)
return
@@ -380,6 +489,7 @@ func (m SDKExporterLogInflight) AddSet(ctx context.Context, incr int64, set attr
o := addOptPool.Get().(*[]metric.AddOption)
defer func() {
+ clear(*o)
*o = (*o)[:0]
addOptPool.Put(o)
}()
@@ -415,6 +525,93 @@ func (SDKExporterLogInflight) AttrServerPort(val int) attribute.KeyValue {
return attribute.Int("server.port", val)
}
+// SDKExporterLogInflightObservable is an instrument used to record metric values
+// conforming to the "otel.sdk.exporter.log.inflight" semantic conventions. It
+// represents the number of log records which were passed to the exporter, but
+// that have not been exported yet (neither successful, nor failed).
+type SDKExporterLogInflightObservable struct {
+ metric.Int64ObservableUpDownCounter
+}
+
+var newSDKExporterLogInflightObservableOpts = []metric.Int64ObservableUpDownCounterOption{
+ metric.WithDescription("The number of log records which were passed to the exporter, but that have not been exported yet (neither successful, nor failed)."),
+ metric.WithUnit("{log_record}"),
+}
+
+// NewSDKExporterLogInflightObservable returns a new
+// SDKExporterLogInflightObservable instrument.
+func NewSDKExporterLogInflightObservable(
+ m metric.Meter,
+ opt ...metric.Int64ObservableUpDownCounterOption,
+) (SDKExporterLogInflightObservable, error) {
+ // Check if the meter is nil.
+ if m == nil {
+ return SDKExporterLogInflightObservable{noop.Int64ObservableUpDownCounter{}}, nil
+ }
+
+ if len(opt) == 0 {
+ opt = newSDKExporterLogInflightObservableOpts
+ } else {
+ opt = append(opt, newSDKExporterLogInflightObservableOpts...)
+ }
+
+ i, err := m.Int64ObservableUpDownCounter(
+ "otel.sdk.exporter.log.inflight",
+ opt...,
+ )
+ if err != nil {
+ return SDKExporterLogInflightObservable{noop.Int64ObservableUpDownCounter{}}, err
+ }
+ return SDKExporterLogInflightObservable{i}, nil
+}
+
+// Inst returns the underlying metric instrument.
+func (m SDKExporterLogInflightObservable) Inst() metric.Int64ObservableUpDownCounter {
+ return m.Int64ObservableUpDownCounter
+}
+
+// Name returns the semantic convention name of the instrument.
+func (SDKExporterLogInflightObservable) Name() string {
+ return "otel.sdk.exporter.log.inflight"
+}
+
+// Unit returns the semantic convention unit of the instrument
+func (SDKExporterLogInflightObservable) Unit() string {
+ return "{log_record}"
+}
+
+// Description returns the semantic convention description of the instrument
+func (SDKExporterLogInflightObservable) Description() string {
+ return "The number of log records which were passed to the exporter, but that have not been exported yet (neither successful, nor failed)."
+}
+
+// AttrComponentName returns an optional attribute for the "otel.component.name"
+// semantic convention. It represents a name uniquely identifying the instance of
+// the OpenTelemetry component within its containing SDK instance.
+func (SDKExporterLogInflightObservable) AttrComponentName(val string) attribute.KeyValue {
+ return attribute.String("otel.component.name", val)
+}
+
+// AttrComponentType returns an optional attribute for the "otel.component.type"
+// semantic convention. It represents a name identifying the type of the
+// OpenTelemetry component.
+func (SDKExporterLogInflightObservable) AttrComponentType(val ComponentTypeAttr) attribute.KeyValue {
+ return attribute.String("otel.component.type", string(val))
+}
+
+// AttrServerAddress returns an optional attribute for the "server.address"
+// semantic convention. It represents the server domain name if available without
+// reverse DNS lookup; otherwise, IP address or Unix domain socket name.
+func (SDKExporterLogInflightObservable) AttrServerAddress(val string) attribute.KeyValue {
+ return attribute.String("server.address", val)
+}
+
+// AttrServerPort returns an optional attribute for the "server.port" semantic
+// convention. It represents the server port number.
+func (SDKExporterLogInflightObservable) AttrServerPort(val int) attribute.KeyValue {
+ return attribute.Int("server.port", val)
+}
+
// SDKExporterMetricDataPointExported is an instrument used to record metric
// values conforming to the "otel.sdk.exporter.metric_data_point.exported"
// semantic conventions. It represents the number of metric data points for which
@@ -491,6 +688,9 @@ func (m SDKExporterMetricDataPointExported) Add(
incr int64,
attrs ...attribute.KeyValue,
) {
+ if !m.Int64Counter.Enabled(ctx) {
+ return
+ }
if len(attrs) == 0 {
m.Int64Counter.Add(ctx, incr)
return
@@ -498,6 +698,7 @@ func (m SDKExporterMetricDataPointExported) Add(
o := addOptPool.Get().(*[]metric.AddOption)
defer func() {
+ clear(*o)
*o = (*o)[:0]
addOptPool.Put(o)
}()
@@ -522,6 +723,9 @@ func (m SDKExporterMetricDataPointExported) Add(
// If no rejection reason is available, `rejected` SHOULD be used as value for
// `error.type`.
func (m SDKExporterMetricDataPointExported) AddSet(ctx context.Context, incr int64, set attribute.Set) {
+ if !m.Int64Counter.Enabled(ctx) {
+ return
+ }
if set.Len() == 0 {
m.Int64Counter.Add(ctx, incr)
return
@@ -529,6 +733,7 @@ func (m SDKExporterMetricDataPointExported) AddSet(ctx context.Context, incr int
o := addOptPool.Get().(*[]metric.AddOption)
defer func() {
+ clear(*o)
*o = (*o)[:0]
addOptPool.Put(o)
}()
@@ -571,6 +776,100 @@ func (SDKExporterMetricDataPointExported) AttrServerPort(val int) attribute.KeyV
return attribute.Int("server.port", val)
}
+// SDKExporterMetricDataPointExportedObservable is an instrument used to record
+// metric values conforming to the "otel.sdk.exporter.metric_data_point.exported"
+// semantic conventions. It represents the number of metric data points for which
+// the export has finished, either successful or failed.
+type SDKExporterMetricDataPointExportedObservable struct {
+ metric.Int64ObservableCounter
+}
+
+var newSDKExporterMetricDataPointExportedObservableOpts = []metric.Int64ObservableCounterOption{
+ metric.WithDescription("The number of metric data points for which the export has finished, either successful or failed."),
+ metric.WithUnit("{data_point}"),
+}
+
+// NewSDKExporterMetricDataPointExportedObservable returns a new
+// SDKExporterMetricDataPointExportedObservable instrument.
+func NewSDKExporterMetricDataPointExportedObservable(
+ m metric.Meter,
+ opt ...metric.Int64ObservableCounterOption,
+) (SDKExporterMetricDataPointExportedObservable, error) {
+ // Check if the meter is nil.
+ if m == nil {
+ return SDKExporterMetricDataPointExportedObservable{noop.Int64ObservableCounter{}}, nil
+ }
+
+ if len(opt) == 0 {
+ opt = newSDKExporterMetricDataPointExportedObservableOpts
+ } else {
+ opt = append(opt, newSDKExporterMetricDataPointExportedObservableOpts...)
+ }
+
+ i, err := m.Int64ObservableCounter(
+ "otel.sdk.exporter.metric_data_point.exported",
+ opt...,
+ )
+ if err != nil {
+ return SDKExporterMetricDataPointExportedObservable{noop.Int64ObservableCounter{}}, err
+ }
+ return SDKExporterMetricDataPointExportedObservable{i}, nil
+}
+
+// Inst returns the underlying metric instrument.
+func (m SDKExporterMetricDataPointExportedObservable) Inst() metric.Int64ObservableCounter {
+ return m.Int64ObservableCounter
+}
+
+// Name returns the semantic convention name of the instrument.
+func (SDKExporterMetricDataPointExportedObservable) Name() string {
+ return "otel.sdk.exporter.metric_data_point.exported"
+}
+
+// Unit returns the semantic convention unit of the instrument
+func (SDKExporterMetricDataPointExportedObservable) Unit() string {
+ return "{data_point}"
+}
+
+// Description returns the semantic convention description of the instrument
+func (SDKExporterMetricDataPointExportedObservable) Description() string {
+ return "The number of metric data points for which the export has finished, either successful or failed."
+}
+
+// AttrErrorType returns an optional attribute for the "error.type" semantic
+// convention. It represents the describes a class of error the operation ended
+// with.
+func (SDKExporterMetricDataPointExportedObservable) AttrErrorType(val ErrorTypeAttr) attribute.KeyValue {
+ return attribute.String("error.type", string(val))
+}
+
+// AttrComponentName returns an optional attribute for the "otel.component.name"
+// semantic convention. It represents a name uniquely identifying the instance of
+// the OpenTelemetry component within its containing SDK instance.
+func (SDKExporterMetricDataPointExportedObservable) AttrComponentName(val string) attribute.KeyValue {
+ return attribute.String("otel.component.name", val)
+}
+
+// AttrComponentType returns an optional attribute for the "otel.component.type"
+// semantic convention. It represents a name identifying the type of the
+// OpenTelemetry component.
+func (SDKExporterMetricDataPointExportedObservable) AttrComponentType(val ComponentTypeAttr) attribute.KeyValue {
+ return attribute.String("otel.component.type", string(val))
+}
+
+// AttrServerAddress returns an optional attribute for the "server.address"
+// semantic convention. It represents the server domain name if available without
+// reverse DNS lookup; otherwise, IP address or Unix domain socket name.
+func (SDKExporterMetricDataPointExportedObservable) AttrServerAddress(val string) attribute.KeyValue {
+ return attribute.String("server.address", val)
+}
+
+// AttrServerPort returns an optional attribute for the "server.port" semantic
+// convention. It represents the server port number.
+func (SDKExporterMetricDataPointExportedObservable) AttrServerPort(val int) attribute.KeyValue {
+ return attribute.Int("server.port", val)
+}
+
// SDKExporterMetricDataPointInflight is an instrument used to record metric
// values conforming to the "otel.sdk.exporter.metric_data_point.inflight"
// semantic conventions. It represents the number of metric data points which
@@ -643,6 +942,9 @@ func (m SDKExporterMetricDataPointInflight) Add(
incr int64,
attrs ...attribute.KeyValue,
) {
+ if !m.Int64UpDownCounter.Enabled(ctx) {
+ return
+ }
if len(attrs) == 0 {
m.Int64UpDownCounter.Add(ctx, incr)
return
@@ -650,6 +952,7 @@ func (m SDKExporterMetricDataPointInflight) Add(
o := addOptPool.Get().(*[]metric.AddOption)
defer func() {
+ clear(*o)
*o = (*o)[:0]
addOptPool.Put(o)
}()
@@ -669,6 +972,9 @@ func (m SDKExporterMetricDataPointInflight) Add(
// For successful exports, `error.type` MUST NOT be set. For failed exports,
// `error.type` MUST contain the failure cause.
func (m SDKExporterMetricDataPointInflight) AddSet(ctx context.Context, incr int64, set attribute.Set) {
+ if !m.Int64UpDownCounter.Enabled(ctx) {
+ return
+ }
if set.Len() == 0 {
m.Int64UpDownCounter.Add(ctx, incr)
return
@@ -676,6 +982,7 @@ func (m SDKExporterMetricDataPointInflight) AddSet(ctx context.Context, incr int
o := addOptPool.Get().(*[]metric.AddOption)
defer func() {
+ clear(*o)
*o = (*o)[:0]
addOptPool.Put(o)
}()
@@ -711,6 +1018,94 @@ func (SDKExporterMetricDataPointInflight) AttrServerPort(val int) attribute.KeyV
return attribute.Int("server.port", val)
}
+// SDKExporterMetricDataPointInflightObservable is an instrument used to record
+// metric values conforming to the "otel.sdk.exporter.metric_data_point.inflight"
+// semantic conventions. It represents the number of metric data points which
+// were passed to the exporter, but that have not been exported yet (neither
+// successful, nor failed).
+type SDKExporterMetricDataPointInflightObservable struct {
+ metric.Int64ObservableUpDownCounter
+}
+
+var newSDKExporterMetricDataPointInflightObservableOpts = []metric.Int64ObservableUpDownCounterOption{
+ metric.WithDescription("The number of metric data points which were passed to the exporter, but that have not been exported yet (neither successful, nor failed)."),
+ metric.WithUnit("{data_point}"),
+}
+
+// NewSDKExporterMetricDataPointInflightObservable returns a new
+// SDKExporterMetricDataPointInflightObservable instrument.
+func NewSDKExporterMetricDataPointInflightObservable(
+ m metric.Meter,
+ opt ...metric.Int64ObservableUpDownCounterOption,
+) (SDKExporterMetricDataPointInflightObservable, error) {
+ // Check if the meter is nil.
+ if m == nil {
+ return SDKExporterMetricDataPointInflightObservable{noop.Int64ObservableUpDownCounter{}}, nil
+ }
+
+ if len(opt) == 0 {
+ opt = newSDKExporterMetricDataPointInflightObservableOpts
+ } else {
+ opt = append(opt, newSDKExporterMetricDataPointInflightObservableOpts...)
+ }
+
+ i, err := m.Int64ObservableUpDownCounter(
+ "otel.sdk.exporter.metric_data_point.inflight",
+ opt...,
+ )
+ if err != nil {
+ return SDKExporterMetricDataPointInflightObservable{noop.Int64ObservableUpDownCounter{}}, err
+ }
+ return SDKExporterMetricDataPointInflightObservable{i}, nil
+}
+
+// Inst returns the underlying metric instrument.
+func (m SDKExporterMetricDataPointInflightObservable) Inst() metric.Int64ObservableUpDownCounter {
+ return m.Int64ObservableUpDownCounter
+}
+
+// Name returns the semantic convention name of the instrument.
+func (SDKExporterMetricDataPointInflightObservable) Name() string {
+ return "otel.sdk.exporter.metric_data_point.inflight"
+}
+
+// Unit returns the semantic convention unit of the instrument
+func (SDKExporterMetricDataPointInflightObservable) Unit() string {
+ return "{data_point}"
+}
+
+// Description returns the semantic convention description of the instrument
+func (SDKExporterMetricDataPointInflightObservable) Description() string {
+ return "The number of metric data points which were passed to the exporter, but that have not been exported yet (neither successful, nor failed)."
+}
+
+// AttrComponentName returns an optional attribute for the "otel.component.name"
+// semantic convention. It represents a name uniquely identifying the instance of
+// the OpenTelemetry component within its containing SDK instance.
+func (SDKExporterMetricDataPointInflightObservable) AttrComponentName(val string) attribute.KeyValue {
+ return attribute.String("otel.component.name", val)
+}
+
+// AttrComponentType returns an optional attribute for the "otel.component.type"
+// semantic convention. It represents a name identifying the type of the
+// OpenTelemetry component.
+func (SDKExporterMetricDataPointInflightObservable) AttrComponentType(val ComponentTypeAttr) attribute.KeyValue {
+ return attribute.String("otel.component.type", string(val))
+}
+
+// AttrServerAddress returns an optional attribute for the "server.address"
+// semantic convention. It represents the server domain name if available without
+// reverse DNS lookup; otherwise, IP address or Unix domain socket name.
+func (SDKExporterMetricDataPointInflightObservable) AttrServerAddress(val string) attribute.KeyValue {
+ return attribute.String("server.address", val)
+}
+
+// AttrServerPort returns an optional attribute for the "server.port" semantic
+// convention. It represents the server port number.
+func (SDKExporterMetricDataPointInflightObservable) AttrServerPort(val int) attribute.KeyValue {
+ return attribute.Int("server.port", val)
+}
+
// SDKExporterOperationDuration is an instrument used to record metric values
// conforming to the "otel.sdk.exporter.operation.duration" semantic conventions.
// It represents the duration of exporting a batch of telemetry records.
@@ -788,6 +1183,9 @@ func (m SDKExporterOperationDuration) Record(
val float64,
attrs ...attribute.KeyValue,
) {
+ if !m.Float64Histogram.Enabled(ctx) {
+ return
+ }
if len(attrs) == 0 {
m.Float64Histogram.Record(ctx, val)
return
@@ -795,6 +1193,7 @@ func (m SDKExporterOperationDuration) Record(
o := recOptPool.Get().(*[]metric.RecordOption)
defer func() {
+ clear(*o)
*o = (*o)[:0]
recOptPool.Put(o)
}()
@@ -821,6 +1220,9 @@ func (m SDKExporterOperationDuration) Record(
// [http]: https://github.com/open-telemetry/opentelemetry-proto/blob/v1.5.0/docs/specification.md#full-success-1
// [grpc]: https://github.com/open-telemetry/opentelemetry-proto/blob/v1.5.0/docs/specification.md#full-success
func (m SDKExporterOperationDuration) RecordSet(ctx context.Context, val float64, set attribute.Set) {
+ if !m.Float64Histogram.Enabled(ctx) {
+ return
+ }
if set.Len() == 0 {
m.Float64Histogram.Record(ctx, val)
return
@@ -828,6 +1230,7 @@ func (m SDKExporterOperationDuration) RecordSet(ctx context.Context, val float64
o := recOptPool.Get().(*[]metric.RecordOption)
defer func() {
+ clear(*o)
*o = (*o)[:0]
recOptPool.Put(o)
}()
@@ -959,6 +1362,9 @@ func (m SDKExporterSpanExported) Add(
incr int64,
attrs ...attribute.KeyValue,
) {
+ if !m.Int64Counter.Enabled(ctx) {
+ return
+ }
if len(attrs) == 0 {
m.Int64Counter.Add(ctx, incr)
return
@@ -966,6 +1372,7 @@ func (m SDKExporterSpanExported) Add(
o := addOptPool.Get().(*[]metric.AddOption)
defer func() {
+ clear(*o)
*o = (*o)[:0]
addOptPool.Put(o)
}()
@@ -990,6 +1397,9 @@ func (m SDKExporterSpanExported) Add(
// If no rejection reason is available, `rejected` SHOULD be used as value for
// `error.type`.
func (m SDKExporterSpanExported) AddSet(ctx context.Context, incr int64, set attribute.Set) {
+ if !m.Int64Counter.Enabled(ctx) {
+ return
+ }
if set.Len() == 0 {
m.Int64Counter.Add(ctx, incr)
return
@@ -997,6 +1407,7 @@ func (m SDKExporterSpanExported) AddSet(ctx context.Context, incr int64, set att
o := addOptPool.Get().(*[]metric.AddOption)
defer func() {
+ clear(*o)
*o = (*o)[:0]
addOptPool.Put(o)
}()
@@ -1039,6 +1450,100 @@ func (SDKExporterSpanExported) AttrServerPort(val int) attribute.KeyValue {
return attribute.Int("server.port", val)
}
+// SDKExporterSpanExportedObservable is an instrument used to record metric
+// values conforming to the "otel.sdk.exporter.span.exported" semantic
+// conventions. It represents the number of spans for which the export has
+// finished, either successful or failed.
+type SDKExporterSpanExportedObservable struct {
+ metric.Int64ObservableCounter
+}
+
+var newSDKExporterSpanExportedObservableOpts = []metric.Int64ObservableCounterOption{
+ metric.WithDescription("The number of spans for which the export has finished, either successful or failed."),
+ metric.WithUnit("{span}"),
+}
+
+// NewSDKExporterSpanExportedObservable returns a new
+// SDKExporterSpanExportedObservable instrument.
+func NewSDKExporterSpanExportedObservable(
+ m metric.Meter,
+ opt ...metric.Int64ObservableCounterOption,
+) (SDKExporterSpanExportedObservable, error) {
+ // Check if the meter is nil.
+ if m == nil {
+ return SDKExporterSpanExportedObservable{noop.Int64ObservableCounter{}}, nil
+ }
+
+ if len(opt) == 0 {
+ opt = newSDKExporterSpanExportedObservableOpts
+ } else {
+ opt = append(opt, newSDKExporterSpanExportedObservableOpts...)
+ }
+
+ i, err := m.Int64ObservableCounter(
+ "otel.sdk.exporter.span.exported",
+ opt...,
+ )
+ if err != nil {
+ return SDKExporterSpanExportedObservable{noop.Int64ObservableCounter{}}, err
+ }
+ return SDKExporterSpanExportedObservable{i}, nil
+}
+
+// Inst returns the underlying metric instrument.
+func (m SDKExporterSpanExportedObservable) Inst() metric.Int64ObservableCounter {
+ return m.Int64ObservableCounter
+}
+
+// Name returns the semantic convention name of the instrument.
+func (SDKExporterSpanExportedObservable) Name() string {
+ return "otel.sdk.exporter.span.exported"
+}
+
+// Unit returns the semantic convention unit of the instrument
+func (SDKExporterSpanExportedObservable) Unit() string {
+ return "{span}"
+}
+
+// Description returns the semantic convention description of the instrument
+func (SDKExporterSpanExportedObservable) Description() string {
+ return "The number of spans for which the export has finished, either successful or failed."
+}
+
+// AttrErrorType returns an optional attribute for the "error.type" semantic
+// convention. It represents the describes a class of error the operation ended
+// with.
+func (SDKExporterSpanExportedObservable) AttrErrorType(val ErrorTypeAttr) attribute.KeyValue {
+ return attribute.String("error.type", string(val))
+}
+
+// AttrComponentName returns an optional attribute for the "otel.component.name"
+// semantic convention. It represents a name uniquely identifying the instance of
+// the OpenTelemetry component within its containing SDK instance.
+func (SDKExporterSpanExportedObservable) AttrComponentName(val string) attribute.KeyValue {
+ return attribute.String("otel.component.name", val)
+}
+
+// AttrComponentType returns an optional attribute for the "otel.component.type"
+// semantic convention. It represents a name identifying the type of the
+// OpenTelemetry component.
+func (SDKExporterSpanExportedObservable) AttrComponentType(val ComponentTypeAttr) attribute.KeyValue {
+ return attribute.String("otel.component.type", string(val))
+}
+
+// AttrServerAddress returns an optional attribute for the "server.address"
+// semantic convention. It represents the server domain name if available without
+// reverse DNS lookup; otherwise, IP address or Unix domain socket name.
+func (SDKExporterSpanExportedObservable) AttrServerAddress(val string) attribute.KeyValue {
+ return attribute.String("server.address", val)
+}
+
+// AttrServerPort returns an optional attribute for the "server.port" semantic
+// convention. It represents the server port number.
+func (SDKExporterSpanExportedObservable) AttrServerPort(val int) attribute.KeyValue {
+ return attribute.Int("server.port", val)
+}
+
// SDKExporterSpanInflight is an instrument used to record metric values
// conforming to the "otel.sdk.exporter.span.inflight" semantic conventions. It
// represents the number of spans which were passed to the exporter, but that
@@ -1109,6 +1614,9 @@ func (m SDKExporterSpanInflight) Add(
incr int64,
attrs ...attribute.KeyValue,
) {
+ if !m.Int64UpDownCounter.Enabled(ctx) {
+ return
+ }
if len(attrs) == 0 {
m.Int64UpDownCounter.Add(ctx, incr)
return
@@ -1116,6 +1624,7 @@ func (m SDKExporterSpanInflight) Add(
o := addOptPool.Get().(*[]metric.AddOption)
defer func() {
+ clear(*o)
*o = (*o)[:0]
addOptPool.Put(o)
}()
@@ -1135,6 +1644,9 @@ func (m SDKExporterSpanInflight) Add(
// For successful exports, `error.type` MUST NOT be set. For failed exports,
// `error.type` MUST contain the failure cause.
func (m SDKExporterSpanInflight) AddSet(ctx context.Context, incr int64, set attribute.Set) {
+ if !m.Int64UpDownCounter.Enabled(ctx) {
+ return
+ }
if set.Len() == 0 {
m.Int64UpDownCounter.Add(ctx, incr)
return
@@ -1142,6 +1654,7 @@ func (m SDKExporterSpanInflight) AddSet(ctx context.Context, incr int64, set att
o := addOptPool.Get().(*[]metric.AddOption)
defer func() {
+ clear(*o)
*o = (*o)[:0]
addOptPool.Put(o)
}()
@@ -1177,6 +1690,94 @@ func (SDKExporterSpanInflight) AttrServerPort(val int) attribute.KeyValue {
return attribute.Int("server.port", val)
}
+// SDKExporterSpanInflightObservable is an instrument used to record metric
+// values conforming to the "otel.sdk.exporter.span.inflight" semantic
+// conventions. It represents the number of spans which were passed to the
+// exporter, but that have not been exported yet (neither successful, nor
+// failed).
+type SDKExporterSpanInflightObservable struct {
+ metric.Int64ObservableUpDownCounter
+}
+
+var newSDKExporterSpanInflightObservableOpts = []metric.Int64ObservableUpDownCounterOption{
+ metric.WithDescription("The number of spans which were passed to the exporter, but that have not been exported yet (neither successful, nor failed)."),
+ metric.WithUnit("{span}"),
+}
+
+// NewSDKExporterSpanInflightObservable returns a new
+// SDKExporterSpanInflightObservable instrument.
+func NewSDKExporterSpanInflightObservable(
+ m metric.Meter,
+ opt ...metric.Int64ObservableUpDownCounterOption,
+) (SDKExporterSpanInflightObservable, error) {
+ // Check if the meter is nil.
+ if m == nil {
+ return SDKExporterSpanInflightObservable{noop.Int64ObservableUpDownCounter{}}, nil
+ }
+
+ if len(opt) == 0 {
+ opt = newSDKExporterSpanInflightObservableOpts
+ } else {
+ opt = append(opt, newSDKExporterSpanInflightObservableOpts...)
+ }
+
+ i, err := m.Int64ObservableUpDownCounter(
+ "otel.sdk.exporter.span.inflight",
+ opt...,
+ )
+ if err != nil {
+ return SDKExporterSpanInflightObservable{noop.Int64ObservableUpDownCounter{}}, err
+ }
+ return SDKExporterSpanInflightObservable{i}, nil
+}
+
+// Inst returns the underlying metric instrument.
+func (m SDKExporterSpanInflightObservable) Inst() metric.Int64ObservableUpDownCounter {
+ return m.Int64ObservableUpDownCounter
+}
+
+// Name returns the semantic convention name of the instrument.
+func (SDKExporterSpanInflightObservable) Name() string {
+ return "otel.sdk.exporter.span.inflight"
+}
+
+// Unit returns the semantic convention unit of the instrument
+func (SDKExporterSpanInflightObservable) Unit() string {
+ return "{span}"
+}
+
+// Description returns the semantic convention description of the instrument
+func (SDKExporterSpanInflightObservable) Description() string {
+ return "The number of spans which were passed to the exporter, but that have not been exported yet (neither successful, nor failed)."
+}
+
+// AttrComponentName returns an optional attribute for the "otel.component.name"
+// semantic convention. It represents a name uniquely identifying the instance of
+// the OpenTelemetry component within its containing SDK instance.
+func (SDKExporterSpanInflightObservable) AttrComponentName(val string) attribute.KeyValue {
+ return attribute.String("otel.component.name", val)
+}
+
+// AttrComponentType returns an optional attribute for the "otel.component.type"
+// semantic convention. It represents a name identifying the type of the
+// OpenTelemetry component.
+func (SDKExporterSpanInflightObservable) AttrComponentType(val ComponentTypeAttr) attribute.KeyValue {
+ return attribute.String("otel.component.type", string(val))
+}
+
+// AttrServerAddress returns an optional attribute for the "server.address"
+// semantic convention. It represents the server domain name if available without
+// reverse DNS lookup; otherwise, IP address or Unix domain socket name.
+func (SDKExporterSpanInflightObservable) AttrServerAddress(val string) attribute.KeyValue {
+ return attribute.String("server.address", val)
+}
+
+// AttrServerPort returns an optional attribute for the "server.port" semantic
+// convention. It represents the server port number.
+func (SDKExporterSpanInflightObservable) AttrServerPort(val int) attribute.KeyValue {
+ return attribute.Int("server.port", val)
+}
+
// SDKLogCreated is an instrument used to record metric values conforming to the
// "otel.sdk.log.created" semantic conventions. It represents the number of logs
// submitted to enabled SDK Loggers.
@@ -1237,6 +1838,9 @@ func (SDKLogCreated) Description() string {
// Add adds incr to the existing count for attrs.
func (m SDKLogCreated) Add(ctx context.Context, incr int64, attrs ...attribute.KeyValue) {
+ if !m.Int64Counter.Enabled(ctx) {
+ return
+ }
if len(attrs) == 0 {
m.Int64Counter.Add(ctx, incr)
return
@@ -1244,29 +1848,92 @@ func (m SDKLogCreated) Add(ctx context.Context, incr int64, attrs ...attribute.K
o := addOptPool.Get().(*[]metric.AddOption)
defer func() {
+ clear(*o)
*o = (*o)[:0]
addOptPool.Put(o)
}()
- *o = append(*o, metric.WithAttributes(attrs...))
- m.Int64Counter.Add(ctx, incr, *o...)
+ *o = append(*o, metric.WithAttributes(attrs...))
+ m.Int64Counter.Add(ctx, incr, *o...)
+}
+
+// AddSet adds incr to the existing count for set.
+func (m SDKLogCreated) AddSet(ctx context.Context, incr int64, set attribute.Set) {
+ if !m.Int64Counter.Enabled(ctx) {
+ return
+ }
+ if set.Len() == 0 {
+ m.Int64Counter.Add(ctx, incr)
+ return
+ }
+
+ o := addOptPool.Get().(*[]metric.AddOption)
+ defer func() {
+ clear(*o)
+ *o = (*o)[:0]
+ addOptPool.Put(o)
+ }()
+
+ *o = append(*o, metric.WithAttributeSet(set))
+ m.Int64Counter.Add(ctx, incr, *o...)
+}
+
+// SDKLogCreatedObservable is an instrument used to record metric values
+// conforming to the "otel.sdk.log.created" semantic conventions. It represents
+// the number of logs submitted to enabled SDK Loggers.
+type SDKLogCreatedObservable struct {
+ metric.Int64ObservableCounter
+}
+
+var newSDKLogCreatedObservableOpts = []metric.Int64ObservableCounterOption{
+ metric.WithDescription("The number of logs submitted to enabled SDK Loggers."),
+ metric.WithUnit("{log_record}"),
+}
+
+// NewSDKLogCreatedObservable returns a new SDKLogCreatedObservable instrument.
+func NewSDKLogCreatedObservable(
+ m metric.Meter,
+ opt ...metric.Int64ObservableCounterOption,
+) (SDKLogCreatedObservable, error) {
+ // Check if the meter is nil.
+ if m == nil {
+ return SDKLogCreatedObservable{noop.Int64ObservableCounter{}}, nil
+ }
+
+ if len(opt) == 0 {
+ opt = newSDKLogCreatedObservableOpts
+ } else {
+ opt = append(opt, newSDKLogCreatedObservableOpts...)
+ }
+
+ i, err := m.Int64ObservableCounter(
+ "otel.sdk.log.created",
+ opt...,
+ )
+ if err != nil {
+ return SDKLogCreatedObservable{noop.Int64ObservableCounter{}}, err
+ }
+ return SDKLogCreatedObservable{i}, nil
+}
+
+// Inst returns the underlying metric instrument.
+func (m SDKLogCreatedObservable) Inst() metric.Int64ObservableCounter {
+ return m.Int64ObservableCounter
}
-// AddSet adds incr to the existing count for set.
-func (m SDKLogCreated) AddSet(ctx context.Context, incr int64, set attribute.Set) {
- if set.Len() == 0 {
- m.Int64Counter.Add(ctx, incr)
- return
- }
+// Name returns the semantic convention name of the instrument.
+func (SDKLogCreatedObservable) Name() string {
+ return "otel.sdk.log.created"
+}
- o := addOptPool.Get().(*[]metric.AddOption)
- defer func() {
- *o = (*o)[:0]
- addOptPool.Put(o)
- }()
+// Unit returns the semantic convention unit of the instrument
+func (SDKLogCreatedObservable) Unit() string {
+ return "{log_record}"
+}
- *o = append(*o, metric.WithAttributeSet(set))
- m.Int64Counter.Add(ctx, incr, *o...)
+// Description returns the semantic convention description of the instrument
+func (SDKLogCreatedObservable) Description() string {
+ return "The number of logs submitted to enabled SDK Loggers."
}
// SDKMetricReaderCollectionDuration is an instrument used to record metric
@@ -1343,6 +2010,9 @@ func (m SDKMetricReaderCollectionDuration) Record(
val float64,
attrs ...attribute.KeyValue,
) {
+ if !m.Float64Histogram.Enabled(ctx) {
+ return
+ }
if len(attrs) == 0 {
m.Float64Histogram.Record(ctx, val)
return
@@ -1350,6 +2020,7 @@ func (m SDKMetricReaderCollectionDuration) Record(
o := recOptPool.Get().(*[]metric.RecordOption)
defer func() {
+ clear(*o)
*o = (*o)[:0]
recOptPool.Put(o)
}()
@@ -1372,6 +2043,9 @@ func (m SDKMetricReaderCollectionDuration) Record(
// while others fail. In that case `error.type` SHOULD be set to any of the
// failure causes.
func (m SDKMetricReaderCollectionDuration) RecordSet(ctx context.Context, val float64, set attribute.Set) {
+ if !m.Float64Histogram.Enabled(ctx) {
+ return
+ }
if set.Len() == 0 {
m.Float64Histogram.Record(ctx, val)
return
@@ -1379,6 +2053,7 @@ func (m SDKMetricReaderCollectionDuration) RecordSet(ctx context.Context, val fl
o := recOptPool.Get().(*[]metric.RecordOption)
defer func() {
+ clear(*o)
*o = (*o)[:0]
recOptPool.Put(o)
}()
@@ -1481,6 +2156,9 @@ func (m SDKProcessorLogProcessed) Add(
incr int64,
attrs ...attribute.KeyValue,
) {
+ if !m.Int64Counter.Enabled(ctx) {
+ return
+ }
if len(attrs) == 0 {
m.Int64Counter.Add(ctx, incr)
return
@@ -1488,6 +2166,7 @@ func (m SDKProcessorLogProcessed) Add(
o := addOptPool.Get().(*[]metric.AddOption)
defer func() {
+ clear(*o)
*o = (*o)[:0]
addOptPool.Put(o)
}()
@@ -1510,6 +2189,9 @@ func (m SDKProcessorLogProcessed) Add(
// considered to be processed already when it has been submitted to the exporter,
// not when the corresponding export call has finished.
func (m SDKProcessorLogProcessed) AddSet(ctx context.Context, incr int64, set attribute.Set) {
+ if !m.Int64Counter.Enabled(ctx) {
+ return
+ }
if set.Len() == 0 {
m.Int64Counter.Add(ctx, incr)
return
@@ -1517,6 +2199,7 @@ func (m SDKProcessorLogProcessed) AddSet(ctx context.Context, incr int64, set at
o := addOptPool.Get().(*[]metric.AddOption)
defer func() {
+ clear(*o)
*o = (*o)[:0]
addOptPool.Put(o)
}()
@@ -1547,6 +2230,88 @@ func (SDKProcessorLogProcessed) AttrComponentType(val ComponentTypeAttr) attribu
return attribute.String("otel.component.type", string(val))
}
+// SDKProcessorLogProcessedObservable is an instrument used to record metric
+// values conforming to the "otel.sdk.processor.log.processed" semantic
+// conventions. It represents the number of log records for which the processing
+// has finished, either successful or failed.
+type SDKProcessorLogProcessedObservable struct {
+ metric.Int64ObservableCounter
+}
+
+var newSDKProcessorLogProcessedObservableOpts = []metric.Int64ObservableCounterOption{
+ metric.WithDescription("The number of log records for which the processing has finished, either successful or failed."),
+ metric.WithUnit("{log_record}"),
+}
+
+// NewSDKProcessorLogProcessedObservable returns a new
+// SDKProcessorLogProcessedObservable instrument.
+func NewSDKProcessorLogProcessedObservable(
+ m metric.Meter,
+ opt ...metric.Int64ObservableCounterOption,
+) (SDKProcessorLogProcessedObservable, error) {
+ // Check if the meter is nil.
+ if m == nil {
+ return SDKProcessorLogProcessedObservable{noop.Int64ObservableCounter{}}, nil
+ }
+
+ if len(opt) == 0 {
+ opt = newSDKProcessorLogProcessedObservableOpts
+ } else {
+ opt = append(opt, newSDKProcessorLogProcessedObservableOpts...)
+ }
+
+ i, err := m.Int64ObservableCounter(
+ "otel.sdk.processor.log.processed",
+ opt...,
+ )
+ if err != nil {
+ return SDKProcessorLogProcessedObservable{noop.Int64ObservableCounter{}}, err
+ }
+ return SDKProcessorLogProcessedObservable{i}, nil
+}
+
+// Inst returns the underlying metric instrument.
+func (m SDKProcessorLogProcessedObservable) Inst() metric.Int64ObservableCounter {
+ return m.Int64ObservableCounter
+}
+
+// Name returns the semantic convention name of the instrument.
+func (SDKProcessorLogProcessedObservable) Name() string {
+ return "otel.sdk.processor.log.processed"
+}
+
+// Unit returns the semantic convention unit of the instrument
+func (SDKProcessorLogProcessedObservable) Unit() string {
+ return "{log_record}"
+}
+
+// Description returns the semantic convention description of the instrument
+func (SDKProcessorLogProcessedObservable) Description() string {
+ return "The number of log records for which the processing has finished, either successful or failed."
+}
+
+// AttrErrorType returns an optional attribute for the "error.type" semantic
+// convention. It represents a low-cardinality description of the failure reason.
+// SDK Batching Log Record Processors MUST use `queue_full` for log records
+// dropped due to a full queue.
+func (SDKProcessorLogProcessedObservable) AttrErrorType(val ErrorTypeAttr) attribute.KeyValue {
+ return attribute.String("error.type", string(val))
+}
+
+// AttrComponentName returns an optional attribute for the "otel.component.name"
+// semantic convention. It represents a name uniquely identifying the instance of
+// the OpenTelemetry component within its containing SDK instance.
+func (SDKProcessorLogProcessedObservable) AttrComponentName(val string) attribute.KeyValue {
+ return attribute.String("otel.component.name", val)
+}
+
+// AttrComponentType returns an optional attribute for the "otel.component.type"
+// semantic convention. It represents a name identifying the type of the
+// OpenTelemetry component.
+func (SDKProcessorLogProcessedObservable) AttrComponentType(val ComponentTypeAttr) attribute.KeyValue {
+ return attribute.String("otel.component.type", string(val))
+}
+
// SDKProcessorLogQueueCapacity is an instrument used to record metric values
// conforming to the "otel.sdk.processor.log.queue.capacity" semantic
// conventions. It represents the maximum number of log records the queue of a
@@ -1768,6 +2533,9 @@ func (m SDKProcessorSpanProcessed) Add(
incr int64,
attrs ...attribute.KeyValue,
) {
+ if !m.Int64Counter.Enabled(ctx) {
+ return
+ }
if len(attrs) == 0 {
m.Int64Counter.Add(ctx, incr)
return
@@ -1775,6 +2543,7 @@ func (m SDKProcessorSpanProcessed) Add(
o := addOptPool.Get().(*[]metric.AddOption)
defer func() {
+ clear(*o)
*o = (*o)[:0]
addOptPool.Put(o)
}()
@@ -1797,6 +2566,9 @@ func (m SDKProcessorSpanProcessed) Add(
// processed already when it has been submitted to the exporter, not when the
// corresponding export call has finished.
func (m SDKProcessorSpanProcessed) AddSet(ctx context.Context, incr int64, set attribute.Set) {
+ if !m.Int64Counter.Enabled(ctx) {
+ return
+ }
if set.Len() == 0 {
m.Int64Counter.Add(ctx, incr)
return
@@ -1804,6 +2576,7 @@ func (m SDKProcessorSpanProcessed) AddSet(ctx context.Context, incr int64, set a
o := addOptPool.Get().(*[]metric.AddOption)
defer func() {
+ clear(*o)
*o = (*o)[:0]
addOptPool.Put(o)
}()
@@ -1834,6 +2607,88 @@ func (SDKProcessorSpanProcessed) AttrComponentType(val ComponentTypeAttr) attrib
return attribute.String("otel.component.type", string(val))
}
+// SDKProcessorSpanProcessedObservable is an instrument used to record metric
+// values conforming to the "otel.sdk.processor.span.processed" semantic
+// conventions. It represents the number of spans for which the processing has
+// finished, either successful or failed.
+type SDKProcessorSpanProcessedObservable struct {
+ metric.Int64ObservableCounter
+}
+
+var newSDKProcessorSpanProcessedObservableOpts = []metric.Int64ObservableCounterOption{
+ metric.WithDescription("The number of spans for which the processing has finished, either successful or failed."),
+ metric.WithUnit("{span}"),
+}
+
+// NewSDKProcessorSpanProcessedObservable returns a new
+// SDKProcessorSpanProcessedObservable instrument.
+func NewSDKProcessorSpanProcessedObservable(
+ m metric.Meter,
+ opt ...metric.Int64ObservableCounterOption,
+) (SDKProcessorSpanProcessedObservable, error) {
+ // Check if the meter is nil.
+ if m == nil {
+ return SDKProcessorSpanProcessedObservable{noop.Int64ObservableCounter{}}, nil
+ }
+
+ if len(opt) == 0 {
+ opt = newSDKProcessorSpanProcessedObservableOpts
+ } else {
+ opt = append(opt, newSDKProcessorSpanProcessedObservableOpts...)
+ }
+
+ i, err := m.Int64ObservableCounter(
+ "otel.sdk.processor.span.processed",
+ opt...,
+ )
+ if err != nil {
+ return SDKProcessorSpanProcessedObservable{noop.Int64ObservableCounter{}}, err
+ }
+ return SDKProcessorSpanProcessedObservable{i}, nil
+}
+
+// Inst returns the underlying metric instrument.
+func (m SDKProcessorSpanProcessedObservable) Inst() metric.Int64ObservableCounter {
+ return m.Int64ObservableCounter
+}
+
+// Name returns the semantic convention name of the instrument.
+func (SDKProcessorSpanProcessedObservable) Name() string {
+ return "otel.sdk.processor.span.processed"
+}
+
+// Unit returns the semantic convention unit of the instrument
+func (SDKProcessorSpanProcessedObservable) Unit() string {
+ return "{span}"
+}
+
+// Description returns the semantic convention description of the instrument
+func (SDKProcessorSpanProcessedObservable) Description() string {
+ return "The number of spans for which the processing has finished, either successful or failed."
+}
+
+// AttrErrorType returns an optional attribute for the "error.type" semantic
+// convention. It represents a low-cardinality description of the failure reason.
+// SDK Batching Span Processors MUST use `queue_full` for spans dropped due to a
+// full queue.
+func (SDKProcessorSpanProcessedObservable) AttrErrorType(val ErrorTypeAttr) attribute.KeyValue {
+ return attribute.String("error.type", string(val))
+}
+
+// AttrComponentName returns an optional attribute for the "otel.component.name"
+// semantic convention. It represents a name uniquely identifying the instance of
+// the OpenTelemetry component within its containing SDK instance.
+func (SDKProcessorSpanProcessedObservable) AttrComponentName(val string) attribute.KeyValue {
+ return attribute.String("otel.component.name", val)
+}
+
+// AttrComponentType returns an optional attribute for the "otel.component.type"
+// semantic convention. It represents a name identifying the type of the
+// OpenTelemetry component.
+func (SDKProcessorSpanProcessedObservable) AttrComponentType(val ComponentTypeAttr) attribute.KeyValue {
+ return attribute.String("otel.component.type", string(val))
+}
+
// SDKProcessorSpanQueueCapacity is an instrument used to record metric values
// conforming to the "otel.sdk.processor.span.queue.capacity" semantic
// conventions. It represents the maximum number of spans the queue of a given
@@ -2049,6 +2904,9 @@ func (m SDKSpanLive) Add(
incr int64,
attrs ...attribute.KeyValue,
) {
+ if !m.Int64UpDownCounter.Enabled(ctx) {
+ return
+ }
if len(attrs) == 0 {
m.Int64UpDownCounter.Add(ctx, incr)
return
@@ -2056,6 +2914,7 @@ func (m SDKSpanLive) Add(
o := addOptPool.Get().(*[]metric.AddOption)
defer func() {
+ clear(*o)
*o = (*o)[:0]
addOptPool.Put(o)
}()
@@ -2072,6 +2931,9 @@ func (m SDKSpanLive) Add(
// AddSet adds incr to the existing count for set.
func (m SDKSpanLive) AddSet(ctx context.Context, incr int64, set attribute.Set) {
+ if !m.Int64UpDownCounter.Enabled(ctx) {
+ return
+ }
if set.Len() == 0 {
m.Int64UpDownCounter.Add(ctx, incr)
return
@@ -2079,6 +2941,7 @@ func (m SDKSpanLive) AddSet(ctx context.Context, incr int64, set attribute.Set)
o := addOptPool.Get().(*[]metric.AddOption)
defer func() {
+ clear(*o)
*o = (*o)[:0]
addOptPool.Put(o)
}()
@@ -2094,6 +2957,72 @@ func (SDKSpanLive) AttrSpanSamplingResult(val SpanSamplingResultAttr) attribute.
return attribute.String("otel.span.sampling_result", string(val))
}
+// SDKSpanLiveObservable is an instrument used to record metric values conforming
+// to the "otel.sdk.span.live" semantic conventions. It represents the number of
+// created spans with `recording=true` for which the end operation has not been
+// called yet.
+type SDKSpanLiveObservable struct {
+ metric.Int64ObservableUpDownCounter
+}
+
+var newSDKSpanLiveObservableOpts = []metric.Int64ObservableUpDownCounterOption{
+ metric.WithDescription("The number of created spans with `recording=true` for which the end operation has not been called yet."),
+ metric.WithUnit("{span}"),
+}
+
+// NewSDKSpanLiveObservable returns a new SDKSpanLiveObservable instrument.
+func NewSDKSpanLiveObservable(
+ m metric.Meter,
+ opt ...metric.Int64ObservableUpDownCounterOption,
+) (SDKSpanLiveObservable, error) {
+ // Check if the meter is nil.
+ if m == nil {
+ return SDKSpanLiveObservable{noop.Int64ObservableUpDownCounter{}}, nil
+ }
+
+ if len(opt) == 0 {
+ opt = newSDKSpanLiveObservableOpts
+ } else {
+ opt = append(opt, newSDKSpanLiveObservableOpts...)
+ }
+
+ i, err := m.Int64ObservableUpDownCounter(
+ "otel.sdk.span.live",
+ opt...,
+ )
+ if err != nil {
+ return SDKSpanLiveObservable{noop.Int64ObservableUpDownCounter{}}, err
+ }
+ return SDKSpanLiveObservable{i}, nil
+}
+
+// Inst returns the underlying metric instrument.
+func (m SDKSpanLiveObservable) Inst() metric.Int64ObservableUpDownCounter {
+ return m.Int64ObservableUpDownCounter
+}
+
+// Name returns the semantic convention name of the instrument.
+func (SDKSpanLiveObservable) Name() string {
+ return "otel.sdk.span.live"
+}
+
+// Unit returns the semantic convention unit of the instrument
+func (SDKSpanLiveObservable) Unit() string {
+ return "{span}"
+}
+
+// Description returns the semantic convention description of the instrument
+func (SDKSpanLiveObservable) Description() string {
+ return "The number of created spans with `recording=true` for which the end operation has not been called yet."
+}
+
+// AttrSpanSamplingResult returns an optional attribute for the
+// "otel.span.sampling_result" semantic convention. It represents the result
+// value of the sampler for this span.
+func (SDKSpanLiveObservable) AttrSpanSamplingResult(val SpanSamplingResultAttr) attribute.KeyValue {
+ return attribute.String("otel.span.sampling_result", string(val))
+}
+
// SDKSpanStarted is an instrument used to record metric values conforming to the
// "otel.sdk.span.started" semantic conventions. It represents the number of
// created spans.
@@ -2163,6 +3092,9 @@ func (m SDKSpanStarted) Add(
incr int64,
attrs ...attribute.KeyValue,
) {
+ if !m.Int64Counter.Enabled(ctx) {
+ return
+ }
if len(attrs) == 0 {
m.Int64Counter.Add(ctx, incr)
return
@@ -2170,6 +3102,7 @@ func (m SDKSpanStarted) Add(
o := addOptPool.Get().(*[]metric.AddOption)
defer func() {
+ clear(*o)
*o = (*o)[:0]
addOptPool.Put(o)
}()
@@ -2189,6 +3122,9 @@ func (m SDKSpanStarted) Add(
// Implementations MUST record this metric for all spans, even for non-recording
// ones.
func (m SDKSpanStarted) AddSet(ctx context.Context, incr int64, set attribute.Set) {
+ if !m.Int64Counter.Enabled(ctx) {
+ return
+ }
if set.Len() == 0 {
m.Int64Counter.Add(ctx, incr)
return
@@ -2196,6 +3132,7 @@ func (m SDKSpanStarted) AddSet(ctx context.Context, incr int64, set attribute.Se
o := addOptPool.Get().(*[]metric.AddOption)
defer func() {
+ clear(*o)
*o = (*o)[:0]
addOptPool.Put(o)
}()
@@ -2220,3 +3157,78 @@ func (SDKSpanStarted) AttrSpanParentOrigin(val SpanParentOriginAttr) attribute.K
func (SDKSpanStarted) AttrSpanSamplingResult(val SpanSamplingResultAttr) attribute.KeyValue {
return attribute.String("otel.span.sampling_result", string(val))
}
+
+// SDKSpanStartedObservable is an instrument used to record metric values
+// conforming to the "otel.sdk.span.started" semantic conventions. It represents
+// the number of created spans.
+type SDKSpanStartedObservable struct {
+ metric.Int64ObservableCounter
+}
+
+var newSDKSpanStartedObservableOpts = []metric.Int64ObservableCounterOption{
+ metric.WithDescription("The number of created spans."),
+ metric.WithUnit("{span}"),
+}
+
+// NewSDKSpanStartedObservable returns a new SDKSpanStartedObservable instrument.
+func NewSDKSpanStartedObservable(
+ m metric.Meter,
+ opt ...metric.Int64ObservableCounterOption,
+) (SDKSpanStartedObservable, error) {
+ // Check if the meter is nil.
+ if m == nil {
+ return SDKSpanStartedObservable{noop.Int64ObservableCounter{}}, nil
+ }
+
+ if len(opt) == 0 {
+ opt = newSDKSpanStartedObservableOpts
+ } else {
+ opt = append(opt, newSDKSpanStartedObservableOpts...)
+ }
+
+ i, err := m.Int64ObservableCounter(
+ "otel.sdk.span.started",
+ opt...,
+ )
+ if err != nil {
+ return SDKSpanStartedObservable{noop.Int64ObservableCounter{}}, err
+ }
+ return SDKSpanStartedObservable{i}, nil
+}
+
+// Inst returns the underlying metric instrument.
+func (m SDKSpanStartedObservable) Inst() metric.Int64ObservableCounter {
+ return m.Int64ObservableCounter
+}
+
+// Name returns the semantic convention name of the instrument.
+func (SDKSpanStartedObservable) Name() string {
+ return "otel.sdk.span.started"
+}
+
+// Unit returns the semantic convention unit of the instrument
+func (SDKSpanStartedObservable) Unit() string {
+ return "{span}"
+}
+
+// Description returns the semantic convention description of the instrument
+func (SDKSpanStartedObservable) Description() string {
+ return "The number of created spans."
+}
+
+// AttrSpanParentOrigin returns an optional attribute for the
+// "otel.span.parent.origin" semantic convention. It represents the determines
+// whether the span has a parent span, and if so, [whether it is a remote parent]
+// .
+//
+// [whether it is a remote parent]: https://opentelemetry.io/docs/specs/otel/trace/api/#isremote
+func (SDKSpanStartedObservable) AttrSpanParentOrigin(val SpanParentOriginAttr) attribute.KeyValue {
+ return attribute.String("otel.span.parent.origin", string(val))
+}
+
+// AttrSpanSamplingResult returns an optional attribute for the
+// "otel.span.sampling_result" semantic convention. It represents the result
+// value of the sampler for this span.
+func (SDKSpanStartedObservable) AttrSpanSamplingResult(val SpanSamplingResultAttr) attribute.KeyValue {
+ return attribute.String("otel.span.sampling_result", string(val))
+}
diff --git a/vendor/go.opentelemetry.io/otel/semconv/v1.40.0/schema.go b/vendor/go.opentelemetry.io/otel/semconv/v1.41.0/schema.go
similarity index 73%
rename from vendor/go.opentelemetry.io/otel/semconv/v1.40.0/schema.go
rename to vendor/go.opentelemetry.io/otel/semconv/v1.41.0/schema.go
index a07ffa3361..24948a48f8 100644
--- a/vendor/go.opentelemetry.io/otel/semconv/v1.40.0/schema.go
+++ b/vendor/go.opentelemetry.io/otel/semconv/v1.41.0/schema.go
@@ -1,9 +1,11 @@
+// Code generated from semantic convention specification. DO NOT EDIT.
+
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0
-package semconv // import "go.opentelemetry.io/otel/semconv/v1.40.0"
+package semconv // import "go.opentelemetry.io/otel/semconv/v1.41.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.40.0"
+const SchemaURL = "https://opentelemetry.io/schemas/1.41.0"
diff --git a/vendor/go.opentelemetry.io/otel/trace/auto.go b/vendor/go.opentelemetry.io/otel/trace/auto.go
index 9316fd0ac4..a75cf047d5 100644
--- a/vendor/go.opentelemetry.io/otel/trace/auto.go
+++ b/vendor/go.opentelemetry.io/otel/trace/auto.go
@@ -20,7 +20,7 @@ import (
"go.opentelemetry.io/otel/attribute"
"go.opentelemetry.io/otel/codes"
- semconv "go.opentelemetry.io/otel/semconv/v1.40.0"
+ semconv "go.opentelemetry.io/otel/semconv/v1.41.0"
"go.opentelemetry.io/otel/trace/embedded"
"go.opentelemetry.io/otel/trace/internal/telemetry"
)
@@ -314,6 +314,14 @@ func convAttrValue(value attribute.Value) telemetry.Value {
case attribute.STRING:
v := truncate(maxSpan.AttrValueLen, value.AsString())
return telemetry.StringValue(v)
+ case attribute.BYTESLICE:
+ // len(v.AsString()) is identical to len(v.AsByteSlice()) but
+ // avoids allocating the full slice before truncation.
+ s := value.AsString()
+ if maxSpan.AttrValueLen >= 0 && len(s) > maxSpan.AttrValueLen {
+ return telemetry.BytesValue([]byte(s[:maxSpan.AttrValueLen]))
+ }
+ return telemetry.BytesValue([]byte(s))
case attribute.BOOLSLICE:
slice := value.AsBoolSlice()
out := make([]telemetry.Value, 0, len(slice))
@@ -343,6 +351,13 @@ func convAttrValue(value attribute.Value) telemetry.Value {
out = append(out, telemetry.StringValue(v))
}
return telemetry.SliceValue(out...)
+ case attribute.SLICE:
+ slice := value.AsSlice()
+ out := make([]telemetry.Value, 0, len(slice))
+ for _, v := range slice {
+ out = append(out, convAttrValue(v))
+ }
+ return telemetry.SliceValue(out...)
}
return telemetry.Value{}
}
@@ -463,7 +478,8 @@ func (s *autoSpan) RecordError(err error, opts ...EventOption) {
cfg := NewEventConfig(opts...)
attrs := cfg.Attributes()
- attrs = append(attrs,
+ attrs = append(
+ attrs,
semconv.ExceptionType(typeStr(err)),
semconv.ExceptionMessage(err.Error()),
)
diff --git a/vendor/go.opentelemetry.io/otel/trace/config.go b/vendor/go.opentelemetry.io/otel/trace/config.go
index d9ecef1cad..4cedba5ac7 100644
--- a/vendor/go.opentelemetry.io/otel/trace/config.go
+++ b/vendor/go.opentelemetry.io/otel/trace/config.go
@@ -34,10 +34,17 @@ func (t *TracerConfig) SchemaURL() string {
return t.schemaURL
}
+type experimentalOption interface {
+ Experimental()
+}
+
// NewTracerConfig applies all the options to a returned TracerConfig.
func NewTracerConfig(options ...TracerOption) TracerConfig {
var config TracerConfig
for _, option := range options {
+ if _, ok := option.(experimentalOption); ok {
+ continue
+ }
config = option.apply(config)
}
return config
@@ -103,6 +110,9 @@ func (cfg *SpanConfig) SpanKind() SpanKind {
func NewSpanStartConfig(options ...SpanStartOption) SpanConfig {
var c SpanConfig
for _, option := range options {
+ if _, ok := option.(experimentalOption); ok {
+ continue
+ }
c = option.applySpanStart(c)
}
return c
@@ -115,6 +125,9 @@ func NewSpanStartConfig(options ...SpanStartOption) SpanConfig {
func NewSpanEndConfig(options ...SpanEndOption) SpanConfig {
var c SpanConfig
for _, option := range options {
+ if _, ok := option.(experimentalOption); ok {
+ continue
+ }
c = option.applySpanEnd(c)
}
return c
@@ -167,6 +180,9 @@ func (cfg *EventConfig) StackTrace() bool {
func NewEventConfig(options ...EventOption) EventConfig {
var c EventConfig
for _, option := range options {
+ if _, ok := option.(experimentalOption); ok {
+ continue
+ }
c = option.applyEvent(c)
}
if c.timestamp.IsZero() {
diff --git a/vendor/go.opentelemetry.io/otel/trace/internal/telemetry/span.go b/vendor/go.opentelemetry.io/otel/trace/internal/telemetry/span.go
index e7ca62c660..61c7819a23 100644
--- a/vendor/go.opentelemetry.io/otel/trace/internal/telemetry/span.go
+++ b/vendor/go.opentelemetry.io/otel/trace/internal/telemetry/span.go
@@ -314,9 +314,9 @@ type SpanEvent struct {
}
// MarshalJSON encodes e into OTLP formatted JSON.
-func (e SpanEvent) MarshalJSON() ([]byte, error) {
- t := e.Time.UnixNano()
- if e.Time.IsZero() || t < 0 {
+func (se SpanEvent) MarshalJSON() ([]byte, error) {
+ t := se.Time.UnixNano()
+ if se.Time.IsZero() || t < 0 {
t = 0
}
@@ -325,7 +325,7 @@ func (e SpanEvent) MarshalJSON() ([]byte, error) {
Alias
Time uint64 `json:"timeUnixNano,omitempty"`
}{
- Alias: Alias(e),
+ Alias: Alias(se),
Time: uint64(t), // nolint: gosec // >0 checked above
})
}
diff --git a/vendor/go.opentelemetry.io/otel/version.go b/vendor/go.opentelemetry.io/otel/version.go
index 1db4f47e43..72746acfdb 100644
--- a/vendor/go.opentelemetry.io/otel/version.go
+++ b/vendor/go.opentelemetry.io/otel/version.go
@@ -5,5 +5,5 @@ package otel // import "go.opentelemetry.io/otel"
// Version is the current release version of OpenTelemetry in use.
func Version() string {
- return "1.43.0"
+ return "1.44.0"
}
diff --git a/vendor/go.opentelemetry.io/otel/versions.yaml b/vendor/go.opentelemetry.io/otel/versions.yaml
index bcc6ee78a4..d6dbf803ef 100644
--- a/vendor/go.opentelemetry.io/otel/versions.yaml
+++ b/vendor/go.opentelemetry.io/otel/versions.yaml
@@ -3,7 +3,7 @@
module-sets:
stable-v1:
- version: v1.43.0
+ version: v1.44.0
modules:
- go.opentelemetry.io/otel
- go.opentelemetry.io/otel/bridge/opencensus
@@ -22,11 +22,12 @@ module-sets:
- go.opentelemetry.io/otel/sdk/metric
- go.opentelemetry.io/otel/trace
experimental-metrics:
- version: v0.65.0
+ version: v0.66.0
modules:
- go.opentelemetry.io/otel/exporters/prometheus
+ - go.opentelemetry.io/otel/metric/x
experimental-logs:
- version: v0.19.0
+ version: v0.20.0
modules:
- go.opentelemetry.io/otel/log
- go.opentelemetry.io/otel/log/logtest
@@ -36,7 +37,7 @@ module-sets:
- go.opentelemetry.io/otel/exporters/otlp/otlplog/otlploghttp
- go.opentelemetry.io/otel/exporters/stdout/stdoutlog
experimental-schema:
- version: v0.0.16
+ version: v0.0.17
modules:
- go.opentelemetry.io/otel/schema
excluded-modules:
@@ -55,6 +56,9 @@ modules:
go.opentelemetry.io/otel/exporters/otlp/otlplog/otlploggrpc:
version-refs:
- ./internal/version.go
+ go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp:
+ version-refs:
+ - ./internal/version.go
go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc:
version-refs:
- ./internal/version.go
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux.go b/vendor/golang.org/x/sys/unix/ztypes_linux.go
index d11d5b96a4..526a0d5f43 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux.go
@@ -6397,3 +6397,79 @@ const (
MPOL_PREFERRED_MANY = 0x5
MPOL_WEIGHTED_INTERLEAVE = 0x6
)
+
+const (
+ GPIO_V2_GET_LINEINFO_IOCTL = 0xc100b405
+ GPIO_V2_GET_LINE_IOCTL = 0xc250b407
+ GPIO_V2_LINE_GET_VALUES_IOCTL = 0xc010b40e
+ GPIO_V2_LINE_SET_VALUES_IOCTL = 0xc010b40f
+ GPIO_V2_GET_LINEINFO_WATCH_IOCTL = 0xc100b406
+ GPIO_GET_LINEINFO_UNWATCH_IOCTL = 0xc004b40c
+)
+const (
+ GPIO_V2_LINE_ATTR_ID_FLAGS = 0x1
+ GPIO_V2_LINE_ATTR_ID_OUTPUT_VALUES = 0x2
+ GPIO_V2_LINE_ATTR_ID_DEBOUNCE = 0x3
+ GPIO_V2_LINE_CHANGED_REQUESTED = 0x1
+ GPIO_V2_LINE_CHANGED_RELEASED = 0x2
+ GPIO_V2_LINE_CHANGED_CONFIG = 0x3
+ GPIO_V2_LINE_EVENT_RISING_EDGE = 0x1
+ GPIO_V2_LINE_EVENT_FALLING_EDGE = 0x2
+)
+
+type GPIOChipInfo struct {
+ Name [32]byte
+ Label [32]byte
+ Lines uint32
+}
+type GPIOV2LineValues struct {
+ Bits uint64
+ Mask uint64
+}
+type GPIOV2LineAttribute struct {
+ Id uint32
+ _ uint32
+ Flags uint64
+}
+type GPIOV2LineConfigAttribute struct {
+ Attr GPIOV2LineAttribute
+ Mask uint64
+}
+type GPIOV2LineConfig struct {
+ Flags uint64
+ Num_attrs uint32
+ _ [5]uint32
+ Attrs [10]GPIOV2LineConfigAttribute
+}
+type GPIOV2LineRequest struct {
+ Offsets [64]uint32
+ Consumer [32]byte
+ Config GPIOV2LineConfig
+ Num_lines uint32
+ Event_buffer_size uint32
+ _ [5]uint32
+ Fd int32
+}
+type GPIOV2LineInfo struct {
+ Name [32]byte
+ Consumer [32]byte
+ Offset uint32
+ Num_attrs uint32
+ Flags uint64
+ Attrs [10]GPIOV2LineAttribute
+ _ [4]uint32
+}
+type GPIOV2LineInfoChanged struct {
+ Info GPIOV2LineInfo
+ Timestamp_ns uint64
+ Event_type uint32
+ _ [5]uint32
+}
+type GPIOV2LineEvent struct {
+ Timestamp_ns uint64
+ Id uint32
+ Offset uint32
+ Seqno uint32
+ Line_seqno uint32
+ _ [6]uint32
+}
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux_386.go b/vendor/golang.org/x/sys/unix/ztypes_linux_386.go
index 97ef790deb..aede1de7f2 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux_386.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux_386.go
@@ -711,3 +711,7 @@ type SysvShmDesc struct {
_ uint32
_ uint32
}
+
+const (
+ GPIO_GET_CHIPINFO_IOCTL = 0x8044b401
+)
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux_amd64.go b/vendor/golang.org/x/sys/unix/ztypes_linux_amd64.go
index 90b50da680..bb3bc4dc2c 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux_amd64.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux_amd64.go
@@ -725,3 +725,7 @@ type SysvShmDesc struct {
_ uint64
_ uint64
}
+
+const (
+ GPIO_GET_CHIPINFO_IOCTL = 0x8044b401
+)
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux_arm.go b/vendor/golang.org/x/sys/unix/ztypes_linux_arm.go
index acda136851..1fdf4c5175 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux_arm.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux_arm.go
@@ -705,3 +705,7 @@ type SysvShmDesc struct {
_ uint32
_ uint32
}
+
+const (
+ GPIO_GET_CHIPINFO_IOCTL = 0x8044b401
+)
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux_arm64.go b/vendor/golang.org/x/sys/unix/ztypes_linux_arm64.go
index ef7a99e1f9..063e6f0b41 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux_arm64.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux_arm64.go
@@ -704,3 +704,7 @@ type SysvShmDesc struct {
_ uint64
_ uint64
}
+
+const (
+ GPIO_GET_CHIPINFO_IOCTL = 0x8044b401
+)
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux_loong64.go b/vendor/golang.org/x/sys/unix/ztypes_linux_loong64.go
index 966063dfc1..9cf836c708 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux_loong64.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux_loong64.go
@@ -705,3 +705,7 @@ type SysvShmDesc struct {
_ uint64
_ uint64
}
+
+const (
+ GPIO_GET_CHIPINFO_IOCTL = 0x8044b401
+)
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux_mips.go b/vendor/golang.org/x/sys/unix/ztypes_linux_mips.go
index dc53b20b74..1d222fcb31 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux_mips.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux_mips.go
@@ -710,3 +710,7 @@ type SysvShmDesc struct {
Ctime_high uint16
_ uint16
}
+
+const (
+ GPIO_GET_CHIPINFO_IOCTL = 0x4044b401
+)
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux_mips64.go b/vendor/golang.org/x/sys/unix/ztypes_linux_mips64.go
index 9ad0aa8c31..912cc4ab63 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux_mips64.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux_mips64.go
@@ -707,3 +707,7 @@ type SysvShmDesc struct {
_ uint64
_ uint64
}
+
+const (
+ GPIO_GET_CHIPINFO_IOCTL = 0x4044b401
+)
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux_mips64le.go b/vendor/golang.org/x/sys/unix/ztypes_linux_mips64le.go
index 29d55493d5..1e358ef34f 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux_mips64le.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux_mips64le.go
@@ -707,3 +707,7 @@ type SysvShmDesc struct {
_ uint64
_ uint64
}
+
+const (
+ GPIO_GET_CHIPINFO_IOCTL = 0x4044b401
+)
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux_mipsle.go b/vendor/golang.org/x/sys/unix/ztypes_linux_mipsle.go
index a4d9e15848..df59f32f5e 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux_mipsle.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux_mipsle.go
@@ -710,3 +710,7 @@ type SysvShmDesc struct {
Ctime_high uint16
_ uint16
}
+
+const (
+ GPIO_GET_CHIPINFO_IOCTL = 0x4044b401
+)
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux_ppc.go b/vendor/golang.org/x/sys/unix/ztypes_linux_ppc.go
index f8a2977716..29355aa0bf 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux_ppc.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux_ppc.go
@@ -718,3 +718,7 @@ type SysvShmDesc struct {
_ uint32
_ [4]byte
}
+
+const (
+ GPIO_GET_CHIPINFO_IOCTL = 0x4044b401
+)
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux_ppc64.go b/vendor/golang.org/x/sys/unix/ztypes_linux_ppc64.go
index 4158d6c4ee..c6083a15d7 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux_ppc64.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux_ppc64.go
@@ -713,3 +713,7 @@ type SysvShmDesc struct {
_ uint64
_ uint64
}
+
+const (
+ GPIO_GET_CHIPINFO_IOCTL = 0x4044b401
+)
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux_ppc64le.go b/vendor/golang.org/x/sys/unix/ztypes_linux_ppc64le.go
index 1035af49f7..6321cc7626 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux_ppc64le.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux_ppc64le.go
@@ -713,3 +713,7 @@ type SysvShmDesc struct {
_ uint64
_ uint64
}
+
+const (
+ GPIO_GET_CHIPINFO_IOCTL = 0x4044b401
+)
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux_riscv64.go b/vendor/golang.org/x/sys/unix/ztypes_linux_riscv64.go
index 2297125d3c..b44f402feb 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux_riscv64.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux_riscv64.go
@@ -792,3 +792,7 @@ const (
RISCV_HWPROBE_KEY_ZICBOZ_BLOCK_SIZE = 0x6
RISCV_HWPROBE_WHICH_CPUS = 0x1
)
+
+const (
+ GPIO_GET_CHIPINFO_IOCTL = 0x8044b401
+)
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux_s390x.go b/vendor/golang.org/x/sys/unix/ztypes_linux_s390x.go
index 8481e9bd98..b22c795a64 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux_s390x.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux_s390x.go
@@ -727,3 +727,7 @@ type SysvShmDesc struct {
_ uint64
_ uint64
}
+
+const (
+ GPIO_GET_CHIPINFO_IOCTL = 0x8044b401
+)
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux_sparc64.go b/vendor/golang.org/x/sys/unix/ztypes_linux_sparc64.go
index a6828a0310..0b18075b53 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux_sparc64.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux_sparc64.go
@@ -708,3 +708,7 @@ type SysvShmDesc struct {
_ uint64
_ uint64
}
+
+const (
+ GPIO_GET_CHIPINFO_IOCTL = 0x4044b401
+)
diff --git a/vendor/google.golang.org/genproto/googleapis/api/expr/v1alpha1/checked.pb.go b/vendor/google.golang.org/genproto/googleapis/api/expr/v1alpha1/checked.pb.go
index af9c44d93e..c197b1a679 100644
--- a/vendor/google.golang.org/genproto/googleapis/api/expr/v1alpha1/checked.pb.go
+++ b/vendor/google.golang.org/genproto/googleapis/api/expr/v1alpha1/checked.pb.go
@@ -1,4 +1,4 @@
-// Copyright 2025 Google LLC
+// Copyright 2026 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
@@ -14,7 +14,7 @@
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
-// protoc-gen-go v1.26.0
+// protoc-gen-go v1.36.11
// protoc v4.24.4
// source: google/api/expr/v1alpha1/checked.proto
@@ -23,6 +23,7 @@ package expr
import (
reflect "reflect"
sync "sync"
+ unsafe "unsafe"
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
@@ -175,10 +176,7 @@ func (Type_WellKnownType) EnumDescriptor() ([]byte, []int) {
// A CEL expression which has been successfully type checked.
type CheckedExpr struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
+ state protoimpl.MessageState `protogen:"open.v1"`
// A map from expression ids to resolved references.
//
// The following entries are in this table:
@@ -194,13 +192,13 @@ type CheckedExpr struct {
// called.
// - Every CreateStruct expression for a message has an entry, identifying
// the message.
- 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"`
+ 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"`
// A map from expression ids to types.
//
// Every expression node which has a type different than DYN has a mapping
// here. If an expression has type DYN, it is omitted from this map to save
// space.
- 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"`
+ 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"`
// The source info derived from input that generated the parsed `expr` and
// any optimizations made during the type-checking pass.
SourceInfo *SourceInfo `protobuf:"bytes,5,opt,name=source_info,json=sourceInfo,proto3" json:"source_info,omitempty"`
@@ -214,16 +212,16 @@ type CheckedExpr struct {
ExprVersion string `protobuf:"bytes,6,opt,name=expr_version,json=exprVersion,proto3" json:"expr_version,omitempty"`
// The checked expression. Semantically equivalent to the parsed `expr`, but
// may have structural differences.
- Expr *Expr `protobuf:"bytes,4,opt,name=expr,proto3" json:"expr,omitempty"`
+ Expr *Expr `protobuf:"bytes,4,opt,name=expr,proto3" json:"expr,omitempty"`
+ unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *CheckedExpr) Reset() {
*x = CheckedExpr{}
- if protoimpl.UnsafeEnabled {
- mi := &file_google_api_expr_v1alpha1_checked_proto_msgTypes[0]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_google_api_expr_v1alpha1_checked_proto_msgTypes[0]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *CheckedExpr) String() string {
@@ -234,7 +232,7 @@ func (*CheckedExpr) ProtoMessage() {}
func (x *CheckedExpr) ProtoReflect() protoreflect.Message {
mi := &file_google_api_expr_v1alpha1_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)
@@ -286,13 +284,10 @@ func (x *CheckedExpr) GetExpr() *Expr {
// Represents a CEL type.
type Type struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
+ state protoimpl.MessageState `protogen:"open.v1"`
// The kind of type.
//
- // Types that are assignable to TypeKind:
+ // Types that are valid to be assigned to TypeKind:
//
// *Type_Dyn
// *Type_Null
@@ -307,16 +302,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_google_api_expr_v1alpha1_checked_proto_msgTypes[1]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_google_api_expr_v1alpha1_checked_proto_msgTypes[1]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Type) String() string {
@@ -327,7 +322,7 @@ func (*Type) ProtoMessage() {}
func (x *Type) ProtoReflect() protoreflect.Message {
mi := &file_google_api_expr_v1alpha1_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)
@@ -342,100 +337,126 @@ func (*Type) Descriptor() ([]byte, []int) {
return file_google_api_expr_v1alpha1_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_NULL_VALUE
+ 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
}
@@ -554,10 +575,7 @@ func (*Type_AbstractType_) isType_TypeKind() {}
// A declaration is part of the contract between the expression, the agent
// evaluating that expression, and the caller requesting evaluation.
type Decl struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
+ state protoimpl.MessageState `protogen:"open.v1"`
// The fully qualified name of the declaration.
//
// Declarations are organized in containers and this represents the full path
@@ -571,20 +589,20 @@ type Decl struct {
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
// Required. The declaration kind.
//
- // Types that are assignable to DeclKind:
+ // 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_google_api_expr_v1alpha1_checked_proto_msgTypes[2]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_google_api_expr_v1alpha1_checked_proto_msgTypes[2]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Decl) String() string {
@@ -595,7 +613,7 @@ func (*Decl) ProtoMessage() {}
func (x *Decl) ProtoReflect() protoreflect.Message {
mi := &file_google_api_expr_v1alpha1_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)
@@ -617,23 +635,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
}
@@ -658,10 +680,7 @@ func (*Decl_Function) isDecl_DeclKind() {}
// Describes a resolved reference to a declaration.
type Reference struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
+ state protoimpl.MessageState `protogen:"open.v1"`
// The fully qualified name of the declaration.
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
// For references to functions, this is a list of `Overload.overload_id`
@@ -676,16 +695,16 @@ type Reference struct {
OverloadId []string `protobuf:"bytes,3,rep,name=overload_id,json=overloadId,proto3" json:"overload_id,omitempty"`
// For references to constants, this may contain the value of the
// constant if known at compile time.
- Value *Constant `protobuf:"bytes,4,opt,name=value,proto3" json:"value,omitempty"`
+ Value *Constant `protobuf:"bytes,4,opt,name=value,proto3" json:"value,omitempty"`
+ unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *Reference) Reset() {
*x = Reference{}
- if protoimpl.UnsafeEnabled {
- mi := &file_google_api_expr_v1alpha1_checked_proto_msgTypes[3]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_google_api_expr_v1alpha1_checked_proto_msgTypes[3]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Reference) String() string {
@@ -696,7 +715,7 @@ func (*Reference) ProtoMessage() {}
func (x *Reference) ProtoReflect() protoreflect.Message {
mi := &file_google_api_expr_v1alpha1_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)
@@ -734,21 +753,18 @@ func (x *Reference) GetValue() *Constant {
// List type with typed elements, e.g. `list`.
type Type_ListType struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
+ state protoimpl.MessageState `protogen:"open.v1"`
// The element type.
- ElemType *Type `protobuf:"bytes,1,opt,name=elem_type,json=elemType,proto3" json:"elem_type,omitempty"`
+ ElemType *Type `protobuf:"bytes,1,opt,name=elem_type,json=elemType,proto3" json:"elem_type,omitempty"`
+ unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *Type_ListType) Reset() {
*x = Type_ListType{}
- if protoimpl.UnsafeEnabled {
- mi := &file_google_api_expr_v1alpha1_checked_proto_msgTypes[6]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_google_api_expr_v1alpha1_checked_proto_msgTypes[6]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Type_ListType) String() string {
@@ -759,7 +775,7 @@ func (*Type_ListType) ProtoMessage() {}
func (x *Type_ListType) ProtoReflect() protoreflect.Message {
mi := &file_google_api_expr_v1alpha1_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)
@@ -783,23 +799,20 @@ func (x *Type_ListType) GetElemType() *Type {
// Map type with parameterized key and value types, e.g. `map`.
type Type_MapType struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
+ state protoimpl.MessageState `protogen:"open.v1"`
// The type of the key.
KeyType *Type `protobuf:"bytes,1,opt,name=key_type,json=keyType,proto3" json:"key_type,omitempty"`
// The type of the value.
- ValueType *Type `protobuf:"bytes,2,opt,name=value_type,json=valueType,proto3" json:"value_type,omitempty"`
+ ValueType *Type `protobuf:"bytes,2,opt,name=value_type,json=valueType,proto3" json:"value_type,omitempty"`
+ unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *Type_MapType) Reset() {
*x = Type_MapType{}
- if protoimpl.UnsafeEnabled {
- mi := &file_google_api_expr_v1alpha1_checked_proto_msgTypes[7]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_google_api_expr_v1alpha1_checked_proto_msgTypes[7]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Type_MapType) String() string {
@@ -810,7 +823,7 @@ func (*Type_MapType) ProtoMessage() {}
func (x *Type_MapType) ProtoReflect() protoreflect.Message {
mi := &file_google_api_expr_v1alpha1_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)
@@ -841,23 +854,20 @@ func (x *Type_MapType) GetValueType() *Type {
// Function type with result and arg types.
type Type_FunctionType struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
+ state protoimpl.MessageState `protogen:"open.v1"`
// Result type of the function.
ResultType *Type `protobuf:"bytes,1,opt,name=result_type,json=resultType,proto3" json:"result_type,omitempty"`
// Argument types of the function.
- ArgTypes []*Type `protobuf:"bytes,2,rep,name=arg_types,json=argTypes,proto3" json:"arg_types,omitempty"`
+ ArgTypes []*Type `protobuf:"bytes,2,rep,name=arg_types,json=argTypes,proto3" json:"arg_types,omitempty"`
+ unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *Type_FunctionType) Reset() {
*x = Type_FunctionType{}
- if protoimpl.UnsafeEnabled {
- mi := &file_google_api_expr_v1alpha1_checked_proto_msgTypes[8]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_google_api_expr_v1alpha1_checked_proto_msgTypes[8]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Type_FunctionType) String() string {
@@ -868,7 +878,7 @@ func (*Type_FunctionType) ProtoMessage() {}
func (x *Type_FunctionType) ProtoReflect() protoreflect.Message {
mi := &file_google_api_expr_v1alpha1_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)
@@ -899,23 +909,20 @@ func (x *Type_FunctionType) GetArgTypes() []*Type {
// Application defined abstract type.
type Type_AbstractType struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
+ state protoimpl.MessageState `protogen:"open.v1"`
// The fully qualified name of this abstract type.
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
// Parameter types for this abstract type.
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_google_api_expr_v1alpha1_checked_proto_msgTypes[9]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_google_api_expr_v1alpha1_checked_proto_msgTypes[9]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Type_AbstractType) String() string {
@@ -926,7 +933,7 @@ func (*Type_AbstractType) ProtoMessage() {}
func (x *Type_AbstractType) ProtoReflect() protoreflect.Message {
mi := &file_google_api_expr_v1alpha1_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)
@@ -962,26 +969,23 @@ func (x *Type_AbstractType) GetParameterTypes() []*Type {
// but may be used in conjunction with other identifiers bound at evaluation
// time.
type Decl_IdentDecl struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
+ state protoimpl.MessageState `protogen:"open.v1"`
// Required. The type of the identifier.
Type *Type `protobuf:"bytes,1,opt,name=type,proto3" json:"type,omitempty"`
// The constant value of the identifier. If not specified, the identifier
// must be supplied at evaluation time.
Value *Constant `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
// Documentation string for the identifier.
- Doc string `protobuf:"bytes,3,opt,name=doc,proto3" json:"doc,omitempty"`
+ Doc string `protobuf:"bytes,3,opt,name=doc,proto3" json:"doc,omitempty"`
+ unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *Decl_IdentDecl) Reset() {
*x = Decl_IdentDecl{}
- if protoimpl.UnsafeEnabled {
- mi := &file_google_api_expr_v1alpha1_checked_proto_msgTypes[10]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_google_api_expr_v1alpha1_checked_proto_msgTypes[10]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Decl_IdentDecl) String() string {
@@ -992,7 +996,7 @@ func (*Decl_IdentDecl) ProtoMessage() {}
func (x *Decl_IdentDecl) ProtoReflect() protoreflect.Message {
mi := &file_google_api_expr_v1alpha1_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)
@@ -1034,21 +1038,30 @@ func (x *Decl_IdentDecl) GetDoc() string {
// Functions have no observable side-effects (there may be side-effects like
// logging which are not observable from CEL).
type Decl_FunctionDecl struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
+ state protoimpl.MessageState `protogen:"open.v1"`
// Required. List of function overloads, must contain at least one overload.
Overloads []*Decl_FunctionDecl_Overload `protobuf:"bytes,1,rep,name=overloads,proto3" json:"overloads,omitempty"`
+ // Documentation string for the function that indicates the general purpose
+ // of the function and its behavior.
+ //
+ // Documentation strings for the function should be general purpose with
+ // specific examples provided in the overload doc string.
+ //
+ // Examples:
+ //
+ // The 'in' operator tests whether an item exists in a collection.
+ //
+ // The 'substring' function returns a substring of a target string.
+ Doc string `protobuf:"bytes,2,opt,name=doc,proto3" json:"doc,omitempty"`
+ unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *Decl_FunctionDecl) Reset() {
*x = Decl_FunctionDecl{}
- if protoimpl.UnsafeEnabled {
- mi := &file_google_api_expr_v1alpha1_checked_proto_msgTypes[11]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_google_api_expr_v1alpha1_checked_proto_msgTypes[11]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Decl_FunctionDecl) String() string {
@@ -1059,7 +1072,7 @@ func (*Decl_FunctionDecl) ProtoMessage() {}
func (x *Decl_FunctionDecl) ProtoReflect() protoreflect.Message {
mi := &file_google_api_expr_v1alpha1_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)
@@ -1081,6 +1094,13 @@ func (x *Decl_FunctionDecl) GetOverloads() []*Decl_FunctionDecl_Overload {
return nil
}
+func (x *Decl_FunctionDecl) GetDoc() string {
+ if x != nil {
+ return x.Doc
+ }
+ return ""
+}
+
// An overload indicates a function's parameter types and return type, and
// may optionally include a function body described in terms of
// [Expr][google.api.expr.v1alpha1.Expr] values.
@@ -1092,10 +1112,7 @@ func (x *Decl_FunctionDecl) GetOverloads() []*Decl_FunctionDecl_Overload {
// Overloads must have non-overlapping argument types after erasure of all
// parameterized type variables (similar as type erasure in Java).
type Decl_FunctionDecl_Overload struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
+ state protoimpl.MessageState `protogen:"open.v1"`
// Required. Globally unique overload name of the function which reflects
// the function name and argument types.
//
@@ -1129,17 +1146,33 @@ type Decl_FunctionDecl_Overload struct {
// For methods, the first parameter declaration, `params[0]` is the
// expected type of the target receiver.
IsInstanceFunction bool `protobuf:"varint,5,opt,name=is_instance_function,json=isInstanceFunction,proto3" json:"is_instance_function,omitempty"`
- // Documentation string for the overload.
- Doc string `protobuf:"bytes,6,opt,name=doc,proto3" json:"doc,omitempty"`
+ // Examples for the overload and its expected return value, separated by
+ // newlines.
+ //
+ // Prefer using CEL literals in examples as they are easily consumed by
+ // humans and simple to validate with machines. The example should contain
+ // an expression with a literal return value in comments inline. If the
+ // expression example is too complex or would need an example for a
+ // variable that cannot be expressed in CEL, document the input and return
+ // in a comment preceding the example.
+ //
+ // Examples:
+ //
+ // 1 in [1, 2, 3] // true
+ // 'key' in {'key1: 1, 'key2': 2} // false
+ // // Test whether one or more keys exist within a map.
+ // // returns true if list_of_keys contains 'key2' or 'key3'
+ // list_of_keys.exists(key, key in {'key3': 1, 'key2': 2})
+ 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_google_api_expr_v1alpha1_checked_proto_msgTypes[12]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_google_api_expr_v1alpha1_checked_proto_msgTypes[12]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Decl_FunctionDecl_Overload) String() string {
@@ -1150,7 +1183,7 @@ func (*Decl_FunctionDecl_Overload) ProtoMessage() {}
func (x *Decl_FunctionDecl_Overload) ProtoReflect() protoreflect.Message {
mi := &file_google_api_expr_v1alpha1_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)
@@ -1209,220 +1242,113 @@ func (x *Decl_FunctionDecl_Overload) GetDoc() string {
var File_google_api_expr_v1alpha1_checked_proto protoreflect.FileDescriptor
-var file_google_api_expr_v1alpha1_checked_proto_rawDesc = []byte{
- 0x0a, 0x26, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x65, 0x78, 0x70,
- 0x72, 0x2f, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2f, 0x63, 0x68, 0x65, 0x63, 0x6b,
- 0x65, 0x64, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x18, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65,
- 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68,
- 0x61, 0x31, 0x1a, 0x25, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x65,
- 0x78, 0x70, 0x72, 0x2f, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 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, 0x9a, 0x04, 0x0a, 0x0b, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x65, 0x64,
- 0x45, 0x78, 0x70, 0x72, 0x12, 0x5c, 0x0a, 0x0d, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63,
- 0x65, 0x5f, 0x6d, 0x61, 0x70, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x37, 0x2e, 0x67, 0x6f,
- 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31,
- 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 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, 0x4d, 0x0a, 0x08, 0x74, 0x79, 0x70, 0x65, 0x5f, 0x6d, 0x61, 0x70, 0x18, 0x03,
- 0x20, 0x03, 0x28, 0x0b, 0x32, 0x32, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70,
- 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 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, 0x45, 0x0a, 0x0b, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x5f, 0x69, 0x6e, 0x66, 0x6f,
- 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e,
- 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61,
- 0x31, 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, 0x32, 0x0a, 0x04, 0x65,
- 0x78, 0x70, 0x72, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x67, 0x6f, 0x6f, 0x67,
- 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c,
- 0x70, 0x68, 0x61, 0x31, 0x2e, 0x45, 0x78, 0x70, 0x72, 0x52, 0x04, 0x65, 0x78, 0x70, 0x72, 0x1a,
- 0x64, 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, 0x39, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18,
- 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x23, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61,
- 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31,
- 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75,
- 0x65, 0x3a, 0x02, 0x38, 0x01, 0x1a, 0x5a, 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, 0x34, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65,
- 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e,
- 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61,
- 0x31, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38,
- 0x01, 0x22, 0xc8, 0x0b, 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, 0x4c, 0x0a, 0x09, 0x70, 0x72, 0x69, 0x6d,
- 0x69, 0x74, 0x69, 0x76, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x2c, 0x2e, 0x67, 0x6f,
- 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31,
- 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 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, 0x48, 0x0a, 0x07, 0x77, 0x72, 0x61, 0x70, 0x70, 0x65,
- 0x72, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x2c, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65,
- 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68,
- 0x61, 0x31, 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, 0x4d, 0x0a, 0x0a, 0x77, 0x65, 0x6c, 0x6c, 0x5f, 0x6b, 0x6e, 0x6f, 0x77, 0x6e, 0x18, 0x05,
- 0x20, 0x01, 0x28, 0x0e, 0x32, 0x2c, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70,
- 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 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,
- 0x46, 0x0a, 0x09, 0x6c, 0x69, 0x73, 0x74, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x06, 0x20, 0x01,
- 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e,
- 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 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, 0x43, 0x0a, 0x08, 0x6d, 0x61, 0x70, 0x5f, 0x74,
- 0x79, 0x70, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x67, 0x6f, 0x6f, 0x67,
- 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c,
- 0x70, 0x68, 0x61, 0x31, 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, 0x49, 0x0a, 0x08,
- 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2b,
- 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72,
- 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 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, 0x34, 0x0a,
- 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x67, 0x6f,
- 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31,
- 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 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, 0x52, 0x0a, 0x0d, 0x61, 0x62, 0x73, 0x74, 0x72, 0x61, 0x63, 0x74, 0x5f,
- 0x74, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2b, 0x2e, 0x67, 0x6f, 0x6f,
- 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61,
- 0x6c, 0x70, 0x68, 0x61, 0x31, 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, 0x47, 0x0a, 0x08, 0x4c, 0x69, 0x73, 0x74, 0x54,
- 0x79, 0x70, 0x65, 0x12, 0x3b, 0x0a, 0x09, 0x65, 0x6c, 0x65, 0x6d, 0x5f, 0x74, 0x79, 0x70, 0x65,
- 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e,
- 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61,
- 0x31, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x52, 0x08, 0x65, 0x6c, 0x65, 0x6d, 0x54, 0x79, 0x70, 0x65,
- 0x1a, 0x83, 0x01, 0x0a, 0x07, 0x4d, 0x61, 0x70, 0x54, 0x79, 0x70, 0x65, 0x12, 0x39, 0x0a, 0x08,
- 0x6b, 0x65, 0x79, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e,
- 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72,
- 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x52, 0x07,
- 0x6b, 0x65, 0x79, 0x54, 0x79, 0x70, 0x65, 0x12, 0x3d, 0x0a, 0x0a, 0x76, 0x61, 0x6c, 0x75, 0x65,
- 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x67, 0x6f,
- 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31,
- 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x52, 0x09, 0x76, 0x61, 0x6c,
- 0x75, 0x65, 0x54, 0x79, 0x70, 0x65, 0x1a, 0x8c, 0x01, 0x0a, 0x0c, 0x46, 0x75, 0x6e, 0x63, 0x74,
- 0x69, 0x6f, 0x6e, 0x54, 0x79, 0x70, 0x65, 0x12, 0x3f, 0x0a, 0x0b, 0x72, 0x65, 0x73, 0x75, 0x6c,
- 0x74, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x67,
- 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76,
- 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x52, 0x0a, 0x72, 0x65,
- 0x73, 0x75, 0x6c, 0x74, 0x54, 0x79, 0x70, 0x65, 0x12, 0x3b, 0x0a, 0x09, 0x61, 0x72, 0x67, 0x5f,
- 0x74, 0x79, 0x70, 0x65, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x67, 0x6f,
- 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31,
- 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x52, 0x08, 0x61, 0x72, 0x67,
- 0x54, 0x79, 0x70, 0x65, 0x73, 0x1a, 0x6b, 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, 0x47, 0x0a, 0x0f, 0x70, 0x61, 0x72,
- 0x61, 0x6d, 0x65, 0x74, 0x65, 0x72, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x18, 0x02, 0x20, 0x03,
- 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e,
- 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 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, 0xb3, 0x05, 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, 0x40, 0x0a, 0x05, 0x69, 0x64, 0x65,
- 0x6e, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x28, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c,
- 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70,
- 0x68, 0x61, 0x31, 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, 0x49, 0x0a, 0x08, 0x66,
- 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2b, 0x2e,
- 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e,
- 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 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, 0x8b, 0x01, 0x0a, 0x09, 0x49, 0x64, 0x65, 0x6e, 0x74,
- 0x44, 0x65, 0x63, 0x6c, 0x12, 0x32, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01,
- 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e,
- 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x54, 0x79,
- 0x70, 0x65, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x12, 0x38, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75,
- 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65,
- 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68,
- 0x61, 0x31, 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, 0xee, 0x02, 0x0a, 0x0c, 0x46, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f,
- 0x6e, 0x44, 0x65, 0x63, 0x6c, 0x12, 0x52, 0x0a, 0x09, 0x6f, 0x76, 0x65, 0x72, 0x6c, 0x6f, 0x61,
- 0x64, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x34, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c,
- 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70,
- 0x68, 0x61, 0x31, 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, 0x89, 0x02, 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, 0x36, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d,
- 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65,
- 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68,
- 0x61, 0x31, 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, 0x3f, 0x0a, 0x0b, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18,
- 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61,
- 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31,
- 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, 0x7a, 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, 0x38, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x04, 0x20,
- 0x01, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69,
- 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x43,
- 0x6f, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x74, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x42, 0x6c,
- 0x0a, 0x1c, 0x63, 0x6f, 0x6d, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69,
- 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x42, 0x09,
- 0x44, 0x65, 0x63, 0x6c, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x3c, 0x67, 0x6f, 0x6f,
- 0x67, 0x6c, 0x65, 0x2e, 0x67, 0x6f, 0x6c, 0x61, 0x6e, 0x67, 0x2e, 0x6f, 0x72, 0x67, 0x2f, 0x67,
- 0x65, 0x6e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x61, 0x70,
- 0x69, 0x73, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x65, 0x78, 0x70, 0x72, 0x2f, 0x76, 0x31, 0x61, 0x6c,
- 0x70, 0x68, 0x61, 0x31, 0x3b, 0x65, 0x78, 0x70, 0x72, 0xf8, 0x01, 0x01, 0x62, 0x06, 0x70, 0x72,
- 0x6f, 0x74, 0x6f, 0x33,
-}
+const file_google_api_expr_v1alpha1_checked_proto_rawDesc = "" +
+ "\n" +
+ "&google/api/expr/v1alpha1/checked.proto\x12\x18google.api.expr.v1alpha1\x1a%google/api/expr/v1alpha1/syntax.proto\x1a\x1bgoogle/protobuf/empty.proto\x1a\x1cgoogle/protobuf/struct.proto\"\x9a\x04\n" +
+ "\vCheckedExpr\x12\\\n" +
+ "\rreference_map\x18\x02 \x03(\v27.google.api.expr.v1alpha1.CheckedExpr.ReferenceMapEntryR\freferenceMap\x12M\n" +
+ "\btype_map\x18\x03 \x03(\v22.google.api.expr.v1alpha1.CheckedExpr.TypeMapEntryR\atypeMap\x12E\n" +
+ "\vsource_info\x18\x05 \x01(\v2$.google.api.expr.v1alpha1.SourceInfoR\n" +
+ "sourceInfo\x12!\n" +
+ "\fexpr_version\x18\x06 \x01(\tR\vexprVersion\x122\n" +
+ "\x04expr\x18\x04 \x01(\v2\x1e.google.api.expr.v1alpha1.ExprR\x04expr\x1ad\n" +
+ "\x11ReferenceMapEntry\x12\x10\n" +
+ "\x03key\x18\x01 \x01(\x03R\x03key\x129\n" +
+ "\x05value\x18\x02 \x01(\v2#.google.api.expr.v1alpha1.ReferenceR\x05value:\x028\x01\x1aZ\n" +
+ "\fTypeMapEntry\x12\x10\n" +
+ "\x03key\x18\x01 \x01(\x03R\x03key\x124\n" +
+ "\x05value\x18\x02 \x01(\v2\x1e.google.api.expr.v1alpha1.TypeR\x05value:\x028\x01\"\xc8\v\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\x12L\n" +
+ "\tprimitive\x18\x03 \x01(\x0e2,.google.api.expr.v1alpha1.Type.PrimitiveTypeH\x00R\tprimitive\x12H\n" +
+ "\awrapper\x18\x04 \x01(\x0e2,.google.api.expr.v1alpha1.Type.PrimitiveTypeH\x00R\awrapper\x12M\n" +
+ "\n" +
+ "well_known\x18\x05 \x01(\x0e2,.google.api.expr.v1alpha1.Type.WellKnownTypeH\x00R\twellKnown\x12F\n" +
+ "\tlist_type\x18\x06 \x01(\v2'.google.api.expr.v1alpha1.Type.ListTypeH\x00R\blistType\x12C\n" +
+ "\bmap_type\x18\a \x01(\v2&.google.api.expr.v1alpha1.Type.MapTypeH\x00R\amapType\x12I\n" +
+ "\bfunction\x18\b \x01(\v2+.google.api.expr.v1alpha1.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\x124\n" +
+ "\x04type\x18\v \x01(\v2\x1e.google.api.expr.v1alpha1.TypeH\x00R\x04type\x12.\n" +
+ "\x05error\x18\f \x01(\v2\x16.google.protobuf.EmptyH\x00R\x05error\x12R\n" +
+ "\rabstract_type\x18\x0e \x01(\v2+.google.api.expr.v1alpha1.Type.AbstractTypeH\x00R\fabstractType\x1aG\n" +
+ "\bListType\x12;\n" +
+ "\telem_type\x18\x01 \x01(\v2\x1e.google.api.expr.v1alpha1.TypeR\belemType\x1a\x83\x01\n" +
+ "\aMapType\x129\n" +
+ "\bkey_type\x18\x01 \x01(\v2\x1e.google.api.expr.v1alpha1.TypeR\akeyType\x12=\n" +
+ "\n" +
+ "value_type\x18\x02 \x01(\v2\x1e.google.api.expr.v1alpha1.TypeR\tvalueType\x1a\x8c\x01\n" +
+ "\fFunctionType\x12?\n" +
+ "\vresult_type\x18\x01 \x01(\v2\x1e.google.api.expr.v1alpha1.TypeR\n" +
+ "resultType\x12;\n" +
+ "\targ_types\x18\x02 \x03(\v2\x1e.google.api.expr.v1alpha1.TypeR\bargTypes\x1ak\n" +
+ "\fAbstractType\x12\x12\n" +
+ "\x04name\x18\x01 \x01(\tR\x04name\x12G\n" +
+ "\x0fparameter_types\x18\x02 \x03(\v2\x1e.google.api.expr.v1alpha1.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\"\xc5\x05\n" +
+ "\x04Decl\x12\x12\n" +
+ "\x04name\x18\x01 \x01(\tR\x04name\x12@\n" +
+ "\x05ident\x18\x02 \x01(\v2(.google.api.expr.v1alpha1.Decl.IdentDeclH\x00R\x05ident\x12I\n" +
+ "\bfunction\x18\x03 \x01(\v2+.google.api.expr.v1alpha1.Decl.FunctionDeclH\x00R\bfunction\x1a\x8b\x01\n" +
+ "\tIdentDecl\x122\n" +
+ "\x04type\x18\x01 \x01(\v2\x1e.google.api.expr.v1alpha1.TypeR\x04type\x128\n" +
+ "\x05value\x18\x02 \x01(\v2\".google.api.expr.v1alpha1.ConstantR\x05value\x12\x10\n" +
+ "\x03doc\x18\x03 \x01(\tR\x03doc\x1a\x80\x03\n" +
+ "\fFunctionDecl\x12R\n" +
+ "\toverloads\x18\x01 \x03(\v24.google.api.expr.v1alpha1.Decl.FunctionDecl.OverloadR\toverloads\x12\x10\n" +
+ "\x03doc\x18\x02 \x01(\tR\x03doc\x1a\x89\x02\n" +
+ "\bOverload\x12\x1f\n" +
+ "\voverload_id\x18\x01 \x01(\tR\n" +
+ "overloadId\x126\n" +
+ "\x06params\x18\x02 \x03(\v2\x1e.google.api.expr.v1alpha1.TypeR\x06params\x12\x1f\n" +
+ "\vtype_params\x18\x03 \x03(\tR\n" +
+ "typeParams\x12?\n" +
+ "\vresult_type\x18\x04 \x01(\v2\x1e.google.api.expr.v1alpha1.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\"z\n" +
+ "\tReference\x12\x12\n" +
+ "\x04name\x18\x01 \x01(\tR\x04name\x12\x1f\n" +
+ "\voverload_id\x18\x03 \x03(\tR\n" +
+ "overloadId\x128\n" +
+ "\x05value\x18\x04 \x01(\v2\".google.api.expr.v1alpha1.ConstantR\x05valueBi\n" +
+ "\x1ccom.google.api.expr.v1alpha1B\tDeclProtoP\x01Z || true) && ` will only result in ``,
// while ` || ` will result in both `` and
// ``.
//
- // Errors cause by the presence of other errors are not included in the
+ // Errors caused by the presence of other errors are not included in the
// set. For example `.foo`, `foo()`, and ` + 1` will
// only result in ``.
//
@@ -219,13 +220,13 @@ type ExprValue_Unknown struct {
// foo() ->
// + -> or
//
- // Unknown takes precidence over Error in cases where a `Value` can short
+ // Unknown takes precedence over Error in cases where a `Value` can short
// circuit the result:
//
// || ->
// && ->
//
- // Errors take precidence in all other cases:
+ // Errors take precedence in all other cases:
//
// + ->
// foo(, ) ->
@@ -242,21 +243,18 @@ func (*ExprValue_Unknown) isExprValue_Kind() {}
//
// The errors included depend on the context. See `ExprValue.error`.
type ErrorSet struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
+ state protoimpl.MessageState `protogen:"open.v1"`
// The errors in the set.
- Errors []*status.Status `protobuf:"bytes,1,rep,name=errors,proto3" json:"errors,omitempty"`
+ Errors []*status.Status `protobuf:"bytes,1,rep,name=errors,proto3" json:"errors,omitempty"`
+ unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *ErrorSet) Reset() {
*x = ErrorSet{}
- if protoimpl.UnsafeEnabled {
- mi := &file_google_api_expr_v1alpha1_eval_proto_msgTypes[2]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_google_api_expr_v1alpha1_eval_proto_msgTypes[2]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *ErrorSet) String() string {
@@ -267,7 +265,7 @@ func (*ErrorSet) ProtoMessage() {}
func (x *ErrorSet) ProtoReflect() protoreflect.Message {
mi := &file_google_api_expr_v1alpha1_eval_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)
@@ -293,21 +291,18 @@ func (x *ErrorSet) GetErrors() []*status.Status {
//
// The unknowns included depend on the context. See `ExprValue.unknown`.
type UnknownSet struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
+ state protoimpl.MessageState `protogen:"open.v1"`
// The ids of the expressions with unknown values.
- Exprs []int64 `protobuf:"varint,1,rep,packed,name=exprs,proto3" json:"exprs,omitempty"`
+ Exprs []int64 `protobuf:"varint,1,rep,packed,name=exprs,proto3" json:"exprs,omitempty"`
+ unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *UnknownSet) Reset() {
*x = UnknownSet{}
- if protoimpl.UnsafeEnabled {
- mi := &file_google_api_expr_v1alpha1_eval_proto_msgTypes[3]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_google_api_expr_v1alpha1_eval_proto_msgTypes[3]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *UnknownSet) String() string {
@@ -318,7 +313,7 @@ func (*UnknownSet) ProtoMessage() {}
func (x *UnknownSet) ProtoReflect() protoreflect.Message {
mi := &file_google_api_expr_v1alpha1_eval_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)
@@ -340,25 +335,22 @@ func (x *UnknownSet) GetExprs() []int64 {
return nil
}
-// A single evalution result.
+// A single evaluation result.
type EvalState_Result struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
- // The id of the expression this result if for.
+ state protoimpl.MessageState `protogen:"open.v1"`
+ // The id of the expression this result is for.
Expr int64 `protobuf:"varint,1,opt,name=expr,proto3" json:"expr,omitempty"`
// The index in `values` of the resulting value.
- Value int64 `protobuf:"varint,2,opt,name=value,proto3" json:"value,omitempty"`
+ Value int64 `protobuf:"varint,2,opt,name=value,proto3" json:"value,omitempty"`
+ unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *EvalState_Result) Reset() {
*x = EvalState_Result{}
- if protoimpl.UnsafeEnabled {
- mi := &file_google_api_expr_v1alpha1_eval_proto_msgTypes[4]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_google_api_expr_v1alpha1_eval_proto_msgTypes[4]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *EvalState_Result) String() string {
@@ -369,7 +361,7 @@ func (*EvalState_Result) ProtoMessage() {}
func (x *EvalState_Result) ProtoReflect() protoreflect.Message {
mi := &file_google_api_expr_v1alpha1_eval_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)
@@ -400,70 +392,41 @@ func (x *EvalState_Result) GetValue() int64 {
var File_google_api_expr_v1alpha1_eval_proto protoreflect.FileDescriptor
-var file_google_api_expr_v1alpha1_eval_proto_rawDesc = []byte{
- 0x0a, 0x23, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x65, 0x78, 0x70,
- 0x72, 0x2f, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2f, 0x65, 0x76, 0x61, 0x6c, 0x2e,
- 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x18, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70,
- 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x1a,
- 0x24, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x65, 0x78, 0x70, 0x72,
- 0x2f, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2f, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x2e,
- 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x17, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x72, 0x70,
- 0x63, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xc2,
- 0x01, 0x0a, 0x09, 0x45, 0x76, 0x61, 0x6c, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x3b, 0x0a, 0x06,
- 0x76, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x23, 0x2e, 0x67,
- 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76,
- 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x45, 0x78, 0x70, 0x72, 0x56, 0x61, 0x6c, 0x75,
- 0x65, 0x52, 0x06, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x12, 0x44, 0x0a, 0x07, 0x72, 0x65, 0x73,
- 0x75, 0x6c, 0x74, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2a, 0x2e, 0x67, 0x6f, 0x6f,
- 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61,
- 0x6c, 0x70, 0x68, 0x61, 0x31, 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, 0xca, 0x01, 0x0a, 0x09, 0x45, 0x78, 0x70, 0x72, 0x56, 0x61, 0x6c, 0x75,
- 0x65, 0x12, 0x37, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b,
- 0x32, 0x1f, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78,
- 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x56, 0x61, 0x6c, 0x75,
- 0x65, 0x48, 0x00, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x3a, 0x0a, 0x05, 0x65, 0x72,
- 0x72, 0x6f, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x67, 0x6f, 0x6f, 0x67,
- 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c,
- 0x70, 0x68, 0x61, 0x31, 0x2e, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x53, 0x65, 0x74, 0x48, 0x00, 0x52,
- 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x12, 0x40, 0x0a, 0x07, 0x75, 0x6e, 0x6b, 0x6e, 0x6f, 0x77,
- 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65,
- 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68,
- 0x61, 0x31, 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, 0x36, 0x0a, 0x08, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x53, 0x65, 0x74, 0x12, 0x2a, 0x0a, 0x06,
- 0x65, 0x72, 0x72, 0x6f, 0x72, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x67,
- 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73,
- 0x52, 0x06, 0x65, 0x72, 0x72, 0x6f, 0x72, 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, 0x6c, 0x0a, 0x1c,
- 0x63, 0x6f, 0x6d, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65,
- 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x42, 0x09, 0x45, 0x76,
- 0x61, 0x6c, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x3c, 0x67, 0x6f, 0x6f, 0x67, 0x6c,
- 0x65, 0x2e, 0x67, 0x6f, 0x6c, 0x61, 0x6e, 0x67, 0x2e, 0x6f, 0x72, 0x67, 0x2f, 0x67, 0x65, 0x6e,
- 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x61, 0x70, 0x69, 0x73,
- 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x65, 0x78, 0x70, 0x72, 0x2f, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68,
- 0x61, 0x31, 0x3b, 0x65, 0x78, 0x70, 0x72, 0xf8, 0x01, 0x01, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74,
- 0x6f, 0x33,
-}
+const file_google_api_expr_v1alpha1_eval_proto_rawDesc = "" +
+ "\n" +
+ "#google/api/expr/v1alpha1/eval.proto\x12\x18google.api.expr.v1alpha1\x1a$google/api/expr/v1alpha1/value.proto\x1a\x17google/rpc/status.proto\"\xc2\x01\n" +
+ "\tEvalState\x12;\n" +
+ "\x06values\x18\x01 \x03(\v2#.google.api.expr.v1alpha1.ExprValueR\x06values\x12D\n" +
+ "\aresults\x18\x03 \x03(\v2*.google.api.expr.v1alpha1.EvalState.ResultR\aresults\x1a2\n" +
+ "\x06Result\x12\x12\n" +
+ "\x04expr\x18\x01 \x01(\x03R\x04expr\x12\x14\n" +
+ "\x05value\x18\x02 \x01(\x03R\x05value\"\xca\x01\n" +
+ "\tExprValue\x127\n" +
+ "\x05value\x18\x01 \x01(\v2\x1f.google.api.expr.v1alpha1.ValueH\x00R\x05value\x12:\n" +
+ "\x05error\x18\x02 \x01(\v2\".google.api.expr.v1alpha1.ErrorSetH\x00R\x05error\x12@\n" +
+ "\aunknown\x18\x03 \x01(\v2$.google.api.expr.v1alpha1.UnknownSetH\x00R\aunknownB\x06\n" +
+ "\x04kind\"6\n" +
+ "\bErrorSet\x12*\n" +
+ "\x06errors\x18\x01 \x03(\v2\x12.google.rpc.StatusR\x06errors\"\"\n" +
+ "\n" +
+ "UnknownSet\x12\x14\n" +
+ "\x05exprs\x18\x01 \x03(\x03R\x05exprsBi\n" +
+ "\x1ccom.google.api.expr.v1alpha1B\tEvalProtoP\x01Z 10)` translates to a comprehension expression. The key
// in the map corresponds to the expression id of the expanded macro, and the
// value is the call `Expr` that was replaced.
- 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"`
+ 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"`
// A list of tags for extensions that were used while parsing or type checking
// the source expression. For example, optimizations that require special
// runtime support may be specified.
@@ -597,16 +618,16 @@ type SourceInfo struct {
// These are used to check feature support between components in separate
// implementations. This can be used to either skip redundant work or
// report an error if the extension is unsupported.
- Extensions []*SourceInfo_Extension `protobuf:"bytes,6,rep,name=extensions,proto3" json:"extensions,omitempty"`
+ 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_google_api_expr_v1alpha1_syntax_proto_msgTypes[3]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_google_api_expr_v1alpha1_syntax_proto_msgTypes[3]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *SourceInfo) String() string {
@@ -617,7 +638,7 @@ func (*SourceInfo) ProtoMessage() {}
func (x *SourceInfo) ProtoReflect() protoreflect.Message {
mi := &file_google_api_expr_v1alpha1_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)
@@ -676,11 +697,8 @@ func (x *SourceInfo) GetExtensions() []*SourceInfo_Extension {
// A specific position in source.
type SourcePosition struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
- // The soucre location name (e.g. file name).
+ state protoimpl.MessageState `protogen:"open.v1"`
+ // The source location name (e.g. file name).
Location string `protobuf:"bytes,1,opt,name=location,proto3" json:"location,omitempty"`
// The UTF-8 code unit offset.
Offset int32 `protobuf:"varint,2,opt,name=offset,proto3" json:"offset,omitempty"`
@@ -689,16 +707,16 @@ type SourcePosition struct {
Line int32 `protobuf:"varint,3,opt,name=line,proto3" json:"line,omitempty"`
// The 0-based index of the starting position within the line of source text
// where the issue occurs. Only meaningful if line is nonzero.
- Column int32 `protobuf:"varint,4,opt,name=column,proto3" json:"column,omitempty"`
+ Column int32 `protobuf:"varint,4,opt,name=column,proto3" json:"column,omitempty"`
+ unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *SourcePosition) Reset() {
*x = SourcePosition{}
- if protoimpl.UnsafeEnabled {
- mi := &file_google_api_expr_v1alpha1_syntax_proto_msgTypes[4]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_google_api_expr_v1alpha1_syntax_proto_msgTypes[4]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *SourcePosition) String() string {
@@ -709,7 +727,7 @@ func (*SourcePosition) ProtoMessage() {}
func (x *SourcePosition) ProtoReflect() protoreflect.Message {
mi := &file_google_api_expr_v1alpha1_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)
@@ -754,25 +772,22 @@ func (x *SourcePosition) GetColumn() int32 {
// An identifier expression. e.g. `request`.
type Expr_Ident struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
+ state protoimpl.MessageState `protogen:"open.v1"`
// Required. Holds a single, unqualified identifier, possibly preceded by a
// '.'.
//
// Qualified names are represented by the
// [Expr.Select][google.api.expr.v1alpha1.Expr.Select] expression.
- Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
+ Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
+ unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *Expr_Ident) Reset() {
*x = Expr_Ident{}
- if protoimpl.UnsafeEnabled {
- mi := &file_google_api_expr_v1alpha1_syntax_proto_msgTypes[5]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_google_api_expr_v1alpha1_syntax_proto_msgTypes[5]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Expr_Ident) String() string {
@@ -783,7 +798,7 @@ func (*Expr_Ident) ProtoMessage() {}
func (x *Expr_Ident) ProtoReflect() protoreflect.Message {
mi := &file_google_api_expr_v1alpha1_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)
@@ -807,10 +822,7 @@ func (x *Expr_Ident) GetName() string {
// A field selection expression. e.g. `request.auth`.
type Expr_Select struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
+ state protoimpl.MessageState `protogen:"open.v1"`
// Required. The target of the selection expression.
//
// For example, in the select expression `request.auth`, the `request`
@@ -824,16 +836,16 @@ type Expr_Select struct {
// Whether the select is to be interpreted as a field presence test.
//
// This results from the macro `has(request.auth)`.
- TestOnly bool `protobuf:"varint,3,opt,name=test_only,json=testOnly,proto3" json:"test_only,omitempty"`
+ TestOnly bool `protobuf:"varint,3,opt,name=test_only,json=testOnly,proto3" json:"test_only,omitempty"`
+ unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *Expr_Select) Reset() {
*x = Expr_Select{}
- if protoimpl.UnsafeEnabled {
- mi := &file_google_api_expr_v1alpha1_syntax_proto_msgTypes[6]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_google_api_expr_v1alpha1_syntax_proto_msgTypes[6]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Expr_Select) String() string {
@@ -844,7 +856,7 @@ func (*Expr_Select) ProtoMessage() {}
func (x *Expr_Select) ProtoReflect() protoreflect.Message {
mi := &file_google_api_expr_v1alpha1_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)
@@ -884,26 +896,23 @@ func (x *Expr_Select) GetTestOnly() bool {
//
// For example, `value == 10`, `size(map_value)`.
type Expr_Call struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
- // The target of an method call-style expression. For example, `x` in
+ state protoimpl.MessageState `protogen:"open.v1"`
+ // The target of a method call-style expression. For example, `x` in
// `x.f()`.
Target *Expr `protobuf:"bytes,1,opt,name=target,proto3" json:"target,omitempty"`
// Required. The name of the function or method being called.
Function string `protobuf:"bytes,2,opt,name=function,proto3" json:"function,omitempty"`
// The arguments.
- Args []*Expr `protobuf:"bytes,3,rep,name=args,proto3" json:"args,omitempty"`
+ Args []*Expr `protobuf:"bytes,3,rep,name=args,proto3" json:"args,omitempty"`
+ unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *Expr_Call) Reset() {
*x = Expr_Call{}
- if protoimpl.UnsafeEnabled {
- mi := &file_google_api_expr_v1alpha1_syntax_proto_msgTypes[7]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_google_api_expr_v1alpha1_syntax_proto_msgTypes[7]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Expr_Call) String() string {
@@ -914,7 +923,7 @@ func (*Expr_Call) ProtoMessage() {}
func (x *Expr_Call) ProtoReflect() protoreflect.Message {
mi := &file_google_api_expr_v1alpha1_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)
@@ -952,13 +961,10 @@ func (x *Expr_Call) GetArgs() []*Expr {
// A list creation expression.
//
-// Lists may either be homogenous, e.g. `[1, 2, 3]`, or heterogeneous, e.g.
+// Lists may either be homogeneous, e.g. `[1, 2, 3]`, or heterogeneous, e.g.
// `dyn([1, 'hello', 2.0])`
type Expr_CreateList struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
+ state protoimpl.MessageState `protogen:"open.v1"`
// The elements part of the list.
Elements []*Expr `protobuf:"bytes,1,rep,name=elements,proto3" json:"elements,omitempty"`
// The indices within the elements list which are marked as optional
@@ -968,15 +974,15 @@ type Expr_CreateList struct {
// is included in the list. If the optional-typed value is absent, the list
// element is omitted from the CreateList result.
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_google_api_expr_v1alpha1_syntax_proto_msgTypes[8]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_google_api_expr_v1alpha1_syntax_proto_msgTypes[8]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Expr_CreateList) String() string {
@@ -987,7 +993,7 @@ func (*Expr_CreateList) ProtoMessage() {}
func (x *Expr_CreateList) ProtoReflect() protoreflect.Message {
mi := &file_google_api_expr_v1alpha1_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)
@@ -1022,24 +1028,21 @@ func (x *Expr_CreateList) GetOptionalIndices() []int32 {
// similar, but prefixed with a type name and composed of field ids:
// `types.MyType{field_id: 'value'}`.
type Expr_CreateStruct struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
- // The type name of the message to be created, empty when creating map
+ state protoimpl.MessageState `protogen:"open.v1"`
+ // The type name of the message to be created; empty when creating map
// literals.
MessageName string `protobuf:"bytes,1,opt,name=message_name,json=messageName,proto3" json:"message_name,omitempty"`
// The entries in the creation expression.
- Entries []*Expr_CreateStruct_Entry `protobuf:"bytes,2,rep,name=entries,proto3" json:"entries,omitempty"`
+ Entries []*Expr_CreateStruct_Entry `protobuf:"bytes,2,rep,name=entries,proto3" json:"entries,omitempty"`
+ unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *Expr_CreateStruct) Reset() {
*x = Expr_CreateStruct{}
- if protoimpl.UnsafeEnabled {
- mi := &file_google_api_expr_v1alpha1_syntax_proto_msgTypes[9]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_google_api_expr_v1alpha1_syntax_proto_msgTypes[9]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Expr_CreateStruct) String() string {
@@ -1050,7 +1053,7 @@ func (*Expr_CreateStruct) ProtoMessage() {}
func (x *Expr_CreateStruct) ProtoReflect() protoreflect.Message {
mi := &file_google_api_expr_v1alpha1_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)
@@ -1102,7 +1105,7 @@ func (x *Expr_CreateStruct) GetEntries() []*Expr_CreateStruct_Entry {
//
// The `has(m.x)` macro tests whether the property `x` is present in struct
// `m`. The semantics of this macro depend on the type of `m`. For proto2
-// messages `has(m.x)` is defined as 'defined, but not set`. For proto3, the
+// messages `has(m.x)` is defined as 'defined, but not set'. For proto3, the
// macro tests whether the property is set to its default. For map and struct
// types, the macro tests whether the property `x` is defined on `m`.
//
@@ -1124,7 +1127,7 @@ func (x *Expr_CreateStruct) GetEntries() []*Expr_CreateStruct_Entry {
//
// Comprehensions for the optional V2 macros which support map-to-map
// translation differ slightly from the standard environment macros in that
-// they expose both the key or index in addition to the value for each list
+// they expose the key or index in addition to the value for each list
// or map entry:
//
// ```
@@ -1140,17 +1143,13 @@ func (x *Expr_CreateStruct) GetEntries() []*Expr_CreateStruct_Entry {
// return `result`
// ```
type Expr_Comprehension struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
+ state protoimpl.MessageState `protogen:"open.v1"`
// The name of the first iteration variable.
- // When the iter_range is a list, this variable is the list element.
- // When the iter_range is a map, this variable is the map entry key.
+ // For the single iteration variable macros, when iter_range is a list, this
+ // variable is the list element and when the iter_range is a map, this
+ // variable is the map key.
IterVar string `protobuf:"bytes,1,opt,name=iter_var,json=iterVar,proto3" json:"iter_var,omitempty"`
- // The name of the second iteration variable, empty if not set.
- // When the iter_range is a list, this variable is the integer index.
- // When the iter_range is a map, this variable is the map entry value.
+ // The name of the second iteration variable; empty if not set.
// This field is only set for comprehension v2 macros.
IterVar2 string `protobuf:"bytes,8,opt,name=iter_var2,json=iterVar2,proto3" json:"iter_var2,omitempty"`
// The range over which the comprehension iterates.
@@ -1171,16 +1170,16 @@ type Expr_Comprehension struct {
// An expression which can contain accu_var.
//
// Computes the result.
- Result *Expr `protobuf:"bytes,7,opt,name=result,proto3" json:"result,omitempty"`
+ Result *Expr `protobuf:"bytes,7,opt,name=result,proto3" json:"result,omitempty"`
+ unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *Expr_Comprehension) Reset() {
*x = Expr_Comprehension{}
- if protoimpl.UnsafeEnabled {
- mi := &file_google_api_expr_v1alpha1_syntax_proto_msgTypes[10]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_google_api_expr_v1alpha1_syntax_proto_msgTypes[10]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Expr_Comprehension) String() string {
@@ -1191,7 +1190,7 @@ func (*Expr_Comprehension) ProtoMessage() {}
func (x *Expr_Comprehension) ProtoReflect() protoreflect.Message {
mi := &file_google_api_expr_v1alpha1_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)
@@ -1264,17 +1263,14 @@ func (x *Expr_Comprehension) GetResult() *Expr {
// Represents an entry.
type Expr_CreateStruct_Entry struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
+ state protoimpl.MessageState `protogen:"open.v1"`
// Required. An id assigned to this node by the parser which is unique
// in a given expression tree. This is used to associate type
- // information and other attributes to the node.
+ // information and other attributes with the node.
Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
// The `Entry` key kinds.
//
- // Types that are assignable to KeyKind:
+ // Types that are valid to be assigned to KeyKind:
//
// *Expr_CreateStruct_Entry_FieldKey
// *Expr_CreateStruct_Entry_MapKey
@@ -1287,15 +1283,15 @@ type Expr_CreateStruct_Entry struct {
Value *Expr `protobuf:"bytes,4,opt,name=value,proto3" json:"value,omitempty"`
// Whether the key-value pair is optional.
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_google_api_expr_v1alpha1_syntax_proto_msgTypes[11]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_google_api_expr_v1alpha1_syntax_proto_msgTypes[11]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *Expr_CreateStruct_Entry) String() string {
@@ -1306,7 +1302,7 @@ func (*Expr_CreateStruct_Entry) ProtoMessage() {}
func (x *Expr_CreateStruct_Entry) ProtoReflect() protoreflect.Message {
mi := &file_google_api_expr_v1alpha1_syntax_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)
@@ -1328,23 +1324,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
}
@@ -1383,29 +1383,26 @@ func (*Expr_CreateStruct_Entry_MapKey) isExpr_CreateStruct_Entry_KeyKind() {}
// An extension that was requested for the source expression.
type SourceInfo_Extension struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
+ state protoimpl.MessageState `protogen:"open.v1"`
// Identifier for the extension. Example: constant_folding
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
// If set, the listed components must understand the extension for the
// expression to evaluate correctly.
//
- // This field has set semantics, repeated values should be deduplicated.
+ // This field has set semantics; repeated values should be deduplicated.
AffectedComponents []SourceInfo_Extension_Component `protobuf:"varint,2,rep,packed,name=affected_components,json=affectedComponents,proto3,enum=google.api.expr.v1alpha1.SourceInfo_Extension_Component" json:"affected_components,omitempty"`
// Version info. May be skipped if it isn't meaningful for the extension.
// (for example constant_folding might always be v0.0).
- Version *SourceInfo_Extension_Version `protobuf:"bytes,3,opt,name=version,proto3" json:"version,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_google_api_expr_v1alpha1_syntax_proto_msgTypes[12]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_google_api_expr_v1alpha1_syntax_proto_msgTypes[12]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *SourceInfo_Extension) String() string {
@@ -1416,7 +1413,7 @@ func (*SourceInfo_Extension) ProtoMessage() {}
func (x *SourceInfo_Extension) ProtoReflect() protoreflect.Message {
mi := &file_google_api_expr_v1alpha1_syntax_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)
@@ -1454,25 +1451,22 @@ func (x *SourceInfo_Extension) GetVersion() *SourceInfo_Extension_Version {
// Version
type SourceInfo_Extension_Version struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
- unknownFields protoimpl.UnknownFields
-
+ state protoimpl.MessageState `protogen:"open.v1"`
// Major version changes indicate different required support level from
// the required components.
Major int64 `protobuf:"varint,1,opt,name=major,proto3" json:"major,omitempty"`
// Minor version changes must not change the observed behavior from
// existing implementations, but may be provided informationally.
- Minor int64 `protobuf:"varint,2,opt,name=minor,proto3" json:"minor,omitempty"`
+ Minor int64 `protobuf:"varint,2,opt,name=minor,proto3" json:"minor,omitempty"`
+ unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *SourceInfo_Extension_Version) Reset() {
*x = SourceInfo_Extension_Version{}
- if protoimpl.UnsafeEnabled {
- mi := &file_google_api_expr_v1alpha1_syntax_proto_msgTypes[15]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
+ mi := &file_google_api_expr_v1alpha1_syntax_proto_msgTypes[15]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
}
func (x *SourceInfo_Extension_Version) String() string {
@@ -1483,7 +1477,7 @@ func (*SourceInfo_Extension_Version) ProtoMessage() {}
func (x *SourceInfo_Extension_Version) ProtoReflect() protoreflect.Message {
mi := &file_google_api_expr_v1alpha1_syntax_proto_msgTypes[15]
- if protoimpl.UnsafeEnabled && x != nil {
+ if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
@@ -1514,252 +1508,129 @@ func (x *SourceInfo_Extension_Version) GetMinor() int64 {
var File_google_api_expr_v1alpha1_syntax_proto protoreflect.FileDescriptor
-var file_google_api_expr_v1alpha1_syntax_proto_rawDesc = []byte{
- 0x0a, 0x25, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x65, 0x78, 0x70,
- 0x72, 0x2f, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2f, 0x73, 0x79, 0x6e, 0x74, 0x61,
- 0x78, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x18, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e,
- 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61,
- 0x31, 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, 0x87, 0x01, 0x0a, 0x0a, 0x50, 0x61, 0x72, 0x73, 0x65, 0x64, 0x45, 0x78, 0x70, 0x72, 0x12,
- 0x32, 0x0a, 0x04, 0x65, 0x78, 0x70, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e,
- 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e,
- 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x45, 0x78, 0x70, 0x72, 0x52, 0x04, 0x65,
- 0x78, 0x70, 0x72, 0x12, 0x45, 0x0a, 0x0b, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x5f, 0x69, 0x6e,
- 0x66, 0x6f, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c,
- 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70,
- 0x68, 0x61, 0x31, 0x2e, 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x0a,
- 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x22, 0xcb, 0x0d, 0x0a, 0x04, 0x45,
- 0x78, 0x70, 0x72, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52,
- 0x02, 0x69, 0x64, 0x12, 0x43, 0x0a, 0x0a, 0x63, 0x6f, 0x6e, 0x73, 0x74, 0x5f, 0x65, 0x78, 0x70,
- 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65,
- 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68,
- 0x61, 0x31, 0x2e, 0x43, 0x6f, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x74, 0x48, 0x00, 0x52, 0x09, 0x63,
- 0x6f, 0x6e, 0x73, 0x74, 0x45, 0x78, 0x70, 0x72, 0x12, 0x45, 0x0a, 0x0a, 0x69, 0x64, 0x65, 0x6e,
- 0x74, 0x5f, 0x65, 0x78, 0x70, 0x72, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x67,
- 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76,
- 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 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,
- 0x48, 0x0a, 0x0b, 0x73, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x5f, 0x65, 0x78, 0x70, 0x72, 0x18, 0x05,
- 0x20, 0x01, 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70,
- 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 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, 0x42, 0x0a, 0x09, 0x63, 0x61, 0x6c,
- 0x6c, 0x5f, 0x65, 0x78, 0x70, 0x72, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x23, 0x2e, 0x67,
- 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76,
- 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x45, 0x78, 0x70, 0x72, 0x2e, 0x43, 0x61, 0x6c,
- 0x6c, 0x48, 0x00, 0x52, 0x08, 0x63, 0x61, 0x6c, 0x6c, 0x45, 0x78, 0x70, 0x72, 0x12, 0x48, 0x0a,
- 0x09, 0x6c, 0x69, 0x73, 0x74, 0x5f, 0x65, 0x78, 0x70, 0x72, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0b,
- 0x32, 0x29, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78,
- 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 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, 0x4e, 0x0a, 0x0b, 0x73, 0x74, 0x72, 0x75, 0x63,
- 0x74, 0x5f, 0x65, 0x78, 0x70, 0x72, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2b, 0x2e, 0x67,
- 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76,
- 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 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, 0x5d, 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, 0x2c, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69,
- 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 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, 0x75, 0x0a, 0x06, 0x53, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x12, 0x38, 0x0a,
- 0x07, 0x6f, 0x70, 0x65, 0x72, 0x61, 0x6e, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e,
- 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72,
- 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 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, 0x8e, 0x01, 0x0a, 0x04, 0x43,
- 0x61, 0x6c, 0x6c, 0x12, 0x36, 0x0a, 0x06, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x18, 0x01, 0x20,
- 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69,
- 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 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, 0x32, 0x0a, 0x04, 0x61, 0x72, 0x67, 0x73, 0x18,
- 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61,
- 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31,
- 0x2e, 0x45, 0x78, 0x70, 0x72, 0x52, 0x04, 0x61, 0x72, 0x67, 0x73, 0x1a, 0x73, 0x0a, 0x0a, 0x43,
- 0x72, 0x65, 0x61, 0x74, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x3a, 0x0a, 0x08, 0x65, 0x6c, 0x65,
- 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x67, 0x6f,
- 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31,
- 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 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, 0xdb, 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, 0x4b, 0x0a, 0x07, 0x65, 0x6e, 0x74, 0x72, 0x69, 0x65, 0x73, 0x18,
- 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x31, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61,
- 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31,
- 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, 0xda, 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, 0x39, 0x0a, 0x07, 0x6d, 0x61,
- 0x70, 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x67, 0x6f,
- 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31,
- 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x45, 0x78, 0x70, 0x72, 0x48, 0x00, 0x52, 0x06, 0x6d,
- 0x61, 0x70, 0x4b, 0x65, 0x79, 0x12, 0x34, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x04,
- 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70,
- 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 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, 0x9a,
- 0x03, 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, 0x1b, 0x0a, 0x09, 0x69,
- 0x74, 0x65, 0x72, 0x5f, 0x76, 0x61, 0x72, 0x32, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08,
- 0x69, 0x74, 0x65, 0x72, 0x56, 0x61, 0x72, 0x32, 0x12, 0x3d, 0x0a, 0x0a, 0x69, 0x74, 0x65, 0x72,
- 0x5f, 0x72, 0x61, 0x6e, 0x67, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x67,
- 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76,
- 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 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, 0x3b, 0x0a, 0x09, 0x61, 0x63, 0x63, 0x75, 0x5f, 0x69, 0x6e, 0x69, 0x74, 0x18,
- 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61,
- 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31,
- 0x2e, 0x45, 0x78, 0x70, 0x72, 0x52, 0x08, 0x61, 0x63, 0x63, 0x75, 0x49, 0x6e, 0x69, 0x74, 0x12,
- 0x45, 0x0a, 0x0e, 0x6c, 0x6f, 0x6f, 0x70, 0x5f, 0x63, 0x6f, 0x6e, 0x64, 0x69, 0x74, 0x69, 0x6f,
- 0x6e, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65,
- 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68,
- 0x61, 0x31, 0x2e, 0x45, 0x78, 0x70, 0x72, 0x52, 0x0d, 0x6c, 0x6f, 0x6f, 0x70, 0x43, 0x6f, 0x6e,
- 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x3b, 0x0a, 0x09, 0x6c, 0x6f, 0x6f, 0x70, 0x5f, 0x73,
- 0x74, 0x65, 0x70, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x67, 0x6f, 0x6f, 0x67,
- 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c,
- 0x70, 0x68, 0x61, 0x31, 0x2e, 0x45, 0x78, 0x70, 0x72, 0x52, 0x08, 0x6c, 0x6f, 0x6f, 0x70, 0x53,
- 0x74, 0x65, 0x70, 0x12, 0x36, 0x0a, 0x06, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x18, 0x07, 0x20,
- 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69,
- 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 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, 0x8c, 0x07, 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, 0x51, 0x0a, 0x09, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x04,
- 0x20, 0x03, 0x28, 0x0b, 0x32, 0x33, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70,
- 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 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, 0x55, 0x0a, 0x0b, 0x6d, 0x61, 0x63, 0x72, 0x6f, 0x5f, 0x63, 0x61,
- 0x6c, 0x6c, 0x73, 0x18, 0x05, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x34, 0x2e, 0x67, 0x6f, 0x6f, 0x67,
- 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c,
- 0x70, 0x68, 0x61, 0x31, 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, 0x4e, 0x0a, 0x0a, 0x65,
- 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x06, 0x20, 0x03, 0x28, 0x0b, 0x32,
- 0x2e, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70,
- 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 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, 0x80, 0x03, 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, 0x69, 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, 0x38, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e,
- 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61,
- 0x31, 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, 0x50, 0x0a, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18,
- 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x36, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61,
- 0x70, 0x69, 0x2e, 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31,
- 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, 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, 0x5d, 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, 0x34, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b,
- 0x32, 0x1e, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x65, 0x78,
- 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x45, 0x78, 0x70, 0x72,
- 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0x70, 0x0a, 0x0e, 0x53,
- 0x6f, 0x75, 0x72, 0x63, 0x65, 0x50, 0x6f, 0x73, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x1a, 0x0a,
- 0x08, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52,
- 0x08, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x16, 0x0a, 0x06, 0x6f, 0x66, 0x66,
- 0x73, 0x65, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x6f, 0x66, 0x66, 0x73, 0x65,
- 0x74, 0x12, 0x12, 0x0a, 0x04, 0x6c, 0x69, 0x6e, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52,
- 0x04, 0x6c, 0x69, 0x6e, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x63, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x18,
- 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x63, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x42, 0x6e, 0x0a,
- 0x1c, 0x63, 0x6f, 0x6d, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e,
- 0x65, 0x78, 0x70, 0x72, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x42, 0x0b, 0x53,
- 0x79, 0x6e, 0x74, 0x61, 0x78, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x3c, 0x67, 0x6f,
- 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x67, 0x6f, 0x6c, 0x61, 0x6e, 0x67, 0x2e, 0x6f, 0x72, 0x67, 0x2f,
- 0x67, 0x65, 0x6e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x61,
- 0x70, 0x69, 0x73, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x65, 0x78, 0x70, 0x72, 0x2f, 0x76, 0x31, 0x61,
- 0x6c, 0x70, 0x68, 0x61, 0x31, 0x3b, 0x65, 0x78, 0x70, 0x72, 0xf8, 0x01, 0x01, 0x62, 0x06, 0x70,
- 0x72, 0x6f, 0x74, 0x6f, 0x33,
-}
+const file_google_api_expr_v1alpha1_syntax_proto_rawDesc = "" +
+ "\n" +
+ "%google/api/expr/v1alpha1/syntax.proto\x12\x18google.api.expr.v1alpha1\x1a\x1egoogle/protobuf/duration.proto\x1a\x1cgoogle/protobuf/struct.proto\x1a\x1fgoogle/protobuf/timestamp.proto\"\x87\x01\n" +
+ "\n" +
+ "ParsedExpr\x122\n" +
+ "\x04expr\x18\x02 \x01(\v2\x1e.google.api.expr.v1alpha1.ExprR\x04expr\x12E\n" +
+ "\vsource_info\x18\x03 \x01(\v2$.google.api.expr.v1alpha1.SourceInfoR\n" +
+ "sourceInfo\"\xcb\r\n" +
+ "\x04Expr\x12\x0e\n" +
+ "\x02id\x18\x02 \x01(\x03R\x02id\x12C\n" +
+ "\n" +
+ "const_expr\x18\x03 \x01(\v2\".google.api.expr.v1alpha1.ConstantH\x00R\tconstExpr\x12E\n" +
+ "\n" +
+ "ident_expr\x18\x04 \x01(\v2$.google.api.expr.v1alpha1.Expr.IdentH\x00R\tidentExpr\x12H\n" +
+ "\vselect_expr\x18\x05 \x01(\v2%.google.api.expr.v1alpha1.Expr.SelectH\x00R\n" +
+ "selectExpr\x12B\n" +
+ "\tcall_expr\x18\x06 \x01(\v2#.google.api.expr.v1alpha1.Expr.CallH\x00R\bcallExpr\x12H\n" +
+ "\tlist_expr\x18\a \x01(\v2).google.api.expr.v1alpha1.Expr.CreateListH\x00R\blistExpr\x12N\n" +
+ "\vstruct_expr\x18\b \x01(\v2+.google.api.expr.v1alpha1.Expr.CreateStructH\x00R\n" +
+ "structExpr\x12]\n" +
+ "\x12comprehension_expr\x18\t \x01(\v2,.google.api.expr.v1alpha1.Expr.ComprehensionH\x00R\x11comprehensionExpr\x1a\x1b\n" +
+ "\x05Ident\x12\x12\n" +
+ "\x04name\x18\x01 \x01(\tR\x04name\x1au\n" +
+ "\x06Select\x128\n" +
+ "\aoperand\x18\x01 \x01(\v2\x1e.google.api.expr.v1alpha1.ExprR\aoperand\x12\x14\n" +
+ "\x05field\x18\x02 \x01(\tR\x05field\x12\x1b\n" +
+ "\ttest_only\x18\x03 \x01(\bR\btestOnly\x1a\x8e\x01\n" +
+ "\x04Call\x126\n" +
+ "\x06target\x18\x01 \x01(\v2\x1e.google.api.expr.v1alpha1.ExprR\x06target\x12\x1a\n" +
+ "\bfunction\x18\x02 \x01(\tR\bfunction\x122\n" +
+ "\x04args\x18\x03 \x03(\v2\x1e.google.api.expr.v1alpha1.ExprR\x04args\x1as\n" +
+ "\n" +
+ "CreateList\x12:\n" +
+ "\belements\x18\x01 \x03(\v2\x1e.google.api.expr.v1alpha1.ExprR\belements\x12)\n" +
+ "\x10optional_indices\x18\x02 \x03(\x05R\x0foptionalIndices\x1a\xdb\x02\n" +
+ "\fCreateStruct\x12!\n" +
+ "\fmessage_name\x18\x01 \x01(\tR\vmessageName\x12K\n" +
+ "\aentries\x18\x02 \x03(\v21.google.api.expr.v1alpha1.Expr.CreateStruct.EntryR\aentries\x1a\xda\x01\n" +
+ "\x05Entry\x12\x0e\n" +
+ "\x02id\x18\x01 \x01(\x03R\x02id\x12\x1d\n" +
+ "\tfield_key\x18\x02 \x01(\tH\x00R\bfieldKey\x129\n" +
+ "\amap_key\x18\x03 \x01(\v2\x1e.google.api.expr.v1alpha1.ExprH\x00R\x06mapKey\x124\n" +
+ "\x05value\x18\x04 \x01(\v2\x1e.google.api.expr.v1alpha1.ExprR\x05value\x12%\n" +
+ "\x0eoptional_entry\x18\x05 \x01(\bR\roptionalEntryB\n" +
+ "\n" +
+ "\bkey_kind\x1a\x9a\x03\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\x1e.google.api.expr.v1alpha1.ExprR\titerRange\x12\x19\n" +
+ "\baccu_var\x18\x03 \x01(\tR\aaccuVar\x12;\n" +
+ "\taccu_init\x18\x04 \x01(\v2\x1e.google.api.expr.v1alpha1.ExprR\baccuInit\x12E\n" +
+ "\x0eloop_condition\x18\x05 \x01(\v2\x1e.google.api.expr.v1alpha1.ExprR\rloopCondition\x12;\n" +
+ "\tloop_step\x18\x06 \x01(\v2\x1e.google.api.expr.v1alpha1.ExprR\bloopStep\x126\n" +
+ "\x06result\x18\a \x01(\v2\x1e.google.api.expr.v1alpha1.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\"\x8c\a\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\x12Q\n" +
+ "\tpositions\x18\x04 \x03(\v23.google.api.expr.v1alpha1.SourceInfo.PositionsEntryR\tpositions\x12U\n" +
+ "\vmacro_calls\x18\x05 \x03(\v24.google.api.expr.v1alpha1.SourceInfo.MacroCallsEntryR\n" +
+ "macroCalls\x12N\n" +
+ "\n" +
+ "extensions\x18\x06 \x03(\v2..google.api.expr.v1alpha1.SourceInfo.ExtensionR\n" +
+ "extensions\x1a\x80\x03\n" +
+ "\tExtension\x12\x0e\n" +
+ "\x02id\x18\x01 \x01(\tR\x02id\x12i\n" +
+ "\x13affected_components\x18\x02 \x03(\x0e28.google.api.expr.v1alpha1.SourceInfo.Extension.ComponentR\x12affectedComponents\x12P\n" +
+ "\aversion\x18\x03 \x01(\v26.google.api.expr.v1alpha1.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\x03\x1a<\n" +
+ "\x0ePositionsEntry\x12\x10\n" +
+ "\x03key\x18\x01 \x01(\x03R\x03key\x12\x14\n" +
+ "\x05value\x18\x02 \x01(\x05R\x05value:\x028\x01\x1a]\n" +
+ "\x0fMacroCallsEntry\x12\x10\n" +
+ "\x03key\x18\x01 \x01(\x03R\x03key\x124\n" +
+ "\x05value\x18\x02 \x01(\v2\x1e.google.api.expr.v1alpha1.ExprR\x05value:\x028\x01\"p\n" +
+ "\x0eSourcePosition\x12\x1a\n" +
+ "\blocation\x18\x01 \x01(\tR\blocation\x12\x16\n" +
+ "\x06offset\x18\x02 \x01(\x05R\x06offset\x12\x12\n" +
+ "\x04line\x18\x03 \x01(\x05R\x04line\x12\x16\n" +
+ "\x06column\x18\x04 \x01(\x05R\x06columnBk\n" +
+ "\x1ccom.google.api.expr.v1alpha1B\vSyntaxProtoP\x01Z |