Re: Discovery API proposals: call for comments

Hi Robin,

We have a similar use case which might be met by a discovery API:

A user is accessing an application that can send text messages. However, the application may be in one of several contexts which may require a different implementation of the standard messaging API, for example:
- If the application is running on a mobile device, and the device is operating in its home network, then use the local device API
- if the application is running on a device that doesn't support the messaging API as a local device API, and the user is in Germany, use an implementation of the API for the SMS gateway at the user's company
- if the application is running on a device that doesn't support the messaging API as a local device API, and the user is elsewhere, use a generic free public SMS sending service
(OK, not a complete policy set there but I think you get the idea)

This is not quite the same as home network discovery, but may require a similar mechanism. In this case the discovery function is envisaged as returning an object conforming to an interface spec (Messaging) rather than metadata.

So far we were using a lazy loader and some commonJS conventions (such as exports), e.g.:

		   
        var msg = "sms:+9912341234?body=Hello%20World"

 	// Get an instance of the DeviceMessaging interface and pass to "send" function
	loader.load("DeviceMessaging",  send);        
        
	// Send the message
        function send(deviceMessaging){
            deviceMessaging.sendMessage(msg);
        }

(The "loader" in our case calls a server-side service registry, passing along system info context metadata (e.g. roaming status, location).)

Hope this helps,

S

On 20 Sep 2011, at 08:57, Robin Berjon wrote:

> Hi all,
> 
> there have been two primary proposals for a Discovery API that would enable web pages to (shockingly enough) discover services (on the device, the local network, or possibly remote) through common mechanisms such as DNS-SD or UPnP.
> 
> One of them comes from Opera:
> 
>    http://people.opera.com/richt/release/specs/discovery/Overview.html
> 
> And the other comes from Webinos:
> 
>    http://dev.webinos.org/deliverables/wp3/Deliverable32/static$42d2e5ab28271945244cdeb7579c65fd.html
> 
> Ideally, we'd like to start with either of those and, if sensible, make sure it supports the use cases of the other. We're therefore calling for feedback from anyone interested in this topic.
> 
> Please direct replies towards public-device-apis@w3.org where the work is taking place. Thanks!
> 
> -- 
> Robin Berjon - http://berjon.com/ - @robinberjon
> 
> 

Received on Wednesday, 21 September 2011 10:44:20 UTC