This is an old revision of the document!

Distributed Objects for Real

Over the past year, a number of researchers at the Software Languages Lab have been involved in experiments designed to uncover new programming abstractions to facilitate the development of mobile RFID-enabled applications.

During these experiments, we have approached the development of such applications from two opposing perspectives, which are briefly described below.

Volatile Data Clouds

The volatile data clouds model can be considered a special case of Reactive Context-Aware Programming specifically applied to the domain of mobile RFID-enabled applications.

The volatile data clouds model considers RFID tags to be data containers whose presence or absence can be used to steer the application. Therefore, it focusses on designing a general means to represent the collection of currently visible tags.

Since the collection is implicitly tied to the environment and changes frequently in response to events emitted by the RFID reader, change is at the very heart of the model. To permit application developers to respond to and propagate these changes without having to explicitly register a plethora of observers, we borrow concepts from reactive programming.

Concretely, the collection of visible tags is modeled as a reactive collection. In order to test for the presence of a particular tag, one can invoke the contains method of the reactive collection, which results in a new dependent reactive value. That value is transparently updated whenever the collection changes. This automatic propagation of changes to a reactive collection of RFID tags is a determining factor in the expressiveness of applications that use the volatile data cloud metaphor.

Another important aspect is efficiently detecting when interesting patterns occur in a reactive tag collection. A pattern of interest can be the presence of a particular (kind of) tag, but should extend to combinations of interesting tags. To detect such occurrences, we make use of pattern matching rules which can be applied to any reactive collection. This technique allows building RFID applications using a declarative programming style.

Tags Objects

The tag objects model represents RFID tags as full-blown objects, which introduces a natural mechanism to deal with mutable tag data. More information as well as videos of our experiments can be found here.

While the volatile data clouds model considers RFID tags to be containers of data which is to be filtered and interpreted by the application, the tag objects model conceived them as hosts for full-fledged objects, which encapsulate mutable state and provide their own methods.

When interacting with these tag objects, one has to deal with the ephemeral nature of the connection between the mobile RFID-enabled application and any particular tag. The concerns to be addressed when interacting with tag objects closely mimic those that govern the interaction with classic remote objects:

First of all, mobile RFID-enabled applications need a means to detect when a particular RFID tag has come into range. As RFID tags are modeled as devices hosting an object, the most natural mechanism to achieve this is to use the default service discovery mechanisms of AmbientTalk.

Once a tag object has been discovered, the application can start to interact with it. However, if either the user of the application or the tagged object is roaming, it is extremely likely that the tag will (temporarily) go out of range. Hence, application programmers are provided with far references to the tag objects. This design ensures that tag objects can only be addressed using asynchronous messages and it implies that when a tag goes out of range, all messages that are sent to it are buffered. Subsequently, when the tag comes in range again, these buffered messages will be flushed and forwarded to the tag.

By aligning tag objects with remote objects, one can develop mobile RFID-enabled applications without having to learn about a new concept. Furthermore, application programmers can rely on the entire arsenal of abstractions to deal with remote objects. For instance, one can be notified of disconnection using the default disconnection and reconnection listeners.

A particularly interesting abstraction when developing mobile RFID-enabled applications are ambient references. First of all, such references introduce mechanisms to clearly specify which objects one wants to refer to (i.e. one can impose additional constraints beyond the type of the object). Additionally, ambient references provide a mechanism to implicitly denote and send messages to a collection of (tag) objects.


Having implemented both models, it remains unclear whether one of the models presented in this paper is to be preferred over the other. As it stands, both models have shown to cater to different kinds of applications. Moreover, when analysing the strengths and weaknesses of each of the models, they have shown to be largely complementary.

The volatile data clouds model treats RFID tags as simple containers of data and aims at providing applications with expressive means to represent a collection of nearby tags which is constantly in flux. Consequently, the model focusses on being able to expressively filter such collections and detect the presence of (a combination of) tags, to which the application can respond. Using volatile data clouds as a means to represent nearby tags allows the programmer to abstract over the events that underly the discovery of new tags and the handling of their disappearance. The cost incurred by using these abstractions is the need for a rather heavy-weight infrastructure to properly handle reactive computation. Furthermore, this model considers RFID tags almost exclusively as a means to indicate the presence of a physical object in close proximity to the device that is running a particular application.

The tag objects model on the other hand treats the contents of an RFID tag as a full-fledged object. This makes the model capable of interacting naturally with tags that contain marshalled objects and makes it particularly interesting to model interactions with active tags. Active tags are RFID tags which contain their own power source and are capable of independently performing (some limited form of) computation. Another advantage is that the model only requires a service discovery mechanism and a means to buffer messages, which makes it considerably more light-weight that the volatile data clouds model. The downside of this method that it provides only crude support to detect the presence of (combinations of) tags in the environment. Furthermore, the application needs to explicitly provide listeners to react to the events signalling the disconnection or reconnection of a tag.

In all likelihood, a programming model that fully leverages the advantages of a world teeming with tagged objects will incorporate elements of both models presented here.

Further Reading

* Distributed Objects for Real. Stijn Mostinckx, Andoni Lombide Carreton, Kevin Pinte, Wolfgang De Meuter. Technical report, 2010, Vrije Universiteit Brussel pdf

research/doforreal.1280924726.txt.gz · Last modified: 2010/08/04 14:36 by stijnm
Recent changes RSS feed Creative Commons License Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki