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

Loading albums (local & spotify) very slowly #212

Closed
13 tasks
jonach66 opened this issue Oct 1, 2017 · 5 comments
Closed
13 tasks

Loading albums (local & spotify) very slowly #212

jonach66 opened this issue Oct 1, 2017 · 5 comments

Comments

@jonach66
Copy link

jonach66 commented Oct 1, 2017

Expected behavior

Loading albums (local & spotify) in acceptable time

Actual behavior

Loading albums (local & spotify) very slowly and again every time clicking on menu "Albums"

Steps to replicate

  1. Iris in browser and clicking menu "Albums"
  2. recklicking "Albums" and the loading process starts again

Tested environment(s)

Operating systems affected

  • [ x] Windows:
  • Mac:
  • [x ] Linux:
  • iOS:
  • [x ] Andriod:
  • Other:

Browsers affected

  • [ x] Chrome:
  • Firefox:
  • Internet Explorer:
  • Opera:
  • Other:

Screen sizes affected

  • Huge (ie desktop)
  • Large (ie laptop)
  • Medium (ie slim laptop/tablet)
  • Small (phone)

Additional details, debug data, logs, etc

  • Was not happening in versions older than 3.3
  • IRIS / MOPIDY is running on headless Voyage Linux 0.10.0
  • local albums are stored on same HDD than OS
  • mopidy config:

[core]
cache_dir = $XDG_CACHE_DIR/mopidy
config_dir = $XDG_CONFIG_DIR/mopidy
data_dir = $XDG_DATA_DIR/mopidy
max_tracklist_length = 10000
restore_state = false

[logging]
color = true
console_format = %(levelname)-8s %(message)s
debug_format = %(levelname)-8s %(asctime)s [%(process)d:%(threadName)s] %(name)s\n %(message)s
debug_file = mopidy.log
config_file =

[audio]
mixer = none
mixer_volume =
output = alsasink
buffer_time =

[proxy]
scheme =
hostname =
port =
username =
password =

[mpd]
enabled = true
hostname = ::
port = 6600
password =
max_connections = 20
connection_timeout = 60
zeroconf = Mopidy MPD server on $hostname
command_blacklist =
listall
listallinfo
default_playlist_scheme = m3u

[http]
enabled = true
hostname = ::
port = 6680
static_dir =
zeroconf = Mopidy HTTP server on $hostname

[stream]
enabled = true
protocols =
http
https
mms
rtmp
rtmps
rtsp
metadata_blacklist =
timeout = 5000

[m3u]
enabled = true
base_dir =
default_encoding = latin-1
default_extension = .m3u8
playlists_dir =

[softwaremixer]
enabled = false ; Extension disabled by user config.

[file]
enabled = true
media_dirs =
/mnt/Data/music
excluded_file_extensions =
.jpg
.jpeg
show_dotfiles = false
follow_symlinks = false
metadata_timeout = 1000

[local]
enabled = true
library = sqlite
media_dir = /mnt/Data/music
scan_timeout = 5000
scan_flush_threshold = 100
scan_follow_symlinks = false
excluded_file_extensions =
.directory
.html
.jpeg
.jpg
.log
.nfo
.png
.txt

[tunein]
enabled = true
timeout = 5000

[spotmop]
enabled = true
debug = false
pusherport = 6681

[oe1]
enabled = true

[musicbox_webclient]
enabled = true
musicbox = false
websocket_host =
websocket_port =
on_track_click = PLAY_ALL

[mopify]
enabled = true
debug = false

[moped]
enabled = true

[local-sqlite]
enabled = true
directories =
Albums local:directory?type=album
Artists local:directory?type=artist
Tracks local:directory?type=track
timeout = 10
use_album_mbid_uri = true
use_artist_mbid_uri = false
use_artist_sortname = true

[local-images]
enabled = true
library = json
base_uri = /images/
image_dir =
album_art_files =
*.jpg
*.jpeg
*.png

[iris]
enabled = true
country = NZ
locale = en_NZ
authorization_url = https://jamesbarnsley.co.nz/auth_v2.php

[spotify]
enabled = true
username = jonach-at
password = ********
bitrate = 320
volume_normalization = false
private_session = false
timeout = 10
allow_cache = true
allow_network = true
allow_playlists = true
search_album_count = 50
search_artist_count = 50
search_track_count = 50
toplist_countries =

[spotify_tunigo]
enabled = true
region =
sub_genres = true
cache_time = 3600

Before you submit

  • Yes, I have tested this issue thoroughly
  • [x ] Yes, I have attached screenshots and/or screencast of the issue in action
  • Yes, I have included any relevant debug data and error logs
    image
@jaedb
Copy link
Owner

jaedb commented Oct 1, 2017

The reason this takes such a long time is that Mopidy doesn't provide additional album information off-the-bat. We need to lookup each individual album and scrape the artwork, artist, full title, etc. The time required to complete this depends on two key factors: your server capability and the size of your library.

Under Steps to replicate you mention clicking elsewhere, and then clicking back to My Albums causes the loading to start again. Can you please confirm that the loading process is not, in fact resuming (look at the number of albums loading)? Even when navigating elsewhere, the albums will continue to load in the background. This is of course provided you haven't refreshed your browser.

@jonach66
Copy link
Author

jonach66 commented Oct 3, 2017

Thank you for your prompt reply, and for that great piece of software!!
Will do several tests over the weekend with/without local albums and with smaler local library to better understand the issue.

@jaedb
Copy link
Owner

jaedb commented Jul 1, 2018

An aside to this, I'm wondering whether a less-intensive but equally-performing caching approach could be to use client-side service workers to cache requests. Browser support is okay (and growing) but I'd like it to be more widespread before making this core functionality.

@jaedb
Copy link
Owner

jaedb commented Jul 1, 2018

Related #162

@jaedb
Copy link
Owner

jaedb commented Nov 23, 2020

Resolved by #600

@jaedb jaedb closed this as completed Nov 23, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants