SlideShare a Scribd company logo
CUBRID InsideFirst Look Inside CUBRID Jan 18, 2009
저작권 Copyright Notice CREATIVE COMMONS 저작자표시-동일조건변경허락 2.0 대한민국 이용자는 아래의 조건을 따르는 경우에 한하여 자유롭게 이 저작물을 복제, 배포, 전송, 전시, 공연 및 방송할 수 있습니다. 이차적 저작물을 작성할 수 있습니다. 다음과 같은 조건을 따라야 합니다: 저작자표시. 귀하는 원저작자를 표시하여야 합니다.  What does "Attribute this work" mean? The page you came from contained embedded licensing metadata, including how the creator wishes to be attributed for re-use. You can use the HTML here to cite the work. Doing so will also include metadata on your page so that others can find the original work as well.  동일조건변경허락. 귀하가 이 저작물을 개작, 변형 또는 가공했을 경우에는, 이 저작물과 동일한 이용허락조건하에서만 배포할 수 있습니다.  귀하는, 이 저작물의 재이용이나 배포의 경우, 이 저작물에 적용된 이용허락조건을 명확하게 나타내어야 합니다. 저작권자로부터 별도의 허가를 받으면 이러한 조건들은 적용되지 않습니다. Nothing in this license impairs or restricts the author's moral rights. CREATIVE COMMONS Attribution-Share Alike 2.0 Korea You are free: to Share — to copy, distribute and transmit the work to Remix — to adapt the work Under the following conditions: Attribution. You must attribute the work in the manner specified by the author or licensor (but not in any way that suggests that they endorse you or your use of the work).  What does "Attribute this work" mean? The page you came from contained embedded licensing metadata, including how the creator wishes to be attributed for re-use. You can use the HTML here to cite the work. Doing so will also include metadata on your page so that others can find the original work as well.  Share Alike. If you alter, transform, or build upon this work, you may distribute the resulting work only under the same or similar license to this one.  For any reuse or distribution, you must make clear to others the license terms of this work. The best way to do this is with a link to this web page. Any of the above conditions can be waived if you get permission from the copyright holder. Nothing in this license impairs or restricts the author's moral rights. http://creativecommons.org/licenses/by-sa/2.0/kr/ Copyright 2009 Search Solution Corporation. All Rights Reserved.
CUBRID
Contents System Architecture and Processes Design & Implementation Concepts Module and Source Structure In The Next CUBRID Inside 4/ 41   First Look Inside CUBRID
[object Object]
System Architecture
CUBRID Processes and IPC
Query Processing WorkflowSystem Architecture and Processes 1 5/ 41   First Look Inside CUBRID
System Architecture and ProcessesWhat is CUBRID? CUBRID is Open Source DBMS owned and developed by NHN Hosted at nForge site Targeted to a database platform for Internet portal service Relational database system with object extensions – Object-Relational Model 1,000,000 line of source code scaled project Engine – C/C++, CUBRID Manager (GUI) and JDBC driver – Java CUBRID provides Full-featured database server engine Server and Broker architecture GUI management and query tool CUBRID Manager Various API (JDBC, ODBC(OLE DB), PHP, and CCI) Python and Ruby as contributed projects 1.1 6/ 41   First Look Inside CUBRID
System Architecture and ProcessesSystem Architecture 1.2 Server Subsystem Multi-threaded storage engine part which runs as DB server Consists of Transaction Manager, Object Manager, Lock Manager, Query Manager, Log Manager, and Storage Manager Client Subsystem Client library part providing native C API Consists of Query Parser & Optimizer, Object & Lock Cache, Transaction Manager and Object Manager Broker Subsystem Linked with client library and implemented CCI protocol Does job queuing, connection pooling, monitoring and logging Connectors JDBC driver CCI library Many drivers are implemented with CCI library – ODBC, OLEDB, PHP, Python, and Ruby 7/ 41   First Look Inside CUBRID
System Architecture and ProcessesSystem Architecture 1.2 CUBRID Manager GUI Interface PHP OLE DB Ruby CUBRID Manager JDBC ODBC CCI Python CM Server Job Queuing Monitoring Connection Pooling Logging Admin Utility Broker Create, Delete, Copy, Rename Query Parser & Optimizer Lock Cache Object Manager Transaction Manager Add Volume Load / Unload Backup / Restore Query Manager Lock Manager Server Compact / Optimize Storage Manager Log Manager Check / Diag Active Log File Based Objects Data Volume Index Volume Temp Volume Archive Log 8/ 41   First Look Inside CUBRID
1.2 CUBRID Manager GUI Interface PHP OLE DB Ruby CUBRID Manager JDBC ODBC CCI Python CM Server Create, Delete, Copy, Rename Job Queuing Monitoring Connection Pooling Logging Admin Utility Broker Client Library Add Volume Native C API Parser Object Manager Schema Manager Transaction Manager Load / Unload Query Transform Workspace Manager Backup / Restore Query Optimizer Memory Manager Compact / Optimize Plan Generation Check / Diag Communication Module Storage Engine Server Communication Module Transaction Manager Log Manager Lock Manager Query Manager Access Method B+Tree Module File Manager System Catalog Module System Architecture Buffer Manager Disk Manager Active Log File Based Objects Data Volume Index Volume Temp Volume Archive Log 9/ 41   First Look Inside CUBRID
System Architecture and ProcessesCUBRID Processes and IPC Master Process ‘cub_master’ Daemon process listening on the TCP port for clients’ connection csql, broker, and admin utilities Registrar of server processes using Unix Domain Socket Server Process ‘cub_server’ Multi-threaded process serving clients’ requests Has thread pool and job queue Accesses database volume and log files One server process per one database Broker Process ‘cub_broker’ Daemon process listening on the TCP port for connectors’ connection Controls cub_cas processes (fork/kill) with connection queue CAS Process ‘cub_cas’ Connects to the server process in behalf of connectors According to the database and user name CSQL Program ‘csql’ Interactive SQL execution 1.3 10/ 41   First Look Inside CUBRID
System Architecture and ProcessesCUBRID Processes and IPC 1.3 JDBC driver CCI library connect query & result query & result port listening cub_broker cubrid_broker.conf fork parse descriptor pass AP Web Server cub_cas cub_cas shared memory cubridcs.so cubridcs.so csql connect cubridcs.so request & response request & response parse Broker TCP job queue multi-thread port listening descriptor pass parse cub_master cub_server cubrid.so cubrid.conf UDS Active Server Standby Server mount (read/write) read register volume file log file databases.txt volume file log file Replication cub_admin cubridsa.so 11/ 41   First Look Inside CUBRID
System Architecture and ProcessesQuery Processing Workflow 1.4 12/ 41   First Look Inside CUBRID
System Architecture and ProcessesQuery Processing Workflow 1.4 XASL  Type UNION Extended Access Spec Language (XASL) DIFFERENCE INTERSECTION OBJFETCH Query Manager TransactionManager Lock Manager SETFETCH BUILD_LIST BUILD_VALUE Query Result Cache Query Plan Cache Query Evaluator (Interpreter) SCAN MERGE_LIST Scan  Management READ UPDATE Storage Manager DELETE INSERT 13/ 41   First Look Inside CUBRID
Design & Implementation Concepts 2 ,[object Object]
Object, Class and OID
Representation, Record Descriptor, and Memory Object Pointer
Workspace – Object & Lock Caching
2PL vs. MVCC
XASL (Extended Access Spec Language)
Heap, B+tree, Catalog, and Temp
Click Counter14/ 41   First Look Inside CUBRID
Design & Implementation ConceptsClient-Server and Standalone Mode 2.1 15/ 41   First Look Inside CUBRID
Design & Implementation ConceptsObject, Class and OID 2.2 16/ 41   First Look Inside CUBRID
Design & Implementation ConceptsRepresentation, Record Descriptor, and Memory Object Pointer 2.3 17/ 41   First Look Inside CUBRID
Design & Implementation ConceptsWorkspace – Object & Lock Caching 2.4 18/ 41   First Look Inside CUBRID
Design & Implementation Concepts2PL vs. MVCC 2.5 19/ 41   First Look Inside CUBRID
Design & Implementation ConceptsXASL (Extended Access Spec Language) 2.6 20/ 41   First Look Inside CUBRID
Design & Implementation ConceptsHeap, B+tree, Catalog, and Temp 2.7 21/ 41   First Look Inside CUBRID
Design & Implementation ConceptsClick Counter In Terms of User Whenever the user clicks an article, the read counter of the article is increased. Counts the clicks on the article In Terms of Service Application Developer The read counter is very important for bulletin board type service. Combine getting article data and increasing read counter together get_article() + increase_counter() = get_article_and_increase_counter() (SELECT article_info) + (UPDATE read_counter+1) In Terms of Database Engineer Do SELECT and UPDATE in one SQL statement SELECT trigger? SELECT FOR UDPATE? UPDATE the record with the short term lock Example SELECT doc_id, title, INCR(read_counter), post_date FROM board WHERE doc_id=? 2.8 22/ 41   First Look Inside CUBRID
Design & Implementation ConceptsClick Counter 2.8 Don’t walk the same passage twice! When you get there, do as many things as possible. Killing two birds with one stone. 23/ 41   First Look Inside CUBRID
Module and Source Structure 3 ,[object Object]
Query Processing Component
Transaction Management Component
Server Storage Management Component
Client Storage Management Component
Object Management Component
Job and Thread Management Component
Client-Server Communication Layer
Broker Component24/ 41   First Look Inside CUBRID

