Commit graph

135 commits

Author SHA1 Message Date
Andrew Kelley
baf5ebeb4e ability to disable streaming in config 2014-03-07 03:10:56 -05:00
Andrew Kelley
2756f4c06f fix crash: call socket.destroy() not socket.close() on error 2014-03-05 00:37:05 -05:00
Andrew Kelley
87f4657484 MPD protocol: fix upgrading protocol ignoring part of the buffer
closes #146

Also fixed a crash when setting consume on/off
2014-03-05 00:33:34 -05:00
Andrew Kelley
9c24952e3f player: fix race condition on initialization. closes #153 2014-03-04 23:58:37 -05:00
Andrew Kelley
72cf1783b7 player: set "don't cache this" headers on stream 2014-03-04 17:19:22 -05:00
Andrew Kelley
71521d90f6 library scanning: always use a trailing slash for readdir 2014-03-04 14:26:01 -05:00
Andrew Kelley
f748199894 extract gzip static middleware to a separate module 2014-03-04 05:46:02 -05:00
Andrew Kelley
c736632282 gzip static assets: store only gzipped assets 2014-03-04 05:03:40 -05:00
Andrew Kelley
9768c840b9 static assets are gzipped and held permanently in memory 2014-03-04 04:58:20 -05:00
Andrew Kelley
223afa1ed0 fix playlist items not being deleted from db during dynamic mode
Might also have fixed a memory leak. Looks like we weren't closing files
when dynamic mode deleted songs from the queue.
2014-03-04 03:36:39 -05:00
Andrew Kelley
3525d6a4e0 MPD protcol: remove unimplemented commands. closes #112 2014-03-04 02:58:05 -05:00
Andrew Kelley
59d0f8cd62 MPD protocol: implement swap and swapid commands 2014-03-04 02:50:26 -05:00
Andrew Kelley
99c92a9203 MPD protocol: implement password and notcommands commands 2014-03-04 02:36:58 -05:00
Andrew Kelley
ea77be50b5 persist playlist on server restart. closes #98 2014-03-04 02:27:31 -05:00
Andrew Kelley
6068a19f3e remove commented out code 2014-03-03 20:51:15 -05:00
Andrew Kelley
a345f24f93 fix crash during upload 2014-03-03 20:40:29 -05:00
Andrew Kelley
bc6ecfb65d default password: multiple of 3 for base64 to avoid ending in '=' 2014-03-03 14:17:50 -05:00
Andrew Kelley
725f10ef97 streaming: 8KB more instant buffering 2014-03-03 12:58:22 -05:00
Andrew Kelley
09f64ecb5c api server: listen for better player events to detect db update 2014-03-03 05:41:54 -05:00
Andrew Kelley
f2712ddaad re-write interface between client and server
* Use raw web sockets instead of socket.io. closes #114
 * promote most plugin code to be actually integrated with
   groovebasin, except last.fm
 * ability to upgrade from mpd protocol to groovebasin protocol
 * serialize/deserialize lastQueueDate and update it for all types of queuing.
   Fixes DynamicMode losing randomness data on server restart.
 * repeat state is saved between restarts
 * fixed a race condition in player.importFile
 * a smaller subset of db file properties are sent to the server, reducing
   library payload size
 * diffs are sent to client for playlist and library. closes #142
 * information is no longer requested in the groovebasin API; it is only
   subscribed to. closes #115
 * all commands go through the permissions framework. see #37
 * chat is deleted for now. closes #17
 * update to latest superagent and leveldb
 * fix stream activating and deactivating when seeking and not streaming
2014-03-03 05:25:50 -05:00
Andrew Kelley
a0c6d8c36d streaming improvements
* server sends data as fast as it can when under the buffer limit
 * client responds to 'seek' events by reconnecting to the stream
