Skip to content

Node.js and the Mobile Device

by Andrea Morton  08.08.2011 06:04 PM

Node.js has been gaining mind-share when it comes to implementing server-side JavaScript services.  Some of the reasons for the increased popularity include the non-blocking/asynchronous programming model and the ease of development using JavaScript.  These same reason make node.js an interesting model for building fast and low power consumption code that lives on a mobile device.

HP/Palm is implementing Node.js inside of their WebOS operating system which is enabling some interesting scenarios.  Below is an example scenario which describes how Node.js can be used both on and off the device.

  1. As you can see in the logical architecture diagram below, the Mobile Device hosts the ‘Client Code’ which uses a ‘Middle Tier Code’ Node.js Service, which ultimately uses a system based node.js service for I/O.  By implementing a node.js host and exposing operating system level services (i.e. I/O), WebOS is enabling a simple and familiar programming model which is easy to consume and low power (since it’s non-blocking).
  2. The ‘Middle Tier Code’ which is implemented using a node.js service, is available to be consumed using JavaScript and can decide whether to use local resources or other (off-device) node.js services on the network/Cloud.  The logic in the ‘Middle Tier Code’ could be a function of network availability, battery power, GPS location, or some other information provided by the device.

For more information about the WebOS node.js implementation visit

Share this post
Post a Comment:

Sign in is required to comment on this blog. Not a member? Join Now.