open-telemetry / opentelemetry-java-examples

https://opentelemetry.io
Apache License 2.0
215 stars 126 forks source link

The log-appender module is not working properly #474

Closed qy-liuhuo closed 1 month ago

qy-liuhuo commented 2 months ago

The log-appender module does not function properly when using opentelemetry-collector-contrib:0.107.0, as evidenced by:

The docker container cannot receive log messages reported by the application.

I think the following container's logs are helpful in resolving the issue:

localhostgate/featuregate.go:63 The default endpoints for all servers in components have changed to use localhost instead of 0.0.0.0. Disable the feature gate to temporarily revert to the previous default.   {"feature gate ID": "component.UseLocalHostAsDefaultHost"}

Problem fixed when I lowered the mirror version to 0.66.0 just change the otel-config.yaml as follow:

version: '3'
services:
  collector:
    image: otel/opentelemetry-collector-contrib:0.66.0
    volumes:
      - ./otel-config.yaml:/otel-config.yaml
    command: ["--config=/otel-config.yaml"]
    ports:
      - "4317:4317"
qy-liuhuo commented 2 months ago

I found a related issue in the opentelemetry-collector-contrib project:

feature gate -The default endpoints for all servers in components have changed to use localhost instead of 0.0.0.0. #34394

jaydeluca commented 1 month ago

fixed by #475