Add option to configure the default identity in ServiceDiscoveryManager

Description

Add option to configure the default identity used by ServiceDiscoveryManager. It's currently hardcoded to 'client', 'pc' 'Smack'.

Environment

None

Activity

Show:

Florian Schmaus 
October 31, 2013 at 11:31 AM

The idea was that there has to be at least one identity. I had a code version where this was assured by using just one identities set, which resulted in a lot of management overhead.
The current code can easily be fixed.

Georg 
October 31, 2013 at 10:48 AM

The current code leads to inconsistencies: there are two variables to maintain the client identity: identity for the "primary" one and identities for listing all of them.

setDefaultIdentity() (as well as set/getIdentityName() and set/getIdentityType()) only affect the former variable, while the discovery info is generated from the latter.

To change the latter, however, addIdenity() has to be called. I am not sure if it is wise to keep two different variables in the SDM (is identity just a reference to one element of identities?). The current state of affairs is that the code is not working as expected.

Fixed

Details

Assignee

Reporter

Components

Fix versions

Affects versions

Priority

Created October 26, 2013 at 11:31 PM
Updated August 17, 2014 at 1:11 PM
Resolved October 31, 2013 at 8:39 PM