More Related Content

What's hot

[2A5]하둡 보안 어떻게 해야 할까
[2A5]하둡 보안 어떻게 해야 할까[2A5]하둡 보안 어떻게 해야 할까
[2A5]하둡 보안 어떻게 해야 할까
NAVER D2
 
CQRS and Event Sourcing for Java Developers
CQRS and Event Sourcing for Java DevelopersCQRS and Event Sourcing for Java Developers
CQRS and Event Sourcing for Java Developers
Markus Eisele
 
Docker Java App with MariaDB – Deployment in Less than a Minute
Docker Java App with MariaDB – Deployment in Less than a MinuteDocker Java App with MariaDB – Deployment in Less than a Minute
Docker Java App with MariaDB – Deployment in Less than a Minute
dchq
 
Kubernetes #1 intro
Kubernetes #1   introKubernetes #1   intro
Kubernetes #1 intro
Terry Cho
 
A flexible plugin like data layer - decouple your -_application logic from yo...
A flexible plugin like data layer - decouple your -_application logic from yo...A flexible plugin like data layer - decouple your -_application logic from yo...
A flexible plugin like data layer - decouple your -_application logic from yo...MongoDB
 
인메모리 클러스터링 아키텍처
인메모리 클러스터링 아키텍처인메모리 클러스터링 아키텍처
인메모리 클러스터링 아키텍처
Jaehong Cheon
 
Securing Your Enterprise Web Apps with MongoDB Enterprise
Securing Your Enterprise Web Apps with MongoDB Enterprise Securing Your Enterprise Web Apps with MongoDB Enterprise
Securing Your Enterprise Web Apps with MongoDB Enterprise
MongoDB
 
Securing Your MongoDB Deployment
Securing Your MongoDB DeploymentSecuring Your MongoDB Deployment
Securing Your MongoDB Deployment
MongoDB
 
Mdb dn 2016_11_ops_mgr
Mdb dn 2016_11_ops_mgrMdb dn 2016_11_ops_mgr
Mdb dn 2016_11_ops_mgr
Daniel M. Farrell
 
Hadoop Security Preview
Hadoop Security PreviewHadoop Security Preview
Hadoop Security Preview
Hadoop User Group
 
Saint2012 mod process security
Saint2012 mod process securitySaint2012 mod process security
Saint2012 mod process security
Ryosuke MATSUMOTO
 
Introduction to Mesos
Introduction to MesosIntroduction to Mesos
Introduction to Mesoskoboltmarky
 
Keystone deep dive 1
Keystone deep dive 1Keystone deep dive 1
Keystone deep dive 1
Jsonr4
 
MongoDB Best Practices in AWS
MongoDB Best Practices in AWS MongoDB Best Practices in AWS
MongoDB Best Practices in AWS Chris Harris
 
Hadoop security
Hadoop securityHadoop security
Hadoop security
shrey mehrotra
 
TrinityCore server install guide
TrinityCore server install guideTrinityCore server install guide
TrinityCore server install guide
Seungmin Shin
 
Leonid Vasilyev "Building, deploying and running production code at Dropbox"
Leonid Vasilyev  "Building, deploying and running production code at Dropbox"Leonid Vasilyev  "Building, deploying and running production code at Dropbox"
Leonid Vasilyev "Building, deploying and running production code at Dropbox"
IT Event
 
Securing Your MongoDB Implementation
Securing Your MongoDB ImplementationSecuring Your MongoDB Implementation
Securing Your MongoDB Implementation
MongoDB
 
Kubernetes #4 volume & stateful set
Kubernetes #4   volume & stateful setKubernetes #4   volume & stateful set
Kubernetes #4 volume & stateful set
Terry Cho
 
Managing distributed-cloud-apps
Managing distributed-cloud-appsManaging distributed-cloud-apps
Managing distributed-cloud-apps
Nikolay Valchev
 

What's hot (20)

[2A5]하둡 보안 어떻게 해야 할까
[2A5]하둡 보안 어떻게 해야 할까[2A5]하둡 보안 어떻게 해야 할까
[2A5]하둡 보안 어떻게 해야 할까
 
CQRS and Event Sourcing for Java Developers
CQRS and Event Sourcing for Java DevelopersCQRS and Event Sourcing for Java Developers
CQRS and Event Sourcing for Java Developers
 
Docker Java App with MariaDB – Deployment in Less than a Minute
Docker Java App with MariaDB – Deployment in Less than a MinuteDocker Java App with MariaDB – Deployment in Less than a Minute
Docker Java App with MariaDB – Deployment in Less than a Minute
 
Kubernetes #1 intro
Kubernetes #1   introKubernetes #1   intro
Kubernetes #1 intro
 
