Facebook Open Sourcing Parse Back-End SDKs
Facebook company Parse is open sourcing its SDKs used to provide back-end services for mobile and other apps.
Acquired by Facebook in April 2013, Parse specializes in Mobile-Back-End-as-a-Service (MBaaS), providing functionality such as storing data, social log-ins, push notifications and app analytics. Desktop, Web and embedded app services are supported also.
The company yesterday said it's open sourcing all of its SDKs, starting with GitHub repositories for iOS and Android on the mobile side and OS X on the Mac desktop (available on GitHub with the iOS SDK).
"Today we're excited to show developers what's under the hood for the first time," said software engineer Nikita Lutsenko in a blog post.
Under that hood are details about how the company overcame challenges in supporting back-end services across multiple platforms. To keep the public-facing API easy to understand and use while supporting new features, it was structured as a facade to work with the internal code, so changes could be made without complicating the API, Lutsenko said.
Along with ease-of-use concerns, the company also focused on architecture unity and performance.
"In order to achieve unity in architecture we developed a whole new approach to asynchronous operations with 'promises' and Bolts framework Tasks, which we previously open sourced," he said. "To tackle speed and stability, we also built a loosely coupled architecture model, which lets us move much faster and stay confident in the reliability of our SDKs' existing functionality."
Grantland Chew, another Parse engineer, went into even more details about the SDKs in his own blog post, delving into the decoupled architecture and the effort to provide API consistency mentioned by Lutsenko.
"It's hard to add new features and make our SDK more robust without making breaking changes," he said. "Additionally, as our codebase grows, we need to ensure that our code stays testable so that we can deliver the most stable experience to our developers. To solve all this, we've adopted a decoupled architecture model that consists of our public API object instances, object states, controllers and REST protocol. Each piece is encapsulated to ensure separation of concerns and different implementations allow us to add new features without modifying too much code."
Chew also explained the inner workings of writing asynchronous APIs with Tasks, which he said makes the process "a breeze."
Chew promised more blog posts to come to explain how the company approaches thread safety and its philosophy for testing, along with other topics.
"By sharing our SDK source code with the community, we want to share everything we've learned along the way, as we hope this will benefit others working on similar challenges in the mobile development space," Lutsenko said. "We know we'll continue learning, too, from the contributions of developers and engineers around the world. We can't wait to hear what you have to say."
David Ramel is the editor of Visual Studio Magazine.