Introduction and classification of databases

Source: Internet
Author: User
Tags cassandra memcached

Directory

Database Introduction and Classification ... 1

1.1 Database Introduction ... 2

1.1.1 What is a database ... 2

1.2 Kinds of database ... 2

1.2.1-Relational Database Introduction ... 2

1.2.2 Non-relational database introduction ... 3

1.3 Common relational database product introduction ... 4

1.3.1 Oracle Database ... 4

1.3.2 MySQL Database ... 5

1.3.3 MARIADB Database ... 5

1.3.4 SQL Server Database ... 6

1.3.5 Access Database ... 6

1.3.6 other infrequently used databases ... 6

1.4 Common non-relational database product introduction ... 6

1.4.1 Memcached (key-value) ... 6

1.4.2 Redis (key-value) ... 7

1.4.3 MongoDB (document-oriented) ... 8

1.4.4 Cassandra (column-oriented) ... 8

1.4.5 other infrequently used non-relational databases ... 8

1.5 database-related knowledge ... 9

1.5.1 database software enterprise Application ranking Reference ... 9

1.1 Database Introduction1.1.1 What is a database

Simply put, the database is a repository of data, which is organized and stored according to a certain data structure (data structure refers to the organization or data), and we can manage the data in the database through various methods provided by the data.

When people collect a large amount of data, they should be saved up to the next step of processing, to further extract useful information. When people put data in the file cabinet, but now with the development of society, the volume of data has increased sharply, now people rely on computer and database technology science to save a lot of data, so as to better use these data resources.

1.2 Types of Databases

Database is usually divided into hierarchical database, network-type database and relational database three kinds. Different databases are linked and organized according to different data structures. In today's Internet, the most common database model is mainly two kinds, namely relational database and non-relational database.

Introduction to 1.2.1 relational database

(1), the origin of the relational database

Although the mesh database and the hierarchical database have well solved the problem of centralizing and sharing the data, there is a great lack of the database independence and abstraction level. When users access the two databases, they still need to define the storage structure of the data and indicate the access path. and the relational database can solve these problems better.

(2), relational database introduction

The relational database model boils down to a simple two-element relationship (i.e., a two-dimensional tabular form) of complex data structures. In the relational database, the operation of the data is almost entirely based on one or more relational tables, and the database is managed by the operation of the related table classification, merging, connecting, or selecting.

The relational database has been around for more than more than 40 years, from theoretical development to real-world products, such as Oracle and Mysql,oracle, which have risen to supremacy in the database sector, creating a huge industrial market of up to $ tens of billions of a year.

(3) Examples of relationships between relational database tables

Student table

School Number

Name

Age

S001

Tom

24

S002

John doe

25

S003

Wang er Leper

26

 

curriculum

Course number

credits

c001

linux

25

c002< /p>

python

25

c003

Choose a timetable

School Number

Course Number

Results

S001

C001

90

S002

C001

97

S003

C001

94

1.2.2 Non-relational database introduction 1.2.2.1 non-relational database birth background

NoSQL, which refers to non-relational databases. With the rise of internet web2.0 website, the traditional relational database in coping with web2.0 website, especially the web2.0 pure dynamic website of ultra-large-scale and high-concurrency SNS type, has been unable to overcome, exposing a lot of difficult problems, and the non-relational database has been developed very rapidly because of its own characteristics. NoSQL databases can play an unimaginable high efficiency and high performance in a given scenario, as an effective complement to traditional relational databases.

NoSQL (NoSQL = not-only sql), meaning "not just SQL," is a new revolutionary movement in the database, which was raised early on, and the trend grew even more in the 2009. NoSQL advocates are advocating the use of non-relational data storage, which is undoubtedly a new kind of thinking injection, relative to the overwhelming use of relational databases.

1.2.2.2 types of non-relational databases

(1), key-value Storage database (Key-value)

A key-value database is similar to a hash table used in traditional languages. The database can be added, queried, or deleted through key, because it is accessed with key primary key, so it is very high performance and scalability.

The key-value database uses a hash table that has a specific key and a pointer to the specific data. The advantage of the Key/value model for IT systems is simplicity, ease of deployment, and high concurrency.

Typical products: Memcached, Redis, Memcachedb

(2), column storage (column-oriented) database

A Columnstore database stores data in a column family, and a column family stores relevant data that is often queried together, such as humans, and we often query someone's name and age, not salary. In this case, the name and age will be placed in one column family, and the salary will be placed in the other column family.

This kind of database is often used to deal with distributed storage of massive data.

Typical products: Cassandra, HBase

(3), document-oriented (document-oriented) database

The document database is inspired by Lotus Notes Office software, and it is similar to the first key-value database. This type of data model is a versioned document, and semi-structured documents are stored in a specific format, such as JSON. A document database can be considered an upgraded version of a key-value database, allowing for the nesting of key values. and the document database is more efficient than the key-value database query.

Document-oriented databases store data as documents. Each document is a self-contained unit of data that is a collection of data items. Each data item has a noun and corresponding value, which can be either a simple data type, such as a string, a number, a date, or a complex type, such as a sequence table and an associated object. The smallest unit of data storage is a document, and document properties stored in the same table can be different, and data can be stored in many forms, such as XML, JSON, or JSONB.

Typical products: MongoDB, CouchDB

(4), graphic database

The graphics database allows us to store the data in a graphical way. Entities are treated as vertices, and relationships between entities are used as edges. For example, if we have three entities, Steve Jobs, Apple and next, there will be two "founded by" sides connecting Apple and next to Steve jobs.

Typical products: neo4j, Inforgrid

1.3 Common relational database product introduction1.3.1 Oracle Database

Oracle database system is one of the most popular client/server (client/server) or B/s architectures in the United States Oracle Corporation (Oracle) provides a distributed database-centric set of software products. For example, Silverstream is a database-based middleware. Oracle database is the most widely used database management system in the world, as a general database system, it has complete data management function; As a relational database, it is a complete relational product; It realizes distributed processing function as a distributed database. But all of its knowledge, as long as it learns Oracle knowledge on one model, can be used on all types of machines.

Oracle database 12c is the latest version. Oracle database introduces a new multi-tenant architecture that makes it easy to deploy and manage the database cloud. In addition, some of the innovative features maximize resource utilization and flexibility, such as Oracle Multitenant can quickly consolidate multiple databases, while automatic data optimization and heat map can compress and tier data at higher densities. These unique technological advancements, combined with major enhancements in availability, security, and big Data support, make Oracle database the ideal platform for private cloud and public cloud deployments.

1.3.2 MySQL Database

MySQL (pronounced "my ess cue el", not "my sequel") is an open source relational database management system (RDBMS), which uses the most common database management language-Structured Query Language (SQL) for database management.

Since MySQL is open source, anyone can download it under general Public License and modify it to suit your individual needs. MySQL is a concern for its speed, reliability and adaptability. Most people think that MySQL is the best choice for managing content without the need for transactional processing.

The name MySQL, the origin is not very clear. A more influential argument is that the basic guidelines and a large number of libraries and tools have been prefixed with "my" for more than 10 years, and anyway, the daughter of Monty Widenius, one of MySQL's founders, is also called My. Which of these two actually gives the name MySQL is still a mystery, including the developers.

1.3.3 MARIADB Database

MARIADB database management System is a branch of MySQL, mainly by the open source community in the maintenance, the use of GPL license. One of the reasons for developing this branch is that after Oracle acquired MySQL, there is a potential risk of shutting MySQL out of the source, so the community uses a branching approach to avoid this risk. MARIADB is designed to be fully compatible with MySQL, including APIs and command lines, making it easy to be a replacement for MySQL. For the storage engine, use XtraDB (English: XtraDB) instead of the MySQL InnoDB. MARIADB, led by MySQL's founder Michael Widenius (English: Michael Widenius), sold his company, MySQL AB, to Sun for $1 billion earlier, and since Sun was acquired by Oracle, MySQL's ownership also falls into Oracle's hands. Mariadb name comes from Michael Widenius's daughter Maria's name.

1.3.4 SQL Server Database

SQL Server, a relational database management system (DBMS) developed and promoted by Microsoft, was originally developed by Microsoft, Sybase, and ashton-tate three companies, and the first OS/2 version was introduced in 1988. Microsoft SQL Server has been updating its version in recent years, Microsoft introduced the SQL Server 6.5 version in 1996, 1998, SQL Server 7.0 version and user meeting; SQL Server 2000 was introduced in 2000 by Microsoft Corporation, and the latest version is SQL SERVER 2012, which was launched in March 2012.

1.3.5 Access database

Microsoft Office Access is a database management system that combines the graphical user interface of the database engine with the software development tools. It is a member of Microsoft Office and is sold separately in both professional and later versions of Office. December 4, 2012, the latest Microsoft Office Access 2013 was released in Microsoft Office 2013, and Microsoft Office Access 2010 was the previous version.

MS Access stores data in its own format in the Access jet-based database engine. It can also import or link data directly (this data is stored in other applications and databases).

Software developers and data architects can use Microsoft Access to develop application software that "advanced users" can use to build software applications. Like other Office applications, access supports the Visual Basic macro language, which is an object-oriented programming language that can reference a variety of objects, including DAO (data Access Objects), ActiveX Data Objects, and many other ActiveX components. Visual objects are used to display tables and reports, and their methods and properties are in a VBA programming environment where VBA code modules can declare and invoke Windows operating system functions.