2014-02-28 15:27:29 -05:00
Andrew Kelley
5102ef205c MPD protocol: remove unsupported commands 2014-02-28 12:08:27 -05:00
Andrew Kelley
7696b9791f MPD protocol: implement outputs and plchangesposid commands 2014-02-28 12:08:27 -05:00
Andrew Kelley
0ca3c286f2 detect file deletions on startup. closes #116 2014-02-28 12:08:12 -05:00
Andrew Kelley
fbc6386960 fix stupid default password 2014-02-27 18:19:26 -05:00
Andrew Kelley
35354ac81e MPD protocol improvements
* correct permissions for some commands
 * implement search and searchadd commands
 * remove commands that groove basin does not support
 * fix idle not checking read permission
 * fix noidle returning OK twice
2014-02-27 17:53:33 -05:00
Andrew Kelley
406eae55aa MPD protocol: emit Last-Modified-Date for directories where appropriate 2014-02-27 16:38:25 -05:00
Andrew Kelley
667fd0c76f MPD protocol: update command supports uri argument 2014-02-27 11:45:50 -05:00
Andrew Kelley
9be515c764 MPD protocol: listallinfo takes a uri parameter 2014-02-27 10:38:54 -05:00
Andrew Kelley
e937b798e4 MPD protocol: make it more robust
* play command: no args or -1 does "unpause"
 * random command: noop instead of error
 * single command: fix the logic to accept the argument
 * optional ranges allow -1 to mean no argument
2014-02-26 22:29:44 -05:00
Andrew Kelley
c018b6cb3a MPD protocol: implement listall command 2014-02-26 18:52:06 -05:00
Andrew Kelley
b1755a4fd9 MPD protocol: implement findadd command 2014-02-26 18:01:33 -05:00
Andrew Kelley
3a953c22e4 MPD protocol: implement count command 2014-02-26 17:49:09 -05:00
Andrew Kelley
d004ca79e5 MPD protocol: implement find command 2014-02-26 17:16:50 -05:00
Andrew Kelley
585b13bad1 MPD protocol: 'consume' status updated correctly 2014-02-26 14:34:51 -05:00
Andrew Kelley
6e567086d9 route dynamicmode through permissions framework
and connect it to 'consume' MPD protocol command
2014-02-26 14:32:11 -05:00
Andrew Kelley
920884263b MPD protocol: implement currentsong command 2014-02-26 12:55:00 -05:00
Andrew Kelley
f23a31d5db fix updated songs getting duplicate db entries
and implement the 'database' subsystem notification in MPD protocol
2014-02-26 12:46:24 -05:00
Andrew Kelley
e51e19846d MPD protocol: implement the lsinfo command 2014-02-26 05:37:09 -05:00
Andrew Kelley
e8fa0e83a3 rework file scanning and watching to not use polling
use fs.watch instead
2014-02-26 04:46:37 -05:00
Andrew Kelley
054f025064 scrub invalid db entries on startup and other misc cleanups 2014-02-26 02:02:06 -05:00
Andrew Kelley
22a0507595 use a deduped queue for importing tracks. fixes #128 2014-02-25 22:11:09 -05:00
Andrew Kelley
c2e4429e48 MPD protocol: code organization 2014-02-25 21:19:13 -05:00
Andrew Kelley
69aefc0739 MPD protocol: implement the list command and fix batch commands 2014-02-25 03:44:45 -05:00
Andrew Kelley
5951806436 MPD protocol: add a forgotten callback invocation 2014-02-25 01:41:55 -05:00
Andrew Kelley
cf30edab0f MPD protocol: implement playlistid command 2014-02-25 01:33:01 -05:00
Andrew Kelley
b258ac5ce9 MPD protocol: implement move and moveid 2014-02-25 01:09:33 -05:00
Andrew Kelley
0a5cab8370 MPD protocol: use numeric IDs and implement more cmds
Now it (mostly) works with MPDroid Android app
2014-02-24 23:47:37 -05:00
Andrew Kelley
866c7e62d5 MPD protocol: implement deleteid command 2014-02-24 22:46:31 -05:00
Andrew Kelley
3196ba9494 MPD Protocol: implement delete command and fix bug
in player.insertTracks
2014-02-24 22:40:47 -05:00