A presentation I gave at the Derailed meetup in Denver on October 24th, 2012.
Behavioral DatabasesNext Generation NoSQL AnalyticsBy Ben Johnson
View Slide
My Background
Former Oracle DBA
Former Oracle DBABehavioral Analytics
Former Oracle DBAData VisualizationBehavioral Analytics
Why did I write adatabase?
Other Databases Are Too SlowRedis100K ops/secondPostgreSQL5K QPS/core
Processing Needed to Occur Near DataClient Server1ms1ms
Processing Needed to Occur Near DataClient Server1ms1ms1ms1ms
Processing Needed to Occur Near DataClient Server1ms1ms1ms1ms1ms1ms
Processing Needed to Occur Near DataClient Server1ms1ms1ms1ms1ms1ms1ms1ms
Processing Needed to Occur Near Data
Memory is getting cheap. Use it.2010$20/GBhttp://www.jcmit.com/memoryprice.htm
Memory is getting cheap. Use it.2011$10/GB2010$20/GBhttp://www.jcmit.com/memoryprice.htm
Memory is getting cheap. Use it.2012$5/GB2011$10/GB2010$20/GBhttp://www.jcmit.com/memoryprice.htm
Traditional Databases Have a LotOf Features I Don’t Need
Locks & Latches
Transactions
Traditional Databases are Limited toSimple Data AccessKey/Value Tabular
Traditional Databases are Limited toSimple Data AccessKey/Value Tabular(Boring)
Traditional Databases Are Not Real-Time
Basics of Behavioral Data
Actions
Actions & State
Actions & State + Time
ClickstreamLogsSensor DataFinancialTransactionsIVR
Important Differences InBehavioral Data
Behavioral Datais Historical
Behavioral Data is Isolated
Isolated = Concurrency
Performance / Internals
Aggregates100M events / sec / core
OptimizationsStored by object then timeMemory mappedEasy, compact data format
SimplicitySupports Int64, Double, String & BoolMessagePack EncodedC99, No Dependencies
Writing Your Own Language(Tangent)
EQL(Event Query Language)
Qip
Qip(Doesn’t stand for anything)
What is Qip?* LLVM-backed query processing language.* JIT compiled on the fly.* As fast as C.* Removed from build because of complexity.
GitHub Archive Visualizer(Demo)
Ruby to SkyIntegration
Add EventSkyDB.add_event(new Event(object_id:1,timestamp: Time.now,action: “/sign_up”,data: {name: “John”,age: 20}))
Next ActionsSkyDB.next_actions([“/”,“/sign_up”,“/checkout”])
What’s NextFor Sky?
More AnalyticsFunctions!
Cohort Analysis1 2 3 4 5Jan 80% 70% 65% 63% 62%Feb 83% 73% 70% 69%Mar 87% 78% 75%Apr 89% 80%May 90%Month Signed UpMonths After Signing Up
DAGsHome PageSign UpCheckoutViewProductCancelOrder
AwesomeOpen SourceAnalytics ToolsIt’s like MixPanel that you can install!
Modules!
PredictiveBehavioral AnalyticsWhat will your users do next?
Risk Analysis
Anomaly Dectection /Fraud Detection
Questions?
Contact Info@benbjohnson[email protected]