Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Architecture: missing isolation #56

Open
hsjobeki opened this issue Jul 14, 2023 · 1 comment
Open

Architecture: missing isolation #56

hsjobeki opened this issue Jul 14, 2023 · 1 comment

Comments

@hsjobeki
Copy link
Contributor

Its is currently very hard to take one module and re-use it in isolation.
For example if you just wanted to take the 'plock2pdefs' module you also have to import a lot of unrelated other modules.

This comes due to the fact that config in all modules is a global attribute. If you access any attribute other than your own you have an implicit dependency on another module. This breaks isolation of modules and even worse dependencies are not declared and the only way to find out via error-retry and code-studies.

We should de-couple modules and declare dependencies explicitly, such that you can only access attributes from explicitly declared modules.

I see the following action points:

  1. Detangle modules.
  2. Create stricter module interfaces. (where only explicitly imported modules config attributes are actually available, preventing implicity)
@aakropotkin
Copy link
Owner

I agree in retrospect these were aspects that I would design differently.

I started migrating several modules to lib to avoid these specific design flaws but plock2pdefs is necessarily going to be one of the last ones I can move because it depends on basically every other subsystem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants