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

Handle possible nil in profiling config #4075

Merged
merged 1 commit into from
Nov 20, 2023

Conversation

adrien-f
Copy link
Contributor

@adrien-f adrien-f commented Nov 9, 2023

Hello!

I've been bitten by this panic:

goroutine 276 [running]:
github.com/parca-dev/parca/pkg/scrape.LabelsByProfiles(0x4007237d58?, 0x39bdb00?)
	github.com/parca-dev/parca/pkg/scrape/target.go:233 +0x120
github.com/parca-dev/parca/pkg/scrape.targetsFromGroup(0x400f5b6ea0, 0x400187c420, {0x0?, 0x46e?, 0x500?}, 0x4007237f10)
	github.com/parca-dev/parca/pkg/scrape/target.go:370 +0x158
github.com/parca-dev/parca/pkg/scrape.(*scrapePool).Sync(0x400ffa0b40, {0x40078ba000, 0x46e, 0x40073a8e40?})
	github.com/parca-dev/parca/pkg/scrape/scrape.go:218 +0x228
github.com/parca-dev/parca/pkg/scrape.(*Manager).reload.func1(0x0?, {0x40078ba000?, 0x4001880a90?, 0x4000fa8160?})
	github.com/parca-dev/parca/pkg/scrape/manager.go:217 +0x28
created by github.com/parca-dev/parca/pkg/scrape.(*Manager).reload in goroutine 62
	github.com/parca-dev/parca/pkg/scrape/manager.go:216 +0x1c4

while having a config file with a custom pprof:

scrape_configs:
      - job_name: kubernetes-nodejs
        scrape_interval: 60s
        scrape_timeout: 70s
        profiling_config:
          pprof_config:
            allocs:
              enabled: false
            block:
              enabled: false
            cpu:
              path: /api/debug/pprof/profile
            memory:
              enabled: false
            mutex:
              enabled: false
      ...

I think Go will short-circuit the condition and not evaluate the right expression right?

@adrien-f adrien-f requested a review from a team as a code owner November 9, 2023 14:15
@CLAassistant
Copy link

CLAassistant commented Nov 9, 2023

CLA assistant check
All committers have signed the CLA.

@adrien-f
Copy link
Contributor Author

Hello @metalmatze , do you know what's happening with the CI?

  /usr/bin/docker pull quay.io/containers/podman:v4.7.2@sha256:15a3734034751edd5615f6324e10029c04089bdcb9d161c35e9fd20b08aa9748
  Error response from daemon: manifest for quay.io/containers/podman@sha256:15a3734034751edd5615f6324e10029c04089bdcb9d161c35e9fd20b08aa9748 not found: manifest unknown: manifest unknown
  Error: Docker pull failed with exit code 1

Anything I need to pull/rebase?

@brancz
Copy link
Member

brancz commented Nov 16, 2023

Apologies for this, unfortunately the podman team keeps deleting container images all the time. Can you rebase this again? It was just updated on main a couple of hours ago.

@brancz brancz merged commit 642df23 into parca-dev:main Nov 20, 2023
33 of 34 checks passed
@brancz
Copy link
Member

brancz commented Nov 20, 2023

Thank you!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants