SlideShare a Scribd company logo
1 of 41
Couchbase at Symantec
Gaurav Chandna
Sr Principal Software Engineer
About Me
Gaurav Chandna
At Symantec for 11 years.
Worked at AntiSpyware,
Behavioral malware, Norton and
now building platforms.
Engineering Manager previously
@xyxxy
2
Agenda
1 Introduction
2 Time series
3 Relational
4 Q&A
Copyright © 2014 Symantec Corporation
3
Introduction
Copyright © 2014 Symantec Corporation 4
Environment
• Service Oriented Architecture
• Message Oriented Middleware
• Multi-tenant
• Multiple data centers
Copyright © 2014 Symantec Corporation
5
Message Oriented Architecture
Copyright © 2014 Symantec Corporation
6
Replication between data centers
Copyright © 2014 Symantec Corporation
7
Time Series Data
Copyright © 2014 Symantec Corporation 8
Copyright © 2014 Symantec Corporation
9
Copyright © 2014 Symantec Corporation
10
Message
Broker
Service
ElasticSearch
Query &
Visualization
Copyright © 2014 Symantec Corporation
11
Quick side bar: Elasticsearch
Copyright © 2014 Symantec Corporation
12
Elasticsearch
Copyright © 2014 Symantec Corporation
13
• Document oriented search engine
• Based on Apache Lucene project
• JSON based
• Distributed
• Scale out
• Multi-tenancy
• RESTful
Elasticsearch
Copyright © 2014 Symantec Corporation
14
• Structured search
• Unstructured search
• Analytics
• Combine
All good?
Copyright © 2014 Symantec Corporation
15
Well… kind of
• Elasticsearch doesn’t recommend using it as data store
– Due to write coalescing
• Limited support for replication between data centers
– Especially across unreliable networks
Copyright © 2014 Symantec Corporation
16
New pipeline
Message
Broker
Service
Couchbase
ElasticSearch
Query &
Visualization
Copyright © 2014 Symantec Corporation
17
Cross data center replication
Copyright © 2014 Symantec Corporation
18
Used to replicate Elasticsearch between data centers
Copyright © 2014 Symantec Corporation
19
It’s all good!
Copyright © 2014 Symantec Corporation
20
Just one more thing…
• Document stored on Couchbase
After X days, the document gets
purged
• XDCR will purge in Elasticsearch
also
• Forked the Couchbase –
Elasticsearch connector to disable
deletion
• Looking to integrate those changes
to Couchbase for community use
Copyright © 2014 Symantec Corporation
21
And we are finally good!
Copyright © 2014 Symantec Corporation
22
Data with relationships
Copyright © 2014 Symantec Corporation 23
Relationships are everywhere
Copyright © 2014 Symantec Corporation
24
Engineering
Gaurav
iPhone Mac
John
PC Android
Right here…
Copyright © 2014 Symantec Corporation
25
Meetup
@Symantec
Gaurav
iPhone
Joshua
Android
In abstract terms
A
B
C D
C’
Y
Copyright © 2014 Symantec Corporation
26
You get information through queries
• Get all members of a particular group
• All groups ordered by number of people in the group
• List all members of a group, order by location
• List all groups where users have iPhone, ordered by total
number of people
• And so on..
Copyright © 2014 Symantec Corporation
27
Engineering considerations
• Ability to add new types
– Don’t make big changes when iWatch came out
• Ability to extend the types
• Add new relationships quickly
Copyright © 2014 Symantec Corporation
28
Table stakes
• Cross data center replication
• Performance
• Horizontal scaling
• Searching
• Querying capability
Copyright © 2014 Symantec Corporation
29
Initial implementation
• {
• ”type": ”person”,
• "name": ”Gaurav",
• "modified": "2015-04-
17T00:39:45.468Z",
• "_id": "79014cbb-69ce-4459-8f4a-
6edaf4b8313a",
• // other information
• }
• {
• ”type": ”department”,
• "name": ”Engineering",
• "_id": "79014cbb-69ce-4459-8f4a-
6edaf4b8313a",
• // other information
• }
Copyright © 2014 Symantec Corporation
30
Initial version
• Store different objects with types
as documents
• Create views in Couchbase
– Type
– Relationships between types
– Specialize on special types
• Ensure persistence during
operations
• Works well… to a point
Copyright © 2014 Symantec Corporation
31
So we needed a next generation
Copyright © 2014 Symantec Corporation
32
Second iteration
• {
• "_id":"Well_crafted_id”
• // Other meta information
• // Other associated information
• }
• Relationship information embedded
in the _id
• Takes advantage of key access to
document by id
• Can still build views on these
documents
• Does require more hand crafting to
get better performance
• Maintain flexibility
• Need to play around with different
APIs to see which work best for use
case
• More generic code
Copyright © 2014 Symantec Corporation
33
What about search?
Copyright © 2014 Symantec Corporation
34
Use Elasticsearch for search!
• Couchbase is primary data store
• Use Couchbase XDCR for one
direction replication
– Like time series data
– But don’t disable deletes
Copyright © 2014 Symantec Corporation
35
Message
Queue
Service
Couchbase
Elasticsearch
But…
• Elasticsearch prefers types to be
well defined for indexing
• Code is generic for extensibility
• Couchbase – Elasticsearch plugin
only supports 1 configuration
• Different services have different
needs
Copyright © 2014 Symantec Corporation
36
• More modifications to the
Elasticsearch – Couchbase
connector
• Custom code to deduce types for
compatibility with Elasticsearch
• Per bucket configurations so
deletes for time series but not for
relational data
• Keep dynamically defined types
and the code generic
Copyright © 2014 Symantec Corporation
37
Final thoughts
• Data modeling is extremely
important
• JSON Parser – experiment for your
use case
• Experiment with the different API
options for your needs
• Don’t be afraid to customize for
your needs!
• Polyglot persistence
– Matt’s presentation
Copyright © 2014 Symantec Corporation
38
Thank you!
Copyright © 2014 Symantec Corporation. All rights reserved. Symantec and the Symantec Logo are trademarks or registered trademarks of Symantec Corporation or its
affiliates in the U.S. and other countries. Other names may be trademarks of their respective owners.
This document is provided for informational purposes only and is not intended as advertising. All warranties relating to the information in this document, either express or
implied, are disclaimed to the maximum extent allowed by law. The information in this document is subject to change without notice.
Gaurav Chandna
Gaurav_chandna@symantec.com
Twitter: @xyxxy
Thank you!
Copyright © 2014 Symantec Corporation. All rights reserved. Symantec and the Symantec Logo are trademarks or registered trademarks of Symantec Corporation or its
affiliates in the U.S. and other countries. Other names may be trademarks of their respective owners.
This document is provided for informational purposes only and is not intended as advertising. All warranties relating to the information in this document, either express or
implied, are disclaimed to the maximum extent allowed by law. The information in this document is subject to change without notice.
We are hiring
www.symantec.com/careers
&Q A
Copyright © 2014 Symantec Corporation 41

More Related Content

What's hot

Building a document e-signing workflow with Azure Durable Functions
Building a document e-signing workflow with Azure Durable FunctionsBuilding a document e-signing workflow with Azure Durable Functions
Building a document e-signing workflow with Azure Durable FunctionsJoonas Westlin
 
Performance Optimization of Cloud Based Applications by Peter Smith, ACL
Performance Optimization of Cloud Based Applications by Peter Smith, ACLPerformance Optimization of Cloud Based Applications by Peter Smith, ACL
Performance Optimization of Cloud Based Applications by Peter Smith, ACLTriNimbus
 
8 cloud design patterns you ought to know - Update Conference 2018
8 cloud design patterns you ought to know - Update Conference 20188 cloud design patterns you ought to know - Update Conference 2018
8 cloud design patterns you ought to know - Update Conference 2018Taswar Bhatti
 
Azure Key Vault - Getting Started
Azure Key Vault - Getting StartedAzure Key Vault - Getting Started
Azure Key Vault - Getting StartedTaswar Bhatti
 
TechDays Finland 2020: Best practices of securing web applications running on...
TechDays Finland 2020: Best practices of securing web applications running on...TechDays Finland 2020: Best practices of securing web applications running on...
TechDays Finland 2020: Best practices of securing web applications running on...Karl Ots
 
Onion Architecture with S#arp
Onion Architecture with S#arpOnion Architecture with S#arp
Onion Architecture with S#arpGary Pedretti
 
Azure Key Vault with a PaaS Architecture and ARM Template Deployment
Azure Key Vault with a PaaS Architecture and ARM Template DeploymentAzure Key Vault with a PaaS Architecture and ARM Template Deployment
Azure Key Vault with a PaaS Architecture and ARM Template DeploymentRoy Kim
 
Making Sense of Hypermedia APIs – Hype or Reality?
Making Sense of Hypermedia APIs – Hype or Reality?Making Sense of Hypermedia APIs – Hype or Reality?
Making Sense of Hypermedia APIs – Hype or Reality?Akana
 
API Description Languages: Which is the Right One for Me?
API Description Languages: Which is the Right One for Me?API Description Languages: Which is the Right One for Me?
API Description Languages: Which is the Right One for Me?Akana
 
The Future of Hadoop Security - Hadoop Summit 2014
The Future of Hadoop Security - Hadoop Summit 2014The Future of Hadoop Security - Hadoop Summit 2014
The Future of Hadoop Security - Hadoop Summit 2014Cloudera, Inc.
 
Global azure virtual 2021 - Azure Lighthouse
Global azure virtual 2021 - Azure LighthouseGlobal azure virtual 2021 - Azure Lighthouse
Global azure virtual 2021 - Azure LighthouseIvo Andreev
 
Introduction to Azure Blueprints
Introduction to Azure BlueprintsIntroduction to Azure Blueprints
Introduction to Azure BlueprintsCheah Eng Soon
 
Programming with Azure Active Directory
Programming with Azure Active DirectoryProgramming with Azure Active Directory
Programming with Azure Active DirectoryJoonas Westlin
 
Azure Saturday: Security + DevOps + Azure = Awesomeness
Azure Saturday: Security + DevOps + Azure = AwesomenessAzure Saturday: Security + DevOps + Azure = Awesomeness
Azure Saturday: Security + DevOps + Azure = AwesomenessKarl Ots
 
Azure Networking - The First Technical Challenge
Azure Networking  - The First Technical ChallengeAzure Networking  - The First Technical Challenge
Azure Networking - The First Technical ChallengeAidan Finn
 
I'm in your cloud... reading everyone's email. Hacking Azure AD via Active Di...
I'm in your cloud... reading everyone's email. Hacking Azure AD via Active Di...I'm in your cloud... reading everyone's email. Hacking Azure AD via Active Di...
I'm in your cloud... reading everyone's email. Hacking Azure AD via Active Di...DirkjanMollema
 
