discovery: introduce session to discovery
Currently we have only one discovery instance per runtime and all
discovery clients share the same instance. Although this makes sense
and required, it may cause inconvenience in some cases like when a
user wants to excludes services that are advertised by the same
discovery client.
This change introduces 'session' to discovery so that we can
distinguish discovery clients including
o simplify discovery.T interface
- remove unnecessary/not-used interfaces.
o make discovery.T as a sessioned discovery and change v23 API for
getting discovery instance.
o change scan() to filter out advertisements from the same discovery.T
instance.
o remove discovery service
- the current interface is not sufficient. E.g., there is no way
to remove obsolete advertisement.
- discovery as a service doesn't make sense for now.
- if needed, we can add it again with more complete
api/implementation later.
MultiPart: 4/4
Change-Id: I3df1dab7dd2b9d42e82a20247df44baf92f822cd
1 file changed