Subscribe via E-mail

Your email:

published qa papers free

Browse by Tag

Posts by Month

Follow Me

NTT DATA Canada Discussion Room

Current Articles | RSS Feed RSS Feed

Cross-Platform Mobile Development - #1

 

Cross-Platform Mobile Development

Best Practices in User-centric, Agile Design for the Cloud

Post 1 of an ongoing series

Written by Pablo Elustondo

Cross Platform Mobile Development resized 600

 

2012 is just starting and some of our new customers are asking for user-centric, cloud-based business applications that run mobile and web platforms and to be developed in an Agile,  flexible and scalable manner. The initial hype of the mobile application development market from 2010 is transitioning to a more mature business practice, revolutionizing the way we interact with computers, according to Gartner. Those of us who build business applications are very happy because this is enabling us to create much more usable applications at the same price as before or less.

 

These changes require some fresh thinking and we need to re-learn some of our techniques and concepts. Gone are the days when we could develop a web application using some server pages technology that every page clicked refreshed the browser and every time a customer asks for a new feature we have to re-do our pages. Technologies like NET webforms, or the venerable Java J2EE from the pre-mobile era are just not adequate any more. Also, trying to complement those technologies by adding interactivity using Flash or Silverlight or Java on the client is outdated, even non-viable in certain platforms.

 

Also, unless you are a really big software shop, you cannot afford to have and to maintain various different versions of the application, one for the web, another for iPhone, another for Android, another for other platforms.

 

Building on this,  we will attempt to answer these issues as the subject of this blog series.  We will target the following 7 design & development ideas:

 

- 1. Develop the core business engine of your application as a set of web services preferably implemented on a good ‘platform as a service’ (PaaS) layer that can easily be scaled up and re-uses exiting features. Two possible paradigmatic options are Google App Engine or Microsoft Azure.  It is possible to develop those services with conventional server technology and deploy to an IaaS provider.  We previously discussed the pros and cons of these choices in our white paper on cloud.  Although some programming languages are slightly better than others, the choice of programming language is almost irrelevant. Java, C#, Python, etc, even javascript on the server could be used. Best practices produce a clean and generic API that can later be used by rich web clients or mobile apps. This service API produces a clear separation that can be tested automatically. Unless you find reasons for other web service protocols, use REST over JSON. XML is also possible but more complex and inefficient for doing highly interactive rich Internet applications.

 

- 2. Use a powerful and clean modern JavaScript framework to build both web pages and the core aspects of our mobile apps. There are various frameworks like jQuery, Dojo and Sencha (ExtJs). We will compare some of these options in future posts. Any of these frameworks will let us program on a solid foundation using object oriented concepts producing high quality HTML5/Javascript/CSS3 applications that can be run on any modern browser and any major mobile platform.

 

- 3 It is possible to implement javascript-based web applications on one HTML page following the “Single-Page Interface Model , and this is recommendable for building a mobile application based on web standards. However this is normally not the best approach for a browser-based application. Normally, we would like to have some pages and would benefit from using some existing frameworks to dynamically create those pages using server pages technology. However, since the javascript pages have more logic that before, you will have less real ‘pages’ and more logic on them. The recommended server pages-based type of frameworks for this kind of development is normally the time-tested MVC architectural pattern. To follow the examples from point 1, you could use the new MVC 3 framework for .NET or Spring MVC for Google App Engine. Of course, plain JSP or ASP pages can also be sufficient but are more prone to bad programming practices.

 

- 4. Although the Javascripts frameworks can be very powerful and could support most mobile application development efforts, accessing some native features and packaging for the application stores will not be possible. For this last step, we will use cross-platform mobile application frameworks like PhoneGap to create a truly native application. PhoneGap allows authoring native applications with HTML5/Javascript/CSS3 web technologies to get access to mobile platforms APIs and application stores.

 

- 5. Think and act Agile. We will have to change our applications often. So, if we can test automatically, we can reuse many of the tests. No more novel-size server pages that we need to scroll several times. Nice code is elegant and minimalistic. Large code is to be avoided. Minimal custom code is to be used since that will often break after minor changes. Agile development relies on good abstractions, object orientation, encapsulation, test driven development, model view controller, separations of concerns, automatic testing and of course use case orientation. (see next point)

 

- 6. Think and act user centric.  If we want to create an application that users will enjoy to use, we need to make sure we understand, imagine and foresee how users would like to use it. We should not ask them, since most will not know. We need to think and create. Using use case analysis, users stories and scenarios is the best way to capture user’s needs, foresee scenarios/use cases and build our application with the user business process in mind. Build a proof of concept, re-do it if necessary from scratch, until some ‘wow’ factor has been achieved. Then increase our scope one interaction at a time without repeating ourselves and never writing anything in stone. Nobody really knows how is the best way to build a good application, not even the user. Both the user and developers need to work  together using imagination and the inevitable trial and error process.

 

