...
- Some of the classes have been extended from external libraries into the Core APs
- Some of the files are too long
- Different levels of abstractions are mixed together
- Poor test coverage, lack of Test Driven Development
- Implicit (hidden) dependencies
Extending classes from external libraries into the core APIs
- Writing to implementations instead of interfaces
- Files too long
- Different levels of abstractions mixed together
- Poor test coverage, lack of TDD
- Implicit (hidden) dependencies (I dislike this the most)
Planning and Approach
The re-factor covers the whole OFBiz code base so we need a simple approach that makes it easy for people to pick up, re-factor and improve an area. This means that we probably wont be able to run it as a traditional linear project. Instead we will look to highlight areas of work where the community can help.
Main Approach
- Identify a list of 5 possible key re-factoring areas
- Ask the Community for volunteers to help re-factor in these 5 selected areas
- As one area is completed, top up the list of 5 with another area
Reasoning
- A short list of 5 is good number to highlight the key areas
- A list will help focus the community
Planning and Approach
- Include ideas for design philosophy (note from Taher)
- need to document our design philosophy for others to consider when writing code. I don't mean just formatting conventions but also things like writing to interfaces, TDD, design rules specific to OFBiz, and so on.
- Use of JIRA for tracking work - can use subtasks linked to one overall task ? Open a master issue with macro sub-task, linked to wiki for each conception detai
- People available to help
- Jacques, Taher, Nicolas, Julien, Gil, Sharan, ??? Hotwax team?
- Initial Approach
- Initial Deliverables
- Initial Milestones
- Milestone / Deliverable Planning and Tracking
- Scope
- Everything including core API interfaces ?? (Need to clarify this so it is totally clear - what does everything mean??)
- Initial Areas for Refactoring
- Initial ideas suggested by Taher.
Refactor Reason / Issue | |||||
---|---|---|---|---|---|
1 | EntitySaxReader | EntitySaxReader implements javolution interfaces and looks hideous | |||
2 | HtmlFormRenderer | HtmlFormRenderer is 3000 lines of code and the interfaces it implements are also huge | |||
3 | XmlFormRenderer | XmlFormRenderer does not implement more than half of the methods | |||
4 | Dependencies on Deprecated Classes / Constructors | Lots of dependencies on deprecated classes / constructors (e.g. HtmlScreenRenderer, FoScreenRenderer) | |||
5 | Start.java | Lots of dependencies on deprecated classes / constructors (e.g. HtmlScreenRenderer, FoScreenRenderer) | |||
6 | Implementations with no interfaces | Implementations with no interfaces (e.g. TemporalExpression, GroupModel, Cache, etc ...) | |||
...