Little Bobby Tables
Little Bobby Tables

Reputation: 4742

What is the correct term equivalent to "Thread Safe" but with respect to multiple database connections?

Assume you have two database connections. Each are currently open and performing reads and writes. They both read and write to some table entry at approximately the same time but the slightly later connection cannot write to/modify the table until the first connection has completed.

Is this simply another example of thread-safe (e.g. at the lower levels a thread is locked to prevent writing/mutation of memory)? Or is there another term for this?

My confusion probably comes from the fact that databases ultimately write to disk and not to memory. Therefore, I assume there is a different name for this. What is it? Thanks!

Upvotes: 0

Views: 33

Answers (1)

niKaragua
niKaragua

Reputation: 11

The concept of "Thread-safety" should not be applied to databases. Because it relates more to programming, to code related to the parallel execution of threads in the context of programming languages. It seems to me that it would be more accurate to say "database with concurrency control".

"Concurrency control is a concept in database management systems (DBMS) that enables multiple transactions to access or modify data simultaneously without incurring errors or inconsistencies." GeeksforGeeks

You can also learn more here:

Upvotes: 1

Related Questions