Re: patch #4 (Was: [Rhythmbox-devel] music sharing patch #3)



On Tue, 2005-08-23 at 22:10 +0100, Bastien Nocera wrote:
> On Tue, 2005-08-23 at 16:46 -0400, Charles Schmidt wrote:
> <snip>
> > We aren't, Howl is.  Unfortunatly, this causes a bug.  If you try to
> > share your library as "My Music", and there already is a "My Music"
> > existing on the network, Howl renames yours to "My Music (2)"  Which
> > seems good, until you notice that the mDNS browsing is notified of /all/
> > new shares, including your own.  So that this doesn't appear in the
> > sourcelist, I do a strcmp (network_name, my_shared_music_name), and if
> > they're the same, don't include it.  However, Howl will not notify you
> > if it renames your music with a number suffix.  So, the end result, if
> > your share name is a duplicate is:
> > 
> > Your music is available to everyone as "My Music (2)"
> > "My Music" (the first person's share) will not appear in your
> > sourcelist.
> > "My Music (2)" (your music) does appear in your sourcelist.
> > 
> > This is just a stupid shortcoming in Howl, and I can't see any way
> > around it.  Hopefully avahi doesn't suffer from the same problems.
> 
> How about resolving the service, and checking this instead?

I could.  I had saved the resolving step for when the user clicks on the
server (no sense trying to resolve things if we're not going to use
them).  The difficult there is its yet another callback to resolve,
which makes the whole thing slower.  Also, after resolving, I,
personally, don't know how to compare the resolved IP to ones that the
client computer has (that is, how do I retrieve a list of IPs the
computer has?).  But yes, I suppose it could be done this way.  I just
think its ugly and unjustified - ideally it would be fixed on howl's
end, they have a COLLISION status enumeration value all set up, its just
not used.

> > > > * When loading a daap server the user interface is not updated until it
> > > > the network communications are finished.  Ideally, the network stuff
> > > > should be in a separate thread, or at the very least the daap buffer
> > > > parsing stuff should be done incrementally in a timeout.
> > > 
> > > Yeah...this is going to be important to fix soon actually; consider an
> > > office where you have say 50 people sharing music...  
> > 
> > I'll start working on that as soon as I finish the avahi migration.
> 
> I hope you aren't removing the howl code. Avahi barely had a release,
> howl is already in many distros.

Certainly not. I've abstracted the mDNS code out into a set of
RBDAAPmDNS Browser, Resolver, Publisher APIs that will use either howl
or avahi, depending on which RB was compiled against.  However, given
the license issues surrounding howl,  and the freedesktop.org status of
avahi, I suspect that avahi will gain momentum quickly.  Perhaps I'm
just being hopeful again though.

-charlie



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]