news.volyx.in

Package managers keep using Git as a database, it never works out (nesbitt.io)

784 points by birdculture · 209 days ago · 465 comments on HN

Article summary

The article discusses how package managers often use Git as a database, but this approach can lead to problems as the registry grows, causing issues with performance, scalability, and maintainability. Several examples are given, including Cargo, Homebrew, CocoaPods, and vcpkg, which have all faced challenges with using Git as a database. These problems can be attributed to Git's design as a version control system, not a database. As a result, many package managers have had to implement workarounds or transition to alternative solutions.

Main themes

  • Git as a database
  • Package manager scalability
  • Performance issues
  • Database vs version control
  • Scalability limitations
  • Workarounds and alternatives

What commenters say

  • Using Git as a database is a fundamentally flawed approach that will inevitably lead to problems as the registry grows.
  • The problems with using Git as a database are not inherent to Git itself, but rather with the protocol and implementation used by GitHub.
  • Fixing problems as they appear is a reasonable and pragmatic approach, rather than trying to anticipate and solve all potential issues upfront.
  • The approach of doing the easy thing and fixing problems as they appear can be seen as unethical, as it can lead to critical infrastructure being built on unstable foundations.
  • The use of Git as a database is a temporary solution that can be sufficient for small-scale projects, but will need to be replaced as the project grows.
  • The idea that software engineers should anticipate and solve all potential problems upfront is unrealistic and ignores the complexities of real-world development.
  • The problems with using Git as a database are not unique to package managers, but are rather a symptom of a broader issue with using version control systems as databases.
  • The solution to the problems with using Git as a database is to use a proper database, which can provide the necessary scalability, performance, and maintainability.