Skip to content
This repository has been archived by the owner on Oct 13, 2024. It is now read-only.

fix(ui): improve speed of dashboard by caching data #224

Merged

Conversation

ReenigneArcher
Copy link
Member

Description

The data required for the web UI has been slow to load in some cases (using IMDB or IGDB databases). This PR adds the ability to cache the data to improve loading times. The first time the UI is accessed, this will still be slow, but once the data has been cached, it will be nearly instant.

The cache is saved to a file, so that it's available between Plex server restarts.

Screenshot

Issues Fixed or Closed

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Dependency update (updates to dependencies)
  • Documentation update (changes to documentation)
  • Repository update (changes to repository files, e.g. .github/...)

Checklist

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have added or updated the in code docstring/documentation-blocks for new or existing methods/components

Branch Updates

LizardByte requires that branches be up-to-date before merging. This means that after any PR is merged, this branch
must be updated before it can be merged. You must also
Allow edits from maintainers.

  • I want maintainers to keep my branch updated

Copy link

codecov bot commented Nov 17, 2023

Codecov Report

Merging #224 (94d4fc2) into nightly (4f9ffa3) will increase coverage by 0.33%.
The diff coverage is 85.00%.

Additional details and impacted files
@@             Coverage Diff             @@
##           nightly     #224      +/-   ##
===========================================
+ Coverage    67.41%   67.75%   +0.33%     
===========================================
  Files           11       11              
  Lines          841      856      +15     
===========================================
+ Hits           567      580      +13     
- Misses         274      276       +2     
Flag Coverage Δ
Linux 67.75% <85.00%> (+3.30%) ⬆️
Windows ?
macOS ?

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Coverage Δ
Contents/Code/default_prefs.py 100.00% <ø> (ø)
Contents/Code/scheduled_tasks.py 94.44% <100.00%> (+0.32%) ⬆️
Contents/Code/webapp.py 65.45% <83.33%> (+0.98%) ⬆️

... and 1 file with indirect coverage changes

@ReenigneArcher ReenigneArcher force-pushed the fix(ui)-improve-speed-of-dashboard-by-caching-data branch from 4897237 to 94d4fc2 Compare November 17, 2023 00:43
@ReenigneArcher ReenigneArcher merged commit dfda394 into nightly Nov 17, 2023
@ReenigneArcher ReenigneArcher deleted the fix(ui)-improve-speed-of-dashboard-by-caching-data branch November 17, 2023 01:00
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant