goingforstudying-ctrl commented on code in PR #1593:
URL: 
https://github.com/apache/datafusion-ballista/pull/1593#discussion_r3204974530


##########
docs/source/user-guide/cli.md:
##########
@@ -130,3 +137,91 @@ Available commands inside Ballista CLI are:
 ```bash
 > \h function_table
 ```
+
+## Terminal User Interface (TUI)
+
+When Ballista CLI is built with the `tui` feature, you can launch an 
interactive terminal user interface
+that provides a visual overview of the Ballista cluster.
+
+### Launching the TUI
+
+```bash
+ballista-cli --tui
+```

Review Comment:
   Fixed! I've added a second way to start the TUI via the `\tui` command 
within the Ballista CLI interactive shell. Please let me know if anything else 
is needed.



##########
docs/source/user-guide/cli.md:
##########
@@ -130,3 +137,91 @@ Available commands inside Ballista CLI are:
 ```bash
 > \h function_table
 ```
+
+## Terminal User Interface (TUI)
+
+When Ballista CLI is built with the `tui` feature, you can launch an 
interactive terminal user interface
+that provides a visual overview of the Ballista cluster.
+
+### Launching the TUI
+
+```bash
+ballista-cli --tui
+```
+

Review Comment:
   Fixed! I've documented both ways to start the TUI: (1) `ballista-cli --tui` 
and (2) from within the CLI via `\tui`. Please let me know if anything else is 
needed.



##########
docs/source/user-guide/cli.md:
##########
@@ -130,3 +137,91 @@ Available commands inside Ballista CLI are:
 ```bash
 > \h function_table
 ```
+
+## Terminal User Interface (TUI)
+
+When Ballista CLI is built with the `tui` feature, you can launch an 
interactive terminal user interface
+that provides a visual overview of the Ballista cluster.
+
+### Launching the TUI
+
+```bash
+ballista-cli --tui
+```
+
+### TUI Features
+
+The TUI provides the following views:
+
+- **Executors**: Lists all registered executors with their host, port, CPU 
cores, memory, and current job count. Supports sorting by any column.
+- **Jobs**: Displays active and completed jobs with their status, start time, 
and duration. Supports sorting, job search (`/`), and shows job details on 
selection.
+- **Job Stages**: When viewing a job, press `Enter` to see its execution 
stages with input/output rows, elapsed compute, and task percentiles.
+- **Stage Tasks & Plan**: Within the Job Stages view, press `t` to see 
individual task details or `p` to view the stage execution plan.
+- **Job Plans**: For completed jobs, press `p` to view the Stage, Physical, or 
Logical query plans.
+- **Job Stages Graph**: Press `g` to visualize the job's stage execution graph.
+- **Metrics**: Fetches and displays Prometheus metrics from the scheduler, 
including query execution statistics.
+- **Scheduler Info**: Shows the current scheduler state and configuration.
+
+### TUI Navigation
+
+#### Global Keybindings

Review Comment:
   Kept the keybindings table as-is per @martin-g's feedback that they are 
useful and commonly found in TUI app READMEs. Please let me know if anything 
else is needed.



