What is the purpose of refactoring mainframe code before implementing it as modular services?
Select an answer to reveal the explanation.
Short Explanation
You refactor mainframe code to isolate cohesive business capabilities first, so the later split into services is clean and meaningful.
Full Explanation
Refactoring mainframe code before modular services is meant to isolate cohesive business capabilities within the existing code so they are ready to be implemented as separate, well-bounded services. This makes eventual service boundaries meaningful, rather than arbitrary splits of existing code. Reducing the total number of files in the codebase is not the goal; cohesion is. Creating a separate service for every copybook referenced anywhere in the application is wrong because it ignores whether that copybook maps to one coherent capability. Rewriting the application without reviewing dependencies between components first is wrong because skipping dependency review is what causes boundaries to be drawn incorrectly. For the exam, describe refactoring's purpose as preparing cohesive capabilities, not shrinking the codebase.