Techorama Belgium 2019 - Building an Azure Governance model for the Enterprise
Techorama Belgium 2019 - Building an Azure Governance model for the EnterpriseTechorama Belgium 2019 - Building an Azure Governance model for the Enterprise
Techorama Belgium 2019 - Building an Azure Governance model for the EnterpriseKarl Ots
 
[DevDay 2016] OpenStack and approaches for new users - Speaker: Chi Le – Head...
[DevDay 2016] OpenStack and approaches for new users - Speaker: Chi Le – Head...[DevDay 2016] OpenStack and approaches for new users - Speaker: Chi Le – Head...
[DevDay 2016] OpenStack and approaches for new users - Speaker: Chi Le – Head...DevDay.org
 

What's hot (20)

Azure signalr service
Azure signalr serviceAzure signalr service
Azure signalr service
 
Building a document e-signing workflow with Azure Durable Functions
Building a document e-signing workflow with Azure Durable FunctionsBuilding a document e-signing workflow with Azure Durable Functions
Building a document e-signing workflow with Azure Durable Functions
 
Azure governance
Azure governanceAzure governance
Azure governance
 
Performance Optimization of Cloud Based Applications by Peter Smith, ACL
Performance Optimization of Cloud Based Applications by Peter Smith, ACLPerformance Optimization of Cloud Based Applications by Peter Smith, ACL
Performance Optimization of Cloud Based Applications by Peter Smith, ACL
 
8 cloud design patterns you ought to know - Update Conference 2018
8 cloud design patterns you ought to know - Update Conference 20188 cloud design patterns you ought to know - Update Conference 2018
8 cloud design patterns you ought to know - Update Conference 2018
 
Azure Key Vault - Getting Started
Azure Key Vault - Getting StartedAzure Key Vault - Getting Started
Azure Key Vault - Getting Started
 
TechDays Finland 2020: Best practices of securing web applications running on...
TechDays Finland 2020: Best practices of securing web applications running on...TechDays Finland 2020: Best practices of securing web applications running on...
TechDays Finland 2020: Best practices of securing web applications running on...
 
Onion Architecture with S#arp
Onion Architecture with S#arpOnion Architecture with S#arp
Onion Architecture with S#arp
 
Azure Key Vault with a PaaS Architecture and ARM Template Deployment
Azure Key Vault with a PaaS Architecture and ARM Template DeploymentAzure Key Vault with a PaaS Architecture and ARM Template Deployment
Azure Key Vault with a PaaS Architecture and ARM Template Deployment
 
Making Sense of Hypermedia APIs – Hype or Reality?
Making Sense of Hypermedia APIs – Hype or Reality?Making Sense of Hypermedia APIs – Hype or Reality?
Making Sense of Hypermedia APIs – Hype or Reality?
 
API Description Languages: Which is the Right One for Me?
API Description Languages: Which is the Right One for Me?API Description Languages: Which is the Right One for Me?
API Description Languages: Which is the Right One for Me?
 
The Future of Hadoop Security - Hadoop Summit 2014
The Future of Hadoop Security - Hadoop Summit 2014The Future of Hadoop Security - Hadoop Summit 2014
The Future of Hadoop Security - Hadoop Summit 2014
 
Global azure virtual 2021 - Azure Lighthouse
Global azure virtual 2021 - Azure LighthouseGlobal azure virtual 2021 - Azure Lighthouse
Global azure virtual 2021 - Azure Lighthouse
 
Introduction to Azure Blueprints
Introduction to Azure BlueprintsIntroduction to Azure Blueprints
Introduction to Azure Blueprints
 
Programming with Azure Active Directory
Programming with Azure Active DirectoryProgramming with Azure Active Directory
Programming with Azure Active Directory
 
Azure Saturday: Security + DevOps + Azure = Awesomeness
Azure Saturday: Security + DevOps + Azure = AwesomenessAzure Saturday: Security + DevOps + Azure = Awesomeness
Azure Saturday: Security + DevOps + Azure = Awesomeness
 
Azure Networking - The First Technical Challenge
Azure Networking  - The First Technical ChallengeAzure Networking  - The First Technical Challenge
Azure Networking - The First Technical Challenge
 
I'm in your cloud... reading everyone's email. Hacking Azure AD via Active Di...
I'm in your cloud... reading everyone's email. Hacking Azure AD via Active Di...I'm in your cloud... reading everyone's email. Hacking Azure AD via Active Di...
I'm in your cloud... reading everyone's email. Hacking Azure AD via Active Di...
 
Techorama Belgium 2019 - Building an Azure Governance model for the Enterprise
Techorama Belgium 2019 - Building an Azure Governance model for the EnterpriseTechorama Belgium 2019 - Building an Azure Governance model for the Enterprise
Techorama Belgium 2019 - Building an Azure Governance model for the Enterprise
 
[DevDay 2016] OpenStack and approaches for new users - Speaker: Chi Le – Head...
[DevDay 2016] OpenStack and approaches for new users - Speaker: Chi Le – Head...[DevDay 2016] OpenStack and approaches for new users - Speaker: Chi Le – Head...
[DevDay 2016] OpenStack and approaches for new users - Speaker: Chi Le – Head...
 

Similar to Couchbase usage at Symantec

Big Data Fundamentals 6.6.18
Big Data Fundamentals 6.6.18Big Data Fundamentals 6.6.18
Big Data Fundamentals 6.6.18Cloudera, Inc.
 
Building A Business-Facing Mobile Developer Community
Building A Business-Facing Mobile Developer CommunityBuilding A Business-Facing Mobile Developer Community
Building A Business-Facing Mobile Developer CommunityProgrammableWeb
 
