Skip to content

Commit

Permalink
visualize fragment in dashboard
Browse files Browse the repository at this point in the history
Signed-off-by: Bugen Zhao <[email protected]>
  • Loading branch information
BugenZhao committed Sep 20, 2024
1 parent 34a2539 commit 510d2ea
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion dashboard/pages/fragment_graph.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ import { Dispatcher, MergeNode, StreamNode } from "../proto/gen/stream_plan"

interface DispatcherNode {
[actorId: number]: Dispatcher[]
fragment: TableFragments_Fragment
}

// Refresh interval (ms) for back pressure stats
Expand Down Expand Up @@ -107,10 +108,14 @@ function buildPlanNodeDependency(
dispatcherName = "noDispatcher"
}

const dispatcherNode = fragment.actors.reduce((obj, actor) => {
let dispatcherNode = fragment.actors.reduce((obj, actor) => {
obj[actor.actorId] = actor.dispatcher
return obj
}, {} as DispatcherNode)
dispatcherNode.fragment = {
...fragment,
actors: [],
}

return d3.hierarchy({
name: dispatcherName,
Expand Down

0 comments on commit 510d2ea

Please sign in to comment.