Skip to content

Conversation

@wrn14897
Copy link
Member

@wrn14897 wrn14897 commented Apr 18, 2025

Ref: HDX-1631

  1. use temp centralized queryChartConfig to handle multi-series chart (metrics specifically)
  2. move ratio computation logics (events chart) to the renderChartConfig
  3. fix missing seriesReturnType prop in chartConfig in the checkAlert file

@changeset-bot
Copy link

changeset-bot bot commented Apr 18, 2025

🦋 Changeset detected

Latest commit: 3d97895

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 3 packages
Name Type
@hyperdx/common-utils Patch
@hyperdx/api Patch
@hyperdx/app Patch

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

@vercel
Copy link

vercel bot commented Apr 18, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
hyperdx-v2-oss-app ✅ Ready (Inspect) Visit Preview 💬 Add feedback Apr 21, 2025 10:53pm

import { buildMTViewSelectQuery } from '@/hdxMTViews';
import { getMetadata } from '@/metadata';

export const isMetric = (config: ChartConfigWithOptDateRange) =>
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Move all these to common-utils

@wrn14897 wrn14897 force-pushed the warren/introduce-queryChartConfig-method branch from f29b031 to 218fc8c Compare April 18, 2025 05:14
@wrn14897 wrn14897 changed the title (WIP) feat: queryChartConfig method + events chart ratio feat: queryChartConfig method + events chart ratio Apr 18, 2025
}),
);

return isRatio
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is awesome

data: Array.from(tsBucketMap.values()),
};
// TODO: we should compute the ratio on the db side
return isRatio ? computeResultSetRatio(_resultSet) : _resultSet;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Isn't this moved to the db side now?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

for metrics, multi-series + ratio are still computed during post-query phase

@kodiakhq kodiakhq bot merged commit 7f0b397 into v2 Apr 21, 2025
5 of 6 checks passed
@kodiakhq kodiakhq bot deleted the warren/introduce-queryChartConfig-method branch April 21, 2025 22:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants