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

Add initial pyroscope java pipeline #38

Merged
merged 45 commits into from
Jan 3, 2024
Merged

Add initial pyroscope java pipeline #38

merged 45 commits into from
Jan 3, 2024

Conversation

tomershafir
Copy link
Collaborator

No description provided.

@tomershafir tomershafir changed the title Add initial pyroscope receiver Add initial pyroscope java pipeline Dec 24, 2023
@akvlad
Copy link
Collaborator

akvlad commented Jan 2, 2024

@tomershafir
I'm currently running the collector pipeline. During the runs I encounter some exceptions.
I'll paste the messages here so they don't get lost.

  • panic: runtime error: index out of range [0] with length 0
panic: runtime error: index out of range [0] with length 0

goroutine 166 [running]:
go.opentelemetry.io/collector/pdata/plog.LogRecordSlice.At(...)
        /go/pkg/mod/go.opentelemetry.io/collector/[email protected]/plog/generated_logrecordslice.go:56
github.com/metrico/otel-collector/exporter/clickhouseprofileexporter/ch.(*clickhouseAccessNativeColumnar).InsertBatch(0xc0021c1748?, {0xc002200018?, 0xc0000150a8?})
        /otel-collector-qryn/exporter/clickhouseprofileexporter/ch/access_native_columnar.go:71 +0xdaf
github.com/metrico/otel-collector/exporter/clickhouseprofileexporter.(*clickhouseProfileExporter).send(0xc001c7ed80, {0x7a88060, 0xc001d93490}, {0xc002200018?, 0xc0000150a8?})
        /otel-collector-qryn/exporter/clickhouseprofileexporter/exporter.go:66 +0xf1
go.opentelemetry.io/collector/exporter/exporterhelper.(*logsRequest).Export(0x7a87fb8?, {0x7a88060?, 0xc001d93490?})
        /go/pkg/mod/go.opentelemetry.io/collector/[email protected]/exporterhelper/logs.go:58 +0x31
go.opentelemetry.io/collector/exporter/exporterhelper.(*timeoutSender).send(0xc0021a4880?, {0x7a87fb8?, 0xc001f8aa20?}, {0x7a474f0?, 0xc002200138?})
        /go/pkg/mod/go.opentelemetry.io/collector/[email protected]/exporterhelper/timeout_sender.go:38 +0x98
go.opentelemetry.io/collector/exporter/exporterhelper.(*retrySender).send(0xc000174160, {0x7a87fb8, 0xc001f8aa20}, {0x7a474f0, 0xc002200138})
        /go/pkg/mod/go.opentelemetry.io/collector/[email protected]/exporterhelper/retry_sender.go:128 +0x41f
go.opentelemetry.io/collector/exporter/exporterhelper.(*logsExporterWithObservability).send(0xc001c9f8c0, {0x7a88338?, 0xc00219e3b0?}, {0x7a474f0?, 0xc002200138?})
        /go/pkg/mod/go.opentelemetry.io/collector/[email protected]/exporterhelper/logs.go:173 +0x7e
go.opentelemetry.io/collector/exporter/exporterhelper.(*queueSender).Start.func1({{0x5ff2dc0, 0xc002200138}, {0x7a88338, 0xc00219e3b0}, 0x0})
        /go/pkg/mod/go.opentelemetry.io/collector/[email protected]/exporterhelper/queue_sender.go:141 +0x7a
go.opentelemetry.io/collector/exporter/exporterhelper/internal.(*boundedMemoryQueue).Start.func1()
        /go/pkg/mod/go.opentelemetry.io/collector/[email protected]/exporterhelper/internal/bounded_memory_queue.go:46 +0x108
created by go.opentelemetry.io/collector/exporter/exporterhelper/internal.(*boundedMemoryQueue).Start in goroutine 1
        /go/pkg/mod/go.opentelemetry.io/collector/[email protected]/exporterhelper/internal/bounded_memory_queue.go:42 +0x55
  • failed to insert batch: [clickhouse [AppendRow]: converting uint8 to Tuple(String, String) is unsupported]
2024-01-02T18:04:11.096+0200    error   clickhouseprofileexporter/exporter.go:68        failed to insert batch: [clickhouse [AppendRow]: converting uint8 to Tuple(String, String) is unsupported]      {"kind": "exporter", "data_type": "logs", "name": "clickhouseprofileexporter"}
github.com/metrico/otel-collector/exporter/clickhouseprofileexporter.(*clickhouseProfileExporter).send
        /otel-collector-qryn/exporter/clickhouseprofileexporter/exporter.go:68
go.opentelemetry.io/collector/exporter/exporterhelper.(*logsRequest).Export
        /go/pkg/mod/go.opentelemetry.io/collector/[email protected]/exporterhelper/logs.go:58
go.opentelemetry.io/collector/exporter/exporterhelper.(*timeoutSender).send
        /go/pkg/mod/go.opentelemetry.io/collector/[email protected]/exporterhelper/timeout_sender.go:38
go.opentelemetry.io/collector/exporter/exporterhelper.(*retrySender).send
        /go/pkg/mod/go.opentelemetry.io/collector/[email protected]/exporterhelper/retry_sender.go:128
go.opentelemetry.io/collector/exporter/exporterhelper.(*logsExporterWithObservability).send
        /go/pkg/mod/go.opentelemetry.io/collector/[email protected]/exporterhelper/logs.go:173
go.opentelemetry.io/collector/exporter/exporterhelper.(*queueSender).Start.func1
        /go/pkg/mod/go.opentelemetry.io/collector/[email protected]/exporterhelper/queue_sender.go:141
go.opentelemetry.io/collector/exporter/exporterhelper/internal.(*boundedMemoryQueue).Start.func1
        /go/pkg/mod/go.opentelemetry.io/collector/[email protected]/exporterhelper/internal/bounded_memory_queue.go:46

@tomershafir
Copy link
Collaborator Author

@akvlad I patched a fix to receive 0 parsed profiles gracefully. Your app is probably not doing enough for async-profiler to record it. Can you try: clone pyroscope-java, tweak the "app" service in ./example/docker-compose-expt.yml by changing a line to - PYROSCOPE_SERVER_ADDRESS=http://host.docker.internal:8062, run make docker-compose-expt

@akvlad
Copy link
Collaborator

akvlad commented Jan 2, 2024

@tomershafir the first error have never appeared except once. Thanks for the fix.
The second one is reproduced every time. Please recheck.

@akvlad
Copy link
Collaborator

akvlad commented Jan 2, 2024

@tomershafir I don't have the ./example folder. Where is it?

@tomershafir
Copy link
Collaborator Author

@akvlad

  1. removed the dropped column profile_id from insert to fix the insert issue
  2. its examples, sorry https://github.com/grafana/pyroscope-java/tree/main/examples

@akvlad
Copy link
Collaborator

akvlad commented Jan 3, 2024

@tomershafir great update. Everything works now.

Can you add Readme to the components you have created? Something like this one https://github.com/metrico/otel-collector/blob/main/exporter/qrynexporter/README.md

@akvlad akvlad merged commit 490afcf into metrico:main Jan 3, 2024
1 check passed
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.

2 participants