post-christmas special gifts

8 views
Skip to first unread message

esion

unread,
Feb 25, 2011, 5:26:17 PM2/25/11
to Streeme
Hello, I would like to throw some suggestions or questions before
starting hack again.

Desktop app:
By default, It would be great to order songs by artists, albums AND
track id.
The both div artists and albums may have a height dynamically set
(lcbrowseartist, lcbrowsealbum).

Mobile app :
Why the lists of artists/albums are not preloaded?

Richard Hoar

unread,
Feb 25, 2011, 11:57:30 PM2/25/11
to str...@googlegroups.com
I had it this way, but something made it very slow on large libraries in the GROUP BY command. If you can think of an efficient way to do it that works across all the databases (mysql, postgres and sqlite) I'd love to know! I really like having newest songs ordered by artist album and track#. number.

By default the artists are ordered by "A" which should match and A* wildcard. Perhaps you don't have anything  in your library beginning with the A character? maybe this should be fixed too.2

-Rich

esion

unread,
Feb 26, 2011, 3:11:49 PM2/26/11
to Streeme
Ok for the first point, I just saw the default desktop song list is
ordered by newest songs
@see. js/player/desktop/streeme.js
l.150
/* default sorting by newest songs */
"aaSorting": [[ 4, "desc" ]],

It is just strange, I believe the sort on track id was forgotten.
In my opinion, "aaSorting": [[ 3, "asc" ]] (artist/album/tk) should
be a a good choice, isn't it?

On 26 fév, 05:57, Richard Hoar <chaffn...@gmail.com> wrote:
> I had it this way, but something made it very slow on large libraries in the
> GROUP BY command. If you can think of an efficient way to do it that works
> across all the databases (mysql, postgres and sqlite) I'd love to know! I
> really like having newest songs ordered by artist album and track#. number.
>
> By default the artists are ordered by "A" which should match and A*
> wildcard. Perhaps you don't have anything  in your library beginning with
> the A character? maybe this should be fixed too.2
>
> -Rich
>

Rich

unread,
Feb 27, 2011, 10:56:05 PM2/27/11
to Streeme
What might be a good idea is to add a setting to app.yml to change the
default ordering for the song/artist/album lists. That way everyone
can have their own Streeme list settings.

I tried to add in a sort by track/album/newest and it's still a bit
slow.. I think I'm going to have to add a date modified field to the
album list to do it without a lot of wasted time.

-Rich

esion

unread,
Mar 1, 2011, 4:12:10 PM3/1/11
to Streeme
Yes it is a good solution. Then I've an another suggestion afterward,
make those kind parameters more user friendly to set and in the same
way, make the app "install and play" by clicking on only one button.

Streeme is a very cool app and it was not so hard to install for me (I
use symfony every days). But I think it becomes difficult and more for
people who doesn't work on web jobs.
The vm is a good idea, I'm not sure it will be enough to make streeme
more popular.

I was thinking about a simple module or app "installer/config" witch
launch tasks and configure parameters.
Then it is possible to use sfYaml to set custom parameters (eg. path
to music folder, default songs order) but it can be dangererous for
performance, the yaml is not exported to php like sfConfig.

Anyway, I tried to modify the navigation on mobile app, to show all
artists instead of click on the first letter. I know it could be
better, it is more a test for now. I'l try to commit on github as soon
as possible.

esion

unread,
Mar 6, 2011, 2:45:20 PM3/6/11
to Streeme
Well I watched queries and I think some indexes are missing, I didn't
do any explain plan on those but I suppose an indexe is required on
each fields where the dbms (database management system) will work.
Also I remember pgsql doesn't create automatically relational indexes
(eg. album.id_artist) with doctrine schema.

Well I think those indexes could improve the listing of songs :
songs.tracknumber (for sort by artist/album/tracknumber)
album.name
artist.name

By the way, what is a "large songs library"?
The query for 10, 30 or 50 000 tracks should not be a problem but the
hydration could be.

And I'm not sure that cache the results make the app more fast.

Rich

unread,
Mar 6, 2011, 11:49:03 PM3/6/11
to Streeme
I fixed your newest/track ordering issue in the latest patch I think.

here's all the indexes on song, and yup - tracknumber isn't one of
them - I'll add it for a migration release
indexes:
artist_index:
fields: [artist_id]
album_index:
fields: [album_id]
genres_index:
fields: [genre_id]
unique_id_index:
fields: [unique_id]
last_scan_id:
fields: [last_scan_id]
songname_index:
fields: [name]
songmtime_index:
fields: [mtime]
songyearpublished_index:
fields: [yearpublished]
songlength_index:
fields: [length]

The largest library I've heard so far is 50000 songs - that's so many!
the query/result cache in mysql makes a big difference, not sure about
the other dbms's. I'm testing on my personal library that has about
7-8k songs in it.

-Rich

esion

unread,
Mar 7, 2011, 3:34:16 AM3/7/11
to Streeme
Oh I also forgot for specific sort (same example again : artist/album/
TK) multiple fields index would make the query more efficient :
sort_index:
fields : [artist_id, album_id, tracknumber]

Rich

unread,
Mar 9, 2011, 3:21:15 AM3/9/11
to Streeme
Right you are.. I'm rolling that out in the next patch - big speed
boost with the two new indexes.

-Rich
Reply all
Reply to author
Forward
0 new messages