Fixedstring type for SpanId and ParentId traces for better compression

Offen
#3,454 2 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen

Maintainer antworten meist innerhalb von 1 Tag

Dieses Issue hat noch niemand übernommen.

Bewertung

Schwierigkeit
4/5
Geschätzter Aufwand
3-5 Tage
Anfängerfreundlichkeit
49/100
Issue-Typ
Feature
Klarheit
Größtenteils klar
Aktivitätsstatus
Aktiv
Tech-Stack
clickhouse, typescript

Rechercherichtung

Start by locating where HyperDX defines or provisions its recommended ClickHouse otel_traces table, then read the relevant schema and trace ingestion code to see how TraceId, SpanId, and ParentSpanId are stored. Check the ClickHouse FixedString length requirements against the trace ID formats and existing data. Done means the issue's proposed migration has a confirmed scope and behavior; the issue does not specify which fields to change or how existing tables should migrate.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Beschreibung

enhancement external Needs Feedback

What are you trying to do?

In the current recommended Clickhouse table structure for Traces SpanId and TraceId have type String

CREATE TABLE IF NOT EXISTS ${DATABASE}.otel_traces
(
    `Timestamp` DateTime64(9) CODEC(Delta(8), ZSTD(1)),
    `TraceId` String CODEC(ZSTD(1)),
    `SpanId` String CODEC(ZSTD(1)),
    `ParentSpanId` String CODEC(ZSTD(1)),
    `TraceState` String CODEC(ZSTD(1)),

These two fields are compressing very badly and basically make up half of the table space usage on disk by themselves:

2. │ SpanId             │ 34.68 GiB       │ 100.74 GiB        │     2.9 │        17.55 │

What would you like to see?

Would it make sense to migrate them to FixedString type?

Vorherrschende Sprache
TypeScript
Sterne
10.1k
Forks
527
Ø Merge
1 T. 20 Std.
Gemergte PRs (30 T.)
186

Entwicklungsumgebung

Erste Schritte

  1. Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
  2. Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
  3. Forken Sie das Repository und arbeiten Sie in einem Branch.
  4. Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.

Mehr aus ClickHouse/ClickStack

Alle Issues in ClickHouse/ClickStack

Ähnliche Issues

Weitere Issues zu TypeScript

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.