It has been a decade since the launch of the iPhone, but for developers, it can feel like we’re still trapped in 2007. If you’re doing anything interesting with a mobile app, you run into a pernicious and frustrating reality: Your mobile development experience was in large part determined by the web technologies that preceded mobile and still persist today.
So when we talk about building mobile apps, what we really mean is building mobile apps that interface with server technologies. And that means interacting with a stack that was designed for a world of desktop computers connected with ethernet cables. While the world has moved beyond big screens and wired connections, mobile developers are the ones who have had to accept endless compromises in order to ship the experiences they want.
To ship useful server-side code, you need a lot of novel, domain-specific skills. When a developer builds an app and connects it to the server, data doesn’t just magically start flowing into handy columns and rows. Before you make your first request, you have to deploy and manage those servers. The devops arts that make that possible are getting easier, but they certainly take up a lot of time.
Next, your server has to serialize the data from whatever format (probably JSON) it gets from the request, and then it has to store it in a database that usually understands SQL, and then it has to perform the business logic on that data. It’s going to do all of that in a server-side language, which of course will be different from the Swift or Android Java you use to write your mobile app.
A simple mobile app is suddenly in need of a sophisticated server-side team. And it’s mostly work spent just trying to get the two sides of your stack—mobile and server—to talk to one another. We have mobile apps and mobile teams, and they have to play nicely with a server-side stack and team that uses technology established in a pre-mobile world.
Simplify the server
There is a better way—an emerging pattern called serverless development—that we at Realm have been working hard to bring to mobile developers. A serverless architecture is meant to abstract away all of the infrastructure and frameworks that make server-side development possible, so that you simply focus on the hard part: writing code that does what you need it to, and which runs reactively as data changes. The server is still there—but all of the work to get productive with it has vanished.
This is the idea behind the Realm Mobile Platform. Because the Realm Object Server is an object synchronization and event handling server that works with Realm’s mobile database, it keeps data in sync across devices seamlessly and automatically, with minimal changes to data models or controllers. It uses live objects shared across the Realm Mobile Database and the Realm Object Server, which update automatically and immediately in response to changes at either source – and with comprehensive data encryption throughout.
How is that so different than normal server-side development? Well, as a mobile developer, you no longer have to become a server-side developer with all of that specialized knowledge in order to do effective work. You don’t have to think about how to get the server running, or how to get the data to the server. You don’t have to do devops. You don’t have to learn how to deal with Postgres and Redis and all of the other server-side technologies that a sophisticated app used to require.
Focus on the app
You end up writing a lot less mobile code too. Instead of writing networking and serialization code inside your mobile app, all you’re responsible for is the model and the data you create from it. Because the platform can take care of syncing, you get to focus on the app code that will actually make your app great—instead of the code that used to be necessary just to make your app work. You’re freed from all of the fragile code that you used to write to talk to the RESTful API that used to take up the rest of your time.
Mobile apps move as fast as we can. Features like live collaboration, two-way data sync, endpoint computing, and “offline first” used to be expensive and difficult to build. By adopting a serverless, mobile-first approach, developers can use Realm Functions to build next-generation capabilities at a fraction of the resources we used to spend just to set the stage for the apps we always wanted to build. Now we can just get to work, building the future.
New Tech Forum provides a venue to explore and discuss emerging enterprise technology in unprecedented depth and breadth. The selection is subjective, based on our pick of the technologies we believe to be important and of greatest interest to InfoWorld readers. InfoWorld does not accept marketing collateral for publication and reserves the right to edit all contributed content. Send all inquiries to email@example.com.