-
Notifications
You must be signed in to change notification settings - Fork 28.9k
[SPARK-30119][WEBUI] Add Pagination Support to Streaming Page #28439
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
cc @srowen @dongjoon-hyun @HyukjinKwon Kindly review |
|
Jenkins test this please |
|
Test build #122231 has finished for PR 28439 at commit
|
|
retest this please |
|
Jenkins test this please |
|
Test build #122270 has finished for PR 28439 at commit
|
Yeah. I think it would be better if we first clean up. |
c07f7bf to
701fb70
Compare
|
Jenkins test this please |
|
Test build #123004 has finished for PR 28439 at commit
|
|
Does this need to go in before or after #28448 ? want to make sure I understand the desired order and dependencies. |
|
Both are independent of each other. Either one can go first. |
|
@sarutak Kindly take a look at this one. |
|
Jenkins test this please |
|
@iRakson Sorry for the late reply. I'll check this weekend. |
|
It's ok. Please check according to your convenience. :) |
|
Test build #123238 has finished for PR 28439 at commit
|
sarutak
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@iRakson This change newly adds paged tables so I think it's better to add test cases too to test whether this change uses the pagination frame framework correctly.
| Seq( | ||
| ("Batch Time", true, None), | ||
| ("Records", true, None), | ||
| ("Scheduling Delay", true, Some(tooltips._1)), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why not just put the tooltip texts as literal like other paged table?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I worked on this before working on other pages, i missed this one. I will update to literals.
| <div class="col-12"> | ||
| <span id="activeBatches" class="collapse-aggregated-activeBatches collapse-table" | ||
| onClick="collapseTable('collapse-aggregated-activeBatches', | ||
| 'aggregated-activeBatches')"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
webui.js refers colapse-aggregated-activeBatches and aggregated-activeBatches so we need change them.
| subPath: String, | ||
| isRunningTable: Boolean, | ||
| isWaitingTable: Boolean, | ||
| isCompletedTable: Boolean, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
isRunningTable, isWaitingTable and isCompletedTable are orthogonal so how about introducing constants which represent table types and pass one of them to the constructor?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you suggesting this. I will change to constants.
| } else { | ||
| Nil | ||
| <tr> | ||
| <td id = {batchTimeId} isFailed = {batch.isFailed.toString}> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For attributes, it's natural not to have white spaces between = and it's operands.
| {formattedBatchTime} | ||
| </a> | ||
| </td> | ||
| <td> {numRecords.toString} Records </td> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's better to keep records rather than Records to minimize appearance change.
| "table table-bordered table-sm table-striped table-head-clickable table-cell-width-limited" | ||
|
|
||
| protected def createOutputOperationProgressBar(batch: BatchUIData): Seq[Node] = { | ||
| <td class="progress-cell"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do we need to move <td> and </td> outside this method?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I removed to maintain consistency. i.e
<td> ...... </td>
<td> ...... </td>
Anyway, i will use the original code.
|
@sarutak Thank you for reviewing. I will update PR with test cases and suggested code changes. |
|
retest this please |
|
add to whitelist. |
|
@iRakson From now on, Jenkins starts on pushing your commit and you can start Jenkins by saying "retest this please". |
|
Test build #123439 has finished for PR 28439 at commit
|
|
Test build #123438 has finished for PR 28439 at commit
|
|
retest this please |
|
@sarutak Gentle ping. |
|
Test build #123527 has finished for PR 28439 at commit
|
|
If you're OK with it @sarutak I'll merge |
|
I've inspected again and it seems ok to me. |
|
I'll merge this time. |
|
@iRakson Could you update the screenshots in the description? |
Updated. |
|
Merged to |
This PR reverts #28439 due to that PR breaks QA build. Closes #28747 from sarutak/revert-SPARK-30119. Authored-by: Kousuke Saruta <[email protected]> Signed-off-by: Kousuke Saruta <[email protected]>
|
The suite passes on my laptop with both sbt and Maven so the suite can be flaky. |
| // Check batch tables | ||
| val h4Text = findAll(cssSelector("h4")).map(_.text).toSeq | ||
| h4Text.exists(_.matches("Active Batches \\(\\d+\\)")) should be (true) | ||
| h4Text.exists(_.matches("Running Batches \\(\\d+\\)")) should be (true) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is causing all the failures. I will remove these tests and raise again
### What changes were proposed in this pull request? * Pagination Support is added to all tables of streaming page in spark web UI. For adding pagination support, existing classes from apache#7399 were used. * Earlier streaming page has two tables `Active Batches` and `Completed Batches`. Now, we will have three tables `Running Batches`, `Waiting Batches` and `Completed Batches`. If we have large number of waiting and running batches then keeping track in a single table is difficult. Also other pages have different table for different type type of data. * Earlier empty tables were shown. Now only non-empty tables will be shown. `Active Batches` table used to show details of waiting batches followed by running batches. ### Why are the changes needed? Pagination will allow users to analyse the table in much better way. All spark web UI pages support pagination apart from streaming pages, so this will add consistency as well. Also it might fix the potential OOM errors that can arise. ### Does this PR introduce _any_ user-facing change? Yes. `Active Batches` table is split into two tables `Running Batches` and `Waiting Batches`. Pagination Support is added to the all the tables. Every other functionality is unchanged. ### How was this patch tested? Manually. Before changes: <img width="1667" alt="Screenshot 2020-05-03 at 7 07 14 PM" src="https://user-images.githubusercontent.com/15366835/80915680-8fb44b80-8d71-11ea-9957-c4a3769b8b67.png"> After Changes: <img width="1669" alt="Screenshot 2020-05-03 at 6 51 22 PM" src="https://user-images.githubusercontent.com/15366835/80915694-a9ee2980-8d71-11ea-8fc5-246413a4951d.png"> Closes apache#28439 from iRakson/streamingPagination. Authored-by: iRakson <[email protected]> Signed-off-by: Kousuke Saruta <[email protected]>
### What changes were proposed in this pull request? #28747 reverted #28439 due to some flaky test case. This PR fixes the flaky test and adds pagination support. ### Why are the changes needed? To support pagination for streaming tab ### Does this PR introduce _any_ user-facing change? Yes, Now streaming tab tables will be paginated. ### How was this patch tested? Manually. Closes #28748 from iRakson/fixstreamingpagination. Authored-by: iRakson <[email protected]> Signed-off-by: Sean Owen <[email protected]>
What changes were proposed in this pull request?
For adding pagination support, existing classes from [SPARK-4598][WebUI]Task table pagination for the Stage page #7399 were used.
Active BatchesandCompleted Batches. Now, we will have three tablesRunning Batches,Waiting BatchesandCompleted Batches. If we have large number of waiting and running batches then keeping track in a single table is difficult. Also other pages have different table for different type type of data.Active Batchestable used to show details of waiting batches followed by running batches.Why are the changes needed?
Pagination will allow users to analyse the table in much better way. All spark web UI pages support pagination apart from streaming pages, so this will add consistency as well. Also it might fix the potential OOM errors that can arise.
Does this PR introduce any user-facing change?
Yes.
Active Batchestable is split into two tablesRunning BatchesandWaiting Batches. Pagination Support is added to the all the tables. Every other functionality is unchanged.How was this patch tested?
UT added.
Before changes:

After Changes:
