Data sharing in traditional file system vs dbms?

In summary, the conversation discusses the challenges of sharing data in TFS (Team Foundation Server) compared to DBMS (Database Management System). It is explained that TFS does not have the same atomic operation capability as DBMS, which can result in data being overwritten when multiple users are making changes. This makes data sharing more difficult in TFS.
  • #1
shivajikobardan
674
54
Homework Statement
Why is data sharing not possible in traditional file system(TFS) (vs DBMS)?
Relevant Equations
None
I know data is decentralized in TFS. But how does that makes data sharing difficult?
We've got distributed computing for the similar purpose on different machines as well.
I read a lot on this but failed to find any information regarding why it was not possible to share data in TFS as compared to DBMS? And why is it easy to share data in DBMS?
OXyqoVluQNQklwcHQr3XbhnrP2ZsvwAEVwe8FVOZJHwa8dLGyA.png

Source: Parteek Bhatia "Simplified Approach to DBMS"

According to this figure, I really don't see anything not offered in TFS that is offered in DBMS.
 
Physics news on Phys.org
  • #2
The DBMS will handle updates to the data insuring that no two entities can update and overwrites one anothers data.

As an example, you have a data record with a count. User A reads the count and adds one to it and then writes it back to the database. At the same time, User B reads the count, adds one and writes it back. You can see that its possible for User B to overwrite User A count increment.

A DBMS would use an atomic operation to increment the count meaning when run by User A the count is read and incremented in one operation. Hence User B is locked out and can't do the same until the User A operation completes.

With a shared filesystem its still possible for someone to read a file, make some changes and write it back while another user is reading the file making different changes and writing it back at a slightly later time

at t0 user A reads file X
at t1 user B reads file X
at t2 user A writes back changes X'
at t3 user B writes back changes X' --> X''

and so User A's changes X' are lost
 
  • Like
Likes shivajikobardan
Back
Top