SlideShare a Scribd company logo
1 of 17
http://vimeo.com/ardanstudios/gophercon
BUSINESS PROBLEM
Database
Application Data
Offer Data
User Data
Online / Coupons
Credit Card
Advice
Daily Deals
Registration
Social
Financial
Impressions / Clicks
Alerts
Budget
Transactions
Logins
Navigation
Events
Many applications have lots of great actionable data on users. How can applications use that
data to provide users offers, advice and help?
• Dynamic Feed Management
• Add new offer feeds, advice or help at runtime.
• No builds required to add new feeds.
• Dynamic Rule Management
• Add, edit and execute rules at runtime.
• Write rules against the actionable data that targets users.
• Have all the user and application data be available for writing rules.
• No builds required to add new rules.
BUSINESS PROBLEM
Our Answer
Go Language MongoDB Mgo/Beego
If we had a system that could do the following, we would have something:
http://docs.mongodb.org/manual/core/data-modeling-introduction/
WHY MONGODB - DYNAMIC FEED MANAGEMENT
Data is stored in “Collections” as
individual documents.
Relationships can be created by using
references. This is in step with how
relational database systems store data.
MongoDB’s schemaless database provides great flexibility.
http://docs.mongodb.org/manual/core/data-modeling-introduction/
WHY MONGODB - DYNAMIC FEED MANAGEMENT
Embedding data allows the greatest flexibility and eliminates the need for “joins” by keeping all
the data organized in a single document. This allows for dynamic feed management.
Scheduler
Checks the schedules
and posts inventory
jobs in queue.
Processor
Performs the data
retrieval and insertion.
Two Go programs perform all the feed management work
WHY GO - DYNAMIC FEED MANAGEMENT
The Feed System Is Driven By Data
Go supports cross platform application development. This allows for building programs that can
be used in high-scale cloud platforms like Iron.IO.
• Write Rules that Can be Updated and Applied at Runtime
• Pass Variables to Filter and Pin Point Relevance
• Use Data Aggregation Techniques to Filter and Group Data
• Build Tests Against Aggregated Datasets
• Build Tests Against Multiple Aggregated Datasets
• Publish Data from Offer and Internal Feeds
DYNAMIC RULE MANAGEMENT
Our Answer
Go Language MongoDB Mgo/Beego
Building rules is a core piece of the system. If we had a rule system that could do the following,
we would have something.
http://docs.mongodb.org/manual/core/aggregation-pipeline/
WHY MONGODB - DYNAMIC RULE MANAGEMENT
We can leverage the aggregation pipeline for writing rules.
VARIABLE RULES - DYNAMIC RULE MANAGEMENT
Pass Variables to Filter & Pin Point Relevance
• Substitute userId for this value in any
rule being applied.
• Substitute screen-tab for this value in
any rule being applied.
For Variable Substitution
• When the user is on the user tab.
• When the budget item is for entertainment expenses.
• When the transaction record is a grocery transaction.
Rule Type: variable
{
"userId" : "12345",
"screen-tab" : "user"
}
Variable rules take variable data that is passed into the rule from the application. Variables are
similar to query string parameters on an URL. They can be tested for specific values.
PIPELINE RULES - DYNAMIC RULE MANAGEMENT
• When the user is younger than 40 years old.
• When the user is single.
• When the user has a Gmail account.
User Demographics : (User Collection)
Rule Type: pipeline
{ "$match" : { "user_id" : "#userId#" }}
{ "$match" : { "age" : { "$lt" : 40}}}
Pipeline rules are run through the MongoDB aggregation pipeline. Datasets can be checked for
specific conditions or saved for use in later Go Template rules.
PIPELINE RULES - DYNAMIC RULE MANAGEMENT
• When the user has spent more than $20 this month on movies.
• When the user has over 5 transactions for less than $5 this week.
• When the user has spent over $5,000 in the past 30 days.
User Transactions : (User_Transactions Collection)
Rule Type: pipeline
{ "$match" : { "user_id" : "#userId#", "category" : "movies" }}
.
{ "$group" : { "_id" : { "category" : "$category" }, "amount" :
{ "$sum" : "$amount" }}}
.
{ "$match" : { "amount" : { "$gt" : 20.00}}}
.
Pipeline rules are run through the MongoDB aggregation pipeline. Datasets can be checked for
specific conditions or saved for use in later Go Template rules.
GO TEMPLATE RULES - DYNAMIC RULE MANAGEMENT
• When the user spends over $100 on groceries and entertainment.
• When the user has a G+ account and is over 40.
• When the user is married and spent over $1,000 last week.
Compare Multiple Datasets
Rule Type: template
{{$movies := index .Movies "amount"}}
.
{{$dining := index .Dining "amount"}}
.
{{if gt $dining $movies}}
VALID
{{end}}
.
Template rules are used to compare multiple datasets generated by aggregation pipeline
queries. Multiple datasets can be compared and checked for specific conditions.
• Go Language
• Systems programming language
• Compiles to binary code for target OS/Architectures
• Cross compile on many operating systems
• Access to scalable cloud computing environments
• MGO driver for Go provides excellent MongoDB support
• MongoDB
• Scalability and redundancy out of the box
• Great MongoDB hosting providers
• Schemaless database that provides great flexibility
• Aggregation pipeline to build rules and datasets
• Can search against text with good performance
• Beego Web Framework
• MVC based web framework
• Enough framework to be productive without being handcuffed
• Sits on top of the Go HTTP package
• Excellent web service and view support
WHY GO, MONGODB and BEEGO - SOLUTION
By combining the data flexibility and aggregation capabilities of MongoDB with the Go language
and template framework, we have a scalable, redundant and feature rich solution.
• Go, MGO, MongoDB and Beego are powerful technologies.
• Create data driven and dynamic systems with Go and MongoDB.
• Leverage powerful cloud systems like Iron.IO and Heroku.
• The MongoDB aggregation pipeline is fast and powerful.
• Go templates provide a seamless way to process datasets.
• These technologies can be used to create highly scalable systems.
CONCLUSION
MongoDB and Go are technologies that work incredibly well together. The communities for both
technologies are vibrant and expanding. Now is the time to consider these technologies.
Building A Relevancy Engine Using MongoDB and Go

