What Is a Distributed Version Control System (DVCS)?
Distributed Version Control System is a type of Version Control System which is used in software development that brings a local copy of the complete repository to every team member’s computer. The entire codebase and the project history is mirrored on every developer’s computer in the team. After this the developers can then commit, branch and merge locally, this improves the ability to work offline. This eliminates the need to rely on a single server for backups. Git is one of the most used and famous DVCS. Other than Git there are other DVCS like : Mercurial, and Bazaar.
The Evolution of Distributed Version Control Systems.
2000- BitKeeper : It was originally released as proprietary software. It was used in the development of the Linux kernel from 2002 to 2005. BitKeeper ended the ‘Free Use’ support in 2005 and started asking users to switch to the commercial version. In 2016 it was released as open-source software under the Apache License 2.0. BitKeeper is no longer developed.
2001 - GNU Arch : It is said to be one of the first free open source distributed version control systems that was part of the GNU project. It was created by Thomas Lord. But soon after it launched it got deprecated after receiving a lot of criticism mainly because it was difficult to learn and use.
2005 - Git : After BitKeeper becoming a proprietary version control system many developers stopped using it and then Git was created, a free open source distributed version control system developed by Linus Trovals to continue working on the Linux Kernel.
Now in 2021 it is one of the most used and famous DVCS.
2005 - Mercurial : It was also originally created to replace BitKeeper for developing Linux Kernel. But the team decided to go with Git instead of Mercurial. Although Mercurial was not selected to manage the Linux kernel sources, it has been adopted by several organizations, including Facebook, the W3C, and Mozilla.
2007 - Bazaar : It is a distributed and client–server revision control system which is free software, part of the GNU Project and sponsored by Canonical. It was originally authored by Martin Pool and then developed by Canonical and community.
Limitations of the DVCS Model.
With all the advantages that the DVCS model provides there are still a few limitations and disadvantages of it.
- Suppose if a project is very large and contains a lot of big binary files in that case, downloading the entire project in DVCS can take more time and space than usual.
- Another problem with DVCS is that there is no ‘Latest Release’ as such. Every developer is working on a new feature on their copy of the repository so getting to know which copy is the most recent one is tough.
- The recent concern in the DVCS is related with Security of the project. Giving developers access to have a copy of the entire codebase of the software project on their systems locally might lead to risk of attacks.
Why Companies Switch to Distributed Version Control System (DVCS) instead of CVCS?
The Centralized Version Control System is based on the client server approach where the server is the master repository that contains all of the versions of the code. Now you will be committing and merging your changes directly to the master/main branch making everything centralized. There will be just one repository and that will contain all the history or version of the code. But CVCS will have various disadvantages coming along with it, which are then overcome by the DVCS such as :
- If the main server goes down then the entire project is at a stand by and in jeopardy making the project backup and its history unavailable. But this will not happen in DVCS as every developer has his or her local copy of the source code.
- The chances of merge conflicts occurring in CVCS are more when compared to DVCS. That is because all the code is getting committed into the same repository and in the same branch. Whereas in the DVCS merge conflicts with other developer’s code are less because every developer works on their own piece of code.
- As the system in CVCS requires a remote server communication all the time therefore the code cannot be quickly merged. Also the CVCS doesn’t allow teams to use different branching strategies, which is a core foundation of DVCS.
These are just a few reasons why Companies are Switching to Distributed Version Control System (DVCS) instead of CVCS.