1.3.6 Other infrequently used databases

Db2,postgresql,informix,syase and so on.

1.4 General Non-relational database product introduction1.4.1 Memcached (Key-value)

memcached is a distributed cache system, originally Danga Interactive for LiveJournal development, but is used by many software (such as MediaWiki). This is a set of open source software that is released under the BSD License licensing agreement. [1]

Memcached lacks authentication and security controls, which means that the memcached server should be placed behind a firewall. [1]

The Memcached API uses a 32-bit cyclic redundancy check (CRC-32) to calculate the key values and spread the data across different machines. When the table is full, the next additions will be replaced with the LRU mechanism. Since memcached is usually used only as a cache system, applications that use memcached will require additional code updates in memcached when writing back to a slower system (like a back-end database) [1]

Memcached is a software developed by Brad Fitzpatric, a Danga Interactive company in LiveJournal. has become an important factor in improving Web application extensibility in many services such as Mixi, Hatena, Facebook, Vox, and LiveJournal. Many Web applications save data to an RDBMS, where the application server reads the data and displays it in the browser. However, with the increase of data volume and the concentration of access, the burden of RDBMS, database response deterioration, site display delay and other significant impact.

This is the time to memcached. Memcached is a high-performance distributed memory cache server. The general purpose is to reduce the number of database accesses by caching database query results to improve the speed and scalability of dynamic Web applications.

The Memcached Daemon (daemon) is written in C, but the client can be written in any language and communicates with the daemon through the Memcached protocol. However, it does not provide redundancy (for example, copying its hashmap entries), and when a server S is stopped or crashed, all key/value pairs stored on s are lost.

Memcached was developed by Danga Interactive, and the latest version was released in 2010 by the author of Anatoly Vorobey and Brad Fitzpatrick. For lifting LiveJournal. COM access speed. LJ Dynamic page visits thousands of times per second, user 7 million. Memcached significantly reduces database load, better allocation of resources, faster access.

1.4.2 Redis (Key-value)

Redis is a key-value storage system. Similar to memcached, it supports storing more value types, including string (string), list (linked list), set (set), Zset (sorted set-ordered collection), and hash (hash type). These data types support Push/pop, Add/remove, and intersection-set and difference sets, and richer operations, and these operations are atomic. Based on this, Redis supports sorting in a variety of different ways. As with memcached, data is cached in memory to ensure efficiency. The difference is that Redis periodically writes the updated data to disk or writes the modified operation to the appended record file, and Master-slave (Master-Slave) synchronization is implemented on this basis.

Redis is a high-performance Key-value database. The emergence of Redis, to a large extent, compensates for the lack of memcached such key/value storage, in some cases can be a good complement to the relational database. It provides clients such as Java,c/c++,c#,php,javascript,perl,object-c,python,ruby,erlang, which is convenient to use. [1]

Redis supports master-slave synchronization. Data can be synchronized from the primary server to any number of slave servers, from the server to the primary server that is associated with other slave servers. This enables Redis to perform single-layer tree replication. The data can be written intentionally or unintentionally from the disk. Because of the full implementation of the publish/subscribe mechanism, you can subscribe to a channel and receive a complete message release record from the master server when the tree is synchronized anywhere from the database. Synchronization is helpful for the scalability and data redundancy of read operations.

1.4.3 MongoDB (document-oriented)

MongoDB is a database based on distributed file storage. Written by the C + + language. Designed to provide scalable, high-performance data storage solutions for Web applications.

MongoDB is a product between a relational database and a non-relational database, and is the most versatile and most like relational database in a non-relational database. The data structure he supports is very loose and is a JSON-like Bson format, so you can store more complex data types. MONGO's biggest feature is that the query language he supports is very powerful, and its syntax is a bit like an object-oriented query language that almost implements most of the functionality of a relational database single-table query, and also supports indexing of data.

1.4.4 Cassandra (column-oriented)

Cassandra is a hybrid non-relational database, similar to Google's bigtable. Its main function is richer than dynamo (distributed Key-value storage System), but the support is not as good as document storage MongoDB (open source product between relational database and non relational database, the most abundant function in non-relational database, most like relational database). The supported data structures are very loose and are JSON-like bjson formats, so you can store more complex data types. Cassandra was originally developed by Facebook and turned into an open source project. It is an ideal database for Internet social cloud computing. Based on Amazon's proprietary, fully distributed dynamo, the data model of Google BigTable is based on the column family (columns Family). Center-to-peer storage. Many aspects can be called Dynamo 2.0. [

1.4.5 other infrequently used non-relational databases

HBase, Memachedb, BerkeleyDB, Tokyo Cabinet

1.5 database-related knowledge1.5.1 database software enterprise application ranking reference

Introduction and classification of databases

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.