diff --git a/.changeset/calm-tips-repeat.md b/.changeset/calm-tips-repeat.md index c39633b0..c81908c2 100644 --- a/.changeset/calm-tips-repeat.md +++ b/.changeset/calm-tips-repeat.md @@ -1,5 +1,5 @@ --- -"@hyperdx/otel-collector": patch +"@hyperdx/otel-collector": minor --- feat: new optimized otel schema based on weeks of benchmarks. diff --git a/docker/clickhouse/local/init-db-e2e.sh b/docker/clickhouse/local/init-db-e2e.sh index 7bbd4b2b..b28676aa 100755 --- a/docker/clickhouse/local/init-db-e2e.sh +++ b/docker/clickhouse/local/init-db-e2e.sh @@ -31,6 +31,7 @@ CREATE TABLE IF NOT EXISTS ${DATABASE}.e2e_otel_logs \`ScopeVersion\` LowCardinality(String) CODEC(ZSTD(1)), \`ScopeAttributes\` Map(LowCardinality(String), String) CODEC(ZSTD(1)), \`LogAttributes\` Map(LowCardinality(String), String) CODEC(ZSTD(1)), + \`EventName\` String CODEC(ZSTD(1)), \`__hdx_materialized_k8s.cluster.name\` LowCardinality(String) MATERIALIZED ResourceAttributes['k8s.cluster.name'] CODEC(ZSTD(1)), \`__hdx_materialized_k8s.container.name\` LowCardinality(String) MATERIALIZED ResourceAttributes['k8s.container.name'] CODEC(ZSTD(1)), \`__hdx_materialized_k8s.deployment.name\` LowCardinality(String) MATERIALIZED ResourceAttributes['k8s.deployment.name'] CODEC(ZSTD(1)), diff --git a/docker/otel-collector/schema/seed/00002_otel_logs.sql b/docker/otel-collector/schema/seed/00002_otel_logs.sql index 67bab8b5..3bc666f6 100644 --- a/docker/otel-collector/schema/seed/00002_otel_logs.sql +++ b/docker/otel-collector/schema/seed/00002_otel_logs.sql @@ -16,6 +16,7 @@ CREATE TABLE IF NOT EXISTS ${DATABASE}.otel_logs `ScopeVersion` LowCardinality(String) CODEC(ZSTD(1)), `ScopeAttributes` Map(LowCardinality(String), String) CODEC(ZSTD(1)), `LogAttributes` Map(LowCardinality(String), String) CODEC(ZSTD(1)), + `EventName` String CODEC(ZSTD(1)), `__hdx_materialized_k8s.cluster.name` LowCardinality(String) MATERIALIZED ResourceAttributes['k8s.cluster.name'] CODEC(ZSTD(1)), `__hdx_materialized_k8s.container.name` LowCardinality(String) MATERIALIZED ResourceAttributes['k8s.container.name'] CODEC(ZSTD(1)), `__hdx_materialized_k8s.deployment.name` LowCardinality(String) MATERIALIZED ResourceAttributes['k8s.deployment.name'] CODEC(ZSTD(1)), diff --git a/docker/otel-collector/schema/seed/00002_otel_logs_compat.sql b/docker/otel-collector/schema/seed/00002_otel_logs_compat.sql index 66b5aa3e..b6d7f21f 100644 --- a/docker/otel-collector/schema/seed/00002_otel_logs_compat.sql +++ b/docker/otel-collector/schema/seed/00002_otel_logs_compat.sql @@ -17,6 +17,7 @@ CREATE TABLE IF NOT EXISTS ${DATABASE}.otel_logs `ScopeVersion` LowCardinality(String) CODEC(ZSTD(1)), `ScopeAttributes` Map(LowCardinality(String), String) CODEC(ZSTD(1)), `LogAttributes` Map(LowCardinality(String), String) CODEC(ZSTD(1)), + `EventName` String CODEC(ZSTD(1)), `__hdx_materialized_k8s.cluster.name` LowCardinality(String) MATERIALIZED ResourceAttributes['k8s.cluster.name'] CODEC(ZSTD(1)), `__hdx_materialized_k8s.container.name` LowCardinality(String) MATERIALIZED ResourceAttributes['k8s.container.name'] CODEC(ZSTD(1)), `__hdx_materialized_k8s.deployment.name` LowCardinality(String) MATERIALIZED ResourceAttributes['k8s.deployment.name'] CODEC(ZSTD(1)),