Skip to content
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

Bug 1972011: Fix time range for drag & drop in devconsole monitoring #9314

Merged
merged 1 commit into from Jul 14, 2021

Conversation

vikram-raj
Copy link
Member

@vikram-raj vikram-raj commented Jun 22, 2021

Fixes:
https://issues.redhat.com/browse/OCPBUGSM-30920

Analysis / Root cause:
Dashboards display different time range when drag&drop on the first chart of the dashboard

Solution Description:
Dispatch the onZoom event so that it will reflect all the charts in the dashboard.

Screen shots / Gifs for design review:
Kapture 2021-06-22 at 20 16 51

@openshift-ci openshift-ci bot added the component/dev-console Related to dev-console label Jun 22, 2021
@vikram-raj vikram-raj changed the title Fix time range for drag & drop in devconsole monitoring Bug 1972011: Fix time range for drag & drop in devconsole monitoring Jun 22, 2021
@openshift-ci openshift-ci bot added bugzilla/severity-medium Referenced Bugzilla bug's severity is medium for the branch this PR is targeting. bugzilla/valid-bug Indicates that a referenced Bugzilla bug is valid for the branch this PR is targeting. labels Jun 22, 2021
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jun 22, 2021

@vikram-raj: This pull request references Bugzilla bug 1972011, which is valid. The bug has been moved to the POST state. The bug has been updated to refer to the pull request using the external bug tracker.

3 validation(s) were run on this bug
  • bug is open, matching expected state (open)
  • bug target release (4.9.0) matches configured target release for branch (4.9.0)
  • bug is in the state NEW, which is one of the valid states (NEW, ASSIGNED, ON_DEV, POST, POST)

No GitHub users were found matching the public email listed for the QA contact in Bugzilla (gamore@redhat.com), skipping review request.

In response to this:

Bug 1972011: Fix time range for drag & drop in devconsole monitoring

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jun 22, 2021

@vikram-raj: This pull request references Bugzilla bug 1972011, which is valid.

3 validation(s) were run on this bug
  • bug is open, matching expected state (open)
  • bug target release (4.9.0) matches configured target release for branch (4.9.0)
  • bug is in the state POST, which is one of the valid states (NEW, ASSIGNED, ON_DEV, POST, POST)

No GitHub users were found matching the public email listed for the QA contact in Bugzilla (gamore@redhat.com), skipping review request.

In response to this:

Bug 1972011: Fix time range for drag & drop in devconsole monitoring

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@vikram-raj
Copy link
Member Author

/kind bug

@openshift-ci openshift-ci bot added the kind/bug Categorizes issue or PR as related to a bug. label Jun 23, 2021
@invincibleJai
Copy link
Member

@vikram-raj do we need to preserve custom time range? i.e

  • go to devconsole
  • select valid project
  • go to monitoring
  • select time range with drag and deop
  • go back to topology and move back to monitoring
  • can see still time range is persisted.

I don't see harm but to be aware if this is expected as on the admin side we don't preserve

@kyoto
Copy link
Member

kyoto commented Jun 28, 2021

Thanks @invincibleJai. I think it would be better if the change were not persisted.

Also, since this is using the same redux entries as the admin Console, this will cause the zoom settings to persist when switching from Dev to Admin Console.

It might be cleaner to use useReducer / useContext instead of Redux in this case (see https://reactjs.org/docs/hooks-faq.html#how-to-avoid-passing-callbacks-down). (Maybe the admin perspective should too.)

@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jul 5, 2021
@andrewballantyne
Copy link
Contributor

Thanks @invincibleJai. I think it would be better if the change were not persisted.

If this is the state we want to go with, then I've approved the current code.

Also, since this is using the same redux entries as the admin Console, this will cause the zoom settings to persist when switching from Dev to Admin Console.

It might be cleaner to use useReducer / useContext instead of Redux in this case (see https://reactjs.org/docs/hooks-faq.html#how-to-avoid-passing-callbacks-down). (Maybe the admin perspective should too.)

Not entirely sure what the follow up point was here @kyoto -- if we wanted to persist it?

@andrewballantyne
Copy link
Contributor

/retest

@kyoto
Copy link
Member

kyoto commented Jul 5, 2021

Not entirely sure what the follow up point was here @kyoto -- if we wanted to persist it?

I think we should not persist it, especially since the change would persist between Dev and Admin Consoles. It would probably be confusing UX.

To be clear, there is no need to change the Admin Console code as part of this PR. I'm just thinking that this Dev Console change should not persist in redux after you leave the page.

@andrewballantyne
Copy link
Contributor

/retest

Copy link
Member

@jerolimov jerolimov left a comment

Choose a reason for hiding this comment

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

Tested with Firefox (which has this image drag and drop issue but two clicks works fine) and Chrome. Sets the custom time range and works as expected 👍

/lgtm

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Jul 14, 2021
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jul 14, 2021

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: andrewballantyne, jerolimov, vikram-raj

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-merge-robot openshift-merge-robot merged commit fbb4361 into openshift:master Jul 14, 2021
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jul 14, 2021

@vikram-raj: All pull requests linked via external trackers have merged:

Bugzilla bug 1972011 has been moved to the MODIFIED state.

In response to this:

Bug 1972011: Fix time range for drag & drop in devconsole monitoring

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@vikram-raj vikram-raj deleted the bz-1972011 branch July 15, 2021 01:00
@spadgett spadgett added this to the v4.9 milestone Aug 30, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. bugzilla/severity-medium Referenced Bugzilla bug's severity is medium for the branch this PR is targeting. bugzilla/valid-bug Indicates that a referenced Bugzilla bug is valid for the branch this PR is targeting. component/dev-console Related to dev-console kind/bug Categorizes issue or PR as related to a bug. lgtm Indicates that a PR is ready to be merged.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants