You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ozone.apache.org by "devabhishekpal (via GitHub)" <gi...@apache.org> on 2024/09/18 15:04:28 UTC

[PR] HDDS-11468. Enabled DB sync button [ozone]

devabhishekpal opened a new pull request, #7216:
URL: https://github.com/apache/ozone/pull/7216

   ## What changes were proposed in this pull request?
   HDDS-11468. Enabled DB sync button
   
   Please describe your PR in detail:
   * Currently the DB sync button gets disabled if the OM sync response is empty
   * We should not disable the button in such a scenario, but allow the user to click
   * Instead we update the tooltip information to let the user know whether a DB sync operation is still going on or it was triggered
   
   ## What is the link to the Apache JIRA
   
   https://issues.apache.org/jira/browse/HDDS-11468
   
   ## How was this patch tested?
   Patch was tested manually and verified behaviour.


-- 
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: issues-unsubscribe@ozone.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-11468. Enabled DB sync button [ozone]

Posted by "devabhishekpal (via GitHub)" <gi...@apache.org>.
devabhishekpal commented on PR #7216:
URL: https://github.com/apache/ozone/pull/7216#issuecomment-2360844658

   Yes Devesh.
   So if you check the line: ```omStatus === '' ? false : true```
   Ref: https://github.com/apache/ozone/blob/70b8dd5ea3b433c2f1b7f8816b269a71d9a2466e/hadoop-ozone/recon/src/main/resources/webapps/recon/ozone-recon-web/src/components/autoReloadPanel/autoReloadPanel.tsx#L82
   This condition would disable the button, if omStatus got a response back i.e the API call was done.
   
   Initially in Overview page we are initializing `omStatus: ''` which matches the condition and returns true.
   Ref: https://github.com/apache/ozone/blob/70b8dd5ea3b433c2f1b7f8816b269a71d9a2466e/hadoop-ozone/recon/src/main/resources/webapps/recon/ozone-recon-web/src/views/overview/overview.tsx#L107
   Hence the button is enabled.
   
   After we click the button [omSyncData()](https://github.com/apache/ozone/blob/70b8dd5ea3b433c2f1b7f8816b269a71d9a2466e/hadoop-ozone/recon/src/main/resources/webapps/recon/ozone-recon-web/src/views/overview/overview.tsx#L233) is triggered which sets the omStatus state.
   
   Hence the check for disabled now `omStatus === ''` doesn't match and it returns `disabled={true}`.
   
   After refresh the state is again being set to `''` i.e empty string, and the button is enabled again.
   
   This is the RCA.
   
   We have now removed the `disabled` prop from the button, thus the button will be enabled at all times allowing the sync.
   


-- 
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: issues-unsubscribe@ozone.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-11468. Enabled DB sync button [ozone]

Posted by "devabhishekpal (via GitHub)" <gi...@apache.org>.
devabhishekpal commented on PR #7216:
URL: https://github.com/apache/ozone/pull/7216#issuecomment-2360901532

   We already have that in the code.
   Ref: https://github.com/apache/ozone/blob/70b8dd5ea3b433c2f1b7f8816b269a71d9a2466e/hadoop-ozone/recon/src/main/resources/webapps/recon/ozone-recon-web/src/components/autoReloadPanel/autoReloadPanel.tsx#L58
   
   Updated the description to reflect 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: issues-unsubscribe@ozone.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-11468. Enabled DB sync button [ozone]

Posted by "devabhishekpal (via GitHub)" <gi...@apache.org>.
devabhishekpal commented on PR #7216:
URL: https://github.com/apache/ozone/pull/7216#issuecomment-2360766904

   @devmadhuu, from the backend we will never get empty string.
   The empty string is coming from the first initialization of the page. It is initialized to empty string.
   Ref: https://github.com/apache/ozone/blob/70b8dd5ea3b433c2f1b7f8816b269a71d9a2466e/hadoop-ozone/recon/src/main/resources/webapps/recon/ozone-recon-web/src/views/overview/overview.tsx#L107


-- 
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: issues-unsubscribe@ozone.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-11468. Enabled DB sync button [ozone]

Posted by "ArafatKhan2198 (via GitHub)" <gi...@apache.org>.
ArafatKhan2198 commented on PR #7216:
URL: https://github.com/apache/ozone/pull/7216#issuecomment-2362847515

   Thanks for the patch @devabhishekpal 
   Thanks for the review @devmadhuu 
   Merging!


-- 
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: issues-unsubscribe@ozone.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-11468. Enabled DB sync button [ozone]

Posted by "devmadhuu (via GitHub)" <gi...@apache.org>.
devmadhuu commented on PR #7216:
URL: https://github.com/apache/ozone/pull/7216#issuecomment-2360784202

   sync button was getting disabled with every click of sync button, not just first click


-- 
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: issues-unsubscribe@ozone.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-11468. Enabled DB sync button [ozone]

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


-- 
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: issues-unsubscribe@ozone.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-11468. Enabled DB sync button [ozone]

Posted by "devmadhuu (via GitHub)" <gi...@apache.org>.
devmadhuu commented on PR #7216:
URL: https://github.com/apache/ozone/pull/7216#issuecomment-2360885523

   Are we updating tooltip info in this PR as per PR description ?


-- 
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: issues-unsubscribe@ozone.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org