-
Notifications
You must be signed in to change notification settings - Fork 355
feat: Enforce ClickStack schemas by default #1682
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
base: main
Are you sure you want to change the base?
Conversation
🦋 Changeset detectedLatest commit: 1492367 The changes in this PR will be included in the next version bump. This PR includes changesets to release 3 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Code ReviewCritical Issues❌ Schema breaking change: Removed materialized columns from hyperdx_sessions table (docker/otel-collector/schema/sessions/00001_hyperdx_sessions.sql:2-35) → Existing queries and indexes referencing __hdx_materialized_rum.sessionId and __hdx_materialized_type will fail. Add migration script to drop dependent indexes and columns if they exist. ❌ Index breaking change: Removed idx_rum_session_id index and changed idx_body to idx_lower_body with different function → Queries using these indexes will fail or perform poorly. Need migration to handle existing tables. Suggestions🔍 Missing goose down migrations: Only goose Up defined, no rollback path → Consider adding down migrations for future schema changes. 📝 Type inconsistency: TypeScript interface defines create_schema: string but uses boolean-like values (opampController.ts:204-205, 220-221) → Should be create_schema: boolean or clarify string representation. Note: The TODO comment in docker-compose.yml:35 suggests this is a known migration path, but ensure coordination with existing deployments. |
E2E Test Results✅ All tests passed • 61 passed • 4 skipped • 763s
Tests ran across 4 shards in parallel. |
| @@ -199,6 +201,8 @@ export const buildOtelCollectorConfig = (teams: ITeam[]): CollectorConfig => { | |||
| ttl: '720h', | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not related to this PR. But I think the TTL should be configurable. I will address it in later PRs
| HYPERDX_LOG_LEVEL: ${HYPERDX_LOG_LEVEL} | ||
| OPAMP_SERVER_URL: 'http://app:${HYPERDX_OPAMP_PORT}' | ||
| # TODO: use new schema | ||
| HYPERDX_OTEL_EXPORTER_CREATE_LEGACY_SCHEMA: 'true' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will flip this flag in a later PR
HYPERDX_OTEL_EXPORTER_CREATE_LEGACY_SCHEMA(default to false) to otel collectorclickstack_db_version_xxxtablesRef: HDX-3301