-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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
[Visualizations] Opening and closing legend causes data re-fetch #21480
Comments
That's indeed expected behavior right now, but I am open to discuss this again. Lemme shortly explain what's happening: Closing/opening a legend will change the uiState of that chart, since the legend state is something that should be saved. Since refactoring the loader, the visualize embeddable actually listenes on the We had a similar mechanism in beforehand, that mechanism was just a bit broken, why it actually didn't trigger for everything in In case we don't want that refetch when a legend toggles, we should discuss again if we want to refetch on @ppisljar any ideas on that one? |
Just noting this is still an issue in 6.6.0. I don't think it's a blocker for 6.7.0. |
Updates: This is still the desired and expected behavior, so it's still present in 6.6.0 and will also be in 6.7.0 (and most likely beyond). With the switch to the expressions for rendering, that will happen at some point, we're planning to take this into a different direction and refactor the existing visualizations. |
I would be careful to call out of sync panels on dashboards desirable. #11233 doesn't want this behavior either. It might be expected for the time being because of the workaround for the maps like you described but not really desirable. The uiState has changed and in this case there is no reason for it to require a fetch. I found that the code already has some state checking to determine if fetch is required here: Unfortunately it is incorrectly setting fetchRequired to true because of these object checks in the file below that add things to updatedParams when their values have not changed. So technically two fetchAndRender calls are being made for this one event. It seems overkill that all uiState changes are causing fetches because of some map workaround. The checking done in embedded_visualize_handler.ts is what we want. Perhaps we could give visualizations a way to tap into this routine so that they can add to this logic? As it stands right now it doesn't even matter if it properly set the fetchRequired flag because the uiState change is going to call fetchAndRender anyways. |
How long does one have to wait for regressions to get worked? It seems as if there is no point to even issue bugs. This regression when found was happening on master....and it never got prioritized. |
Sorry Jacob, we are hoping to address this issue with a big redesign of our rendering infrastructure we are working on. Unfortunately this is taking us a long time, but i can guarantee we are not ignoring the issued bug reports. |
IMO a regression about data being out of sync on a dashboard should never have needed to wait for a major redesign to be fixed. What’s funny about you saying that is a redesign caused this issue in the first place. This is something that worked until the team broke it with version 6 redesign and now you are saying it won’t get fixed until some other redesign is ready. Do you see how frustrating that logic sounds? |
This has been fixed on master. I am closing it |
This behavior is different from 6.3. Not sure if it's a blocker or not. I think it's a bug because the user can't be sure what time range the data is showing, nor will it be consistent with the other visualizations on a dashboard. Note that we already have some inconsistencies (that exist in 6.3 as well) when you add a new panel - it will display newer data than the panels already on a dashboard.
Below are gifs, but they are a bit difficult to see what's going on, so, to repro manually:
I'll file a separate bug for adding panels causing inconsistent time ranges among the panels (why below you will see the same visualization with different data). That exists in 6.3.
6.3:
![63data](https://user-images.githubusercontent.com/16563603/43463092-c6d9caf2-94a5-11e8-9f4e-ad94fbdafb28.gif)
master [and thus I assume 6.4 as well]:
![64data](https://user-images.githubusercontent.com/16563603/43463438-8f5e0966-94a6-11e8-9a8d-bd0c2a258792.gif)
cc @elastic/kibana-visualizations
The text was updated successfully, but these errors were encountered: