From d9f8b26be16ebbae7a89271ab94bb475ac4f3998 Mon Sep 17 00:00:00 2001 From: Brandon Johnson Date: Tue, 31 Oct 2023 09:37:10 -0400 Subject: [PATCH 1/6] chore: bump module versions to v1.39.0 --- cmd/plugindocgen/go.mod | 2 +- go.mod | 44 ++++++++++++------------ processor/datapointcountprocessor/go.mod | 6 ++-- processor/logcountprocessor/go.mod | 6 ++-- processor/metricextractprocessor/go.mod | 4 +-- processor/spancountprocessor/go.mod | 6 ++-- updater/go.mod | 2 +- 7 files changed, 35 insertions(+), 35 deletions(-) diff --git a/cmd/plugindocgen/go.mod b/cmd/plugindocgen/go.mod index b898d49c1..32c82d100 100644 --- a/cmd/plugindocgen/go.mod +++ b/cmd/plugindocgen/go.mod @@ -3,7 +3,7 @@ module github.com/observiq/bindplane-agent/plugindocgen go 1.20 require ( - github.com/observiq/bindplane-agent/receiver/pluginreceiver v1.38.1 + github.com/observiq/bindplane-agent/receiver/pluginreceiver v1.39.0 github.com/spf13/pflag v1.0.5 gopkg.in/yaml.v3 v3.0.1 ) diff --git a/go.mod b/go.mod index 5caac7b16..3f3e9b3b0 100644 --- a/go.mod +++ b/go.mod @@ -5,26 +5,26 @@ go 1.20 require ( github.com/google/uuid v1.3.1 github.com/mholt/archiver/v3 v3.5.1 - github.com/observiq/bindplane-agent/exporter/azureblobexporter v1.38.1 - github.com/observiq/bindplane-agent/exporter/googlecloudexporter v1.38.1 - github.com/observiq/bindplane-agent/exporter/googlemanagedprometheusexporter v1.38.1 - github.com/observiq/bindplane-agent/packagestate v1.38.1 - github.com/observiq/bindplane-agent/processor/datapointcountprocessor v1.38.1 - github.com/observiq/bindplane-agent/processor/logcountprocessor v1.38.1 - github.com/observiq/bindplane-agent/processor/logdeduplicationprocessor v1.38.1 - github.com/observiq/bindplane-agent/processor/maskprocessor v1.38.1 - github.com/observiq/bindplane-agent/processor/metricextractprocessor v1.38.1 - github.com/observiq/bindplane-agent/processor/metricstatsprocessor v1.38.1 - github.com/observiq/bindplane-agent/processor/removeemptyvaluesprocessor v1.38.1 - github.com/observiq/bindplane-agent/processor/resourceattributetransposerprocessor v1.38.1 - github.com/observiq/bindplane-agent/processor/samplingprocessor v1.38.1 - github.com/observiq/bindplane-agent/processor/spancountprocessor v1.38.1 - github.com/observiq/bindplane-agent/processor/throughputmeasurementprocessor v1.38.1 - github.com/observiq/bindplane-agent/receiver/azureblobrehydrationreceiver v1.38.1 - github.com/observiq/bindplane-agent/receiver/m365receiver v1.38.1 - github.com/observiq/bindplane-agent/receiver/pluginreceiver v1.38.1 - github.com/observiq/bindplane-agent/receiver/routereceiver v1.38.1 - github.com/observiq/bindplane-agent/receiver/sapnetweaverreceiver v1.38.1 + github.com/observiq/bindplane-agent/exporter/azureblobexporter v1.39.0 + github.com/observiq/bindplane-agent/exporter/googlecloudexporter v1.39.0 + github.com/observiq/bindplane-agent/exporter/googlemanagedprometheusexporter v1.39.0 + github.com/observiq/bindplane-agent/packagestate v1.39.0 + github.com/observiq/bindplane-agent/processor/datapointcountprocessor v1.39.0 + github.com/observiq/bindplane-agent/processor/logcountprocessor v1.39.0 + github.com/observiq/bindplane-agent/processor/logdeduplicationprocessor v1.39.0 + github.com/observiq/bindplane-agent/processor/maskprocessor v1.39.0 + github.com/observiq/bindplane-agent/processor/metricextractprocessor v1.39.0 + github.com/observiq/bindplane-agent/processor/metricstatsprocessor v1.39.0 + github.com/observiq/bindplane-agent/processor/removeemptyvaluesprocessor v1.39.0 + github.com/observiq/bindplane-agent/processor/resourceattributetransposerprocessor v1.39.0 + github.com/observiq/bindplane-agent/processor/samplingprocessor v1.39.0 + github.com/observiq/bindplane-agent/processor/spancountprocessor v1.39.0 + github.com/observiq/bindplane-agent/processor/throughputmeasurementprocessor v1.39.0 + github.com/observiq/bindplane-agent/receiver/azureblobrehydrationreceiver v1.39.0 + github.com/observiq/bindplane-agent/receiver/m365receiver v1.39.0 + github.com/observiq/bindplane-agent/receiver/pluginreceiver v1.39.0 + github.com/observiq/bindplane-agent/receiver/routereceiver v1.39.0 + github.com/observiq/bindplane-agent/receiver/sapnetweaverreceiver v1.39.0 github.com/oklog/ulid/v2 v2.1.0 github.com/open-telemetry/opamp-go v0.9.0 github.com/open-telemetry/opentelemetry-collector-contrib/connector/countconnector v0.88.0 @@ -230,8 +230,8 @@ require ( github.com/kylelemons/godebug v1.1.0 // indirect github.com/minio/asm2plan9s v0.0.0-20200509001527-cdd76441f9d8 // indirect github.com/minio/c2goasm v0.0.0-20190812172519-36a3d3bbc4f3 // indirect - github.com/observiq/bindplane-agent/counter v1.38.1 // indirect - github.com/observiq/bindplane-agent/expr v1.38.1 // indirect + github.com/observiq/bindplane-agent/counter v1.39.0 // indirect + github.com/observiq/bindplane-agent/expr v1.39.0 // indirect github.com/open-telemetry/opentelemetry-collector-contrib/exporter/googlemanagedprometheusexporter v0.88.0 // indirect github.com/open-telemetry/opentelemetry-collector-contrib/internal/kafka v0.88.0 // indirect github.com/open-telemetry/opentelemetry-collector-contrib/processor/servicegraphprocessor v0.88.0 // indirect diff --git a/processor/datapointcountprocessor/go.mod b/processor/datapointcountprocessor/go.mod index 3a8aa9572..70808c2a6 100644 --- a/processor/datapointcountprocessor/go.mod +++ b/processor/datapointcountprocessor/go.mod @@ -3,9 +3,9 @@ module github.com/observiq/bindplane-agent/processor/datapointcountprocessor go 1.20 require ( - github.com/observiq/bindplane-agent/counter v1.38.1 - github.com/observiq/bindplane-agent/expr v1.38.1 - github.com/observiq/bindplane-agent/receiver/routereceiver v1.38.1 + github.com/observiq/bindplane-agent/counter v1.39.0 + github.com/observiq/bindplane-agent/expr v1.39.0 + github.com/observiq/bindplane-agent/receiver/routereceiver v1.39.0 github.com/open-telemetry/opentelemetry-collector-contrib/pkg/ottl v0.88.0 github.com/stretchr/testify v1.8.4 go.opentelemetry.io/collector/component v0.88.0 diff --git a/processor/logcountprocessor/go.mod b/processor/logcountprocessor/go.mod index 3994d0fd7..a9818506c 100644 --- a/processor/logcountprocessor/go.mod +++ b/processor/logcountprocessor/go.mod @@ -3,9 +3,9 @@ module github.com/observiq/bindplane-agent/processor/logcountprocessor go 1.20 require ( - github.com/observiq/bindplane-agent/counter v1.38.1 - github.com/observiq/bindplane-agent/expr v1.38.1 - github.com/observiq/bindplane-agent/receiver/routereceiver v1.38.1 + github.com/observiq/bindplane-agent/counter v1.39.0 + github.com/observiq/bindplane-agent/expr v1.39.0 + github.com/observiq/bindplane-agent/receiver/routereceiver v1.39.0 github.com/open-telemetry/opentelemetry-collector-contrib/pkg/ottl v0.88.0 github.com/stretchr/testify v1.8.4 go.opentelemetry.io/collector/component v0.88.0 diff --git a/processor/metricextractprocessor/go.mod b/processor/metricextractprocessor/go.mod index d852707f7..0fa5b7516 100644 --- a/processor/metricextractprocessor/go.mod +++ b/processor/metricextractprocessor/go.mod @@ -3,8 +3,8 @@ module github.com/observiq/bindplane-agent/processor/metricextractprocessor go 1.20 require ( - github.com/observiq/bindplane-agent/expr v1.38.1 - github.com/observiq/bindplane-agent/receiver/routereceiver v1.38.1 + github.com/observiq/bindplane-agent/expr v1.39.0 + github.com/observiq/bindplane-agent/receiver/routereceiver v1.39.0 github.com/open-telemetry/opentelemetry-collector-contrib/pkg/ottl v0.88.0 github.com/open-telemetry/opentelemetry-collector-contrib/pkg/pdatatest v0.88.0 github.com/stretchr/testify v1.8.4 diff --git a/processor/spancountprocessor/go.mod b/processor/spancountprocessor/go.mod index b044b4cd1..6654f5078 100644 --- a/processor/spancountprocessor/go.mod +++ b/processor/spancountprocessor/go.mod @@ -3,9 +3,9 @@ module github.com/observiq/bindplane-agent/processor/spancountprocessor go 1.20 require ( - github.com/observiq/bindplane-agent/counter v1.38.1 - github.com/observiq/bindplane-agent/expr v1.38.1 - github.com/observiq/bindplane-agent/receiver/routereceiver v1.38.1 + github.com/observiq/bindplane-agent/counter v1.39.0 + github.com/observiq/bindplane-agent/expr v1.39.0 + github.com/observiq/bindplane-agent/receiver/routereceiver v1.39.0 github.com/open-telemetry/opentelemetry-collector-contrib/pkg/ottl v0.88.0 github.com/stretchr/testify v1.8.4 go.opentelemetry.io/collector/component v0.88.0 diff --git a/updater/go.mod b/updater/go.mod index 656e3a90e..bf44f7c44 100644 --- a/updater/go.mod +++ b/updater/go.mod @@ -4,7 +4,7 @@ go 1.20 require ( github.com/kballard/go-shellquote v0.0.0-20180428030007-95032a82bc51 - github.com/observiq/bindplane-agent/packagestate v1.38.1 + github.com/observiq/bindplane-agent/packagestate v1.39.0 github.com/open-telemetry/opamp-go v0.9.0 github.com/spf13/pflag v1.0.5 github.com/stretchr/testify v1.8.4 From 6fbf4e41addf979ca2c25eb7a5a0246b45bd34ae Mon Sep 17 00:00:00 2001 From: Corbin Phelps Date: Mon, 6 Nov 2023 11:50:37 -0500 Subject: [PATCH 2/6] chore: Removed archived k8s reference (#1325) * Removed archived k8s reference Signed-off-by: Corbin Phelps * PR Feedback Signed-off-by: Corbin Phelps * Removed the k8s google cloud docmentation Signed-off-by: Corbin Phelps --------- Signed-off-by: Corbin Phelps --- README.md | 4 ---- config/google_cloud_exporter/kubernetes/README.md | 15 --------------- docs/getting-started.md | 2 +- 3 files changed, 1 insertion(+), 20 deletions(-) delete mode 100644 config/google_cloud_exporter/kubernetes/README.md diff --git a/README.md b/README.md index 6f1e0e727..3fc456ee7 100644 --- a/README.md +++ b/README.md @@ -59,10 +59,6 @@ sudo sh -c "$(curl -fsSlL https://github.com/observiq/bindplane-agent/releases/l For more installation information see [installing on macOS](/docs/installation-mac.md). -#### Kubernetes - -To deploy the agent on Kubernetes, further documentation can be found at our [observiq-otel-collector-k8s](https://github.com/observIQ/observiq-otel-collector-k8s) repository. - ### Next Steps Now that the agent is installed it is collecting basic metrics about the host machine printing them to the log. If you want to further configure your agent you may do so by editing the config file. To find your config file based on your OS reference the table below: diff --git a/config/google_cloud_exporter/kubernetes/README.md b/config/google_cloud_exporter/kubernetes/README.md deleted file mode 100644 index 194ec847d..000000000 --- a/config/google_cloud_exporter/kubernetes/README.md +++ /dev/null @@ -1,15 +0,0 @@ -# Kubernetes Telemetry with Google Cloud - -The agent is capable of sending Kubernetes telemetry to Google Cloud Monitoring. - -## Deployment - -Deployment documentation can be found in our [observiq-otel-collector-k8s](https://github.com/observIQ/observiq-otel-collector-k8s) repository. - -Deployments are cloud agnostic, meaning the agent(s) can run on most Kubernetes clusters, including development systems such as Minikube. - -All metrics will show up under the following [Monitored resource types](https://cloud.google.com/monitoring/api/resources) -- [k8s_cluster](https://cloud.google.com/monitoring/api/resources) -- [k8s_node](https://cloud.google.com/monitoring/api/resources#tag_k8s_node) -- [k8s_pod](https://cloud.google.com/monitoring/api/resources#tag_k8s_pod) -- [k8s_container](https://cloud.google.com/monitoring/api/resources#tag_k8s_container) diff --git a/docs/getting-started.md b/docs/getting-started.md index 1a1b381ce..c75ba7e84 100644 --- a/docs/getting-started.md +++ b/docs/getting-started.md @@ -23,7 +23,7 @@ msiexec /i "https://github.com/observIQ/bindplane-agent/releases/latest/download sudo sh -c "$(curl -fsSlL https://github.com/observiq/bindplane-agent/releases/latest/download/install_unix.sh)" install_unix.sh ``` -For more details on installation, see our [Linux](/docs/installation-linux.md), [Windows](/docs/installation-windows.md), and [Mac](/docs/installation-mac.md) installation guides. For Kubernetes, visit our [Kubernetes repo](https://github.com/observIQ/observiq-otel-collector-k8s). +For more details on installation, see our [Linux](/docs/installation-linux.md), [Windows](/docs/installation-windows.md), and [Mac](/docs/installation-mac.md) installation guides. ## Setting up pre-requisites and authentication credentials From e1fa864a193ab46759fd902e55b33bed4a36fb32 Mon Sep 17 00:00:00 2001 From: Dakota Paasman <122491662+dpaasman00@users.noreply.github.com> Date: Fri, 10 Nov 2023 08:25:59 -0500 Subject: [PATCH 3/6] feat: Add default HTTP log receiver (#1330) * add default HTTP log receiver * keiths feedback * replace interface{} with any * keiths feedback p2 * brandons feedback & docs update * corbins feedback * update config struct --- docs/receivers.md | 1 + factories/receivers.go | 2 + go.mod | 25 +- go.sum | 44 +-- receiver/httpreceiver/README.md | 61 ++++ receiver/httpreceiver/config.go | 65 ++++ receiver/httpreceiver/config_test.go | 138 +++++++ receiver/httpreceiver/factory.go | 54 +++ receiver/httpreceiver/factory_test.go | 42 +++ receiver/httpreceiver/go.mod | 62 ++++ receiver/httpreceiver/go.sum | 154 ++++++++ .../internal/metadata/generated_status.go | 12 + receiver/httpreceiver/logs.go | 232 ++++++++++++ receiver/httpreceiver/logs_test.go | 344 ++++++++++++++++++ receiver/httpreceiver/metadata.yaml | 7 + 15 files changed, 1210 insertions(+), 33 deletions(-) create mode 100644 receiver/httpreceiver/README.md create mode 100644 receiver/httpreceiver/config.go create mode 100644 receiver/httpreceiver/config_test.go create mode 100644 receiver/httpreceiver/factory.go create mode 100644 receiver/httpreceiver/factory_test.go create mode 100644 receiver/httpreceiver/go.mod create mode 100644 receiver/httpreceiver/go.sum create mode 100644 receiver/httpreceiver/internal/metadata/generated_status.go create mode 100644 receiver/httpreceiver/logs.go create mode 100644 receiver/httpreceiver/logs_test.go create mode 100644 receiver/httpreceiver/metadata.yaml diff --git a/docs/receivers.md b/docs/receivers.md index e4bc5436a..c67ecb55c 100644 --- a/docs/receivers.md +++ b/docs/receivers.md @@ -30,6 +30,7 @@ Below is a list of supported receivers with links to their documentation pages. | Fluentd Forward Receiver | [fluentforwardreceiver](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/receiver/fluentforwardreceiver/README.md) | | Google Cloud Pub/Sub Receiver | [googlecloudpubsubreceiver](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/receiver/googlecloudpubsubreceiver/README.md) | | Google Cloud Spanner Receiver | [googlecloudspannerreceiver](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/receiver/googlecloudspannerreceiver/README.md) | +| HTTP Log Receiver | [httpreceiver](../receiver/httpreceiver/README.md) | | Host Metrics Receiver | [hostmetricsreceiver](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/receiver/hostmetricsreceiver/README.md) | | InfluxDB Receiver | [influxdbreceiver](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/receiver/influxdbreceiver/README.md) | | Jaeger Receiver | [jaegerreceiver](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/receiver/jaegerreceiver/README.md) | diff --git a/factories/receivers.go b/factories/receivers.go index 64b0b1f60..83fa73bc8 100644 --- a/factories/receivers.go +++ b/factories/receivers.go @@ -16,6 +16,7 @@ package factories import ( "github.com/observiq/bindplane-agent/receiver/azureblobrehydrationreceiver" + "github.com/observiq/bindplane-agent/receiver/httpreceiver" "github.com/observiq/bindplane-agent/receiver/m365receiver" "github.com/observiq/bindplane-agent/receiver/pluginreceiver" "github.com/observiq/bindplane-agent/receiver/routereceiver" @@ -115,6 +116,7 @@ var defaultReceivers = []receiver.Factory{ googlecloudpubsubreceiver.NewFactory(), googlecloudspannerreceiver.NewFactory(), hostmetricsreceiver.NewFactory(), + httpreceiver.NewFactory(), iisreceiver.NewFactory(), influxdbreceiver.NewFactory(), jaegerreceiver.NewFactory(), diff --git a/go.mod b/go.mod index 3f3e9b3b0..7b602c0f7 100644 --- a/go.mod +++ b/go.mod @@ -21,6 +21,7 @@ require ( github.com/observiq/bindplane-agent/processor/spancountprocessor v1.39.0 github.com/observiq/bindplane-agent/processor/throughputmeasurementprocessor v1.39.0 github.com/observiq/bindplane-agent/receiver/azureblobrehydrationreceiver v1.39.0 + github.com/observiq/bindplane-agent/receiver/httpreceiver v1.39.0 github.com/observiq/bindplane-agent/receiver/m365receiver v1.39.0 github.com/observiq/bindplane-agent/receiver/pluginreceiver v1.39.0 github.com/observiq/bindplane-agent/receiver/routereceiver v1.39.0 @@ -173,7 +174,7 @@ require ( go.opentelemetry.io/collector/receiver/otlpreceiver v0.88.0 go.uber.org/multierr v1.11.0 go.uber.org/zap v1.26.0 - golang.org/x/sys v0.13.0 + golang.org/x/sys v0.14.0 gopkg.in/natefinch/lumberjack.v2 v2.2.1 gopkg.in/yaml.v3 v3.0.1 ) @@ -266,8 +267,8 @@ require ( go.opentelemetry.io/otel/exporters/stdout/stdoutmetric v0.42.0 // indirect go.opentelemetry.io/otel/exporters/stdout/stdouttrace v1.19.0 // indirect go.opentelemetry.io/proto/otlp v1.0.0 // indirect - google.golang.org/genproto/googleapis/api v0.0.0-20231002182017-d307bd883b97 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231012201019-e917dd12ba7a // indirect + google.golang.org/genproto/googleapis/api v0.0.0-20231016165738-49dd2c1f3d0b // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20231106174013-bbf56f31fb17 // indirect gopkg.in/zorkian/go-datadog-api.v2 v2.30.0 // indirect sigs.k8s.io/controller-runtime v0.16.2 // indirect ) @@ -296,16 +297,16 @@ require ( ) require ( - cloud.google.com/go v0.110.8 // indirect - cloud.google.com/go/compute v1.23.0 // indirect + cloud.google.com/go v0.110.9 // indirect + cloud.google.com/go/compute v1.23.2 // indirect cloud.google.com/go/compute/metadata v0.2.4-0.20230617002413-005d2dfb6b68 // indirect - cloud.google.com/go/iam v1.1.2 // indirect + cloud.google.com/go/iam v1.1.4 // indirect cloud.google.com/go/logging v1.8.1 // indirect - cloud.google.com/go/longrunning v0.5.1 // indirect - cloud.google.com/go/monitoring v1.16.0 // indirect + cloud.google.com/go/longrunning v0.5.3 // indirect + cloud.google.com/go/monitoring v1.16.2 // indirect cloud.google.com/go/pubsub v1.33.0 // indirect cloud.google.com/go/spanner v1.51.0 // indirect - cloud.google.com/go/trace v1.10.1 // indirect + cloud.google.com/go/trace v1.10.3 // indirect code.cloudfoundry.org/clock v1.0.0 // indirect code.cloudfoundry.org/go-diodes v0.0.0-20211115184647-b584dd5df32c // indirect code.cloudfoundry.org/go-loggregator v7.4.0+incompatible // indirect @@ -615,14 +616,14 @@ require ( golang.org/x/oauth2 v0.13.0 // indirect golang.org/x/sync v0.4.0 // indirect golang.org/x/term v0.13.0 // indirect - golang.org/x/text v0.13.0 // indirect + golang.org/x/text v0.14.0 // indirect golang.org/x/time v0.3.0 // indirect golang.org/x/tools v0.14.0 // indirect golang.org/x/xerrors v0.0.0-20220907171357-04be3eba64a2 // indirect gonum.org/v1/gonum v0.14.0 // indirect google.golang.org/api v0.148.0 // indirect google.golang.org/appengine v1.6.7 // indirect - google.golang.org/genproto v0.0.0-20231002182017-d307bd883b97 // indirect + google.golang.org/genproto v0.0.0-20231030173426-d783a09b4405 // indirect google.golang.org/grpc v1.59.0 // indirect google.golang.org/protobuf v1.31.0 // indirect gopkg.in/inf.v0 v0.9.1 // indirect @@ -686,6 +687,8 @@ replace github.com/observiq/bindplane-agent/exporter/googlemanagedprometheusexpo replace github.com/observiq/bindplane-agent/receiver/azureblobrehydrationreceiver => ./receiver/azureblobrehydrationreceiver +replace github.com/observiq/bindplane-agent/receiver/httpreceiver => ./receiver/httpreceiver + // Does not build with windows and only used in configschema executable // Relevant issue https://github.com/mattn/go-ieproxy/issues/45 replace github.com/mattn/go-ieproxy v0.0.9 => github.com/mattn/go-ieproxy v0.0.1 diff --git a/go.sum b/go.sum index b2b3cd0c2..f7565f090 100644 --- a/go.sum +++ b/go.sum @@ -25,28 +25,28 @@ cloud.google.com/go v0.90.0/go.mod h1:kRX0mNRHe0e2rC6oNakvwQqzyDmg57xJ+SZU1eT2aD cloud.google.com/go v0.93.3/go.mod h1:8utlLll2EF5XMAV15woO4lSbWQlk8rer9aLOfLh7+YI= cloud.google.com/go v0.94.1/go.mod h1:qAlAugsXlC+JWO+Bke5vCtc9ONxjQT3drlTTnAplMW4= cloud.google.com/go v0.97.0/go.mod h1:GF7l59pYBVlXQIBLx3a761cZ41F9bBH3JUlihCt2Udc= -cloud.google.com/go v0.110.8 h1:tyNdfIxjzaWctIiLYOTalaLKZ17SI44SKFW26QbOhME= -cloud.google.com/go v0.110.8/go.mod h1:Iz8AkXJf1qmxC3Oxoep8R1T36w8B92yU29PcBhHO5fk= +cloud.google.com/go v0.110.9 h1:e7ITSqGFFk4rbz/JFIqZh3G4VEHguhAL4BQcFlWtU68= +cloud.google.com/go v0.110.9/go.mod h1:rpxevX/0Lqvlbc88b7Sc1SPNdyK1riNBTUU6JXhYNpM= cloud.google.com/go/bigquery v1.0.1/go.mod h1:i/xbL2UlR5RvWAURpBYZTtm/cXjCha9lbfbpx4poX+o= cloud.google.com/go/bigquery v1.3.0/go.mod h1:PjpwJnslEMmckchkHFfq+HTD2DmtT67aNFKH1/VBDHE= cloud.google.com/go/bigquery v1.4.0/go.mod h1:S8dzgnTigyfTmLBfrtrhyYhwRxG72rYxvftPBK2Dvzc= cloud.google.com/go/bigquery v1.5.0/go.mod h1:snEHRnqQbz117VIFhE8bmtwIDY80NLUZUMb4Nv6dBIg= cloud.google.com/go/bigquery v1.7.0/go.mod h1://okPTzCYNXSlb24MZs83e2Do+h+VXtc4gLoIoXIAPc= cloud.google.com/go/bigquery v1.8.0/go.mod h1:J5hqkt3O0uAFnINi6JXValWIb1v0goeZM77hZzJN/fQ= -cloud.google.com/go/compute v1.23.0 h1:tP41Zoavr8ptEqaW6j+LQOnyBBhO7OkOMAGrgLopTwY= -cloud.google.com/go/compute v1.23.0/go.mod h1:4tCnrn48xsqlwSAiLf1HXMQk8CONslYbdiEZc9FEIbM= +cloud.google.com/go/compute v1.23.2 h1:nWEMDhgbBkBJjfpVySqU4jgWdc22PLR0o4vEexZHers= +cloud.google.com/go/compute v1.23.2/go.mod h1:JJ0atRC0J/oWYiiVBmsSsrRnh92DhZPG4hFDcR04Rns= cloud.google.com/go/compute/metadata v0.2.4-0.20230617002413-005d2dfb6b68 h1:aRVqY1p2IJaBGStWMsQMpkAa83cPkCDLl80eOj0Rbz4= cloud.google.com/go/compute/metadata v0.2.4-0.20230617002413-005d2dfb6b68/go.mod h1:1a3eRNYX12fs5UABBIXS8HXVvQbX9hRB/RkEBPORpe8= cloud.google.com/go/datastore v1.0.0/go.mod h1:LXYbyblFSglQ5pkeyhO+Qmw7ukd3C+pD7TKLgZqpHYE= cloud.google.com/go/datastore v1.1.0/go.mod h1:umbIZjpQpHh4hmRpGhH4tLFup+FVzqBi1b3c64qFpCk= -cloud.google.com/go/iam v1.1.2 h1:gacbrBdWcoVmGLozRuStX45YKvJtzIjJdAolzUs1sm4= -cloud.google.com/go/iam v1.1.2/go.mod h1:A5avdyVL2tCppe4unb0951eI9jreack+RJ0/d+KUZOU= +cloud.google.com/go/iam v1.1.4 h1:K6n/GZHFTtEoKT5aUG3l9diPi0VduZNQ1PfdnpkkIFk= +cloud.google.com/go/iam v1.1.4/go.mod h1:l/rg8l1AaA+VFMho/HYx2Vv6xinPSLMF8qfhRPIZ0L8= cloud.google.com/go/logging v1.8.1 h1:26skQWPeYhvIasWKm48+Eq7oUqdcdbwsCVwz5Ys0FvU= cloud.google.com/go/logging v1.8.1/go.mod h1:TJjR+SimHwuC8MZ9cjByQulAMgni+RkXeI3wwctHJEI= -cloud.google.com/go/longrunning v0.5.1 h1:Fr7TXftcqTudoyRJa113hyaqlGdiBQkp0Gq7tErFDWI= -cloud.google.com/go/longrunning v0.5.1/go.mod h1:spvimkwdz6SPWKEt/XBij79E9fiTkHSQl/fRUUQJYJc= -cloud.google.com/go/monitoring v1.16.0 h1:rlndy4K8yknMY9JuGe2aK4SbCh21FXoCdX7SAGHmRgI= -cloud.google.com/go/monitoring v1.16.0/go.mod h1:Ptp15HgAyM1fNICAojDMoNc/wUmn67mLHQfyqbw+poY= +cloud.google.com/go/longrunning v0.5.3 h1:maKa7O9YTzmVzwdlRKr981U1Ys2auup6rpeMt8y3+RU= +cloud.google.com/go/longrunning v0.5.3/go.mod h1:y/0ga59EYu58J6SHmmQOvekvND2qODbu8ywBBW7EK7Y= +cloud.google.com/go/monitoring v1.16.2 h1:gx7BDZcoRqX5DfuJzw9LdhVjEkqCLmDXScdnrmIy9ik= +cloud.google.com/go/monitoring v1.16.2/go.mod h1:B44KGwi4ZCF8Rk/5n+FWeispDXoKSk9oss2QNlXJBgc= cloud.google.com/go/pubsub v1.0.1/go.mod h1:R0Gpsv3s54REJCy4fxDixWD93lHJMoZTyQ2kNxGRt3I= cloud.google.com/go/pubsub v1.1.0/go.mod h1:EwwdRX2sKPjnvnqCa270oGRyludottCI76h+R3AArQw= cloud.google.com/go/pubsub v1.2.0/go.mod h1:jhfEVHT8odbXTkndysNHCcx0awwzvfOlguIAii9o8iA= @@ -60,8 +60,8 @@ cloud.google.com/go/storage v1.5.0/go.mod h1:tpKbwo567HUNpVclU5sGELwQWBDZ8gh0Zeo cloud.google.com/go/storage v1.6.0/go.mod h1:N7U0C8pVQ/+NIKOBQyamJIeKQKkZ+mxpohlUTyfDhBk= cloud.google.com/go/storage v1.8.0/go.mod h1:Wv1Oy7z6Yz3DshWRJFhqM/UCfaWIRTdp0RXyy7KQOVs= cloud.google.com/go/storage v1.10.0/go.mod h1:FLPqc6j+Ki4BU591ie1oL6qBQGu2Bl/tZ9ullr3+Kg0= -cloud.google.com/go/trace v1.10.1 h1:EwGdOLCNfYOOPtgqo+D2sDLZmRCEO1AagRTJCU6ztdg= -cloud.google.com/go/trace v1.10.1/go.mod h1:gbtL94KE5AJLH3y+WVpfWILmqgc6dXcqgNXdOPAQTYk= +cloud.google.com/go/trace v1.10.3 h1:yiQ2EdegdiZDPwNPoUqGYAMd0wNValT/NRsC1XGyBJ0= +cloud.google.com/go/trace v1.10.3/go.mod h1:Ke1bgfc73RV3wUFml+uQp7EsDw4dGaETLxB7Iq/r4CY= code.cloudfoundry.org/clock v0.0.0-20180518195852-02e53af36e6c/go.mod h1:QD9Lzhd/ux6eNQVUDVRJX/RKTigpewimNYBi7ivZKY8= code.cloudfoundry.org/clock v1.0.0 h1:kFXWQM4bxYvdBw2X8BbBeXwQNgfoWv1vqAk2ZZyBN2o= code.cloudfoundry.org/clock v1.0.0/go.mod h1:QD9Lzhd/ux6eNQVUDVRJX/RKTigpewimNYBi7ivZKY8= @@ -2203,8 +2203,8 @@ golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.8.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.11.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.12.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= -golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.14.0 h1:Vz7Qs629MkJkGyHxUlRHizWJRG2j8fbQKjELVSNhy7Q= +golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210220032956-6a3ed077a48d/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= @@ -2228,8 +2228,8 @@ golang.org/x/text v0.3.8/go.mod h1:E6s5w1FMmriuDzIBO73fBruAKo1PCIq6d2Q6DHfQ8WQ= golang.org/x/text v0.4.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= golang.org/x/text v0.5.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= golang.org/x/text v0.7.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= -golang.org/x/text v0.13.0 h1:ablQoSUd0tRdKxZewP80B+BaqeKJuVhuRxj/dkrun3k= -golang.org/x/text v0.13.0/go.mod h1:TvPlkZtksWOMsz7fbANvkp4WM8x/WCo/om8BMLbz+aE= +golang.org/x/text v0.14.0 h1:ScX5w1eTa3QqT8oi6+ziP7dTV1S2+ALU0bI+0zXKWiQ= +golang.org/x/text v0.14.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU= golang.org/x/time v0.0.0-20180412165947-fbb02b2291d2/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= @@ -2414,12 +2414,12 @@ google.golang.org/genproto v0.0.0-20210831024726-fe130286e0e2/go.mod h1:eFjDcFEc google.golang.org/genproto v0.0.0-20210903162649-d08c68adba83/go.mod h1:eFjDcFEctNawg4eG61bRv87N7iHBWyVhJu7u1kqDUXY= google.golang.org/genproto v0.0.0-20210924002016-3dee208752a0/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= google.golang.org/genproto v0.0.0-20220502173005-c8bf987b8c21/go.mod h1:RAyBrSAP7Fh3Nc84ghnVLDPuV51xc9agzmm4Ph6i0Q4= -google.golang.org/genproto v0.0.0-20231002182017-d307bd883b97 h1:SeZZZx0cP0fqUyA+oRzP9k7cSwJlvDFiROO72uwD6i0= -google.golang.org/genproto v0.0.0-20231002182017-d307bd883b97/go.mod h1:t1VqOqqvce95G3hIDCT5FeO3YUc6Q4Oe24L/+rNMxRk= -google.golang.org/genproto/googleapis/api v0.0.0-20231002182017-d307bd883b97 h1:W18sezcAYs+3tDZX4F80yctqa12jcP1PUS2gQu1zTPU= -google.golang.org/genproto/googleapis/api v0.0.0-20231002182017-d307bd883b97/go.mod h1:iargEX0SFPm3xcfMI0d1domjg0ZF4Aa0p2awqyxhvF0= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231012201019-e917dd12ba7a h1:a2MQQVoTo96JC9PMGtGBymLp7+/RzpFc2yX/9WfFg1c= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231012201019-e917dd12ba7a/go.mod h1:4cYg8o5yUbm77w8ZX00LhMVNl/YVBFJRYWDc0uYWMs0= +google.golang.org/genproto v0.0.0-20231030173426-d783a09b4405 h1:I6WNifs6pF9tNdSob2W24JtyxIYjzFB9qDlpUC76q+U= +google.golang.org/genproto v0.0.0-20231030173426-d783a09b4405/go.mod h1:3WDQMjmJk36UQhjQ89emUzb1mdaHcPeeAh4SCBKznB4= +google.golang.org/genproto/googleapis/api v0.0.0-20231016165738-49dd2c1f3d0b h1:CIC2YMXmIhYw6evmhPxBKJ4fmLbOFtXQN/GV3XOZR8k= +google.golang.org/genproto/googleapis/api v0.0.0-20231016165738-49dd2c1f3d0b/go.mod h1:IBQ646DjkDkvUIsVq/cc03FUFQ9wbZu7yE396YcL870= +google.golang.org/genproto/googleapis/rpc v0.0.0-20231106174013-bbf56f31fb17 h1:Jyp0Hsi0bmHXG6k9eATXoYtjd6e2UzZ1SCn/wIupY14= +google.golang.org/genproto/googleapis/rpc v0.0.0-20231106174013-bbf56f31fb17/go.mod h1:oQ5rr10WTTMvP4A36n8JpR1OrO1BEiV4f78CneXZxkA= google.golang.org/grpc v1.14.0/go.mod h1:yo6s7OP7yaDglbqo1J04qKzAhqBH6lvTonzMVmEdcZw= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= diff --git a/receiver/httpreceiver/README.md b/receiver/httpreceiver/README.md new file mode 100644 index 000000000..9d1e8d166 --- /dev/null +++ b/receiver/httpreceiver/README.md @@ -0,0 +1,61 @@ +# HTTP Receiver +This receiver is capable of collecting logs for a variety of services, serving as a default HTTP log receiver. Anything that is able to send JSON structured logs to an endpoint using HTTP will be able to utilize this receiver. + +## Minimum Agent Versions +- Introduced: [v1.39.0](https://github.com/observIQ/bindplane-agent/releases/tag/v1.39.0) + +## Supported Pipelines +- Logs + +## How It Works +1. The user configures this receiver in a pipeline. +2. The user configures a supported component to route telemetry from this receiver. + +## Prerequisites +- The log source can be configured to send logs to an endpoint using HTTP +- The logs sent by the log source are JSON structured + +## Configuration +| Field | Type | Default | Required | Description | +|----------------------|-----------|------------------|----------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| endpoint | string | | `true` | The hostname and port the receiver should listen on for logs being sent as HTTP POST requests. | +| path | string | | `false` | Specifies a path the receiver should be listening to for logs. Useful when the log source also sends other data to the endpoint, such as metrics. | +| tls.key_file | string | | `false` | Configure the receiver to use TLS. | +| tls.cert_file | string | | `false` | Configure the receiver to use TLS. | + +### Example Configuration +```yaml +receivers: + http: + endpoint: "localhost:12345" + path: "/api/v2/logs" +exporters: + googlecloud: + project: my-gcp-project + +service: + pipelines: + logs: + receivers: [http] + exporters: [googlecloud] +``` + +### Example Configuration With TLS +```yaml +receivers: + http: + endpoint: "0.0.0.0:12345" + path: "/logs" + tls: + key_file: "certs/server.key" + cert_file: "certs/server.crt" +exporters: + googlecloud: + project: my-gcp-project + +service: + pipelines: + logs: + receivers: [http] + exporters: [googlecloud] +``` diff --git a/receiver/httpreceiver/config.go b/receiver/httpreceiver/config.go new file mode 100644 index 000000000..feb370be0 --- /dev/null +++ b/receiver/httpreceiver/config.go @@ -0,0 +1,65 @@ +// Copyright observIQ, Inc. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Package httpreceiver is a default HTTP receiver for log ingestion +package httpreceiver + +import ( + "errors" + "net" + "path" + + "go.opentelemetry.io/collector/config/confighttp" +) + +// Config defines the configuration for an HTTP receiver +type Config struct { + Path string `mapstructure:"path"` + confighttp.HTTPServerSettings `mapstructure:",squash"` +} + +var ( + errNoEndpoint = errors.New("an endpoint must be specified") + errBadEndpoint = errors.New("unable to split endpoint into 'host:port' pair") + errBadPath = errors.New("given path is malformed") + errNoCert = errors.New("tls was configured, but no cert file was specified") + errNoKey = errors.New("tls was configured, but no key file was specified") +) + +// Validate ensures an HTTP receiver config is correct +func (c *Config) Validate() error { + if c.Endpoint == "" { + return errNoEndpoint + } + + if _, _, err := net.SplitHostPort(c.Endpoint); err != nil { + return errBadEndpoint + } + if c.TLSSetting != nil { + if c.TLSSetting.CertFile == "" && c.TLSSetting.CertPem == "" { + return errNoCert + } + if c.TLSSetting.KeyFile == "" && c.TLSSetting.KeyPem == "" { + return errNoKey + } + } + if c.Path != "" { + clean := path.Clean(c.Path) + if c.Path != clean { + return errBadPath + } + } + + return nil +} diff --git a/receiver/httpreceiver/config_test.go b/receiver/httpreceiver/config_test.go new file mode 100644 index 000000000..eccc89a3e --- /dev/null +++ b/receiver/httpreceiver/config_test.go @@ -0,0 +1,138 @@ +// Copyright observIQ, Inc. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package httpreceiver + +import ( + "testing" + + "github.com/stretchr/testify/require" + "go.opentelemetry.io/collector/component" + "go.opentelemetry.io/collector/config/confighttp" + "go.opentelemetry.io/collector/config/configtls" +) + +func TestValidate(t *testing.T) { + testCases := []struct { + desc string + expectedErr error + config Config + }{ + { + desc: "pass simple", + config: Config{ + HTTPServerSettings: confighttp.HTTPServerSettings{ + Endpoint: "localhost:12345", + }, + }, + }, + { + desc: "pass complex", + config: Config{ + Path: "/api/v2/logs", + HTTPServerSettings: confighttp.HTTPServerSettings{ + Endpoint: "localhost:12345", + TLSSetting: &configtls.TLSServerSetting{ + TLSSetting: configtls.TLSSetting{ + CertFile: "some_cert_file", + KeyFile: "some_key_file", + }, + }, + }, + }, + }, + { + desc: "fail no endpoint", + expectedErr: errNoEndpoint, + config: Config{ + Path: "/api/v2/logs", + HTTPServerSettings: confighttp.HTTPServerSettings{ + TLSSetting: &configtls.TLSServerSetting{ + TLSSetting: configtls.TLSSetting{ + CertFile: "some_cert_file", + KeyFile: "some_key_file", + }, + }, + }, + }, + }, + { + desc: "fail bad endpoint", + expectedErr: errBadEndpoint, + config: Config{ + Path: "/api/v2/logs", + HTTPServerSettings: confighttp.HTTPServerSettings{ + Endpoint: "localhost12345", + TLSSetting: &configtls.TLSServerSetting{ + TLSSetting: configtls.TLSSetting{ + CertFile: "some_cert_file", + KeyFile: "some_key_file", + }, + }, + }, + }, + }, + { + desc: "fail tls but no CertFile", + expectedErr: errNoCert, + config: Config{ + Path: "/api/v2/logs", + HTTPServerSettings: confighttp.HTTPServerSettings{ + Endpoint: "localhost:12345", + TLSSetting: &configtls.TLSServerSetting{ + TLSSetting: configtls.TLSSetting{ + KeyFile: "some_key_file", + }, + }, + }, + }, + }, + { + desc: "fail tls but no KeyFile", + expectedErr: errNoKey, + config: Config{ + Path: "/api/v2/logs", + HTTPServerSettings: confighttp.HTTPServerSettings{ + Endpoint: "localhost:12345", + TLSSetting: &configtls.TLSServerSetting{ + TLSSetting: configtls.TLSSetting{ + CertFile: "some_cert_file", + }, + }, + }, + }, + }, + { + desc: "fail bad path", + expectedErr: errBadPath, + config: Config{ + Path: "/api , /v2//", + HTTPServerSettings: confighttp.HTTPServerSettings{ + Endpoint: "localhost:12345", + }, + }, + }, + } + + for _, tc := range testCases { + t.Run(tc.desc, func(t *testing.T) { + err := component.ValidateConfig(tc.config) + if tc.expectedErr != nil { + require.EqualError(t, err, tc.expectedErr.Error()) + } else { + require.NoError(t, err) + } + }) + } +} diff --git a/receiver/httpreceiver/factory.go b/receiver/httpreceiver/factory.go new file mode 100644 index 000000000..1648f78c5 --- /dev/null +++ b/receiver/httpreceiver/factory.go @@ -0,0 +1,54 @@ +// Copyright observIQ, Inc. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package httpreceiver + +import ( + "context" + "fmt" + + "go.opentelemetry.io/collector/component" + "go.opentelemetry.io/collector/consumer" + "go.opentelemetry.io/collector/receiver" + + "github.com/observiq/bindplane-agent/receiver/httpreceiver/internal/metadata" +) + +// NewFactory creates a new factory for the HTTP receiver +func NewFactory() receiver.Factory { + return receiver.NewFactory( + metadata.Type, + createDefaultConfig, + receiver.WithLogs(createLogsReceiver, metadata.LogsStability), + ) +} + +func createLogsReceiver( + _ context.Context, + params receiver.CreateSettings, + rConf component.Config, + consumer consumer.Logs, +) (receiver.Logs, error) { + cfg := rConf.(*Config) + r, err := newHTTPLogsReceiver(params, cfg, consumer) + if err != nil { + return nil, fmt.Errorf("unable to create an HTTP log receiver instance: %w", err) + } + return r, nil +} + +func createDefaultConfig() component.Config { + c := &Config{} + return c +} diff --git a/receiver/httpreceiver/factory_test.go b/receiver/httpreceiver/factory_test.go new file mode 100644 index 000000000..61454aa0a --- /dev/null +++ b/receiver/httpreceiver/factory_test.go @@ -0,0 +1,42 @@ +// Copyright observIQ, Inc. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package httpreceiver + +import ( + "context" + "testing" + + "github.com/observiq/bindplane-agent/receiver/httpreceiver/internal/metadata" + "github.com/stretchr/testify/require" + "go.opentelemetry.io/collector/receiver/receivertest" +) + +func TestType(t *testing.T) { + factory := NewFactory() + ft := factory.Type() + require.EqualValues(t, metadata.Type, ft) +} + +func TestCreateLogsReceiver(t *testing.T) { + cfg := createDefaultConfig().(*Config) + + _, err := NewFactory().CreateLogsReceiver( + context.Background(), + receivertest.NewNopCreateSettings(), + cfg, + nil, + ) + require.NoError(t, err) +} diff --git a/receiver/httpreceiver/go.mod b/receiver/httpreceiver/go.mod new file mode 100644 index 000000000..80dc71096 --- /dev/null +++ b/receiver/httpreceiver/go.mod @@ -0,0 +1,62 @@ +module github.com/observiq/bindplane-agent/receiver/httpreceiver + +go 1.20 + +require ( + github.com/open-telemetry/opentelemetry-collector-contrib/pkg/pdatatest v0.88.0 + github.com/stretchr/testify v1.8.4 + go.opentelemetry.io/collector/component v0.88.0 + go.opentelemetry.io/collector/config/confighttp v0.88.0 + go.opentelemetry.io/collector/config/configtls v0.88.0 + go.opentelemetry.io/collector/consumer v0.88.0 + go.opentelemetry.io/collector/pdata v1.0.0-rcv0017 + go.opentelemetry.io/collector/receiver v0.88.0 + go.uber.org/multierr v1.11.0 + go.uber.org/zap v1.26.0 +) + +require ( + github.com/cespare/xxhash/v2 v2.2.0 // indirect + github.com/davecgh/go-spew v1.1.1 // indirect + github.com/felixge/httpsnoop v1.0.3 // indirect + github.com/fsnotify/fsnotify v1.6.0 // indirect + github.com/go-logr/logr v1.2.4 // indirect + github.com/go-logr/stdr v1.2.2 // indirect + github.com/gogo/protobuf v1.3.2 // indirect + github.com/golang/protobuf v1.5.3 // indirect + github.com/golang/snappy v0.0.4 // indirect + github.com/json-iterator/go v1.1.12 // indirect + github.com/klauspost/compress v1.17.1 // indirect + github.com/knadh/koanf/maps v0.1.1 // indirect + github.com/knadh/koanf/providers/confmap v0.1.0 // indirect + github.com/knadh/koanf/v2 v2.0.1 // indirect + github.com/mitchellh/copystructure v1.2.0 // indirect + github.com/mitchellh/mapstructure v1.5.1-0.20220423185008-bf980b35cac4 // indirect + github.com/mitchellh/reflectwalk v1.0.2 // indirect + github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect + github.com/modern-go/reflect2 v1.0.2 // indirect + github.com/open-telemetry/opentelemetry-collector-contrib/pkg/pdatautil v0.88.0 // indirect + github.com/pmezard/go-difflib v1.0.0 // indirect + github.com/rs/cors v1.10.1 // indirect + go.opentelemetry.io/collector v0.88.0 // indirect + go.opentelemetry.io/collector/config/configauth v0.88.0 // indirect + go.opentelemetry.io/collector/config/configcompression v0.88.0 // indirect + go.opentelemetry.io/collector/config/configopaque v0.88.0 // indirect + go.opentelemetry.io/collector/config/configtelemetry v0.88.0 // indirect + go.opentelemetry.io/collector/config/internal v0.88.0 // indirect + go.opentelemetry.io/collector/confmap v0.88.0 // indirect + go.opentelemetry.io/collector/extension v0.88.0 // indirect + go.opentelemetry.io/collector/extension/auth v0.88.0 // indirect + go.opentelemetry.io/collector/featuregate v1.0.0-rcv0017 // indirect + go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.45.0 // indirect + go.opentelemetry.io/otel v1.19.0 // indirect + go.opentelemetry.io/otel/metric v1.19.0 // indirect + go.opentelemetry.io/otel/trace v1.19.0 // indirect + golang.org/x/net v0.17.0 // indirect + golang.org/x/sys v0.14.0 // indirect + golang.org/x/text v0.14.0 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20231106174013-bbf56f31fb17 // indirect + google.golang.org/grpc v1.59.0 // indirect + google.golang.org/protobuf v1.31.0 // indirect + gopkg.in/yaml.v3 v3.0.1 // indirect +) diff --git a/receiver/httpreceiver/go.sum b/receiver/httpreceiver/go.sum new file mode 100644 index 000000000..6052da559 --- /dev/null +++ b/receiver/httpreceiver/go.sum @@ -0,0 +1,154 @@ +github.com/cespare/xxhash/v2 v2.2.0 h1:DC2CZ1Ep5Y4k3ZQ899DldepgrayRUGE6BBZ/cd9Cj44= +github.com/cespare/xxhash/v2 v2.2.0/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= +github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= +github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= +github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= +github.com/felixge/httpsnoop v1.0.3 h1:s/nj+GCswXYzN5v2DpNMuMQYe+0DDwt5WVCU6CWBdXk= +github.com/felixge/httpsnoop v1.0.3/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= +github.com/fsnotify/fsnotify v1.6.0 h1:n+5WquG0fcWoWp6xPWfHdbskMCQaFnG6PfBrh1Ky4HY= +github.com/fsnotify/fsnotify v1.6.0/go.mod h1:sl3t1tCWJFWoRz9R8WJCbQihKKwmorjAbSClcnxKAGw= +github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= +github.com/go-logr/logr v1.2.4 h1:g01GSCwiDw2xSZfjJ2/T9M+S6pFdcNtFYsp+Y43HYDQ= +github.com/go-logr/logr v1.2.4/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= +github.com/go-logr/stdr v1.2.2 h1:hSWxHoqTgW2S2qGc0LTAI563KZ5YKYRhT3MFKZMbjag= +github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE= +github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= +github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= +github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk= +github.com/golang/protobuf v1.5.3 h1:KhyjKVUg7Usr/dYsdSqoFveMYd5ko72D+zANwlG1mmg= +github.com/golang/protobuf v1.5.3/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= +github.com/golang/snappy v0.0.4 h1:yAGX7huGHXlcLOEtBnF4w7FQwA26wojNCwOYAEhLjQM= +github.com/golang/snappy v0.0.4/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= +github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= +github.com/google/go-cmp v0.5.9 h1:O2Tfq5qg4qc4AmwVlvv0oLiVAGB7enBSJ2x2DqQFi38= +github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= +github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnrnM= +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.17.1 h1:NE3C767s2ak2bweCZo3+rdP4U/HoyVXLv/X9f2gPS5g= +github.com/klauspost/compress v1.17.1/go.mod h1:ntbaceVETuRiXiv4DpjP66DpAtAGkEQskQzEyD//IeE= +github.com/knadh/koanf/maps v0.1.1 h1:G5TjmUh2D7G2YWf5SQQqSiHRJEjaicvU0KpypqB3NIs= +github.com/knadh/koanf/maps v0.1.1/go.mod h1:npD/QZY3V6ghQDdcQzl1W4ICNVTkohC8E73eI2xW4yI= +github.com/knadh/koanf/providers/confmap v0.1.0 h1:gOkxhHkemwG4LezxxN8DMOFopOPghxRVp7JbIvdvqzU= +github.com/knadh/koanf/providers/confmap v0.1.0/go.mod h1:2uLhxQzJnyHKfxG927awZC7+fyHFdQkd697K4MdLnIU= +github.com/knadh/koanf/v2 v2.0.1 h1:1dYGITt1I23x8cfx8ZnldtezdyaZtfAuRtIFOiRzK7g= +github.com/knadh/koanf/v2 v2.0.1/go.mod h1:ZeiIlIDXTE7w1lMT6UVcNiRAS2/rCeLn/GdLNvY1Dus= +github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE= +github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= +github.com/mitchellh/copystructure v1.2.0 h1:vpKXTN4ewci03Vljg/q9QvCGUDttBOGBIa15WveJJGw= +github.com/mitchellh/copystructure v1.2.0/go.mod h1:qLl+cE2AmVv+CoeAwDPye/v+N2HKCj9FbZEVFJRxO9s= +github.com/mitchellh/mapstructure v1.5.1-0.20220423185008-bf980b35cac4 h1:BpfhmLKZf+SjVanKKhCgf3bg+511DmU9eDQTen7LLbY= +github.com/mitchellh/mapstructure v1.5.1-0.20220423185008-bf980b35cac4/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= +github.com/mitchellh/reflectwalk v1.0.2 h1:G2LzWKi524PWgd3mLHV8Y5k7s6XUvT0Gef6zxSIeXaQ= +github.com/mitchellh/reflectwalk v1.0.2/go.mod h1:mSTlrgnPZtwu0c4WaC2kGObEpuNDbx0jmZXqmk4esnw= +github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= +github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg= +github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= +github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9Gz0M= +github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= +github.com/open-telemetry/opentelemetry-collector-contrib/internal/coreinternal v0.88.0 h1:2HoGcjmHHIDMafd3Uj3flQJrV8TC2FAnUiTKD8FH0G8= +github.com/open-telemetry/opentelemetry-collector-contrib/pkg/pdatatest v0.88.0 h1:jqdkgfHXcjvk6L2CyTUv3Rn+whX3TfFWd0Mz4QNAV1c= +github.com/open-telemetry/opentelemetry-collector-contrib/pkg/pdatatest v0.88.0/go.mod h1:5QXLdN4gdjAEcMHNEK/RrDdp+FObca0bS4/pRauyZs8= +github.com/open-telemetry/opentelemetry-collector-contrib/pkg/pdatautil v0.88.0 h1:S1FEVDH5GEMZQuHg8jfv47lCHHDFVjZBpO/Yrb/vKpE= +github.com/open-telemetry/opentelemetry-collector-contrib/pkg/pdatautil v0.88.0/go.mod h1:IJqzjDv6ZFeu7cYGCUzQ5/3CuTPVIo3UAGK3o2jK/Sw= +github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= +github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= +github.com/rogpeppe/go-internal v1.10.0 h1:TMyTOH3F/DB16zRVcYyreMH6GnZZrwQVAoYjRBZyWFQ= +github.com/rs/cors v1.10.1 h1:L0uuZVXIKlI1SShY2nhFfo44TYvDPQ1w4oFkUJNfhyo= +github.com/rs/cors v1.10.1/go.mod h1:XyqrcTp5zjWr1wsJ8PIRZssZ8b/WMcMf71DJnit4EMU= +github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= +github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= +github.com/stretchr/testify v1.8.4 h1:CcVxjf3Q8PM0mHUKJCdn+eZZtm5yQwehR5yeSVQQcUk= +github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= +github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= +github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= +go.opentelemetry.io/collector v0.88.0 h1:I0lerJK1h88vk7enriSgLV+h7dM099G9FgwkfmIZaf0= +go.opentelemetry.io/collector v0.88.0/go.mod h1:we0quZ+4txHS3Sfb0VdjFv95KYLGmto4ZAThCHiYgGA= +go.opentelemetry.io/collector/component v0.88.0 h1:LU/1ov5D/O/gv9D2Uv88EjNKHn7DHcUCZn1qQsb/zgw= +go.opentelemetry.io/collector/component v0.88.0/go.mod h1:4utKxz4Lilym3SPxNXJHosdaTjT1aQxI+TCmnJO54pU= +go.opentelemetry.io/collector/config/configauth v0.88.0 h1:EpAB9j7GvNf6M5+5QZvUPMBksS5+rVIdE+10r+AmsBw= +go.opentelemetry.io/collector/config/configauth v0.88.0/go.mod h1:iMPoqAeGB9UScF/sugPF8xcuctlhx8jFK2jAmzDn/1E= +go.opentelemetry.io/collector/config/configcompression v0.88.0 h1:9Ky6C4c8z1AXwJ5QwXMpwRZ4lRYenAxUjMXKoUXbzoA= +go.opentelemetry.io/collector/config/configcompression v0.88.0/go.mod h1:LaavoxZsro5lL7qh1g9DMifG0qixWPEecW18Qr8bpag= +go.opentelemetry.io/collector/config/confighttp v0.88.0 h1:RykKy8wnn0KrpPyy6U/dVczNccqDBZYfvPy3RqZNTBE= +go.opentelemetry.io/collector/config/confighttp v0.88.0/go.mod h1:LMtHaaftWIKeTCCI8yMXWuMv2auea9wAROAwXzUgtRg= +go.opentelemetry.io/collector/config/configopaque v0.88.0 h1:4Q4UnPdAQzGqPsR7mTegJ47eT/2IvCosEnJstl9re6A= +go.opentelemetry.io/collector/config/configopaque v0.88.0/go.mod h1:TPCHaU+QXiEV+JXbgyr6mSErTI9chwQyasDVMdJr3eY= +go.opentelemetry.io/collector/config/configtelemetry v0.88.0 h1:54Z9uoSTpbkq3esDwHvJMChoUH8p/nfesG2xJTOXayY= +go.opentelemetry.io/collector/config/configtelemetry v0.88.0/go.mod h1:+LAXM5WFMW/UbTlAuSs6L/W72WC+q8TBJt/6z39FPOU= +go.opentelemetry.io/collector/config/configtls v0.88.0 h1:XL2jAiee2hai/DXmEqAwg1rWojSX5ltkkj8tIU43SVo= +go.opentelemetry.io/collector/config/configtls v0.88.0/go.mod h1:kh0EjprdBzrE1Zpp6V0pdSVXHlU7dkBTQfIKAQiKFKQ= +go.opentelemetry.io/collector/config/internal v0.88.0 h1:pNzJkUh6Zvr+d0MOcQs3Rj822vGntPAlRDtAM5EGpD4= +go.opentelemetry.io/collector/config/internal v0.88.0/go.mod h1:42VsQ/1kP2qnvzjNi+dfNP+KyCFRADejyrJ8m2GVL3M= +go.opentelemetry.io/collector/confmap v0.88.0 h1:tOgY6NXMXAL2hz2+zVDQ0jvBlCUHprSf90bw5ktbdaI= +go.opentelemetry.io/collector/confmap v0.88.0/go.mod h1:CSJlMk1KRZloXAygpiPeCLpuQiLVDEZYbGsGHIKHeUg= +go.opentelemetry.io/collector/consumer v0.88.0 h1:l8Ty5UHhZ2U6WCp4yHt97uW6vN1vMP0JbFeQEaVnEgY= +go.opentelemetry.io/collector/consumer v0.88.0/go.mod h1:VVoafgyhjpO6fuJu12GqspmuLrn91JCOou0sOtb9GOg= +go.opentelemetry.io/collector/extension v0.88.0 h1:/WH97pQYypL7ZC5OEccoE0gFs6fjBC/Uh9NuVEYEoZ0= +go.opentelemetry.io/collector/extension v0.88.0/go.mod h1:5wPlOyWtVJcZS9CMhFUnuRvNQ0XIoV/iUSaZWtCjoHA= +go.opentelemetry.io/collector/extension/auth v0.88.0 h1:4vjVCWwkh3uGqClM32jbmUDGzZ22lK4IdoSTd5xTu/s= +go.opentelemetry.io/collector/extension/auth v0.88.0/go.mod h1:IcwiPhj6ZGTaZ7WVRVvl97uyw9NShsVqcTRLtXddpK0= +go.opentelemetry.io/collector/featuregate v1.0.0-rcv0017 h1:DtJQalPXMWQqT6jd2LZ1oKrOfLJJRCi+rh2LKnkj4Zo= +go.opentelemetry.io/collector/featuregate v1.0.0-rcv0017/go.mod h1:fLmJMf1AoHttkF8p5oJAc4o5ZpHu8yO5XYJ7gbLCLzo= +go.opentelemetry.io/collector/pdata v1.0.0-rcv0017 h1:AgALhc2VenoA5l1DvTdg7mkzaBGqoTSuMkAtjsttBFo= +go.opentelemetry.io/collector/pdata v1.0.0-rcv0017/go.mod h1:Rv9fOclA5AtM/JGm0d4jBOIAo1+jBA13UT5Bx0ovXi4= +go.opentelemetry.io/collector/receiver v0.88.0 h1:MPvVAFOfjl0+Ylka7so8QoK8T2Za2471rv5t3sqbbSY= +go.opentelemetry.io/collector/receiver v0.88.0/go.mod h1:MIZ6jPPZ+I8XibZm6I3RAn9h7Wcy2ZJsPmtXd2BLr60= +go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.45.0 h1:x8Z78aZx8cOF0+Kkazoc7lwUNMGy0LrzEMxTm4BbTxg= +go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.45.0/go.mod h1:62CPTSry9QZtOaSsE3tOzhx6LzDhHnXJ6xHeMNNiM6Q= +go.opentelemetry.io/otel v1.19.0 h1:MuS/TNf4/j4IXsZuJegVzI1cwut7Qc00344rgH7p8bs= +go.opentelemetry.io/otel v1.19.0/go.mod h1:i0QyjOq3UPoTzff0PJB2N66fb4S0+rSbSB15/oyH9fY= +go.opentelemetry.io/otel/metric v1.19.0 h1:aTzpGtV0ar9wlV4Sna9sdJyII5jTVJEvKETPiOKwvpE= +go.opentelemetry.io/otel/metric v1.19.0/go.mod h1:L5rUsV9kM1IxCj1MmSdS+JQAcVm319EUrDVLrt7jqt8= +go.opentelemetry.io/otel/trace v1.19.0 h1:DFVQmlVbfVeOuBRrwdtaehRrWiL1JoVs9CPIQ1Dzxpg= +go.opentelemetry.io/otel/trace v1.19.0/go.mod h1:mfaSyvGyEJEI0nyV2I4qhNQnbBOUUmYZpYojqMnX2vo= +go.uber.org/goleak v1.2.1 h1:NBol2c7O1ZokfZ0LEU9K6Whx/KnwvepVetCUhtKja4A= +go.uber.org/multierr v1.11.0 h1:blXXJkSxSSfBVBlC76pxqeO+LN3aDfLQo+309xJstO0= +go.uber.org/multierr v1.11.0/go.mod h1:20+QtiLqy0Nd6FdQB9TLXag12DsQkrbs3htMFfDN80Y= +go.uber.org/zap v1.26.0 h1:sI7k6L95XOKS281NhVKOFCUNIvv9e0w4BF8N3u+tCRo= +go.uber.org/zap v1.26.0/go.mod h1:dtElttAiwGvoJ/vj4IwHBS/gXsEu/pZ50mUIRWuG0so= +golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= +golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= +golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= +golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= +golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= +golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= +golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= +golang.org/x/net v0.0.0-20200226121028-0de0cce0169b/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= +golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= +golang.org/x/net v0.17.0 h1:pVaXccu2ozPjCXewfr1S7xza/zcXTity9cCdXQYSjIM= +golang.org/x/net v0.17.0/go.mod h1:NxSsAGuq816PNPmqtQdLE42eU2Fs7NoRIZrHJAlaCOE= +golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/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.0.0-20220908164124-27713097b956/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.14.0 h1:Vz7Qs629MkJkGyHxUlRHizWJRG2j8fbQKjELVSNhy7Q= +golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= +golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= +golang.org/x/text v0.14.0 h1:ScX5w1eTa3QqT8oi6+ziP7dTV1S2+ALU0bI+0zXKWiQ= +golang.org/x/text v0.14.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU= +golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= +golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= +golang.org/x/tools v0.0.0-20200619180055-7c47624df98f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= +golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= +golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +google.golang.org/genproto/googleapis/rpc v0.0.0-20231106174013-bbf56f31fb17 h1:Jyp0Hsi0bmHXG6k9eATXoYtjd6e2UzZ1SCn/wIupY14= +google.golang.org/genproto/googleapis/rpc v0.0.0-20231106174013-bbf56f31fb17/go.mod h1:oQ5rr10WTTMvP4A36n8JpR1OrO1BEiV4f78CneXZxkA= +google.golang.org/grpc v1.59.0 h1:Z5Iec2pjwb+LEOqzpB2MR12/eKFhDPhuqW91O+4bwUk= +google.golang.org/grpc v1.59.0/go.mod h1:aUPDwccQo6OTjy7Hct4AfBPD1GptF4fyUjIkQ9YtF98= +google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw= +google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= +google.golang.org/protobuf v1.31.0 h1:g0LDEJHgrBl9N9r17Ru3sqWhkIx2NB67okBHPwC7hs8= +google.golang.org/protobuf v1.31.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= +gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= +gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= +gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= +gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= diff --git a/receiver/httpreceiver/internal/metadata/generated_status.go b/receiver/httpreceiver/internal/metadata/generated_status.go new file mode 100644 index 000000000..ceae52e61 --- /dev/null +++ b/receiver/httpreceiver/internal/metadata/generated_status.go @@ -0,0 +1,12 @@ +// Code generated by mdatagen. DO NOT EDIT. + +package metadata + +import ( + "go.opentelemetry.io/collector/component" +) + +const ( + Type = "http" + LogsStability = component.StabilityLevelAlpha +) diff --git a/receiver/httpreceiver/logs.go b/receiver/httpreceiver/logs.go new file mode 100644 index 000000000..27a01a45b --- /dev/null +++ b/receiver/httpreceiver/logs.go @@ -0,0 +1,232 @@ +// Copyright observIQ, Inc. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package httpreceiver + +import ( + "context" + "encoding/json" + "errors" + "fmt" + "io" + "net/http" + "sync" + "time" + "unicode" + + "go.opentelemetry.io/collector/component" + "go.opentelemetry.io/collector/config/confighttp" + "go.opentelemetry.io/collector/consumer" + "go.opentelemetry.io/collector/pdata/pcommon" + "go.opentelemetry.io/collector/pdata/plog" + "go.opentelemetry.io/collector/receiver" + "go.uber.org/zap" +) + +type httpLogsReceiver struct { + path string + serverSettings *confighttp.HTTPServerSettings + telemetrySettings component.TelemetrySettings + server *http.Server + consumer consumer.Logs + wg sync.WaitGroup + logger *zap.Logger +} + +// newHTTPLogsReceiver returns a newly configured httpLogsReceiver +func newHTTPLogsReceiver(params receiver.CreateSettings, cfg *Config, consumer consumer.Logs) (*httpLogsReceiver, error) { + return &httpLogsReceiver{ + path: cfg.Path, + serverSettings: &cfg.HTTPServerSettings, + telemetrySettings: params.TelemetrySettings, + consumer: consumer, + logger: params.Logger, + }, nil +} + +// Start calls startListening +func (r *httpLogsReceiver) Start(_ context.Context, host component.Host) error { + return r.startListening(host) +} + +// startListening starts serve on the server using TLS depending on receiver configuration +func (r *httpLogsReceiver) startListening(host component.Host) error { + r.logger.Debug("starting receiver HTTP server") + var err error + r.server, err = r.serverSettings.ToServer(host, r.telemetrySettings, r) + if err != nil { + return fmt.Errorf("to server: %w", err) + } + + listener, err := r.serverSettings.ToListener() + if err != nil { + return fmt.Errorf("to listener: %w", err) + } + + r.wg.Add(1) + go func() { + defer r.wg.Done() + + if r.serverSettings.TLSSetting != nil { + r.logger.Debug("starting ServeTLS", + zap.String("address", r.serverSettings.Endpoint), + zap.String("cert_file", r.serverSettings.TLSSetting.CertFile), + zap.String("key_file", r.serverSettings.TLSSetting.KeyFile), + ) + + err := r.server.ServeTLS(listener, r.serverSettings.TLSSetting.CertFile, r.serverSettings.TLSSetting.KeyFile) + r.logger.Debug("ServeTLS done") + if err != http.ErrServerClosed { + r.logger.Error("ServeTLS failed", zap.Error(err)) + host.ReportFatalError(err) + } + } else { + r.logger.Debug("starting to serve", + zap.String("address", r.serverSettings.Endpoint), + ) + + err := r.server.Serve(listener) + r.logger.Debug("Serve done") + if err != http.ErrServerClosed { + r.logger.Error("Serve failed", zap.Error(err)) + host.ReportFatalError(err) + } + } + }() + + return nil +} + +// Shutdown calls shutdownListener +func (r *httpLogsReceiver) Shutdown(ctx context.Context) error { + return r.shutdownListener(ctx) +} + +// shutdownLIstener tells the server to stop serving and waits for it to stop +func (r *httpLogsReceiver) shutdownListener(ctx context.Context) error { + r.logger.Debug("shutting down server") + + if err := r.server.Shutdown(ctx); err != nil { + return err + } + r.logger.Debug("waiting for shutdown to complete") + r.wg.Wait() + return nil + +} + +// handleRequest is the function the server uses for requests; calls ConsumeLogs +func (r *httpLogsReceiver) ServeHTTP(rw http.ResponseWriter, req *http.Request) { + // path was configured && this req.URL does not match it + if r.path != "" && req.URL.Path != r.path { + rw.WriteHeader(http.StatusNotFound) + r.logger.Debug("received request to path that does not match the configured path", zap.String("request path", req.URL.Path)) + return + } + + // read in request body + r.logger.Debug("reading in request body") + payload, err := io.ReadAll(req.Body) + if err != nil { + rw.WriteHeader(http.StatusUnprocessableEntity) + r.logger.Error("failed to read logs payload", zap.Error(err), zap.String("remote", req.RemoteAddr)) + return + } + + // parse []byte into map structure + logs, err := parsePayload(payload) + if err != nil { + rw.WriteHeader(http.StatusUnprocessableEntity) + r.logger.Error("failed to convert log request payload to maps", zap.Error(err), zap.String("payload", string(payload))) + return + } + + // consume logs after processing + if err := r.consumer.ConsumeLogs(req.Context(), r.processLogs(pcommon.NewTimestampFromTime(time.Now()), logs)); err != nil { + rw.WriteHeader(http.StatusInternalServerError) + r.logger.Error("failed to consume logs", zap.Error(err)) + return + } + + rw.WriteHeader(http.StatusOK) +} + +// processLogs transforms the parsed payload into plog.Logs +func (r *httpLogsReceiver) processLogs(now pcommon.Timestamp, logs []map[string]any) plog.Logs { + pLogs := plog.NewLogs() + resourceLogs := pLogs.ResourceLogs().AppendEmpty() + scopeLogs := resourceLogs.ScopeLogs().AppendEmpty() + + for _, log := range logs { + logRecord := scopeLogs.LogRecords().AppendEmpty() + + logRecord.SetObservedTimestamp(now) + + if err := logRecord.Body().SetEmptyMap().FromRaw(log); err != nil { + r.logger.Warn("unable to set log body", zap.Error(err)) + } + } + + return pLogs +} + +// parsePayload transforms the payload into []map[string]any structure +func parsePayload(payload []byte) ([]map[string]any, error) { + firstChar := seekFirstNonWhitespace(string(payload)) + switch firstChar { + case "{": + rawLogObject := map[string]any{} + if err := json.Unmarshal(payload, &rawLogObject); err != nil { + return nil, err + } + return []map[string]any{rawLogObject}, nil + case "[": + rawLogsArray := []json.RawMessage{} + if err := json.Unmarshal(payload, &rawLogsArray); err != nil { + return nil, err + } + return parseJSONArray(rawLogsArray) + default: + return nil, errors.New("unsupported payload format, expected either a JSON object or array") + } +} + +// seekFirstNonWhitespace finds the first non whitespace character of the string +func seekFirstNonWhitespace(s string) string { + firstChar := "" + for _, r := range s { + if unicode.IsSpace(r) { + continue + } + firstChar = string(r) + break + } + return firstChar +} + +// parseJSONArray parses a []json.RawMessage into an array of map[string]any +func parseJSONArray(rawLogs []json.RawMessage) ([]map[string]any, error) { + logs := make([]map[string]any, 0, len(rawLogs)) + for _, l := range rawLogs { + if len(l) == 0 { + continue + } + var log map[string]any + if err := json.Unmarshal(l, &log); err != nil { + return nil, err + } + logs = append(logs, log) + } + return logs, nil +} diff --git a/receiver/httpreceiver/logs_test.go b/receiver/httpreceiver/logs_test.go new file mode 100644 index 000000000..e7971b432 --- /dev/null +++ b/receiver/httpreceiver/logs_test.go @@ -0,0 +1,344 @@ +// Copyright observIQ, Inc. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package httpreceiver + +import ( + "bytes" + "encoding/json" + "errors" + "io" + "net/http" + "net/http/httptest" + "net/textproto" + "net/url" + "testing" + "time" + + "github.com/open-telemetry/opentelemetry-collector-contrib/pkg/pdatatest/plogtest" + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" + "go.opentelemetry.io/collector/config/confighttp" + "go.opentelemetry.io/collector/config/configtls" + "go.opentelemetry.io/collector/consumer" + "go.opentelemetry.io/collector/consumer/consumertest" + "go.opentelemetry.io/collector/pdata/pcommon" + "go.opentelemetry.io/collector/pdata/plog" + "go.opentelemetry.io/collector/receiver/receivertest" + "go.uber.org/zap/zaptest" +) + +// tests parsePayload() and processLogs() +func TestPayloadToLogRecord(t *testing.T) { + testCases := []struct { + desc string + payload string + expectedErr error + expectedLogs func(*testing.T, string) plog.Logs + }{ + { + desc: "simple pass", + payload: `[{"message": "2023/11/06 08:09:10 Generic event", "status": "info", "timestamp": 1699276151086, "hostname": "Dakotas-MBP-2.hsd1.mi.comcast.net", "service": "custom_file", "ddsource": "my_app", "ddtags": "filename:dd-log-file.log"}]`, + expectedLogs: expectedLogs, + }, + { + desc: "multiple pass", + payload: `[{"message": "2023/11/06 08:09:10 Generic event", "status": "info", "timestamp": 1699276151086, "hostname": "Dakotas-MBP-2.hsd1.mi.comcast.net", "service": "custom_file", "ddsource": "my_app", "ddtags": "filename:dd-log-file.log"}, {"message": "2023/11/06 08:10:10 Generic event", "status": "info", "timestamp": 1699276151086, "hostname": "Dakotas-MBP-2.hsd1.mi.comcast.net", "service": "custom_file", "ddsource": "my_app", "ddtags": "filename:dd-log-file.log"}]`, + expectedLogs: expectedLogs, + }, + { + desc: "nested json", + payload: `[{"status": "info", "timestamp": "8402734234", "message": {"data": "hello world"}, "hostname": "localhost"}]`, + expectedLogs: expectedLogs, + }, + { + desc: "object json", + payload: `{"status": "info", "timestamp": "8402734234", "message": {"data": "hello world"}, "hostname": "localhost"}`, + expectedLogs: func(t *testing.T, s string) plog.Logs { + logs := plog.NewLogs() + resourceLogs := logs.ResourceLogs().AppendEmpty() + scopeLogs := resourceLogs.ScopeLogs().AppendEmpty() + + rawLog := json.RawMessage{} + require.NoError(t, json.Unmarshal([]byte(s), &rawLog)) + + logRecord := scopeLogs.LogRecords().AppendEmpty() + logRecord.SetObservedTimestamp(pcommon.NewTimestampFromTime(time.Now())) + + var log map[string]any + require.NoError(t, json.Unmarshal(rawLog, &log)) + require.NoError(t, logRecord.Body().SetEmptyMap().FromRaw(log)) + + return logs + }, + }, + } + + for _, tc := range testCases { + t.Run(tc.desc, func(t *testing.T) { + r := newReceiver(t, &Config{ + Path: "", + HTTPServerSettings: confighttp.HTTPServerSettings{ + Endpoint: "localhost:12345", + TLSSetting: &configtls.TLSServerSetting{}, + }, + }, &consumertest.LogsSink{}) + var logs plog.Logs + raw, err := parsePayload([]byte(tc.payload)) + if err == nil { + logs = r.processLogs(pcommon.NewTimestampFromTime(time.Now()), raw) + } + + if tc.expectedErr != nil { + require.Error(t, err) + require.Nil(t, logs) + require.EqualError(t, err, tc.expectedErr.Error()) + } else { + require.NoError(t, err) + require.NotNil(t, logs) + require.NoError(t, plogtest.CompareLogs(tc.expectedLogs(t, tc.payload), logs, plogtest.IgnoreObservedTimestamp())) + } + }) + } +} + +func expectedLogs(t *testing.T, payload string) plog.Logs { + logs := plog.NewLogs() + resourceLogs := logs.ResourceLogs().AppendEmpty() + scopeLogs := resourceLogs.ScopeLogs().AppendEmpty() + + rawLogs := []json.RawMessage{} + require.NoError(t, json.Unmarshal([]byte(payload), &rawLogs)) + + for _, l := range rawLogs { + logRecord := scopeLogs.LogRecords().AppendEmpty() + + logRecord.SetObservedTimestamp(pcommon.NewTimestampFromTime(time.Now())) + + var log map[string]any + require.NoError(t, json.Unmarshal(l, &log)) + require.NoError(t, logRecord.Body().SetEmptyMap().FromRaw(log)) + } + + return logs +} + +// tests handleRequest() +func TestServeHTTP(t *testing.T) { + testCases := []struct { + desc string + cfg *Config + request *http.Request + expectedStatusCode int + logExpected bool + consumerFailure bool + }{ + { + desc: "simple", + cfg: &Config{ + Path: "", + HTTPServerSettings: confighttp.HTTPServerSettings{ + Endpoint: "localhost:12345", + TLSSetting: &configtls.TLSServerSetting{}, + }, + }, + request: &http.Request{ + Method: "POST", + URL: &url.URL{}, + Header: map[string][]string{ + textproto.CanonicalMIMEHeaderKey("Content-Encoding"): {"identity"}, + textproto.CanonicalMIMEHeaderKey("Content-Type"): {"application/json"}, + }, + Body: io.NopCloser(bytes.NewBufferString(`[{"message": "2023/11/06 08:09:10 Generic event", "status": "info", "timestamp": 1699276151086, "hostname": "Dakotas-MBP-2.hsd1.mi.comcast.net", "service": "custom_file", "ddsource": "my_app", "ddtags": "filename:dd-log-file.log"}]`)), + }, + expectedStatusCode: http.StatusOK, + logExpected: true, + consumerFailure: false, + }, + { + desc: "with path", + cfg: &Config{ + Path: "/logs", + HTTPServerSettings: confighttp.HTTPServerSettings{ + Endpoint: "localhost:12345", + TLSSetting: &configtls.TLSServerSetting{}, + }, + }, + request: &http.Request{ + Method: "POST", + URL: &url.URL{ + Path: "/logs", + }, + Header: map[string][]string{ + textproto.CanonicalMIMEHeaderKey("Content-Encoding"): {"identity"}, + textproto.CanonicalMIMEHeaderKey("Content-Type"): {"application/json"}, + }, + Body: io.NopCloser(bytes.NewBufferString(`[{"message": "2023/11/06 08:09:10 Generic event", "status": "info", "timestamp": 1699276151086, "hostname": "Dakotas-MBP-2.hsd1.mi.comcast.net", "service": "custom_file", "ddsource": "my_app", "ddtags": "filename:dd-log-file.log"}]`)), + }, + expectedStatusCode: http.StatusOK, + logExpected: true, + consumerFailure: false, + }, + { + desc: "bad path", + cfg: &Config{ + Path: "/logs", + HTTPServerSettings: confighttp.HTTPServerSettings{ + Endpoint: "localhost:12345", + TLSSetting: &configtls.TLSServerSetting{}, + }, + }, + request: &http.Request{ + Method: "POST", + URL: &url.URL{ + Path: "/metrics", + }, + Header: map[string][]string{ + textproto.CanonicalMIMEHeaderKey("Content-Encoding"): {"identity"}, + textproto.CanonicalMIMEHeaderKey("Content-Type"): {"application/json"}, + }, + Body: io.NopCloser(bytes.NewBufferString(`[{"message": "2023/11/06 08:09:10 Generic event", "status": "info", "timestamp": 1699276151086, "hostname": "Dakotas-MBP-2.hsd1.mi.comcast.net", "service": "custom_file", "ddsource": "my_app", "ddtags": "filename:dd-log-file.log"}]`)), + }, + expectedStatusCode: http.StatusNotFound, + logExpected: false, + consumerFailure: false, + }, + { + desc: "bad json, parse fails", + cfg: &Config{ + Path: "/logs", + HTTPServerSettings: confighttp.HTTPServerSettings{ + Endpoint: "localhost:12345", + TLSSetting: &configtls.TLSServerSetting{}, + }, + }, + request: &http.Request{ + Method: "POST", + URL: &url.URL{ + Path: "/logs", + }, + Header: map[string][]string{ + textproto.CanonicalMIMEHeaderKey("Content-Encoding"): {"identity"}, + textproto.CanonicalMIMEHeaderKey("Content-Type"): {"application/json"}, + }, + Body: io.NopCloser(bytes.NewBufferString(`hello world`)), + }, + expectedStatusCode: http.StatusUnprocessableEntity, + logExpected: false, + consumerFailure: false, + }, + { + desc: "consumer fails", + cfg: &Config{ + Path: "/logs", + HTTPServerSettings: confighttp.HTTPServerSettings{ + Endpoint: "localhost:12345", + TLSSetting: &configtls.TLSServerSetting{}, + }, + }, + request: &http.Request{ + Method: "POST", + URL: &url.URL{ + Path: "/logs", + }, + Header: map[string][]string{ + textproto.CanonicalMIMEHeaderKey("Content-Encoding"): {"identity"}, + textproto.CanonicalMIMEHeaderKey("Content-Type"): {"application/json"}, + }, + Body: io.NopCloser(bytes.NewBufferString(`[{"message": "2023/11/06 08:09:10 Generic event", "status": "info", "timestamp": 1699276151086, "hostname": "Dakotas-MBP-2.hsd1.mi.comcast.net", "service": "custom_file", "ddsource": "my_app", "ddtags": "filename:dd-log-file.log"}]`)), + }, + expectedStatusCode: http.StatusInternalServerError, + logExpected: false, + consumerFailure: true, + }, + { + desc: "connectivity test", + cfg: &Config{ + Path: "/logs", + HTTPServerSettings: confighttp.HTTPServerSettings{ + Endpoint: "localhost:12345", + TLSSetting: &configtls.TLSServerSetting{}, + }, + }, + request: &http.Request{ + Method: "POST", + URL: &url.URL{ + Path: "/logs", + }, + Header: map[string][]string{ + textproto.CanonicalMIMEHeaderKey("Content-Encoding"): {"identity"}, + textproto.CanonicalMIMEHeaderKey("Content-Type"): {"application/json"}, + }, + Body: io.NopCloser(bytes.NewBufferString(`{}`)), + }, + expectedStatusCode: http.StatusOK, + logExpected: true, + consumerFailure: false, + }, + { + desc: "simple; json object", + cfg: &Config{ + Path: "", + HTTPServerSettings: confighttp.HTTPServerSettings{ + Endpoint: "localhost:12345", + TLSSetting: &configtls.TLSServerSetting{}, + }, + }, + request: &http.Request{ + Method: "POST", + URL: &url.URL{}, + Header: map[string][]string{ + textproto.CanonicalMIMEHeaderKey("Content-Encoding"): {"identity"}, + textproto.CanonicalMIMEHeaderKey("Content-Type"): {"application/json"}, + }, + Body: io.NopCloser(bytes.NewBufferString(`{"message": "2023/11/06 08:09:10 Generic event", "status": "info", "timestamp": 1699276151086, "hostname": "Dakotas-MBP-2.hsd1.mi.comcast.net", "service": "custom_file", "ddsource": "my_app", "ddtags": "filename:dd-log-file.log"}`)), + }, + expectedStatusCode: http.StatusOK, + logExpected: true, + consumerFailure: false, + }, + } + + for _, tc := range testCases { + t.Run(tc.desc, func(t *testing.T) { + var consumer consumer.Logs + if tc.consumerFailure { + consumer = consumertest.NewErr(errors.New("consumer failed")) + } else { + consumer = &consumertest.LogsSink{} + } + + r := newReceiver(t, tc.cfg, consumer) + rec := httptest.NewRecorder() + r.ServeHTTP(rec, tc.request) + + assert.Equal(t, tc.expectedStatusCode, rec.Code, "status codes are not equal") + if !tc.consumerFailure { + if tc.logExpected { + assert.Equal(t, 1, consumer.(*consumertest.LogsSink).LogRecordCount(), "did not receive log record") + } else { + assert.Equal(t, 0, consumer.(*consumertest.LogsSink).LogRecordCount(), "Received log record when it should have been dropped") + } + } + }) + } +} + +func newReceiver(t *testing.T, cfg *Config, c consumer.Logs) *httpLogsReceiver { + s := receivertest.NewNopCreateSettings() + s.Logger = zaptest.NewLogger(t) + r, err := newHTTPLogsReceiver(s, cfg, c) + require.NoError(t, err) + return r +} diff --git a/receiver/httpreceiver/metadata.yaml b/receiver/httpreceiver/metadata.yaml new file mode 100644 index 000000000..87396ca7c --- /dev/null +++ b/receiver/httpreceiver/metadata.yaml @@ -0,0 +1,7 @@ +type: http + +status: + class: receiver + stability: + alpha: [logs] + distributions: [observiq] From f484d280bd5e105de4bde4dbc7e6a284c3b5de32 Mon Sep 17 00:00:00 2001 From: Corbin Phelps Date: Mon, 13 Nov 2023 10:30:19 -0500 Subject: [PATCH 4/6] deps: Updated OTel to v0.88.0 (#1333) Updated otel to v0.88.0 Signed-off-by: Corbin Phelps --- processor/datapointcountprocessor/go.mod | 2 +- processor/datapointcountprocessor/go.sum | 4 ++-- processor/logcountprocessor/go.mod | 2 +- processor/logcountprocessor/go.sum | 4 ++-- processor/spancountprocessor/go.mod | 2 +- processor/spancountprocessor/go.sum | 4 ++-- receiver/httpreceiver/go.mod | 2 +- 7 files changed, 10 insertions(+), 10 deletions(-) diff --git a/processor/datapointcountprocessor/go.mod b/processor/datapointcountprocessor/go.mod index 70808c2a6..d70e4c5c3 100644 --- a/processor/datapointcountprocessor/go.mod +++ b/processor/datapointcountprocessor/go.mod @@ -11,7 +11,7 @@ require ( go.opentelemetry.io/collector/component v0.88.0 go.opentelemetry.io/collector/consumer v0.88.0 go.opentelemetry.io/collector/pdata v1.0.0-rcv0017 - go.opentelemetry.io/collector/processor v0.86.0 + go.opentelemetry.io/collector/processor v0.88.0 go.opentelemetry.io/collector/receiver v0.88.0 go.uber.org/zap v1.26.0 ) diff --git a/processor/datapointcountprocessor/go.sum b/processor/datapointcountprocessor/go.sum index 90ba48980..420c6706b 100644 --- a/processor/datapointcountprocessor/go.sum +++ b/processor/datapointcountprocessor/go.sum @@ -276,8 +276,8 @@ go.opentelemetry.io/collector/featuregate v1.0.0-rcv0017 h1:DtJQalPXMWQqT6jd2LZ1 go.opentelemetry.io/collector/featuregate v1.0.0-rcv0017/go.mod h1:fLmJMf1AoHttkF8p5oJAc4o5ZpHu8yO5XYJ7gbLCLzo= go.opentelemetry.io/collector/pdata v1.0.0-rcv0017 h1:AgALhc2VenoA5l1DvTdg7mkzaBGqoTSuMkAtjsttBFo= go.opentelemetry.io/collector/pdata v1.0.0-rcv0017/go.mod h1:Rv9fOclA5AtM/JGm0d4jBOIAo1+jBA13UT5Bx0ovXi4= -go.opentelemetry.io/collector/processor v0.86.0 h1:b4Htiom5mgcM5d7Memw1NkxBKgOADF1je0mLIhulQUM= -go.opentelemetry.io/collector/processor v0.86.0/go.mod h1:gJCNmRCqm/GKBHjRqlvRxMqWWcLCe1S6QNOxjtFv638= +go.opentelemetry.io/collector/processor v0.88.0 h1:5BUZaH+RhTpgTVqBZCrBnN/vl0M1CtwQsZ8ek4iH1lc= +go.opentelemetry.io/collector/processor v0.88.0/go.mod h1:2T5KxgBQxXuuyMu9dh+PIBxQ/geCFYcdnjmlWZx8o3E= go.opentelemetry.io/collector/receiver v0.88.0 h1:MPvVAFOfjl0+Ylka7so8QoK8T2Za2471rv5t3sqbbSY= go.opentelemetry.io/collector/receiver v0.88.0/go.mod h1:MIZ6jPPZ+I8XibZm6I3RAn9h7Wcy2ZJsPmtXd2BLr60= go.opentelemetry.io/otel v1.19.0 h1:MuS/TNf4/j4IXsZuJegVzI1cwut7Qc00344rgH7p8bs= diff --git a/processor/logcountprocessor/go.mod b/processor/logcountprocessor/go.mod index a9818506c..d69a12b69 100644 --- a/processor/logcountprocessor/go.mod +++ b/processor/logcountprocessor/go.mod @@ -11,7 +11,7 @@ require ( go.opentelemetry.io/collector/component v0.88.0 go.opentelemetry.io/collector/consumer v0.88.0 go.opentelemetry.io/collector/pdata v1.0.0-rcv0017 - go.opentelemetry.io/collector/processor v0.86.0 + go.opentelemetry.io/collector/processor v0.88.0 go.opentelemetry.io/collector/receiver v0.88.0 go.uber.org/zap v1.26.0 ) diff --git a/processor/logcountprocessor/go.sum b/processor/logcountprocessor/go.sum index 7c972824d..d792f7ae0 100644 --- a/processor/logcountprocessor/go.sum +++ b/processor/logcountprocessor/go.sum @@ -275,8 +275,8 @@ go.opentelemetry.io/collector/featuregate v1.0.0-rcv0017 h1:DtJQalPXMWQqT6jd2LZ1 go.opentelemetry.io/collector/featuregate v1.0.0-rcv0017/go.mod h1:fLmJMf1AoHttkF8p5oJAc4o5ZpHu8yO5XYJ7gbLCLzo= go.opentelemetry.io/collector/pdata v1.0.0-rcv0017 h1:AgALhc2VenoA5l1DvTdg7mkzaBGqoTSuMkAtjsttBFo= go.opentelemetry.io/collector/pdata v1.0.0-rcv0017/go.mod h1:Rv9fOclA5AtM/JGm0d4jBOIAo1+jBA13UT5Bx0ovXi4= -go.opentelemetry.io/collector/processor v0.86.0 h1:b4Htiom5mgcM5d7Memw1NkxBKgOADF1je0mLIhulQUM= -go.opentelemetry.io/collector/processor v0.86.0/go.mod h1:gJCNmRCqm/GKBHjRqlvRxMqWWcLCe1S6QNOxjtFv638= +go.opentelemetry.io/collector/processor v0.88.0 h1:5BUZaH+RhTpgTVqBZCrBnN/vl0M1CtwQsZ8ek4iH1lc= +go.opentelemetry.io/collector/processor v0.88.0/go.mod h1:2T5KxgBQxXuuyMu9dh+PIBxQ/geCFYcdnjmlWZx8o3E= go.opentelemetry.io/collector/receiver v0.88.0 h1:MPvVAFOfjl0+Ylka7so8QoK8T2Za2471rv5t3sqbbSY= go.opentelemetry.io/collector/receiver v0.88.0/go.mod h1:MIZ6jPPZ+I8XibZm6I3RAn9h7Wcy2ZJsPmtXd2BLr60= go.opentelemetry.io/otel v1.19.0 h1:MuS/TNf4/j4IXsZuJegVzI1cwut7Qc00344rgH7p8bs= diff --git a/processor/spancountprocessor/go.mod b/processor/spancountprocessor/go.mod index 6654f5078..f8d41b091 100644 --- a/processor/spancountprocessor/go.mod +++ b/processor/spancountprocessor/go.mod @@ -11,7 +11,7 @@ require ( go.opentelemetry.io/collector/component v0.88.0 go.opentelemetry.io/collector/consumer v0.88.0 go.opentelemetry.io/collector/pdata v1.0.0-rcv0017 - go.opentelemetry.io/collector/processor v0.86.0 + go.opentelemetry.io/collector/processor v0.88.0 go.opentelemetry.io/collector/receiver v0.88.0 go.uber.org/zap v1.26.0 ) diff --git a/processor/spancountprocessor/go.sum b/processor/spancountprocessor/go.sum index 90ba48980..420c6706b 100644 --- a/processor/spancountprocessor/go.sum +++ b/processor/spancountprocessor/go.sum @@ -276,8 +276,8 @@ go.opentelemetry.io/collector/featuregate v1.0.0-rcv0017 h1:DtJQalPXMWQqT6jd2LZ1 go.opentelemetry.io/collector/featuregate v1.0.0-rcv0017/go.mod h1:fLmJMf1AoHttkF8p5oJAc4o5ZpHu8yO5XYJ7gbLCLzo= go.opentelemetry.io/collector/pdata v1.0.0-rcv0017 h1:AgALhc2VenoA5l1DvTdg7mkzaBGqoTSuMkAtjsttBFo= go.opentelemetry.io/collector/pdata v1.0.0-rcv0017/go.mod h1:Rv9fOclA5AtM/JGm0d4jBOIAo1+jBA13UT5Bx0ovXi4= -go.opentelemetry.io/collector/processor v0.86.0 h1:b4Htiom5mgcM5d7Memw1NkxBKgOADF1je0mLIhulQUM= -go.opentelemetry.io/collector/processor v0.86.0/go.mod h1:gJCNmRCqm/GKBHjRqlvRxMqWWcLCe1S6QNOxjtFv638= +go.opentelemetry.io/collector/processor v0.88.0 h1:5BUZaH+RhTpgTVqBZCrBnN/vl0M1CtwQsZ8ek4iH1lc= +go.opentelemetry.io/collector/processor v0.88.0/go.mod h1:2T5KxgBQxXuuyMu9dh+PIBxQ/geCFYcdnjmlWZx8o3E= go.opentelemetry.io/collector/receiver v0.88.0 h1:MPvVAFOfjl0+Ylka7so8QoK8T2Za2471rv5t3sqbbSY= go.opentelemetry.io/collector/receiver v0.88.0/go.mod h1:MIZ6jPPZ+I8XibZm6I3RAn9h7Wcy2ZJsPmtXd2BLr60= go.opentelemetry.io/otel v1.19.0 h1:MuS/TNf4/j4IXsZuJegVzI1cwut7Qc00344rgH7p8bs= diff --git a/receiver/httpreceiver/go.mod b/receiver/httpreceiver/go.mod index 80dc71096..487e0748e 100644 --- a/receiver/httpreceiver/go.mod +++ b/receiver/httpreceiver/go.mod @@ -11,7 +11,6 @@ require ( go.opentelemetry.io/collector/consumer v0.88.0 go.opentelemetry.io/collector/pdata v1.0.0-rcv0017 go.opentelemetry.io/collector/receiver v0.88.0 - go.uber.org/multierr v1.11.0 go.uber.org/zap v1.26.0 ) @@ -52,6 +51,7 @@ require ( go.opentelemetry.io/otel v1.19.0 // indirect go.opentelemetry.io/otel/metric v1.19.0 // indirect go.opentelemetry.io/otel/trace v1.19.0 // indirect + go.uber.org/multierr v1.11.0 // indirect golang.org/x/net v0.17.0 // indirect golang.org/x/sys v0.14.0 // indirect golang.org/x/text v0.14.0 // indirect From e43c72d7db226299fb3e8e7d6644da28bc531292 Mon Sep 17 00:00:00 2001 From: Corbin Phelps Date: Tue, 14 Nov 2023 07:57:13 -0500 Subject: [PATCH 5/6] deps: Dependabot 11-13-23 (#1334) * Updated google.golang.org/api to v0.150.0 Signed-off-by: Corbin Phelps * Updated golang.org/x/sys to v0.14.0 Signed-off-by: Corbin Phelps * Updated github.com/shirou/gopsutil/v3 to v3.23.10 Signed-off-by: Corbin Phelps * Updated github.com/google/uuid to v1.4.0 Signed-off-by: Corbin Phelps * Updated github.com/docker/docker to v24.0.7+incompatible Signed-off-by: Corbin Phelps --------- Signed-off-by: Corbin Phelps --- cmd/plugindocgen/go.mod | 10 ++-- cmd/plugindocgen/go.sum | 33 ++++++------- exporter/azureblobexporter/go.mod | 2 +- exporter/azureblobexporter/go.sum | 4 +- exporter/googlecloudexporter/go.mod | 23 ++++----- exporter/googlecloudexporter/go.sum | 48 ++++++++++--------- .../googlemanagedprometheusexporter/go.mod | 23 ++++----- .../googlemanagedprometheusexporter/go.sum | 48 ++++++++++--------- expr/go.mod | 4 +- expr/go.sum | 8 ++-- go.mod | 12 ++--- go.sum | 26 +++++----- processor/datapointcountprocessor/go.mod | 4 +- processor/datapointcountprocessor/go.sum | 8 ++-- processor/logcountprocessor/go.mod | 4 +- processor/logcountprocessor/go.sum | 8 ++-- processor/logdeduplicationprocessor/go.mod | 2 +- processor/logdeduplicationprocessor/go.sum | 4 +- processor/maskprocessor/go.mod | 2 +- processor/maskprocessor/go.sum | 4 +- processor/metricextractprocessor/go.mod | 4 +- processor/metricextractprocessor/go.sum | 8 ++-- processor/metricstatsprocessor/go.mod | 2 +- processor/metricstatsprocessor/go.sum | 4 +- processor/removeemptyvaluesprocessor/go.mod | 2 +- processor/removeemptyvaluesprocessor/go.sum | 4 +- .../go.mod | 6 +-- .../go.sum | 15 +++--- processor/samplingprocessor/go.mod | 2 +- processor/samplingprocessor/go.sum | 4 +- processor/spancountprocessor/go.mod | 4 +- processor/spancountprocessor/go.sum | 8 ++-- .../throughputmeasurementprocessor/go.mod | 2 +- .../throughputmeasurementprocessor/go.sum | 4 +- receiver/azureblobrehydrationreceiver/go.mod | 2 +- receiver/azureblobrehydrationreceiver/go.sum | 4 +- receiver/m365receiver/go.mod | 4 +- receiver/m365receiver/go.sum | 8 ++-- receiver/pluginreceiver/go.mod | 22 ++++----- receiver/pluginreceiver/go.sum | 44 ++++++++--------- receiver/routereceiver/go.mod | 2 +- receiver/routereceiver/go.sum | 4 +- receiver/sapnetweaverreceiver/go.mod | 2 +- receiver/sapnetweaverreceiver/go.sum | 4 +- updater/go.mod | 2 +- updater/go.sum | 4 +- 46 files changed, 228 insertions(+), 220 deletions(-) diff --git a/cmd/plugindocgen/go.mod b/cmd/plugindocgen/go.mod index 32c82d100..33ef69101 100644 --- a/cmd/plugindocgen/go.mod +++ b/cmd/plugindocgen/go.mod @@ -21,7 +21,7 @@ require ( github.com/gogo/protobuf v1.3.2 // indirect github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect github.com/golang/protobuf v1.5.3 // indirect - github.com/google/uuid v1.3.1 // indirect + github.com/google/uuid v1.4.0 // indirect github.com/grpc-ecosystem/grpc-gateway/v2 v2.18.0 // indirect github.com/inconshreveable/mousetrap v1.1.0 // indirect github.com/json-iterator/go v1.1.12 // indirect @@ -42,7 +42,7 @@ require ( github.com/prometheus/common v0.44.0 // indirect github.com/prometheus/procfs v0.11.1 // indirect github.com/prometheus/statsd_exporter v0.22.7 // indirect - github.com/shirou/gopsutil/v3 v3.23.9 // indirect + github.com/shirou/gopsutil/v3 v3.23.10 // indirect github.com/shoenig/go-m1cpu v0.1.6 // indirect github.com/spf13/cobra v1.7.0 // indirect github.com/tklauser/go-sysconf v0.3.12 // indirect @@ -85,11 +85,11 @@ require ( go.uber.org/multierr v1.11.0 // indirect go.uber.org/zap v1.26.0 // indirect golang.org/x/net v0.17.0 // indirect - golang.org/x/sys v0.13.0 // indirect + golang.org/x/sys v0.14.0 // indirect golang.org/x/text v0.13.0 // indirect gonum.org/v1/gonum v0.14.0 // indirect - google.golang.org/genproto/googleapis/api v0.0.0-20231002182017-d307bd883b97 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231009173412-8bfb1ae86b6c // indirect + google.golang.org/genproto/googleapis/api v0.0.0-20231016165738-49dd2c1f3d0b // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20231030173426-d783a09b4405 // indirect google.golang.org/grpc v1.59.0 // indirect google.golang.org/protobuf v1.31.0 // indirect gopkg.in/yaml.v2 v2.4.0 // indirect diff --git a/cmd/plugindocgen/go.sum b/cmd/plugindocgen/go.sum index 359ae8ff7..ae8386495 100644 --- a/cmd/plugindocgen/go.sum +++ b/cmd/plugindocgen/go.sum @@ -30,7 +30,7 @@ cloud.google.com/go/compute v1.6.0/go.mod h1:T29tfhtVbq1wvAPo0E3+7vhgmkOYeXjhFvz cloud.google.com/go/compute v1.6.1/go.mod h1:g85FgpzFvNULZ+S8AYq87axRKuf2Kh7deLqV/jJ3thU= cloud.google.com/go/compute v1.7.0/go.mod h1:435lt8av5oL9P3fv1OEzSbSUe+ybHXGMPQHHZWZxy9U= cloud.google.com/go/compute v1.10.0/go.mod h1:ER5CLbMxl90o2jtNbGSbtfOpQKR0t15FOtRsugnLrlU= -cloud.google.com/go/compute v1.23.0 h1:tP41Zoavr8ptEqaW6j+LQOnyBBhO7OkOMAGrgLopTwY= +cloud.google.com/go/compute v1.23.1 h1:V97tBoDaZHb6leicZ1G6DLK2BAaZLJ/7+9BB/En3hR0= cloud.google.com/go/compute/metadata v0.2.3 h1:mg4jlk7mCAj6xXp9UJ4fjI9VUI5rubuGBW5aJ7UnBMY= cloud.google.com/go/containeranalysis v0.5.1/go.mod h1:1D92jd8gRR/c0fGMlymRgxWD3Qw9C1ff6/T7mLgVL8I= cloud.google.com/go/containeranalysis v0.6.0/go.mod h1:HEJoiEIu+lEXM+k7+qLCci0h33lX3ZqoYFdmPcoO7s4= @@ -227,7 +227,7 @@ github.com/denisenkom/go-mssqldb v0.12.2 h1:1OcPn5GBIobjWNd+8yjfHNIaFX14B1pWI3F9 github.com/dennwc/varint v1.0.0 h1:kGNFFSSw8ToIy3obO/kKr8U9GZYUAxQEVuix4zfDWzE= github.com/digitalocean/godo v1.99.0 h1:gUHO7n9bDaZFWvbzOum4bXE0/09ZuYA9yA8idQHX57E= github.com/docker/distribution v2.8.2+incompatible h1:T3de5rq0dB1j30rp0sA2rER+m322EBzniBPB6ZIzuh8= -github.com/docker/docker v24.0.6+incompatible h1:hceabKCtUgDqPu+qm0NgsaXf28Ljf4/pWFL7xjWWDgE= +github.com/docker/docker v24.0.7+incompatible h1:Wo6l37AuwP3JaMnZa226lzVXGA3F9Ig1seQen0cKYlM= github.com/docker/go-connections v0.4.0 h1:El9xVISelRB7BuFusrZozjnkIM5YnzCViNKohAFqRJQ= github.com/docker/go-units v0.5.0 h1:69rxXcBk27SvSaaxTtLh/8llcHD8vYHT7WSdRZ/jvr4= github.com/dustin/go-humanize v1.0.0/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk= @@ -333,6 +333,7 @@ github.com/google/go-cmp v0.5.7/go.mod h1:n+brtR0CgQNWTVd5ZUFpTBC8YFBDLK/h/bpaJ8 github.com/google/go-cmp v0.5.8/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/go-cmp v0.5.9/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= +github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/go-querystring v1.1.0 h1:AnCroh3fv4ZBgVIf1Iwtovgjaw/GiKJo8M8yD/fhyJ8= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/gofuzz v1.2.0 h1:xRy4A+RhZaiKjJ1bPfwQ8sedCA+YS2YcCHW6ec7JMi0= @@ -340,12 +341,12 @@ github.com/google/martian/v3 v3.2.1/go.mod h1:oBOf6HBosgwRXnUGWUB05QECsc6uvmMiJ3 github.com/google/s2a-go v0.1.7 h1:60BLSyTrOV4/haCDW4zb1guZItoSq8foHCXrAnjBo/o= github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/google/uuid v1.3.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/google/uuid v1.3.1 h1:KjJaJ9iWZ3jOFZIf1Lqf4laDRCasjl0BCmnEGxkdLb4= -github.com/google/uuid v1.3.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= +github.com/google/uuid v1.4.0 h1:MtMxsa51/r9yyhkyLsVeVt0B+BGQZzpQiTQ4eHZ8bc4= +github.com/google/uuid v1.4.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/googleapis/enterprise-certificate-proxy v0.0.0-20220520183353-fd19c99a87aa/go.mod h1:17drOmN3MwGY7t0e+Ei9b45FFGA3fBs3x36SsCg1hq8= github.com/googleapis/enterprise-certificate-proxy v0.1.0/go.mod h1:17drOmN3MwGY7t0e+Ei9b45FFGA3fBs3x36SsCg1hq8= github.com/googleapis/enterprise-certificate-proxy v0.2.0/go.mod h1:8C0jb7/mgJe/9KK8Lm7X9ctZC2t60YyIpYEI16jx0Qg= -github.com/googleapis/enterprise-certificate-proxy v0.3.1 h1:SBWmZhjUDRorQxrN0nwzf+AHBxnbFjViHQS4P0yVpmQ= +github.com/googleapis/enterprise-certificate-proxy v0.3.2 h1:Vie5ybvEvT75RniqhfFxPRy3Bf7vr3h0cechB90XaQs= github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk= github.com/googleapis/gax-go/v2 v2.1.0/go.mod h1:Q3nei7sK6ybPYH7twZdmQpAd1MKb7pfu6SK+H1/DsU0= github.com/googleapis/gax-go/v2 v2.1.1/go.mod h1:hddJymUZASv3XPyGkUpKj8pPO47Rmb0eJc8R6ouapiM= @@ -593,8 +594,8 @@ github.com/ryanuber/columnize v2.1.0+incompatible/go.mod h1:sm1tb6uqfes/u+d4ooFo github.com/ryanuber/go-glob v1.0.0/go.mod h1:807d1WSdnB0XRJzKNil9Om6lcp/3a0v4qIHxIXzX/Yc= github.com/scaleway/scaleway-sdk-go v1.0.0-beta.20 h1:a9hSJdJcd16e0HoMsnFvaHvxB3pxSD+SC7+CISp7xY0= github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc= -github.com/shirou/gopsutil/v3 v3.23.9 h1:ZI5bWVeu2ep4/DIxB4U9okeYJ7zp/QLTO4auRb/ty/E= -github.com/shirou/gopsutil/v3 v3.23.9/go.mod h1:x/NWSb71eMcjFIO0vhyGW5nZ7oSIgVjrCnADckb85GA= +github.com/shirou/gopsutil/v3 v3.23.10 h1:/N42opWlYzegYaVkWejXWJpbzKv2JDy3mrgGzKsh9hM= +github.com/shirou/gopsutil/v3 v3.23.10/go.mod h1:JIE26kpucQi+innVlAUnIEOSBhBUkirr5b44yr55+WE= github.com/shoenig/go-m1cpu v0.1.6 h1:nxdKQNcEB6vzgA2E2bvzKIYRuNj7XNJ4S/aRSwKzFtM= github.com/shoenig/go-m1cpu v0.1.6/go.mod h1:1JJMcUBvfNwpq05QDQVAnx3gUHr9IYF7GNg9SUEw2VQ= github.com/shoenig/test v0.6.4 h1:kVTaSd7WLz5WZ2IaoM0RSzRsUD+m8wRR+5qvntpn4LU= @@ -805,7 +806,7 @@ golang.org/x/sync v0.0.0-20201207232520-09787c993a3a/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20220601150217-0de741cfad7f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20220929204114-8fcdb60fdcc0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.4.0 h1:zxkM55ReGkDlKSM+Fu41A+zmbZuaPVbGMzvvdUPznYQ= +golang.org/x/sync v0.5.0 h1:60k92dhOjHxJkrqnwsfl8KuaHbn/5dl0lUPUklKo3qE= golang.org/x/sys v0.0.0-20180823144017-11551d06cbcc/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= @@ -862,9 +863,9 @@ golang.org/x/sys v0.0.0-20220708085239-5a0f0661e09d/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20220728004956-3c1f35247d10/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.8.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.11.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.12.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.14.0 h1:Vz7Qs629MkJkGyHxUlRHizWJRG2j8fbQKjELVSNhy7Q= +golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= golang.org/x/term v0.13.0 h1:bb+I9cTfFazGW51MZqBVmZy7+JEJMouUHTUSKVQLBek= @@ -922,7 +923,7 @@ google.golang.org/api v0.96.0/go.mod h1:w7wJQLTM+wvQpNf5JyEcBoxK0RH7EDrh/L4qfsuJ google.golang.org/api v0.97.0/go.mod h1:w7wJQLTM+wvQpNf5JyEcBoxK0RH7EDrh/L4qfsuJ13s= google.golang.org/api v0.98.0/go.mod h1:w7wJQLTM+wvQpNf5JyEcBoxK0RH7EDrh/L4qfsuJ13s= google.golang.org/api v0.100.0/go.mod h1:ZE3Z2+ZOr87Rx7dqFsdRQkRBk36kDtp/h+QpHbB7a70= -google.golang.org/api v0.147.0 h1:Can3FaQo9LlVqxJCodNmeZW/ib3/qKAY3rFeXiHo5gc= +google.golang.org/api v0.150.0 h1:Z9k22qD289SZ8gCJrk4DrWXkNjtfvKAUo/l1ma8eBYE= google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= google.golang.org/appengine v1.6.6/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc= @@ -978,11 +979,11 @@ google.golang.org/genproto v0.0.0-20221010155953-15ba04fc1c0e/go.mod h1:3526vdqw google.golang.org/genproto v0.0.0-20221014173430-6e2ab493f96b/go.mod h1:1vXfmgAz9N9Jx0QA82PqRVauvCz1SGSz739p0f183jM= google.golang.org/genproto v0.0.0-20221014213838-99cd37c6964a/go.mod h1:1vXfmgAz9N9Jx0QA82PqRVauvCz1SGSz739p0f183jM= google.golang.org/genproto v0.0.0-20221024183307-1bc688fe9f3e/go.mod h1:9qHF0xnpdSfF6knlcsnpzUu5y+rpwgbvsyGAZPBMg4s= -google.golang.org/genproto v0.0.0-20231002182017-d307bd883b97 h1:SeZZZx0cP0fqUyA+oRzP9k7cSwJlvDFiROO72uwD6i0= -google.golang.org/genproto/googleapis/api v0.0.0-20231002182017-d307bd883b97 h1:W18sezcAYs+3tDZX4F80yctqa12jcP1PUS2gQu1zTPU= -google.golang.org/genproto/googleapis/api v0.0.0-20231002182017-d307bd883b97/go.mod h1:iargEX0SFPm3xcfMI0d1domjg0ZF4Aa0p2awqyxhvF0= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231009173412-8bfb1ae86b6c h1:jHkCUWkseRf+W+edG5hMzr/Uh1xkDREY4caybAq4dpY= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231009173412-8bfb1ae86b6c/go.mod h1:4cYg8o5yUbm77w8ZX00LhMVNl/YVBFJRYWDc0uYWMs0= +google.golang.org/genproto v0.0.0-20231016165738-49dd2c1f3d0b h1:+YaDE2r2OG8t/z5qmsh7Y+XXwCbvadxxZ0YY6mTdrVA= +google.golang.org/genproto/googleapis/api v0.0.0-20231016165738-49dd2c1f3d0b h1:CIC2YMXmIhYw6evmhPxBKJ4fmLbOFtXQN/GV3XOZR8k= +google.golang.org/genproto/googleapis/api v0.0.0-20231016165738-49dd2c1f3d0b/go.mod h1:IBQ646DjkDkvUIsVq/cc03FUFQ9wbZu7yE396YcL870= +google.golang.org/genproto/googleapis/rpc v0.0.0-20231030173426-d783a09b4405 h1:AB/lmRny7e2pLhFEYIbl5qkDAUt2h0ZRO4wGPhZf+ik= +google.golang.org/genproto/googleapis/rpc v0.0.0-20231030173426-d783a09b4405/go.mod h1:67X1fPuzjcrkymZzZV1vvkFeTn2Rvc6lYF9MYFGCcwE= google.golang.org/grpc v1.14.0/go.mod h1:yo6s7OP7yaDglbqo1J04qKzAhqBH6lvTonzMVmEdcZw= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.22.0/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg= diff --git a/exporter/azureblobexporter/go.mod b/exporter/azureblobexporter/go.mod index 6f00f45e5..43ff44703 100644 --- a/exporter/azureblobexporter/go.mod +++ b/exporter/azureblobexporter/go.mod @@ -41,7 +41,7 @@ require ( go.opentelemetry.io/otel/trace v1.19.0 // indirect go.uber.org/multierr v1.11.0 // indirect golang.org/x/net v0.17.0 // indirect - golang.org/x/sys v0.13.0 // indirect + golang.org/x/sys v0.14.0 // indirect golang.org/x/text v0.13.0 // indirect google.golang.org/genproto/googleapis/rpc v0.0.0-20230822172742-b8732ec3820d // indirect google.golang.org/grpc v1.59.0 // indirect diff --git a/exporter/azureblobexporter/go.sum b/exporter/azureblobexporter/go.sum index 53e079781..6a9e6363a 100644 --- a/exporter/azureblobexporter/go.sum +++ b/exporter/azureblobexporter/go.sum @@ -171,8 +171,8 @@ golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5h 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.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= -golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.14.0 h1:Vz7Qs629MkJkGyHxUlRHizWJRG2j8fbQKjELVSNhy7Q= +golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.13.0 h1:ablQoSUd0tRdKxZewP80B+BaqeKJuVhuRxj/dkrun3k= diff --git a/exporter/googlecloudexporter/go.mod b/exporter/googlecloudexporter/go.mod index 1300205db..f136299b0 100644 --- a/exporter/googlecloudexporter/go.mod +++ b/exporter/googlecloudexporter/go.mod @@ -13,14 +13,14 @@ require ( go.opentelemetry.io/collector/processor v0.88.0 go.opentelemetry.io/collector/processor/batchprocessor v0.88.0 go.uber.org/multierr v1.11.0 - google.golang.org/api v0.148.0 + google.golang.org/api v0.150.0 ) require ( - cloud.google.com/go/compute v1.23.0 // indirect + cloud.google.com/go/compute v1.23.1 // indirect cloud.google.com/go/logging v1.8.1 // indirect - cloud.google.com/go/monitoring v1.16.0 // indirect - cloud.google.com/go/trace v1.10.1 // indirect + cloud.google.com/go/monitoring v1.16.1 // indirect + cloud.google.com/go/trace v1.10.2 // indirect github.com/GoogleCloudPlatform/opentelemetry-operations-go/exporter/trace v1.20.0 // indirect github.com/cenkalti/backoff/v4 v4.2.1 // indirect github.com/davecgh/go-spew v1.1.1 // indirect @@ -47,10 +47,10 @@ require ( go.uber.org/zap v1.26.0 golang.org/x/net v0.17.0 // indirect golang.org/x/oauth2 v0.13.0 // indirect - golang.org/x/sync v0.4.0 // indirect + golang.org/x/sync v0.5.0 // indirect golang.org/x/text v0.13.0 // indirect google.golang.org/appengine v1.6.7 // indirect - google.golang.org/genproto v0.0.0-20231002182017-d307bd883b97 // indirect + google.golang.org/genproto v0.0.0-20231016165738-49dd2c1f3d0b // indirect google.golang.org/grpc v1.59.0 // indirect google.golang.org/protobuf v1.31.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect @@ -59,11 +59,11 @@ require ( require ( cloud.google.com/go v0.110.8 // indirect cloud.google.com/go/compute/metadata v0.2.3 // indirect - cloud.google.com/go/longrunning v0.5.1 // indirect + cloud.google.com/go/longrunning v0.5.2 // indirect github.com/GoogleCloudPlatform/opentelemetry-operations-go/internal/resourcemapping v0.44.0 // indirect github.com/fsnotify/fsnotify v1.6.0 // indirect github.com/google/s2a-go v0.1.7 // indirect - github.com/googleapis/enterprise-certificate-proxy v0.3.1 // indirect + github.com/googleapis/enterprise-certificate-proxy v0.3.2 // indirect github.com/knadh/koanf/v2 v2.0.1 // indirect github.com/mitchellh/mapstructure v1.5.1-0.20220423185008-bf980b35cac4 // indirect github.com/tidwall/gjson v1.10.2 // indirect @@ -78,7 +78,8 @@ require ( go.opentelemetry.io/collector/featuregate v1.0.0-rcv0017 // indirect go.opentelemetry.io/collector/semconv v0.88.0 // indirect golang.org/x/crypto v0.14.0 // indirect - golang.org/x/sys v0.13.0 // indirect - google.golang.org/genproto/googleapis/api v0.0.0-20231002182017-d307bd883b97 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231012201019-e917dd12ba7a // indirect + golang.org/x/sys v0.14.0 // indirect + golang.org/x/time v0.3.0 // indirect + google.golang.org/genproto/googleapis/api v0.0.0-20231016165738-49dd2c1f3d0b // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20231030173426-d783a09b4405 // indirect ) diff --git a/exporter/googlecloudexporter/go.sum b/exporter/googlecloudexporter/go.sum index 754658af1..55c25f80a 100644 --- a/exporter/googlecloudexporter/go.sum +++ b/exporter/googlecloudexporter/go.sum @@ -2,18 +2,18 @@ cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMT cloud.google.com/go v0.34.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= cloud.google.com/go v0.110.8 h1:tyNdfIxjzaWctIiLYOTalaLKZ17SI44SKFW26QbOhME= cloud.google.com/go v0.110.8/go.mod h1:Iz8AkXJf1qmxC3Oxoep8R1T36w8B92yU29PcBhHO5fk= -cloud.google.com/go/compute v1.23.0 h1:tP41Zoavr8ptEqaW6j+LQOnyBBhO7OkOMAGrgLopTwY= -cloud.google.com/go/compute v1.23.0/go.mod h1:4tCnrn48xsqlwSAiLf1HXMQk8CONslYbdiEZc9FEIbM= +cloud.google.com/go/compute v1.23.1 h1:V97tBoDaZHb6leicZ1G6DLK2BAaZLJ/7+9BB/En3hR0= +cloud.google.com/go/compute v1.23.1/go.mod h1:CqB3xpmPKKt3OJpW2ndFIXnA9A4xAy/F3Xp1ixncW78= cloud.google.com/go/compute/metadata v0.2.3 h1:mg4jlk7mCAj6xXp9UJ4fjI9VUI5rubuGBW5aJ7UnBMY= cloud.google.com/go/compute/metadata v0.2.3/go.mod h1:VAV5nSsACxMJvgaAuX6Pk2AawlZn8kiOGuCv6gTkwuA= cloud.google.com/go/logging v1.8.1 h1:26skQWPeYhvIasWKm48+Eq7oUqdcdbwsCVwz5Ys0FvU= cloud.google.com/go/logging v1.8.1/go.mod h1:TJjR+SimHwuC8MZ9cjByQulAMgni+RkXeI3wwctHJEI= -cloud.google.com/go/longrunning v0.5.1 h1:Fr7TXftcqTudoyRJa113hyaqlGdiBQkp0Gq7tErFDWI= -cloud.google.com/go/longrunning v0.5.1/go.mod h1:spvimkwdz6SPWKEt/XBij79E9fiTkHSQl/fRUUQJYJc= -cloud.google.com/go/monitoring v1.16.0 h1:rlndy4K8yknMY9JuGe2aK4SbCh21FXoCdX7SAGHmRgI= -cloud.google.com/go/monitoring v1.16.0/go.mod h1:Ptp15HgAyM1fNICAojDMoNc/wUmn67mLHQfyqbw+poY= -cloud.google.com/go/trace v1.10.1 h1:EwGdOLCNfYOOPtgqo+D2sDLZmRCEO1AagRTJCU6ztdg= -cloud.google.com/go/trace v1.10.1/go.mod h1:gbtL94KE5AJLH3y+WVpfWILmqgc6dXcqgNXdOPAQTYk= +cloud.google.com/go/longrunning v0.5.2 h1:u+oFqfEwwU7F9dIELigxbe0XVnBAo9wqMuQLA50CZ5k= +cloud.google.com/go/longrunning v0.5.2/go.mod h1:nqo6DQbNV2pXhGDbDMoN2bWz68MjZUzqv2YttZiveCs= +cloud.google.com/go/monitoring v1.16.1 h1:CTklIuUkS5nCricGojPwdkSgPsCTX2HmYTxFDg+UvpU= +cloud.google.com/go/monitoring v1.16.1/go.mod h1:6HsxddR+3y9j+o/cMJH6q/KJ/CBTvM/38L/1m7bTRJ4= +cloud.google.com/go/trace v1.10.2 h1:80Rh4JSqJLfe/xGNrpyO4MQxiFDXcHG1XrsevfmrIRQ= +cloud.google.com/go/trace v1.10.2/go.mod h1:NPXemMi6MToRFcSxRl2uDnu/qAlAQ3oULUphcHGh1vA= contrib.go.opencensus.io/exporter/prometheus v0.4.2 h1:sqfsYl5GIY/L570iT+l93ehxaWJs2/OwXtiWwew3oAg= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/GoogleCloudPlatform/opentelemetry-operations-go/exporter/collector v0.44.0 h1:4UERCh56sgYXn6XzH5+qsft5fnus2b/RzcTk+6Ue7Vo= @@ -132,9 +132,9 @@ github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/ github.com/google/s2a-go v0.1.7 h1:60BLSyTrOV4/haCDW4zb1guZItoSq8foHCXrAnjBo/o= github.com/google/s2a-go v0.1.7/go.mod h1:50CgR4k1jNlWBu4UfS4AcfhVe1r6pdZPygJ3R8F0Qdw= github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/google/uuid v1.3.1 h1:KjJaJ9iWZ3jOFZIf1Lqf4laDRCasjl0BCmnEGxkdLb4= -github.com/googleapis/enterprise-certificate-proxy v0.3.1 h1:SBWmZhjUDRorQxrN0nwzf+AHBxnbFjViHQS4P0yVpmQ= -github.com/googleapis/enterprise-certificate-proxy v0.3.1/go.mod h1:VLSiSSBs/ksPL8kq3OBOQ6WRI2QnaFynd1DCjZ62+V0= +github.com/google/uuid v1.4.0 h1:MtMxsa51/r9yyhkyLsVeVt0B+BGQZzpQiTQ4eHZ8bc4= +github.com/googleapis/enterprise-certificate-proxy v0.3.2 h1:Vie5ybvEvT75RniqhfFxPRy3Bf7vr3h0cechB90XaQs= +github.com/googleapis/enterprise-certificate-proxy v0.3.2/go.mod h1:VLSiSSBs/ksPL8kq3OBOQ6WRI2QnaFynd1DCjZ62+V0= github.com/googleapis/gax-go/v2 v2.12.0 h1:A+gCJKdRfqXkr+BIRGtZLibNXf0m1f9E4HG56etFpas= github.com/googleapis/gax-go/v2 v2.12.0/go.mod h1:y+aIqrI5eb1YGMVJfuV3185Ts/D7qKpsEkdD5+I6QGU= github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= @@ -411,8 +411,8 @@ golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201207232520-09787c993a3a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.4.0 h1:zxkM55ReGkDlKSM+Fu41A+zmbZuaPVbGMzvvdUPznYQ= -golang.org/x/sync v0.4.0/go.mod h1:FU7BRWz2tNW+3quACPkgCx/L+uEAv1htQ0V83Z9Rj+Y= +golang.org/x/sync v0.5.0 h1:60k92dhOjHxJkrqnwsfl8KuaHbn/5dl0lUPUklKo3qE= +golang.org/x/sync v0.5.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= golang.org/x/sys v0.0.0-20180823144017-11551d06cbcc/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= @@ -444,8 +444,8 @@ golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210603081109-ebe580a85c40/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220908164124-27713097b956/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= -golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.14.0 h1:Vz7Qs629MkJkGyHxUlRHizWJRG2j8fbQKjELVSNhy7Q= +golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20181227161524-e6919f6577db/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= @@ -456,6 +456,8 @@ golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.13.0 h1:ablQoSUd0tRdKxZewP80B+BaqeKJuVhuRxj/dkrun3k= golang.org/x/text v0.13.0/go.mod h1:TvPlkZtksWOMsz7fbANvkp4WM8x/WCo/om8BMLbz+aE= golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= +golang.org/x/time v0.3.0 h1:rg5rLMjNzMS1RkNLzCG38eapWhnYLFYXDXj2gOlr8j4= +golang.org/x/time v0.3.0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY= @@ -471,8 +473,8 @@ golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8T golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -google.golang.org/api v0.148.0 h1:HBq4TZlN4/1pNcu0geJZ/Q50vIwIXT532UIMYoo0vOs= -google.golang.org/api v0.148.0/go.mod h1:8/TBgwaKjfqTdacOJrOv2+2Q6fBDU1uHKK06oGSkxzU= +google.golang.org/api v0.150.0 h1:Z9k22qD289SZ8gCJrk4DrWXkNjtfvKAUo/l1ma8eBYE= +google.golang.org/api v0.150.0/go.mod h1:ccy+MJ6nrYFgE3WgRx/AMXOxOmU8Q4hSa+jjibzhxcg= google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= google.golang.org/appengine v1.6.7 h1:FZR1q0exgwxzPzp/aF+VccGrSfxfPpkBqjIIEq3ru6c= @@ -483,12 +485,12 @@ google.golang.org/genproto v0.0.0-20190819201941-24fa4b261c55/go.mod h1:DMBHOl98 google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= google.golang.org/genproto v0.0.0-20210602131652-f16073e35f0c/go.mod h1:UODoCrxHCcBojKKwX1terBiRUaqAsFqJiF615XL43r0= -google.golang.org/genproto v0.0.0-20231002182017-d307bd883b97 h1:SeZZZx0cP0fqUyA+oRzP9k7cSwJlvDFiROO72uwD6i0= -google.golang.org/genproto v0.0.0-20231002182017-d307bd883b97/go.mod h1:t1VqOqqvce95G3hIDCT5FeO3YUc6Q4Oe24L/+rNMxRk= -google.golang.org/genproto/googleapis/api v0.0.0-20231002182017-d307bd883b97 h1:W18sezcAYs+3tDZX4F80yctqa12jcP1PUS2gQu1zTPU= -google.golang.org/genproto/googleapis/api v0.0.0-20231002182017-d307bd883b97/go.mod h1:iargEX0SFPm3xcfMI0d1domjg0ZF4Aa0p2awqyxhvF0= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231012201019-e917dd12ba7a h1:a2MQQVoTo96JC9PMGtGBymLp7+/RzpFc2yX/9WfFg1c= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231012201019-e917dd12ba7a/go.mod h1:4cYg8o5yUbm77w8ZX00LhMVNl/YVBFJRYWDc0uYWMs0= +google.golang.org/genproto v0.0.0-20231016165738-49dd2c1f3d0b h1:+YaDE2r2OG8t/z5qmsh7Y+XXwCbvadxxZ0YY6mTdrVA= +google.golang.org/genproto v0.0.0-20231016165738-49dd2c1f3d0b/go.mod h1:CgAqfJo+Xmu0GwA0411Ht3OU3OntXwsGmrmjI8ioGXI= +google.golang.org/genproto/googleapis/api v0.0.0-20231016165738-49dd2c1f3d0b h1:CIC2YMXmIhYw6evmhPxBKJ4fmLbOFtXQN/GV3XOZR8k= +google.golang.org/genproto/googleapis/api v0.0.0-20231016165738-49dd2c1f3d0b/go.mod h1:IBQ646DjkDkvUIsVq/cc03FUFQ9wbZu7yE396YcL870= +google.golang.org/genproto/googleapis/rpc v0.0.0-20231030173426-d783a09b4405 h1:AB/lmRny7e2pLhFEYIbl5qkDAUt2h0ZRO4wGPhZf+ik= +google.golang.org/genproto/googleapis/rpc v0.0.0-20231030173426-d783a09b4405/go.mod h1:67X1fPuzjcrkymZzZV1vvkFeTn2Rvc6lYF9MYFGCcwE= google.golang.org/grpc v1.14.0/go.mod h1:yo6s7OP7yaDglbqo1J04qKzAhqBH6lvTonzMVmEdcZw= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.22.0/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg= diff --git a/exporter/googlemanagedprometheusexporter/go.mod b/exporter/googlemanagedprometheusexporter/go.mod index 41892448d..2d54c4e8e 100644 --- a/exporter/googlemanagedprometheusexporter/go.mod +++ b/exporter/googlemanagedprometheusexporter/go.mod @@ -10,17 +10,17 @@ require ( go.opentelemetry.io/collector/exporter v0.88.0 go.opentelemetry.io/collector/pdata v1.0.0-rcv0017 go.uber.org/zap v1.26.0 - google.golang.org/api v0.147.0 + google.golang.org/api v0.150.0 ) require ( cloud.google.com/go v0.110.8 // indirect - cloud.google.com/go/compute v1.23.0 // indirect + cloud.google.com/go/compute v1.23.1 // indirect cloud.google.com/go/compute/metadata v0.2.3 // indirect cloud.google.com/go/logging v1.8.1 // indirect - cloud.google.com/go/longrunning v0.5.1 // indirect - cloud.google.com/go/monitoring v1.16.0 // indirect - cloud.google.com/go/trace v1.10.1 // indirect + cloud.google.com/go/longrunning v0.5.2 // indirect + cloud.google.com/go/monitoring v1.16.1 // indirect + cloud.google.com/go/trace v1.10.2 // indirect github.com/GoogleCloudPlatform/opentelemetry-operations-go/exporter/collector v0.44.0 // indirect github.com/GoogleCloudPlatform/opentelemetry-operations-go/exporter/collector/googlemanagedprometheus v0.44.0 // indirect github.com/GoogleCloudPlatform/opentelemetry-operations-go/exporter/trace v1.20.0 // indirect @@ -34,7 +34,7 @@ require ( github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect github.com/golang/protobuf v1.5.3 // indirect github.com/google/s2a-go v0.1.7 // indirect - github.com/googleapis/enterprise-certificate-proxy v0.3.1 // indirect + github.com/googleapis/enterprise-certificate-proxy v0.3.2 // indirect github.com/googleapis/gax-go/v2 v2.12.0 // indirect github.com/json-iterator/go v1.1.12 // indirect github.com/knadh/koanf v1.5.0 // indirect @@ -68,13 +68,14 @@ require ( golang.org/x/crypto v0.14.0 // indirect golang.org/x/net v0.17.0 // indirect golang.org/x/oauth2 v0.13.0 // indirect - golang.org/x/sync v0.4.0 // indirect - golang.org/x/sys v0.13.0 // indirect + golang.org/x/sync v0.5.0 // indirect + golang.org/x/sys v0.14.0 // indirect golang.org/x/text v0.13.0 // indirect + golang.org/x/time v0.3.0 // indirect google.golang.org/appengine v1.6.7 // indirect - google.golang.org/genproto v0.0.0-20231002182017-d307bd883b97 // indirect - google.golang.org/genproto/googleapis/api v0.0.0-20231002182017-d307bd883b97 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231009173412-8bfb1ae86b6c // indirect + google.golang.org/genproto v0.0.0-20231016165738-49dd2c1f3d0b // indirect + google.golang.org/genproto/googleapis/api v0.0.0-20231016165738-49dd2c1f3d0b // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20231030173426-d783a09b4405 // indirect google.golang.org/grpc v1.59.0 // indirect google.golang.org/protobuf v1.31.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect diff --git a/exporter/googlemanagedprometheusexporter/go.sum b/exporter/googlemanagedprometheusexporter/go.sum index bd9fff8ae..1fa328969 100644 --- a/exporter/googlemanagedprometheusexporter/go.sum +++ b/exporter/googlemanagedprometheusexporter/go.sum @@ -2,18 +2,18 @@ cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMT cloud.google.com/go v0.34.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= cloud.google.com/go v0.110.8 h1:tyNdfIxjzaWctIiLYOTalaLKZ17SI44SKFW26QbOhME= cloud.google.com/go v0.110.8/go.mod h1:Iz8AkXJf1qmxC3Oxoep8R1T36w8B92yU29PcBhHO5fk= -cloud.google.com/go/compute v1.23.0 h1:tP41Zoavr8ptEqaW6j+LQOnyBBhO7OkOMAGrgLopTwY= -cloud.google.com/go/compute v1.23.0/go.mod h1:4tCnrn48xsqlwSAiLf1HXMQk8CONslYbdiEZc9FEIbM= +cloud.google.com/go/compute v1.23.1 h1:V97tBoDaZHb6leicZ1G6DLK2BAaZLJ/7+9BB/En3hR0= +cloud.google.com/go/compute v1.23.1/go.mod h1:CqB3xpmPKKt3OJpW2ndFIXnA9A4xAy/F3Xp1ixncW78= cloud.google.com/go/compute/metadata v0.2.3 h1:mg4jlk7mCAj6xXp9UJ4fjI9VUI5rubuGBW5aJ7UnBMY= cloud.google.com/go/compute/metadata v0.2.3/go.mod h1:VAV5nSsACxMJvgaAuX6Pk2AawlZn8kiOGuCv6gTkwuA= cloud.google.com/go/logging v1.8.1 h1:26skQWPeYhvIasWKm48+Eq7oUqdcdbwsCVwz5Ys0FvU= cloud.google.com/go/logging v1.8.1/go.mod h1:TJjR+SimHwuC8MZ9cjByQulAMgni+RkXeI3wwctHJEI= -cloud.google.com/go/longrunning v0.5.1 h1:Fr7TXftcqTudoyRJa113hyaqlGdiBQkp0Gq7tErFDWI= -cloud.google.com/go/longrunning v0.5.1/go.mod h1:spvimkwdz6SPWKEt/XBij79E9fiTkHSQl/fRUUQJYJc= -cloud.google.com/go/monitoring v1.16.0 h1:rlndy4K8yknMY9JuGe2aK4SbCh21FXoCdX7SAGHmRgI= -cloud.google.com/go/monitoring v1.16.0/go.mod h1:Ptp15HgAyM1fNICAojDMoNc/wUmn67mLHQfyqbw+poY= -cloud.google.com/go/trace v1.10.1 h1:EwGdOLCNfYOOPtgqo+D2sDLZmRCEO1AagRTJCU6ztdg= -cloud.google.com/go/trace v1.10.1/go.mod h1:gbtL94KE5AJLH3y+WVpfWILmqgc6dXcqgNXdOPAQTYk= +cloud.google.com/go/longrunning v0.5.2 h1:u+oFqfEwwU7F9dIELigxbe0XVnBAo9wqMuQLA50CZ5k= +cloud.google.com/go/longrunning v0.5.2/go.mod h1:nqo6DQbNV2pXhGDbDMoN2bWz68MjZUzqv2YttZiveCs= +cloud.google.com/go/monitoring v1.16.1 h1:CTklIuUkS5nCricGojPwdkSgPsCTX2HmYTxFDg+UvpU= +cloud.google.com/go/monitoring v1.16.1/go.mod h1:6HsxddR+3y9j+o/cMJH6q/KJ/CBTvM/38L/1m7bTRJ4= +cloud.google.com/go/trace v1.10.2 h1:80Rh4JSqJLfe/xGNrpyO4MQxiFDXcHG1XrsevfmrIRQ= +cloud.google.com/go/trace v1.10.2/go.mod h1:NPXemMi6MToRFcSxRl2uDnu/qAlAQ3oULUphcHGh1vA= contrib.go.opencensus.io/exporter/prometheus v0.4.2 h1:sqfsYl5GIY/L570iT+l93ehxaWJs2/OwXtiWwew3oAg= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/GoogleCloudPlatform/opentelemetry-operations-go/exporter/collector v0.44.0 h1:4UERCh56sgYXn6XzH5+qsft5fnus2b/RzcTk+6Ue7Vo= @@ -135,9 +135,9 @@ github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/ github.com/google/s2a-go v0.1.7 h1:60BLSyTrOV4/haCDW4zb1guZItoSq8foHCXrAnjBo/o= github.com/google/s2a-go v0.1.7/go.mod h1:50CgR4k1jNlWBu4UfS4AcfhVe1r6pdZPygJ3R8F0Qdw= github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/google/uuid v1.3.1 h1:KjJaJ9iWZ3jOFZIf1Lqf4laDRCasjl0BCmnEGxkdLb4= -github.com/googleapis/enterprise-certificate-proxy v0.3.1 h1:SBWmZhjUDRorQxrN0nwzf+AHBxnbFjViHQS4P0yVpmQ= -github.com/googleapis/enterprise-certificate-proxy v0.3.1/go.mod h1:VLSiSSBs/ksPL8kq3OBOQ6WRI2QnaFynd1DCjZ62+V0= +github.com/google/uuid v1.4.0 h1:MtMxsa51/r9yyhkyLsVeVt0B+BGQZzpQiTQ4eHZ8bc4= +github.com/googleapis/enterprise-certificate-proxy v0.3.2 h1:Vie5ybvEvT75RniqhfFxPRy3Bf7vr3h0cechB90XaQs= +github.com/googleapis/enterprise-certificate-proxy v0.3.2/go.mod h1:VLSiSSBs/ksPL8kq3OBOQ6WRI2QnaFynd1DCjZ62+V0= github.com/googleapis/gax-go/v2 v2.12.0 h1:A+gCJKdRfqXkr+BIRGtZLibNXf0m1f9E4HG56etFpas= github.com/googleapis/gax-go/v2 v2.12.0/go.mod h1:y+aIqrI5eb1YGMVJfuV3185Ts/D7qKpsEkdD5+I6QGU= github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= @@ -441,8 +441,8 @@ golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201207232520-09787c993a3a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.4.0 h1:zxkM55ReGkDlKSM+Fu41A+zmbZuaPVbGMzvvdUPznYQ= -golang.org/x/sync v0.4.0/go.mod h1:FU7BRWz2tNW+3quACPkgCx/L+uEAv1htQ0V83Z9Rj+Y= +golang.org/x/sync v0.5.0 h1:60k92dhOjHxJkrqnwsfl8KuaHbn/5dl0lUPUklKo3qE= +golang.org/x/sync v0.5.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= golang.org/x/sys v0.0.0-20180823144017-11551d06cbcc/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= @@ -474,8 +474,8 @@ golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210603081109-ebe580a85c40/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220908164124-27713097b956/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= -golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.14.0 h1:Vz7Qs629MkJkGyHxUlRHizWJRG2j8fbQKjELVSNhy7Q= +golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20181227161524-e6919f6577db/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= @@ -486,6 +486,8 @@ golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.13.0 h1:ablQoSUd0tRdKxZewP80B+BaqeKJuVhuRxj/dkrun3k= golang.org/x/text v0.13.0/go.mod h1:TvPlkZtksWOMsz7fbANvkp4WM8x/WCo/om8BMLbz+aE= golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= +golang.org/x/time v0.3.0 h1:rg5rLMjNzMS1RkNLzCG38eapWhnYLFYXDXj2gOlr8j4= +golang.org/x/time v0.3.0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY= @@ -502,8 +504,8 @@ golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8T golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= gonum.org/v1/gonum v0.14.0 h1:2NiG67LD1tEH0D7kM+ps2V+fXmsAnpUeec7n8tcr4S0= -google.golang.org/api v0.147.0 h1:Can3FaQo9LlVqxJCodNmeZW/ib3/qKAY3rFeXiHo5gc= -google.golang.org/api v0.147.0/go.mod h1:pQ/9j83DcmPd/5C9e2nFOdjjNkDZ1G+zkbK2uvdkJMs= +google.golang.org/api v0.150.0 h1:Z9k22qD289SZ8gCJrk4DrWXkNjtfvKAUo/l1ma8eBYE= +google.golang.org/api v0.150.0/go.mod h1:ccy+MJ6nrYFgE3WgRx/AMXOxOmU8Q4hSa+jjibzhxcg= google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= google.golang.org/appengine v1.6.7 h1:FZR1q0exgwxzPzp/aF+VccGrSfxfPpkBqjIIEq3ru6c= @@ -514,12 +516,12 @@ google.golang.org/genproto v0.0.0-20190819201941-24fa4b261c55/go.mod h1:DMBHOl98 google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= google.golang.org/genproto v0.0.0-20210602131652-f16073e35f0c/go.mod h1:UODoCrxHCcBojKKwX1terBiRUaqAsFqJiF615XL43r0= -google.golang.org/genproto v0.0.0-20231002182017-d307bd883b97 h1:SeZZZx0cP0fqUyA+oRzP9k7cSwJlvDFiROO72uwD6i0= -google.golang.org/genproto v0.0.0-20231002182017-d307bd883b97/go.mod h1:t1VqOqqvce95G3hIDCT5FeO3YUc6Q4Oe24L/+rNMxRk= -google.golang.org/genproto/googleapis/api v0.0.0-20231002182017-d307bd883b97 h1:W18sezcAYs+3tDZX4F80yctqa12jcP1PUS2gQu1zTPU= -google.golang.org/genproto/googleapis/api v0.0.0-20231002182017-d307bd883b97/go.mod h1:iargEX0SFPm3xcfMI0d1domjg0ZF4Aa0p2awqyxhvF0= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231009173412-8bfb1ae86b6c h1:jHkCUWkseRf+W+edG5hMzr/Uh1xkDREY4caybAq4dpY= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231009173412-8bfb1ae86b6c/go.mod h1:4cYg8o5yUbm77w8ZX00LhMVNl/YVBFJRYWDc0uYWMs0= +google.golang.org/genproto v0.0.0-20231016165738-49dd2c1f3d0b h1:+YaDE2r2OG8t/z5qmsh7Y+XXwCbvadxxZ0YY6mTdrVA= +google.golang.org/genproto v0.0.0-20231016165738-49dd2c1f3d0b/go.mod h1:CgAqfJo+Xmu0GwA0411Ht3OU3OntXwsGmrmjI8ioGXI= +google.golang.org/genproto/googleapis/api v0.0.0-20231016165738-49dd2c1f3d0b h1:CIC2YMXmIhYw6evmhPxBKJ4fmLbOFtXQN/GV3XOZR8k= +google.golang.org/genproto/googleapis/api v0.0.0-20231016165738-49dd2c1f3d0b/go.mod h1:IBQ646DjkDkvUIsVq/cc03FUFQ9wbZu7yE396YcL870= +google.golang.org/genproto/googleapis/rpc v0.0.0-20231030173426-d783a09b4405 h1:AB/lmRny7e2pLhFEYIbl5qkDAUt2h0ZRO4wGPhZf+ik= +google.golang.org/genproto/googleapis/rpc v0.0.0-20231030173426-d783a09b4405/go.mod h1:67X1fPuzjcrkymZzZV1vvkFeTn2Rvc6lYF9MYFGCcwE= google.golang.org/grpc v1.14.0/go.mod h1:yo6s7OP7yaDglbqo1J04qKzAhqBH6lvTonzMVmEdcZw= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.22.0/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg= diff --git a/expr/go.mod b/expr/go.mod index 51c9379cb..bf356d48a 100644 --- a/expr/go.mod +++ b/expr/go.mod @@ -13,7 +13,7 @@ require ( github.com/alecthomas/participle/v2 v2.1.0 // indirect github.com/davecgh/go-spew v1.1.1 // indirect github.com/gobwas/glob v0.2.3 // indirect - github.com/google/uuid v1.3.1 // indirect + github.com/google/uuid v1.4.0 // indirect github.com/iancoleman/strcase v0.3.0 // indirect github.com/knadh/koanf v1.5.0 // indirect github.com/knadh/koanf/v2 v2.0.1 // indirect @@ -43,7 +43,7 @@ require ( github.com/modern-go/reflect2 v1.0.2 // indirect go.uber.org/multierr v1.11.0 // indirect golang.org/x/net v0.17.0 // indirect - golang.org/x/sys v0.13.0 // indirect; indirectgopkg.in/natefinch/lumberjack.v2 + golang.org/x/sys v0.14.0 // indirect; indirectgopkg.in/natefinch/lumberjack.v2 golang.org/x/text v0.13.0 // indirect google.golang.org/grpc v1.59.0 // indirect google.golang.org/protobuf v1.31.0 // indirect diff --git a/expr/go.sum b/expr/go.sum index bf74c1602..85f8d4c26 100644 --- a/expr/go.sum +++ b/expr/go.sum @@ -101,8 +101,8 @@ github.com/google/go-cmp v0.5.7/go.mod h1:n+brtR0CgQNWTVd5ZUFpTBC8YFBDLK/h/bpaJ8 github.com/google/go-cmp v0.5.9 h1:O2Tfq5qg4qc4AmwVlvv0oLiVAGB7enBSJ2x2DqQFi38= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/google/uuid v1.3.1 h1:KjJaJ9iWZ3jOFZIf1Lqf4laDRCasjl0BCmnEGxkdLb4= -github.com/google/uuid v1.3.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= +github.com/google/uuid v1.4.0 h1:MtMxsa51/r9yyhkyLsVeVt0B+BGQZzpQiTQ4eHZ8bc4= +github.com/google/uuid v1.4.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw= github.com/hashicorp/consul/api v1.13.0/go.mod h1:ZlVrynguJKcYr54zGaDbaL3fOvKC9m72FhPvA8T35KQ= @@ -364,8 +364,8 @@ golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210603081109-ebe580a85c40/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= -golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.14.0 h1:Vz7Qs629MkJkGyHxUlRHizWJRG2j8fbQKjELVSNhy7Q= +golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20181227161524-e6919f6577db/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= diff --git a/go.mod b/go.mod index 7b602c0f7..4b93fcb18 100644 --- a/go.mod +++ b/go.mod @@ -3,7 +3,7 @@ module github.com/observiq/bindplane-agent go 1.20 require ( - github.com/google/uuid v1.3.1 + github.com/google/uuid v1.4.0 github.com/mholt/archiver/v3 v3.5.1 github.com/observiq/bindplane-agent/exporter/azureblobexporter v1.39.0 github.com/observiq/bindplane-agent/exporter/googlecloudexporter v1.39.0 @@ -148,7 +148,7 @@ require ( github.com/open-telemetry/opentelemetry-collector-contrib/receiver/windowsperfcountersreceiver v0.88.0 github.com/open-telemetry/opentelemetry-collector-contrib/receiver/zipkinreceiver v0.88.0 github.com/open-telemetry/opentelemetry-collector-contrib/receiver/zookeeperreceiver v0.88.0 - github.com/shirou/gopsutil/v3 v3.23.9 + github.com/shirou/gopsutil/v3 v3.23.10 github.com/spf13/pflag v1.0.5 github.com/stretchr/testify v1.8.4 go.opencensus.io v0.24.0 @@ -381,7 +381,7 @@ require ( github.com/devigned/tab v0.1.1 // indirect github.com/digitalocean/godo v1.99.0 // indirect github.com/docker/distribution v2.8.2+incompatible // indirect - github.com/docker/docker v24.0.6+incompatible // indirect + github.com/docker/docker v24.0.7+incompatible // indirect github.com/docker/go-connections v0.4.1-0.20210727194412-58542c764a11 // indirect github.com/docker/go-units v0.5.0 // indirect github.com/dsnet/compress v0.0.2-0.20210315054119-f66993602bf5 // indirect @@ -428,7 +428,7 @@ require ( github.com/google/go-cmp v0.6.0 // indirect github.com/google/go-querystring v1.1.0 // indirect github.com/google/gofuzz v1.2.0 // indirect - github.com/googleapis/enterprise-certificate-proxy v0.3.1 // indirect + github.com/googleapis/enterprise-certificate-proxy v0.3.2 // indirect github.com/googleapis/gax-go/v2 v2.12.0 // indirect github.com/gophercloud/gophercloud v1.5.0 // indirect github.com/gorilla/mux v1.8.0 // indirect @@ -614,14 +614,14 @@ require ( golang.org/x/mod v0.13.0 // indirect golang.org/x/net v0.17.0 // indirect golang.org/x/oauth2 v0.13.0 // indirect - golang.org/x/sync v0.4.0 // indirect + golang.org/x/sync v0.5.0 // indirect golang.org/x/term v0.13.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/time v0.3.0 // indirect golang.org/x/tools v0.14.0 // indirect golang.org/x/xerrors v0.0.0-20220907171357-04be3eba64a2 // indirect gonum.org/v1/gonum v0.14.0 // indirect - google.golang.org/api v0.148.0 // indirect + google.golang.org/api v0.150.0 // indirect google.golang.org/appengine v1.6.7 // indirect google.golang.org/genproto v0.0.0-20231030173426-d783a09b4405 // indirect google.golang.org/grpc v1.59.0 // indirect diff --git a/go.sum b/go.sum index f7565f090..89147bf21 100644 --- a/go.sum +++ b/go.sum @@ -462,8 +462,8 @@ github.com/docker/distribution v2.8.1+incompatible/go.mod h1:J2gT2udsDAN96Uj4Kfc github.com/docker/distribution v2.8.2+incompatible h1:T3de5rq0dB1j30rp0sA2rER+m322EBzniBPB6ZIzuh8= github.com/docker/distribution v2.8.2+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w= github.com/docker/docker v20.10.21+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= -github.com/docker/docker v24.0.6+incompatible h1:hceabKCtUgDqPu+qm0NgsaXf28Ljf4/pWFL7xjWWDgE= -github.com/docker/docker v24.0.6+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= +github.com/docker/docker v24.0.7+incompatible h1:Wo6l37AuwP3JaMnZa226lzVXGA3F9Ig1seQen0cKYlM= +github.com/docker/docker v24.0.7+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= github.com/docker/go-connections v0.4.0/go.mod h1:Gbd7IOopHjR8Iph03tsViu4nIes5XhDvyHbTtUxmeec= github.com/docker/go-connections v0.4.1-0.20210727194412-58542c764a11 h1:IPrmumsT9t5BS7XcPhgsCTlkWbYg80SEXUzDpReaU6Y= github.com/docker/go-connections v0.4.1-0.20210727194412-58542c764a11/go.mod h1:a6bNUGTbQBsY6VRHTr4h/rkOXjl244DyRD0tx3fgq4Q= @@ -739,10 +739,10 @@ github.com/google/s2a-go v0.1.7/go.mod h1:50CgR4k1jNlWBu4UfS4AcfhVe1r6pdZPygJ3R8 github.com/google/uuid v1.0.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/google/uuid v1.1.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/google/uuid v1.3.1 h1:KjJaJ9iWZ3jOFZIf1Lqf4laDRCasjl0BCmnEGxkdLb4= -github.com/google/uuid v1.3.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/googleapis/enterprise-certificate-proxy v0.3.1 h1:SBWmZhjUDRorQxrN0nwzf+AHBxnbFjViHQS4P0yVpmQ= -github.com/googleapis/enterprise-certificate-proxy v0.3.1/go.mod h1:VLSiSSBs/ksPL8kq3OBOQ6WRI2QnaFynd1DCjZ62+V0= +github.com/google/uuid v1.4.0 h1:MtMxsa51/r9yyhkyLsVeVt0B+BGQZzpQiTQ4eHZ8bc4= +github.com/google/uuid v1.4.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= +github.com/googleapis/enterprise-certificate-proxy v0.3.2 h1:Vie5ybvEvT75RniqhfFxPRy3Bf7vr3h0cechB90XaQs= +github.com/googleapis/enterprise-certificate-proxy v0.3.2/go.mod h1:VLSiSSBs/ksPL8kq3OBOQ6WRI2QnaFynd1DCjZ62+V0= github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg= github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk= github.com/googleapis/gax-go/v2 v2.1.0/go.mod h1:Q3nei7sK6ybPYH7twZdmQpAd1MKb7pfu6SK+H1/DsU0= @@ -1624,8 +1624,8 @@ github.com/secure-systems-lab/go-securesystemslib v0.7.0/go.mod h1:/2gYnlnHVQ6xe github.com/segmentio/asm v1.2.0 h1:9BQrFxC+YOHJlTlHGkTrFWf59nbL3XnCoFLTwDCI7ys= github.com/segmentio/asm v1.2.0/go.mod h1:BqMnlJP91P8d+4ibuonYZw9mfnzI9HfxselHZr5aAcs= github.com/shirou/gopsutil/v3 v3.22.2/go.mod h1:WapW1AOOPlHyXr+yOyw3uYx36enocrtSoSBy0L5vUHY= -github.com/shirou/gopsutil/v3 v3.23.9 h1:ZI5bWVeu2ep4/DIxB4U9okeYJ7zp/QLTO4auRb/ty/E= -github.com/shirou/gopsutil/v3 v3.23.9/go.mod h1:x/NWSb71eMcjFIO0vhyGW5nZ7oSIgVjrCnADckb85GA= +github.com/shirou/gopsutil/v3 v3.23.10 h1:/N42opWlYzegYaVkWejXWJpbzKv2JDy3mrgGzKsh9hM= +github.com/shirou/gopsutil/v3 v3.23.10/go.mod h1:JIE26kpucQi+innVlAUnIEOSBhBUkirr5b44yr55+WE= github.com/shoenig/go-m1cpu v0.1.6 h1:nxdKQNcEB6vzgA2E2bvzKIYRuNj7XNJ4S/aRSwKzFtM= github.com/shoenig/go-m1cpu v0.1.6/go.mod h1:1JJMcUBvfNwpq05QDQVAnx3gUHr9IYF7GNg9SUEw2VQ= github.com/shoenig/test v0.6.4/go.mod h1:byHiCGXqrVaflBLAMq/srcZIHynQPQgeyvkvXnjqq0k= @@ -2087,8 +2087,8 @@ golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20220601150217-0de741cfad7f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.1.0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.4.0 h1:zxkM55ReGkDlKSM+Fu41A+zmbZuaPVbGMzvvdUPznYQ= -golang.org/x/sync v0.4.0/go.mod h1:FU7BRWz2tNW+3quACPkgCx/L+uEAv1htQ0V83Z9Rj+Y= +golang.org/x/sync v0.5.0 h1:60k92dhOjHxJkrqnwsfl8KuaHbn/5dl0lUPUklKo3qE= +golang.org/x/sync v0.5.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= golang.org/x/sys v0.0.0-20180823144017-11551d06cbcc/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= @@ -2202,7 +2202,7 @@ golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.8.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.11.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.12.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.14.0 h1:Vz7Qs629MkJkGyHxUlRHizWJRG2j8fbQKjELVSNhy7Q= golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw= @@ -2345,8 +2345,8 @@ google.golang.org/api v0.51.0/go.mod h1:t4HdrdoNgyN5cbEfm7Lum0lcLDLiise1F8qDKX00 google.golang.org/api v0.54.0/go.mod h1:7C4bFFOvVDGXjfDTAsgGwDgAxRDeQ4X8NvUedIt6z3k= google.golang.org/api v0.55.0/go.mod h1:38yMfeP1kfjsl8isn0tliTjIb1rJXcQi4UXlbqivdVE= google.golang.org/api v0.57.0/go.mod h1:dVPlbZyBo2/OjBpmvNdpn2GRm6rPy75jyU7bmhdrMgI= -google.golang.org/api v0.148.0 h1:HBq4TZlN4/1pNcu0geJZ/Q50vIwIXT532UIMYoo0vOs= -google.golang.org/api v0.148.0/go.mod h1:8/TBgwaKjfqTdacOJrOv2+2Q6fBDU1uHKK06oGSkxzU= +google.golang.org/api v0.150.0 h1:Z9k22qD289SZ8gCJrk4DrWXkNjtfvKAUo/l1ma8eBYE= +google.golang.org/api v0.150.0/go.mod h1:ccy+MJ6nrYFgE3WgRx/AMXOxOmU8Q4hSa+jjibzhxcg= google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= google.golang.org/appengine v1.2.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= diff --git a/processor/datapointcountprocessor/go.mod b/processor/datapointcountprocessor/go.mod index d70e4c5c3..6a878cdba 100644 --- a/processor/datapointcountprocessor/go.mod +++ b/processor/datapointcountprocessor/go.mod @@ -23,7 +23,7 @@ require ( github.com/gobwas/glob v0.2.3 // indirect github.com/gogo/protobuf v1.3.2 // indirect github.com/golang/protobuf v1.5.3 // indirect - github.com/google/uuid v1.3.1 // indirect + github.com/google/uuid v1.4.0 // indirect github.com/iancoleman/strcase v0.3.0 // indirect github.com/json-iterator/go v1.1.12 // indirect github.com/knadh/koanf v1.5.0 // indirect @@ -44,7 +44,7 @@ require ( go.uber.org/multierr v1.11.0 // indirect golang.org/x/exp v0.0.0-20230711023510-fffb14384f22 // indirect golang.org/x/net v0.17.0 // indirect - golang.org/x/sys v0.13.0 // indirect + golang.org/x/sys v0.14.0 // indirect golang.org/x/text v0.13.0 // indirect google.golang.org/genproto/googleapis/rpc v0.0.0-20230822172742-b8732ec3820d // indirect google.golang.org/grpc v1.59.0 // indirect diff --git a/processor/datapointcountprocessor/go.sum b/processor/datapointcountprocessor/go.sum index 420c6706b..5e9734479 100644 --- a/processor/datapointcountprocessor/go.sum +++ b/processor/datapointcountprocessor/go.sum @@ -101,8 +101,8 @@ github.com/google/go-cmp v0.5.7/go.mod h1:n+brtR0CgQNWTVd5ZUFpTBC8YFBDLK/h/bpaJ8 github.com/google/go-cmp v0.5.9 h1:O2Tfq5qg4qc4AmwVlvv0oLiVAGB7enBSJ2x2DqQFi38= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/google/uuid v1.3.1 h1:KjJaJ9iWZ3jOFZIf1Lqf4laDRCasjl0BCmnEGxkdLb4= -github.com/google/uuid v1.3.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= +github.com/google/uuid v1.4.0 h1:MtMxsa51/r9yyhkyLsVeVt0B+BGQZzpQiTQ4eHZ8bc4= +github.com/google/uuid v1.4.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw= github.com/hashicorp/consul/api v1.13.0/go.mod h1:ZlVrynguJKcYr54zGaDbaL3fOvKC9m72FhPvA8T35KQ= @@ -371,8 +371,8 @@ golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210603081109-ebe580a85c40/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= -golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.14.0 h1:Vz7Qs629MkJkGyHxUlRHizWJRG2j8fbQKjELVSNhy7Q= +golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20181227161524-e6919f6577db/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= diff --git a/processor/logcountprocessor/go.mod b/processor/logcountprocessor/go.mod index d69a12b69..c89021328 100644 --- a/processor/logcountprocessor/go.mod +++ b/processor/logcountprocessor/go.mod @@ -30,7 +30,7 @@ require ( github.com/gobwas/glob v0.2.3 // indirect github.com/gogo/protobuf v1.3.2 // indirect github.com/golang/protobuf v1.5.3 // indirect - github.com/google/uuid v1.3.1 // indirect + github.com/google/uuid v1.4.0 // indirect github.com/iancoleman/strcase v0.3.0 // indirect github.com/json-iterator/go v1.1.12 // indirect github.com/knadh/koanf v1.5.0 // indirect @@ -48,7 +48,7 @@ require ( go.uber.org/multierr v1.11.0 // indirect golang.org/x/exp v0.0.0-20230711023510-fffb14384f22 // indirect golang.org/x/net v0.17.0 // indirect - golang.org/x/sys v0.13.0 // indirect + golang.org/x/sys v0.14.0 // indirect golang.org/x/text v0.13.0 // indirect google.golang.org/genproto/googleapis/rpc v0.0.0-20230822172742-b8732ec3820d // indirect google.golang.org/grpc v1.59.0 // indirect diff --git a/processor/logcountprocessor/go.sum b/processor/logcountprocessor/go.sum index d792f7ae0..1622d9249 100644 --- a/processor/logcountprocessor/go.sum +++ b/processor/logcountprocessor/go.sum @@ -101,8 +101,8 @@ github.com/google/go-cmp v0.5.7/go.mod h1:n+brtR0CgQNWTVd5ZUFpTBC8YFBDLK/h/bpaJ8 github.com/google/go-cmp v0.5.9 h1:O2Tfq5qg4qc4AmwVlvv0oLiVAGB7enBSJ2x2DqQFi38= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/google/uuid v1.3.1 h1:KjJaJ9iWZ3jOFZIf1Lqf4laDRCasjl0BCmnEGxkdLb4= -github.com/google/uuid v1.3.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= +github.com/google/uuid v1.4.0 h1:MtMxsa51/r9yyhkyLsVeVt0B+BGQZzpQiTQ4eHZ8bc4= +github.com/google/uuid v1.4.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw= github.com/hashicorp/consul/api v1.13.0/go.mod h1:ZlVrynguJKcYr54zGaDbaL3fOvKC9m72FhPvA8T35KQ= @@ -370,8 +370,8 @@ golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210603081109-ebe580a85c40/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= -golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.14.0 h1:Vz7Qs629MkJkGyHxUlRHizWJRG2j8fbQKjELVSNhy7Q= +golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20181227161524-e6919f6577db/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= diff --git a/processor/logdeduplicationprocessor/go.mod b/processor/logdeduplicationprocessor/go.mod index 6d4b4b137..9b582840a 100644 --- a/processor/logdeduplicationprocessor/go.mod +++ b/processor/logdeduplicationprocessor/go.mod @@ -38,7 +38,7 @@ require ( go.opentelemetry.io/otel/trace v1.19.0 // indirect go.uber.org/multierr v1.11.0 // indirect golang.org/x/net v0.17.0 // indirect - golang.org/x/sys v0.13.0 // indirect + golang.org/x/sys v0.14.0 // indirect golang.org/x/text v0.13.0 // indirect google.golang.org/genproto/googleapis/rpc v0.0.0-20230822172742-b8732ec3820d // indirect google.golang.org/grpc v1.59.0 // indirect diff --git a/processor/logdeduplicationprocessor/go.sum b/processor/logdeduplicationprocessor/go.sum index 1b8b92f1b..d0308de83 100644 --- a/processor/logdeduplicationprocessor/go.sum +++ b/processor/logdeduplicationprocessor/go.sum @@ -354,8 +354,8 @@ golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210603081109-ebe580a85c40/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= -golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.14.0 h1:Vz7Qs629MkJkGyHxUlRHizWJRG2j8fbQKjELVSNhy7Q= +golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20181227161524-e6919f6577db/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= diff --git a/processor/maskprocessor/go.mod b/processor/maskprocessor/go.mod index 297f80018..adacaec6d 100644 --- a/processor/maskprocessor/go.mod +++ b/processor/maskprocessor/go.mod @@ -34,7 +34,7 @@ require ( go.opentelemetry.io/otel/trace v1.19.0 // indirect go.uber.org/multierr v1.11.0 // indirect golang.org/x/net v0.17.0 // indirect - golang.org/x/sys v0.13.0 // indirect + golang.org/x/sys v0.14.0 // indirect golang.org/x/text v0.13.0 // indirect google.golang.org/genproto/googleapis/rpc v0.0.0-20230822172742-b8732ec3820d // indirect google.golang.org/grpc v1.59.0 // indirect diff --git a/processor/maskprocessor/go.sum b/processor/maskprocessor/go.sum index 80b0c4bd0..67456f1a8 100644 --- a/processor/maskprocessor/go.sum +++ b/processor/maskprocessor/go.sum @@ -376,8 +376,8 @@ golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210603081109-ebe580a85c40/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= -golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.14.0 h1:Vz7Qs629MkJkGyHxUlRHizWJRG2j8fbQKjELVSNhy7Q= +golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20181227161524-e6919f6577db/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= diff --git a/processor/metricextractprocessor/go.mod b/processor/metricextractprocessor/go.mod index 0fa5b7516..96f4ce0f4 100644 --- a/processor/metricextractprocessor/go.mod +++ b/processor/metricextractprocessor/go.mod @@ -21,7 +21,7 @@ require ( github.com/cespare/xxhash/v2 v2.2.0 // indirect github.com/davecgh/go-spew v1.1.1 // indirect github.com/gobwas/glob v0.2.3 // indirect - github.com/google/uuid v1.3.1 // indirect + github.com/google/uuid v1.4.0 // indirect github.com/iancoleman/strcase v0.3.0 // indirect github.com/knadh/koanf/v2 v2.0.1 // indirect github.com/open-telemetry/opentelemetry-collector-contrib/internal/coreinternal v0.88.0 // indirect @@ -52,7 +52,7 @@ require ( go.opentelemetry.io/otel/trace v1.19.0 // indirect go.uber.org/multierr v1.11.0 // indirect golang.org/x/net v0.17.0 // indirect - golang.org/x/sys v0.13.0 // indirect + golang.org/x/sys v0.14.0 // indirect golang.org/x/text v0.13.0 // indirect google.golang.org/grpc v1.59.0 // indirect google.golang.org/protobuf v1.31.0 // indirect diff --git a/processor/metricextractprocessor/go.sum b/processor/metricextractprocessor/go.sum index b8d0a75a1..9aa3d4e02 100644 --- a/processor/metricextractprocessor/go.sum +++ b/processor/metricextractprocessor/go.sum @@ -103,8 +103,8 @@ github.com/google/go-cmp v0.5.7/go.mod h1:n+brtR0CgQNWTVd5ZUFpTBC8YFBDLK/h/bpaJ8 github.com/google/go-cmp v0.5.9 h1:O2Tfq5qg4qc4AmwVlvv0oLiVAGB7enBSJ2x2DqQFi38= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/google/uuid v1.3.1 h1:KjJaJ9iWZ3jOFZIf1Lqf4laDRCasjl0BCmnEGxkdLb4= -github.com/google/uuid v1.3.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= +github.com/google/uuid v1.4.0 h1:MtMxsa51/r9yyhkyLsVeVt0B+BGQZzpQiTQ4eHZ8bc4= +github.com/google/uuid v1.4.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw= github.com/hashicorp/consul/api v1.13.0/go.mod h1:ZlVrynguJKcYr54zGaDbaL3fOvKC9m72FhPvA8T35KQ= @@ -378,8 +378,8 @@ golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210603081109-ebe580a85c40/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= -golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.14.0 h1:Vz7Qs629MkJkGyHxUlRHizWJRG2j8fbQKjELVSNhy7Q= +golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20181227161524-e6919f6577db/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= diff --git a/processor/metricstatsprocessor/go.mod b/processor/metricstatsprocessor/go.mod index c9eb8af5c..e0fcaff4f 100644 --- a/processor/metricstatsprocessor/go.mod +++ b/processor/metricstatsprocessor/go.mod @@ -36,7 +36,7 @@ require ( go.opentelemetry.io/otel/metric v1.19.0 // indirect go.opentelemetry.io/otel/trace v1.19.0 // indirect golang.org/x/net v0.17.0 // indirect - golang.org/x/sys v0.13.0 // indirect + golang.org/x/sys v0.14.0 // indirect golang.org/x/text v0.13.0 // indirect google.golang.org/genproto/googleapis/rpc v0.0.0-20230822172742-b8732ec3820d // indirect google.golang.org/grpc v1.59.0 // indirect diff --git a/processor/metricstatsprocessor/go.sum b/processor/metricstatsprocessor/go.sum index b3311afe8..be3817d3d 100644 --- a/processor/metricstatsprocessor/go.sum +++ b/processor/metricstatsprocessor/go.sum @@ -358,8 +358,8 @@ golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210603081109-ebe580a85c40/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= -golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.14.0 h1:Vz7Qs629MkJkGyHxUlRHizWJRG2j8fbQKjELVSNhy7Q= +golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20181227161524-e6919f6577db/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= diff --git a/processor/removeemptyvaluesprocessor/go.mod b/processor/removeemptyvaluesprocessor/go.mod index 3ca09b040..ec7028d1b 100644 --- a/processor/removeemptyvaluesprocessor/go.mod +++ b/processor/removeemptyvaluesprocessor/go.mod @@ -35,7 +35,7 @@ require ( go.opentelemetry.io/otel/trace v1.19.0 // indirect go.uber.org/multierr v1.11.0 // indirect golang.org/x/net v0.17.0 // indirect - golang.org/x/sys v0.13.0 // indirect + golang.org/x/sys v0.14.0 // indirect golang.org/x/text v0.13.0 // indirect google.golang.org/genproto/googleapis/rpc v0.0.0-20230822172742-b8732ec3820d // indirect google.golang.org/grpc v1.59.0 // indirect diff --git a/processor/removeemptyvaluesprocessor/go.sum b/processor/removeemptyvaluesprocessor/go.sum index 749f532a6..a12d79d61 100644 --- a/processor/removeemptyvaluesprocessor/go.sum +++ b/processor/removeemptyvaluesprocessor/go.sum @@ -379,8 +379,8 @@ golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210603081109-ebe580a85c40/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= -golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.14.0 h1:Vz7Qs629MkJkGyHxUlRHizWJRG2j8fbQKjELVSNhy7Q= +golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20181227161524-e6919f6577db/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= diff --git a/processor/resourceattributetransposerprocessor/go.mod b/processor/resourceattributetransposerprocessor/go.mod index 1e46acd9b..152f25419 100644 --- a/processor/resourceattributetransposerprocessor/go.mod +++ b/processor/resourceattributetransposerprocessor/go.mod @@ -26,7 +26,7 @@ require ( github.com/gogo/protobuf v1.3.2 // indirect github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect github.com/golang/protobuf v1.5.3 // indirect - github.com/google/uuid v1.3.1 // indirect + github.com/google/uuid v1.4.0 // indirect github.com/grpc-ecosystem/grpc-gateway/v2 v2.16.0 // indirect github.com/inconshreveable/mousetrap v1.1.0 // indirect github.com/json-iterator/go v1.1.12 // indirect @@ -46,7 +46,7 @@ require ( github.com/prometheus/common v0.44.0 // indirect github.com/prometheus/procfs v0.11.1 // indirect github.com/prometheus/statsd_exporter v0.22.7 // indirect - github.com/shirou/gopsutil/v3 v3.23.9 // indirect + github.com/shirou/gopsutil/v3 v3.23.10 // indirect github.com/shoenig/go-m1cpu v0.1.6 // indirect github.com/spf13/cobra v1.7.0 // indirect github.com/spf13/pflag v1.0.5 // indirect @@ -84,7 +84,7 @@ require ( go.opentelemetry.io/proto/otlp v1.0.0 // indirect go.uber.org/multierr v1.11.0 // indirect golang.org/x/net v0.17.0 // indirect - golang.org/x/sys v0.13.0 // indirect + golang.org/x/sys v0.14.0 // indirect golang.org/x/text v0.13.0 // indirect gonum.org/v1/gonum v0.14.0 // indirect google.golang.org/genproto/googleapis/api v0.0.0-20230822172742-b8732ec3820d // indirect diff --git a/processor/resourceattributetransposerprocessor/go.sum b/processor/resourceattributetransposerprocessor/go.sum index 547f6fec9..6bac45211 100644 --- a/processor/resourceattributetransposerprocessor/go.sum +++ b/processor/resourceattributetransposerprocessor/go.sum @@ -167,8 +167,9 @@ github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/ github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.7/go.mod h1:n+brtR0CgQNWTVd5ZUFpTBC8YFBDLK/h/bpaJ8/DtOE= github.com/google/go-cmp v0.5.8/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= -github.com/google/go-cmp v0.5.9 h1:O2Tfq5qg4qc4AmwVlvv0oLiVAGB7enBSJ2x2DqQFi38= github.com/google/go-cmp v0.5.9/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= +github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= +github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/martian v2.1.0+incompatible/go.mod h1:9I4somxYTbIHy5NJKHRl3wXiIaQGbYVAs8BPL6v8lEs= github.com/google/martian/v3 v3.0.0/go.mod h1:y5Zk1BBys9G+gd6Jrk0W3cC1+ELVxBWuIGO+w/tUAp0= @@ -181,8 +182,8 @@ github.com/google/pprof v0.0.0-20200430221834-fc25d7d30c6d/go.mod h1:ZgVRPoUq/hf github.com/google/pprof v0.0.0-20200708004538-1a94d8640e99/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM= github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI= github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/google/uuid v1.3.1 h1:KjJaJ9iWZ3jOFZIf1Lqf4laDRCasjl0BCmnEGxkdLb4= -github.com/google/uuid v1.3.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= +github.com/google/uuid v1.4.0 h1:MtMxsa51/r9yyhkyLsVeVt0B+BGQZzpQiTQ4eHZ8bc4= +github.com/google/uuid v1.4.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg= github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk= github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= @@ -353,8 +354,8 @@ github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f/go.mod h1:sm1tb github.com/ryanuber/columnize v2.1.0+incompatible/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts= github.com/ryanuber/go-glob v1.0.0/go.mod h1:807d1WSdnB0XRJzKNil9Om6lcp/3a0v4qIHxIXzX/Yc= github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc= -github.com/shirou/gopsutil/v3 v3.23.9 h1:ZI5bWVeu2ep4/DIxB4U9okeYJ7zp/QLTO4auRb/ty/E= -github.com/shirou/gopsutil/v3 v3.23.9/go.mod h1:x/NWSb71eMcjFIO0vhyGW5nZ7oSIgVjrCnADckb85GA= +github.com/shirou/gopsutil/v3 v3.23.10 h1:/N42opWlYzegYaVkWejXWJpbzKv2JDy3mrgGzKsh9hM= +github.com/shirou/gopsutil/v3 v3.23.10/go.mod h1:JIE26kpucQi+innVlAUnIEOSBhBUkirr5b44yr55+WE= github.com/shoenig/go-m1cpu v0.1.6 h1:nxdKQNcEB6vzgA2E2bvzKIYRuNj7XNJ4S/aRSwKzFtM= github.com/shoenig/go-m1cpu v0.1.6/go.mod h1:1JJMcUBvfNwpq05QDQVAnx3gUHr9IYF7GNg9SUEw2VQ= github.com/shoenig/test v0.6.4 h1:kVTaSd7WLz5WZ2IaoM0RSzRsUD+m8wRR+5qvntpn4LU= @@ -638,9 +639,9 @@ golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20220708085239-5a0f0661e09d/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.8.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.11.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.12.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.14.0 h1:Vz7Qs629MkJkGyHxUlRHizWJRG2j8fbQKjELVSNhy7Q= +golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= diff --git a/processor/samplingprocessor/go.mod b/processor/samplingprocessor/go.mod index 1f32ce50e..68bb2f706 100644 --- a/processor/samplingprocessor/go.mod +++ b/processor/samplingprocessor/go.mod @@ -34,7 +34,7 @@ require ( go.opentelemetry.io/otel/trace v1.19.0 // indirect go.uber.org/multierr v1.11.0 // indirect golang.org/x/net v0.17.0 // indirect - golang.org/x/sys v0.13.0 // indirect + golang.org/x/sys v0.14.0 // indirect golang.org/x/text v0.13.0 // indirect google.golang.org/genproto/googleapis/rpc v0.0.0-20230822172742-b8732ec3820d // indirect google.golang.org/grpc v1.59.0 // indirect diff --git a/processor/samplingprocessor/go.sum b/processor/samplingprocessor/go.sum index 80b0c4bd0..67456f1a8 100644 --- a/processor/samplingprocessor/go.sum +++ b/processor/samplingprocessor/go.sum @@ -376,8 +376,8 @@ golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210603081109-ebe580a85c40/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= -golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.14.0 h1:Vz7Qs629MkJkGyHxUlRHizWJRG2j8fbQKjELVSNhy7Q= +golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20181227161524-e6919f6577db/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= diff --git a/processor/spancountprocessor/go.mod b/processor/spancountprocessor/go.mod index f8d41b091..1df91dbe5 100644 --- a/processor/spancountprocessor/go.mod +++ b/processor/spancountprocessor/go.mod @@ -23,7 +23,7 @@ require ( github.com/gobwas/glob v0.2.3 // indirect github.com/gogo/protobuf v1.3.2 // indirect github.com/golang/protobuf v1.5.3 // indirect - github.com/google/uuid v1.3.1 // indirect + github.com/google/uuid v1.4.0 // indirect github.com/iancoleman/strcase v0.3.0 // indirect github.com/json-iterator/go v1.1.12 // indirect github.com/knadh/koanf v1.5.0 // indirect @@ -44,7 +44,7 @@ require ( go.uber.org/multierr v1.11.0 // indirect golang.org/x/exp v0.0.0-20230711023510-fffb14384f22 // indirect golang.org/x/net v0.17.0 // indirect - golang.org/x/sys v0.13.0 // indirect + golang.org/x/sys v0.14.0 // indirect golang.org/x/text v0.13.0 // indirect google.golang.org/genproto/googleapis/rpc v0.0.0-20230822172742-b8732ec3820d // indirect google.golang.org/grpc v1.59.0 // indirect diff --git a/processor/spancountprocessor/go.sum b/processor/spancountprocessor/go.sum index 420c6706b..5e9734479 100644 --- a/processor/spancountprocessor/go.sum +++ b/processor/spancountprocessor/go.sum @@ -101,8 +101,8 @@ github.com/google/go-cmp v0.5.7/go.mod h1:n+brtR0CgQNWTVd5ZUFpTBC8YFBDLK/h/bpaJ8 github.com/google/go-cmp v0.5.9 h1:O2Tfq5qg4qc4AmwVlvv0oLiVAGB7enBSJ2x2DqQFi38= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/google/uuid v1.3.1 h1:KjJaJ9iWZ3jOFZIf1Lqf4laDRCasjl0BCmnEGxkdLb4= -github.com/google/uuid v1.3.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= +github.com/google/uuid v1.4.0 h1:MtMxsa51/r9yyhkyLsVeVt0B+BGQZzpQiTQ4eHZ8bc4= +github.com/google/uuid v1.4.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw= github.com/hashicorp/consul/api v1.13.0/go.mod h1:ZlVrynguJKcYr54zGaDbaL3fOvKC9m72FhPvA8T35KQ= @@ -371,8 +371,8 @@ golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210603081109-ebe580a85c40/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= -golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.14.0 h1:Vz7Qs629MkJkGyHxUlRHizWJRG2j8fbQKjELVSNhy7Q= +golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20181227161524-e6919f6577db/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= diff --git a/processor/throughputmeasurementprocessor/go.mod b/processor/throughputmeasurementprocessor/go.mod index 148b02707..432f813fc 100644 --- a/processor/throughputmeasurementprocessor/go.mod +++ b/processor/throughputmeasurementprocessor/go.mod @@ -34,7 +34,7 @@ require ( go.opentelemetry.io/otel/trace v1.19.0 // indirect go.uber.org/multierr v1.11.0 // indirect golang.org/x/net v0.17.0 // indirect - golang.org/x/sys v0.13.0 // indirect + golang.org/x/sys v0.14.0 // indirect golang.org/x/text v0.13.0 // indirect google.golang.org/genproto/googleapis/rpc v0.0.0-20230822172742-b8732ec3820d // indirect google.golang.org/grpc v1.59.0 // indirect diff --git a/processor/throughputmeasurementprocessor/go.sum b/processor/throughputmeasurementprocessor/go.sum index 80b0c4bd0..67456f1a8 100644 --- a/processor/throughputmeasurementprocessor/go.sum +++ b/processor/throughputmeasurementprocessor/go.sum @@ -376,8 +376,8 @@ golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210603081109-ebe580a85c40/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= -golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.14.0 h1:Vz7Qs629MkJkGyHxUlRHizWJRG2j8fbQKjELVSNhy7Q= +golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20181227161524-e6919f6577db/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= diff --git a/receiver/azureblobrehydrationreceiver/go.mod b/receiver/azureblobrehydrationreceiver/go.mod index 3002a11b6..5a3f8426a 100644 --- a/receiver/azureblobrehydrationreceiver/go.mod +++ b/receiver/azureblobrehydrationreceiver/go.mod @@ -39,7 +39,7 @@ require ( go.uber.org/goleak v1.2.1 // indirect go.uber.org/multierr v1.11.0 // indirect golang.org/x/net v0.17.0 // indirect - golang.org/x/sys v0.13.0 // indirect + golang.org/x/sys v0.14.0 // indirect golang.org/x/text v0.13.0 // indirect google.golang.org/genproto/googleapis/rpc v0.0.0-20230822172742-b8732ec3820d // indirect google.golang.org/grpc v1.59.0 // indirect diff --git a/receiver/azureblobrehydrationreceiver/go.sum b/receiver/azureblobrehydrationreceiver/go.sum index a32854caf..165f10ffb 100644 --- a/receiver/azureblobrehydrationreceiver/go.sum +++ b/receiver/azureblobrehydrationreceiver/go.sum @@ -109,8 +109,8 @@ golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJ 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.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= -golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.14.0 h1:Vz7Qs629MkJkGyHxUlRHizWJRG2j8fbQKjELVSNhy7Q= +golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.13.0 h1:ablQoSUd0tRdKxZewP80B+BaqeKJuVhuRxj/dkrun3k= diff --git a/receiver/m365receiver/go.mod b/receiver/m365receiver/go.mod index 388a61ec8..b493f576e 100644 --- a/receiver/m365receiver/go.mod +++ b/receiver/m365receiver/go.mod @@ -4,7 +4,7 @@ go 1.20 require ( github.com/google/go-cmp v0.6.0 - github.com/google/uuid v1.3.1 + github.com/google/uuid v1.4.0 github.com/open-telemetry/opentelemetry-collector-contrib/pkg/pdatatest v0.88.0 github.com/open-telemetry/opentelemetry-collector-contrib/pkg/stanza v0.88.0 github.com/stretchr/testify v1.8.4 @@ -62,7 +62,7 @@ require ( go.opentelemetry.io/otel/trace v1.19.0 // indirect go.uber.org/multierr v1.11.0 // indirect golang.org/x/net v0.17.0 // indirect - golang.org/x/sys v0.13.0 // indirect + golang.org/x/sys v0.14.0 // indirect golang.org/x/text v0.13.0 // indirect gonum.org/v1/gonum v0.14.0 // indirect google.golang.org/genproto/googleapis/rpc v0.0.0-20230822172742-b8732ec3820d // indirect diff --git a/receiver/m365receiver/go.sum b/receiver/m365receiver/go.sum index a41da1812..a6384251f 100644 --- a/receiver/m365receiver/go.sum +++ b/receiver/m365receiver/go.sum @@ -116,8 +116,8 @@ github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/google/uuid v1.3.1 h1:KjJaJ9iWZ3jOFZIf1Lqf4laDRCasjl0BCmnEGxkdLb4= -github.com/google/uuid v1.3.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= +github.com/google/uuid v1.4.0 h1:MtMxsa51/r9yyhkyLsVeVt0B+BGQZzpQiTQ4eHZ8bc4= +github.com/google/uuid v1.4.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw= github.com/hashicorp/consul/api v1.13.0/go.mod h1:ZlVrynguJKcYr54zGaDbaL3fOvKC9m72FhPvA8T35KQ= @@ -431,8 +431,8 @@ golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210603081109-ebe580a85c40/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220908164124-27713097b956/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= -golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.14.0 h1:Vz7Qs629MkJkGyHxUlRHizWJRG2j8fbQKjELVSNhy7Q= +golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20181227161524-e6919f6577db/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= diff --git a/receiver/pluginreceiver/go.mod b/receiver/pluginreceiver/go.mod index c92adb0b8..7d76e390a 100644 --- a/receiver/pluginreceiver/go.mod +++ b/receiver/pluginreceiver/go.mod @@ -88,13 +88,13 @@ require ( go.opentelemetry.io/otel/exporters/stdout/stdoutmetric v0.42.0 // indirect go.opentelemetry.io/otel/exporters/stdout/stdouttrace v1.19.0 // indirect go.opentelemetry.io/proto/otlp v1.0.0 // indirect - golang.org/x/sync v0.4.0 // indirect - google.golang.org/genproto/googleapis/api v0.0.0-20231002182017-d307bd883b97 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231009173412-8bfb1ae86b6c // indirect + golang.org/x/sync v0.5.0 // indirect + google.golang.org/genproto/googleapis/api v0.0.0-20231016165738-49dd2c1f3d0b // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20231030173426-d783a09b4405 // indirect ) require ( - cloud.google.com/go/compute v1.23.0 // indirect + cloud.google.com/go/compute v1.23.1 // indirect cloud.google.com/go/compute/metadata v0.2.3 // indirect contrib.go.opencensus.io/exporter/prometheus v0.4.2 // indirect github.com/Azure/azure-sdk-for-go v65.0.0+incompatible // indirect @@ -132,7 +132,7 @@ require ( github.com/dennwc/varint v1.0.0 // indirect github.com/digitalocean/godo v1.99.0 // indirect github.com/docker/distribution v2.8.2+incompatible // indirect - github.com/docker/docker v24.0.6+incompatible // indirect + github.com/docker/docker v24.0.7+incompatible // indirect github.com/docker/go-connections v0.4.0 // indirect github.com/docker/go-units v0.5.0 // indirect github.com/emicklei/go-restful/v3 v3.10.2 // indirect @@ -164,8 +164,8 @@ require ( github.com/google/go-cmp v0.6.0 // indirect github.com/google/go-querystring v1.1.0 // indirect github.com/google/gofuzz v1.2.0 // indirect - github.com/google/uuid v1.3.1 // indirect - github.com/googleapis/enterprise-certificate-proxy v0.3.1 // indirect + github.com/google/uuid v1.4.0 // indirect + github.com/googleapis/enterprise-certificate-proxy v0.3.2 // indirect github.com/googleapis/gax-go/v2 v2.12.0 // indirect github.com/gophercloud/gophercloud v1.5.0 // indirect github.com/gorilla/websocket v1.5.0 // indirect @@ -227,7 +227,7 @@ require ( github.com/prometheus/prometheus v0.47.2 // indirect github.com/prometheus/statsd_exporter v0.22.7 // indirect github.com/scaleway/scaleway-sdk-go v1.0.0-beta.20 // indirect - github.com/shirou/gopsutil/v3 v3.23.9 // indirect + github.com/shirou/gopsutil/v3 v3.23.10 // indirect github.com/sijms/go-ora/v2 v2.7.19 // indirect github.com/sirupsen/logrus v1.9.0 // indirect github.com/snowflakedb/gosnowflake v1.6.25 // indirect @@ -255,16 +255,16 @@ require ( golang.org/x/mod v0.13.0 // indirect golang.org/x/net v0.17.0 // indirect golang.org/x/oauth2 v0.13.0 // indirect - golang.org/x/sys v0.13.0 // indirect + golang.org/x/sys v0.14.0 // indirect golang.org/x/term v0.13.0 // indirect golang.org/x/text v0.13.0 // indirect golang.org/x/time v0.3.0 // indirect golang.org/x/tools v0.14.0 // indirect golang.org/x/xerrors v0.0.0-20220907171357-04be3eba64a2 // indirect gonum.org/v1/gonum v0.14.0 // indirect - google.golang.org/api v0.147.0 // indirect + google.golang.org/api v0.150.0 // indirect google.golang.org/appengine v1.6.7 // indirect - google.golang.org/genproto v0.0.0-20231002182017-d307bd883b97 // indirect + google.golang.org/genproto v0.0.0-20231016165738-49dd2c1f3d0b // indirect google.golang.org/grpc v1.59.0 // indirect google.golang.org/protobuf v1.31.0 // indirect gopkg.in/inf.v0 v0.9.1 // indirect diff --git a/receiver/pluginreceiver/go.sum b/receiver/pluginreceiver/go.sum index 30a3595af..5ebe9d40a 100644 --- a/receiver/pluginreceiver/go.sum +++ b/receiver/pluginreceiver/go.sum @@ -19,8 +19,8 @@ cloud.google.com/go/bigquery v1.4.0/go.mod h1:S8dzgnTigyfTmLBfrtrhyYhwRxG72rYxvf cloud.google.com/go/bigquery v1.5.0/go.mod h1:snEHRnqQbz117VIFhE8bmtwIDY80NLUZUMb4Nv6dBIg= cloud.google.com/go/bigquery v1.7.0/go.mod h1://okPTzCYNXSlb24MZs83e2Do+h+VXtc4gLoIoXIAPc= cloud.google.com/go/bigquery v1.8.0/go.mod h1:J5hqkt3O0uAFnINi6JXValWIb1v0goeZM77hZzJN/fQ= -cloud.google.com/go/compute v1.23.0 h1:tP41Zoavr8ptEqaW6j+LQOnyBBhO7OkOMAGrgLopTwY= -cloud.google.com/go/compute v1.23.0/go.mod h1:4tCnrn48xsqlwSAiLf1HXMQk8CONslYbdiEZc9FEIbM= +cloud.google.com/go/compute v1.23.1 h1:V97tBoDaZHb6leicZ1G6DLK2BAaZLJ/7+9BB/En3hR0= +cloud.google.com/go/compute v1.23.1/go.mod h1:CqB3xpmPKKt3OJpW2ndFIXnA9A4xAy/F3Xp1ixncW78= cloud.google.com/go/compute/metadata v0.2.3 h1:mg4jlk7mCAj6xXp9UJ4fjI9VUI5rubuGBW5aJ7UnBMY= cloud.google.com/go/compute/metadata v0.2.3/go.mod h1:VAV5nSsACxMJvgaAuX6Pk2AawlZn8kiOGuCv6gTkwuA= cloud.google.com/go/datastore v1.0.0/go.mod h1:LXYbyblFSglQ5pkeyhO+Qmw7ukd3C+pD7TKLgZqpHYE= @@ -222,8 +222,8 @@ github.com/dnaeon/go-vcr v1.2.0 h1:zHCHvJYTMh1N7xnV7zf1m1GPBF9Ad0Jk/whtQ1663qI= github.com/dnaeon/go-vcr v1.2.0/go.mod h1:R4UdLID7HZT3taECzJs4YgbbH6PIGXB6W/sc5OLb6RQ= github.com/docker/distribution v2.8.2+incompatible h1:T3de5rq0dB1j30rp0sA2rER+m322EBzniBPB6ZIzuh8= github.com/docker/distribution v2.8.2+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w= -github.com/docker/docker v24.0.6+incompatible h1:hceabKCtUgDqPu+qm0NgsaXf28Ljf4/pWFL7xjWWDgE= -github.com/docker/docker v24.0.6+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= +github.com/docker/docker v24.0.7+incompatible h1:Wo6l37AuwP3JaMnZa226lzVXGA3F9Ig1seQen0cKYlM= +github.com/docker/docker v24.0.7+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= github.com/docker/go-connections v0.4.0 h1:El9xVISelRB7BuFusrZozjnkIM5YnzCViNKohAFqRJQ= github.com/docker/go-connections v0.4.0/go.mod h1:Gbd7IOopHjR8Iph03tsViu4nIes5XhDvyHbTtUxmeec= github.com/docker/go-units v0.5.0 h1:69rxXcBk27SvSaaxTtLh/8llcHD8vYHT7WSdRZ/jvr4= @@ -394,10 +394,10 @@ github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm4 github.com/google/s2a-go v0.1.7 h1:60BLSyTrOV4/haCDW4zb1guZItoSq8foHCXrAnjBo/o= github.com/google/s2a-go v0.1.7/go.mod h1:50CgR4k1jNlWBu4UfS4AcfhVe1r6pdZPygJ3R8F0Qdw= github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/google/uuid v1.3.1 h1:KjJaJ9iWZ3jOFZIf1Lqf4laDRCasjl0BCmnEGxkdLb4= -github.com/google/uuid v1.3.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/googleapis/enterprise-certificate-proxy v0.3.1 h1:SBWmZhjUDRorQxrN0nwzf+AHBxnbFjViHQS4P0yVpmQ= -github.com/googleapis/enterprise-certificate-proxy v0.3.1/go.mod h1:VLSiSSBs/ksPL8kq3OBOQ6WRI2QnaFynd1DCjZ62+V0= +github.com/google/uuid v1.4.0 h1:MtMxsa51/r9yyhkyLsVeVt0B+BGQZzpQiTQ4eHZ8bc4= +github.com/google/uuid v1.4.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= +github.com/googleapis/enterprise-certificate-proxy v0.3.2 h1:Vie5ybvEvT75RniqhfFxPRy3Bf7vr3h0cechB90XaQs= +github.com/googleapis/enterprise-certificate-proxy v0.3.2/go.mod h1:VLSiSSBs/ksPL8kq3OBOQ6WRI2QnaFynd1DCjZ62+V0= github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg= github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk= github.com/googleapis/gax-go/v2 v2.12.0 h1:A+gCJKdRfqXkr+BIRGtZLibNXf0m1f9E4HG56etFpas= @@ -751,8 +751,8 @@ github.com/scaleway/scaleway-sdk-go v1.0.0-beta.20 h1:a9hSJdJcd16e0HoMsnFvaHvxB3 github.com/scaleway/scaleway-sdk-go v1.0.0-beta.20/go.mod h1:fCa7OJZ/9DRTnOKmxvT6pn+LPWUptQAmHF/SBJUGEcg= github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529 h1:nn5Wsu0esKSJiIVhscUtVbo7ada43DJhG55ua/hjS5I= github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc= -github.com/shirou/gopsutil/v3 v3.23.9 h1:ZI5bWVeu2ep4/DIxB4U9okeYJ7zp/QLTO4auRb/ty/E= -github.com/shirou/gopsutil/v3 v3.23.9/go.mod h1:x/NWSb71eMcjFIO0vhyGW5nZ7oSIgVjrCnADckb85GA= +github.com/shirou/gopsutil/v3 v3.23.10 h1:/N42opWlYzegYaVkWejXWJpbzKv2JDy3mrgGzKsh9hM= +github.com/shirou/gopsutil/v3 v3.23.10/go.mod h1:JIE26kpucQi+innVlAUnIEOSBhBUkirr5b44yr55+WE= github.com/shoenig/go-m1cpu v0.1.6 h1:nxdKQNcEB6vzgA2E2bvzKIYRuNj7XNJ4S/aRSwKzFtM= github.com/shoenig/go-m1cpu v0.1.6/go.mod h1:1JJMcUBvfNwpq05QDQVAnx3gUHr9IYF7GNg9SUEw2VQ= github.com/shoenig/test v0.6.4/go.mod h1:byHiCGXqrVaflBLAMq/srcZIHynQPQgeyvkvXnjqq0k= @@ -1032,8 +1032,8 @@ golang.org/x/sync v0.0.0-20201207232520-09787c993a3a/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20220601150217-0de741cfad7f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.4.0 h1:zxkM55ReGkDlKSM+Fu41A+zmbZuaPVbGMzvvdUPznYQ= -golang.org/x/sync v0.4.0/go.mod h1:FU7BRWz2tNW+3quACPkgCx/L+uEAv1htQ0V83Z9Rj+Y= +golang.org/x/sync v0.5.0 h1:60k92dhOjHxJkrqnwsfl8KuaHbn/5dl0lUPUklKo3qE= +golang.org/x/sync v0.5.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= golang.org/x/sys v0.0.0-20180823144017-11551d06cbcc/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= @@ -1108,9 +1108,9 @@ golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.8.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.11.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.12.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.14.0 h1:Vz7Qs629MkJkGyHxUlRHizWJRG2j8fbQKjELVSNhy7Q= +golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= golang.org/x/term v0.1.0/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= @@ -1206,8 +1206,8 @@ google.golang.org/api v0.24.0/go.mod h1:lIXQywCXRcnZPGlsd8NbLnOjtAoL6em04bJ9+z0M google.golang.org/api v0.28.0/go.mod h1:lIXQywCXRcnZPGlsd8NbLnOjtAoL6em04bJ9+z0MncE= google.golang.org/api v0.29.0/go.mod h1:Lcubydp8VUV7KeIHD9z2Bys/sm/vGKnG1UHuDBSrHWM= google.golang.org/api v0.30.0/go.mod h1:QGmEvQ87FHZNiUVJkT14jQNYJ4ZJjdRF23ZXz5138Fc= -google.golang.org/api v0.147.0 h1:Can3FaQo9LlVqxJCodNmeZW/ib3/qKAY3rFeXiHo5gc= -google.golang.org/api v0.147.0/go.mod h1:pQ/9j83DcmPd/5C9e2nFOdjjNkDZ1G+zkbK2uvdkJMs= +google.golang.org/api v0.150.0 h1:Z9k22qD289SZ8gCJrk4DrWXkNjtfvKAUo/l1ma8eBYE= +google.golang.org/api v0.150.0/go.mod h1:ccy+MJ6nrYFgE3WgRx/AMXOxOmU8Q4hSa+jjibzhxcg= google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= @@ -1248,12 +1248,12 @@ google.golang.org/genproto v0.0.0-20200729003335-053ba62fc06f/go.mod h1:FWY/as6D google.golang.org/genproto v0.0.0-20200804131852-c06518451d9c/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20200825200019-8632dd797987/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210602131652-f16073e35f0c/go.mod h1:UODoCrxHCcBojKKwX1terBiRUaqAsFqJiF615XL43r0= -google.golang.org/genproto v0.0.0-20231002182017-d307bd883b97 h1:SeZZZx0cP0fqUyA+oRzP9k7cSwJlvDFiROO72uwD6i0= -google.golang.org/genproto v0.0.0-20231002182017-d307bd883b97/go.mod h1:t1VqOqqvce95G3hIDCT5FeO3YUc6Q4Oe24L/+rNMxRk= -google.golang.org/genproto/googleapis/api v0.0.0-20231002182017-d307bd883b97 h1:W18sezcAYs+3tDZX4F80yctqa12jcP1PUS2gQu1zTPU= -google.golang.org/genproto/googleapis/api v0.0.0-20231002182017-d307bd883b97/go.mod h1:iargEX0SFPm3xcfMI0d1domjg0ZF4Aa0p2awqyxhvF0= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231009173412-8bfb1ae86b6c h1:jHkCUWkseRf+W+edG5hMzr/Uh1xkDREY4caybAq4dpY= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231009173412-8bfb1ae86b6c/go.mod h1:4cYg8o5yUbm77w8ZX00LhMVNl/YVBFJRYWDc0uYWMs0= +google.golang.org/genproto v0.0.0-20231016165738-49dd2c1f3d0b h1:+YaDE2r2OG8t/z5qmsh7Y+XXwCbvadxxZ0YY6mTdrVA= +google.golang.org/genproto v0.0.0-20231016165738-49dd2c1f3d0b/go.mod h1:CgAqfJo+Xmu0GwA0411Ht3OU3OntXwsGmrmjI8ioGXI= +google.golang.org/genproto/googleapis/api v0.0.0-20231016165738-49dd2c1f3d0b h1:CIC2YMXmIhYw6evmhPxBKJ4fmLbOFtXQN/GV3XOZR8k= +google.golang.org/genproto/googleapis/api v0.0.0-20231016165738-49dd2c1f3d0b/go.mod h1:IBQ646DjkDkvUIsVq/cc03FUFQ9wbZu7yE396YcL870= +google.golang.org/genproto/googleapis/rpc v0.0.0-20231030173426-d783a09b4405 h1:AB/lmRny7e2pLhFEYIbl5qkDAUt2h0ZRO4wGPhZf+ik= +google.golang.org/genproto/googleapis/rpc v0.0.0-20231030173426-d783a09b4405/go.mod h1:67X1fPuzjcrkymZzZV1vvkFeTn2Rvc6lYF9MYFGCcwE= google.golang.org/grpc v1.14.0/go.mod h1:yo6s7OP7yaDglbqo1J04qKzAhqBH6lvTonzMVmEdcZw= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38= diff --git a/receiver/routereceiver/go.mod b/receiver/routereceiver/go.mod index 15c0d7335..4f03ecc54 100644 --- a/receiver/routereceiver/go.mod +++ b/receiver/routereceiver/go.mod @@ -32,7 +32,7 @@ require ( go.uber.org/multierr v1.11.0 // indirect go.uber.org/zap v1.26.0 // indirect golang.org/x/net v0.17.0 // indirect - golang.org/x/sys v0.13.0 // indirect + golang.org/x/sys v0.14.0 // indirect golang.org/x/text v0.13.0 // indirect google.golang.org/genproto/googleapis/rpc v0.0.0-20230822172742-b8732ec3820d // indirect google.golang.org/grpc v1.59.0 // indirect diff --git a/receiver/routereceiver/go.sum b/receiver/routereceiver/go.sum index 41a8bc7ce..f48e4d6f6 100644 --- a/receiver/routereceiver/go.sum +++ b/receiver/routereceiver/go.sum @@ -350,8 +350,8 @@ golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210603081109-ebe580a85c40/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= -golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.14.0 h1:Vz7Qs629MkJkGyHxUlRHizWJRG2j8fbQKjELVSNhy7Q= +golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20181227161524-e6919f6577db/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= diff --git a/receiver/sapnetweaverreceiver/go.mod b/receiver/sapnetweaverreceiver/go.mod index 50a031e5a..18c2d58cd 100644 --- a/receiver/sapnetweaverreceiver/go.mod +++ b/receiver/sapnetweaverreceiver/go.mod @@ -56,7 +56,7 @@ require ( go.opentelemetry.io/otel/metric v1.19.0 // indirect go.opentelemetry.io/otel/trace v1.19.0 // indirect golang.org/x/net v0.17.0 // indirect - golang.org/x/sys v0.13.0 // indirect + golang.org/x/sys v0.14.0 // indirect golang.org/x/text v0.13.0 // indirect google.golang.org/genproto/googleapis/rpc v0.0.0-20230822172742-b8732ec3820d // indirect google.golang.org/grpc v1.59.0 // indirect diff --git a/receiver/sapnetweaverreceiver/go.sum b/receiver/sapnetweaverreceiver/go.sum index f8c337892..d578e6066 100644 --- a/receiver/sapnetweaverreceiver/go.sum +++ b/receiver/sapnetweaverreceiver/go.sum @@ -419,8 +419,8 @@ golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210603081109-ebe580a85c40/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220908164124-27713097b956/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= -golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.14.0 h1:Vz7Qs629MkJkGyHxUlRHizWJRG2j8fbQKjELVSNhy7Q= +golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20181227161524-e6919f6577db/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= diff --git a/updater/go.mod b/updater/go.mod index bf44f7c44..c071d1912 100644 --- a/updater/go.mod +++ b/updater/go.mod @@ -9,7 +9,7 @@ require ( github.com/spf13/pflag v1.0.5 github.com/stretchr/testify v1.8.4 go.uber.org/zap v1.26.0 - golang.org/x/sys v0.13.0 + golang.org/x/sys v0.14.0 ) require ( diff --git a/updater/go.sum b/updater/go.sum index a2d21dd5e..b81609a45 100644 --- a/updater/go.sum +++ b/updater/go.sum @@ -35,8 +35,8 @@ go.uber.org/multierr v1.10.0 h1:S0h4aNzvfcFsC3dRF1jLoaov7oRaKqRGC/pUEJ2yvPQ= go.uber.org/multierr v1.10.0/go.mod h1:20+QtiLqy0Nd6FdQB9TLXag12DsQkrbs3htMFfDN80Y= go.uber.org/zap v1.26.0 h1:sI7k6L95XOKS281NhVKOFCUNIvv9e0w4BF8N3u+tCRo= go.uber.org/zap v1.26.0/go.mod h1:dtElttAiwGvoJ/vj4IwHBS/gXsEu/pZ50mUIRWuG0so= -golang.org/x/sys v0.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= -golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.14.0 h1:Vz7Qs629MkJkGyHxUlRHizWJRG2j8fbQKjELVSNhy7Q= +golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw= google.golang.org/protobuf v1.28.0 h1:w43yiav+6bVFTBQFZX0r7ipe9JQ1QsbMgHwbBziscLw= From 5482ff4bd9974577aa96c9e903f5bca03299bc0b Mon Sep 17 00:00:00 2001 From: Miguel Rodriguez Date: Tue, 14 Nov 2023 11:04:30 -0500 Subject: [PATCH 6/6] feat: Add Chronicle exporter (#1331) * Add Chronicle exporter * Remove failed to from most error messages * Fix collector version * Add license * Update timestamp marshal name * Fix marshal all logs logic * Fix mapstructure tag for creds * Various fixes from google call * Doc API for regions & use it as alt endpoint * Add comment * PR Feedback - Brandon * Use expression package * Log and drop log on failing to get field * Remove dead code --- docs/exporters.md | 77 +++---- exporter/chronicleexporter/README.md | 47 ++++ exporter/chronicleexporter/config.go | 91 ++++++++ exporter/chronicleexporter/config_test.go | 97 ++++++++ exporter/chronicleexporter/doc.go | 18 ++ exporter/chronicleexporter/exporter.go | 133 +++++++++++ exporter/chronicleexporter/exporter_test.go | 199 +++++++++++++++++ exporter/chronicleexporter/factory.go | 70 ++++++ exporter/chronicleexporter/factory_test.go | 33 +++ .../internal/metadata/generated_status.go | 12 + .../internal/mocks/mock_marshaler.go | 92 ++++++++ exporter/chronicleexporter/marshal.go | 146 ++++++++++++ exporter/chronicleexporter/marshal_test.go | 208 ++++++++++++++++++ exporter/chronicleexporter/metadata.yaml | 7 + factories/exporters.go | 2 + go.mod | 1 + go.sum | 2 + 17 files changed, 1197 insertions(+), 38 deletions(-) create mode 100644 exporter/chronicleexporter/README.md create mode 100644 exporter/chronicleexporter/config.go create mode 100644 exporter/chronicleexporter/config_test.go create mode 100644 exporter/chronicleexporter/doc.go create mode 100644 exporter/chronicleexporter/exporter.go create mode 100644 exporter/chronicleexporter/exporter_test.go create mode 100644 exporter/chronicleexporter/factory.go create mode 100644 exporter/chronicleexporter/factory_test.go create mode 100644 exporter/chronicleexporter/internal/metadata/generated_status.go create mode 100644 exporter/chronicleexporter/internal/mocks/mock_marshaler.go create mode 100644 exporter/chronicleexporter/marshal.go create mode 100644 exporter/chronicleexporter/marshal_test.go create mode 100644 exporter/chronicleexporter/metadata.yaml diff --git a/docs/exporters.md b/docs/exporters.md index 5c87904a3..6233aa7ec 100644 --- a/docs/exporters.md +++ b/docs/exporters.md @@ -2,41 +2,42 @@ Below is a list of supported exporters with links to their documentation pages. -| Name | GitHub README | -| ---------------------------------------- | ------------- | -| Alibaba Cloud Log Service Exporter | [alibabacloudlogserviceexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/alibabacloudlogserviceexporter/README.md) | -| AWS CloudWatch Logs Exporter | [awscloudwatchlogsexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/awscloudwatchlogsexporter/README.md) | -| AWS CloudWatch EMF Exporter | [awsemfexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/awsemfexporter/README.md) | -| AWS Kinesis Exporter | [awskinesisexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/awskinesisexporter/README.md) | -| AWS S3 Exporter | [awss3exporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/awss3exporter/README.md) | -| AWS X-Ray Tracing Exporter | [awsxrayexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/awsxrayexporter/README.md) | -| Azure Blob Exporter | [azureblobexporter](../exporter/azureblobexporter/README.md) | -| Azure Monitor Exporter | [azuremonitorexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/azuremonitorexporter/README.md) | -| Carbon Exporter | [carbonexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/carbonexporter/README.md) | -| ClickHouse Exporter | [clickhouseexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/clickhouseexporter/README.md) | -| Coralogix Exporter | [coralogixexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/coralogixexporter/README.md) | -| Datadog Exporter | [datadogexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/datadogexporter/README.md) | -| Dynatrace Exporter | [dynatraceexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/dynatraceexporter/README.md) | -| Elasticsearch Exporter | [elasticsearchexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/elasticsearchexporter/README.md) | -| F5 Cloud Exporter | [f5cloudexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/f5cloudexporter/README.md) | -| File Exporter | [fileexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/fileexporter/README.md) | -| Google Cloud Exporter | [googlecloudexporter](../exporter/googlecloudexporter/README.md) | -| Google Cloud Pub/Sub Exporter | [googlecloudpubsubexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/googlecloudpubsubexporter/README.md) | -| Google Managed Service for Prometheus Collector Exporter | [googlemanagedprometheus](../exporter/googlemanagedprometheusexporter/README.md) | -| InfluxDB Exporter | [influxdbexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/influxdbexporter/README.md) | -| Jaeger gRPC Exporter | [jaegerexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/jaegerexporter/README.md) | -| Kafka Exporter | [kafkaexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/kafkaexporter/README.md) | -| Load-Balancing (Trace ID Aware) Exporter | [loadbalancingexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/loadbalancingexporter/README.md) | -| Logging Exporter | [loggingexporter](https://github.com/open-telemetry/opentelemetry-collector/blob/v0.88.0/exporter/loggingexporter/README.md) | -| Loki Exporter | [lokiexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/lokiexporter/README.md) | -| Logz.io Exporter | [logzioexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/logzioexporter/README.md) | -| OpenCensus gRPC Exporter | [opencensusexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/opencensusexporter/README.md) | -| OTLP gRPC Exporter | [otlpexporter](https://github.com/open-telemetry/opentelemetry-collector/blob/v0.88.0/exporter/otlpexporter/README.md) | -| OTLP HTTP Exporter | [otlphttpexporter](https://github.com/open-telemetry/opentelemetry-collector/blob/v0.88.0/exporter/otlphttpexporter/README.md) | -| Prometheus Exporter | [prometheusexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/prometheusexporter/README.md) | -| Prometheus Remote Write Exporter | [prometheusremotewriteexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/prometheusremotewriteexporter/README.md) | -| SAPM Exporter | [sapmexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/sapmexporter/README.md) | -| SignalFX Metrics Exporter | [signalfxexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/signalfxexporter/README.md) | -| Splunk HTTP Event Collector (HEC) Exporter | [splunkhecexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/splunkhecexporter/README.md) | -| Sumo Logic Exporter | [sumologic](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/sumologicexporter/README.md) | -| Zipkin Exporter | [zipkinexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/zipkinexporter/README.md) | +| Name | GitHub README | +| -------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------ | +| Alibaba Cloud Log Service Exporter | [alibabacloudlogserviceexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/alibabacloudlogserviceexporter/README.md) | +| AWS CloudWatch Logs Exporter | [awscloudwatchlogsexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/awscloudwatchlogsexporter/README.md) | +| AWS CloudWatch EMF Exporter | [awsemfexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/awsemfexporter/README.md) | +| AWS Kinesis Exporter | [awskinesisexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/awskinesisexporter/README.md) | +| AWS S3 Exporter | [awss3exporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/awss3exporter/README.md) | +| AWS X-Ray Tracing Exporter | [awsxrayexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/awsxrayexporter/README.md) | +| Azure Blob Exporter | [azureblobexporter](../exporter/azureblobexporter/README.md) | +| Azure Monitor Exporter | [azuremonitorexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/azuremonitorexporter/README.md) | +| Carbon Exporter | [carbonexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/carbonexporter/README.md) | +| Chronicle Exporter | [chronicleexporter](../exporter/chronicleexporter/README.md) | +| ClickHouse Exporter | [clickhouseexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/clickhouseexporter/README.md) | +| Coralogix Exporter | [coralogixexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/coralogixexporter/README.md) | +| Datadog Exporter | [datadogexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/datadogexporter/README.md) | +| Dynatrace Exporter | [dynatraceexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/dynatraceexporter/README.md) | +| Elasticsearch Exporter | [elasticsearchexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/elasticsearchexporter/README.md) | +| F5 Cloud Exporter | [f5cloudexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/f5cloudexporter/README.md) | +| File Exporter | [fileexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/fileexporter/README.md) | +| Google Cloud Exporter | [googlecloudexporter](../exporter/googlecloudexporter/README.md) | +| Google Cloud Pub/Sub Exporter | [googlecloudpubsubexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/googlecloudpubsubexporter/README.md) | +| Google Managed Service for Prometheus Collector Exporter | [googlemanagedprometheus](../exporter/googlemanagedprometheusexporter/README.md) | +| InfluxDB Exporter | [influxdbexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/influxdbexporter/README.md) | +| Jaeger gRPC Exporter | [jaegerexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/jaegerexporter/README.md) | +| Kafka Exporter | [kafkaexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/kafkaexporter/README.md) | +| Load-Balancing (Trace ID Aware) Exporter | [loadbalancingexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/loadbalancingexporter/README.md) | +| Logging Exporter | [loggingexporter](https://github.com/open-telemetry/opentelemetry-collector/blob/v0.88.0/exporter/loggingexporter/README.md) | +| Loki Exporter | [lokiexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/lokiexporter/README.md) | +| Logz.io Exporter | [logzioexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/logzioexporter/README.md) | +| OpenCensus gRPC Exporter | [opencensusexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/opencensusexporter/README.md) | +| OTLP gRPC Exporter | [otlpexporter](https://github.com/open-telemetry/opentelemetry-collector/blob/v0.88.0/exporter/otlpexporter/README.md) | +| OTLP HTTP Exporter | [otlphttpexporter](https://github.com/open-telemetry/opentelemetry-collector/blob/v0.88.0/exporter/otlphttpexporter/README.md) | +| Prometheus Exporter | [prometheusexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/prometheusexporter/README.md) | +| Prometheus Remote Write Exporter | [prometheusremotewriteexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/prometheusremotewriteexporter/README.md) | +| SAPM Exporter | [sapmexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/sapmexporter/README.md) | +| SignalFX Metrics Exporter | [signalfxexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/signalfxexporter/README.md) | +| Splunk HTTP Event Collector (HEC) Exporter | [splunkhecexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/splunkhecexporter/README.md) | +| Sumo Logic Exporter | [sumologic](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/sumologicexporter/README.md) | +| Zipkin Exporter | [zipkinexporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.88.0/exporter/zipkinexporter/README.md) | diff --git a/exporter/chronicleexporter/README.md b/exporter/chronicleexporter/README.md new file mode 100644 index 000000000..e4afad809 --- /dev/null +++ b/exporter/chronicleexporter/README.md @@ -0,0 +1,47 @@ +# Chronicle Exporter + +This exporter facilitates the sending of logs to Chronicle, which is a security analytics platform provided by Google. It is designed to integrate with OpenTelemetry collectors to export telemetry data such as logs to a Chronicle account. + +## Minimum Collector Versions + +- Introduced: [v1.39.0](https://github.com/observIQ/bindplane-agent/releases/tag/v1.39.0) + +## Supported Pipelines + +- Logs + +## How It Works + +1. The exporter uses the configured credentials to authenticate with the Google Cloud services. +2. It marshals logs into the format expected by Chronicle. +3. It sends the logs to the appropriate regional Chronicle endpoint. + +## Configuration + +The exporter can be configured using the following fields: + +| Field | Type | Default | Required | Description | +| ------------------ | ------ | ------- | -------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `region` | string | | `false` | The region where the data will be sent, it must be one of the predefined regions. if no region is specfied defaults to `https://malachiteingestion-pa.googleapis.com` | +| `creds_file_path` | string | | `true` | The file path to the Google credentials JSON file. | +| `creds` | string | | `true` | The Google credentials JSON. | +| `log_type` | string | | `true` | The type of log that will be sent. | +| `raw_log_field` | string | | `false` | The field name for raw logs. | +| `customer_id` | string | | `false` | The customer ID used for sending logs. | +| `sending_queue` | struct | | `false` | Configuration for the sending queue. | +| `retry_on_failure` | struct | | `false` | Configuration for retry logic on failure. | +| `timeout_settings` | struct | | `false` | Configuration for timeout settings. | + +### Regions + +Predefined regions include multiple global locations such as `Europe Multi-Region`, `Frankfurt`, `London`, `Singapore`, `Sydney`, `Tel Aviv`, `United States Multi-Region`, and `Zurich`. Each region has a specific endpoint URL. + +## Example Configuration + +```yaml +chronicle: + region: "Europe Multi-Region" + creds_file_path: "/path/to/google/creds.json" + log_type: "threat_detection" + customer_id: "customer-123" +``` diff --git a/exporter/chronicleexporter/config.go b/exporter/chronicleexporter/config.go new file mode 100644 index 000000000..c293c9e46 --- /dev/null +++ b/exporter/chronicleexporter/config.go @@ -0,0 +1,91 @@ +// Copyright observIQ, Inc. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package chronicleexporter + +import ( + "errors" + "fmt" + + "github.com/observiq/bindplane-agent/expr" + "go.opentelemetry.io/collector/component" + "go.opentelemetry.io/collector/exporter/exporterhelper" + "go.uber.org/zap" +) + +// Alternative regional endpoints for Chronicle. +// https://cloud.google.com/chronicle/docs/reference/search-api#regional_endpoints +var regions = map[string]string{ + "Europe Multi-Region": "https://europe-backstory.googleapis.com", + "Frankfurt": "https://europe-west3-backstory.googleapis.com", + "London": "http://europe-west2-backstory.googleapis.com", + "Singapore": "https://asia-southeast1-backstory.googleapis.com", + "Sydney": "https://australia-southeast1-backstory.googleapis.com", + "Tel Aviv": "https://me-west1-backstory.googleapis.com", + "United States Multi-Region": "https://united-states-backstory.googleapis.com", + "Zurich": "https://europe-west6-backstory.googleapis.com", +} + +// Config defines configuration for the Chronicle exporter. +type Config struct { + exporterhelper.TimeoutSettings `mapstructure:",squash"` // squash ensures fields are correctly decoded in embedded struct. + exporterhelper.QueueSettings `mapstructure:"sending_queue"` + exporterhelper.RetrySettings `mapstructure:"retry_on_failure"` + + // Endpoint is the URL where Chronicle data will be sent. + Region string `mapstructure:"region"` + + // CredsFilePath is the file path to the Google credentials JSON file. + CredsFilePath string `mapstructure:"creds_file_path"` + + // Creds are the Google credentials JSON file. + Creds string `mapstructure:"creds"` + + // LogType is the type of log that will be sent to Chronicle. + LogType string `mapstructure:"log_type"` + + // RawLogField is the field name that will be used to send raw logs to Chronicle. + RawLogField string `mapstructure:"raw_log_field"` + + // CustomerID is the customer ID that will be used to send logs to Chronicle. + CustomerID string `mapstructure:"customer_id"` +} + +// Validate checks if the configuration is valid. +func (cfg *Config) Validate() error { + if cfg.CredsFilePath != "" && cfg.Creds != "" { + return errors.New("can only specify creds_file_path or creds") + } + + if cfg.LogType == "" { + return errors.New("log_type is required") + } + + if cfg.Region != "" { + if _, ok := regions[cfg.Region]; !ok { + return errors.New("region is invalid") + } + } + + if cfg.RawLogField != "" { + _, err := expr.NewOTTLLogRecordExpression(cfg.RawLogField, component.TelemetrySettings{ + Logger: zap.NewNop(), + }) + if err != nil { + return fmt.Errorf("raw_log_field is invalid: %s", err) + } + } + + return nil +} diff --git a/exporter/chronicleexporter/config_test.go b/exporter/chronicleexporter/config_test.go new file mode 100644 index 000000000..cb04c4e71 --- /dev/null +++ b/exporter/chronicleexporter/config_test.go @@ -0,0 +1,97 @@ +// Copyright observIQ, Inc. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package chronicleexporter + +import ( + "testing" + + "github.com/stretchr/testify/require" +) + +func TestConfigValidate(t *testing.T) { + testCases := []struct { + desc string + config *Config + expectedErr string + }{ + { + desc: "Both creds_file_path and creds are set", + config: &Config{ + CredsFilePath: "/path/to/creds_file", + Creds: "creds_example", + Region: "United States Multi-Region", + LogType: "log_type_example", + }, + expectedErr: "can only specify creds_file_path or creds", + }, + { + desc: "LogType is empty", + config: &Config{ + Region: "United States Multi-Region", + Creds: "creds_example", + }, + expectedErr: "log_type is required", + }, + { + desc: "Region is invalid", + config: &Config{ + Region: "Invalid Region", + Creds: "creds_example", + LogType: "log_type_example", + }, + expectedErr: "region is invalid", + }, + { + desc: "Valid config with creds", + config: &Config{ + Region: "United States Multi-Region", + Creds: "creds_example", + LogType: "log_type_example", + }, + expectedErr: "", + }, + { + desc: "Valid config with creds_file_path", + config: &Config{ + Region: "United States Multi-Region", + CredsFilePath: "/path/to/creds_file", + LogType: "log_type_example", + }, + expectedErr: "", + }, + { + desc: "Valid config with raw log field", + config: &Config{ + Region: "United States Multi-Region", + CredsFilePath: "/path/to/creds_file", + LogType: "log_type_example", + RawLogField: `body["field"]`, + }, + expectedErr: "", + }, + } + + for _, tc := range testCases { + t.Run(tc.desc, func(t *testing.T) { + err := tc.config.Validate() + if tc.expectedErr == "" { + require.NoError(t, err) + } else { + require.Error(t, err) + require.Contains(t, err.Error(), tc.expectedErr) + } + }) + } +} diff --git a/exporter/chronicleexporter/doc.go b/exporter/chronicleexporter/doc.go new file mode 100644 index 000000000..7b452648f --- /dev/null +++ b/exporter/chronicleexporter/doc.go @@ -0,0 +1,18 @@ +// Copyright observIQ, Inc. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +//go:generate mdatagen metadata.yaml + +// Package chronicleexporter exports OpenTelemetry data to Chronicle. +package chronicleexporter // import "github.com/observiq/bindplane-agent/exporter/azureblobexporter" diff --git a/exporter/chronicleexporter/exporter.go b/exporter/chronicleexporter/exporter.go new file mode 100644 index 000000000..7387494f5 --- /dev/null +++ b/exporter/chronicleexporter/exporter.go @@ -0,0 +1,133 @@ +// Copyright observIQ, Inc. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package chronicleexporter + +import ( + "bytes" + "context" + "fmt" + "io" + "net/http" + "os" + + "go.opentelemetry.io/collector/consumer" + "go.opentelemetry.io/collector/exporter" + "go.opentelemetry.io/collector/pdata/plog" + "go.uber.org/zap" + "golang.org/x/oauth2" + "golang.org/x/oauth2/google" +) + +const scope = "https://www.googleapis.com/auth/malachite-ingestion" + +const baseEndpoint = "https://malachiteingestion-pa.googleapis.com" + +const apiTarget = "/v2/unstructuredlogentries:batchCreate" + +type chronicleExporter struct { + cfg *Config + logger *zap.Logger + httpClient *http.Client + marshaler logMarshaler + endpoint string +} + +func newExporter(cfg *Config, params exporter.CreateSettings) (*chronicleExporter, error) { + var creds *google.Credentials + var err error + + switch { + case cfg.Creds != "": + creds, err = google.CredentialsFromJSON(context.Background(), []byte(cfg.CredsFilePath), scope) + if err != nil { + return nil, fmt.Errorf("obtain credentials from JSON: %w", err) + } + case cfg.CredsFilePath != "": + credsData, err := os.ReadFile(cfg.CredsFilePath) + if err != nil { + return nil, fmt.Errorf("read credentials file: %w", err) + } + + creds, err = google.CredentialsFromJSON(context.Background(), credsData, scope) + if err != nil { + return nil, fmt.Errorf("obtain credentials from JSON: %w", err) + } + default: + creds, err = google.FindDefaultCredentials(context.Background(), scope) + if err != nil { + return nil, fmt.Errorf("find default credentials: %w", err) + } + } + + // Use the credentials to create an HTTP client + httpClient := oauth2.NewClient(context.Background(), creds.TokenSource) + + return &chronicleExporter{ + endpoint: buildEndpoint(cfg), + cfg: cfg, + logger: params.Logger, + httpClient: httpClient, + marshaler: newMarshaler(*cfg, params.TelemetrySettings), + }, nil +} + +// buildEndpoint builds the endpoint to send logs to based on the region. there is a default endpoint `https://malachiteingestion-pa.googleapis.com` +// but there are also regional endpoints that can be used instead. the regional endpoints are listed here: https://cloud.google.com/chronicle/docs/reference/search-api#regional_endpoints +func buildEndpoint(cfg *Config) string { + if cfg.Region != "" && regions[cfg.Region] != "" { + return fmt.Sprintf("%s%s", regions[cfg.Region], apiTarget) + } + return fmt.Sprintf("%s%s", baseEndpoint, apiTarget) +} + +func (ce *chronicleExporter) Capabilities() consumer.Capabilities { + return consumer.Capabilities{MutatesData: false} +} + +func (ce *chronicleExporter) logsDataPusher(ctx context.Context, ld plog.Logs) error { + udmData, err := ce.marshaler.MarshalRawLogs(ctx, ld) + if err != nil { + return fmt.Errorf("marshal logs: %w", err) + } + + return ce.uploadToChronicle(ctx, udmData) +} + +func (ce *chronicleExporter) uploadToChronicle(ctx context.Context, data []byte) error { + request, err := http.NewRequestWithContext(ctx, "POST", ce.endpoint, bytes.NewBuffer(data)) + if err != nil { + return fmt.Errorf("create request: %w", err) + } + + request.Header.Set("Content-Type", "application/json") + + resp, err := ce.httpClient.Do(request) + if err != nil { + return fmt.Errorf("send request to Chronicle: %w", err) + } + defer resp.Body.Close() + + if resp.StatusCode != http.StatusOK { + respBody, err := io.ReadAll(resp.Body) + if err != nil { + ce.logger.Warn("Failed to read response body", zap.Error(err)) + } else { + ce.logger.Warn("Received non-OK response from Chronicle", zap.String("status", resp.Status), zap.ByteString("body", respBody)) + } + return fmt.Errorf("received non-OK response from Chronicle: %s", resp.Status) + } + + return nil +} diff --git a/exporter/chronicleexporter/exporter_test.go b/exporter/chronicleexporter/exporter_test.go new file mode 100644 index 000000000..afd8f67d6 --- /dev/null +++ b/exporter/chronicleexporter/exporter_test.go @@ -0,0 +1,199 @@ +// Copyright observIQ, Inc. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package chronicleexporter + +import ( + "context" + "errors" + "net/http" + "testing" + + "github.com/jarcoal/httpmock" + "github.com/observiq/bindplane-agent/exporter/chronicleexporter/internal/mocks" + "github.com/stretchr/testify/mock" + "github.com/stretchr/testify/require" + "go.uber.org/zap" +) + +func TestLogsDataPusher(t *testing.T) { + // Set up configuration, logger, and context + cfg := Config{Region: "United States Multi-Region"} + ctx := context.Background() + + testCases := []struct { + desc string + setupExporter func() *chronicleExporter + setupMocks func(*chronicleExporter) + expectedErr string + }{ + { + desc: "successful push to Chronicle", + setupExporter: func() *chronicleExporter { + exporter := &chronicleExporter{ + endpoint: baseEndpoint, + cfg: &cfg, + logger: zap.NewNop(), + httpClient: http.DefaultClient, + } + httpmock.ActivateNonDefault(exporter.httpClient) + return exporter + }, + setupMocks: func(exporter *chronicleExporter) { + httpmock.RegisterResponder("POST", baseEndpoint, httpmock.NewStringResponder(http.StatusOK, "")) + + marshaller := mocks.NewMockMarshaler(t) + marshaller.On("MarshalRawLogs", mock.Anything, mock.Anything).Return([]byte("mock data"), nil) + exporter.marshaler = marshaller + }, + expectedErr: "", + }, + { + desc: "send request to Chronicle", + setupExporter: func() *chronicleExporter { + exporter := &chronicleExporter{ + endpoint: baseEndpoint, + cfg: &cfg, + logger: zap.NewNop(), + httpClient: http.DefaultClient, + } + httpmock.ActivateNonDefault(exporter.httpClient) + return exporter + }, + setupMocks: func(exporter *chronicleExporter) { + // Register a responder that returns an error to simulate sending request failure + httpmock.RegisterResponder("POST", baseEndpoint, httpmock.NewErrorResponder(errors.New("network error"))) + marshaller := mocks.NewMockMarshaler(t) + marshaller.On("MarshalRawLogs", mock.Anything, mock.Anything).Return([]byte("mock data"), nil) + exporter.marshaler = marshaller + }, + expectedErr: "send request to Chronicle", + }, + { + desc: "marshaling logs fails", + setupExporter: func() *chronicleExporter { + exporter := &chronicleExporter{ + endpoint: baseEndpoint, + cfg: &cfg, + logger: zap.NewNop(), + httpClient: http.DefaultClient, + } + httpmock.ActivateNonDefault(exporter.httpClient) + return exporter + }, + setupMocks: func(exporter *chronicleExporter) { + marshaller := mocks.NewMockMarshaler(t) + marshaller.On("MarshalRawLogs", mock.Anything, mock.Anything).Return(nil, errors.New("marshaling error")) + exporter.marshaler = marshaller + }, + expectedErr: "marshal logs", + }, + { + desc: "received non-OK response from Chronicle", + setupExporter: func() *chronicleExporter { + exporter := &chronicleExporter{ + endpoint: baseEndpoint, + cfg: &cfg, + logger: zap.NewNop(), + httpClient: http.DefaultClient, + } + httpmock.ActivateNonDefault(exporter.httpClient) + return exporter + }, + setupMocks: func(exporter *chronicleExporter) { + // Mock a non-OK HTTP response + httpmock.RegisterResponder("POST", baseEndpoint, httpmock.NewStringResponder(http.StatusInternalServerError, "Internal Server Error")) + + marshaller := mocks.NewMockMarshaler(t) + marshaller.On("MarshalRawLogs", mock.Anything, mock.Anything).Return([]byte("mock data"), nil) + exporter.marshaler = marshaller + }, + expectedErr: "received non-OK response from Chronicle: 500", + }, + } + + for _, tc := range testCases { + t.Run(tc.desc, func(t *testing.T) { + exporter := tc.setupExporter() + defer httpmock.DeactivateAndReset() + + tc.setupMocks(exporter) + + // Create a dummy plog.Logs to pass to logsDataPusher + logs := mockLogs(mockLogRecord(t, "Test body", map[string]any{"key1": "value1"})) + + err := exporter.logsDataPusher(ctx, logs) + + if tc.expectedErr == "" { + require.NoError(t, err) + } else { + require.Error(t, err) + require.Contains(t, err.Error(), tc.expectedErr) + } + + // Verify the expected number of calls were made + if tc.expectedErr == "" { + info := httpmock.GetCallCountInfo() + expectedMethod := "POST " + baseEndpoint + require.Equal(t, 1, info[expectedMethod], "Expected number of calls to %s is not met", expectedMethod) + } + }) + } +} +func TestBuildEndpoint(t *testing.T) { + testCases := []struct { + name string + cfg Config + expectedEndpoint string + }{ + { + name: "Europe Multi-Region", + cfg: Config{Region: "Europe Multi-Region"}, + expectedEndpoint: "https://europe-backstory.googleapis.com/v2/unstructuredlogentries:batchCreate", + }, + { + name: "Frankfurt", + cfg: Config{Region: "Frankfurt"}, + expectedEndpoint: "https://europe-west3-backstory.googleapis.com/v2/unstructuredlogentries:batchCreate", + }, + { + name: "London", + cfg: Config{Region: "London"}, + expectedEndpoint: "http://europe-west2-backstory.googleapis.com/v2/unstructuredlogentries:batchCreate", + }, + { + name: "Singapore", + cfg: Config{Region: "Singapore"}, + expectedEndpoint: "https://asia-southeast1-backstory.googleapis.com/v2/unstructuredlogentries:batchCreate", + }, + { + name: "default case (no region)", + cfg: Config{}, + expectedEndpoint: "https://malachiteingestion-pa.googleapis.com/v2/unstructuredlogentries:batchCreate", + }, + } + + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + endpoint := buildEndpoint(&tc.cfg) + require.Equal(t, tc.expectedEndpoint, endpoint, "Endpoint does not match for test case: %s", tc.name) + }) + } +} + +func Test_exporter_Capabilities(t *testing.T) { + exp := &chronicleExporter{} + capabilities := exp.Capabilities() + require.False(t, capabilities.MutatesData) +} diff --git a/exporter/chronicleexporter/factory.go b/exporter/chronicleexporter/factory.go new file mode 100644 index 000000000..63d939456 --- /dev/null +++ b/exporter/chronicleexporter/factory.go @@ -0,0 +1,70 @@ +// Copyright observIQ, Inc. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package chronicleexporter + +import ( + "context" + "errors" + + "github.com/observiq/bindplane-agent/exporter/chronicleexporter/internal/metadata" + "go.opentelemetry.io/collector/component" + "go.opentelemetry.io/collector/exporter" + "go.opentelemetry.io/collector/exporter/exporterhelper" +) + +// NewFactory creates a new Chronicle exporter factory. +func NewFactory() exporter.Factory { + return exporter.NewFactory( + metadata.Type, + createDefaultConfig, + exporter.WithLogs(createLogsExporter, metadata.LogsStability)) +} + +// createDefaultConfig creates the default configuration for the exporter. +func createDefaultConfig() component.Config { + return &Config{ + TimeoutSettings: exporterhelper.NewDefaultTimeoutSettings(), + QueueSettings: exporterhelper.NewDefaultQueueSettings(), + RetrySettings: exporterhelper.NewDefaultRetrySettings(), + } +} + +// createLogsExporter creates a new log exporter based on this config. +func createLogsExporter( + ctx context.Context, + params exporter.CreateSettings, + cfg component.Config, +) (exporter.Logs, error) { + chronicleCfg, ok := cfg.(*Config) + if !ok { + return nil, errors.New("invalid config type") + } + + exp, err := newExporter(chronicleCfg, params) + if err != nil { + return nil, err + } + + return exporterhelper.NewLogsExporter( + ctx, + params, + chronicleCfg, + exp.logsDataPusher, + exporterhelper.WithCapabilities(exp.Capabilities()), + exporterhelper.WithTimeout(chronicleCfg.TimeoutSettings), + exporterhelper.WithQueue(chronicleCfg.QueueSettings), + exporterhelper.WithRetry(chronicleCfg.RetrySettings), + ) +} diff --git a/exporter/chronicleexporter/factory_test.go b/exporter/chronicleexporter/factory_test.go new file mode 100644 index 000000000..1a6aa1044 --- /dev/null +++ b/exporter/chronicleexporter/factory_test.go @@ -0,0 +1,33 @@ +// Copyright observIQ, Inc. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package chronicleexporter // import "github.com/observiq/bindplane-agent/exporter/azureblobexporter" + +import ( + "testing" + + "github.com/stretchr/testify/require" + "go.opentelemetry.io/collector/exporter/exporterhelper" +) + +func Test_createDefaultConfig(t *testing.T) { + expectedCfg := &Config{ + TimeoutSettings: exporterhelper.NewDefaultTimeoutSettings(), + QueueSettings: exporterhelper.NewDefaultQueueSettings(), + RetrySettings: exporterhelper.NewDefaultRetrySettings(), + } + + actual := createDefaultConfig() + require.Equal(t, expectedCfg, actual) +} diff --git a/exporter/chronicleexporter/internal/metadata/generated_status.go b/exporter/chronicleexporter/internal/metadata/generated_status.go new file mode 100644 index 000000000..a9efef636 --- /dev/null +++ b/exporter/chronicleexporter/internal/metadata/generated_status.go @@ -0,0 +1,12 @@ +// Code generated by mdatagen. DO NOT EDIT. + +package metadata + +import ( + "go.opentelemetry.io/collector/component" +) + +const ( + Type = "chronicle" + LogsStability = component.StabilityLevelAlpha +) diff --git a/exporter/chronicleexporter/internal/mocks/mock_marshaler.go b/exporter/chronicleexporter/internal/mocks/mock_marshaler.go new file mode 100644 index 000000000..0334a5b7b --- /dev/null +++ b/exporter/chronicleexporter/internal/mocks/mock_marshaler.go @@ -0,0 +1,92 @@ +// Code generated by mockery v2.31.1. DO NOT EDIT. + +package mocks + +import ( + context "context" + + mock "github.com/stretchr/testify/mock" + plog "go.opentelemetry.io/collector/pdata/plog" +) + +// MockMarshaler is an autogenerated mock type for the logMarshaler type +type MockMarshaler struct { + mock.Mock +} + +type MockMarshaler_Expecter struct { + mock *mock.Mock +} + +func (_m *MockMarshaler) EXPECT() *MockMarshaler_Expecter { + return &MockMarshaler_Expecter{mock: &_m.Mock} +} + +// MarshalRawLogs provides a mock function with given fields: ctx, ld +func (_m *MockMarshaler) MarshalRawLogs(ctx context.Context, ld plog.Logs) ([]byte, error) { + ret := _m.Called(ctx, ld) + + var r0 []byte + var r1 error + if rf, ok := ret.Get(0).(func(context.Context, plog.Logs) ([]byte, error)); ok { + return rf(ctx, ld) + } + if rf, ok := ret.Get(0).(func(context.Context, plog.Logs) []byte); ok { + r0 = rf(ctx, ld) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).([]byte) + } + } + + if rf, ok := ret.Get(1).(func(context.Context, plog.Logs) error); ok { + r1 = rf(ctx, ld) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// MockMarshaler_MarshalRawLogs_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'MarshalRawLogs' +type MockMarshaler_MarshalRawLogs_Call struct { + *mock.Call +} + +// MarshalRawLogs is a helper method to define mock.On call +// - ctx context.Context +// - ld plog.Logs +func (_e *MockMarshaler_Expecter) MarshalRawLogs(ctx interface{}, ld interface{}) *MockMarshaler_MarshalRawLogs_Call { + return &MockMarshaler_MarshalRawLogs_Call{Call: _e.mock.On("MarshalRawLogs", ctx, ld)} +} + +func (_c *MockMarshaler_MarshalRawLogs_Call) Run(run func(ctx context.Context, ld plog.Logs)) *MockMarshaler_MarshalRawLogs_Call { + _c.Call.Run(func(args mock.Arguments) { + run(args[0].(context.Context), args[1].(plog.Logs)) + }) + return _c +} + +func (_c *MockMarshaler_MarshalRawLogs_Call) Return(_a0 []byte, _a1 error) *MockMarshaler_MarshalRawLogs_Call { + _c.Call.Return(_a0, _a1) + return _c +} + +func (_c *MockMarshaler_MarshalRawLogs_Call) RunAndReturn(run func(context.Context, plog.Logs) ([]byte, error)) *MockMarshaler_MarshalRawLogs_Call { + _c.Call.Return(run) + return _c +} + +// NewMockMarshaler creates a new instance of MockMarshaler. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. +// The first argument is typically a *testing.T value. +func NewMockMarshaler(t interface { + mock.TestingT + Cleanup(func()) +}) *MockMarshaler { + mock := &MockMarshaler{} + mock.Mock.Test(t) + + t.Cleanup(func() { mock.AssertExpectations(t) }) + + return mock +} diff --git a/exporter/chronicleexporter/marshal.go b/exporter/chronicleexporter/marshal.go new file mode 100644 index 000000000..fc77538be --- /dev/null +++ b/exporter/chronicleexporter/marshal.go @@ -0,0 +1,146 @@ +// Copyright observIQ, Inc. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package chronicleexporter + +import ( + "context" + "encoding/json" + "fmt" + "time" + + "github.com/observiq/bindplane-agent/expr" + "github.com/open-telemetry/opentelemetry-collector-contrib/pkg/ottl/contexts/ottllog" + "go.opentelemetry.io/collector/component" + "go.opentelemetry.io/collector/pdata/pcommon" + "go.opentelemetry.io/collector/pdata/plog" + "go.uber.org/zap" +) + +// marshaler is an interface for marshalling logs. +// +//go:generate mockery --name logMarshaler --output ./internal/mocks --with-expecter --filename mock_marshaler.go --structname MockMarshaler +type logMarshaler interface { + MarshalRawLogs(ctx context.Context, ld plog.Logs) ([]byte, error) +} + +type marshaler struct { + cfg Config + teleSettings component.TelemetrySettings +} + +func newMarshaler(cfg Config, teleSettings component.TelemetrySettings) *marshaler { + return &marshaler{ + cfg: cfg, + teleSettings: teleSettings, + } +} + +func (m *marshaler) MarshalRawLogs(ctx context.Context, ld plog.Logs) ([]byte, error) { + rawLogs, err := m.extractRawLogs(ctx, ld) + if err != nil { + return nil, fmt.Errorf("extract raw logs: %w", err) + } + + rawLogData := map[string]any{ + "entries": rawLogs, + "log_type": m.cfg.LogType, + } + + if m.cfg.CustomerID != "" { + rawLogData["customer_id"] = m.cfg.CustomerID + } + + return json.Marshal(rawLogData) +} + +type entry struct { + LogText string `json:"log_text"` + Timestamp string `json:"ts_rfc3339"` +} + +func (m *marshaler) extractRawLogs(ctx context.Context, ld plog.Logs) ([]entry, error) { + entries := []entry{} + + for i := 0; i < ld.ResourceLogs().Len(); i++ { + resourceLog := ld.ResourceLogs().At(i) + for j := 0; j < resourceLog.ScopeLogs().Len(); j++ { + scopeLog := resourceLog.ScopeLogs().At(j) + for k := 0; k < scopeLog.LogRecords().Len(); k++ { + logRecord := scopeLog.LogRecords().At(k) + + var rawLog string + var err error + if m.cfg.RawLogField == "" { + body := logRecord.Body().Str() + entireLogRecord := map[string]any{ + "body": body, + "attributes": logRecord.Attributes().AsRaw(), + "resource_attributes": resourceLog.Resource().Attributes().AsRaw(), + } + + bytesLogRecord, err := json.Marshal(entireLogRecord) + if err != nil { + return nil, fmt.Errorf("marshal log record: %w", err) + } + + rawLog = string(bytesLogRecord) + } else { + rawLog, err = m.getRawField(ctx, logRecord, scopeLog.Scope(), resourceLog.Resource()) + if err != nil { + m.teleSettings.Logger.Error("Error getting raw field", zap.Error(err)) + continue + } + } + + entries = append(entries, entry{ + LogText: rawLog, + Timestamp: logRecord.Timestamp().AsTime().Format(time.RFC3339Nano), + }) + } + } + } + + return entries, nil +} + +func (m *marshaler) getRawField(ctx context.Context, logRecord plog.LogRecord, scope pcommon.InstrumentationScope, resource pcommon.Resource) (string, error) { + lrExpr, err := expr.NewOTTLLogRecordExpression(m.cfg.RawLogField, m.teleSettings) + if err != nil { + return "", fmt.Errorf("raw_log_field is invalid: %s", err) + } + tCtx := ottllog.NewTransformContext(logRecord, scope, resource) + + lrExprResult, err := lrExpr.Execute(ctx, tCtx) + if err != nil { + return "", fmt.Errorf("execute log record expression: %w", err) + } + + if lrExprResult == nil { + return "", fmt.Errorf("log record expression result is nil") + } + + switch lrExprResult.(type) { + case string: + return lrExprResult.(string), nil + case pcommon.Map: + bytes, err := json.Marshal(lrExprResult.(pcommon.Map).AsRaw()) + if err != nil { + return "", fmt.Errorf("marshal log record expression result: %w", err) + } + return string(bytes), nil + } + + return "", fmt.Errorf("unsupported log record expression result type: %T", lrExprResult) +} diff --git a/exporter/chronicleexporter/marshal_test.go b/exporter/chronicleexporter/marshal_test.go new file mode 100644 index 000000000..1614012cc --- /dev/null +++ b/exporter/chronicleexporter/marshal_test.go @@ -0,0 +1,208 @@ +// Copyright observIQ, Inc. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package chronicleexporter + +import ( + "context" + "encoding/json" + "testing" + "time" + + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" + "go.opentelemetry.io/collector/component" + "go.opentelemetry.io/collector/pdata/pcommon" + "go.opentelemetry.io/collector/pdata/plog" + "go.uber.org/zap" +) + +var testTime = time.Date(2023, 1, 2, 3, 4, 5, 6, time.UTC) + +// mockLogRecord creates a simple mock plog.LogRecord for testing. +func mockLogRecord(t *testing.T, body string, attributes map[string]any) plog.LogRecord { + lr := plog.NewLogRecord() + lr.Body().SetStr(body) + lr.Attributes().EnsureCapacity(len(attributes)) + lr.SetTimestamp(pcommon.NewTimestampFromTime(testTime)) + for k, v := range attributes { + switch v.(type) { + case string: + lr.Attributes().PutStr(k, v.(string)) + case map[string]any: + lr.Attributes().FromRaw(attributes) + default: + t.Fatalf("unexpected attribute type: %T", v) + } + } + return lr +} + +// mockLogs creates mock plog.Logs with the given records. +func mockLogs(records ...plog.LogRecord) plog.Logs { + logs := plog.NewLogs() + rl := logs.ResourceLogs().AppendEmpty() + sl := rl.ScopeLogs().AppendEmpty() + for _, rec := range records { + rec.CopyTo(sl.LogRecords().AppendEmpty()) + } + return logs +} + +// mockLogRecordWithNestedBody creates a log record with a nested body structure. +func mockLogRecordWithNestedBody(body map[string]any) plog.LogRecord { + lr := plog.NewLogRecord() + lr.Body().SetEmptyMap().EnsureCapacity(len(body)) + lr.Body().Map().FromRaw(body) + return lr +} + +func TestMarshalRawLogs(t *testing.T) { + tests := []struct { + name string + logRecords []plog.LogRecord + expectedJSON string + logType string + rawLogField string + errExpected error + }{ + { + name: "Single log record", + logRecords: []plog.LogRecord{ + mockLogRecord(t, "Test body", map[string]any{"key1": "value1"}), + }, + expectedJSON: `{"customer_id":"test_customer_id","entries":[{"log_text":"Test body","ts_rfc3339":"2023-01-02T03:04:05.000000006Z"}],"log_type":"test_log_type"}`, + logType: "test_log_type", + rawLogField: "body", + }, + { + name: "Multiple log records", + logRecords: []plog.LogRecord{ + mockLogRecord(t, "First log", map[string]any{"key1": "value1"}), + mockLogRecord(t, "Second log", map[string]any{"key2": "value2"}), + }, + expectedJSON: `{"customer_id":"test_customer_id","entries":[{"log_text":"First log","ts_rfc3339":"2023-01-02T03:04:05.000000006Z"},{"log_text":"Second log","ts_rfc3339":"2023-01-02T03:04:05.000000006Z"}],"log_type":"test_log_type"}`, + logType: "test_log_type", + rawLogField: "body", + }, + { + name: "Log record with attributes", + logRecords: []plog.LogRecord{ + mockLogRecord(t, "Test body", map[string]any{"key1": "value1", "key2": "value2"}), + }, + expectedJSON: `{"customer_id":"test_customer_id","entries":[{"log_text":"{\"key1\":\"value1\",\"key2\":\"value2\"}","ts_rfc3339":"2023-01-02T03:04:05.000000006Z"}],"log_type":"test_log_type"}`, + logType: "test_log_type", + rawLogField: "attributes", + }, + { + name: "Nested rawLogField", + logRecords: []plog.LogRecord{ + mockLogRecord(t, "Test body", map[string]any{"nested": map[string]any{"key": "value"}}), + }, + expectedJSON: `{"customer_id":"test_customer_id","entries":[{"log_text":"value","ts_rfc3339":"2023-01-02T03:04:05.000000006Z"}],"log_type":"test_log_type"}`, + logType: "test_log_type", + rawLogField: `attributes["nested"]["key"]`, + }, + { + name: "Empty log record", + logRecords: []plog.LogRecord{}, + expectedJSON: `{"customer_id":"test_customer_id","entries":[],"log_type":"test_log_type"}`, + logType: "test_log_type", + rawLogField: "body", + }, + { + name: "Log record with missing field", + logRecords: []plog.LogRecord{ + mockLogRecord(t, "Test body", map[string]any{"key1": "value1"}), + }, + expectedJSON: `{"customer_id":"test_customer_id","entries":[],"log_type":"test_log_type"}`, + logType: "test_log_type", + rawLogField: `attributes["missing"]`, + // No error expected because the record will be dropped. + }, + { + name: "Nested body field", + logRecords: []plog.LogRecord{ + mockLogRecordWithNestedBody(map[string]any{ + "event": map[string]any{ + "type": "login_attempt", + "details": map[string]any{ + "username": "user123", + "ip": "192.168.1.1", + }, + }, + }), + }, + expectedJSON: `{"customer_id":"test_customer_id","entries":[{"log_text":"{\"event\":{\"details\":{\"ip\":\"192.168.1.1\",\"username\":\"user123\"},\"type\":\"login_attempt\"}}","ts_rfc3339":"1970-01-01T00:00:00Z"}],"log_type":"test_log_type"}`, + logType: "test_log_type", + rawLogField: "body", + }, + { + name: "use Nested body field", + logRecords: []plog.LogRecord{ + mockLogRecordWithNestedBody(map[string]any{ + "event": map[string]any{ + "type": "login_attempt", + "details": map[string]any{ + "username": "user123", + "ip": "192.168.1.1", + }, + }, + }), + }, + expectedJSON: `{"customer_id":"test_customer_id","entries":[{"log_text":"user123","ts_rfc3339":"1970-01-01T00:00:00Z"}],"log_type":"test_log_type"}`, + logType: "test_log_type", + rawLogField: `body["event"]["details"]["username"]`, + }, + { + name: "No rawLogField specified", + logRecords: []plog.LogRecord{ + mockLogRecord(t, "Test log without raw field", map[string]any{"key1": "value1"}), + }, + expectedJSON: `{"customer_id":"test_customer_id","entries":[{"log_text":"{\"attributes\":{\"key1\":\"value1\"},\"body\":\"Test log without raw field\",\"resource_attributes\":{}}","ts_rfc3339":"2023-01-02T03:04:05.000000006Z"}],"log_type":"test_log_type"}`, + logType: "test_log_type", + rawLogField: "", // No rawLogField specified + }, + } + + for _, tt := range tests { + t.Run(tt.name, func(t *testing.T) { + cfg := &Config{LogType: tt.logType, RawLogField: tt.rawLogField, CustomerID: "test_customer_id"} + ce := &chronicleExporter{ + cfg: cfg, + logger: zap.NewNop(), + marshaler: &marshaler{cfg: *cfg, teleSettings: component.TelemetrySettings{Logger: zap.NewNop()}}, + } + + logs := mockLogs(tt.logRecords...) + result, err := ce.marshaler.MarshalRawLogs(context.Background(), logs) + if tt.errExpected != nil { + require.Error(t, err, "MarshalRawLogs should return an error") + return + } + + require.NoError(t, err, "MarshalRawLogs should not return an error") + + var resultJSON map[string]interface{} + err = json.Unmarshal(result, &resultJSON) + require.NoError(t, err, "Unmarshalling result should not produce an error") + + var expectedJSON map[string]interface{} + err = json.Unmarshal([]byte(tt.expectedJSON), &expectedJSON) + require.NoError(t, err, "Unmarshalling expected JSON should not produce an error") + + assert.Equal(t, tt.expectedJSON, string(result), "Marshalled JSON should match expected JSON") + }) + } +} diff --git a/exporter/chronicleexporter/metadata.yaml b/exporter/chronicleexporter/metadata.yaml new file mode 100644 index 000000000..ee14f6f0c --- /dev/null +++ b/exporter/chronicleexporter/metadata.yaml @@ -0,0 +1,7 @@ +type: chronicle + +status: + class: exporter + stability: + alpha: [logs] + distributions: [observiq] diff --git a/factories/exporters.go b/factories/exporters.go index 7b7f2ce1d..df8327136 100644 --- a/factories/exporters.go +++ b/factories/exporters.go @@ -16,6 +16,7 @@ package factories import ( "github.com/observiq/bindplane-agent/exporter/azureblobexporter" + "github.com/observiq/bindplane-agent/exporter/chronicleexporter" "github.com/observiq/bindplane-agent/exporter/googlecloudexporter" "github.com/observiq/bindplane-agent/exporter/googlemanagedprometheusexporter" "github.com/observiq/bindplane-agent/internal/version" @@ -66,6 +67,7 @@ var defaultExporters = []exporter.Factory{ azureblobexporter.NewFactory(), azuremonitorexporter.NewFactory(), carbonexporter.NewFactory(), + chronicleexporter.NewFactory(), clickhouseexporter.NewFactory(), coralogixexporter.NewFactory(), datadogexporter.NewFactory(), diff --git a/go.mod b/go.mod index 4b93fcb18..796e50e4d 100644 --- a/go.mod +++ b/go.mod @@ -460,6 +460,7 @@ require ( github.com/influxdata/line-protocol/v2 v2.2.1 // indirect github.com/ionos-cloud/sdk-go/v6 v6.1.8 // indirect github.com/jaegertracing/jaeger v1.48.0 // indirect + github.com/jarcoal/httpmock v1.3.1 github.com/jcmturner/aescts/v2 v2.0.0 // indirect github.com/jcmturner/dnsutils/v2 v2.0.0 // indirect github.com/jcmturner/gofork v1.7.6 // indirect diff --git a/go.sum b/go.sum index 89147bf21..dca74dca3 100644 --- a/go.sum +++ b/go.sum @@ -902,6 +902,8 @@ github.com/ionos-cloud/sdk-go/v6 v6.1.8/go.mod h1:EzEgRIDxBELvfoa/uBN0kOQaqovLjU github.com/jaegertracing/jaeger v1.48.0 h1:YuKooQ7qJsjgxws9xuf8C/BLNTPx8qTAJz4wv7IHhSc= github.com/jaegertracing/jaeger v1.48.0/go.mod h1:BoAPkdCAIEuLsVz/EDhjXd+GSVpHtJhiGqWoFEvBCKg= github.com/jarcoal/httpmock v1.3.0 h1:2RJ8GP0IIaWwcC9Fp2BmVi8Kog3v2Hn7VXM3fTd+nuc= +github.com/jarcoal/httpmock v1.3.1 h1:iUx3whfZWVf3jT01hQTO/Eo5sAYtB2/rqaUuOtpInww= +github.com/jarcoal/httpmock v1.3.1/go.mod h1:3yb8rc4BI7TCBhFY8ng0gjuLKJNquuDNiPaZjnENuYg= github.com/jcmturner/aescts/v2 v2.0.0 h1:9YKLH6ey7H4eDBXW8khjYslgyqG2xZikXP0EQFKrle8= github.com/jcmturner/aescts/v2 v2.0.0/go.mod h1:AiaICIRyfYg35RUkr8yESTqvSy7csK90qZ5xfvvsoNs= github.com/jcmturner/dnsutils/v2 v2.0.0 h1:lltnkeZGL0wILNvrNiVCR6Ro5PGU/SeBvVO/8c/iPbo=