Notes on Parse



Download 35.27 Kb.
Date30.06.2017
Size35.27 Kb.
#22266

Notes on Parse


Created 10/26/12

Updated 03/12/13, Updated 05/31/13, Updated 08/23/13, Updated 09/12/13, Updated 10/04/13, Updated 10/20/13

Updated 10/21/13, Updated 05/01/14, Updated 12/11/14, Updated 04/12/15, Updated 01/28/16

Introduction


Parse is the cloud app platform for iOS, Android, JavaScript, OS X, Windows 8, and Windows Phone 8. With Parse, you can add a scalable and powerful backend in minutes and launch a full-featured mobile or web app in record time without ever worrying about server management. Parse offers push notifications, social integration, data storage, and the ability to add rich custom logic to your app’s backend with Cloud Code.
They describe their offerings as being organized into several products:

Parse DataParse SocialParse PushCloud Code


They have a comprehensive API, providing direct JavaScript calls, as well as native libraries for iOS and Android applications. The JavaScript API is a fork of the Backbone API. The API supports push notifications on iOS and Android. Supports geolocation data.
At a “Developers Day” conference in early September 2013, they introduced support for Analytics, background jobs and the Unity SDK. In addition, their modules for Images and Users are now available.

Shutdown


Parse was acquired by Facebook in April 2013.
StackMob has been purchased and shut down (May 2014), so we began to focus on Parse.
In January 2016, it was announced that Parse was shutting down:
We have a difficult announcement to make. Beginning today we're winding down the Parse service, and Parse will be fully retired after a year-long period ending on January 28, 2017. We're proud that we've been able to help so many of you build great mobile apps, but we need to focus our resources elsewhere.

We understand that this won't be an easy transition, and we're working hard to make this process as easy as possible. We are committed to maintaining the backend service during the sunset period, and are providing several tools to help migrate applications to other services.

First, we're releasing a database migration tool that lets you migrate data from your Parse app to any MongoDB database. During this migration, the Parse API will continue to operate as usual based on your new database, so this can happen without downtime. Second, we're releasing the open source Parse Server, which lets you run most of the Parse API from your own Node.js server. Once you have your data in your own database, Parse Server lets you keep your application running without major changes in the client-side code. For more details, check out our migration guide here.

We know that many of you have come to rely on Parse, and we are striving to make this transition as straightforward as possible. We enjoyed working with each of you, and we have deep admiration for the things you've built. Thank you for using Parse.


Pricing


In late April 2014, they announced a new pricing plan: We’ve grown an incredible amount over these past three years and it came time to revisit our pricing. We set out to improve it in three ways:

  • Make it easier for developers to predict and estimate their costs when using Parse.

  • Make our product more self-serve for developers who grow very quickly on our platform.

  • Offer more for free!

Moving forward, there won’t be different ‘tiers’ of Parse. There’s only one type of Parse account and you can have an unlimited number of apps or games within it. For each of those apps, you get the following:




  • Parse Core

  • 30 api requests per second (+ $100 per additional 10 reqs/sec)

  • 20GB of file storage (+ $0.03 per GB over)

  • 20GB of database storage

  • 2TB of file transfer (+ $0.10 per GB over)

Parse Push

  • 1 million unique recipients/month (+$0.05 per 1,000 unique recipients over)

  • Advanced push targeting, push scheduling, and multiple push certificates available to everyone for free!

Parse Analytics

  • Completely free! (including advanced analytics)

New customers will begin using this model today. If you’re an existing customer, you have six months to opt-in. We expect folks to move over quickly as we’re confident that this is a better model for everyone. At 30 requests/sec, an app can send us 77.76 million API requests in a month before needing to pay a dime. That’s over 70X what we offered before!


The following “app” lets you dial in your desired service level (requests per second is the most important parameter), and see the resulting price (typically $100/month up to $1000/month). You can also set the service per-application, in order to focus the resources on some of your apps, such as the high-traffic ones.


Included in all plans:


For instance, the Parse Data starts at 1GB of database storage, and the Parse Hosting can storage your application files, image files, and web assets, starting at 1GB of file storage.
What is particularly important is that the Cloud Code facility is available, even at the Basic level.

Resources


All documentation is on their web site. This is organized around SDK’s for the major mobile app platforms (iOS, Android, etc.), as well as a set of tutorials.
For a third-party tutorial of setting a Parse-based application (from Tiggzi using their front-end builder in 2012) see http://www.youtube.com/watch?v=lAHdU3ajOSM
Another video tutorial is at http://www.youtube.com/watch?v=E_0llIdtYNA
See also http://www.raywenderlich.com/20482/how-to-choose-the-best-backend-provider-for-your-ios-app-parse-vs-stackmob-vs-appcelerator-cloud-and-more
See also http://cleveryou.net/post/22718728512/parse-stackmob-some-thoughts

Company Information


Founded in mid-2011. Bought by Facebook by $90M in April 2013.
Early funding came from Start Fund, Google Ventures, Menlo Ventures. Total funding was $7.5M with major funding in Series A from Ignition Partners.
Primary competitors included StackMob, Kinvey, and Apigee. New arrivals in the BaaS space include FatFractal, and a provider table for this topic on Wikipedia (now removed) listed over 16 companies in all.

Customers


Besides Facebook itself, they have many large ones including Cisco, IDEO, Travel Channel, Cadillac, Food Network, Hipmunk (travel), etc.
There are over 400 applications based on Parse that they highlight on their site. The total count of apps was 10,000 as of mid-2012 (see http://stackoverflow.com/questions/11283729/how-scalable-is-parse), with a growth rate of 40% per-month. Apps from small companies that we have met with include “Band of the Day” from 955 Designs.

Concepts


The offering is built around a configurable backend storage system, driven by a dashboard that configures accounts, apps, schema, etc. Each app has its own user table, and has authentication and access control facilities. You can have any number of content table schemas. The dashboard provides to manage and monitor the users and the content, as well as generate analytics.
A REST-based API is used, but most developers will use the backend through one of the provide SDK’s which offers a wrapper over the REST-based API itself.

Dashboard


This allows you to select an application, create an application, view data and stats about the application, manage data contents, and manage account information.
There is a selector to choose from a “Light” or “Dark” dashboard, near the bottom. Don’t miss it, as we have found that the “Dark” is a lot easier to read.
Home screen:

This also shows what the “Basic level” limits are: 1M requests (monthly), 1GB of storage, and 1M push notifications (monthly)


Data Management screen:


Technology


It appears that their backend is written in Ruby based on their recruiting efforts. There is no specific mention of what database/persistence layers are used.
Most of their development recruiting is for the various front-ends and developer community support.
Their level of standards-compliance is very good, as they use OAuth and OAuth2 for authentication, and standards for API organization.

Getting Started


The “Tutorial Application for JavaScript” was a Todo list manager. It was described as:
A todo management application built with the JavaScript SDK and based on the canonical Backbone todo app. This app showcases user logins, queries, clientside security, and interactions with various Backbone features like views and collections.

User Management


Every StackMob application has a “user” schema, which has a number of predefined operations, such as registration, signup, etc.
For login management, OAuth and OAuth2 is used.

Cloud Code


This allows you to upload code the Parse platform and have it carried out on their servers.
Enables you to define custom endpoints on the cloud.
The code is written in JavaScript, and can access backend resources such as Data, Files, and Email handlers.

Background Jobs


In September 2013, Parse introduced Background Jobs. These allow you to set up long running tasks by writing code similar to Cloud Functions:
Parse.Cloud.job("userMigration", function(request, status) {

  // Set up to modify user data

  Parse.Cloud.useMasterKey();

  // Query for all users

  var query = new Parse.Query(Parse.User);

  query.each(function(user) {

      // Set and save the change

      user.set("plan", request.params.plan);

      return user.save();

  }).then(function() {

    // Set the job's success status

    status.success("Migration completed successfully.");

  }, function(error) {

    // Set the job's error status

    status.error("Uh oh, something went wrong.");

  });


});
In the above code example, a user migration Background Job has been defined to update a plan field in the Parse.User object. This is a good candidate for a Background Job as it could be a long running process that could timeout if set up as a Cloud Function.
Once you’ve deployed your code, you can add it as a new entry to the jobs schedule in the Web Console. There are many options available to customize the frequency of your jobs, including the start time. You can also view the status of any currently running jobs or previous jobs that have been completed.
In addition to Parse Cloud Code, you may also consider using iron.io to schedule cron jobs.

Analytics



This feature can show usage trends for API calls, push notifications, etc.
What it doesn’t seem to do is allow you filter against specific API calls, such as ones on different schema entities. This would be really useful.

Available Cloud Modules


These are like add-ons within the Heroku system.
The two newest modules: Parse Image Cloud Module and the Parse User Session Module. With the Parse Image Cloud Module, you can manipulate graphical images easily, such as creating a Cloud Code Function to make a thumbnail of a photo. With the Parse User Session Module, we're helping you focus on user experience by adding a great new Express middleware module to help you manage users logging in and out.
At this point, there doesn’t appear to be marketplace for third-party modules.

Developer Community


Parse and Facebook team members will be on hand at Box Developer Day, TwilioCon, and MHacks. We're also hosting the Silicon Valley MongoDB User Group Meetup.
There are several videos from the Developer Day held in September 2013 available at http://blog.parse.com/2013/09/17/parse-developer-day-video-series-keynote-and-developer-show-and-tell/
Video: Parse CPO James Yu talks about the philosophy behind the design of Parse, the enabling purpose of platforms, why being cross platform is pivotal for your product, and how Parse is solving this problem once and for all. The introduction features Mark Zuckerberg. This video is located at http://www.youtube.com/watch?v=rnnjQpyCJec
Some third-party discussion about the announcements at Developer Day are located at http://techcrunch.com/2013/09/05/parse-developer-day/

Parse Unity SDK


Unity provides some impressive tools for helping game developers build cross-platform games. Now, make cross-platform game development even simpler with our Unity SDK and get Parse’s powerful services at your fingertips.

Converting a Backbone.js project


Parse JavaScript SDK is compatible with existing Backbone applications with minimal changes. For more info on converting Backbone apps, see https://www.parse.com/docs/js_guide#convert.
The changes that we dealt with when converting a StackMob application were:

  1. Follow the instructions for installing the SDK for an existing JavaScript app.

  2. Replace all instances of Backbone.Model or StackMob.Model with Parse.Object. When doing so, schemaName should be replaced with an appropriate className that maps your objects to a Parse class:

    var BackboneTodo = Backbone.Model.extend({

      urlRoot: "/todos"

    });

     

    var StackMobTodo = StackMob.Model.extend({



      schemaName: "todo"

    });
    var ParseTodo = Parse.Object.extend({

      className: "Todo"

    });


  3. Replace all instances of Backbone.Collection (or the corresponding StackMob all) with Parse.Collection and specify the Parse.Object class as the model. You should also specify a query so that the collection knows how to fetch the objects:

    var ParseTodoCollection = Parse.Collection.extend({

      model: ParseTodo

    });

     

    var todos = new ParseTodoCollection();



     

    // Construct a query to get the current user's todo items

    var query = new Parse.Query(ParseTodo);

    query.equalTo("user", Parse.User.current());

    todos.query = query;

    todos.fetch();



  4. All Views need to change from Backbone.View to Parse.View.

  5. We also found that calls to .create() in StackMob needed to be changed to .save().

  6. Anywhere you were constructing models from a server you'll need to construct a Parse.Query to grab the objects that you're interested in, similar to what we had to do for the query attribute on the Parse.Collection.

  7. Add or update your app to use user authentication and apply ACLs as necessary to objects.

    Recent Improvements


    This section is extracted from various developer community emails that we have read or have seen in recent blog posts.

    Android Samples


    Many of you have asked for more sample projects and tutorials for our Android SDK. We’ve heard you, and today we’re excited to share three samples and demos for Parse and Android: the sample app Mealspotting, an Android version of our popular One-to-Many Relationships tutorial, and a Facebook tutorial that covers logging users in through Facebook and making requests to Facebook’s API.

    New Ways to Delete Objects


    We’ve added two features that make deleting objects even easier, while giving you the power to perform custom actions when those deletes happen. These include the ability to delete multiple objects at once in the JavaScript SDK via a destroyAll method approved and the ability to run custom Cloud Code before and after delete operations. See the blog post for more details on how to use these new features.

    April 2015 Email


    Have you tried the new Parse Explorer yet?

    Investigate what's happening with a subset of your app's API requests with our powerful yet easy-to-use query language.


    Meet the #1 Grossing Finance App in the App Store

    Learn how MileIQ uses Parse to help employees across the U.S. tackle mileage tracking and reimbursement.
    Supporting Swift with Nullability Annotations

    Our SDKs support Swift in more ways than ever with nullability annotations. Check out how it can help improve your workflow.

    Late 2015 Email


    They have rolled out the beta version of a new Dashboard.

    Usage Notes


    The service has worked correctly and responded promptly in all tests since we turned on the account.

    Open Questions/Issues


    How to support data model table (schema) relationships?
    Could we use the Background Jobs feature to support nightly notifications to players summarizing status?

    Appendix A: Example Programs Created


    We created Parse1018, which is a modification of the ToDo list program.
    We created Parse1019, which is a modification of the “Wine List” application that was used in the Backbone/StackMob demo from CodeCamp 2013. It has been converted into an “Exercise Activity List Management” application.

    Appendix B: Using Parse with Angular.js


    Today our friends at BRANDiD are releasing a boilerplate for Parse and Angular JS, which they've let us share on our blog. If you're looking to build a web app with Parse, we know you'll find all of the hard work they've already done useful!
    See http://blog.parse.com/2013/10/17/guest-post-parse-x-angular-js-boilerplate/ for Details

    Appendix C: Our Account


    The email is jrisberg@aol, with pw q*.
    We are on the Basic plan. There is currently no credit card on file.


    Page


  8. Download 35.27 Kb.

    Share with your friends:




The database is protected by copyright ©ininet.org 2024
send message

    Main page