More Related Content

What's hot

The Right (and Wrong) Use Cases for MongoDB
The Right (and Wrong) Use Cases for MongoDBThe Right (and Wrong) Use Cases for MongoDB
The Right (and Wrong) Use Cases for MongoDBMongoDB
 
[MongoDB.local Bengaluru 2018] Rapid Development at Scale with MongoDB at Koinex
[MongoDB.local Bengaluru 2018] Rapid Development at Scale with MongoDB at Koinex[MongoDB.local Bengaluru 2018] Rapid Development at Scale with MongoDB at Koinex
[MongoDB.local Bengaluru 2018] Rapid Development at Scale with MongoDB at KoinexMongoDB
 
MongoDB and Web Scraping with the Gyes platform. MongoDB Atlanta 2013
MongoDB and Web Scraping with the Gyes platform. MongoDB Atlanta 2013MongoDB and Web Scraping with the Gyes platform. MongoDB Atlanta 2013
MongoDB and Web Scraping with the Gyes platform. MongoDB Atlanta 2013Jesus Diaz
 
Business Jumpstart: The Right (and Wrong) Use Cases for MongoDB
Business Jumpstart: The Right (and Wrong) Use Cases for MongoDBBusiness Jumpstart: The Right (and Wrong) Use Cases for MongoDB
Business Jumpstart: The Right (and Wrong) Use Cases for MongoDBMongoDB
 
Dynamic Website Designing
Dynamic Website DesigningDynamic Website Designing
Dynamic Website DesigningOGEN Infosystem
 
MongoDB .local Munich 2019: MongoDB Atlas Auto-Scaling
MongoDB .local Munich 2019: MongoDB Atlas Auto-ScalingMongoDB .local Munich 2019: MongoDB Atlas Auto-Scaling
MongoDB .local Munich 2019: MongoDB Atlas Auto-ScalingMongoDB
 
Introduction about Mongo DB for Beginners
Introduction about Mongo DB for Beginners Introduction about Mongo DB for Beginners
Introduction about Mongo DB for Beginners battikaran
 
01 nosql and multi model database
01   nosql and multi model database01   nosql and multi model database
01 nosql and multi model databaseMahdi Atawneh
 
