hyperdx/packages/app
Karl Power bc8c4eec9a
feat: allow applying session settings to queries (#1609)
Closes HDX-3154

This PR adds a feature that allows the user to add settings to a source. These settings are then added to the end of every query that is rendered through the `renderChartConfig` function, along with any other chart specific settings. 

See: https://clickhouse.com/docs/sql-reference/statements/select#settings-in-select-query

Most of the work was to pass the `source` or `source.querySettings` value through the code to the `renderChartConfig` calls and to update the related tests. There are also some UI changes in the `SourceForm` components.

`SQLParser.Parser` from the `node-sql-parser` throws an error when it encounters a SETTINGS clause in a sql string, so a function was added to remove that clause from any sql that is passed to the parser. It assumes that the SETTINGS clause will always be at the end of the sql string, it removes any part of the string including and after the SETTINGS clause.


https://github.com/user-attachments/assets/7ac3b852-2c86-4431-88bc-106f982343bb
2026-01-21 16:07:30 +00:00
..
.storybook feat(app): refactor Sources components and add custom Mantine UI variants (#1561) 2026-01-07 14:02:36 +00:00
pages chore: bundle drain3 wasm deps (#1564) 2026-01-07 19:12:39 +01:00
public chore: bundle drain3 wasm deps (#1564) 2026-01-07 19:12:39 +01:00
scripts chore: Run playwright tests with mongo backend (#1493) 2025-12-17 18:33:28 +00:00
src feat: allow applying session settings to queries (#1609) 2026-01-21 16:07:30 +00:00
styles refactor(app-nav): reorganize AppNav component structure and improve maintainability (#1621) 2026-01-20 12:35:04 +00:00
tests/e2e test: Add E2E tests for Dashboard Filters (#1612) 2026-01-15 22:29:21 +00:00
types fix: Pollyfill crypto.randomUUID (#904) 2025-06-03 12:35:56 -04:00
.Dockerignore first commit 2023-09-12 20:08:05 -07:00
.env.development feat: add subpath config (#1236) 2025-10-17 14:43:58 -07:00
.gitignore chore: Run playwright tests with mongo backend (#1493) 2025-12-17 18:33:28 +00:00
.stylelintignore Search Relative Time Queries (#1305) 2025-10-29 15:49:10 +00:00
CHANGELOG.md Release HyperDX (#1542) 2026-01-10 22:19:00 +01:00
Dockerfile chore: Update to next 16, react 19, add react compiler (#1434) 2025-12-04 23:40:59 +00:00
eslint.config.mjs Standardize Button/ActionIcon variants and enforce via ESLint (#1610) 2026-01-16 14:42:16 +00:00
global-setup.js Add new useTimeQuery hook (#75) 2023-10-29 04:44:07 +00:00
jest.config.js Bump Typescript Version (app) (#1401) 2025-11-24 21:19:42 +00:00
knip.json feat: move v2 codes 2024-11-12 05:53:15 -07:00
mdx.d.ts first commit 2023-09-12 20:08:05 -07:00
next.config.mjs small quality of live improvements (#1489) 2025-12-15 23:08:27 +00:00
package.json Release HyperDX (#1542) 2026-01-10 22:19:00 +01:00
playwright.config.ts chore: Run playwright tests with mongo backend (#1493) 2025-12-17 18:33:28 +00:00
postcss.config.cjs chore: Upgrade to Mantine@7 (#306) 2024-02-25 10:37:55 +00:00
stylelint.config.mjs Fix deprecated @import syntax warning after upgrading react (#1465) 2025-12-11 22:58:08 +00:00
tsconfig.build.json fix: Update tsconfigs to resolve IDE type errors (#1150) 2025-09-11 08:55:14 -04:00
tsconfig.json chore: Update to next 16, react 19, add react compiler (#1434) 2025-12-04 23:40:59 +00:00