Mainframe COBOL to Java, C# & Cloud

Mainframe Modernization Strategy: Solutions for a Successful COBOL-to-Java and Cloud Migration

Whether the target is Amazon AWS, Microsoft Azure, a private cloud, or another platform, migrating mainframe applications to the cloud offers significant financial and operational advantages. This process, known as mainframe modernization, is increasingly being adopted due to several key factors: the long-term maintenance challenges of legacy mainframe applications, the high success rate of code-translation projects, and the decreasing costs of converting COBOL code into maintainable Java or C#.

One of the most resource-intensive aspects of refactoring or migration is the testing phase, ensuring that the new application maintains the same functionality as the original. This challenge exists whether the application is recompiled using a new compiler, such as Micro Focus, and rehosted on the cloud, or fully translated into a new programming language. Given the significant costs and efforts associated with testing, many organizations are opting for code translation, allowing them to transition to modern programming languages while ensuring long-term maintainability by a new generation of developers.


This paper focuses on a long-term solution that involves changing the codebase from COBOL to a cloud-friendly language/framework such as Java or C#. This approach offers the following benefits in the context of mainframe modernization:

To review other migration options, explore the Comparison of COBOL Migration Strategies, where you can delve deeper into the 5 R's of modernization approaches.


Essential Steps for Successful Mainframe Modernization:

Converting COBOL Code to Maintainable, Cloud-Friendly Java

The most cost-effective and low-risk approach to migrating from mainframe COBOL applications is leveraging a mature translator capable of producing maintainable and functionally correct Java or C# code. SoftwareMining achieves this by addressing 16 Essential Features for Successful COBOL-to-Java Conversion Projects within the context of mainframe modernization.


CICS Support in Refactored Java Applications

Java and C# Application Servers provide much of the functionality provided by CICS, vital for mainframe modernization. The COBOL Translator must be able to generate code which will utilize such features during the modernization process.
See Approach to Migration of CICS Cobol to Java / C#.


Converting BMS/MFS Screens to HTML (JSP)

The translation should support the conversion of BMS/MFS formats to HTML documents which utilize APIs provided by native languages such as JSP, Razor, or ASP. This is a critical step in mainframe modernization.

Furthermore, the generated code should use meaningful statements instead of legacy BMS statements. Many of the COBOL screen manipulation statements may be foreign to new developers, making this clarity essential for effective mainframe modernization.
For more detail please see converting legacy BMS operations to meaningful statements.


Data Migration: KSDS Indexed Files to SQL Database

While mainframe modernization efforts often involve moving COBOL applications to SQL databases, a significant number of applications still rely on KSDS files for their data storage needs. Addressing this aspect of data migration is an essential step in mainframe modernization.

SoftwareMining's conversion process is specifically designed to facilitate this critical aspect of mainframe modernization. It automatically handles the migration of VSAM/KSDS structures by generating representative SQL database schemas, thus streamlining the transition from legacy data structures to modern, scalable databases.

Meanwhile, the CICS API accessing the VSAM data is converted into Object-Relational designs that manage database access. For further information, please see Mainframe CICS VSAM to Java Conversion.

Additionally, as part of the mainframe modernization process, the data migration scripts provided by SoftwareMining are equipped to handle the conversion of character encoding from EBCDIC to ASCII, ensuring data integrity and compatibility in the new environment.


Messaging System Transition: From MQ Series to Java

Most legacy COBOL applications use a queueing framework for passing messages between modules. As a key aspect of mainframe modernization, once translated, during the testing phase the new system should be able to communicate with the legacy MQ Series.

Beyond the testing phase, the new application should be prepared to use any other commercial or Open-Source queueing system, enabling seamless integration and flexibility as part of the mainframe modernization process.

SoftwareMining's approach to mainframe modernization includes translating interfaces which allow implementations to communicate with any queueing system, ensuring adaptability and ease of integration in modernized applications.


JCL to Unix or Windows Shell Scripts

For successful mainframe modernization, it is crucial that JCL scripts are converted and are compatible with the cloud. A viable JCL solution needs to address a series of challenges, making the legacy JCL scripts comprehensible and functional for new developers.


Refactoring COBOL Applications with Embedded SQL for Modern Java Solutions

In mainframe modernization, the conversion of COBOL + EXEC SQL to Java / C# needs to change the dialect of SQL - from COBOL centric (using Host-Variables, Null-Indicators) to Java (using '?') or C# centric.

Additionally, for performance reasons, the converter will also need to try and reduce the amount of data-based communication, as these may have higher overheads on the Cloud.
There may also be performance issues when communicating between DB2 on mainframe and external Java/C# applications. For more information, see detecting cause of performance issues.


Migrating IMS and Other Data Files to SQL Databases

For some cases, such as IMS DB, the mainframe modernization process may require a separate stage by creating a "middle-data-access-layer".


Handling Assembler or Other Variants (e.g., Algol Code)

During mainframe modernization, Assembler programs should be reviewed on a case-by-case basis. In many instances, they can be replaced by Java and C# libraries, offering a richer framework and library set than COBOL.

For more detailed information about SoftwareMining's approach to mainframe modernization, including its CICS libraries, JCL solutions, and more, please refer to the respective sections.



Mainframe COBOL Migration Related Papers




  © 2025 SoftwareMining is a trademark of Software Modernization Technologies Ltd (UK). Registered in England company no: 07300248. Reg Offices: 79 Stevens House, Jerome Place, Kingston Upon Thames, KT1 1HX, United Kingdom.