SQL vs MongoDB
SQL vs MongoDBSQL vs MongoDB
SQL vs MongoDBcalltutors
 
Multi model-databases 29-10-2014 LJC
Multi model-databases 29-10-2014 LJCMulti model-databases 29-10-2014 LJC
Multi model-databases 29-10-2014 LJCArangoDB Database
 
MongoDB .local Chicago 2019: MongoDB Atlas Data Lake Technical Deep Dive
MongoDB .local Chicago 2019: MongoDB Atlas Data Lake Technical Deep DiveMongoDB .local Chicago 2019: MongoDB Atlas Data Lake Technical Deep Dive
MongoDB .local Chicago 2019: MongoDB Atlas Data Lake Technical Deep DiveMongoDB
 
Expanding Retail Frontiers with MongoDB
Expanding Retail Frontiers with MongoDBExpanding Retail Frontiers with MongoDB
Expanding Retail Frontiers with MongoDBNorberto Leite
 
Beyond the Basics 3: Introduction to the MongoDB BI Connector
Beyond the Basics 3: Introduction to the MongoDB BI ConnectorBeyond the Basics 3: Introduction to the MongoDB BI Connector
Beyond the Basics 3: Introduction to the MongoDB BI ConnectorMongoDB
 
MongoDB Days Silicon Valley: Jumpstart: The Right and Wrong Use Cases for Mon...
MongoDB Days Silicon Valley: Jumpstart: The Right and Wrong Use Cases for Mon...MongoDB Days Silicon Valley: Jumpstart: The Right and Wrong Use Cases for Mon...
MongoDB Days Silicon Valley: Jumpstart: The Right and Wrong Use Cases for Mon...MongoDB
 
Addressing Your Backup Needs Using Ops Manager and Atlas
Addressing Your Backup Needs Using Ops Manager and AtlasAddressing Your Backup Needs Using Ops Manager and Atlas
Addressing Your Backup Needs Using Ops Manager and AtlasMongoDB
 
MongoDB .local Toronto 2019: MongoDB Atlas Jumpstart
MongoDB .local Toronto 2019: MongoDB Atlas JumpstartMongoDB .local Toronto 2019: MongoDB Atlas Jumpstart
MongoDB .local Toronto 2019: MongoDB Atlas JumpstartMongoDB
 
Webinar: Expanding Retail Frontiers with MongoDB
 Webinar: Expanding Retail Frontiers with MongoDB Webinar: Expanding Retail Frontiers with MongoDB
Webinar: Expanding Retail Frontiers with MongoDBMongoDB
 
Webinar: Introducing the MongoDB Connector for BI 2.0 with Tableau
Webinar: Introducing the MongoDB Connector for BI 2.0 with TableauWebinar: Introducing the MongoDB Connector for BI 2.0 with Tableau
Webinar: Introducing the MongoDB Connector for BI 2.0 with TableauMongoDB
 

What's hot (20)

The Right (and Wrong) Use Cases for MongoDB
The Right (and Wrong) Use Cases for MongoDBThe Right (and Wrong) Use Cases for MongoDB
The Right (and Wrong) Use Cases for MongoDB
 
[MongoDB.local Bengaluru 2018] Rapid Development at Scale with MongoDB at Koinex
[MongoDB.local Bengaluru 2018] Rapid Development at Scale with MongoDB at Koinex[MongoDB.local Bengaluru 2018] Rapid Development at Scale with MongoDB at Koinex
[MongoDB.local Bengaluru 2018] Rapid Development at Scale with MongoDB at Koinex
 
Dynamic Website
Dynamic Website Dynamic Website
Dynamic Website
 
MongoDB and Web Scraping with the Gyes platform. MongoDB Atlanta 2013
MongoDB and Web Scraping with the Gyes platform. MongoDB Atlanta 2013MongoDB and Web Scraping with the Gyes platform. MongoDB Atlanta 2013
MongoDB and Web Scraping with the Gyes platform. MongoDB Atlanta 2013
 
Business Jumpstart: The Right (and Wrong) Use Cases for MongoDB
Business Jumpstart: The Right (and Wrong) Use Cases for MongoDBBusiness Jumpstart: The Right (and Wrong) Use Cases for MongoDB
Business Jumpstart: The Right (and Wrong) Use Cases for MongoDB
 
