00:20:39 video length
Bio Brian LeRoux leads the open source PhoneGap project team at Adobe (currently undergoing incubation as Apache Cordova). He's been with the PhoneGap project from its very humble beginnings at Nitobi Software.
Software is changing the world; QCon aims to empower software development by facilitating the spread of knowledge and innovation in the enterprise software development community; to achieve this, QCon is organized as a practitioner-driven conference designed for people influencing innovation in their teams: team leads, architects, project managers, engineering directors.
1. My name is Srini Penchikala. […] In this interview, we will be talking with Brian Leroux from Adobe team, about building Cross Platform Mobile Applications. Can you introduce yourself to our audience and tell us a little bit about what you do and what you are currently working on?
Sure, I work at Adobe Systems, my name is Brian and at Adobe my core focus is on the Apache Cordova Project which is a sort of Open Source rebirth of Phone Gap. But I do a lot of mobile web stuff too.
Srini: Also you are hosting a tutorial at this conference on developing Cross Platform Mobile Applications?
It’s tricky for sure, it’s a loaded statement. A lot of people will say that the Cross Platform is a bit of a myth usually on the Internet which is kind of ironic because they will say it from any device in the world at any time. It’s our belief in the Phone Gap team that the web solves Cross Platform, so web technologies is kind of where we go with this, there has been sort of false profits in the past with Java and its many runtimes but the web really has permeated most devices and platforms.
We are still in the early stages and the web has gone through a real massive rebirth in the browser, there is a new browser war, but it’s almost a war of cooperation now, and the technologies are moving so fast, that we are seeing all kinds of new frameworks, new developments, new understandings, new performance characteristics and profiles. So it’s really young and it’s really early, I don’t think we fully understand our own monster yet today.
Organizationally, I think the development process is still being figured out, one area that I’ve been obsessing on lately, is that there is always a build step, whether we want to admit it or not in web development we are now doing things like concatenating files, obfuscating them, precompiling templates, running tests, running a linter. All this ceremony happens when we do build and development times are a lot different than runtimes, a lot different than deployment time, and there is a lot of duplication of effort between different groups in organizations. This isn’t an “either-or” either. So a lot of people are trying to pursue Cross Platform organizationally as a strategy to cost save, also to reuse skills, so there is a lot of web developers and there it’s a good idea to leverage that, but at the same time it’s definitely worth exploring the native platforms with what they have to offer, they have large markets, sometimes getting more direct user experience and more direct access to the hardware. So it’s not really an “either-or” but I think we all are still trying to figure out how these things fit together and how to build the applications in an efficient way.
I am partial of PhoneGap, because I work on it but I don’t want that bias to influence of people think about things, it’s just another technique and there are lot of tools. I personally feel if I was an organization ninety nine percent of the cases I’ve been looking building a responsive web design as my first go to, and then view something like Phone Gap as a progressive enhancement to access app stores and revenue models around that, and then maybe explore in parallel the idea of doing more goal directed, native development on devices. Interestingly though, at PhoneGap we are trying to really blur this and so there it’s a term now called Hybrid Development, and we do both your application development in the browser and then you have a build step that brings you into the phones. In Phone Gap we’ve recently started exposing our plug-in API which allows you to essentially write the native code bits and then wire it back to the browser instance in the PhoneGap application. So doing this there really isn’t a debate to be had, you can access anything native from the browser if you want, including GUI components, or not. So it’s not getting easier, it’s actually getting harder because there are more ways to do things.
6. You mentioned about development time and concepts like Responsive Design. What are some considerations or best practices that the designers and developers should take into consideration when deciding to go with Cross Platform Application Development?
Srini’s Full Question: In the Mobile Runtime environment every byte counts. Let’s go back to the device features that Phone Gap brings to the table like push notifications or camera or accelerometer. I know HTML5 supports geolocation, so do you see HTML5, next generation or version or HTML6 even, can it support those device features out of the box?
We’ve always believe really heavily in device API’s and that was what we went with things with the PhoneGap Project. When we started building these sort of fancy browsers, one way to describe PhoneGap, our whole vision was to access the sensors and the data on the devices, you can’t get into the web, the web being sandbox, we can’t access things like the camera, and actually in the web we’ve been able to do this for a while with technologies like Flash and now in the Media capture API it’s available on Android and Opera I believe. Probably Firefox 9 release at this time, so we are seeing these API’s start to trickle into the browser and I don’t know if we want to increment the HTML version number or if we want to just start viewing this as the web Platform or the web Runtime. These are the things that I’m personally really excited about – file system access, Index DB, just all these sensors and data on a phone, your contacts, the media on your device, the ability to record audio and video, we saw audio API’s possibly land maybe in the next version of iOS 6, so really exciting time.
Srini’s Full Question: Definitely you are right, the mobile is the way to go, so definitely the users in this space and industry will be asking for a lot of these application features. So Brian, let me go back to this Cross Platform Application features again. They are supposed to bring the best of two worlds, one being the Mobile Web Applications and the other being the native mobile apps so you can write one program language or one API and be able to deploy these applications to different devices, without having to write code in Objective-C, or Java, or C#. So is it really the case or do Cross Platform Applications potentially bring the worst of both worlds, where the mobile apps are not as rich as the native apps and not run on all mobile devices?
It is one of those “it depends” answers which are no fun for software developers but we all have to give that answer every time. It depends, one example for you, we once had a client come to us a while ago and we’re like “We are going to build this app and it’s going to be huge, it’s going to be the biggest app ever, and it’s going to have more functionality than Facebook” and they thought that was a great idea and I thought that was the worst idea ever. So instead of one thing that we challenge people when they say “Is it’s capable to do this stuff”, I view it in the mobile context especially you should probably just aim for do one thing and do it super well, as opposed to trying to do a lots of things because you are going to have terrible performance, it’s going to be a latent experience over the wire and your user experience is going to be confused and junky.
If you need to do a lots of things it’s nothing wrong with doing a lot of apps and it’s sort of my answer in general to: “How do you solve doing a lot of stuff, do you need objective C or Java?” is “Maybe, depends of what you are trying to do”. We are adding more API’s all the time to PhoneGap and there is a huge very rich plug-in ecosystem that is growing out there. I wouldn’t discourage someone from writing objective C or Java, I think those are great languages to learn and you can’t really begin to appreciate the web platform until you have to go deal with the native platforms too. None of these are silver bullets and none negate each other, there is always a time and place.
9. Use the right solution to solve the right problem. I know that are a lot of these Mobile Enterprise Application Platforms, MEAPs, like IBM WorkLight, or Oracle ADF Mobile. They promise that they provide everything out of the box. So what do you think about these products in terms of developing the Cross Platform Apps?
IBM is really big contributor back to PhoneGap and we know workwise built quite few apps and I haven’t play with Oracle solution but I know they are using Phone Gap as well so I can really comment directly of what I think of them but I know that the Enterprise right now deeply concerned about getting back into the space, we are seeing a moving away from devices distributed by the Enterprise to their work force to people just using their own devices, so they need to start developing applications, so these guys can get it, most people of these days are rocking a Smartphone, iOS, Blackberry, Windows Phone, Android even Bada actually, so accessing this array of possible devices, the other big problem the Enterprise had is they pick just one, what is happen when another one emerges and so we saw this between iOS and Android, there is been a sort of tension between these two platforms and Blackberry on the way down, they can’t just choose one, so they know they need to use a delivery platform like the web to get to their work force.
10. And there is also vendor lock-in with MEAPs. Let’s go back to the tools, can you talk about some tools for Developing Cross Platform Applications, what developers can use to make it easy for developing Cross Platform Applications?
jQuery comes with some penalties, so I would use something like Clojure Compiler and Advance Book make sure that I was only using the parts of jQuery that I’m actually going to be sending over the wire. jQuery as a whole still quite a big library. From the front-end side of things are the more like CSS I quite like Twitter Bootstrap lately but looking at Twitter Bootstrap it’s four thousand lines of CSS which is pretty inappropriate to send over the wire, so again I actually wrote a tool called CSS Slap Chop, that removes selectors you are not using , get it down to only the bare minimum that you need to send over the wire.
build.phonegap.com is fantastic for just trying up PhoneGap without installing the SDKs. It’s a cloud based service for building PhoneGap applications but it’s also really good for building a Continuous Integration system with your code, so we’ve got hooks and an API so if you want when you do a check in, you can have us to do run a build, it creates a QR Code and so then your clients and stakeholders, they just install the app and check it out for themselves. It is really useful, well Continuous Integration, I’m sure the QCon audience understands so useful could be, so that is another angle. There are a lot of tools and I don’t like people to think that they can’t use things like Dojo, YUI or Sencha or jQuery Mobile, they are all totally appropriate for some people.
Srini: They have to look at their own requirements and pick the right tool.
And their skills too, where their existing investments are, they’ve already invested in something like extJS, Sencha might make sense for them.
We are hoping that we will be shipping 1.9 next week so I don’t remember the date, it’s July 18th or no, June 18th, so we are going to ship 2.0 on July 20. I’m fairly confident we should be through the incubation process by then, the remaining issues are like really kind of silly things like license header files and stuff, so we are almost out of incubation, which is nice.
Then there is the newer ones, is Boot to Gecko from Mozilla which I’m extremely bullish on and Tizen from Intel and Samsung, so these web based operating systems are like a browser on top of a Kernel, and with this emergence all of the sudden a whole new set of problems came to light and this new group just started the W3C, called the sysapps group. And they are starting to look at addressing what a web operating system look like, what a web runtime look like and a sort of early talk right now and it isn’t been completely charged but the ideas of , they start with the idea of what runtime security model will look like and how all installable web apps could work and so I’m really excited about that. I don’t know where things are going to go necessarily but I know this is probably the closest thing we have a glimpse of the future.
14. You mentioned about the Security, so let’s discuss about that. Security is a critical requirement no matter what, especially with the Mobile Applications. Can you talk about what are the applications security considerations when using PhoneGap Cross platform Mobile Apps?
So PhoneGap is exactly like a Mobile Web App and unfortunately on the devices these days, there is no encrypted key store, I think on some models of enterprise Blackberries you can get an encrypted key store and possibly on older Nokias but not in the current generation of Nokias. Because there is no encrypted keys store, there is no way for us to store keys on the phone which means you are going have to have an off step if you want it in store, if you want to deal with any sensitive data, if you want to store locally cool encrypted for sure but understand you are going to encrypt performance penalty based on the CPU, you got and you can’t keep the key on the same phone, it’s really not safe to do that. Local store interesting in the Android is pretty safe, but again I would not necessarily trust this. So this is what you’ve left with, it’s all the same rules as the web, basically you are on a proxy request, you don’t want to include third party scripts. You are sandboxing in an iFrame.
It’s a good question. Favorite IT books, I collect a lot of really old software books and I quote business from Eric Raymond’s I think it’s the Unix Philosophy, the Art of Unix Programming always a good book, just read that if you are a software engineer. Obviously Fred Brook’s is good one too. Non programming I read a lot of High Fantasy, it’s kind of like my sitcoms and I’ve been reading the Malazan series which is a huge epic and I’m hoping to finish that soon, my favorite book is the one I’m reading right now.
Srini: What is the title of the book?
The Malazan series, I think there are like twelve of them, I can’t remember, tides of darkness or something like that.
Srini: Thanks Brian, thanks for the time!
Cool, thanks man!