A flexible plugin like data layer - decouple your -_application logic from yo...
A flexible plugin like data layer - decouple your -_application logic from yo...A flexible plugin like data layer - decouple your -_application logic from yo...
A flexible plugin like data layer - decouple your -_application logic from yo...
 
인메모리 클러스터링 아키텍처
인메모리 클러스터링 아키텍처인메모리 클러스터링 아키텍처
인메모리 클러스터링 아키텍처
 
Securing Your Enterprise Web Apps with MongoDB Enterprise
Securing Your Enterprise Web Apps with MongoDB Enterprise Securing Your Enterprise Web Apps with MongoDB Enterprise
Securing Your Enterprise Web Apps with MongoDB Enterprise
 
Securing Your MongoDB Deployment
Securing Your MongoDB DeploymentSecuring Your MongoDB Deployment
Securing Your MongoDB Deployment
 
Mdb dn 2016_11_ops_mgr
Mdb dn 2016_11_ops_mgrMdb dn 2016_11_ops_mgr
Mdb dn 2016_11_ops_mgr
 
Hadoop Security Preview
Hadoop Security PreviewHadoop Security Preview
Hadoop Security Preview
 
Saint2012 mod process security
Saint2012 mod process securitySaint2012 mod process security
Saint2012 mod process security
 
Introduction to Mesos
Introduction to MesosIntroduction to Mesos
Introduction to Mesos
 
Keystone deep dive 1
Keystone deep dive 1Keystone deep dive 1
Keystone deep dive 1
 
MongoDB Best Practices in AWS
MongoDB Best Practices in AWS MongoDB Best Practices in AWS
MongoDB Best Practices in AWS
 
Hadoop security
Hadoop securityHadoop security
Hadoop security
 
TrinityCore server install guide
TrinityCore server install guideTrinityCore server install guide
TrinityCore server install guide
 
Leonid Vasilyev "Building, deploying and running production code at Dropbox"
Leonid Vasilyev  "Building, deploying and running production code at Dropbox"Leonid Vasilyev  "Building, deploying and running production code at Dropbox"
Leonid Vasilyev "Building, deploying and running production code at Dropbox"
 
Securing Your MongoDB Implementation
Securing Your MongoDB ImplementationSecuring Your MongoDB Implementation
Securing Your MongoDB Implementation
 
Kubernetes #4 volume & stateful set
Kubernetes #4   volume & stateful setKubernetes #4   volume & stateful set
Kubernetes #4 volume & stateful set
 
Managing distributed-cloud-apps
Managing distributed-cloud-appsManaging distributed-cloud-apps
Managing distributed-cloud-apps
 

Viewers also liked

CUBRID HA - Guaranteed Way to Never-Die Web Services - OSCON 2011
CUBRID HA - Guaranteed Way to Never-Die Web Services - OSCON 2011CUBRID HA - Guaranteed Way to Never-Die Web Services - OSCON 2011
CUBRID HA - Guaranteed Way to Never-Die Web Services - OSCON 2011
CUBRID
 
Быстрый и простой способ шардирования MySQL с помощью CUBRID SHARD - 2013 R...
Быстрый и простой способ шардирования MySQL с помощью CUBRID SHARD - 2013 R...Быстрый и простой способ шардирования MySQL с помощью CUBRID SHARD - 2013 R...
Быстрый и простой способ шардирования MySQL с помощью CUBRID SHARD - 2013 R...
CUBRID
 
Installing CUBRID Database and CUBRID Manager on Windows
Installing CUBRID Database and CUBRID Manager on WindowsInstalling CUBRID Database and CUBRID Manager on Windows
Installing CUBRID Database and CUBRID Manager on Windows
CUBRID
 
Realtime communication in mobile
Realtime communication in mobileRealtime communication in mobile
Realtime communication in mobile
girish_fingent
 
WhatsApp architecture
WhatsApp architectureWhatsApp architecture
WhatsApp architecture
Mahesh Bitla
 

Viewers also liked (6)

CUBRID HA - Guaranteed Way to Never-Die Web Services - OSCON 2011
CUBRID HA - Guaranteed Way to Never-Die Web Services - OSCON 2011CUBRID HA - Guaranteed Way to Never-Die Web Services - OSCON 2011
CUBRID HA - Guaranteed Way to Never-Die Web Services - OSCON 2011
 
Быстрый и простой способ шардирования MySQL с помощью CUBRID SHARD - 2013 R...
Быстрый и простой способ шардирования MySQL с помощью CUBRID SHARD - 2013 R...Быстрый и простой способ шардирования MySQL с помощью CUBRID SHARD - 2013 R...
Быстрый и простой способ шардирования MySQL с помощью CUBRID SHARD - 2013 R...
 
Installing CUBRID Database and CUBRID Manager on Windows
Installing CUBRID Database and CUBRID Manager on WindowsInstalling CUBRID Database and CUBRID Manager on Windows
Installing CUBRID Database and CUBRID Manager on Windows
 
Realtime communication in mobile
Realtime communication in mobileRealtime communication in mobile
Realtime communication in mobile
 
WhatsApp architecture
WhatsApp architectureWhatsApp architecture
WhatsApp architecture
 
Whatsapp project work
Whatsapp project workWhatsapp project work
Whatsapp project work
 

Similar to CUBRID Inside - Architecture, Source & Management Components

Integrating CC Licensing with Applications
Integrating CC Licensing with ApplicationsIntegrating CC Licensing with Applications
Integrating CC Licensing with ApplicationsNathan Yergler
 
Code igniter - A brief introduction
Code igniter - A brief introductionCode igniter - A brief introduction
Code igniter - A brief introduction
Commit University
 
Innovate2011 Keys to Building OSLC Integrations
Innovate2011 Keys to Building OSLC IntegrationsInnovate2011 Keys to Building OSLC Integrations
Innovate2011 Keys to Building OSLC Integrations
Steve Speicher
 
Liberty Buildpack: Designed for Extension - Integrating your services in Blue...
Liberty Buildpack: Designed for Extension - Integrating your services in Blue...Liberty Buildpack: Designed for Extension - Integrating your services in Blue...
Liberty Buildpack: Designed for Extension - Integrating your services in Blue...
Rohit Kelapure
 
Monorail presentation at WebDevelopersCommunity, Feb 1, 2009
Monorail presentation at WebDevelopersCommunity, Feb 1, 2009Monorail presentation at WebDevelopersCommunity, Feb 1, 2009
Monorail presentation at WebDevelopersCommunity, Feb 1, 2009
ken.egozi
 
Kubernetes One-Click Deployment: Hands-on Workshop (Mainz)
Kubernetes One-Click Deployment: Hands-on Workshop (Mainz)Kubernetes One-Click Deployment: Hands-on Workshop (Mainz)
Kubernetes One-Click Deployment: Hands-on Workshop (Mainz)
QAware GmbH
 
DevCon5 (July 2014) - Acision SDK
DevCon5 (July 2014) - Acision SDKDevCon5 (July 2014) - Acision SDK
DevCon5 (July 2014) - Acision SDK
Crocodile WebRTC SDK and Cloud Signalling Network
 