-7. Try to use standard/popular technology. Using Javascript/CSS3 and HTML5 for developing the client is clearly a much standard route than using Platform specific programming languages. More programmers will be available and the application will be easier to maintain and scale. Using REST web service interfaces and XML or JSON as transport protocols will set a future of interoperability. Of course, focusing too much on standards may limit innovation, the right balance is key.

 

In future posts, we will analyze these 7 principles in-depth and will show some simple sample applications with concrete examples. We also will point to various links for further research. We hope to get comments and corrections and make this post a solid and simple recipe for user-centric cloud-based cross-platform mobile development. 

read-part-2

The opinions expressed on this discussion room are writer's and don't necessarily represent NTT DATA Canada's positions, strategies or opinions.

Comments

An additional tool to add to this discussion is Application Craft http://applicationcraft.com  
 
jQuerymobile has announced AC as a JQM dev platform and here's a case study that Phonegap did on them : http://phonegap.com/case_study/phonegap-application-craft-pain-free-mobile-app-development/  
 
In summary, it’s a cloud-based dev platform that does mobile (all important platforms) and desktop on an equal footing. It's got an IDE that does drag-and-drop / WYSIWYG UI building as well as code editing. I guess you could describe it as Visual Basic in the Cloud, but Javascript not Basic. Widget based like VB was, extensible. Open Source with free platform offering.
Posted @ Tuesday, January 10, 2012 10:37 AM by Max
Hi Max, 
Excellent comment, very much appreciated. You are right; I need to include the topic ‘Development Platforms’ in the analysis. And clearly, “IDE as a service” is a very promising trend. I did a little drive test of ApplicationCraft and I liked what I saw. I cannot put an opinion until I see the whole picture using a small but end-to-end example. It looks like a nice topic for my next post. I know there are other tools like this out there like Tiggr and NS Basic. Clearly a topic I need to include in analysis. If you already have some sort of comparison between Application Craft, Tiggr, NS Basic or any other, please post it here as comment.  
Thanks!, Pablo.  
Posted @ Wednesday, January 11, 2012 10:51 AM by Pablo Elustondo
Agile and User-Centric can really both come together in the PROJECT methodologies you intend to use to manage the development.  
 
AGILE is not a development method but a project management method.  
 
The development practices that support it are called Agile but are practices in their own right - TDD, XP, Pair Programming, Continuous Integration, etc. Appropriate use of an AGILE PM method drives out the use of these development practices and requirements management practices ("user centric", stakeholders, product owners, etc.).
Posted @ Sunday, January 15, 2012 7:56 by Terry H
Hi Terry, 
I would say it's an honour to have your comment, specially because most of what i know about agile I learnt from you. I agree with your comment about the ‘development practices’, as Agile is more of an ‘ approach’ that a real ‘method’, something you need to instantiate. (like RUP and others..). However, I am not sure that I agree with your statement “AGILE is not a development method, but a project management method”. Here I would disagree. But to avoid relying too much on my my personal opinion I would refer to reliable and popular sources. Agile as we know it, started from the agile manifesto. written by software developers with not reference whatsoever to the notion of ‘project’. Of course you can have ‘Agile project management’, but I think, in the same way this wiki entry explains, this is a derivative. Something that “project managers’ discover later in the cycle to adapt to new way of doing things. To quote directly “...agile (project) management derives from agile software development, it follows the same standards”. Also the current most popular wiki entry for agile refers to “Agile software development” and not project management. In my opinion and experience if you try ‘agile project management” without actual agile software development practices like: tdd, abstract coding,, etc, you know what happen. Also, note that if you go to Scott Ambler home page, you will see that “agile software development” will have two matches with a lot of sense, but if you search for “project”, you will find “Mapped objects into relational databases on numerous projects” :). Conclusion, agile is a software development approach that has influenced and renovated project management and requirements gathering and understanding and yes, both developers and project managers (and also customers) should be on the same page, but I think that if you have to choose only one of these three for whatever the reason, I would say, start from developers. If developer are not agile, do not evene mention the idea to customers or project managers.  
Ok, you can throw your next punch now, I hope to be agile :).
Posted @ Monday, January 16, 2012 12:53 by Pablo Elustondo
Post Comment
Name
 *
Email
 *
Website (optional)
Comment
 *

Allowed tags: <a> link, <b> bold, <i> italics