open-telemetry / opentelemetry-collector-contrib

Contrib repository for the OpenTelemetry Collector
https://opentelemetry.io
Apache License 2.0
2.88k stars 2.25k forks source link

[sqlquery]: Command invoked during init statement #32420

Open MovieStoreGuy opened 4 months ago

MovieStoreGuy commented 4 months ago

Component(s)

receiver/sqlquery

What happened?

Description

On invocation of the binary, the function https://github.com/snowflakedb/gosnowflake/blob/3b14581d78684b783c0b2c86ae5873cf338fdec4/driver.go#L70 is called which can cause lock contention within the kernel if binary is invoked frequently enough. (Ie, via a docker health command.

Steps to Reproduce

# Err Message
level=warning msg=\"DBUS_SESSION_BUS_ADDRESS envvar looks to be not set, this can lead to runaway dbus-daemon processes. To avoid this, set envvar DBUS_SESSION_BUS_ADDRESS=$XDG_RUNTIME_DIR/bus (if it exists) or DBUS_SESSION_BUS_ADDRESS=/dev/null.\" func=\"gosnowflake.(*defaultLogger).Warn\" file=\"log.go:228\"\nPassed healthcheck\n

Expected Result

Ideally not having this error reported or function invoked.

Actual Result

High amount of invoked called to dbus

Collector version

v0.97.0

Environment information

Environment

Compiler: v1.21.2 + cgo

github-actions[bot] commented 4 months ago

Pinging code owners:

See Adding Labels via Comments if you do not have permissions to add labels yourself.

MovieStoreGuy commented 4 months ago

The ideal situation is that the upstream dep moves their init function to an optional watchdog process that can called manually by the service.

crobert-1 commented 4 months ago

Thanks for filing @MovieStoreGuy! Looks like this is https://github.com/99designs/keyring/issues/103 and https://github.com/snowflakedb/gosnowflake/issues/773. Unfortunately from those issues it looks like there's nothing that can be done on our side at this time, from what I understand. I'll leave it open though in case others run into this issue and someone has an idea on how to resolve. 👍

crobert-1 commented 4 months ago

Note that this is not a sqlquery receiver issue alone, but also impacts the Snowflake receiver, Pulsar receiver, and docsgen and configschema packages as well, if not more.

github-actions[bot] commented 2 months ago

This issue has been inactive for 60 days. It will be closed in 60 days if there is no activity. To ping code owners by adding a component label, see Adding Labels via Comments, or if you are unsure of which component this issue relates to, please ping @open-telemetry/collector-contrib-triagers. If this issue is still relevant, please ping the code owners or leave a comment explaining why it is still relevant. Otherwise, please close it.

Pinging code owners:

See Adding Labels via Comments if you do not have permissions to add labels yourself.

github-actions[bot] commented 2 weeks ago

This issue has been inactive for 60 days. It will be closed in 60 days if there is no activity. To ping code owners by adding a component label, see Adding Labels via Comments, or if you are unsure of which component this issue relates to, please ping @open-telemetry/collector-contrib-triagers. If this issue is still relevant, please ping the code owners or leave a comment explaining why it is still relevant. Otherwise, please close it.

Pinging code owners:

See Adding Labels via Comments if you do not have permissions to add labels yourself.