Experts Live Switzerland 2017 - Automatisierte Docker Release Pipeline mit VS...
Experts Live Switzerland 2017 - Automatisierte Docker Release Pipeline mit VS...Experts Live Switzerland 2017 - Automatisierte Docker Release Pipeline mit VS...
Experts Live Switzerland 2017 - Automatisierte Docker Release Pipeline mit VS...
Marc Müller
 
Technology / Open Source @ Creative Commons (CC Salon SF, August 2009)
Technology / Open Source @ Creative Commons (CC Salon SF, August 2009)Technology / Open Source @ Creative Commons (CC Salon SF, August 2009)
Technology / Open Source @ Creative Commons (CC Salon SF, August 2009)Nathan Yergler
 
Taking Software Lifecycle Integration (SLI) to the Next Layer - Welcome to Co...
Taking Software Lifecycle Integration (SLI) to the Next Layer - Welcome to Co...Taking Software Lifecycle Integration (SLI) to the Next Layer - Welcome to Co...
Taking Software Lifecycle Integration (SLI) to the Next Layer - Welcome to Co...
Johannes Nicolai
 
Building and Deployment of Drupal sites with Features and Context
Building and Deployment of Drupal sites with Features and ContextBuilding and Deployment of Drupal sites with Features and Context
Building and Deployment of Drupal sites with Features and Context
Svilen Sabev
 
ASP.NET 8 Developer Roadmap By ScholarHat PDF
ASP.NET 8 Developer Roadmap By ScholarHat PDFASP.NET 8 Developer Roadmap By ScholarHat PDF
ASP.NET 8 Developer Roadmap By ScholarHat PDF
Scholarhat
 
CODE IGNITER
CODE IGNITERCODE IGNITER
CODE IGNITER
Yesha kapadia
 
What’s new in Rational collaborative lifecycle management 2011?
What’s new in Rational collaborative lifecycle management 2011?What’s new in Rational collaborative lifecycle management 2011?
What’s new in Rational collaborative lifecycle management 2011?
IBM Danmark
 
Ajax toolkit framework
Ajax toolkit frameworkAjax toolkit framework
Ajax toolkit framework
Sunil Kumar
 
Chembience
ChembienceChembience
Chembience
Markus Sitzmann
 
report_vendor_connect
report_vendor_connectreport_vendor_connect
report_vendor_connectYash Mittal
 
Build Event-Driven Microservices with Confluent Cloud Workshop #1
Build Event-Driven Microservices with Confluent Cloud Workshop #1Build Event-Driven Microservices with Confluent Cloud Workshop #1
Build Event-Driven Microservices with Confluent Cloud Workshop #1
confluent
 
AWS Community Day Bangkok 2019 - Build a Serverless Web Application in 30 mins
AWS Community Day Bangkok 2019 - Build a Serverless Web Application in 30 minsAWS Community Day Bangkok 2019 - Build a Serverless Web Application in 30 mins
AWS Community Day Bangkok 2019 - Build a Serverless Web Application in 30 mins
AWS User Group - Thailand
 

Similar to CUBRID Inside - Architecture, Source & Management Components (20)

Integrating CC Licensing with Applications
Integrating CC Licensing with ApplicationsIntegrating CC Licensing with Applications
Integrating CC Licensing with Applications
 
Code igniter - A brief introduction
Code igniter - A brief introductionCode igniter - A brief introduction
Code igniter - A brief introduction
 
Innovate2011 Keys to Building OSLC Integrations
Innovate2011 Keys to Building OSLC IntegrationsInnovate2011 Keys to Building OSLC Integrations
Innovate2011 Keys to Building OSLC Integrations
 
AEM 6.X (With Basics) Training Syllabus
AEM 6.X (With Basics) Training SyllabusAEM 6.X (With Basics) Training Syllabus
AEM 6.X (With Basics) Training Syllabus
 
Liberty Buildpack: Designed for Extension - Integrating your services in Blue...
Liberty Buildpack: Designed for Extension - Integrating your services in Blue...Liberty Buildpack: Designed for Extension - Integrating your services in Blue...
Liberty Buildpack: Designed for Extension - Integrating your services in Blue...
 
Monorail presentation at WebDevelopersCommunity, Feb 1, 2009
Monorail presentation at WebDevelopersCommunity, Feb 1, 2009Monorail presentation at WebDevelopersCommunity, Feb 1, 2009
Monorail presentation at WebDevelopersCommunity, Feb 1, 2009
 
Kubernetes One-Click Deployment: Hands-on Workshop (Mainz)
Kubernetes One-Click Deployment: Hands-on Workshop (Mainz)Kubernetes One-Click Deployment: Hands-on Workshop (Mainz)
Kubernetes One-Click Deployment: Hands-on Workshop (Mainz)
 
DevCon5 (July 2014) - Acision SDK
DevCon5 (July 2014) - Acision SDKDevCon5 (July 2014) - Acision SDK
DevCon5 (July 2014) - Acision SDK
 
Experts Live Switzerland 2017 - Automatisierte Docker Release Pipeline mit VS...
Experts Live Switzerland 2017 - Automatisierte Docker Release Pipeline mit VS...Experts Live Switzerland 2017 - Automatisierte Docker Release Pipeline mit VS...
Experts Live Switzerland 2017 - Automatisierte Docker Release Pipeline mit VS...
 
Technology / Open Source @ Creative Commons (CC Salon SF, August 2009)
Technology / Open Source @ Creative Commons (CC Salon SF, August 2009)Technology / Open Source @ Creative Commons (CC Salon SF, August 2009)
Technology / Open Source @ Creative Commons (CC Salon SF, August 2009)
 
Taking Software Lifecycle Integration (SLI) to the Next Layer - Welcome to Co...
Taking Software Lifecycle Integration (SLI) to the Next Layer - Welcome to Co...Taking Software Lifecycle Integration (SLI) to the Next Layer - Welcome to Co...
Taking Software Lifecycle Integration (SLI) to the Next Layer - Welcome to Co...
 
Building and Deployment of Drupal sites with Features and Context
Building and Deployment of Drupal sites with Features and ContextBuilding and Deployment of Drupal sites with Features and Context
Building and Deployment of Drupal sites with Features and Context
 
ASP.NET 8 Developer Roadmap By ScholarHat PDF
ASP.NET 8 Developer Roadmap By ScholarHat PDFASP.NET 8 Developer Roadmap By ScholarHat PDF
ASP.NET 8 Developer Roadmap By ScholarHat PDF
 
CODE IGNITER
CODE IGNITERCODE IGNITER
CODE IGNITER
 
What’s new in Rational collaborative lifecycle management 2011?
What’s new in Rational collaborative lifecycle management 2011?What’s new in Rational collaborative lifecycle management 2011?
What’s new in Rational collaborative lifecycle management 2011?
 
Ajax toolkit framework
Ajax toolkit frameworkAjax toolkit framework
Ajax toolkit framework
 
Chembience
ChembienceChembience
Chembience
 
report_vendor_connect
report_vendor_connectreport_vendor_connect
report_vendor_connect
 
Build Event-Driven Microservices with Confluent Cloud Workshop #1
Build Event-Driven Microservices with Confluent Cloud Workshop #1Build Event-Driven Microservices with Confluent Cloud Workshop #1
Build Event-Driven Microservices with Confluent Cloud Workshop #1
 
AWS Community Day Bangkok 2019 - Build a Serverless Web Application in 30 mins
AWS Community Day Bangkok 2019 - Build a Serverless Web Application in 30 minsAWS Community Day Bangkok 2019 - Build a Serverless Web Application in 30 mins
AWS Community Day Bangkok 2019 - Build a Serverless Web Application in 30 mins
 

More from CUBRID

The Architecture of CUBRID
The Architecture of CUBRIDThe Architecture of CUBRID
The Architecture of CUBRID
CUBRID
 
Installing CUBRID on Windows
Installing CUBRID on WindowsInstalling CUBRID on Windows
Installing CUBRID on Windows
CUBRID
 
Installing CUBRID on Linux
Installing CUBRID on LinuxInstalling CUBRID on Linux
Installing CUBRID on Linux
CUBRID
 
Cubrid Inside 5th Session 4 Replication
Cubrid Inside 5th Session 4 ReplicationCubrid Inside 5th Session 4 Replication
Cubrid Inside 5th Session 4 ReplicationCUBRID
 
Cubrid Inside 5th Session 3 Migration
Cubrid Inside 5th Session 3 MigrationCubrid Inside 5th Session 3 Migration
Cubrid Inside 5th Session 3 MigrationCUBRID
 
Cubrid Inside 5th Session 2 Ha Implementation
Cubrid Inside 5th Session 2 Ha ImplementationCubrid Inside 5th Session 2 Ha Implementation
Cubrid Inside 5th Session 2 Ha ImplementationCUBRID
 

More from CUBRID (6)

The Architecture of CUBRID
The Architecture of CUBRIDThe Architecture of CUBRID
The Architecture of CUBRID
 
Installing CUBRID on Windows
Installing CUBRID on WindowsInstalling CUBRID on Windows
Installing CUBRID on Windows
 
Installing CUBRID on Linux
Installing CUBRID on LinuxInstalling CUBRID on Linux
Installing CUBRID on Linux
 
Cubrid Inside 5th Session 4 Replication
Cubrid Inside 5th Session 4 ReplicationCubrid Inside 5th Session 4 Replication
Cubrid Inside 5th Session 4 Replication
 
Cubrid Inside 5th Session 3 Migration
Cubrid Inside 5th Session 3 MigrationCubrid Inside 5th Session 3 Migration
Cubrid Inside 5th Session 3 Migration
 
Cubrid Inside 5th Session 2 Ha Implementation
Cubrid Inside 5th Session 2 Ha ImplementationCubrid Inside 5th Session 2 Ha Implementation
Cubrid Inside 5th Session 2 Ha Implementation
 

Recently uploaded

Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
UiPathCommunity
 
Search and Society: Reimagining Information Access for Radical Futures
Search and Society: Reimagining Information Access for Radical FuturesSearch and Society: Reimagining Information Access for Radical Futures
Search and Society: Reimagining Information Access for Radical Futures
Bhaskar Mitra
 
How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...
Product School
 
"Impact of front-end architecture on development cost", Viktor Turskyi
"Impact of front-end architecture on development cost", Viktor Turskyi"Impact of front-end architecture on development cost", Viktor Turskyi
"Impact of front-end architecture on development cost", Viktor Turskyi
Fwdays
 
Essentials of Automations: Optimizing FME Workflows with Parameters
Essentials of Automations: Optimizing FME Workflows with ParametersEssentials of Automations: Optimizing FME Workflows with Parameters
Essentials of Automations: Optimizing FME Workflows with Parameters
Safe Software
 
ODC, Data Fabric and Architecture User Group
ODC, Data Fabric and Architecture User GroupODC, Data Fabric and Architecture User Group
ODC, Data Fabric and Architecture User Group
CatarinaPereira64715
 
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdfFIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance
 
IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptxIOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
Abida Shariff
 
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
Product School
 
Knowledge engineering: from people to machines and back
Knowledge engineering: from people to machines and backKnowledge engineering: from people to machines and back
Knowledge engineering: from people to machines and back
Elena Simperl
 
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
DanBrown980551
 
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
Tobias Schneck
 
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 previewState of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
Prayukth K V
 
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered QualitySoftware Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Inflectra
 
Leading Change strategies and insights for effective change management pdf 1.pdf
Leading Change strategies and insights for effective change management pdf 1.pdfLeading Change strategies and insights for effective change management pdf 1.pdf
Leading Change strategies and insights for effective change management pdf 1.pdf
OnBoard
 
Epistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI supportEpistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI support
Alan Dix
 
Bits & Pixels using AI for Good.........
Bits & Pixels using AI for Good.........Bits & Pixels using AI for Good.........
Bits & Pixels using AI for Good.........
Alison B. Lowndes
 
JMeter webinar - integration with InfluxDB and Grafana
JMeter webinar - integration with InfluxDB and GrafanaJMeter webinar - integration with InfluxDB and Grafana
JMeter webinar - integration with InfluxDB and Grafana
RTTS
 
Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...
Product School
 
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdfFIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance
 

Recently uploaded (20)

Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
 
Search and Society: Reimagining Information Access for Radical Futures
Search and Society: Reimagining Information Access for Radical FuturesSearch and Society: Reimagining Information Access for Radical Futures
Search and Society: Reimagining Information Access for Radical Futures
 
How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...
 
"Impact of front-end architecture on development cost", Viktor Turskyi
"Impact of front-end architecture on development cost", Viktor Turskyi"Impact of front-end architecture on development cost", Viktor Turskyi
"Impact of front-end architecture on development cost", Viktor Turskyi
 
Essentials of Automations: Optimizing FME Workflows with Parameters
Essentials of Automations: Optimizing FME Workflows with ParametersEssentials of Automations: Optimizing FME Workflows with Parameters
Essentials of Automations: Optimizing FME Workflows with Parameters
 
ODC, Data Fabric and Architecture User Group
ODC, Data Fabric and Architecture User GroupODC, Data Fabric and Architecture User Group
ODC, Data Fabric and Architecture User Group
 
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdfFIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
 
IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptxIOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
 
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
 
Knowledge engineering: from people to machines and back
Knowledge engineering: from people to machines and backKnowledge engineering: from people to machines and back
Knowledge engineering: from people to machines and back
 
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
 
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
 
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 previewState of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
 
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered QualitySoftware Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
 
Leading Change strategies and insights for effective change management pdf 1.pdf
Leading Change strategies and insights for effective change management pdf 1.pdfLeading Change strategies and insights for effective change management pdf 1.pdf
Leading Change strategies and insights for effective change management pdf 1.pdf
 
Epistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI supportEpistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI support
 
Bits & Pixels using AI for Good.........
Bits & Pixels using AI for Good.........Bits & Pixels using AI for Good.........
Bits & Pixels using AI for Good.........
 
JMeter webinar - integration with InfluxDB and Grafana
JMeter webinar - integration with InfluxDB and GrafanaJMeter webinar - integration with InfluxDB and Grafana
JMeter webinar - integration with InfluxDB and Grafana
 
Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...
 
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdfFIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
 

CUBRID Inside - Architecture, Source & Management Components

  • 1. CUBRID InsideFirst Look Inside CUBRID Jan 18, 2009
  • 2. 저작권 Copyright Notice CREATIVE COMMONS 저작자표시-동일조건변경허락 2.0 대한민국 이용자는 아래의 조건을 따르는 경우에 한하여 자유롭게 이 저작물을 복제, 배포, 전송, 전시, 공연 및 방송할 수 있습니다. 이차적 저작물을 작성할 수 있습니다. 다음과 같은 조건을 따라야 합니다: 저작자표시. 귀하는 원저작자를 표시하여야 합니다. What does "Attribute this work" mean? The page you came from contained embedded licensing metadata, including how the creator wishes to be attributed for re-use. You can use the HTML here to cite the work. Doing so will also include metadata on your page so that others can find the original work as well. 동일조건변경허락. 귀하가 이 저작물을 개작, 변형 또는 가공했을 경우에는, 이 저작물과 동일한 이용허락조건하에서만 배포할 수 있습니다. 귀하는, 이 저작물의 재이용이나 배포의 경우, 이 저작물에 적용된 이용허락조건을 명확하게 나타내어야 합니다. 저작권자로부터 별도의 허가를 받으면 이러한 조건들은 적용되지 않습니다. Nothing in this license impairs or restricts the author's moral rights. CREATIVE COMMONS Attribution-Share Alike 2.0 Korea You are free: to Share — to copy, distribute and transmit the work to Remix — to adapt the work Under the following conditions: Attribution. You must attribute the work in the manner specified by the author or licensor (but not in any way that suggests that they endorse you or your use of the work). What does "Attribute this work" mean? The page you came from contained embedded licensing metadata, including how the creator wishes to be attributed for re-use. You can use the HTML here to cite the work. Doing so will also include metadata on your page so that others can find the original work as well. Share Alike. If you alter, transform, or build upon this work, you may distribute the resulting work only under the same or similar license to this one. For any reuse or distribution, you must make clear to others the license terms of this work. The best way to do this is with a link to this web page. Any of the above conditions can be waived if you get permission from the copyright holder. Nothing in this license impairs or restricts the author's moral rights. http://creativecommons.org/licenses/by-sa/2.0/kr/ Copyright 2009 Search Solution Corporation. All Rights Reserved.
  • 4. Contents System Architecture and Processes Design & Implementation Concepts Module and Source Structure In The Next CUBRID Inside 4/ 41 First Look Inside CUBRID
  • 5.
  • 8. Query Processing WorkflowSystem Architecture and Processes 1 5/ 41 First Look Inside CUBRID
  • 9. System Architecture and ProcessesWhat is CUBRID? CUBRID is Open Source DBMS owned and developed by NHN Hosted at nForge site Targeted to a database platform for Internet portal service Relational database system with object extensions – Object-Relational Model 1,000,000 line of source code scaled project Engine – C/C++, CUBRID Manager (GUI) and JDBC driver – Java CUBRID provides Full-featured database server engine Server and Broker architecture GUI management and query tool CUBRID Manager Various API (JDBC, ODBC(OLE DB), PHP, and CCI) Python and Ruby as contributed projects 1.1 6/ 41 First Look Inside CUBRID
  • 10. System Architecture and ProcessesSystem Architecture 1.2 Server Subsystem Multi-threaded storage engine part which runs as DB server Consists of Transaction Manager, Object Manager, Lock Manager, Query Manager, Log Manager, and Storage Manager Client Subsystem Client library part providing native C API Consists of Query Parser & Optimizer, Object & Lock Cache, Transaction Manager and Object Manager Broker Subsystem Linked with client library and implemented CCI protocol Does job queuing, connection pooling, monitoring and logging Connectors JDBC driver CCI library Many drivers are implemented with CCI library – ODBC, OLEDB, PHP, Python, and Ruby 7/ 41 First Look Inside CUBRID
  • 11. System Architecture and ProcessesSystem Architecture 1.2 CUBRID Manager GUI Interface PHP OLE DB Ruby CUBRID Manager JDBC ODBC CCI Python CM Server Job Queuing Monitoring Connection Pooling Logging Admin Utility Broker Create, Delete, Copy, Rename Query Parser & Optimizer Lock Cache Object Manager Transaction Manager Add Volume Load / Unload Backup / Restore Query Manager Lock Manager Server Compact / Optimize Storage Manager Log Manager Check / Diag Active Log File Based Objects Data Volume Index Volume Temp Volume Archive Log 8/ 41 First Look Inside CUBRID
  • 12. 1.2 CUBRID Manager GUI Interface PHP OLE DB Ruby CUBRID Manager JDBC ODBC CCI Python CM Server Create, Delete, Copy, Rename Job Queuing Monitoring Connection Pooling Logging Admin Utility Broker Client Library Add Volume Native C API Parser Object Manager Schema Manager Transaction Manager Load / Unload Query Transform Workspace Manager Backup / Restore Query Optimizer Memory Manager Compact / Optimize Plan Generation Check / Diag Communication Module Storage Engine Server Communication Module Transaction Manager Log Manager Lock Manager Query Manager Access Method B+Tree Module File Manager System Catalog Module System Architecture Buffer Manager Disk Manager Active Log File Based Objects Data Volume Index Volume Temp Volume Archive Log 9/ 41 First Look Inside CUBRID
  • 13. System Architecture and ProcessesCUBRID Processes and IPC Master Process ‘cub_master’ Daemon process listening on the TCP port for clients’ connection csql, broker, and admin utilities Registrar of server processes using Unix Domain Socket Server Process ‘cub_server’ Multi-threaded process serving clients’ requests Has thread pool and job queue Accesses database volume and log files One server process per one database Broker Process ‘cub_broker’ Daemon process listening on the TCP port for connectors’ connection Controls cub_cas processes (fork/kill) with connection queue CAS Process ‘cub_cas’ Connects to the server process in behalf of connectors According to the database and user name CSQL Program ‘csql’ Interactive SQL execution 1.3 10/ 41 First Look Inside CUBRID
  • 14. System Architecture and ProcessesCUBRID Processes and IPC 1.3 JDBC driver CCI library connect query & result query & result port listening cub_broker cubrid_broker.conf fork parse descriptor pass AP Web Server cub_cas cub_cas shared memory cubridcs.so cubridcs.so csql connect cubridcs.so request & response request & response parse Broker TCP job queue multi-thread port listening descriptor pass parse cub_master cub_server cubrid.so cubrid.conf UDS Active Server Standby Server mount (read/write) read register volume file log file databases.txt volume file log file Replication cub_admin cubridsa.so 11/ 41 First Look Inside CUBRID
  • 15. System Architecture and ProcessesQuery Processing Workflow 1.4 12/ 41 First Look Inside CUBRID
  • 16. System Architecture and ProcessesQuery Processing Workflow 1.4 XASL Type UNION Extended Access Spec Language (XASL) DIFFERENCE INTERSECTION OBJFETCH Query Manager TransactionManager Lock Manager SETFETCH BUILD_LIST BUILD_VALUE Query Result Cache Query Plan Cache Query Evaluator (Interpreter) SCAN MERGE_LIST Scan Management READ UPDATE Storage Manager DELETE INSERT 13/ 41 First Look Inside CUBRID
  • 17.
  • 19. Representation, Record Descriptor, and Memory Object Pointer
  • 20. Workspace – Object & Lock Caching
  • 22. XASL (Extended Access Spec Language)
  • 24. Click Counter14/ 41 First Look Inside CUBRID
  • 25. Design & Implementation ConceptsClient-Server and Standalone Mode 2.1 15/ 41 First Look Inside CUBRID
  • 26. Design & Implementation ConceptsObject, Class and OID 2.2 16/ 41 First Look Inside CUBRID
  • 27. Design & Implementation ConceptsRepresentation, Record Descriptor, and Memory Object Pointer 2.3 17/ 41 First Look Inside CUBRID
  • 28. Design & Implementation ConceptsWorkspace – Object & Lock Caching 2.4 18/ 41 First Look Inside CUBRID
  • 29. Design & Implementation Concepts2PL vs. MVCC 2.5 19/ 41 First Look Inside CUBRID
  • 30. Design & Implementation ConceptsXASL (Extended Access Spec Language) 2.6 20/ 41 First Look Inside CUBRID
  • 31. Design & Implementation ConceptsHeap, B+tree, Catalog, and Temp 2.7 21/ 41 First Look Inside CUBRID
  • 32. Design & Implementation ConceptsClick Counter In Terms of User Whenever the user clicks an article, the read counter of the article is increased. Counts the clicks on the article In Terms of Service Application Developer The read counter is very important for bulletin board type service. Combine getting article data and increasing read counter together get_article() + increase_counter() = get_article_and_increase_counter() (SELECT article_info) + (UPDATE read_counter+1) In Terms of Database Engineer Do SELECT and UPDATE in one SQL statement SELECT trigger? SELECT FOR UDPATE? UPDATE the record with the short term lock Example SELECT doc_id, title, INCR(read_counter), post_date FROM board WHERE doc_id=? 2.8 22/ 41 First Look Inside CUBRID
  • 33. Design & Implementation ConceptsClick Counter 2.8 Don’t walk the same passage twice! When you get there, do as many things as possible. Killing two birds with one stone. 23/ 41 First Look Inside CUBRID
  • 34.
  • 40. Job and Thread Management Component
  • 42. Broker Component24/ 41 First Look Inside CUBRID
  • 43. Module and Source StructureOverall Structure 41 First Look Inside CUBRID 25/ 3.1 C API Transaction Management Common & Support Broker Job & Thread Management CCI Library Server Storage Management CUBRID Manager Query Processing Client-Server Comm PHP Connector Query Processing Native C API Query Processing Job & Thread Management Utilities Object Management Memory Manager JDBC Driver Client Storage Management Java Stored Procedure
  • 44. 41 First Look Inside CUBRID 26/ Module and Source Structure 3.1 src/ broker CUBRID Manager GUI PHP OLE DB Ruby JDBC ODBC CCI Python CM Server src/ query src/ storage src/ transaction src/ compat Create, Delete, Copy, Rename Job Queuing Monitoring Connection Pooling Logging Client Library Add Volume Native C API Parser Object Manager Schema Manager Transaction Manager Load / Unload Query Transform Workspace Manager Backup / Restore Query Optimizer Memory Manager Compact / Optimize Plan Generation Check / Diag Communication Module src/ cmserver src/ communication src/ jdbc src/ object src/ oledb src/ php src/ cci src/ odbc src/ optimizer src/ base src/ executables src/ heaplayers src/ parser src/ thread src/ connection Storage Engine Communication Module Transaction Manager Log Manager Lock Manager Query Manager Access Method B+Tree Module File Manager System Catalog Module Buffer Manager Disk Manager
  • 45. Module and Source StructureQuery Processing Component Scanner/Parser Parses query string and builds parse tree Uses ANTLR v1.x as parser generator Will be replaced with ‘bison’ at R2.0 Source files in src/parser Data structure: PT_PARSER, PT_NODE, … Semantic Checker Type check and binding, name resolution, semantic checking, view translation, and so on Source files in src/parser Parse tree traversing function: parser_walk_tree() Optimizer Rewrite optimization by heuristic rules Select a query execution plan by CBO (Cost Based Optimization) method Source files in src/parser and src/optimizer Data structure: QO_NODE, QO_PLANNER, … XASL Generator Generate XASL tree from the query execution plan XASL contains scan information (heap/index/list file/set/method scan), value list, and predicates Source files in src/parser Data structure: XASL_NODE, REGU_VARIABLE, … Query Manager (Executor) Executes XASL tree (XASL interpreter) Includes query evaluator, query plan cache, query result cache, query result file, and scan management Source files in src/query Main function: qexec_execute_mainblock() Cursor Manager Extracts tuple from the list file page shipped from the server Query Manager Source files in src/query 3.2 27/ 41 First Look Inside CUBRID
  • 46. Module and Source StructureQuery Processing Component 3.2 Object Management Component Broker Semantic Checker Scanner/Parser Optimizer XASL Generator Cursor Manager Client-Server Communication Layer Client-Server Communication Layer Server Query Plan/Result Cache Query Manager Transaction Management Component Query Evaluator (Interpreter) Storage Management Component (Server) Scan Management 28/ 41 First Look Inside CUBRID
  • 47. Module and Source StructureTransaction Management Component Transaction Manager Controls transaction – start, commit/abort, savepoint, and top operation Works tightly with lock and log manager Supports 2PC protocol for global transaction Initialize other related modules such as lock, log, and recovery manager Source files in src/transaction Data structure: LOG_TDES, TRANTABLE, … Object Locator Controls the flow of objects between the workspaces and the database pages Translates between memory representation and disk representation Caches objects from the server into the workspace with the granted locks Cached object and lock provides fast access to the objects and reduces interacting with the lock manager on the server Source files in src/transaction Lock Manager Based on strict 2PL protocol Includes support for OR feature class lock and instance lock Deadlock detector with WFG As separate thread Source files in src/transaction Data structure: LK_ENTRY, LK_TRAN_LOCK, … Log Manager Transaction logging and recovering REDO/UNDO recovery protocol WAL protocol Physical logging and logical logging Supports group commit and asynchronous commit feature Source files in src/transaciton Data structure: LOG_GLOBAL, LOG_HDRPAGE, LOG_PAGE, 3.3 29/ 41 First Look Inside CUBRID
  • 48. Module and Source StructureTransaction Management Component 3.3 Storage Management Component (Client) Object Management Component Transaction Manager (Client) Broker Object Locator (Client) Client-Server Communication Layer Client-Server Communication Layer Server Object Locator (Server) Lock Manager Transaction Manager (Server) Storage Management Component (Server) Log Manager 30/ 41 First Look Inside CUBRID
  • 49. Module and Source StructureServer Storage Management Component File I/O Manager Provides disk I/O access functions and implements file structure Coordinates the allocation and deallocation of unstructured files and pages File>Sector>Page File manager requests sectors from the disk manager Source files in src/storage Identifier: vdes, PAGEID Disk Manager Volume file management – implements volume structure in a OS file A volume corresponds to a singe file A set of contiguous pages of fixed size Source files in src/storage Identifier: volid Page Buffer Manager Data buffer pool with LRU replacement algorithm Uses buffer hash table and fix/unfix protocol (latch) Source files in src/storage Identifier: VPID Data structure: PGBUF_BUFFER_POOL Slotted Page Manager Manages insertions, deletions, and modifications of records on pages Each record has an associated slot identifier Source files in src/storage OID = (pageid, slotid, volid) Overflow File Manager Larger object than the size of a page is placed on overflow pages Source files in src/storage Object Heap Manager Inserts/deletes/updates objects within a file Permanent unchangeable OID is assigned to an object when it is stored on a heap Provides heap scan method (sequential scan) and direct fetch method An object heap holds the instances of one class Source files in src/storage Identifier: HFID B+-tree Manager Implements prefix B+-tree index with KVL Provides index scan method – unique find and range search 3.4 31/ 41 First Look Inside CUBRID
  • 50. Module and Source StructureServer Storage Management Component 3.4 Broker Client-Server Communication Layer Client-Server Communication Layer Server Query Processing Component (Server) Transaction Management Component (Server) Object Heap Manager B+-tree Manager Large Object Manager Extendible Hash Manager File Manager Slotted Page Manager Overflow File Manager Page Buffer Manager Catalog Manager Disk Manager I/O Manager 32/ 41 First Look Inside CUBRID
  • 51. Module and Source StructureClient Storage Management Component Workspace Manager Maintains a cache of database objects within the virtual memory address space of client process Maintains hash table that maps a OID into MOP MOP has OID field and a pointer to memory object Source files in src/object Quick Fit Allocator Memory manager for workspace Source files in src/object, src/base Garbage Collector To collect and free the unused(dangled) memory objects Normally GC is disabled Object and Lock Caching When the contents of object(s) is(are) required, the object locator is called to fetch the object(s) from the database via the server-side object locator The object locator translate the disk representation of the objet into the memory representation and allocates MOP to points it While accessing the object in the database, the requested lock is held by the lock manager in the server and the memory object has the cached lock mode The cached objects can be decached at any time when its state is not consistent with the disk objects, or will be decached at the time of transaction abort At the time of transaction commit, only the cached locks are released; objects remains with null lock 3.5 33/ 41 First Look Inside CUBRID
  • 52. Module and Source StructureClient Storage Management Component 3.5 Object Management Component Broker Garbage Collector Quick File Allocator Workspace Manager Transaction Management Component Object Locator (Client) Client-Server Communication Layer Client-Server Communication Layer Server 34/ 41 First Look Inside CUBRID
  • 53. Module and Source StructureObject Management Component Object Accessor Interface for object creation, deletion, inspection, and modification Source files in src/object Object Representation Transforms (or translates) between the disk representation and the memory representation of the object Resolves byte ordering also Source files in src/object, src/base Functions: or_xxx(), tf_mem_to_disk(), tf_disk_to_mem(), … Data Type and Domain Internal data structure for data type and domain Source files in src/object Data structure: TP_DOMAIN Sets Source files in src/object Data structure: SETOBJ, COL Schema Manager Implements OR model regarding database schema Definitions of the class object – attributes, method, class inheritance, and conflict resolution Memory representation of class object Source files in src/objet Data structure: SM_CLASS, SM_ATTRIBUTE, … Authentication and Authorization User authentication and database privilege User, GRANT, REVOKE, … Source files in src/object Trigger Manager Implements trigger feature Source files src/object Dynamic Loader Support dynamic loading of shared object as ‘method’ Depreciated feature Large Object Implements glo, elo, fbo classes and supporting methods Source files in src/object 3.6 35/ 41 First Look Inside CUBRID
  • 54. Module and Source StructureObject Management Component 3.6 Object Accessor Broker Schema Manager Authentication & Authorization Trigger Manager Set Dynamic Loader Data Type and Domain Object Representation Storage Management Component (Client) Client-Server Communication Layer Client-Server Communication Layer Server 36/ 41 First Look Inside CUBRID
  • 55. Module and Source StructureJob and Thread Management Component Connection Manager Connection establishment and management and request handler Source files in src/communication, src/connection Data structure: CSS_QUEUE_ENTRY, CSS_CONN_ENTRY, … Job Queue Master thread monitors socket fds (select()), receives clients’ request packet, en-queues it, and then wake up a worker thread in the thread pool Source files in src/connection Data structure: CSS_JOB_ENTRY, … Critical Section Implements semaphore Source files in src/thread System Threads Master thread Deadlock detection thread Run deadlock detection algorithm periodically Resolves deadlock by aborting unilaterally victim transaction(s) Checkpoint thread Executes periodic checkpoint action OOB handling thread Catch OOB signal Page flush thread Flushes dirty data buffer pages to the volume files in the background To reduce burden of page replacement Log flush thread Flushes dirty log buffer pages to the log file in the background Implements group commit and asynchronous commit features Source files in src/thread 3.7 37/ 41 First Look Inside CUBRID
  • 56. Module and Source StructureClient-Server Communication Layer Socket Transceiver Socket utility functions TCP/IP, Unix domain socket, and named pipe Source files in src/connection Linux and Windows port Packet Handler Sends requests and receives response between client and server Packet types: request packet, data packet, close packet, out-of-band packet, error packet, abort packet Packet format: packet header + payload Queuing request and data packets Source files in src/connection Communication Interface Layer RPC stub style functions Implements object serialization Source files in src/communication 3.8 38/ 41 First Look Inside CUBRID
  • 57. Module and Source StructureBroker Component Broker Process Accepts connection requests from the Connectors (JDBC, CCI, …) Allocates and/or assigns CAS process to the request Controls and monitors CAS processes Has four threads main: manages cas process receiver_thread: does accept() and enqueues new job dispatch_thread: dequeue job and assigns cas process cas_monitor_thread: monitors cas process to restart Source files in src/broker CAS Process Linked with CUBRID client library So, run as a single thread Receives and processes requests from the application(Connectors) Connect to database Prepare and execute query Fetch the result Commit/rollback transaction Get/set parameters Has four states IDLE: not connected with AP BUSY: processing request CLIENT_WAIT: connected and waiting for request; within a transaction CLOSE_WAIT: connected and waiting for request; out of a transaction Source files in src/broker 3.9 39/ 41 First Look Inside CUBRID
  • 58. In The Next CUBRID Inside 4 40/ 41 First Look Inside CUBRID
  • 59. In The Next CUBRID Inside 4 What topic do you want to see covered in the next CUBRID Inside? Suggesting Topics 41/ 41 First Look Inside CUBRID