Hi,

I have fleshed out the code inside ProxyDatabasePlugin.cpp so that it
now works.

I have only lightly tested this, on a basic setup, and I don't no a lot
about mpd, so I can't be sure that everything is working as it should.

One visible problem is a performance issue for the search
operation. Because it is not forwarded to the remote server but done by
walking the tree, the performance is not good (because of the many trips to
the server necessary for exploring each directory). For example on my
configuration, a search which takes 0.4 S on the local server will take 6 S
when using the proxy. The "list" operation which is executed by calling the
"VisitUniqueTags()" method in the Database plugin, and which delegates the
work to the server, does not suffer from the same issue, and it would seem
possible to have the same kind of approach with search (using
mpd_search_db_songs() instead of mpd_search_db_tags()), but this needs a
non-local change (to the plugin interface).

I also had to open up the SongFilter interface a bit (for implementing the
constaints inside VisitUniqueTags().

I think that this plugin could be quite useful in a configuration where
there is a central music store and several independant players: only the
central server has to update().

As as mentionned a couple of months ago, I would like to implement another
equivalent plugin to talk to an UPNP Media Server, I'm just coming back to
it, and exploring the ProxyDatabase one was a good way to see how things
worked on the mpd side.

A patch against the current master branch is attached, I hope that you will
find it useful.

Best regards,

jf

Attachment: mpd-proxydb.diff
Description: Binary data

------------------------------------------------------------------------------
October Webinars: Code for Performance
Free Intel webinars can help you accelerate application performance.
Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from 
the latest Intel processors and coprocessors. See abstracts and register >
http://pubads.g.doubleclick.net/gampad/clk?id=60134071&iu=/4140/ostg.clktrk
_______________________________________________
Musicpd-dev-team mailing list
Musicpd-dev-team@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/musicpd-dev-team

Reply via email to