Bug 6683 - Refactor: Server and player discovery
: Refactor: Server and player discovery
Status: CLOSED FIXED
Product: SB Controller
Classification: Unclassified
Component: Setup
: unspecified
: PC Windows XP
: P2 normal (vote)
: 7.1
Assigned To: Richard Titmuss
:
Depends on:
Blocks: 5378 7258 7862 8177 8252 8456
  Show dependency treegraph
 
Reported: 2008-01-20 13:25 UTC by Richard Titmuss
Modified: 2008-08-04 14:05 UTC (History)
0 users

See Also:
Category: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Richard Titmuss 2008-01-20 13:25:30 UTC
The current way of doing server and player discovery is a bit limited, and does not cover all cases. In particular the udap method of controlling a player was originally only intended for player setup however it has become clear that this needs to be integrated into the core classes. Some recent changes have started this process by more refactoring is needed.

- SlimDiscoveryApplet needs to be removed, this is now offering little functionality over the SlimServers.lua

- SlimServers.lua needs to be renamed, maybe SqueezeDiscovery.lua and available as a global class

- Player.lua needs extending, as well as including Players connected to SC/SN it also needs to model players just discovered by udap. The connect() method in Player should use SC/SN or udap to move the player between servers as appropriate for the player state.

- SqueezeDiscovery.lua should use udp to search for SC and Players in the background all the time. SC connections should be made on an as needed basis.

- SelectPlayerApplet, SelectMusicSourceApplet and SetupSqueezeboxApplet will need updating to reflect these changes. At the moment these applets don't always take the correct action, for example the SelectMusicSourceApplet will always use SC/SN to move a player and never udap.

- Both SelectMusicSourceApplet and SetupSqueezeboxApplet include code for selecting from the available music sources. SetupSqueezeboxApplet needs to be modified to use the same code as SelectMusicSourceApplet.

- Other applets, for example SlimBrowserApplet will also be affected.

This should be considered for 7.0.1.
Comment 1 Richard Titmuss 2008-01-20 13:39:12 UTC
*** Bug 6673 has been marked as a duplicate of this bug. ***
Comment 2 Richard Titmuss 2008-02-01 12:54:03 UTC
Note that these also need to use a monotonic clock, not os.time().
Comment 3 Richard Titmuss 2008-06-26 00:32:12 UTC
Fixed in 7.1 r2600.
Comment 4 Chris Owens 2008-07-30 15:32:31 UTC
This bug has now been fixed in the 7.1 release version of SqueezeCenter!  Please download the new version from http://www.slimdevices.com if you haven't already.  

If you are still experiencing this problem, feel free to reopen the bug with your new comments and we'll have another look.