Canada Revenue Agency Helpdesk: IBM COBOL to Java on AWS
How TSRI and AWS modernized the CRA Helpdesk application, from mainframe COBOL, CICS and green screens to cloud-native Java, Angular and PostgreSQL, transforming all source code in under three days.
Executive summary
Mainframe to the cloud
CRA and AWS engaged TSRI to modernize CRA’s COBOL-based system to Java on AWS. TSRI tuned its Janus Studio® transformation engine to parse, document, transform and refactor the IBM z/OS COBOL application.
TSRI modernized and refactored the CRA Helpdesk application from a monolithic IBM mainframe COBOL and CICS application to a modern, multi-tier Java architecture. All BMS green screens were automatically transformed to Angular web screens, a REST layer was introduced, and DB2 and VSAM sequential files were converted to PostgreSQL on Amazon Aurora.
TSRI then completed integration and testing and deployed the containerized application on AWS.
01 · Challenge
Two problems that felt insurmountable
The Canada Revenue Agency (CRA), Canada’s tax collection and enforcement agency, faced two key problems: operational costs to maintain its mainframe systems had spiraled out of control, and finding people to keep programming the agency’s legacy applications had become harder with each passing year.
CRA had been planning mainframe modernization for its IBM portfolio for some time, but a high-risk COTS replacement or manual rewrite could take many years and carry a high risk of failure. To reduce operating costs, find and retain people with the right skills, and be more agile, it needed to modernize its COBOL, JCL, user interface and DB2 database.
02 · Selection
Why AWS and CRA chose TSRI
Before launching a full project, CRA and AWS needed proof that automated modernization would accelerate migration off the mainframe and lower risk. CRA investigated multiple migration patterns (rewrite, rehost, replatform, lift-and-shift and COTS replacement) and reviewed multiple modernization vendors.
CRA chose TSRI in part because TSRI was a 2021 launch partner for the AWS Mainframe Modernization competency, for its unique refactoring capability, and for its ability to modernize COBOL, JCL, DB2 and VSAM, and BMS green screens to Java, Python and an Angular web front end.
This team effort used AWS Migration Acceleration Program (MAP) funding, TSRI’s Mainframe Modernization Competency, and AWS ProServe and CRA resources.
MAP: Assess, Mobilize, Migrate & Modernize
Funding and resources from AWS
Janus Studio® tuned for CRA
Reusable for future CRA projects
03 · Approach
Compiling Java in days, not years
TSRI tuned Janus Studio® specifically for CRA before any code was modernized. Within the first 3 days, TSRI had modeled and transformed all code to compiling Java; on day 10 it delivered an Application Blueprint® documenting the legacy Helpdesk application in fully linked hypertext.
How the project ran
- 01 · DAY 3
Compiling Java
All COBOL modeled and transformed
- 02 · DAY 10
Application Blueprint®
Fully linked legacy documentation
- 03 · DATA
Schema & ETL
PostgreSQL schema, test data loaded
- 04 · DAYS
Frameworks on AWS
Deployed to the AWS landing zone
- 05 · REFACTOR
SonarQube-guided
Automated and customer-driven
What changed, layer by layer
Blueprints that cover the whole system
The Application Blueprint® covered not just the COBOL code, but the CICS interfaces, externals, hundreds of screens and connected utilities. A Transformation Blueprint® showed the modernized Java codebase and how DB2 and VSAM data would move to PostgreSQL through TSRI’s dual database layer.
04 · Architecture
CRA Helpdesk on AWS
The modernized solution was containerized and deployed on the provided AWS landing zone with native AWS services and the TSRI framework. All code, including the framework, was delivered as source code, with a code warranty and no license fees.
Wrapping CICS for the cloud
A CICS gateway lets many transactions run at once, essential for an agency that handles thousands of transactions a day and millions around late April and quarterly corporate tax deadlines. TSRI built a REST interface around the CICS interfaces, separating the presentation layer from the container layer so the application can scale through peak periods on AWS’s Well-Architected model.
Working through pandemic constraints
COVID-19 delayed some materials TSRI needed, and subject-matter experts weren’t always available to explain screen-by-screen flow, which slowed validation across hundreds of BMS screens. Limited access to highly secure areas created further hurdles, which TSRI worked around.
05 · Refactoring
From functional equivalence to high-quality code
After reaching functional equivalence, TSRI used fully automated, semi-automated and customer-driven refactoring to meet CRA code specifications and a target SonarQube quality score: removing dead code, consolidating similar records and code, adapting the package structure, and remediating SonarQube issues. CRA supplied updated legacy baselines instead of freezing code.
COBOL to Java
All mainframe source transformed in less than 3 days.
From thousands of issues
All latent defects in replacement services and CICS implementations, and all remedied.
Transformation-related
Across the full transformation.
Lower annual TCO
From the AWS business case, once the full mainframe architecture is migrated.
06 · Results
On time, on budget, and ready to scale
With AWS MAP funding, CRA, TSRI and AWS completed the project on time and within budget. The code and data transformation took about three weeks; the rest of the schedule went to externals and utilities, testing, integration, deployment and customer-driven refactoring. TSRI and AWS are now working with CRA to apply the same tuned rules to the rest of its application portfolio.