This has the benefit that we can import both into other projects.
For example, I'm working on a test-helpers crate. And from this crate I want to use the tracker Configuration.
In the current state, this is impossible. Because if we want to use the Configuration struct, we would have to import it from the torrust-tracker crate. So we would have to add the torrust-tracker crate to the dependencies of the test-helpers crate and that would mean that we have a cyclic dependency (test-helpers <-> torrust-tracker). Not good!
To avoid this and similar issues, we must isolate code in their own crates as much as possible. This way we can easily selectively import code without running into a cyclic disaster.
This has the benefit that we can import both into other projects.
For example, I'm working on a test-helpers crate. And from this crate I want to use the tracker
Configuration.In the current state, this is impossible. Because if we want to use the
Configurationstruct, we would have to import it from thetorrust-trackercrate. So we would have to add thetorrust-trackercrate to the dependencies of thetest-helperscrate and that would mean that we have a cyclic dependency (test-helpers<->torrust-tracker). Not good!To avoid this and similar issues, we must isolate code in their own crates as much as possible. This way we can easily selectively import code without running into a cyclic disaster.