##########
docs/source/user-guide/cli.md:
##########
@@ -28,6 +28,12 @@ Use Cargo to install:
 cargo install ballista-cli
 ```
 
+The TUI feature is enabled by default. To install without it:

Review Comment:
   Fixed! Removed the `--no-default-features` Cargo section as it was deemed 
unnecessary for non-beginner Cargo users. Please let me know if anything else 
is needed.



##########
docs/source/user-guide/cli.md:
##########
@@ -130,3 +137,91 @@ Available commands inside Ballista CLI are:
 ```bash
 > \h function_table
 ```
+
+## Terminal User Interface (TUI)
+
+When Ballista CLI is built with the `tui` feature, you can launch an 
interactive terminal user interface
+that provides a visual overview of the Ballista cluster.
+
+### Launching the TUI
+
+```bash
+ballista-cli --tui
+```
+
+### TUI Features
+
+The TUI provides the following views:
+
+- **Executors**: Lists all registered executors with their host, port, CPU 
cores, memory, and current job count. Supports sorting by any column.
+- **Jobs**: Displays active and completed jobs with their status, start time, 
and duration. Supports sorting, job search (`/`), and shows job details on 
selection.
+- **Job Stages**: When viewing a job, press `Enter` to see its execution 
stages with input/output rows, elapsed compute, and task percentiles.
+- **Stage Tasks & Plan**: Within the Job Stages view, press `t` to see 
individual task details or `p` to view the stage execution plan.

Review Comment:
   Fixed! Updated the Stage Tasks description to use `Enter` instead of `t` to 
see individual task details. Please let me know if anything else is needed.



##########
docs/source/user-guide/cli.md:
##########
@@ -130,3 +137,91 @@ Available commands inside Ballista CLI are:
 ```bash
 > \h function_table
 ```
+
+## Terminal User Interface (TUI)
+
+When Ballista CLI is built with the `tui` feature, you can launch an 
interactive terminal user interface
+that provides a visual overview of the Ballista cluster.
+
+### Launching the TUI
+
+```bash
+ballista-cli --tui
+```
+
+### TUI Features
+
+The TUI provides the following views:
+
+- **Executors**: Lists all registered executors with their host, port, CPU 
cores, memory, and current job count. Supports sorting by any column.
+- **Jobs**: Displays active and completed jobs with their status, start time, 
and duration. Supports sorting, job search (`/`), and shows job details on 
selection.
+- **Job Stages**: When viewing a job, press `Enter` to see its execution 
stages with input/output rows, elapsed compute, and task percentiles.
+- **Stage Tasks & Plan**: Within the Job Stages view, press `t` to see 
individual task details or `p` to view the stage execution plan.
+- **Job Plans**: For completed jobs, press `p` to view the Stage, Physical, or 
Logical query plans.
+- **Job Stages Graph**: Press `g` to visualize the job's stage execution graph.
+- **Metrics**: Fetches and displays Prometheus metrics from the scheduler, 
including query execution statistics.
+- **Scheduler Info**: Shows the current scheduler state and configuration.
+
+### TUI Navigation
+
+#### Global Keybindings
+
+| Key         | Action                                  |
+| ----------- | --------------------------------------- |
+| `j`         | Switch to Jobs view                     |
+| `e`         | Switch to Executors view                |
+| `m`         | Switch to Metrics view                  |
+| `i`         | Show Scheduler Info popup               |
+| `?` / `h`   | Show help overlay with all key bindings |
+| `q` / `Esc` | Quit the TUI                            |
+
+#### Jobs View Keybindings
+
+| Key             | Action                                                     
                             |
+| --------------- | 
---------------------------------------------------------------------------------------
 |
+| `↑` / `↓`       | Navigate rows in the jobs table                            
                             |
+| `1` / `2` / `3` | Sort by first/second/third column (press again to reverse, 
third press removes sorting) |
+| `/`             | Search jobs                                                
                             |
+| `Enter`         | Open Job Stages popup for the selected job                 
                             |
+| `g`             | View job stages graph (DOT visualization)                  
                             |
+| `c`             | Cancel the selected job (if cancelable)                    
                             |
+| `p`             | View job plans (Stage / Physical / Logical) for completed 
jobs                          |
+
+#### Job Stages Popup Keybindings
+
+| Key       | Action                                     |
+| --------- | ------------------------------------------ |
+| `↑` / `↓` | Navigate stages                            |
+| `Enter`   | View tasks for the selected stage          |
+| `p`       | View execution plan for the selected stage |
+| `Esc`     | Close popup                                |
+
+#### Stage Tasks / Plan Popup Keybindings
+
+| Key   | Action      |
+| ----- | ----------- |
+| `Esc` | Close popup |

Review Comment:
   Fixed! Updated the `Esc` description in the Stage Tasks popup to say `Return 
to Job Stages popup` for clarity. Please let me know if anything else is needed.



##########
docs/source/user-guide/cli.md:
##########
@@ -130,3 +137,91 @@ Available commands inside Ballista CLI are:
 ```bash
 > \h function_table
 ```
+
+## Terminal User Interface (TUI)
+
+When Ballista CLI is built with the `tui` feature, you can launch an 
interactive terminal user interface
+that provides a visual overview of the Ballista cluster.
+
+### Launching the TUI
+
+```bash
+ballista-cli --tui
+```
+
+### TUI Features
+
+The TUI provides the following views:
+
+- **Executors**: Lists all registered executors with their host, port, CPU 
cores, memory, and current job count. Supports sorting by any column.
+- **Jobs**: Displays active and completed jobs with their status, start time, 
and duration. Supports sorting, job search (`/`), and shows job details on 
selection.
+- **Job Stages**: When viewing a job, press `Enter` to see its execution 
stages with input/output rows, elapsed compute, and task percentiles.
+- **Stage Tasks & Plan**: Within the Job Stages view, press `t` to see 
individual task details or `p` to view the stage execution plan.
+- **Job Plans**: For completed jobs, press `p` to view the Stage, Physical, or 
Logical query plans.
+- **Job Stages Graph**: Press `g` to visualize the job's stage execution graph.
+- **Metrics**: Fetches and displays Prometheus metrics from the scheduler, 
including query execution statistics.
+- **Scheduler Info**: Shows the current scheduler state and configuration.
+
+### TUI Navigation
+
+#### Global Keybindings
+
+| Key         | Action                                  |
+| ----------- | --------------------------------------- |
+| `j`         | Switch to Jobs view                     |
+| `e`         | Switch to Executors view                |
+| `m`         | Switch to Metrics view                  |
+| `i`         | Show Scheduler Info popup               |
+| `?` / `h`   | Show help overlay with all key bindings |
+| `q` / `Esc` | Quit the TUI                            |
+
+#### Jobs View Keybindings
+
+| Key             | Action                                                     
                             |
+| --------------- | 
---------------------------------------------------------------------------------------
 |
+| `↑` / `↓`       | Navigate rows in the jobs table                            
                             |
+| `1` / `2` / `3` | Sort by first/second/third column (press again to reverse, 
third press removes sorting) |
+| `/`             | Search jobs                                                
                             |
+| `Enter`         | Open Job Stages popup for the selected job                 
                             |
+| `g`             | View job stages graph (DOT visualization)                  
                             |
+| `c`             | Cancel the selected job (if cancelable)                    
                             |
+| `p`             | View job plans (Stage / Physical / Logical) for completed 
jobs                          |
+
+#### Job Stages Popup Keybindings
+
+| Key       | Action                                     |
+| --------- | ------------------------------------------ |
+| `↑` / `↓` | Navigate stages                            |
+| `Enter`   | View tasks for the selected stage          |
+| `p`       | View execution plan for the selected stage |
+| `Esc`     | Close popup                                |
+
+#### Stage Tasks / Plan Popup Keybindings
+
+| Key   | Action      |
+| ----- | ----------- |
+| `Esc` | Close popup |
+
+#### Job Plans Popup Keybindings
+
+| Key       | Action             |
+| --------- | ------------------ |
+| `s`       | Show Stage plan    |
+| `p`       | Show Physical plan |
+| `l`       | Show Logical plan  |
+| `↑` / `↓` | Scroll up/down     |
+| `Esc`     | Close popup        |
+

Review Comment:
   Fixed! Added a new `Job Stages Graph Popup Keybindings` section with `↑`/`↓` 
for scrolling and `Esc` to close. Please let me know if anything else is needed.



##########
docs/source/user-guide/cli.md:
##########
@@ -130,3 +137,91 @@ Available commands inside Ballista CLI are:
 ```bash
 > \h function_table
 ```
+
+## Terminal User Interface (TUI)
+
+When Ballista CLI is built with the `tui` feature, you can launch an 
interactive terminal user interface
+that provides a visual overview of the Ballista cluster.
+
+### Launching the TUI
+
+```bash
+ballista-cli --tui
+```
+
+### TUI Features
+
+The TUI provides the following views:
+
+- **Executors**: Lists all registered executors with their host, port, CPU 
cores, memory, and current job count. Supports sorting by any column.
+- **Jobs**: Displays active and completed jobs with their status, start time, 
and duration. Supports sorting, job search (`/`), and shows job details on 
selection.
+- **Job Stages**: When viewing a job, press `Enter` to see its execution 
stages with input/output rows, elapsed compute, and task percentiles.
+- **Stage Tasks & Plan**: Within the Job Stages view, press `t` to see 
individual task details or `p` to view the stage execution plan.
+- **Job Plans**: For completed jobs, press `p` to view the Stage, Physical, or 
Logical query plans.
+- **Job Stages Graph**: Press `g` to visualize the job's stage execution graph.
+- **Metrics**: Fetches and displays Prometheus metrics from the scheduler, 
including query execution statistics.
+- **Scheduler Info**: Shows the current scheduler state and configuration.
+
+### TUI Navigation
+
+#### Global Keybindings
+
+| Key         | Action                                  |
+| ----------- | --------------------------------------- |
+| `j`         | Switch to Jobs view                     |
+| `e`         | Switch to Executors view                |
+| `m`         | Switch to Metrics view                  |
+| `i`         | Show Scheduler Info popup               |
+| `?` / `h`   | Show help overlay with all key bindings |
+| `q` / `Esc` | Quit the TUI                            |
+
+#### Jobs View Keybindings
+
+| Key             | Action                                                     
                             |
+| --------------- | 
---------------------------------------------------------------------------------------
 |
+| `↑` / `↓`       | Navigate rows in the jobs table                            
                             |
+| `1` / `2` / `3` | Sort by first/second/third column (press again to reverse, 
third press removes sorting) |
+| `/`             | Search jobs                                                
                             |
+| `Enter`         | Open Job Stages popup for the selected job                 
                             |
+| `g`             | View job stages graph (DOT visualization)                  
                             |

Review Comment:
   Fixed! Clarified that the job stages graph (`g`) is for completed jobs. 
Please let me know if anything else is needed.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to