A Reference Architecture to Enable Visibility and Traceability across the Ent...
A Reference Architecture to Enable Visibility and Traceability across the Ent...A Reference Architecture to Enable Visibility and Traceability across the Ent...
A Reference Architecture to Enable Visibility and Traceability across the Ent...CollabNet
 
Hybrid Analysis Mapping: Making Security and Development Tools Play Nice Toge...
Hybrid Analysis Mapping: Making Security and Development Tools Play Nice Toge...Hybrid Analysis Mapping: Making Security and Development Tools Play Nice Toge...
Hybrid Analysis Mapping: Making Security and Development Tools Play Nice Toge...Denim Group
 
Caching Patterns
Caching PatternsCaching Patterns
Caching Patternstomi vanek
 
Web App Security Presentation by Ryan Holland - 05-31-2017
Web App Security Presentation by Ryan Holland - 05-31-2017Web App Security Presentation by Ryan Holland - 05-31-2017
Web App Security Presentation by Ryan Holland - 05-31-2017TriNimbus
 
Introducing the Entity Framework
Introducing the Entity FrameworkIntroducing the Entity Framework
Introducing the Entity FrameworkLearnNowOnline
 
Migration from SQL to MongoDB - A Case Study at TheKnot.com
Migration from SQL to MongoDB - A Case Study at TheKnot.com Migration from SQL to MongoDB - A Case Study at TheKnot.com
Migration from SQL to MongoDB - A Case Study at TheKnot.com MongoDB
 
Application patterns
Application patternsApplication patterns
Application patternstomi vanek
 
A proven path for migrating from clearcase to git and or subversion
A proven path for migrating from clearcase to git and or subversionA proven path for migrating from clearcase to git and or subversion
A proven path for migrating from clearcase to git and or subversionCollabNet
 
Cassandra Summit 2014: Internet of Complex Things Analytics with Apache Cassa...
Cassandra Summit 2014: Internet of Complex Things Analytics with Apache Cassa...Cassandra Summit 2014: Internet of Complex Things Analytics with Apache Cassa...
Cassandra Summit 2014: Internet of Complex Things Analytics with Apache Cassa...DataStax Academy
 
AppSphere 15 - How AppDynamics is Shaking up the Synthetic Monitoring Product...
AppSphere 15 - How AppDynamics is Shaking up the Synthetic Monitoring Product...AppSphere 15 - How AppDynamics is Shaking up the Synthetic Monitoring Product...
AppSphere 15 - How AppDynamics is Shaking up the Synthetic Monitoring Product...AppDynamics
 
Cloud-Native-Data with Cornelia Davis
Cloud-Native-Data with Cornelia DavisCloud-Native-Data with Cornelia Davis
Cloud-Native-Data with Cornelia DavisVMware Tanzu
 
Creating hybrid cloud openstack + public cloud
Creating hybrid cloud   openstack + public cloudCreating hybrid cloud   openstack + public cloud
Creating hybrid cloud openstack + public cloudMiguel Zuniga
 
Enterprise CI as-a-Service using Jenkins
Enterprise CI as-a-Service using JenkinsEnterprise CI as-a-Service using Jenkins
Enterprise CI as-a-Service using JenkinsCollabNet
 
Single Source of Truth for Network Automation
Single Source of Truth for Network AutomationSingle Source of Truth for Network Automation
Single Source of Truth for Network AutomationAndy Davidson
 
NetIQ identity powered security
NetIQ identity powered security   NetIQ identity powered security
NetIQ identity powered security Finceptum Oy
 

Similar to Couchbase usage at Symantec (20)

Big Data Fundamentals 6.6.18
Big Data Fundamentals 6.6.18Big Data Fundamentals 6.6.18
Big Data Fundamentals 6.6.18
 
Big Data Fundamentals
Big Data FundamentalsBig Data Fundamentals
Big Data Fundamentals
 
Building A Business-Facing Mobile Developer Community
Building A Business-Facing Mobile Developer CommunityBuilding A Business-Facing Mobile Developer Community
Building A Business-Facing Mobile Developer Community
 
DevOps: Infrastructure as Code
DevOps: Infrastructure as CodeDevOps: Infrastructure as Code
DevOps: Infrastructure as Code
 
A Reference Architecture to Enable Visibility and Traceability across the Ent...
A Reference Architecture to Enable Visibility and Traceability across the Ent...A Reference Architecture to Enable Visibility and Traceability across the Ent...
A Reference Architecture to Enable Visibility and Traceability across the Ent...
 
Hybrid Analysis Mapping: Making Security and Development Tools Play Nice Toge...
Hybrid Analysis Mapping: Making Security and Development Tools Play Nice Toge...Hybrid Analysis Mapping: Making Security and Development Tools Play Nice Toge...
Hybrid Analysis Mapping: Making Security and Development Tools Play Nice Toge...
 
Caching Patterns
Caching PatternsCaching Patterns
Caching Patterns
 
Web App Security Presentation by Ryan Holland - 05-31-2017
Web App Security Presentation by Ryan Holland - 05-31-2017Web App Security Presentation by Ryan Holland - 05-31-2017
Web App Security Presentation by Ryan Holland - 05-31-2017
 
Introducing the Entity Framework
Introducing the Entity FrameworkIntroducing the Entity Framework
Introducing the Entity Framework
 
Migration from SQL to MongoDB - A Case Study at TheKnot.com
Migration from SQL to MongoDB - A Case Study at TheKnot.com Migration from SQL to MongoDB - A Case Study at TheKnot.com
Migration from SQL to MongoDB - A Case Study at TheKnot.com
 
Application patterns
Application patternsApplication patterns
Application patterns
 
A proven path for migrating from clearcase to git and or subversion
A proven path for migrating from clearcase to git and or subversionA proven path for migrating from clearcase to git and or subversion
A proven path for migrating from clearcase to git and or subversion
 
Cassandra Summit 2014: Internet of Complex Things Analytics with Apache Cassa...
Cassandra Summit 2014: Internet of Complex Things Analytics with Apache Cassa...Cassandra Summit 2014: Internet of Complex Things Analytics with Apache Cassa...
Cassandra Summit 2014: Internet of Complex Things Analytics with Apache Cassa...
 
AppSphere 15 - How AppDynamics is Shaking up the Synthetic Monitoring Product...
AppSphere 15 - How AppDynamics is Shaking up the Synthetic Monitoring Product...AppSphere 15 - How AppDynamics is Shaking up the Synthetic Monitoring Product...
AppSphere 15 - How AppDynamics is Shaking up the Synthetic Monitoring Product...
 
Cloud-native Data
Cloud-native DataCloud-native Data
Cloud-native Data
 
Cloud-Native-Data with Cornelia Davis
Cloud-Native-Data with Cornelia DavisCloud-Native-Data with Cornelia Davis
Cloud-Native-Data with Cornelia Davis
 
Creating hybrid cloud openstack + public cloud
Creating hybrid cloud   openstack + public cloudCreating hybrid cloud   openstack + public cloud
Creating hybrid cloud openstack + public cloud
 
Enterprise CI as-a-Service using Jenkins
Enterprise CI as-a-Service using JenkinsEnterprise CI as-a-Service using Jenkins
Enterprise CI as-a-Service using Jenkins
 
Single Source of Truth for Network Automation
Single Source of Truth for Network AutomationSingle Source of Truth for Network Automation
Single Source of Truth for Network Automation
 
NetIQ identity powered security
NetIQ identity powered security   NetIQ identity powered security
NetIQ identity powered security
 

Recently uploaded

Building on a FAIRly Strong Foundation to Connect Academic Research to Transl...
Building on a FAIRly Strong Foundation to Connect Academic Research to Transl...Building on a FAIRly Strong Foundation to Connect Academic Research to Transl...
Building on a FAIRly Strong Foundation to Connect Academic Research to Transl...Jack DiGiovanna
 
9711147426✨Call In girls Gurgaon Sector 31. SCO 25 escort service
9711147426✨Call In girls Gurgaon Sector 31. SCO 25 escort service9711147426✨Call In girls Gurgaon Sector 31. SCO 25 escort service
9711147426✨Call In girls Gurgaon Sector 31. SCO 25 escort servicejennyeacort
 
Call Us ➥97111√47426🤳Call Girls in Aerocity (Delhi NCR)
Call Us ➥97111√47426🤳Call Girls in Aerocity (Delhi NCR)Call Us ➥97111√47426🤳Call Girls in Aerocity (Delhi NCR)
Call Us ➥97111√47426🤳Call Girls in Aerocity (Delhi NCR)jennyeacort
 
Indian Call Girls in Abu Dhabi O5286O24O8 Call Girls in Abu Dhabi By Independ...
Indian Call Girls in Abu Dhabi O5286O24O8 Call Girls in Abu Dhabi By Independ...Indian Call Girls in Abu Dhabi O5286O24O8 Call Girls in Abu Dhabi By Independ...
Indian Call Girls in Abu Dhabi O5286O24O8 Call Girls in Abu Dhabi By Independ...dajasot375
 
代办国外大学文凭《原版美国UCLA文凭证书》加州大学洛杉矶分校毕业证制作成绩单修改
代办国外大学文凭《原版美国UCLA文凭证书》加州大学洛杉矶分校毕业证制作成绩单修改代办国外大学文凭《原版美国UCLA文凭证书》加州大学洛杉矶分校毕业证制作成绩单修改
代办国外大学文凭《原版美国UCLA文凭证书》加州大学洛杉矶分校毕业证制作成绩单修改atducpo
 
办理学位证纽约大学毕业证(NYU毕业证书)原版一比一
办理学位证纽约大学毕业证(NYU毕业证书)原版一比一办理学位证纽约大学毕业证(NYU毕业证书)原版一比一
办理学位证纽约大学毕业证(NYU毕业证书)原版一比一fhwihughh
 
RA-11058_IRR-COMPRESS Do 198 series of 1998
RA-11058_IRR-COMPRESS Do 198 series of 1998RA-11058_IRR-COMPRESS Do 198 series of 1998
RA-11058_IRR-COMPRESS Do 198 series of 1998YohFuh
 
High Class Call Girls Noida Sector 39 Aarushi 🔝8264348440🔝 Independent Escort...
High Class Call Girls Noida Sector 39 Aarushi 🔝8264348440🔝 Independent Escort...High Class Call Girls Noida Sector 39 Aarushi 🔝8264348440🔝 Independent Escort...
High Class Call Girls Noida Sector 39 Aarushi 🔝8264348440🔝 Independent Escort...soniya singh
 
Saket, (-DELHI )+91-9654467111-(=)CHEAP Call Girls in Escorts Service Saket C...
Saket, (-DELHI )+91-9654467111-(=)CHEAP Call Girls in Escorts Service Saket C...Saket, (-DELHI )+91-9654467111-(=)CHEAP Call Girls in Escorts Service Saket C...
Saket, (-DELHI )+91-9654467111-(=)CHEAP Call Girls in Escorts Service Saket C...Sapana Sha
 
