Refactor Entity Registry Functions for Improved Maintainability #1
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The Addressed Issue:
The Entity Registry class contained several large, complex functions with deeply nested logic that were difficult to maintain, test, and understand. Specifically:
These complex and highly nested functions made it challenging for developers to understand the code flow at a glance, test individual pieces of logic in isolation and maintain the code when needed.
What I Have Engineered:
Reengineering Approach Used:
The Iterative Reengineering approach is used where the reengineering process is applied to the source code of a few functions at a time, ensuring continued system operation and preserving user familiarity. I focused on only 3 specific functions within the Entity Registry class while maintaining system operation with 100% backward compatibility and preserving user functionality by making no changes to the function signatures, parameters and return values.
Impact of Changes:
The positive impacts from this reengineering process are: