PostgreSQL Ends the Waiting Game

This article takes a close-up look at how multi-version concurrency control cuts read-write waiting time in PostgreSQL.

provided by: 
Originally published at Internet.com


The Waiting ... Is the Hardest Part



Please wait ... and wait and wait again. One of the nagging problems many databases can't seem to shake is that at some point a user is going to have to wait while someone else updates the system. Whether the database system is using table-level, page-level, column-level, or row-level locking, the same problem arises: readers (SELECTs) wait for writers (UPDATEs) to finish, and writers (UPDATEs) wait for readers (SELECTs) to finish.

PostgreSQL, the open source database that is often compared to most advanced commercial databases, has a mechanism called MVCC (MultiVersion Concurrency Control). MVCC has the ability to perform row-level locking as well as lock rows for writing in one session while giving access to these rows unaffected in another session. It's been said that MySQL, a lightweight open source database, has a version of MVCC, but the two aren't really comparable since MySQL can do only table locking for reading. This is one of the many instances where PostgreSQL has the upper hand.

With PostgreSQL, readers never wait for writers, and writers never wait for readers. I can already hear the objections to the claim that there is no "no-locking" in PostgreSQL, so let me explain PostgreSQL's MVCC in further detail...

Read article at Internet.com site
Related Article
- Random Numbers and Tic Tac Toe with Visual Basic .NET
The holidays are a time for fun. Learn about random numbers from Paul Kimmel's latest Visual Basic Today column from CodeGuru.com. Includes a Tic Tac Toe game!
Regional Articles
- PostgreSQL Ends the Waiting Game Alabama
- PostgreSQL Ends the Waiting Game Alaska
- PostgreSQL Ends the Waiting Game Arizona
- PostgreSQL Ends the Waiting Game Arkansas
- PostgreSQL Ends the Waiting Game California
- PostgreSQL Ends the Waiting Game Colorado
- PostgreSQL Ends the Waiting Game Connecticut
- PostgreSQL Ends the Waiting Game DC
- PostgreSQL Ends the Waiting Game Delaware
- PostgreSQL Ends the Waiting Game Florida
- PostgreSQL Ends the Waiting Game Georgia
- PostgreSQL Ends the Waiting Game Hawaii
- PostgreSQL Ends the Waiting Game Idaho
- PostgreSQL Ends the Waiting Game Illinois
- PostgreSQL Ends the Waiting Game Indiana
- PostgreSQL Ends the Waiting Game Iowa
- PostgreSQL Ends the Waiting Game Kansas
- PostgreSQL Ends the Waiting Game Kentucky
- PostgreSQL Ends the Waiting Game Louisiana
- PostgreSQL Ends the Waiting Game Maine
- PostgreSQL Ends the Waiting Game Maryland
- PostgreSQL Ends the Waiting Game Massachusetts
- PostgreSQL Ends the Waiting Game Michigan
- PostgreSQL Ends the Waiting Game Minnesota
- PostgreSQL Ends the Waiting Game Mississippi
- PostgreSQL Ends the Waiting Game Missouri
- PostgreSQL Ends the Waiting Game Montana
- PostgreSQL Ends the Waiting Game Nebraska
- PostgreSQL Ends the Waiting Game Nevada
- PostgreSQL Ends the Waiting Game New Hampshire
- PostgreSQL Ends the Waiting Game New Jersey
- PostgreSQL Ends the Waiting Game New Mexico
- PostgreSQL Ends the Waiting Game New York
- PostgreSQL Ends the Waiting Game North Carolina
- PostgreSQL Ends the Waiting Game North Dakota
- PostgreSQL Ends the Waiting Game Ohio
- PostgreSQL Ends the Waiting Game Oklahoma
- PostgreSQL Ends the Waiting Game Oregon
- PostgreSQL Ends the Waiting Game Pennsylvania
- PostgreSQL Ends the Waiting Game Rhode Island
- PostgreSQL Ends the Waiting Game South Carolina
- PostgreSQL Ends the Waiting Game South Dakota
- PostgreSQL Ends the Waiting Game Tennessee
- PostgreSQL Ends the Waiting Game Texas
- PostgreSQL Ends the Waiting Game Utah
- PostgreSQL Ends the Waiting Game Vermont
- PostgreSQL Ends the Waiting Game Virginia
- PostgreSQL Ends the Waiting Game Washington
- PostgreSQL Ends the Waiting Game West Virginia
- PostgreSQL Ends the Waiting Game Wisconsin
- PostgreSQL Ends the Waiting Game Wyoming
Related Article
- Random Numbers and Tic Tac Toe with Visual Basic .NET
The holidays are a time for fun. Learn about random numbers from Paul Kimmel's latest Visual Basic Today column from CodeGuru.com. Includes a Tic Tac Toe game!

Rss   Delicious   Digg   Add To My Yahoo   Add To My Google   Bookmark   Search Plugin

Topics:
Architecture & Design Languages & Tools Project Management Web Services
Database Microsoft & .NET Security Wireless
Java Open Source Techniques XML