Skip to content

can not build collector with datadog exporter on  #23425

Closed
@cforce

Description

Component(s)

exporter/datadog

What happened?

Description

Building custom collector distro based upon

dist:
  name: xxx
  description: xxx
  version: "0.1.0"
  otelcol_version: "0.79.0"
  module: gitlab.com/xx/xx/xxx
  include_core: true
  output_path: ../bin
  debug_compilation: false

receivers:
  - gomod: github.com/open-telemetry/opentelemetry-collector-contrib/receiver/hostmetricsreceiver v0.79.0 # beta
processors:
  - gomod: github.com/open-telemetry/opentelemetry-collector-contrib/processor/attributesprocessor v0.79.0 # beta
  - gomod: github.com/open-telemetry/opentelemetry-collector-contrib/processor/resourcedetectionprocessor v0.79.0 # stable           
exporters:
  - gomod: github.com/open-telemetry/opentelemetry-collector-contrib/exporter/datadogexporter v0.79.0 # stable
  - gomod: github.com/open-telemetry/opentelemetry-collector-contrib/exporter/awscloudwatchlogsexporter v0.79.0 # beta    
connectors:
  # get metrics about the  collector traces by connecting trace exporter to metric receiver producing trace collector metrics
  - gomod: github.com/open-telemetry/opentelemetry-collector-contrib/connector/spanmetricsconnector v0.78.0 # alpha
extensions:
  #- gomod: github.com/open-telemetry/opentelemetry-collector/extension/zpagesextension v0.79.0 # stable
  #- gomod: github.com/open-telemetry/opentelemetry-collector/extension/ballastextension v0.79.0 # beta

Steps to Reproduce

unset GO_DYNLINK
env CGO_CXXFLAGS_SOVD="-std=c++17 -D_FORTIFY_SOURCE=2 -fstack-protector-strong -fPIE -pie -O2"
CGO_LDFLAGS_SOVD="-ldlt -Wl,-z,relro,-z,now"
GOOS=linux
GOARCH=$ARCH
CGO_ENABLED=0
GOWORK=off
builder --config=$BUILDER_FILE

Expected Result

compiles

Actual Result

compile errors

Collector version

v0.79.0

Environment information

Environment

OS: Ubuntu 20.04
Compiler:go 1.20.2

OpenTelemetry Collector configuration

No response

Log output

gitlab.com/xx/xx/xxx imports
	github.com/open-telemetry/opentelemetry-collector-contrib/exporter/datadogexporter tested by
	github.com/open-telemetry/opentelemetry-collector-contrib/exporter/datadogexporter.test imports
	go.opentelemetry.io/collector/receiver/otlpreceiver imports
	google.golang.org/genproto/googleapis/rpc/status: ambiguous import: found package google.golang.org/genproto/googleapis/rpc/status in multiple modules:
	google.golang.org/genproto v0.0.0-20230410155749-daa745c078e1 (/root/go/pkg/mod/google.golang.org/genproto@v0.0.0-20230410155749-daa745c078e1/googleapis/rpc/status)
	google.golang.org/genproto/googleapis/rpc v0.0.0-20230530153820-e85fd2cbaebc (/root/go/pkg/mod/google.golang.org/genproto/googleapis/rpc@v0.0.0-20230530153820-e85fd2cbaebc/status)
gitlab.com/xx/xx/xxx imports
	github.com/open-telemetry/opentelemetry-collector-contrib/connector/spanmetricsconnector imports
	go.opentelemetry.io/collector/pdata/pmetric imports
	go.opentelemetry.io/collector/pdata/internal/data/protogen/collector/metrics/v1 imports
	google.golang.org/grpc/codes tested by
	google.golang.org/grpc/codes.test imports
	google.golang.org/genproto/googleapis/rpc/code: ambiguous import: found package google.golang.org/genproto/googleapis/rpc/code in multiple modules:
	google.golang.org/genproto v0.0.0-20230410155749-daa745c078e1 (/root/go/pkg/mod/google.golang.org/genproto@v0.0.0-20230410155749-daa745c078e1/googleapis/rpc/code)
	google.golang.org/genproto/googleapis/rpc v0.0.0-20230530153820-e85fd2cbaebc (/root/go/pkg/mod/google.golang.org/genproto/googleapis/rpc@v0.0.0-20230530153820-e85fd2cbaebc/code)
gitlab.com/xx/xx/xxx imports
	github.com/open-telemetry/opentelemetry-collector-contrib/connector/spanmetricsconnector imports
	go.opentelemetry.io/collector/pdata/pmetric imports
	go.opentelemetry.io/collector/pdata/internal/data/protogen/collector/metrics/v1 imports
	google.golang.org/grpc/status tested by
	google.golang.org/grpc/status.test imports
	google.golang.org/genproto/googleapis/rpc/errdetails: ambiguous import: found package google.golang.org/genproto/googleapis/rpc/errdetails in multiple modules:
	google.golang.org/genproto v0.0.0-20230410155749-daa745c078e1 (/root/go/pkg/mod/google.golang.org/genproto@v0.0.0-20230410155749-daa745c078e1/googleapis/rpc/errdetails)
	google.golang.org/genproto/googleapis/rpc v0.0.0-20230530153820-e85fd2cbaebc (/root/go/pkg/mod/google.golang.org/genproto/googleapis/rpc@v0.0.0-20230530153820-e85fd2cbaebc/errdetails)

Additional context

No response

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions