You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by "himanish-star (via GitHub)" <gi...@apache.org> on 2025/03/20 16:36:45 UTC

[PR] feat: change display of rebalance response [pinot]

himanish-star opened a new pull request, #15331:
URL: https://github.com/apache/pinot/pull/15331

   ### Description
   
   This PR aims at displaying the rebalance server response in a more legible manner


-- 
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: commits-unsubscribe@pinot.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


Re: [PR] feat: change display of rebalance response [pinot]

Posted by "somandal (via GitHub)" <gi...@apache.org>.
somandal commented on code in PR #15331:
URL: https://github.com/apache/pinot/pull/15331#discussion_r2012441309


##########
pinot-controller/src/main/resources/app/components/Homepage/Operations/RebalanceServer/RebalanceServerResponses/RebalanceServerPreChecksResponse.tsx:
##########
@@ -0,0 +1,43 @@
+import {Grid, Typography} from "@material-ui/core";
+import {RebalanceServerSection} from "../RebalanceServerSection";
+import Alert from "@material-ui/lab/Alert";
+import InfoOutlinedIcon from "@material-ui/icons/InfoOutlined";
+import {Cancel, CheckCircle} from "@material-ui/icons";
+import React from "react";
+import {RebalanceServerResponseLabelValue} from "./RebalanceServerResponseLabelValue";
+import {RebalanceServerResponseCard} from "./RebalanceServerResponseCard";
+
+export const RebalanceServerPreChecksResponse = ({ response }) => {
+    const numberOfPreChecksPassing = Object.keys(response.preChecksResult ?? {})
+        .filter(result => response.preChecksResult[result].preCheckStatus === 'PASS').length;
+    const totalNumberOfPreChecks = Object.keys(response.preChecksResult ?? {}).length;
+    return (
+        <Grid item xs={12}>
+            <RebalanceServerResponseCard>
+                <RebalanceServerSection
+                    canHideSection
+                    sectionTitle={"Pre Checks Result"}
+                    additionalSectionTitle={
+                        <Typography variant='body2' style={{ color: numberOfPreChecksPassing === totalNumberOfPreChecks ? 'green' : 'red' }}>
+                            {numberOfPreChecksPassing} / {totalNumberOfPreChecks}
+                        </Typography>
+                    }>
+                    <Alert style={{ marginBottom: 20 }} color='info' icon={<InfoOutlinedIcon fontSize='small' />}>
+                        <Typography variant='caption'>
+                            These are non-blocking checks.
+                            Rebalance can be run even if these fail. Please be sure to fix the issues before proceeding with actual rebalance!
+                        </Typography>
+                    </Alert>
+                    <Grid container spacing={2}>
+                        { Object.keys(response.preChecksResult).map((preCheckResult, index) => (
+                            <Grid item xs={12} style={{ display: 'flex', alignItems: 'flex-start' }} spacing={2}>
+                                {response.preChecksResult[preCheckResult].preCheckStatus === "PASS" ? <CheckCircle style={{ marginRight: 10, marginTop: 5 }} fontSize='small' htmlColor='green' /> : <Cancel style={{ marginRight: 10, marginTop: 5 }} fontSize='small' color='error' />}

Review Comment:
   will this handle the 3 different types of status?
   - PASS
   - WARN
   - ERROR
   (we should show WARN and ERROR differently - different colors etc)



-- 
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: commits-unsubscribe@pinot.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


Re: [PR] feat: change display of rebalance response [pinot]

Posted by "himanish-star (via GitHub)" <gi...@apache.org>.
himanish-star commented on code in PR #15331:
URL: https://github.com/apache/pinot/pull/15331#discussion_r2012663014


##########
pinot-controller/src/main/resources/app/components/Homepage/Operations/RebalanceServer/RebalanceResponse.tsx:
##########
@@ -0,0 +1,63 @@
+import {RebalanceServerSection} from "./RebalanceServerSection";
+import React from 'react';
+import {Grid, Paper} from "@material-ui/core";
+import CustomCodemirror from "../../../CustomCodemirror";
+import {
+    RebalanceServerSectionResponse
+} from "./RebalanceServerResponses/RebalanceServerSectionResponse";
+import {RebalanceServerPreChecksResponse} from "./RebalanceServerResponses/RebalanceServerPreChecksResponse";
+import {RebalanceServerResponseLabelValue} from "./RebalanceServerResponses/RebalanceServerResponseLabelValue";
+import {
+    RebalanceServerRebalanceSummaryResponse
+} from "./RebalanceServerResponses/RebalanceServerRebalanceSummaryResponse";
+import {RebalanceServerResponseCard} from "./RebalanceServerResponses/RebalanceServerResponseCard";
+
+export const RebalanceResponse = ({ response }) => {
+    const responseSectionsToShow = [
+        {
+            name: 'Segment Assignment',
+            key: 'segmentAssignment'
+        },
+        {
+            name: 'Instance Assignment',
+            key: 'instanceAssignment'
+        }

Review Comment:
   Done



-- 
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: commits-unsubscribe@pinot.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


Re: [PR] feat: change display of rebalance response [pinot]

Posted by "yashmayya (via GitHub)" <gi...@apache.org>.
yashmayya merged PR #15331:
URL: https://github.com/apache/pinot/pull/15331


-- 
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: commits-unsubscribe@pinot.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


Re: [PR] feat: change display of rebalance response [pinot]

Posted by "codecov-commenter (via GitHub)" <gi...@apache.org>.
codecov-commenter commented on PR #15331:
URL: https://github.com/apache/pinot/pull/15331#issuecomment-2741165656

   ## [Codecov](https://app.codecov.io/gh/apache/pinot/pull/15331?dropdown=coverage&src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) Report
   All modified and coverable lines are covered by tests :white_check_mark:
   > Project coverage is 55.98%. Comparing base [(`59551e4`)](https://app.codecov.io/gh/apache/pinot/commit/59551e45224f1535c4863fd577622b37366ccc97?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) to head [(`091a573`)](https://app.codecov.io/gh/apache/pinot/commit/091a5735efee405faa9401a74cd4845d43a788fd?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache).
   > Report is 1881 commits behind head on master.
   
   > :exclamation:  There is a different number of reports uploaded between BASE (59551e4) and HEAD (091a573). Click for more details.
   > 
   > <details><summary>HEAD has 48 uploads less than BASE</summary>
   >
   >| Flag | BASE (59551e4) | HEAD (091a573) |
   >|------|------|------|
   >|integration|7|0|
   >|integration2|3|0|
   >|temurin|12|2|
   >|java-21|7|2|
   >|skip-bytebuffers-true|3|1|
   >|skip-bytebuffers-false|7|1|
   >|unittests|5|2|
   >|java-11|5|0|
   >|unittests2|3|0|
   >|integration1|2|0|
   >|custom-integration1|2|0|
   ></details>
   
   <details><summary>Additional details and impacted files</summary>
   
   
   ```diff
   @@             Coverage Diff              @@
   ##             master   #15331      +/-   ##
   ============================================
   - Coverage     61.75%   55.98%   -5.77%     
   - Complexity      207      685     +478     
   ============================================
     Files          2436     2173     -263     
     Lines        133233   117259   -15974     
     Branches      20636    18751    -1885     
   ============================================
   - Hits          82274    65649   -16625     
   - Misses        44911    46213    +1302     
   + Partials       6048     5397     -651     
   ```
   
   | [Flag](https://app.codecov.io/gh/apache/pinot/pull/15331/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | Coverage Δ | |
   |---|---|---|
   | [custom-integration1](https://app.codecov.io/gh/apache/pinot/pull/15331/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `?` | |
   | [integration](https://app.codecov.io/gh/apache/pinot/pull/15331/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `?` | |
   | [integration1](https://app.codecov.io/gh/apache/pinot/pull/15331/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `?` | |
   | [integration2](https://app.codecov.io/gh/apache/pinot/pull/15331/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `?` | |
   | [java-11](https://app.codecov.io/gh/apache/pinot/pull/15331/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `?` | |
   | [java-21](https://app.codecov.io/gh/apache/pinot/pull/15331/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `55.98% <ø> (-5.64%)` | :arrow_down: |
   | [skip-bytebuffers-false](https://app.codecov.io/gh/apache/pinot/pull/15331/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `55.92% <ø> (-5.83%)` | :arrow_down: |
   | [skip-bytebuffers-true](https://app.codecov.io/gh/apache/pinot/pull/15331/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `55.96% <ø> (+28.23%)` | :arrow_up: |
   | [temurin](https://app.codecov.io/gh/apache/pinot/pull/15331/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `55.98% <ø> (-5.77%)` | :arrow_down: |
   | [unittests](https://app.codecov.io/gh/apache/pinot/pull/15331/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `55.98% <ø> (-5.77%)` | :arrow_down: |
   | [unittests1](https://app.codecov.io/gh/apache/pinot/pull/15331/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `55.98% <ø> (+9.09%)` | :arrow_up: |
   | [unittests2](https://app.codecov.io/gh/apache/pinot/pull/15331/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `?` | |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   </details>
   
   [:umbrella: View full report in Codecov by Sentry](https://app.codecov.io/gh/apache/pinot/pull/15331?dropdown=coverage&src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache).   
   :loudspeaker: Have feedback on the report? [Share it here](https://about.codecov.io/codecov-pr-comment-feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache).
   
   <details><summary>🚀 New features to boost your workflow: </summary>
   
   - ❄ [Test Analytics](https://docs.codecov.com/docs/test-analytics): Detect flaky tests, report on failures, and find test suite problems.
   - 📦 [JS Bundle Analysis](https://docs.codecov.com/docs/javascript-bundle-analysis): Save yourself from yourself by tracking and limiting bundle sizes in JS merges.
   </details>


-- 
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: commits-unsubscribe@pinot.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


Re: [PR] feat: change display of rebalance response [pinot]

Posted by "somandal (via GitHub)" <gi...@apache.org>.
somandal commented on code in PR #15331:
URL: https://github.com/apache/pinot/pull/15331#discussion_r2012438995


##########
pinot-controller/src/main/resources/app/components/Homepage/Operations/RebalanceServer/RebalanceServerResponses/RebalanceServerRebalanceSummaryResponse.tsx:
##########
@@ -0,0 +1,35 @@
+import {Grid} from "@material-ui/core";
+import {RebalanceServerSection} from "../RebalanceServerSection";
+import React from "react";
+import './CustomCodeMirror.css';
+import {RebalanceServerResponseCard} from "./RebalanceServerResponseCard";
+import {RebalanceServerSectionResponse} from "./RebalanceServerSectionResponse";
+
+export const RebalanceServerRebalanceSummaryResponse = ({ response }) => {
+    const responseSectionsToShow = [
+        {
+            name: 'I. Server Information',
+            key: 'serverInfo'
+        },
+        {
+            name: 'II. Segment Information',
+            key: 'segmentInfo'
+        }
+    ];
+

Review Comment:
   cc @J-HowHuang, once the Tenant info changes are in, we'll want to add it here so please make a note of this



-- 
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: commits-unsubscribe@pinot.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


Re: [PR] feat: change display of rebalance response [pinot]

Posted by "himanish-star (via GitHub)" <gi...@apache.org>.
himanish-star commented on code in PR #15331:
URL: https://github.com/apache/pinot/pull/15331#discussion_r2011416002


##########
pinot-controller/src/main/resources/app/components/Homepage/Operations/RebalanceServer/RebalanceResponse.tsx:
##########
@@ -0,0 +1,63 @@
+import {RebalanceServerSection} from "./RebalanceServerSection";
+import React from 'react';
+import {Grid, Paper} from "@material-ui/core";
+import CustomCodemirror from "../../../CustomCodemirror";
+import {
+    RebalanceServerSectionResponse
+} from "./RebalanceServerResponses/RebalanceServerSectionResponse";
+import {RebalanceServerPreChecksResponse} from "./RebalanceServerResponses/RebalanceServerPreChecksResponse";
+import {RebalanceServerResponseLabelValue} from "./RebalanceServerResponses/RebalanceServerResponseLabelValue";
+import {
+    RebalanceServerRebalanceSummaryResponse
+} from "./RebalanceServerResponses/RebalanceServerRebalanceSummaryResponse";
+import {RebalanceServerResponseCard} from "./RebalanceServerResponses/RebalanceServerResponseCard";
+
+export const RebalanceResponse = ({ response }) => {
+    const responseSectionsToShow = [
+        {
+            name: 'Segment Assignment',
+            key: 'segmentAssignment'
+        },
+        {
+            name: 'Instance Assignment',
+            key: 'instanceAssignment'
+        }
+    ];
+

Review Comment:
   @somandal for adding new sections you just need to provide the `key` and `name of the section` and it will render



-- 
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: commits-unsubscribe@pinot.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


Re: [PR] feat: change display of rebalance response [pinot]

Posted by "himanish-star (via GitHub)" <gi...@apache.org>.
himanish-star commented on code in PR #15331:
URL: https://github.com/apache/pinot/pull/15331#discussion_r2011416497


##########
pinot-controller/src/main/resources/app/components/Homepage/Operations/RebalanceServer/RebalanceServerResponses/RebalanceServerRebalanceSummaryResponse.tsx:
##########
@@ -0,0 +1,35 @@
+import {Grid} from "@material-ui/core";
+import {RebalanceServerSection} from "../RebalanceServerSection";
+import React from "react";
+import './CustomCodeMirror.css';
+import {RebalanceServerResponseCard} from "./RebalanceServerResponseCard";
+import {RebalanceServerSectionResponse} from "./RebalanceServerSectionResponse";
+
+export const RebalanceServerRebalanceSummaryResponse = ({ response }) => {
+    const responseSectionsToShow = [
+        {
+            name: 'I. Server Information',
+            key: 'serverInfo'
+        },
+        {
+            name: 'II. Segment Information',
+            key: 'segmentInfo'
+        }
+    ];
+

Review Comment:
   @somandal for adding new sections inside Rebalance Summary Section  you just need to provide the `key` and `name of the section` and it will render



-- 
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: commits-unsubscribe@pinot.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


Re: [PR] feat: change display of rebalance response [pinot]

Posted by "somandal (via GitHub)" <gi...@apache.org>.
somandal commented on code in PR #15331:
URL: https://github.com/apache/pinot/pull/15331#discussion_r2012435827


##########
pinot-controller/src/main/resources/app/components/Homepage/Operations/RebalanceServer/RebalanceResponse.tsx:
##########
@@ -0,0 +1,63 @@
+import {RebalanceServerSection} from "./RebalanceServerSection";
+import React from 'react';
+import {Grid, Paper} from "@material-ui/core";
+import CustomCodemirror from "../../../CustomCodemirror";
+import {
+    RebalanceServerSectionResponse
+} from "./RebalanceServerResponses/RebalanceServerSectionResponse";
+import {RebalanceServerPreChecksResponse} from "./RebalanceServerResponses/RebalanceServerPreChecksResponse";
+import {RebalanceServerResponseLabelValue} from "./RebalanceServerResponses/RebalanceServerResponseLabelValue";
+import {
+    RebalanceServerRebalanceSummaryResponse
+} from "./RebalanceServerResponses/RebalanceServerRebalanceSummaryResponse";
+import {RebalanceServerResponseCard} from "./RebalanceServerResponses/RebalanceServerResponseCard";
+
+export const RebalanceResponse = ({ response }) => {
+    const responseSectionsToShow = [
+        {
+            name: 'Segment Assignment',
+            key: 'segmentAssignment'
+        },
+        {
+            name: 'Instance Assignment',
+            key: 'instanceAssignment'
+        }

Review Comment:
   let's also add:
   
   ```
   {
       name: 'Tier Instance Assignment',
       key: 'tierInstanceAssignment'
   }
   ```



-- 
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: commits-unsubscribe@pinot.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org