Dynamic Website Designing
Dynamic Website DesigningDynamic Website Designing
Dynamic Website Designing
 
MongoDB .local Munich 2019: MongoDB Atlas Auto-Scaling
MongoDB .local Munich 2019: MongoDB Atlas Auto-ScalingMongoDB .local Munich 2019: MongoDB Atlas Auto-Scaling
MongoDB .local Munich 2019: MongoDB Atlas Auto-Scaling
 
Introduction about Mongo DB for Beginners
Introduction about Mongo DB for Beginners Introduction about Mongo DB for Beginners
Introduction about Mongo DB for Beginners
 
01 nosql and multi model database
01   nosql and multi model database01   nosql and multi model database
01 nosql and multi model database
 
SQL vs MongoDB
SQL vs MongoDBSQL vs MongoDB
SQL vs MongoDB
 
Multi model-databases 29-10-2014 LJC
Multi model-databases 29-10-2014 LJCMulti model-databases 29-10-2014 LJC
Multi model-databases 29-10-2014 LJC
 
MongoDB .local Chicago 2019: MongoDB Atlas Data Lake Technical Deep Dive
MongoDB .local Chicago 2019: MongoDB Atlas Data Lake Technical Deep DiveMongoDB .local Chicago 2019: MongoDB Atlas Data Lake Technical Deep Dive
MongoDB .local Chicago 2019: MongoDB Atlas Data Lake Technical Deep Dive
 
Expanding Retail Frontiers with MongoDB
Expanding Retail Frontiers with MongoDBExpanding Retail Frontiers with MongoDB
Expanding Retail Frontiers with MongoDB
 
Beyond the Basics 3: Introduction to the MongoDB BI Connector
Beyond the Basics 3: Introduction to the MongoDB BI ConnectorBeyond the Basics 3: Introduction to the MongoDB BI Connector
Beyond the Basics 3: Introduction to the MongoDB BI Connector
 
MongoDB Days Silicon Valley: Jumpstart: The Right and Wrong Use Cases for Mon...
MongoDB Days Silicon Valley: Jumpstart: The Right and Wrong Use Cases for Mon...MongoDB Days Silicon Valley: Jumpstart: The Right and Wrong Use Cases for Mon...
MongoDB Days Silicon Valley: Jumpstart: The Right and Wrong Use Cases for Mon...
 
Addressing Your Backup Needs Using Ops Manager and Atlas
Addressing Your Backup Needs Using Ops Manager and AtlasAddressing Your Backup Needs Using Ops Manager and Atlas
Addressing Your Backup Needs Using Ops Manager and Atlas
 
MongoDB .local Toronto 2019: MongoDB Atlas Jumpstart
MongoDB .local Toronto 2019: MongoDB Atlas JumpstartMongoDB .local Toronto 2019: MongoDB Atlas Jumpstart
MongoDB .local Toronto 2019: MongoDB Atlas Jumpstart
 
Webinar: Expanding Retail Frontiers with MongoDB
 Webinar: Expanding Retail Frontiers with MongoDB Webinar: Expanding Retail Frontiers with MongoDB
Webinar: Expanding Retail Frontiers with MongoDB
 
Webinar: Introducing the MongoDB Connector for BI 2.0 with Tableau
Webinar: Introducing the MongoDB Connector for BI 2.0 with TableauWebinar: Introducing the MongoDB Connector for BI 2.0 with Tableau
Webinar: Introducing the MongoDB Connector for BI 2.0 with Tableau
 
Online MongoDB Training by Easylearning.guru
Online MongoDB Training by Easylearning.guruOnline MongoDB Training by Easylearning.guru
Online MongoDB Training by Easylearning.guru
 

Viewers also liked

Fraser Graham Killer Robots
Fraser Graham Killer RobotsFraser Graham Killer Robots
Fraser Graham Killer RobotsArtem Kovardin
 
High Performance Systems in Go - GopherCon 2014
High Performance Systems in Go - GopherCon 2014High Performance Systems in Go - GopherCon 2014
High Performance Systems in Go - GopherCon 2014Derek Collison
 
