On the minus side, Parse is missing big pieces that are necessary for business apps, such as data integration, offline operation, and online/offline synchronization. At the same time, its pricing seems geared to lower-volume apps. If you happen to create the next viral hit, Parse will cost you plenty as the usage of your app picks up.
On OS X and Linux, a single tool, called Parse, installs to /usr/local/bin/parse. On Windows, the Parse tool installs a ParseConsole, which launches a Parse-aware PowerShell session; the first session adds Parse to PowerShell for future use. The command-line tool Parse is an app scaffold generator, app deployment tool, log printer, app rollback tool, and self-updater.
Your cloud code resides in
main.js after running
parse new. The default is a “hello, world” program:
response.success("Hello world!"); });
You can push this to the cloud with parse deploy. Once it has successfully deployed, you can use any Parse client to run it, including a simple REST call. The tutorial in your Parse Web console will generate sample code for you with the correct credentials in several languages. Here’s the Python version with my credentials obscured:
connection =httplib.HTTPSConnection('api.parse.com', 443)
“Hello, world” does nothing but demonstrate that you can call code in the Parse Cloud, but Cloud functions can be useful if you pass them parameters and have them do database lookups and calculations on the data. If you need to do more complicated tasks, you’ll probably want to break your application up into multiple .JSfiles and load them from
Key/value pair storage in the Parse cloud is simple to use. The details vary with the client SDK, but this Java code for Android is typical:
ParseObject testObject = newParseObject("TestObject");
The resulting data can be retrieved from any app with access to the data and viewed in the Parse Dashboard.
You can define
Parse.Cloud.beforeSave handler functions to perform server-side data validation, and possibly apply data-modification rules, such as restricting the length of strings or removing forbidden characters. To take actions after data has been saved, define
Parse.Cloud.afterSave handler functions. Similarly, you can control object deletion by handling the
Parse.Cloud.beforeDelete event, and take action after object deletion, such as logging, with a
Parse.Cloud.afterDelete handler. These event handlers have much the same flavor as Kinvey’s hook-processing functions.
Parse Cloud functions will be killed after 15 seconds of wall clock time. The
afterDelete functions will be killed after three seconds of runtime. To get around these limits, you can define a background job,
Parse.Cloud.job. Background jobs are terminated after 15 minutes of runtime. You can schedule background jobs from your Parse Dashboard.
Standard Parse Cloud functions take parameters in JSON. If you need to use a different format, you can write custom Webhooks and call the Express Web application framework to process input.
Parse uses a NoSQL data store, but it supports relationships: one to one, one to many, and many to many. These can be implemented with pointers, arrays, Parse relations, and join tables. Parse supports nine simple data types, including null, and a given column can be any data type when first stored. However, Parse will lock the type of that field to the initial type after the first value has been stored. There are two ways to store binary data in Parse: as a byte stream or as a file.
Users and roles
Parse has a fairly complete user system predefined, including the usual sign-up and email verification, along with a provision for anonymous users. A system of ACLs controls what data individual users can read and write. For more complicated use cases, Parse supports roles, with a separate layer of ACLs for the roles and a hierarchy of roles.
Not surprisingly, given that Parse belongs to Facebook, it has good support for social account linking -- including Twitter. In each case, you must have an app set up on the social networking platform to enable the OAuth authentication.
Parse supports in-app purchases only on iOS. Oddly, Parse currently supports a local data store only on Android, although support for a local data store on iOS is planned.
Parse boasts it can do double duty as a Web host. That’s nice, but it isn’t exactly a compelling consideration for choosing a mobile back-end service.
Parse has nine prefab integrations with other services. Three of them -- Mailgun, Mandrill, and SendGrid -- are for sending email. Stripe is for charging credit cards. Twilio sends SMS messages and voice messages. In addition, Parse has third-party modules for Cloudinary, Instagram, and Paymill.
I haven’t seen any options for hosting Parse other than its own multitenant cloud. I can’t see it being used for apps that need to be HIPAA-compliant or for apps restricted to data located in the European Union.
Parse now has usage-based pricing, ranging from free for low usage to $1,700 per month per app for 200 requests per second, plus five centers per 1,000 unique push messaging recipients per month over the first million. That’s quite reasonable for many apps, but I can see a popular consumer app blowing through the limits, and I can’t see a large business wanting those kinds of limits for its important apps. On the other hand, vendors of successful apps and large businesses are often in a position to negotiate pricing.
While I don’t see Parse as the top MBaaS option for most businesses, I can see Parse as an easy, low-cost way to prototype the back end of a mobile app, especially a consumer app. The questions in my mind are whether it makes sense to start with a back end that lacks important capabilities that you may need later, and whether it makes sense to start with a back end that may become too expensive for an app that’s popular but not a big moneymaker.
This story, "Parse Delivers on Mobile Apps, But Not for Business" was originally published by InfoWorld.
On the surface, it may seem like a difficult choice between Alexa and Google Home, but once you look at...
Apple has to out-execute itself (and its rivals) every year to coerce millions of users to upgrade and...
Apple's second-generation watch doubles down on fitness with GPS, water-resistance, a dual-core...
CIOs discuss key efforts to shake up their IT departments as they lay the foundation for digital...
The Federal Communications Commission approves new rules that will finally make it harder for...
If implemented properly, blockchain can help secure medical devices and improve patient privacy, but...
Does Silicon Valley’s latest quick-fix for its diversity problem actually work? Or does it just...