Two of the more pervasive solutions taking this approach are Appcelerator Titanium and PhoneGap. These tools are available for free, with the business model built around consulting and support services. However, they only provide developers with a part of the solution, that being the development tool. Support services surrounding it, such as source control, deployment, and user access, are the responsibility of the developer to resolve. Additionally, these frameworks have their own libraries, syntax, and development approaches that take time to get acquainted with. Proficiency is gained through substantial time investment and cycles of trial and error.
Into this rapidly crowding market approach, Rhomobile has entered its RhoMBUS suite. RhoMBUS consists of four products, each of which focuses on a key aspect of the mobile application development lifecycle for the major smartphone operating systems (iPhone, Android, BlackBerry, Windows Mobile, and Windows Phone 7). Rhomobile bases its products on the Ruby language and models its model-view-controller (MVC) framework on the popular Ruby on Rails approach to web application development. Thus, for developers already very comfortable with writing Rails applications coupled with the Git distributed version control system (DVCS), Rhomobile's mobile business unified services makes a lot of sense.
The RhoMBUS product suite consists of four products: Rhodes, RhoSync, RhoHub, and RhoGallery. Together, these products provide a comprehensive solution for those who want to develop, deploy, and manage cross-platform native mobile applications. Let's explore what each one has to offer.
Rhodes is the open-source, MIT-licensed, Ruby-based framework where developers will spend most of their time programming their mobile applications. Like Ruby on Rails, Rhodes operates very similarly to that framework in both MVC component construction and the command-line scripts (e.g., rake, generate) that Rails developers know so well. Additionally, views are Embedded RuBy (ERB) files that mix HTML, CSS, and embedded Ruby instructions for the Rhodes presentation layer.
Installing Rhodes on Windows is a somewhat easy affair thanks to the InstantRhodes executable, which is available as a free download from rhomobile.com/downloads. The package includes the latest Ruby distribution for Windows along with Git and the Redis (redis.io) key-value data structure server used with the RhoSync product.
However, a few other Windows-specific dependencies must be met before rake'ing a Rhodes application. The SDKs and their emulators for the respective target platforms must be installed in order to build and test Rhodes solutions. In the case of Windows, Windows Mobile, Windows Phone 7, Android, and BlackBerry, SDKs need to be set up and properly configured. For example, the locations of MSBuild.exe, java.exe, and Android SDK and NDK (the version of Rhodes I used required NDK Revision 4b) need to be added to the PATH system variable. Windows Phone developers running Visual Studio will also require Visual Studio 2010 SP1 applied along with the Windows Phone SDK 7.1 Release Candidate (or later). A native Mac OS X 10.6 or later computer installed the iOS SDK is required to test an iOS Rhodes build. As such, keeping code synced across different OS builds is where RhoHub comes into play (more about that later).
To start building and testing Rhodes applications in mobile simulators or devices, you use the rake command. For example, to build for the Windows Phone simulator, on a Windows platform run the following command:
Similarly, on a Mac run the command
$ rake run:iphone
to run the project in the iPhone simulator. Figure 1 shows the process of running a Windows Phone 7 application in the Rhodes simulator.
After a developer writes an application that lives within the respective native WebKit wrapper on the target platform, data synchronization is typically the next big step that needs to be addressed in most modern-day, cross-platform mobile applications. RhoSync employs the open-source key-value data server to perform create, read, update, and delete (CRUD) operations on the enterprise back end. Unlike Rhodes, RhoSync requires a paid commercial license to use it, which helps cover the expenses of Rhomobile's hosting of the synchronization services across the various mobile platforms. Rhomobile has partnered with popular Rails cloud Platform as a Service (PaaS) provider Heroku, part of Salesforce.com's company portfolio, to provide the hosting services.
Instrumenting and running RhoSync-enabled applications begins with creating a RhoSync skeleton framework using the "rhosync app name_of_app" command, followed by entering a command to start the Redis server. Finally, the newly created RhoSync application is spun up via the "rake rhosync:start" command.
Of course, there's the matter of writing the source adapters to manage the back-end data interaction. You can create model skeletons by using the "rhosync source name_of_class" command. This generates method stubs for login, query, sync, create, update, delete, and logoff operations. Queries are made via the standard Ruby JSON library and RESTful web services.
Once the mobile application is built and data synchronization is in place, the next matters you need to deal with are managing source code and deploying the application. To address these needs, Rhomobile has created a Github-like service called RhoHub. After creating and logging into a RhoHub account, developers add their Secure Shell (SSH) public key(s) to their account, then create a new project to host and deploy their code, as shown in Figure 2. If the project is brand-new and has no code yet written for it, RhoHub's project creation can auto-generate a skeleton Rhodes application ready for Git cloning.
Developers can then share out their project, allowing commits from other project collaborators. Using the Rhomobile servers, RhoHub can also generate builds for the various mobile platforms, alleviating the hassle of requiring the various SDKs to be installed on your local development computer. RhoSync is also preconfigured; its deployment is as easy as clicking the Deploy button in the RhoHub project screen.
After all the coding and testing are done, the project is finally live and ready for users. But how do users find and install your application? RhoGallery provides this last piece of the puzzle by offering a unified portal of application discoverability for the applications you have developed for your customers, be they consumer-oriented or enterprise-specific apps.
The steps to deploy and distribute Rhodes apps through RhoGallery are straightforward. Sign into RhoHub, create a new Gallery, assign your Rhodes application to that Gallery, and invite customers/users via email or text message to peruse and download your app(s) from the Gallery. Figure 3 shows an example application-distribution setup. The message sent from RhoGallery contains the URL and credentials to gain access to the Gallery, so all a user needs to do is click the link and select the application of interest. Applications retrieved in this fashion can also be sandboxed, automatically provisioned, and deprovisioned (i.e., remotely wiped) from devices.
Pricing ranges from free to $10,000 per year or more depending on the number of RhoSync'd hosted devices and amount of data storage and RhoGallery access required. Considering the potential volume of data that 1,000 devices might generate per year, the $10,000 price is acceptable though a bit steep, given that the package includes only 5GB of online storage.
My Overall Take on RhoMBUS
Rhomobile obviously took its inspiration from the Ruby on Rails framework, and it is that audience of developers that the RhoMBUS platform is most optimized for. Developers with little or no Rails experience, or those who prefer working within the comfort of an all-encompassing visual IDE, will likely find RhoMBUS a challenging development experience. Note that Rhomobile has released a feature for the Helios release of Eclipse called RhoStudio, available for free at rhostudio.rhomobile.com, but this only assists with class generation, syntax highlighting, and the various file and object management facilities that Eclipse natively provides.
If your idea of mobile development is dragging and dropping user interface components within Visual Studio, double-clicking those components, and effortlessly editing their properties and having event code auto-generated, RhoMBUS is probably not for you. But if you are an intermediate-to-advanced Ruby on Rails developer, and you prefer Rails over other web application frameworks, RhoMBUS was built for you.
I also appreciate the fact that Rhomobile has taken care of the major pain points of dealing with distributed-team source control, data synchronization, and application deployment. While the more adventurous could assemble each of these pieces on their own, knowing that everything "just works" (especially given the finicky nature of Ruby Gem version control), I'm glad to hand over the responsibly of that overhead hassle to Rhomobile. In fact, I see Rhomobile's role as an extension (and acquisition target) of that of a company like Salesforce.com with its strategy of making cloud-based application lifecycle management standard practice in today's IT industry.
Although the enterprise-class package pricing is on the expensive side, the fact that Rhomobile has created a cohesive end-to-end development solution for multiple mobile-device OSs is an attractive value proposition for businesses seeking a Ruby-centric, single-codebase-deployment mobile application development solution.