Skip to content

Add live mode and output options to graph command#1324

Draft
Nakshatra480 wants to merge 1 commit intodora-rs:mainfrom
Nakshatra480:enhance-graph-command-1204
Draft

Add live mode and output options to graph command#1324
Nakshatra480 wants to merge 1 commit intodora-rs:mainfrom
Nakshatra480:enhance-graph-command-1204

Conversation

@Nakshatra480
Copy link

Fixes #1204

What this adds

The dora graph command was pretty basic - it could only generate static HTML files. This PR adds a few things I thought would be useful:

  • --live flag that shows real-time node status with auto-refresh
  • --output to specify where you want the graph saved
  • Color coding for node states (green for running, gray for stopped, red for failed)

How it works

When you use --live, it connects to the coordinator and queries node status, then injects a meta refresh tag so the page updates every 2 seconds. The best part is we don't need a separate template file anymore - just dynamically inject the refresh tag when needed.

Example usage

# Save to a custom location
dora graph dataflow.yml --output /tmp/my-graph.html

# Live monitoring (requires running dataflow)
dora graph dataflow.yml --live --open

@Nakshatra480 Nakshatra480 force-pushed the enhance-graph-command-1204 branch 3 times, most recently from 12cffdb to 65aa320 Compare January 21, 2026 06:40
Adds Running, Failed, Stopped states for tracking.
@Nakshatra480 Nakshatra480 force-pushed the enhance-graph-command-1204 branch from 65aa320 to 0050a73 Compare January 21, 2026 06:41
@Nakshatra480
Copy link
Author

Nakshatra480 commented Jan 24, 2026

@haixuanTao @phil-opp changes are ready, pls review it

Copy link
Collaborator

@phil-opp phil-opp left a comment

Choose a reason for hiding this comment

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

When you use --live, it connects to the coordinator and queries node status

I don't see this anywhere?

}

#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash, serde::Serialize, serde::Deserialize)]
pub enum NodeStatus {
Copy link
Collaborator

Choose a reason for hiding this comment

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

Is this even used anywhere?

if live {
html = html.replace(
"<head>",
"<head>\n <meta http-equiv=\"refresh\" content=\"2\">",
Copy link
Collaborator

Choose a reason for hiding this comment

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

This just refreshes a static html page, no?

@phil-opp phil-opp added the waiting-for-author The pull request requires adjustments by the PR author. label Feb 18, 2026
@Nakshatra480 Nakshatra480 marked this pull request as draft February 20, 2026 09:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

waiting-for-author The pull request requires adjustments by the PR author.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Enhance dora graph Command (Visualization Upgrade)

2 participants