building a better baas
Post on 05-Dec-2014
379 Views
Preview:
DESCRIPTION
TRANSCRIPT
Building the better BaaSEd Anuff & Nate McCall
@edanuff @zznate
What’s a BaaS and what’s so special about Usergrid?
Ed AnuffUsergrid Founder, Apigee Product Strategist
3
App, Cloud, and HTTP
4
No Web Stack
5
Page Templates
MVC Logic
Database
Just Apps and APIs
6
Building A Platform
7
Not just an App
8
Developer
App
TeamTeam Team
Team
App App App
App
Team
App
Team
TeamTeam Team
App App App App App App
Key Challenges
• New Type Of Database (Cassandra)• New Type Of Deployment (Elastic in the Cloud, Small & Fast on the Desktop)• New Type of Access (REST API, SDKs)• New Type of Learning Curve (Smart Docs & Swagger)
15
Major Milestones & Progress
• 2011 – Usergrid released as first Open Source BaaS• 2012 – Usergrid becomes part of Apigee• 2012 – Apigee ships Enterprise App Services• 2013 – Integrated as Apigee Edge BaaS• 2013 – Usergrid goes to Apache• 2014 – Apache Usergrid 1.0 release!• 2014 – Apigee 127 Developer Kit with Node.js, Volos, and Usergrid• 2014 – Apigee BaaS 2.0 and Usergrid 2.0 Beta
16
How do you use a BaaS?
17
/users
/groups
/users/me/followers
/restaurants/products/car-washes
/<whatever>
POST /devices/<id>
POST /events
{ “category” : “ads”, “counters” : { “ad_clicks” : 5}}
/users/ed/friends/nate
/users/ed/likes/foods/pizza
GET /restaurants?near=37.803, -122.404
GET /restaurants?ql=name contains ‘pizza’ and within 5m of 39.962,-105.114
POST /users/me/activities
{ “title”: “look”, “location”: …}
GET /users/me/feed
[{ “title”: “Ed ate a slice of pizza”, “location”: …}]
postUserActivity(me, activity)
[client postUserActivity: “me”activity: activityObj]
/token?grant_type=...
/auth/facebook?fb_access_token=…
/users?filter=facebook.first_name eq 'john'
/users?ql=name eq 'john' and facebook.education.school.name contains '...'
What’s Usergrid 2.0 all about?
Nate McCallApache Usergrid PPMC & Cassandra MVP
31
Who is this man and why isn’t he here?
32
Todd Nine, Lead Architect for Apigee Edge BaaS, Apache Usergrid Committer, andRecently Married Man as of Last Friday, now on Honeymoon
New Pieces of the Stack
33
RxJava GuicyFigArchaius
Challenges
• 1.0 Architecture had a number of Cassandra anti-patterns
• Enterprise users wanted to load and query large datasets
• Cassandra moving to 2.0 with CQL3, deprecating Thrift protocol
• Team wanted to leverage new indexing models of Elastic Search
34
New Architectures
• Elastic Search
• Cassandra 2.0+
• Moving most common operations to CQL as the transport
• Archaius and Guice for dynamic configuration management
• Hystrix and RxJava
35
New Architectures: Elastic Search
• Right tool for the job
• Cassandra worked… until it didn’t.
• Well known operationalization characteristics
• Scale-out was well understood for “full text search” use case
36
New Architectures: Cassandra 2.0/2.1
• Still best of breed NoSQL solution for scale
• Off-heap performance improvements
• Failure scenario performance improvements
37
New Architectures: Archaius and Guice
• Properties typing
• Property change polling
• Hierarchical callbacks on changes
• Load from anywhere dynamic sources
• … all via Guice annotations
38
New Architectures: Archaius + Guice = GuicyFig
39
New Architectures: Archaius + Guice = GuicyFig
40
New Architectures: Hystrix and RxJava
• Compose sequences of asynchronous events declaratively
• Circuit breaker pattern for back-off and retry
• Natural fit with complex, asynchronous operations such as graph updates…
41
New Architectures: RxJava Example
42
More Stuff
• Major components are plug-able
• MVCC
• Directed edge graph supports time series and collections
• Chop load testing framework
43
New Open Source Projects Spun Out
• Judo-Chop: annotation based load testing framework
• GuicyFig: combination of Netflix’s Archaius and Google’s Guice
• Modular Cassandra JUnit integration (coming soon!)
44
What’s next?
45
Usergrid 3.0
• V2 API (V3?)
• Subscriptions (standing server-side queries with notifications)
• WebSocket/Server-side Events
• WebHooks
• Data storage management (reporting, limits, etc.)
• Collection management (deletes, copies, etc.)
• Consistency exposed via API(conditional puts, etc.)
• Indexing API
• Queues
• Expanded/pluggable sign-in (more Oauth, LDAP, etc.)
46
How can you get involved?
47
48
http://www.usergrid.org
http://developer.apigee.com
Thank you
top related