Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

frequently prints startup error messages #32213

Closed
mike9421 opened this issue Apr 7, 2024 · 3 comments
Closed

frequently prints startup error messages #32213

mike9421 opened this issue Apr 7, 2024 · 3 comments
Labels
bug Something isn't working cmd/opampsupervisor

Comments

@mike9421
Copy link

mike9421 commented Apr 7, 2024

Component(s)

cmd/opampsupervisor

What happened?

Description

When I input incorrect OTEL configurations in the remote configuration, opampsupervisor frequently prints restart error messages instead of printing according to the restartTimer settings. As shown in the picture below:

image

Steps to Reproduce

  1. Fill in the correct configuration to ensure that the opampsupervisor can connect to the backend normally
  2. Start the backend OpAMP sample server
  3. Start opampsupervisor
  4. Providing incorrect remote configurations via the OpAMP UI.
  5. View the stdout of opampsupervisor

Expected Result

Printing error messages according to the time set by the restartTimer.

Actual Result

Continuously printing error messages.

Collector version

all

Environment information

OS: Darwin
Compiler: go 1.21

OpenTelemetry Collector configuration

Any wrong configuration, for example:

exporters:
    logging: null
extensions:
    health_check:
        endpoint: 0.0.0.0:13133
receivers:
    otlp:
        protocols:
            https:
                endpoint: localhost:64509
service:
    extensions:
        - health_check
    pipelines:
        logs:
            exporters:
                - logging
            receivers:
                - otlp

Log output

2024-04-07T17:25:08.990+0800    DEBUG   supervisor/supervisor.go:758    Agent process exited unexpectedly. Will restart in a bit...     {"pid": 19071, "exit_code": 1}
2024-04-07T17:25:08.991+0800    DEBUG   supervisor/supervisor.go:758    Agent process exited unexpectedly. Will restart in a bit...     {"pid": 19071, "exit_code": 1}
2024-04-07T17:25:08.991+0800    DEBUG   supervisor/supervisor.go:758    Agent process exited unexpectedly. Will restart in a bit...     {"pid": 19071, "exit_code": 1}
2024-04-07T17:25:08.991+0800    DEBUG   supervisor/supervisor.go:758    Agent process exited unexpectedly. Will restart in a bit...     {"pid": 19071, "exit_code": 1}
2024-04-07T17:25:08.991+0800    DEBUG   supervisor/supervisor.go:758    Agent process exited unexpectedly. Will restart in a bit...     {"pid": 19071, "exit_code": 1}
2024-04-07T17:25:08.991+0800    DEBUG   supervisor/supervisor.go:758    Agent process exited unexpectedly. Will restart in a bit...     {"pid": 19071, "exit_code": 1}
2024-04-07T17:25:08.991+0800    DEBUG   supervisor/supervisor.go:758    Agent process exited unexpectedly. Will restart in a bit...     {"pid": 19071, "exit_code": 1}
2024-04-07T17:25:08.991+0800    DEBUG   supervisor/supervisor.go:758    Agent process exited unexpectedly. Will restart in a bit...     {"pid": 19071, "exit_code": 1}
2024-04-07T17:25:08.992+0800    DEBUG   supervisor/supervisor.go:758    Agent process exited unexpectedly. Will restart in a bit...     {"pid": 19071, "exit_code": 1}
2024-04-07T17:25:08.992+0800    DEBUG   supervisor/supervisor.go:758    Agent process exited unexpectedly. Will restart in a bit...     {"pid": 19071, "exit_code": 1}
2024-04-07T17:25:08.992+0800    DEBUG   supervisor/supervisor.go:758    Agent process exited unexpectedly. Will restart in a bit...     {"pid": 19071, "exit_code": 1}
2024-04-07T17:25:08.992+0800    DEBUG   supervisor/supervisor.go:758    Agent process exited unexpectedly. Will restart in a bit...     {"pid": 19071, "exit_code": 1}
2024-04-07T17:25:08.992+0800    DEBUG   supervisor/supervisor.go:758    Agent process exited unexpectedly. Will restart in a bit...     {"pid": 19071, "exit_code": 1}
2024-04-07T17:25:08.992+0800    DEBUG   supervisor/supervisor.go:758    Agent process exited unexpectedly. Will restart in a bit...     {"pid": 19071, "exit_code": 1}
2024-04-07T17:25:08.993+0800    DEBUG   supervisor/supervisor.go:758    Agent process exited unexpectedly. Will restart in a bit...     {"pid": 19071, "exit_code": 1}
2024-04-07T17:25:08.993+0800    DEBUG   supervisor/supervisor.go:758    Agent process exited unexpectedly. Will restart in a bit...     {"pid": 19071, "exit_code": 1}
2024-04-07T17:25:08.993+0800    DEBUG   supervisor/supervisor.go:758    Agent process exited unexpectedly. Will restart in a bit...     {"pid": 19071, "exit_code": 1}
2024-04-07T17:25:08.993+0800    DEBUG   supervisor/supervisor.go:758    Agent process exited unexpectedly. Will restart in a bit...     {"pid": 19071, "exit_code": 1}
2024-04-07T17:25:08.993+0800    DEBUG   supervisor/supervisor.go:758    Agent process exited unexpectedly. Will restart in a bit...     {"pid": 19071, "exit_code": 1}
2024-04-07T17:25:08.993+0800    DEBUG   supervisor/supervisor.go:758    Agent process exited unexpectedly. Will restart in a bit...     {"pid": 19071, "exit_code": 1}

Additional context

Frequently printing error messages is due to the problem of source code, which can be solved by changing it to c.doneCh <- struct{}{}.

But I don't know why to use close(c.doneCh), is there any other consideration?

@mike9421 mike9421 added bug Something isn't working needs triage New item requiring triage labels Apr 7, 2024
Copy link
Contributor

github-actions bot commented Apr 7, 2024

Pinging code owners:

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

@srikanthccv
Copy link
Member

This is a duplicate of #27891. Will be fixed by #32150

@JaredTan95 JaredTan95 removed the needs triage New item requiring triage label Apr 7, 2024
@crobert-1
Copy link
Member

crobert-1 commented Apr 8, 2024

Closing as duplicate, thanks for filing @mike9421!

@crobert-1 crobert-1 closed this as not planned Won't fix, can't repro, duplicate, stale Apr 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working cmd/opampsupervisor
Projects
None yet
Development

No branches or pull requests

4 participants