WRITELOOP

NOTES ON MONOREPOS

Monorepos have some benefits, which comes with some trade-offs. Here are some thoughts about it.

2022 September 1
  • Good for microservices.

  • Can help structuring a codebase’s architecture.

  • Agnostic to deployment architecture. (they do not enforce any particular architecture)

  • Can be useful to share dependencies, protocols, frameworks, etc.

  • You can share code/libraries with wheels (on multi/traditional repos) - or through the repository, using monorepos (it is easier to discover what depends on a library, and to test on all dependees at once)

  • You need build systems designed for monorepos (differently of Make, Tox, etc..). E.g. pants, bazel, buck - designed for python

  • monorepo build systems maintain the rule graph: the units of work and the dependencies between them. You can also have custom rules.

  • workflow = code dependencies + task dependencies

  • side-effect free, no global state

  • pants