SlideShare uma empresa Scribd logo
1 de 18
1 © Jive confidential
TASMO
MATERIALIZED VIEWS
OF EVENT STREAMS
USING HBASE
Tasmo
Materialized Views of Event Streams using HBase
Presenters:
Pete Matern
Jonathan Colt
3 © Jive confidential
What’s the problem
• Joining to death at read time
• With our operational constraints of a single point of failure (single db
instance)
• Can only scale up - not out
• Read load far exceeds write load
• Read every field of an object every time any field changed to support
indexing
• Read every field of an object to update one
4 © Jive confidential
What we needed
• Joins performed at write time (materialized views)
• Horizontally scalable
• No single point of failure
• Incremental updates
• Notification of changes
• Idempotency
• Tolerance of duplicate and out of order input
• Front end developers work against their object model rather than HBase
specific constructs.
5 © Jive confidential
What we built: Tasmo
Stateless HA service which
• Maintains materialized views of data
• Consumes our model (declaration of input and output types)
• Notifies consumers when views change
• Replaces all our relational db usage
6 © Jive confidential
How we consume and render our model
• Every reader of our model defines views for Tasmo to maintain
• Views contain joined/filtered data specific to point of use
• Readers of these views render output or further process the data
events
Hbase ReadersTasmo
read viewsread / write
View
definition ViewsViewsViews
7 © Jive confidential
How we declare our input and output (Model)
Type: Content
● Subject: String
● Body: String
● Container: Reference
● Author: Reference
Event Declarations
Type: User
● Username: String
● First Name: String
● Last Name: String
● Creation Date: Long
Type: Content
● Subject
● Container (Type: Folder)
○ Name
○ ModDate
● Author (Type: User)
○ Username
○ CreationDate
View Declaration
8 © Jive confidential
Event > Model > View > Web Page
body = “When can
we try it?”
Model
Container
Content
Author
Comment
Tasmo
Hbase
View
Comment Event
9 © Jive confidential
Web Page backed by View Instance
10 © Jive confidential
How we notify consumers
• Consumers register for notifications on a type of view
• Applying an event to the model in Tasmo results in the set of affected view
instances.
• We push the modified view instances to registered consumers
Search
events
Tasmo
notify
Binary storage
Activity Analysis
11 © Jive confidential
How we maintain search indices
• Define views of data which correspond to the index schemas
• Indexing engine registers for notifications of these view types
• Tasmo fires notifications for affected view instances per event
• Indexing engine reads the modified views, which represent complete and
up to date documents for indexing.
Search
events
Hbase
Tasmo
notify
read
index
views
read / write
12 © Jive confidential
10,000 feet how it works
Consumes events, consults configuration describing joins and selects, applies
all relevant changes in event to update data views
Values
Existence
Relationships
Write
events
Relationships Views
Traverse Join / Select
writes
scans
concurrency
consistency
retry ( multiversion concurrency)
updates /
removes
Tasmo
13 © Jive confidential
Taking over time
• Snowflake id for every event - makes them unique and time orderable
• Event time is based on when the system receives an event
• Event time is used as HBase cell timestamp - logically stale writes no op
• Event time has the room to disambiguate add vs remove:
o Snowflake ids are even numbers.
o Snowflake is used directly for adds
o Snowflake -1 is used for removes
o For a given event - adds trump removes
14 © Jive confidential
Concurrency Issues
• Problem: As different events add/remove relationships in parallel, we can
fail to add/remove elements of views.
• Solution: Per relationship high water marks maintained in an HBase table.
We test the per relationship times we saw during a path traversal against
the high water mark. If we detect we are stale, we retry the operation.
15 © Jive confidential
Why HBase?
• Timestamp control
• Row level atomicity of changes
• Performance and proven scalability
16 © Jive confidential
Roadmap
• Production later this year. Currently heavily used by
developers at Jive.
• Looking at what work could be moved into
coprocessors.
• Considering double writes into two HBase clusters for
higher availability if MTTR is too high in our
environment.
17 © Jive confidential
Questions and Answers
Open source
https://github.com/jivesoftware/tasmo
Please Help!
jonathan.colt@jivesoftware.com
pete@jivesoftware.com
Open Sourcing Tasmo

Mais conteúdo relacionado

Mais de Jive Software an Aurea company

How FICO Kick-Started Collaboration in a Siloed Culture
How FICO Kick-Started Collaboration in a Siloed CultureHow FICO Kick-Started Collaboration in a Siloed Culture
How FICO Kick-Started Collaboration in a Siloed CultureJive Software an Aurea company
 
It's Just Life (and Other Lessons From Top Women in Tech)
It's Just Life (and Other Lessons From Top Women in Tech) It's Just Life (and Other Lessons From Top Women in Tech)
It's Just Life (and Other Lessons From Top Women in Tech) Jive Software an Aurea company
 