Best practices-for-production-environments
Best practices-for-production-environmentsBest practices-for-production-environments
Best practices-for-production-environmentsArtem Kovardin
 
A Channel Compendium
A Channel CompendiumA Channel Compendium
A Channel CompendiumCloudflare
 
SDL Media Manager Use Cases
SDL Media Manager Use CasesSDL Media Manager Use Cases
SDL Media Manager Use Caseswmaagdenberg
 
Garbage collector и управление памятью в Go
Garbage collector и управление памятью в GoGarbage collector и управление памятью в Go
Garbage collector и управление памятью в GoArtem Kovardin
 
C-spirit reborn: why Go was bound to be created
C-spirit reborn: why Go was bound to be createdC-spirit reborn: why Go was bound to be created
C-spirit reborn: why Go was bound to be createdArtem Kovardin
 

Viewers also liked (10)

Fraser Graham Killer Robots
Fraser Graham Killer RobotsFraser Graham Killer Robots
Fraser Graham Killer Robots
 
Go database/sql
Go database/sqlGo database/sql
Go database/sql
 
High Performance Systems in Go - GopherCon 2014
High Performance Systems in Go - GopherCon 2014High Performance Systems in Go - GopherCon 2014
High Performance Systems in Go - GopherCon 2014
 
Best practices-for-production-environments
Best practices-for-production-environmentsBest practices-for-production-environments
Best practices-for-production-environments
 
A Channel Compendium
A Channel CompendiumA Channel Compendium
A Channel Compendium
 
SDL Media Manager Use Cases
SDL Media Manager Use CasesSDL Media Manager Use Cases
SDL Media Manager Use Cases
 
Garbage collector и управление памятью в Go
Garbage collector и управление памятью в GoGarbage collector и управление памятью в Go
Garbage collector и управление памятью в Go
 
Anthony Starks - deck
Anthony Starks - deckAnthony Starks - deck
Anthony Starks - deck
 
C-spirit reborn: why Go was bound to be created
C-spirit reborn: why Go was bound to be createdC-spirit reborn: why Go was bound to be created
C-spirit reborn: why Go was bound to be created
 
OOP в Go
OOP в GoOOP в Go
OOP в Go
 

Similar to Building A Relevancy Engine Using MongoDB and Go

MongoDB Breakfast Milan - Mainframe Offloading Strategies
MongoDB Breakfast Milan -  Mainframe Offloading StrategiesMongoDB Breakfast Milan -  Mainframe Offloading Strategies
MongoDB Breakfast Milan - Mainframe Offloading StrategiesMongoDB
 
Novedades de MongoDB 3.6
Novedades de MongoDB 3.6Novedades de MongoDB 3.6
Novedades de MongoDB 3.6MongoDB
 
When to Use MongoDB...and When You Should Not...
When to Use MongoDB...and When You Should Not...When to Use MongoDB...and When You Should Not...
When to Use MongoDB...and When You Should Not...MongoDB
 
MongoDB Tick Data Presentation
MongoDB Tick Data PresentationMongoDB Tick Data Presentation
MongoDB Tick Data PresentationMongoDB
 
Overcoming Today's Data Challenges with MongoDB
Overcoming Today's Data Challenges with MongoDBOvercoming Today's Data Challenges with MongoDB
Overcoming Today's Data Challenges with MongoDBMongoDB
 
Enabling Telco to Build and Run Modern Applications
Enabling Telco to Build and Run Modern Applications Enabling Telco to Build and Run Modern Applications
Enabling Telco to Build and Run Modern Applications Tugdual Grall
 
Overcoming Today's Data Challenges with MongoDB
Overcoming Today's Data Challenges with MongoDBOvercoming Today's Data Challenges with MongoDB
Overcoming Today's Data Challenges with MongoDBMongoDB
 
3 scenarios when to use MongoDB!
3 scenarios when to use MongoDB!3 scenarios when to use MongoDB!
3 scenarios when to use MongoDB!Edureka!
 
apidays Paris 2022 - Sustainable API Green Score, Yannick Tremblais (Groupe R...
apidays Paris 2022 - Sustainable API Green Score, Yannick Tremblais (Groupe R...apidays Paris 2022 - Sustainable API Green Score, Yannick Tremblais (Groupe R...
apidays Paris 2022 - Sustainable API Green Score, Yannick Tremblais (Groupe R...apidays
 
Data Treatment MongoDB
Data Treatment MongoDBData Treatment MongoDB
Data Treatment MongoDBNorberto Leite
 
Accelerating a Path to Digital With a Cloud Data Strategy
Accelerating a Path to Digital With a Cloud Data StrategyAccelerating a Path to Digital With a Cloud Data Strategy
Accelerating a Path to Digital With a Cloud Data StrategyMongoDB
 
MongoDB on Financial Services Sector
MongoDB on Financial Services SectorMongoDB on Financial Services Sector
MongoDB on Financial Services SectorNorberto Leite
 
Unlocking Operational Intelligence from the Data Lake
Unlocking Operational Intelligence from the Data LakeUnlocking Operational Intelligence from the Data Lake
Unlocking Operational Intelligence from the Data LakeMongoDB
 
Enabling digital transformation api ecosystems and data virtualization
Enabling digital transformation   api ecosystems and data virtualizationEnabling digital transformation   api ecosystems and data virtualization
Enabling digital transformation api ecosystems and data virtualizationDenodo
 
Webinar: Faster Big Data Analytics with MongoDB
Webinar: Faster Big Data Analytics with MongoDBWebinar: Faster Big Data Analytics with MongoDB
Webinar: Faster Big Data Analytics with MongoDBMongoDB
 
When to Use MongoDB
When to Use MongoDBWhen to Use MongoDB
When to Use MongoDBMongoDB
 
Webinar: How Partners Can Benefit from our New Program (EMEA)
Webinar: How Partners Can Benefit from our New Program (EMEA)Webinar: How Partners Can Benefit from our New Program (EMEA)
Webinar: How Partners Can Benefit from our New Program (EMEA)MongoDB
 
MongoDB SoCal 2020: Migrate Anything* to MongoDB Atlas
MongoDB SoCal 2020: Migrate Anything* to MongoDB AtlasMongoDB SoCal 2020: Migrate Anything* to MongoDB Atlas
MongoDB SoCal 2020: Migrate Anything* to MongoDB AtlasMongoDB
 

Similar to Building A Relevancy Engine Using MongoDB and Go (20)

Dataweek-Talk-2014
Dataweek-Talk-2014Dataweek-Talk-2014
Dataweek-Talk-2014
 
MongoDB Breakfast Milan - Mainframe Offloading Strategies
MongoDB Breakfast Milan -  Mainframe Offloading StrategiesMongoDB Breakfast Milan -  Mainframe Offloading Strategies
MongoDB Breakfast Milan - Mainframe Offloading Strategies
 
Novedades de MongoDB 3.6
Novedades de MongoDB 3.6Novedades de MongoDB 3.6
Novedades de MongoDB 3.6
 
When to Use MongoDB...and When You Should Not...
When to Use MongoDB...and When You Should Not...When to Use MongoDB...and When You Should Not...
When to Use MongoDB...and When You Should Not...
 
MongoDB Tick Data Presentation
MongoDB Tick Data PresentationMongoDB Tick Data Presentation
MongoDB Tick Data Presentation
 
Overcoming Today's Data Challenges with MongoDB
Overcoming Today's Data Challenges with MongoDBOvercoming Today's Data Challenges with MongoDB
Overcoming Today's Data Challenges with MongoDB
 
Enabling Telco to Build and Run Modern Applications
Enabling Telco to Build and Run Modern Applications Enabling Telco to Build and Run Modern Applications
Enabling Telco to Build and Run Modern Applications
 
Overcoming Today's Data Challenges with MongoDB
Overcoming Today's Data Challenges with MongoDBOvercoming Today's Data Challenges with MongoDB
Overcoming Today's Data Challenges with MongoDB
 
3 scenarios when to use MongoDB!
3 scenarios when to use MongoDB!3 scenarios when to use MongoDB!
3 scenarios when to use MongoDB!
 
apidays Paris 2022 - Sustainable API Green Score, Yannick Tremblais (Groupe R...
apidays Paris 2022 - Sustainable API Green Score, Yannick Tremblais (Groupe R...apidays Paris 2022 - Sustainable API Green Score, Yannick Tremblais (Groupe R...
apidays Paris 2022 - Sustainable API Green Score, Yannick Tremblais (Groupe R...
 
Data Treatment MongoDB
Data Treatment MongoDBData Treatment MongoDB
Data Treatment MongoDB
 
Accelerating a Path to Digital With a Cloud Data Strategy
Accelerating a Path to Digital With a Cloud Data StrategyAccelerating a Path to Digital With a Cloud Data Strategy
Accelerating a Path to Digital With a Cloud Data Strategy
 
MongoDB on Financial Services Sector
MongoDB on Financial Services SectorMongoDB on Financial Services Sector
MongoDB on Financial Services Sector
 
Unlocking Operational Intelligence from the Data Lake
Unlocking Operational Intelligence from the Data LakeUnlocking Operational Intelligence from the Data Lake
Unlocking Operational Intelligence from the Data Lake
 
Enabling digital transformation api ecosystems and data virtualization
Enabling digital transformation   api ecosystems and data virtualizationEnabling digital transformation   api ecosystems and data virtualization
Enabling digital transformation api ecosystems and data virtualization
 
Webinar: Faster Big Data Analytics with MongoDB
Webinar: Faster Big Data Analytics with MongoDBWebinar: Faster Big Data Analytics with MongoDB
Webinar: Faster Big Data Analytics with MongoDB
 
When to Use MongoDB
When to Use MongoDBWhen to Use MongoDB
When to Use MongoDB
 
Webinar: How Partners Can Benefit from our New Program (EMEA)
Webinar: How Partners Can Benefit from our New Program (EMEA)Webinar: How Partners Can Benefit from our New Program (EMEA)
Webinar: How Partners Can Benefit from our New Program (EMEA)
 
MongoDB SoCal 2020: Migrate Anything* to MongoDB Atlas
MongoDB SoCal 2020: Migrate Anything* to MongoDB AtlasMongoDB SoCal 2020: Migrate Anything* to MongoDB Atlas
MongoDB SoCal 2020: Migrate Anything* to MongoDB Atlas
 
Serverless_with_MongoDB
Serverless_with_MongoDBServerless_with_MongoDB
Serverless_with_MongoDB
 

Recently uploaded

From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Allon Mureinik
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityPrincipled Technologies
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Paola De la Torre
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhisoniya singh
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 3652toLead Limited
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersThousandEyes
 
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...gurkirankumar98700
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 

Recently uploaded (20)

From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
 
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 

Building A Relevancy Engine Using MongoDB and Go

  • 1.
  • 3. BUSINESS PROBLEM Database Application Data Offer Data User Data Online / Coupons Credit Card Advice Daily Deals Registration Social Financial Impressions / Clicks Alerts Budget Transactions Logins Navigation Events Many applications have lots of great actionable data on users. How can applications use that data to provide users offers, advice and help?
  • 4. • Dynamic Feed Management • Add new offer feeds, advice or help at runtime. • No builds required to add new feeds. • Dynamic Rule Management • Add, edit and execute rules at runtime. • Write rules against the actionable data that targets users. • Have all the user and application data be available for writing rules. • No builds required to add new rules. BUSINESS PROBLEM Our Answer Go Language MongoDB Mgo/Beego If we had a system that could do the following, we would have something:
  • 5. http://docs.mongodb.org/manual/core/data-modeling-introduction/ WHY MONGODB - DYNAMIC FEED MANAGEMENT Data is stored in “Collections” as individual documents. Relationships can be created by using references. This is in step with how relational database systems store data. MongoDB’s schemaless database provides great flexibility.
  • 6. http://docs.mongodb.org/manual/core/data-modeling-introduction/ WHY MONGODB - DYNAMIC FEED MANAGEMENT Embedding data allows the greatest flexibility and eliminates the need for “joins” by keeping all the data organized in a single document. This allows for dynamic feed management.
  • 7. Scheduler Checks the schedules and posts inventory jobs in queue. Processor Performs the data retrieval and insertion. Two Go programs perform all the feed management work WHY GO - DYNAMIC FEED MANAGEMENT The Feed System Is Driven By Data Go supports cross platform application development. This allows for building programs that can be used in high-scale cloud platforms like Iron.IO.
  • 8. • Write Rules that Can be Updated and Applied at Runtime • Pass Variables to Filter and Pin Point Relevance • Use Data Aggregation Techniques to Filter and Group Data • Build Tests Against Aggregated Datasets • Build Tests Against Multiple Aggregated Datasets • Publish Data from Offer and Internal Feeds DYNAMIC RULE MANAGEMENT Our Answer Go Language MongoDB Mgo/Beego Building rules is a core piece of the system. If we had a rule system that could do the following, we would have something.
  • 9. http://docs.mongodb.org/manual/core/aggregation-pipeline/ WHY MONGODB - DYNAMIC RULE MANAGEMENT We can leverage the aggregation pipeline for writing rules.
  • 10. VARIABLE RULES - DYNAMIC RULE MANAGEMENT Pass Variables to Filter & Pin Point Relevance • Substitute userId for this value in any rule being applied. • Substitute screen-tab for this value in any rule being applied. For Variable Substitution • When the user is on the user tab. • When the budget item is for entertainment expenses. • When the transaction record is a grocery transaction. Rule Type: variable { "userId" : "12345", "screen-tab" : "user" } Variable rules take variable data that is passed into the rule from the application. Variables are similar to query string parameters on an URL. They can be tested for specific values.
  • 11. PIPELINE RULES - DYNAMIC RULE MANAGEMENT • When the user is younger than 40 years old. • When the user is single. • When the user has a Gmail account. User Demographics : (User Collection) Rule Type: pipeline { "$match" : { "user_id" : "#userId#" }} { "$match" : { "age" : { "$lt" : 40}}} Pipeline rules are run through the MongoDB aggregation pipeline. Datasets can be checked for specific conditions or saved for use in later Go Template rules.
  • 12. PIPELINE RULES - DYNAMIC RULE MANAGEMENT • When the user has spent more than $20 this month on movies. • When the user has over 5 transactions for less than $5 this week. • When the user has spent over $5,000 in the past 30 days. User Transactions : (User_Transactions Collection) Rule Type: pipeline { "$match" : { "user_id" : "#userId#", "category" : "movies" }} . { "$group" : { "_id" : { "category" : "$category" }, "amount" : { "$sum" : "$amount" }}} . { "$match" : { "amount" : { "$gt" : 20.00}}} . Pipeline rules are run through the MongoDB aggregation pipeline. Datasets can be checked for specific conditions or saved for use in later Go Template rules.
  • 13. GO TEMPLATE RULES - DYNAMIC RULE MANAGEMENT • When the user spends over $100 on groceries and entertainment. • When the user has a G+ account and is over 40. • When the user is married and spent over $1,000 last week. Compare Multiple Datasets Rule Type: template {{$movies := index .Movies "amount"}} . {{$dining := index .Dining "amount"}} . {{if gt $dining $movies}} VALID {{end}} . Template rules are used to compare multiple datasets generated by aggregation pipeline queries. Multiple datasets can be compared and checked for specific conditions.
  • 14. • Go Language • Systems programming language • Compiles to binary code for target OS/Architectures • Cross compile on many operating systems • Access to scalable cloud computing environments • MGO driver for Go provides excellent MongoDB support • MongoDB • Scalability and redundancy out of the box • Great MongoDB hosting providers • Schemaless database that provides great flexibility • Aggregation pipeline to build rules and datasets • Can search against text with good performance • Beego Web Framework • MVC based web framework • Enough framework to be productive without being handcuffed • Sits on top of the Go HTTP package • Excellent web service and view support WHY GO, MONGODB and BEEGO - SOLUTION By combining the data flexibility and aggregation capabilities of MongoDB with the Go language and template framework, we have a scalable, redundant and feature rich solution.
  • 15.
  • 16. • Go, MGO, MongoDB and Beego are powerful technologies. • Create data driven and dynamic systems with Go and MongoDB. • Leverage powerful cloud systems like Iron.IO and Heroku. • The MongoDB aggregation pipeline is fast and powerful. • Go templates provide a seamless way to process datasets. • These technologies can be used to create highly scalable systems. CONCLUSION MongoDB and Go are technologies that work incredibly well together. The communities for both technologies are vibrant and expanding. Now is the time to consider these technologies.