DBDB.io The Encyclopedia of Database Systems · Est. 2017
Database of Databases

Database Entry

Cubrid


CUBRID is an open-source relational DBMS designed to optimize services in web.[05]

Source Code
https://github.com/CUBRID/cubrid[02]
Developer
Country of Origin
KR
Start Year
2008 [06]
Project Type
Open Source
Written in
C
Supported Languages
C, Java, JavaScript, Perl, PHP, Python, Ruby
Compatible With
MySQL
Operating Systems
Linux, Windows
Licenses
BSD License, GPL v2

Database Entry

Cubrid


CUBRID is an open-source relational DBMS designed to optimize services in web.[05]

History[06][07]


The CUBRID project started in South Korea in 2006, with NHN (later split into Naver Corporation and NHN Entertainment in 2013) as a major co-developer. In 2008, CUBRID version 1.1 (R1.1) was released as an open source project, later this version was re-named as 8.1.1. As of December 2018, CUBRID is ranked as the 65nd most popular relational DBMS by DB-Engines.

Checkpoints[08]


CUBRID allows user to configure checkpoint through two options: 1. Configure checkpoint trigger by log page size. Checkpoint will be triggered every time the transaction log size has reaches the set value. 2. Configure checkpoint tigger by time interval. Checkpoint runs in a periodical fashion. The default is 6 minutes. 3. Configure a slow data flush from the buffer to disk.

Concurrency Control[09][10]


Since v10.0, CUBRID moved from two phase locking protocol (2PL) to a Multiversion Concurrency Control (MVCC) protocol. The gain is mostly non-blocking reads for read intensive applications, typical in real-world use cases. This also grants point-in-time consistent view of the database, and reduction of performance costs compared to other concurrency protocols.

Data Model[05]


CUBRID is an object-relational database management system, that is, it is essentially similar to relational database, but also provides an object oriented database elements relations.

Foreign Keys[11]


CUBRID supports foreign key constraint, i.e. a set of columns that references the primary key in other tables. Users can also specify what action is triggered by update or delete of the primary key referenced. Options include:

  • CASCADE: deletes the foreign key when the associated the primary key got deleted.
  • SET NULL: updates the value of the foreign key to NULL when the corresponding record is deleted or updated.
  • RESTRICT: guarantees the primary key associated with this foreign key remains constant. Any transaction attempting to update or delete this primary key will be roll back.

Indexes[12][13]


CUBRID uses B-trees for indexes files. It supports the following types of indexes:

  • Indexes and unique indexes
  • Filtered index: used for creating indexes on a subset of rows in the table if certain criteria is met. The criteria is set by the user when creating this filtered index.
  • Function-based index: used for indexing rows based on a function accepting values in table rows as arguments. It is typically used for indexes created from complex conditions or calculations.

Isolation Levels[09][14]


CUBRID supports true snapshot isolation under the Multiversion Concurrency Control (MVCC) protocol. CUBRID provides 3 isolation levels: Serializable, Repeatable read, and Read committed, where Read commited is the default.

Joins[15]


CUBRID allows user to set optimization levels and get current query plan. Specifically for join methods, it supports nested loop join, sort merge join (turned off by default), and index nested loop join.

Logging[16]


CUBRID allows user to configure the frequency of logging and the life span of log archives. For example, user can set the size of log buffer cached in memory, and the maximum number of archive log files stored in disk. Archiving runs in the background by default.

Query Compilation[17][18][19]


CUBRID in general does not support query compilation. However, its PHP API (and PHP API only) provides a method which pre-compiles the SQL statement accepted, which can be used for re-executing the statement or effectively processing Long Data.

Query Interface[20][21][22][23][24]


CUBRID supports a wide range of SQL syntaxs. It also provides APIs in various languages with corresponding driver, e.g. JDBC Driver, PHP Driver, CCI Driver (C-based application), Perl Driver, Python Driver, etc. Additionally, user can also interact with CUBRID via its GUI-based program called CUBRID Manager.