Customers are your Best Advocates - Turn Them into your Best Sales Team
Customers are your Best Advocates - Turn Them into your Best Sales TeamCustomers are your Best Advocates - Turn Them into your Best Sales Team
Customers are your Best Advocates - Turn Them into your Best Sales TeamJive Software an Aurea company
 
How to Rethink Your Company Intranet to Deliver Business Value
How to Rethink Your Company Intranet to Deliver Business ValueHow to Rethink Your Company Intranet to Deliver Business Value
How to Rethink Your Company Intranet to Deliver Business ValueJive Software an Aurea company
 

Mais de Jive Software an Aurea company (20)

Engage Your Co-Workers Like Customers
Engage Your Co-Workers Like CustomersEngage Your Co-Workers Like Customers
Engage Your Co-Workers Like Customers
 
Employee Engagement in the Work-Anywhere Era
Employee Engagement in the Work-Anywhere EraEmployee Engagement in the Work-Anywhere Era
Employee Engagement in the Work-Anywhere Era
 
Penn Foster - Encouraging Community Self-Service
Penn Foster - Encouraging Community Self-Service Penn Foster - Encouraging Community Self-Service
Penn Foster - Encouraging Community Self-Service
 
How FICO Kick-Started Collaboration in a Siloed Culture
How FICO Kick-Started Collaboration in a Siloed CultureHow FICO Kick-Started Collaboration in a Siloed Culture
How FICO Kick-Started Collaboration in a Siloed Culture
 
CIOs Are At A Crossroads
CIOs Are At A CrossroadsCIOs Are At A Crossroads
CIOs Are At A Crossroads
 
The Top 10 JiveWorld14 Takeaways
The Top 10 JiveWorld14 TakeawaysThe Top 10 JiveWorld14 Takeaways
The Top 10 JiveWorld14 Takeaways
 
5 Artists, 5 Days: How We Rebranded
5 Artists, 5 Days: How We Rebranded5 Artists, 5 Days: How We Rebranded
5 Artists, 5 Days: How We Rebranded
 
The NextGen Worker - Embrace the Millennial Workstyle
The NextGen Worker - Embrace the Millennial WorkstyleThe NextGen Worker - Embrace the Millennial Workstyle
The NextGen Worker - Embrace the Millennial Workstyle
 
It's Just Life (and Other Lessons From Top Women in Tech)
It's Just Life (and Other Lessons From Top Women in Tech) It's Just Life (and Other Lessons From Top Women in Tech)
It's Just Life (and Other Lessons From Top Women in Tech)
 
Top 9 Social Lessons Learned from Soccer
Top 9 Social Lessons Learned from SoccerTop 9 Social Lessons Learned from Soccer
Top 9 Social Lessons Learned from Soccer
 
Get Real at JiveWorld
Get Real at JiveWorldGet Real at JiveWorld
Get Real at JiveWorld
 
How to use Social for Corporate Communications
How to use Social for Corporate CommunicationsHow to use Social for Corporate Communications
How to use Social for Corporate Communications
 
How to Use Social to Innovate Your Business
How to Use Social to Innovate Your BusinessHow to Use Social to Innovate Your Business
How to Use Social to Innovate Your Business
 
Make 50 Hours of Selling More Productive
Make 50 Hours of Selling More ProductiveMake 50 Hours of Selling More Productive
Make 50 Hours of Selling More Productive
 
Customers are your Best Advocates - Turn Them into your Best Sales Team
Customers are your Best Advocates - Turn Them into your Best Sales TeamCustomers are your Best Advocates - Turn Them into your Best Sales Team
Customers are your Best Advocates - Turn Them into your Best Sales Team
 
How to Use Social for IT Project Management
How to Use Social for IT Project ManagementHow to Use Social for IT Project Management
How to Use Social for IT Project Management
 
How to Rethink Your Company Intranet to Deliver Business Value
How to Rethink Your Company Intranet to Deliver Business ValueHow to Rethink Your Company Intranet to Deliver Business Value
How to Rethink Your Company Intranet to Deliver Business Value
 
How to Use Public Communities for Events
How to Use Public Communities for EventsHow to Use Public Communities for Events
How to Use Public Communities for Events
 
6 Secrets to Social Success
6 Secrets to Social Success6 Secrets to Social Success
6 Secrets to Social Success
 
Deal Management Made Easy: The Devoteam Story
Deal Management Made Easy: The Devoteam StoryDeal Management Made Easy: The Devoteam Story
Deal Management Made Easy: The Devoteam Story
 

Último

Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationSlibray Presentation
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticscarlostorres15106
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfAddepto
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubKalema Edgar
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebUiPathCommunity
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLScyllaDB
 
Powerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time ClashPowerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time Clashcharlottematthew16
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupFlorian Wilhelm
 
Search Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfSearch Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfRankYa
 
SAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxSAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxNavinnSomaal
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brandgvaughan
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...Fwdays
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machinePadma Pradeep
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii SoldatenkoFwdays
 
My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024The Digital Insurer
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 3652toLead Limited
 
Commit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easyCommit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easyAlfredo García Lavilla
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Scott Keck-Warren
 

Último (20)

Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck Presentation
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdf
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding Club
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio Web
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQL
 
Powerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time ClashPowerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time Clash
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project Setup
 
Search Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfSearch Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdf
 
SAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxSAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptx
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brand
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machine
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko
 
My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365
 
Commit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easyCommit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easy
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024
 

Open Sourcing Tasmo

  • 1. 1 © Jive confidential TASMO MATERIALIZED VIEWS OF EVENT STREAMS USING HBASE
  • 2. Tasmo Materialized Views of Event Streams using HBase Presenters: Pete Matern Jonathan Colt
  • 3. 3 © Jive confidential What’s the problem • Joining to death at read time • With our operational constraints of a single point of failure (single db instance) • Can only scale up - not out • Read load far exceeds write load • Read every field of an object every time any field changed to support indexing • Read every field of an object to update one
  • 4. 4 © Jive confidential What we needed • Joins performed at write time (materialized views) • Horizontally scalable • No single point of failure • Incremental updates • Notification of changes • Idempotency • Tolerance of duplicate and out of order input • Front end developers work against their object model rather than HBase specific constructs.
  • 5. 5 © Jive confidential What we built: Tasmo Stateless HA service which • Maintains materialized views of data • Consumes our model (declaration of input and output types) • Notifies consumers when views change • Replaces all our relational db usage
  • 6. 6 © Jive confidential How we consume and render our model • Every reader of our model defines views for Tasmo to maintain • Views contain joined/filtered data specific to point of use • Readers of these views render output or further process the data events Hbase ReadersTasmo read viewsread / write View definition ViewsViewsViews
  • 7. 7 © Jive confidential How we declare our input and output (Model) Type: Content ● Subject: String ● Body: String ● Container: Reference ● Author: Reference Event Declarations Type: User ● Username: String ● First Name: String ● Last Name: String ● Creation Date: Long Type: Content ● Subject ● Container (Type: Folder) ○ Name ○ ModDate ● Author (Type: User) ○ Username ○ CreationDate View Declaration
  • 8. 8 © Jive confidential Event > Model > View > Web Page body = “When can we try it?” Model Container Content Author Comment Tasmo Hbase View Comment Event
  • 9. 9 © Jive confidential Web Page backed by View Instance
  • 10. 10 © Jive confidential How we notify consumers • Consumers register for notifications on a type of view • Applying an event to the model in Tasmo results in the set of affected view instances. • We push the modified view instances to registered consumers Search events Tasmo notify Binary storage Activity Analysis
  • 11. 11 © Jive confidential How we maintain search indices • Define views of data which correspond to the index schemas • Indexing engine registers for notifications of these view types • Tasmo fires notifications for affected view instances per event • Indexing engine reads the modified views, which represent complete and up to date documents for indexing. Search events Hbase Tasmo notify read index views read / write
  • 12. 12 © Jive confidential 10,000 feet how it works Consumes events, consults configuration describing joins and selects, applies all relevant changes in event to update data views Values Existence Relationships Write events Relationships Views Traverse Join / Select writes scans concurrency consistency retry ( multiversion concurrency) updates / removes Tasmo
  • 13. 13 © Jive confidential Taking over time • Snowflake id for every event - makes them unique and time orderable • Event time is based on when the system receives an event • Event time is used as HBase cell timestamp - logically stale writes no op • Event time has the room to disambiguate add vs remove: o Snowflake ids are even numbers. o Snowflake is used directly for adds o Snowflake -1 is used for removes o For a given event - adds trump removes
  • 14. 14 © Jive confidential Concurrency Issues • Problem: As different events add/remove relationships in parallel, we can fail to add/remove elements of views. • Solution: Per relationship high water marks maintained in an HBase table. We test the per relationship times we saw during a path traversal against the high water mark. If we detect we are stale, we retry the operation.
  • 15. 15 © Jive confidential Why HBase? • Timestamp control • Row level atomicity of changes • Performance and proven scalability
  • 16. 16 © Jive confidential Roadmap • Production later this year. Currently heavily used by developers at Jive. • Looking at what work could be moved into coprocessors. • Considering double writes into two HBase clusters for higher availability if MTTR is too high in our environment.
  • 17. 17 © Jive confidential Questions and Answers Open source https://github.com/jivesoftware/tasmo Please Help! jonathan.colt@jivesoftware.com pete@jivesoftware.com