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

[cmd/opampsupervisor]: Move start logic into separate "Start" function #34380

Closed
BinaryFissionGames opened this issue Aug 1, 2024 · 4 comments
Assignees
Labels

Comments

@BinaryFissionGames
Copy link
Contributor

Component(s)

cmd/opampsupervisor

Describe the issue you're reporting

NewSupervisor currently constructs the supervisor object and additionally starts the supervision processes (e.g. it bootstraps, starts the collector, connects to opamp server).

Instead, NewSupervisor should simply construct the Supervisor object, and the actual supervision process should happen on "Start".

This would help with unit testing, where we currently manually construct supervisor objects, leading to failures in unit tests in some PRs where logic is updated to access a field that wasn't initialized properly.

@BinaryFissionGames BinaryFissionGames added the needs triage New item requiring triage label Aug 1, 2024
Copy link
Contributor

github-actions bot commented Aug 1, 2024

Pinging code owners:

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

@crobert-1 crobert-1 added enhancement New feature or request and removed needs triage New item requiring triage labels Aug 1, 2024
@crobert-1
Copy link
Member

Removed needs triage as this makes sense to me and was filed by a code owner.

@odubajDT
Copy link
Contributor

odubajDT commented Aug 8, 2024

Hi, I would like to take this ticket @crobert-1

evan-bradley pushed a commit that referenced this issue Aug 8, 2024
…te Start() function (#34509)

**Link to tracking Issue:** #34380

Signed-off-by: odubajDT <ondrej.dubaj@dynatrace.com>
@BinaryFissionGames
Copy link
Contributor Author

Resolved via #34509

f7o pushed a commit to f7o/opentelemetry-collector-contrib that referenced this issue Sep 12, 2024
…te Start() function (open-telemetry#34509)

**Link to tracking Issue:** open-telemetry#34380

Signed-off-by: odubajDT <ondrej.dubaj@dynatrace.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants