Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Stanfy MadCode Meetup#5: Backend without code. Parse.com: myth and reality

Stanfy MadCode Meetup#5: Backend without code. Parse.com: myth and reality

Full post
https://medium.com/@stanfymobile/backend-without-code-parse-com-myth-vs-reality-9965d7b3606

Key points:
1. How many developers are needed to write client-server mobile app? Fun and easy: set up a new app with Parse.com.
2. Feeling confident enough to use own server? Check migration issues.
3. Own experience: limitations and best practices

042b7c0e45c53de46667f07de2fb2614?s=128

vixentael

April 08, 2015
Tweet

More Decks by vixentael

Other Decks in Programming

Transcript

  1. Backend without code. parse.com: myth vs reality

  2. Mobile Backend as a Service without MBaaS • need own

    server, database, services • time/costs/devs to setup • flexible server configuration Backend without code. parse.com: myth vs reality. Stanfy MadCode Meetup, stanfy.com, 08.04.2015 with MBaaS • ready to start • no need of server developers* • dependent on MBaaS configuration
  3. our background social network • facebook login • likes, shares,

    comments • complicated relations between users yet another social network • many pictures • anonymous users • lots of push notifications (incl geo-based) • moderation • complicated business logic (smart feed) personal dairy • many photos • offline mode with synchronization medication alarm • push notifications • offline mode • customizations ‘on the fly’ • client-friendly users’ statistics Backend without code. parse.com: myth vs reality. Stanfy MadCode Meetup, stanfy.com, 08.04.2015
  4. why would I use Parse? • cross platform • easy

    setup • proof of concept / mvp • push notifications • cost saving* • cloud code disclaimer: i don’t work for parse.com Backend without code. parse.com: myth vs reality. Stanfy MadCode Meetup, stanfy.com, 08.04.2015
  5. be careful if • huge application (many objects) • million

    of users • streaming • chatting Backend without code. parse.com: myth vs reality. Stanfy MadCode Meetup, stanfy.com, 08.04.2015
  6. security questionable Backend without code. parse.com: myth vs reality. Stanfy

    MadCode Meetup, stanfy.com, 08.04.2015
  7. security • application keys are public • easy to find

    keys and connect to db • easy to generate spam requests • turn off the “Allow client class creation” • set the correct ACL permissions • do not allow read/edit data to non-authorized users Backend without code. parse.com: myth vs reality. Stanfy MadCode Meetup, stanfy.com, 08.04.2015
  8. easy setup • create Parse application • download SDK •

    write code • write+deploy cloud code* Backend without code. parse.com: myth vs reality. Stanfy MadCode Meetup, stanfy.com, 08.04.2015
  9. client (iOS) SDK • cocoapods • “saveEventually” • cache •

    inner storage • working with files (PFFile) • in-app purchases support • ready UI interfaces • weird crashes —> Backend without code. parse.com: myth vs reality. Stanfy MadCode Meetup, stanfy.com, 08.04.2015
  10. saving pictures from phone • restrictions: 10MB per file •

    native support of uploading, downloading, progress (PFFile) • long upload* • Amazon S3 as alternative Backend without code. parse.com: myth vs reality. Stanfy MadCode Meetup, stanfy.com, 08.04.2015
  11. cloud code: awesomeness • mongoDB • REST API • javascript

    + python • better to do everything on cloud • debug mode: “parse develop AppName” • cloud modules (email sending) Backend without code. parse.com: myth vs reality. Stanfy MadCode Meetup, stanfy.com, 08.04.2015
  12. cloud code: awesomeness (2) • triggers (beforeSave, afterSave) • join

    queries • background jobs • Parse.Promises (a-la semaphores) • paging support (limit, offset) Backend without code. parse.com: myth vs reality. Stanfy MadCode Meetup, stanfy.com, 08.04.2015
  13. cloud code: pain • async (“callback hell”) • debugging: •

    change CC -> deploy -> check -> change • logs only • short execution time • 15/3 sec for function/trigger • 15 min for job • application keys in global.json file Backend without code. parse.com: myth vs reality. Stanfy MadCode Meetup, stanfy.com, 08.04.2015
  14. cloud code: pain (2) • inner queries • 1000 objects

    limit per query • limited ‘count’ operation Backend without code. parse.com: myth vs reality. Stanfy MadCode Meetup, stanfy.com, 08.04.2015
  15. dev and prod apps • create dev app in Parse

    • develop-develop-develop • master build points on dev app • iOS keys • javascript keys • use ‘parse develop AppName’ to debug CC • create/clone prod app in Parse • deploy CC • appstore build points on prod app • iOS keys • javascript keys Backend without code. parse.com: myth vs reality. Stanfy MadCode Meetup, stanfy.com, 08.04.2015
  16. dev and prod apps separate applications on Parse different keys

    inside iOS Backend without code. parse.com: myth vs reality. Stanfy MadCode Meetup, stanfy.com, 08.04.2015
  17. dev and prod apps save user version on iOS check

    version on CC user table Backend without code. parse.com: myth vs reality. Stanfy MadCode Meetup, stanfy.com, 08.04.2015
  18. to migrate from Parse • update client applications (iOS) •

    one click export -> json files Backend without code. parse.com: myth vs reality. Stanfy MadCode Meetup, stanfy.com, 08.04.2015
  19. benefits from dev perspective • easy to integrate, easy to

    use • cool client SDK • awesome* documentation and forum • push notifications (fast and easy setup) • cloud code awesomeness Backend without code. parse.com: myth vs reality. Stanfy MadCode Meetup, stanfy.com, 08.04.2015
  20. benefits from customer/manager perspective • reduce time to market •

    reduce development/support cost* • various analytics (users, events, crashes..) • various services out of the box (email confirmation, sending emails..) • flexible pricing • user-friendly admin db Backend without code. parse.com: myth vs reality. Stanfy MadCode Meetup, stanfy.com, 08.04.2015
  21. disadvantages from developer perspective • request-driven development (limits) • not

    developer-friendly admin site (can’t drop class programmatically) • no autobackups for free plan • cloud code pain Backend without code. parse.com: myth vs reality. Stanfy MadCode Meetup, stanfy.com, 08.04.2015
  22. disadvantages from client/manager perspective • dependence on 3rd-party servers •

    long-term strategy risks (“what if Parse will be shut tomorrow?”) • performance issues* • not flexible for business (“we can’t implement this!”) • limited build-in set of tools • cost* • hard to foresee spendings Backend without code. parse.com: myth vs reality. Stanfy MadCode Meetup, stanfy.com, 08.04.2015
  23. useful links https://parse.com/docs/ what is the best baas http://www.quora.com/What-is-the-best-backend-as-a-service-provider http://www.quora.com/What-is-Baas-Backend-as-a-service-How-does-Parse-StackMob-

    FireBase-Go-Instant-differ-from-each-other baas or not bass http://venturebeat.com/2014/04/10/to-baas-or-not-to-baas-3-things-to-consider-before-you- make-the-call/ http://www.smashingmagazine.com/2014/12/15/understanding-mobile-back-end-as-a-service/ Backend without code. parse.com: myth vs reality. Stanfy MadCode Meetup, stanfy.com, 08.04.2015
  24. useful links (2) limits of Parse http://profi.co/all-the-limits-of-parse/ https://parse.com/docs/cloud_code_guide#functions-resource https://parse.com/docs/cloud_code_guide#jobs Parse

    scalability http://stackoverflow.com/questions/11283729/how-scalable-is-parse https://parse.com/questions/scalability http://blog.parse.com/2013/12/19/building-scalable-apps-on-parse/ Parse performance http://blog.blastlab.co/post/95809259581/performance-tests-of-the-parse-com Backend without code. parse.com: myth vs reality. Stanfy MadCode Meetup, stanfy.com, 08.04.2015
  25. useful links (3) Parse security https://parse.com/about/security http://blog.parse.com/2014/06/30/parse-security-i-are-you-the-key-master/ http://blog.parse.com/2014/07/07/parse-security-ii-class-hysteria/ http://blog.parse.com/2014/07/14/parse-security-iii-are-you-on-the-list/ http://blog.parse.com/2014/07/21/parse-security-iv-ahead-in-the-cloud/

    http://blog.parse.com/2014/07/28/parse-security-v-how-to-make-friends/ https://www.linkedin.com/groups/Is-Parse-secure-solution-2204708.S.277308762 https://www.webniraj.com/2013/08/01/using-the-parse-javascript-sdk-be-careful/ Backend without code. parse.com: myth vs reality. Stanfy MadCode Meetup, stanfy.com, 08.04.2015
  26. useful links (4) experience using Parse https://news.ycombinator.com/item?id=8347310 migration http://blog.parse.com/2013/05/13/launch-and-iterate-parse-data-migrations/ http://blog.parse.com/2012/03/09/one-click-export/

    http://blog.human-friendly.com/parse-data-collection-disabled https://catalyze.io/blog/migrating-from-parse-to-catalyze Backend without code. parse.com: myth vs reality. Stanfy MadCode Meetup, stanfy.com, 08.04.2015
  27. useful links (5) "Безопасность Parse в iOS приложении" http://habrahabr.ru/post/247541/ "Социальная

    сеть без сервера. История разработки iOS-клиента и backend" http://habrahabr.ru/post/198864/ "Сайт без бекэнда: аутентификация пользователя в BaaS parse.com через социальные сети” http://habrahabr.ru/post/248511/ Backend without code. parse.com: myth vs reality. Stanfy MadCode Meetup, stanfy.com, 08.04.2015
  28. illustrations Alexander Aksinin http://www.aksinin.com/gallery.php?lang=en&graphic Mark Knol https://www.flickr.com/photos/markknol/with/4387497595/ James Bills http://butdoesitfloat.com/Time-travel-in-the-classic-sense-has-no-place-in-rational-theory-but

    Backend without code. parse.com: myth vs reality. Stanfy MadCode Meetup, stanfy.com, 08.04.2015
  29. Last slide @vixentael Backend without code. parse.com: myth vs reality.

    Stanfy MadCode Meetup, stanfy.com, 08.04.2015