Skip to content

Commit

Permalink
Add OTel go sql statement
Browse files Browse the repository at this point in the history
  • Loading branch information
dineshg13 committed Oct 15, 2023
1 parent 2f206d9 commit 09049d7
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/bare-metal.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
IMG=otel-go-instrumentation:latest make docker-build
- name: run auto-instrumentation
run: |
docker run -d -e OTEL_EXPORTER_OTLP_ENDPOINT="http://172.17.0.1:4317" --privileged --pid=host otel-go-instrumentation
docker run -d -e OTEL_EXPORTER_OTLP_ENDPOINT="http://172.17.0.1:4317" -e OTEL_GO_AUTO_INCLUDE_DB_STATEMENT=true --privileged --pid=host otel-go-instrumentation
- name: Build sample app
run: |
cd internal/test/e2e/${{ matrix.library }}
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/e2e/k8s/deployment/sample-job.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,8 @@ spec:
value: "http://test-opentelemetry-collector:4317"
- name: OTEL_PROPAGATORS
value: "tracecontext,baggage"
- name: OTEL_GO_AUTO_INCLUDE_DB_STATEMENT
value: "true"
resources: {}
securityContext:
runAsUser: 0
Expand Down
1 change: 1 addition & 0 deletions internal/pkg/orchestrator/orchestrator.go
Original file line number Diff line number Diff line change
Expand Up @@ -205,6 +205,7 @@ func (s *Service) findProcess() {
// couldn't determine serviceName
// pid wouldn't monitored
if serviceName == "" {
log.Logger.Info("Ignoring pid as serviceName isn't set", "pid", p)
continue
}

Expand Down

0 comments on commit 09049d7

Please sign in to comment.