If we are already considering creating sub-modules, it may be a good time to consider splitting the code into top-level modules. These top-level modules can be put together as separate Julia packages.
Let's take a look at the benefits and potential issues for making new top-level modules:
The benefits of having separate top-level modules are as follows:
- Each package can have its own release life cycle and version. It is possible to make changes to a package and release only that portion.
- Version compatibility is enforced by Julia's Pkg system. A new version of the package may be released, and it may be used by another package as long as the package versions are compatible.
- Packages are more reusable because they can be utilized by other applications.
Potential issues with top-level modules are as follows:
- There is more management overhead because each package will be maintained and released independently.
- Deployment may be more difficult since multiple packages have to be installed and inter dependent packages must obey version compatibility requirements.