All kinds of databases are used in the IT sector. Re­la­tion­al models are es­pe­cial­ly popular as they make it possible to connect in­for­ma­tion. There also other types, though, which provide special ad­van­tages and so might be a better choice in certain sit­u­a­tions: NoSQL databases, document-oriented databases, column-oriented databases or graph databases. There’s also the Key Value Database. Here, a simple principle brings about tremen­dous per­for­mance.

What is a Key Value Store?

Key Value Databases are based on a table with just two columns: In the first is the value, and the other contains a key, a distinct iden­ti­fi­ca­tion mark. A value can take different forms. Very simple values like strings or integers are possible, but complex objects can also come up as values in the database. (The function or the position of the value can also occupy a document, for example, although then we would be talking about a document-based database.) Ref­er­ences to files can also be inserted into the database. Tuples—col­lec­tions of values—are also prac­ti­ca­ble.

The values in a database don’t have to be uniform. It’s possible to ac­com­mo­date different objects in the same column. The same applies for the iden­ti­fi­ca­tion marks. In most cases, the key will pre­sum­ably follow a certain pattern. In principle, though, it isn’t necessary. Strings and integers can also be con­struct­ed according to arbitrary criteria here.

Fact

Key Value Stores appear as in-memory databases (that is, in the working memory) and as on-disk solutions (that is, in fixed-disk storage).

Ad­van­tages and ap­pli­ca­tions of Key Value Databases

The ad­van­tages of Key Value Databases are their high per­for­mance and flexible scal­a­bil­i­ty, both of which stem from the model’s simple structure. As Key Value Stores don’t require or stipulate any uniform pattern, changes to the database can be made while in operation. It’s possible to introduce a new field while actions are happening in other entries at the same time.

The high speed makes this database model possible through the simple con­nec­tion of key and value. If you want to retrieve in­for­ma­tion, you simply access the value directly via its specific key. The data is available directly. At the same time, though, this is a dis­ad­van­tage of the Key Value Store, as no other access method is available. Re­la­tion­al databases permit complex queries. The content of such databases can be sifted through in various aspects. In contrast, a Key Value Store only allows for access via the key. It’s generally necessary to do without further indices and search pos­si­bil­i­ties.

The ap­pli­ca­tions of Key Value Stores are based on both their ad­van­tages and their re­stric­tions. Key Value Databases are used whenever quick access times are needed for large quan­ti­ties of data. For this reason, typical ap­pli­ca­tions are shopping carts in online shops, or session data. Here, in­for­ma­tion is clearly ordered and must be available in the shortest possible time. For large, well-known websites, these databases must con­stant­ly create new entries and delete old ones, something that Key Value Databases are perfectly adapted to.

Well-known Key Value Databases

There are now various database man­age­ment systems (DBMS) that are based on Key Value Databases.

  • Amazon DynamoDB: The pro­pri­etary DBMS belongs to Amazon Web Services (AWS) and can also be used as a document-oriented database.
  • Berkeley DB: This DBMS is developed by Oracle and provides in­ter­faces for the most varied pro­gram­ming languages.
  • Redis: The open-source project Redis is one of the most-used DBMS and has already been used by Instagram and GitHub at an early stage.
  • Riak: The DBMS Riak is available as an open-source version, as en­ter­prise software, or in the form of cloud storage.
  • Voldemort: The dis­trib­uted DBMS is used and promoted by LinkedIn, among others.
Go to Main Menu