Professional Documents
Culture Documents
Abstract. The past few years have marked a shift in Web development as users
have become accustomed to Web applications with dynamic content and en-
hanced user experience. New emerging protocols and standards seek to provide
increased flexibility by making available new models of interaction to Web ap-
plications. One such application is the Web of Things. In this paper, we propose
a new lightweight architecture for the Web of Things, based on RESTful ap-
proaches. We further show, through a proof of concept application, taking a
smart city as its context, how new technologies can be combined to support our
proposed architecture and application development for the Web of Things. We
argue that the use of protocols and standards such as WebSocket, WebSocket
API, Server-Sent Events and JSON, the JavaScript Object Notation, can make
the vision of the Web of Things a reality.
1 Introduction
Users have long been accustomed to consuming services offered over the Internet
using web browsers. However, with Apple and Google’s launch of the smartphone era
in 2007-8, users have also started to consume services and acquire vast amounts of
information when they are on the move. This trend has grown exponentially since
then, with smartphones dominating today’s cell phone markets. A separate but related
trend has been that of an increasing number of hitherto standalone devices and sensors
now being endowed with wired/wireless connectivity. Together, these two have given
rise to the Internet of Things (IoT), a global information network consisting of
trillions of smart objects in the world we live in [1].
Whilst the IoT has identified application areas such as supply chain management
[2], healthcare [3,4], and workplace support [5], issues raised by the new infrastruc-
ture include managing and making sense of the massive amount of data generated
F. Daniel, G.A. Papadopoulos, P. Thiran (Eds.): MobiWIS 2013, LNCS 8093, pp. 248–259, 2013.
© Springer-Verlag Berlin Heidelberg 2013
A Lightweight Architecture for the Web-of-Things 249
This section describes the basic concepts and technologies, which can potentially be
used to design and develop Web of Things applications.
reusing existing, well-accepted standards and practices such as HTTP, URI and REST
(REpresentational State Transfer).
Such RESTful technologies [11] have obvious advantages when compared against
approaches based on the by now traditional Web Services Architecture (SOAP,
WSDL, UDDI) – they are lightweight, loosely coupled, require relatively little
computing resources and virtually no operating system support, and scale well.
All of this means that one can embed tiny Web servers and, by using the REST
architectural style (which is the same as that of the web, i.e. based on HTTP, URIs
and HTML/XML) one can build scalable interaction models at the application layer
[12, 13].
Thus, a scenario whereby smart objects on the Web start abstracting and describing
their services using either XML or JSON (JavaScript Object Notation), which are
both human and machine readable, can easily be envisaged. In so doing, such smart
objects can be accessed and interacted with via Web browsers. Indeed, assuming a
user with appropriate technological skills, there is no reason why such users cannot
create mash-ups, combining real-world physical devices with virtual services made
available over the Web – all combining towards a Web of Things [14, 15].
3 Research Challenges
The future of WoT holds many promising ideas, and generates great research interest
from researchers, businesses and industry. All application domains can benefit from
A Lightweight Architecture for the Web-of-Things 251
WoT solutions and areas such as disaster prediction; smart homes; medical applica-
tions; transport systems; smart cities and security systems are some of the most com-
mon examples. Some of the possibilities and research challenges of the WoT and
cloud computing are highlighted in the following table.
Other and related areas represent as well research challenges for WoT and com-
monly mentioned are identification of objects, sensing of environment, information
ownership, continued absence of standards and security/privacy [18] [19]. Although
highly important and relevant, we would like to draw the attention to the somewhat
less commonly discussed one level higher of abstraction. The application layer,
which allows for the use of IoT data/information and which ties everything together
in WoT solutions, will be the primarily focus. From Table 1 there are several im-
portant issues to deal with and we would like in this article to focus on growth in
application use and interoperable communication. We do see all these properties as
important, independent research issues with unique attributes. We chose to focus on
architectural issues, interoperability and growth as we do think they are of essential
value and need to be in place for the technology to gain sufficient importance and
adaptation.
User/Application Layer
Things Management
Layer
Data Store
1
http://www.arduino.cc/
A Lightweight Architecture for the Web-of-Things 253
such as web services. In the proposed architecture, we exploit the RESTful architec-
ture of web services in order to transparently represent the data and functionality of
the physical devices and to hide their underlying complexity and low level details.
RESTful architecture is more appropriate to the characteristic of the devices in WoT
as it is lightweight and loosely coupled. We enable information exchange through the
use of JSON structured data, and business logic is applied through common software
engineering components.
This layer represents user applications that interact with the TSL in order to make
requests and consume services. For example, user request can be checking the tem-
perature of a given location or adjusting lights in a room or building. Communication
will go through the web services described in the TSL and they can be accessed from
virtually any web component, device and implementation language.
5 Scenario
In a vibrant city environment we are constantly overloaded with information from
various sources. As more and more objects are becoming smart and interactive there
are constant feeds trying to communicate with us. Such communication is often
achieved through connection with our mobile devices. The mobile device can through
Bluetooth, RFID and NFC be an integrated part of the environment, consuming
information from nearby posters, bulletin boards or integrated sensors. They can
actively push and pull information facilitating for, i.e., commercial displayed informa-
tion on devices tailored accordingly to context, location and interests. In such an envi-
ronment with potential information overload, the information acquired needs to be
precise and tailored. Various forms of distribution or filtering of this information
networks are available, but we take this one step further to propose a proactive model
for this by using our proposed architecture framework (Fig 2).
254 T.-M. Grønli, G. Ghiinea, and M. Younas
By using this framework k a user moving around in a city would end up with filterred,
tailored and personally adap pted information on his/her mobile device. General utiliiza-
tion could be: the customerr needs to find the fastest route to a specific address; a rrec-
ommendation for a particullar shop to purchase the desired product from based on IoT
information aligned with personal
p preferences; recommendation of shops to visiit in
order to fulfil the needs of the shopping list. Application usage and examples scennar-
ios are numerous, but neverrtheless it is important how this information is going too be
made available. By applyin ng a service, management and interface layer we provvide
three levels of abstractions allowing for service composition in each step. The phyysi-
cal Arduino devices will bee wrapped in the interface layer, concealing all communiica-
tion needed for physical Io oT sensor access. Through the management layer businness
logic can be built and wraapped for access from the service layer. The service laayer
will then provide the physical IoT sensors available as services to end users/
applications. This will thenn facilitate taking advantage of a modern event based arcchi-
tecture communication from m Node.js.
A Lightweight Architecture for the Web-of-Things 255
Given an environment consisting of a rapid growing number of smart objects that can
sense, measure, record, transmit and provide services this brings to the table a whole
new range of possibilities and challenges. Despite the WoT being excellent for mak-
ing things smart, it still needs a wrapper to be able to offer aggregated data from its
IoT sensors. Previous research has dealt with sensor communication and data
aggregation as separate matters [6, 7, 20]. Earlier approaches have often used tradi-
tional client server programming model in a layered architecture fashion. Though
nothing wrong with this, we see the possibility for a cleaner maintenance model, the
architecture and easier options for dynamic growth based on our suggested Frame-
work architecture. We build upon a popular technique to efficiently and flexibly man-
age concurrent interactions on the server in event-driven programming. This approach
makes use of asynchronous procedure calls that are executed in the order they are
created [20] and such event-driven programming provide performance and flexibility
benefits over traditional synchronous approaches.
6.1 Node.js
The interest of JavaScript on the server has increased lately by the introduction of a
new event-based framework named Node.js [21]. Node.js differs from other efforts by
providing an event based framework intended for writing scalable Web servers by
utilising JavaScript. It does not use the commonly used concurrency model based on
threads, but employs an event model that makes input and output with network and
files asynchronous and non-blocking [21]. This makes it suitable for new protocols
and standards such as WebSocket and Server-Sent Events, which rely on having an
open connection to the server. In order to facilitate for modern WoT application archi-
tecture, we have in our framework architecture demonstrated how this technology can
be applied to gain an advantage.
[“MessageType”, ConnectionId,
C MsgID, “Message”, “TimeStamp”]
The use of a JSON array th herefore facilitates for new WoT components to be eaasily
included in communication n, thus not slowing network growth and aiding scalabiility
(in its absence, one would have
h to code specific parsers for each new data type useed).
This would provide supporrt for infinite scaling of the solution when deployed tto a
cloud vendor. Results fromm a comparison between a Node server and a Jetty servver,
show how much more efficient Node is in handling concurrent requests (Fig 3).
From Fig 3 we can see that the response time for Node stays considerably bellow
what the Jetty server uses until they both reach peak load at 14000 concurrrent
requests. Another perspecttive on growth of application usage will be the abilityy to
add and remove IoT senso ors as one pleases to the WoT network. In a vibrant ccity
environment this will be a daily task as sensors come and go/turned on and off.
A Lightweight Architecture for the Web-of-Things 257
Applying Node.js for this task increases the utilization of common resources and a
shared background. Using common standards enables interoperable communication
both among WoT smart objects, but also among WoT solutions if desired. The light-
weight footprint of Node.js enables focus on implementation logic and component
interoperability.
7 Conclusion
The field of Web development has been characterized by a lack of coherent architec-
tural concepts, partly due to the absences of standard protocols that support modern
communication styles. As a result of this, systems specifically designed for real-time
data delivery have been realized with proprietary technology in the industry, often
violating established software engineering principles. The danger is that the vision of
the Web of Things will also suffer from the same drawbacks. In this article, we
address this issue and propose a new, lightweight architecture for the WoT.
Taking the case of a smart city, we implement a proof-of-concept application based
on the proposed architecture, which uses modern technologies such as Node.js and
JSON and show how IoT devices are accessed and managed through WoT services
managed by a Cloud solution. We see this as an incremental step towards further
eliminating the borders between smart objects and the data they generate on mobile
clients. Future research should further explore the possibilities for strengthening and
standardizing such a service environment, as well as addressing important issues such
as privacy, security and real-time response needs.
References
1. Kortuem, G., et al.: Educating the Internet-of-Things Generation. Computer 46(2), 53–61
(2013)
2. Konomi, S., Roussos, G.: Ubiquitous Computing in the Real World: Lessons Learnt from
Large-Scale RFID Deployments. Personal and Ubiquitous Computing 11(7), 507–521
(2007)
3. Bui, N., Zorzi, M.: Health care applications: a solution based on the internet of things. In:
Proceedings of the 4th International Symposium on Applied Sciences in Biomedical and
Communication Technologies (ISABEL 2011), Article 131, 5 pages. ACM, New York
(2011)
4. Ghose, A., Bhaumik, C., Das, D., Agrawal, A.K.: Mobile healthcare infrastructure for
home and small clinic. In: Proceedings of the 2nd ACM International Workshop on Perva-
sive Wireless Healthcare (MobileHealth 2012), pp. 15–20. ACM, New York (2012)
5. Efstratiou, C., Davies, N., Kortuem, G., Finney, J., Hooper, R., Lowton, M.: Experiences
of designing and deploying intelligent sensor nodes to monitor hand-arm vibrations in the
field. In: Proceedings of the 5th International Conference on Mobile Systems, Applications
and Services (MobiSys 2007), pp. 127–138. ACM, New York (2007)
A Lightweight Architecture for the Web-of-Things 259
6. Doody, P., Shields, A.: Mining network relationships in the internet of things. In: Proceed-
ings of the 2012 International Workshop on Self-aware Internet of Things (Self-IoT 2012),
pp. 7–12. ACM, New York (2012)
7. Ma, Y., Rao, J., Hu, W., Meng, X., Han, X., Zhang, Y., Chai, Y., Liu, C.: An efficient
index for massive IOT data in cloud environment. In: Proceedings of the 21st ACM
International Conference on Information and Knowledge Management (CIKM 2012),
pp. 2129–2133. ACM, New York (2012)
8. Li, Y., Teraoka, F.: Privacy protection for low-cost RFID tags in IoT systems. In: Proceed-
ings of the 7th International Conference on Future Internet Technologies (CFI 2012),
pp. 60–65. ACM, New York (2012)
9. Kozlov, D., Veijalainen, J., Ali, Y.: Security and privacy threats in IoT architectures. In:
Proceedings of the 7th International Conference on Body Area Networks (BodyNets
2012), pp. 256–262. ICST, Brussels (2012)
10. Jia, H., Wu, M., Jung, E., Shapiro, A., Shyam Sundar, S.: Balancing human agency and
object agency: an end-user interview study of the internet of things. In: Proceedings of the
2012 ACM Conference on Ubiquitous Computing (UbiComp 2012), pp. 1185–1188.
ACM, New York (2012)
11. Richardson, L., Ruby, S.: RESTful Web Services. O’Reilly Media, Inc. (2007)
12. Duquennoy, S., Grimaud, G., Vandewalle, J.: The Web of Things: interconnecting devices
with high usability and performance. In: Proceedings of the 6th IEEE International Confe-
rence on Embedded Software and Systems (ICESS 2009), HangZhou, Zhejiang, China
(2009)
13. Guinard, D., Ion, I., Mayer, S.: In Search of an Internet of Things Service Architecture:
REST or WS-*? A Developers’ Perspective. In: Puiatti, A., Gu, T. (eds.) MobiQuitous
2011. Lecture Notes of the Institute for Computer Sciences, Social Informatics and Tele-
communications Engineering, vol. 104, pp. 326–337. Springer, Heidelberg (2012)
14. Castro, M., Jara, A.J., Skarmeta, A.: Architecture for Improving Terrestrial Logistics
Based on the Web of Things. Sensors 12(5), 6538–6575 (2012)
15. Guinard, D., Trifa, V.: Towards the Web of Things: Web Mashups for Embedded Devices.
In: Proc. WWW 2009, Madrid, Spain (2009)
16. Khajeh-Hosseini, A., Greewnood, D., Smith, J.W., Sommerville, I.: The cloud adoption
toolkit: supporting cloud adoption decisions in the enterprise. Software: Practice and Expe-
rience 42(4), 447–465 (2012)
17. Kovatsch, M., Mayer, S., Ostermaier, B.: Moving Application Logic from the Firmware to
the Cloud:Towards the Thin Server Architecture for the Internet of Things. In: Proc. of the
6th International Conference on Innovative Mobile and Internet Services in Ubiquitous
Computing (IMIS 2012), Palermo, Italy (2012)
18. Miorandi, D., Sicari, S., De Pellegrini, F., Chlamtac, I.: Internet of Things: Vision, Appli-
cations & Research Challenges. Ad Hoc Networks 10(7), 1497–1516 (2012)
19. Hurlburt, G.F., Voas, J., Miller, K.W.: The Internet of Things: A Reality Check. IT Profes-
sional 14(3), 56–59 (2012)
20. Ganty, P., Majumdar, R., Rybalchenko, A.: Verifying liveness for asynchronous programs.
In: ACM SIGPLAN Notices. ACM (2009)
21. Joyent Inc. Node.js - Evented I/O for JavaScript (2013), http://nodejs.org/
22. Alhamad, M., Dillon, T., Chang, E.: Conceptual SLA framework for cloud computing. In:
2010 4th IEEE International Conference on Digital Ecosystems and Technologies (DEST),
April 13-16, pp. 606–610 (2010)