...
- List all dependents of existing module interfaces
Identify and remove unused modules and classes with module dependencies.
Remove ReportServlet - FCREPO-646
Remove ThreadMonitor - FCREPO-647
Identify circular module dependencies (noted with
on above page).
Modify existing modules to accept
...
injected dependencies and config values
- Decouple module interface impl from Module abstract class where needed
- Push param validation responsibility down to each impl (not in Module)
- Use constructor injection if possible. For those with circular dependencies that can't be refactored easily, provide setters.
Original Module Class | Refactoring Needed |
---|---|
org.fcrepo.server.access.DefaultAccess | Add DefaultAccessModule: Construct and delegate calls to DefaultAccess |
.. |
|
Phase II - Swap
- Decide on DI framework
- Design and implement a way to deal with non-module configuration currently in fedora.fcfg (global configuration and datastores)
- Convert fcfg to DI configuration and update installer to populate it instead
- Trigger initialization of module singletons via DI framework in context initialization
- Use injected module dependencies wherever possible, avoiding use of Module and Server at runtime
...