visualize-admin / visualization-tool

The tool for visualizing Swiss Open Government Data. Project ownership: Federal Office for the Environment FOEN
https://visualize.admin.ch
BSD 3-Clause "New" or "Revised" License
32 stars 3 forks source link

perf: Only load key dimension and measure values during chart initialization #1890

Closed bprusinowski closed 5 days ago

bprusinowski commented 1 week ago

Closes #1658

This PR optimizes performance of initializing charts based on cubes with non-key dimensions by limiting these dimensions and measures selection to only include key dimensions.

We do it by re-using DataCubePreview query, which in most of the cases is loaded and cached before starting a new chart that loads components metadata, so we know which dimension is a key dimension.

vercel[bot] commented 1 week ago

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
visualization-tool ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 20, 2024 3:34pm