Amazon TQM (2) Amazon TQM (2)Amazon TQM (2).pptx
Amazon TQM (2) Amazon TQM (2)Amazon TQM (2).pptxAmazon TQM (2) Amazon TQM (2)Amazon TQM (2).pptx
Amazon TQM (2) Amazon TQM (2)Amazon TQM (2).pptxAbdelrhman abooda
 
RadioAdProWritingCinderellabyButleri.pdf
RadioAdProWritingCinderellabyButleri.pdfRadioAdProWritingCinderellabyButleri.pdf
RadioAdProWritingCinderellabyButleri.pdfgstagge
 
VIP High Class Call Girls Jamshedpur Anushka 8250192130 Independent Escort Se...
VIP High Class Call Girls Jamshedpur Anushka 8250192130 Independent Escort Se...VIP High Class Call Girls Jamshedpur Anushka 8250192130 Independent Escort Se...
VIP High Class Call Girls Jamshedpur Anushka 8250192130 Independent Escort Se...Suhani Kapoor
 
04242024_CCC TUG_Joins and Relationships
04242024_CCC TUG_Joins and Relationships04242024_CCC TUG_Joins and Relationships
04242024_CCC TUG_Joins and Relationshipsccctableauusergroup
 
Call Girls In Mahipalpur O9654467111 Escorts Service
Call Girls In Mahipalpur O9654467111  Escorts ServiceCall Girls In Mahipalpur O9654467111  Escorts Service
Call Girls In Mahipalpur O9654467111 Escorts ServiceSapana Sha
 
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130Suhani Kapoor
 
Dubai Call Girls Wifey O52&786472 Call Girls Dubai
Dubai Call Girls Wifey O52&786472 Call Girls DubaiDubai Call Girls Wifey O52&786472 Call Girls Dubai
Dubai Call Girls Wifey O52&786472 Call Girls Dubaihf8803863
 
Schema on read is obsolete. Welcome metaprogramming..pdf
Schema on read is obsolete. Welcome metaprogramming..pdfSchema on read is obsolete. Welcome metaprogramming..pdf
Schema on read is obsolete. Welcome metaprogramming..pdfLars Albertsson
 

Recently uploaded (20)

Building on a FAIRly Strong Foundation to Connect Academic Research to Transl...
Building on a FAIRly Strong Foundation to Connect Academic Research to Transl...Building on a FAIRly Strong Foundation to Connect Academic Research to Transl...
Building on a FAIRly Strong Foundation to Connect Academic Research to Transl...
 
9711147426✨Call In girls Gurgaon Sector 31. SCO 25 escort service
9711147426✨Call In girls Gurgaon Sector 31. SCO 25 escort service9711147426✨Call In girls Gurgaon Sector 31. SCO 25 escort service
9711147426✨Call In girls Gurgaon Sector 31. SCO 25 escort service
 
VIP Call Girls Service Charbagh { Lucknow Call Girls Service 9548273370 } Boo...
VIP Call Girls Service Charbagh { Lucknow Call Girls Service 9548273370 } Boo...VIP Call Girls Service Charbagh { Lucknow Call Girls Service 9548273370 } Boo...
VIP Call Girls Service Charbagh { Lucknow Call Girls Service 9548273370 } Boo...
 
Call Us ➥97111√47426🤳Call Girls in Aerocity (Delhi NCR)
Call Us ➥97111√47426🤳Call Girls in Aerocity (Delhi NCR)Call Us ➥97111√47426🤳Call Girls in Aerocity (Delhi NCR)
Call Us ➥97111√47426🤳Call Girls in Aerocity (Delhi NCR)
 
Call Girls in Saket 99530🔝 56974 Escort Service
Call Girls in Saket 99530🔝 56974 Escort ServiceCall Girls in Saket 99530🔝 56974 Escort Service
Call Girls in Saket 99530🔝 56974 Escort Service
 
Indian Call Girls in Abu Dhabi O5286O24O8 Call Girls in Abu Dhabi By Independ...
Indian Call Girls in Abu Dhabi O5286O24O8 Call Girls in Abu Dhabi By Independ...Indian Call Girls in Abu Dhabi O5286O24O8 Call Girls in Abu Dhabi By Independ...
Indian Call Girls in Abu Dhabi O5286O24O8 Call Girls in Abu Dhabi By Independ...
 
代办国外大学文凭《原版美国UCLA文凭证书》加州大学洛杉矶分校毕业证制作成绩单修改
代办国外大学文凭《原版美国UCLA文凭证书》加州大学洛杉矶分校毕业证制作成绩单修改代办国外大学文凭《原版美国UCLA文凭证书》加州大学洛杉矶分校毕业证制作成绩单修改
代办国外大学文凭《原版美国UCLA文凭证书》加州大学洛杉矶分校毕业证制作成绩单修改
 
办理学位证纽约大学毕业证(NYU毕业证书)原版一比一
办理学位证纽约大学毕业证(NYU毕业证书)原版一比一办理学位证纽约大学毕业证(NYU毕业证书)原版一比一
办理学位证纽约大学毕业证(NYU毕业证书)原版一比一
 
RA-11058_IRR-COMPRESS Do 198 series of 1998
RA-11058_IRR-COMPRESS Do 198 series of 1998RA-11058_IRR-COMPRESS Do 198 series of 1998
RA-11058_IRR-COMPRESS Do 198 series of 1998
 
High Class Call Girls Noida Sector 39 Aarushi 🔝8264348440🔝 Independent Escort...
High Class Call Girls Noida Sector 39 Aarushi 🔝8264348440🔝 Independent Escort...High Class Call Girls Noida Sector 39 Aarushi 🔝8264348440🔝 Independent Escort...
High Class Call Girls Noida Sector 39 Aarushi 🔝8264348440🔝 Independent Escort...
 
Saket, (-DELHI )+91-9654467111-(=)CHEAP Call Girls in Escorts Service Saket C...
Saket, (-DELHI )+91-9654467111-(=)CHEAP Call Girls in Escorts Service Saket C...Saket, (-DELHI )+91-9654467111-(=)CHEAP Call Girls in Escorts Service Saket C...
Saket, (-DELHI )+91-9654467111-(=)CHEAP Call Girls in Escorts Service Saket C...
 
Amazon TQM (2) Amazon TQM (2)Amazon TQM (2).pptx
Amazon TQM (2) Amazon TQM (2)Amazon TQM (2).pptxAmazon TQM (2) Amazon TQM (2)Amazon TQM (2).pptx
Amazon TQM (2) Amazon TQM (2)Amazon TQM (2).pptx
 
RadioAdProWritingCinderellabyButleri.pdf
RadioAdProWritingCinderellabyButleri.pdfRadioAdProWritingCinderellabyButleri.pdf
RadioAdProWritingCinderellabyButleri.pdf
 
VIP High Class Call Girls Jamshedpur Anushka 8250192130 Independent Escort Se...
VIP High Class Call Girls Jamshedpur Anushka 8250192130 Independent Escort Se...VIP High Class Call Girls Jamshedpur Anushka 8250192130 Independent Escort Se...
VIP High Class Call Girls Jamshedpur Anushka 8250192130 Independent Escort Se...
 
04242024_CCC TUG_Joins and Relationships
04242024_CCC TUG_Joins and Relationships04242024_CCC TUG_Joins and Relationships
04242024_CCC TUG_Joins and Relationships
 
Call Girls In Mahipalpur O9654467111 Escorts Service
Call Girls In Mahipalpur O9654467111  Escorts ServiceCall Girls In Mahipalpur O9654467111  Escorts Service
Call Girls In Mahipalpur O9654467111 Escorts Service
 
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
 
Dubai Call Girls Wifey O52&786472 Call Girls Dubai
Dubai Call Girls Wifey O52&786472 Call Girls DubaiDubai Call Girls Wifey O52&786472 Call Girls Dubai
Dubai Call Girls Wifey O52&786472 Call Girls Dubai
 
Schema on read is obsolete. Welcome metaprogramming..pdf
Schema on read is obsolete. Welcome metaprogramming..pdfSchema on read is obsolete. Welcome metaprogramming..pdf
Schema on read is obsolete. Welcome metaprogramming..pdf
 
Decoding Loan Approval: Predictive Modeling in Action
Decoding Loan Approval: Predictive Modeling in ActionDecoding Loan Approval: Predictive Modeling in Action
Decoding Loan Approval: Predictive Modeling in Action
 

Couchbase usage at Symantec

  • 1. Couchbase at Symantec Gaurav Chandna Sr Principal Software Engineer
  • 2. About Me Gaurav Chandna At Symantec for 11 years. Worked at AntiSpyware, Behavioral malware, Norton and now building platforms. Engineering Manager previously @xyxxy 2
  • 3. Agenda 1 Introduction 2 Time series 3 Relational 4 Q&A Copyright © 2014 Symantec Corporation 3
  • 4. Introduction Copyright © 2014 Symantec Corporation 4
  • 5. Environment • Service Oriented Architecture • Message Oriented Middleware • Multi-tenant • Multiple data centers Copyright © 2014 Symantec Corporation 5
  • 6. Message Oriented Architecture Copyright © 2014 Symantec Corporation 6
  • 7. Replication between data centers Copyright © 2014 Symantec Corporation 7
  • 8. Time Series Data Copyright © 2014 Symantec Corporation 8
  • 9. Copyright © 2014 Symantec Corporation 9
  • 10. Copyright © 2014 Symantec Corporation 10
  • 12. Quick side bar: Elasticsearch Copyright © 2014 Symantec Corporation 12
  • 13. Elasticsearch Copyright © 2014 Symantec Corporation 13 • Document oriented search engine • Based on Apache Lucene project • JSON based • Distributed • Scale out • Multi-tenancy • RESTful
  • 14. Elasticsearch Copyright © 2014 Symantec Corporation 14 • Structured search • Unstructured search • Analytics • Combine
  • 15. All good? Copyright © 2014 Symantec Corporation 15
  • 16. Well… kind of • Elasticsearch doesn’t recommend using it as data store – Due to write coalescing • Limited support for replication between data centers – Especially across unreliable networks Copyright © 2014 Symantec Corporation 16
  • 18. Cross data center replication Copyright © 2014 Symantec Corporation 18
  • 19. Used to replicate Elasticsearch between data centers Copyright © 2014 Symantec Corporation 19
  • 20. It’s all good! Copyright © 2014 Symantec Corporation 20
  • 21. Just one more thing… • Document stored on Couchbase After X days, the document gets purged • XDCR will purge in Elasticsearch also • Forked the Couchbase – Elasticsearch connector to disable deletion • Looking to integrate those changes to Couchbase for community use Copyright © 2014 Symantec Corporation 21
  • 22. And we are finally good! Copyright © 2014 Symantec Corporation 22
  • 23. Data with relationships Copyright © 2014 Symantec Corporation 23
  • 24. Relationships are everywhere Copyright © 2014 Symantec Corporation 24 Engineering Gaurav iPhone Mac John PC Android
  • 25. Right here… Copyright © 2014 Symantec Corporation 25 Meetup @Symantec Gaurav iPhone Joshua Android
  • 26. In abstract terms A B C D C’ Y Copyright © 2014 Symantec Corporation 26
  • 27. You get information through queries • Get all members of a particular group • All groups ordered by number of people in the group • List all members of a group, order by location • List all groups where users have iPhone, ordered by total number of people • And so on.. Copyright © 2014 Symantec Corporation 27
  • 28. Engineering considerations • Ability to add new types – Don’t make big changes when iWatch came out • Ability to extend the types • Add new relationships quickly Copyright © 2014 Symantec Corporation 28
  • 29. Table stakes • Cross data center replication • Performance • Horizontal scaling • Searching • Querying capability Copyright © 2014 Symantec Corporation 29
  • 30. Initial implementation • { • ”type": ”person”, • "name": ”Gaurav", • "modified": "2015-04- 17T00:39:45.468Z", • "_id": "79014cbb-69ce-4459-8f4a- 6edaf4b8313a", • // other information • } • { • ”type": ”department”, • "name": ”Engineering", • "_id": "79014cbb-69ce-4459-8f4a- 6edaf4b8313a", • // other information • } Copyright © 2014 Symantec Corporation 30
  • 31. Initial version • Store different objects with types as documents • Create views in Couchbase – Type – Relationships between types – Specialize on special types • Ensure persistence during operations • Works well… to a point Copyright © 2014 Symantec Corporation 31
  • 32. So we needed a next generation Copyright © 2014 Symantec Corporation 32
  • 33. Second iteration • { • "_id":"Well_crafted_id” • // Other meta information • // Other associated information • } • Relationship information embedded in the _id • Takes advantage of key access to document by id • Can still build views on these documents • Does require more hand crafting to get better performance • Maintain flexibility • Need to play around with different APIs to see which work best for use case • More generic code Copyright © 2014 Symantec Corporation 33
  • 34. What about search? Copyright © 2014 Symantec Corporation 34
  • 35. Use Elasticsearch for search! • Couchbase is primary data store • Use Couchbase XDCR for one direction replication – Like time series data – But don’t disable deletes Copyright © 2014 Symantec Corporation 35 Message Queue Service Couchbase Elasticsearch
  • 36. But… • Elasticsearch prefers types to be well defined for indexing • Code is generic for extensibility • Couchbase – Elasticsearch plugin only supports 1 configuration • Different services have different needs Copyright © 2014 Symantec Corporation 36
  • 37. • More modifications to the Elasticsearch – Couchbase connector • Custom code to deduce types for compatibility with Elasticsearch • Per bucket configurations so deletes for time series but not for relational data • Keep dynamically defined types and the code generic Copyright © 2014 Symantec Corporation 37
  • 38. Final thoughts • Data modeling is extremely important • JSON Parser – experiment for your use case • Experiment with the different API options for your needs • Don’t be afraid to customize for your needs! • Polyglot persistence – Matt’s presentation Copyright © 2014 Symantec Corporation 38
  • 39. Thank you! Copyright © 2014 Symantec Corporation. All rights reserved. Symantec and the Symantec Logo are trademarks or registered trademarks of Symantec Corporation or its affiliates in the U.S. and other countries. Other names may be trademarks of their respective owners. This document is provided for informational purposes only and is not intended as advertising. All warranties relating to the information in this document, either express or implied, are disclaimed to the maximum extent allowed by law. The information in this document is subject to change without notice. Gaurav Chandna Gaurav_chandna@symantec.com Twitter: @xyxxy
  • 40. Thank you! Copyright © 2014 Symantec Corporation. All rights reserved. Symantec and the Symantec Logo are trademarks or registered trademarks of Symantec Corporation or its affiliates in the U.S. and other countries. Other names may be trademarks of their respective owners. This document is provided for informational purposes only and is not intended as advertising. All warranties relating to the information in this document, either express or implied, are disclaimed to the maximum extent allowed by law. The information in this document is subject to change without notice. We are hiring www.symantec.com/careers
  • 41. &Q A Copyright © 2014 Symantec Corporation 41

Editor's Notes

  1. This is a Title Slide Portrait slide ideal for including a portrait with a brief title, presenter’s name and title. To Replace the Picture on this sample slide (this applies to all slides in this template that contain replaceable pictures) Select the sample picture and press Delete on your keyboard. Click the icon inside the shape to open the Insert Picture dialog box. Navigate to the location where the picture is stored, select desired picture and click on the Insert button to fit the image proportionally within the shape. Note: Do not right-click the image to change the picture inside the picture placeholder. This will change the frame size of the picture placeholder. Instead, follow the steps outlined above. Tip: simple SEO adjustments can make your presentation more discoverable. Read this PDF for best practices:  http://seo.ges.symantec.com/seo-best-practices-for-file-optimization.pdf
  2. Slide 2 – About Me
  3. A is associated with B B is associated with C A is associated with C Code models them as objects and relationships and privileges Talk through the use cases of what we do Why relational doesn’t work Talk about the different options that we have in code JSON Parsing is expensive. Can talk about the initial implementation Take aways model your data properly