mirror of https://github.com/apache/druid.git
Add daily stats to console (#12329)
This commit is contained in:
parent
2d8eb117c0
commit
eb6de94e1f
|
@ -56,6 +56,7 @@ export class BarGroup extends React.Component<BarGroupProps> {
|
||||||
datasource: entry.datasource,
|
datasource: entry.datasource,
|
||||||
xValue: entry.x,
|
xValue: entry.x,
|
||||||
yValue: entry.y,
|
yValue: entry.y,
|
||||||
|
dailySize: entry.dailySize,
|
||||||
};
|
};
|
||||||
return (
|
return (
|
||||||
<BarUnit
|
<BarUnit
|
||||||
|
|
|
@ -193,6 +193,7 @@ ORDER BY "start" DESC`;
|
||||||
y0,
|
y0,
|
||||||
datasource,
|
datasource,
|
||||||
color: SegmentTimeline.getColor(i),
|
color: SegmentTimeline.getColor(i),
|
||||||
|
dailySize: d.total,
|
||||||
};
|
};
|
||||||
y0 += d[datasource] === undefined ? 0 : d[datasource];
|
y0 += d[datasource] === undefined ? 0 : d[datasource];
|
||||||
return barUnitData;
|
return barUnitData;
|
||||||
|
|
|
@ -31,6 +31,7 @@ export interface BarUnitData {
|
||||||
width: number;
|
width: number;
|
||||||
datasource: string;
|
datasource: string;
|
||||||
color: string;
|
color: string;
|
||||||
|
dailySize?: number;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface BarChartMargin {
|
export interface BarChartMargin {
|
||||||
|
@ -48,6 +49,7 @@ export interface HoveredBarInfo {
|
||||||
datasource?: string;
|
datasource?: string;
|
||||||
xValue?: number;
|
xValue?: number;
|
||||||
yValue?: number;
|
yValue?: number;
|
||||||
|
dailySize?: number;
|
||||||
}
|
}
|
||||||
|
|
||||||
interface StackedBarChartProps {
|
interface StackedBarChartProps {
|
||||||
|
@ -151,6 +153,11 @@ export const StackedBarChart = React.memo(function StackedBarChart(props: Stacke
|
||||||
<div className="bar-chart-tooltip">
|
<div className="bar-chart-tooltip">
|
||||||
<div>Datasource: {hoverOn.datasource}</div>
|
<div>Datasource: {hoverOn.datasource}</div>
|
||||||
<div>Time: {hoverOn.xValue}</div>
|
<div>Time: {hoverOn.xValue}</div>
|
||||||
|
<div>
|
||||||
|
{`${
|
||||||
|
activeDataType === 'countData' ? 'Daily total count:' : 'Daily total size:'
|
||||||
|
} ${formatTick(hoverOn.dailySize!)}`}
|
||||||
|
</div>
|
||||||
<div>
|
<div>
|
||||||
{`${activeDataType === 'countData' ? 'Count:' : 'Size:'} ${formatTick(
|
{`${activeDataType === 'countData' ? 'Count:' : 'Size:'} ${formatTick(
|
||||||
hoverOn.yValue!,
|
hoverOn.yValue!,
|
||||||
|
|
Loading…
Reference in New Issue