Introduction
As mobile and ubiquitous computing environments evolve, applications increasingly rely on "context"—real-time information such as a user's location, the current crowd level in a shop, or ambient temperature. However, building these context-aware applications is challenging because data is often scattered across heterogeneous devices and changes rapidly. This paper introduces the Context Data Management System (CDMS), a scalable middleware designed to bridge the gap between raw sensor data and high-level application logic.
The Challenge of Distributed Context
Traditionally, developers had to hard-code connections to specific data sources. This approach fails to scale; if a sensor moves or a new device enters the network, the application logic breaks. Furthermore, context data is highly dynamic and becomes "stale" quickly. The authors identify two primary hurdles: efficient source organization and rapid lookup. The goal is to allow developers to find the right data at the right time without needing to manage the underlying network complexity.
System Architecture
The CDMS employs a decentralized architecture that organizes data sources into semantic peer-to-peer (P2P) overlays. The system consists of three primary layers:
- The Server: Provides a central interface for context queries and manages global metadata.
- Context Spaces: Data is organized into logical domains such as "OFFICE," "HOME," or "PERSON." Within these spaces, sources providing similar attributes (e.g., temperature) form semantic clusters.
- Physical Space Gateways (PSGs): These software modules act as bridges, registering local sensors with the wider system and handling local data processing.
To simplify development, the CDMS provides a SQL-like query interface. Instead of complex networking protocols, developers can issue standard queries like SELECT location FROM PERSON WHERE name = "Keith". The system also includes automated schema matching to resolve naming discrepancies (e.g., mapping "temp" to "temperature") using linguistic algorithms.
Experimental Evaluation
The authors evaluated a Java-based prototype of the CDMS by virtualizing between 200 and 1,000 Physical Space Gateways. Each space was assigned 30 random context attributes to simulate a diverse real-world environment.
Key Results
- Registration Latency: A new physical space can register and join the network in approximately 1.2 seconds. The majority of this time is spent identifying and joining the appropriate semantic clusters.
- Query Performance: For a network of 1,000 sources, the total query response time was roughly 0.9 to 1.0 seconds.
- Bottleneck Analysis: As shown in the performance breakdown, approximately 90% of the query latency is attributed to the P2P lookup process itself, suggesting that the efficiency of the underlying P2P protocol is the primary constraint on system speed.
- Data Accuracy: The system achieved 100% recall (finding all relevant data sources) when the query Time-To-Live (TTL) was set to 6 or higher, demonstrating that semantic clustering effectively routes queries to the correct nodes.
Conclusion and Future Work
The CDMS demonstrates that decoupling data discovery from application logic through semantic P2P overlays is a viable path for scalable context-aware computing. While the current prototype uses a basic Gnutella-style flooding mechanism, future iterations could benefit from more sophisticated protocols like Distributed Hash Tables (DHTs) to further reduce network traffic. Additionally, the authors plan to expand the reasoning engine to handle more complex, multi-domain logic and improve lookup speeds for highly dynamic data.
Summary updated