Storage Architecture[25][26]


CUBRID is a disk-oriented database, memory is used for caching purposes. User can configure several disk-related parameters for database volumes and files, such as database volumn size and log volume size (both default to 512M), or the percentage of disk space allocated in a heap page for updates.

Storage Model[19][27]


As an object-relational database, CUBRID stores records as objects with an unique Object Identifier (OID). Insertions, deletions and modifications of records on pages are managed by the Slotted Page Manager, and large object which does not fit in a single page is placed on overflow pages managed by the Overflow File Manager.

Storage Organization


Stored Procedures[28]


CUBRID supports stored functions and procedures (via java) which enables complicated logic infeasiable otherwise through SQL. This functionality is turned off by default.

System Architecture[29][30]


CUBRID allows one master process for each host. It offers CUBRID High Availability (HA) which supports uninterrupted services under a hardware, software or network failure. It ensures database synchronization among multiple servers, and is implemented under shared-nothing architecture. Synchronization between an active server and a standby server is achieved through transaction log multiplexing and reflection.

Views[31]


CUBRID supports creation of views via statement CREATE VIEW. The virtual tables does not exist physically, but can be updatable if it satisfies some criteria.

Citations

31 sources
  1. CUBRID | Enterprise Open Source DBMS cubrid.org
  2. GitHub - CUBRID/cubrid: CUBRID is a comprehensive open source relational database management system highly optimized for Web Applications. · GitHub github.com
  3. CUBRID Foundation: Manuals cubrid.org
  4. CUBRID - Wikipedia wikipedia.org
  5. Introduction to CUBRID | CUBRID 10.1 User Manual cubrid.org
  6. Meet CUBRID: One of Korea’s Top Open Source Projects | Alolita Sharma technetra.com
  7. https://db-engines.com/en/ranking/relational+dbms db-engines.com Dead — Check Archive
  8. System Parameters | CUBRID 10.1 User Manual cubrid.org
  9. System Parameters | CUBRID 10.1 User Manual cubrid.org
  10. Database Transaction | CUBRID 10.1 User Manual cubrid.org
  11. TABLE DEFINITION STATEMENTS | CUBRID 10.1 User Manual cubrid.org
  12. Updating Statistics | CUBRID 10.1 User Manual cubrid.org
  13. INDEX DEFINITION STATEMENTS | CUBRID 10.1 User Manual cubrid.org
  14. Database Transaction | CUBRID 10.1 User Manual cubrid.org
  15. Updating Statistics | CUBRID 10.1 User Manual cubrid.org
  16. System Parameters | CUBRID 10.1 User Manual cubrid.org
  17. Introduction to CUBRID | CUBRID 10.1 User Manual cubrid.org
  18. PHP: cubrid_prepare - Manual php.net
  19. CUBRID Inside - Architecture, Source & Management Components | PPTX slideshare.net
  20. API Reference | CUBRID 10.1 User Manual cubrid.org
  21. CSQL Interpreter | CUBRID 10.1 User Manual cubrid.org
  22. CUBRID SQL | CUBRID 10.1 User Manual cubrid.org
  23. Query Tools | CUBRID 10.1 User Manual cubrid.org
  24. Query Tools | CUBRID 10.1 User Manual cubrid.org
  25. System Parameters | CUBRID 10.1 User Manual cubrid.org
  26. https://www.slideshare.net/cubrid/cubrid-inside-architecture-source-management-component slideshare.net Dead — Check Archive
  27. DZone: Programming & DevOps news, tutorials & tools dzone.com Dead — Check Archive
  28. Java Stored Function/Procedure | CUBRID 10.1 User Manual cubrid.org
  29. Introduction to CUBRID | CUBRID 10.1 User Manual cubrid.org
  30. CUBRID HA | CUBRID 10.1 User Manual cubrid.org
  31. VIEW DEFINITION STATEMENTS | CUBRID 10.1 User Manual cubrid.org
Revision #7 Last Updated: