It is a visitor publish by Supreet Padhi, Expertise Architect, and Manasa Ramesh, Expertise Architect at Exactly in partnership with AWS.
Enterprises depend on mainframes to run mission-critical purposes and retailer important knowledge, enabling real-time operations that assist obtain enterprise aims. These organizations face a standard problem: learn how to unlock the worth of their mainframe knowledge in at present’s cloud-first world whereas sustaining system stability and knowledge high quality. Modernizing these programs is crucial for competitiveness and innovation.
The digital transformation crucial has made mainframe knowledge integration with cloud companies a strategic precedence for enterprises worldwide. Organizations that may seamlessly bridge their mainframe environments with fashionable cloud platforms acquire important aggressive benefits by improved agility, diminished operational prices, and enhanced analytics capabilities. Nonetheless, implementing such integrations presents distinctive technical challenges that require specialised options. Among the challenges embrace changing EBCDIC knowledge to ASCII, the place the dealing with of information varieties is exclusive to the mainframe, akin to binary knowledge and COMP knowledge. Knowledge saved in Digital Storage Entry Methodology (VSAM) information could be fairly advanced as a consequence of practices to retailer a number of totally different file varieties in a single file. To deal with these challenges, Exactly—a worldwide chief in knowledge integrity, serving over 12,000 prospects—has partnered with Amazon Net Providers (AWS) to allow real-time synchronization between mainframe programs and Amazon Relational Database Service (Amazon RDS). For extra on this collaboration, try our earlier weblog publish: Unlock Mainframe Knowledge with Exactly Join and Amazon Aurora.
On this publish, we introduce another structure to synchronize mainframe knowledge to the cloud utilizing Amazon Managed Streaming for Apache Kafka (Amazon MSK) for better flexibility and scalability. This event-driven method offers further potentialities for mainframe knowledge integration and modernization methods.
A key enhancement on this resolution is the usage of the AWS Mainframe Modernization – Knowledge Replication for IBM z/OS Amazon Machine Picture (AMI) out there in AWS Market, which simplifies deployment and reduces implementation time.
Actual-time processing and event-driven structure advantages
Actual-time processing makes knowledge actionable inside seconds somewhat than ready for batch processing cycles. For instance, monetary establishments akin to World Funds have leveraged this resolution to modernize mission-critical banking operations, together with funds processing. By migrating these operations to the AWS Cloud, they enhanced consumer expertise, improved scalability and maintainability, whereas enabling superior fraud detection – all with out impacting the efficiency of current mainframe programs. Change knowledge seize (CDC) permits this by figuring out database adjustments and delivering them in actual time to cloud environments.
CDC gives two key benefits for mainframe modernization:
- Incremental knowledge motion – Eliminates disruptive bulk extracts by streaming solely modified knowledge to cloud targets, minimizing system impression and guaranteeing knowledge foreign money
- Actual-time synchronization – Retains cloud purposes in sync with mainframe programs, enabling fast insights and responsive operations
Resolution overview
On this publish, we offer an in depth implementation information for streaming mainframe knowledge adjustments from DB2z by AWS Mainframe Modernization – Knowledge Replication for IBM z/OS AMI to Amazon MSK after which making use of these adjustments to Amazon Relational Database Service (Amazon RDS) for PostgreSQL utilizing MSK Join with the Confluent JDBC Sink Connector.
By introducing Amazon MSK into structure and streamlining deployment by the AWS Market AMI, we create new potentialities for knowledge distribution, transformation, and consumption that increase upon our beforehand demonstrated direct replication method. This streaming-based structure gives a number of further advantages:
- Simplified deployment – Speed up implementation utilizing the preconfigured AWS Market AMI
- Decoupled programs – Separate the priority of information extraction from knowledge consumption, permitting each side to scale independently
- Multi-consumer assist – Allow a number of downstream purposes and companies to devour the identical knowledge stream based on their very own necessities
- Extensibility – Create a basis that may be prolonged to assist further mainframe knowledge sources akin to IMS and VSAM, in addition to further AWS targets utilizing MSK Join sink connectors
The next diagram illustrates the answer structure.
- Seize/Writer – Join CDC Seize/Writer captures Db2 adjustments from Db2 logs utilizing IFI 306 Learn and communicates captured knowledge adjustments to a goal engine by TCP/IP.
- Controller Daemon – The Controller Daemon authenticates all connection requests, managing safe communication between the supply and goal environments.
- Apply Engine – The Apply Engine is a multifaceted and multifunctional element within the goal atmosphere. It receives the adjustments from the Writer agent and applies the modified knowledge to the goal Amazon MSK.
- Join CDC Single Message Remodel (SMT) – Performs all mandatory knowledge filtering, transformation, and augmentation required by the sink connector.
- JDBC Sink Connector – As knowledge arrives, an occasion of the JDBC Sink Connector together with Apache Kafka writes the information to focus on tables in Amazon RDS.
This structure offers a clear separation between the information seize course of and the information consumption course of, permitting every to scale independently. The usage of MSK as an middleman permits a number of programs to devour the identical knowledge stream, opening potentialities for advanced occasion processing, real-time analytics, and integration with different AWS companies.
Conditions
To finish the answer, you want the next stipulations:
- Set up AWS Mainframe Modernization – Knowledge Replication for IBM z/OS
- Have entry to Db2z on mainframe from AWS utilizing your authorized connectivity between AWS and your mainframe
Resolution walkthrough
The next code content material shouldn’t be deployed to manufacturing environments with out further safety testing.
Configure the AWS Mainframe Modernization Knowledge Replication with Exactly AMI on Amazon EC2
Comply with the steps outlined at Exactly AWS Mainframe Modernization Knowledge Replication. Upon the preliminary launch of the AMI, use the next command to hook up with the Amazon Elastic Compute Cloud (Amazon EC2) occasion:
Configure the serverless cluster
To create an Amazon Aurora PostgreSQL-Suitable Version Serverless v2 cluster, full the next steps:
- Create a DB cluster through the use of the next AWS Command Line Interface (AWS CLI) command. Substitute the placeholder strings with values that correspond to your cluster’s subnet and subnet group IDs.
- Confirm the standing of the cluster through the use of the next command:
- Add a author DB occasion to the Aurora cluster:
- Confirm the standing of the author occasion:
Create a database within the PostgreSQL cluster
After your Aurora Serverless v2 cluster is working, it’s worthwhile to create a database to your replicated mainframe knowledge. Comply with these steps:
- Set up the psql shopper:
- Retrieve the password from secret supervisor:
- Create a brand new database in PostgreSQL:
Configure the serverless MSK cluster
To create a serverless MSK cluster, full the next steps:
- Copy the next JSON and paste it into a brand new file
create-msk-serverless-cluster.json. Substitute the placeholder strings with values that correspond to your cluster’s subnet and safety group IDs. - Invoke the next AWS CLI command within the folder the place you saved the JSON file within the earlier step:
- Confirm cluster standing by invoking the next AWS CLI command:
- Get the bootstrap dealer deal with by invoking the next AWS CLI command:
- Outline the atmosphere variable to retailer the bootstrap servers of the MSK cluster and regionally set up Kafka within the path atmosphere variable:
Create a subject on the MSK cluster
To create a Kafka matter, it’s worthwhile to set up the Kafka CLI first. Comply with these steps:
- Obtain the binary distribution of Apache Kafka and extract the archive in folder
kafka: - To make use of IAM to authenticate with the MSK cluster, obtain the Amazon MSK Library for IAM and replica to the native Kafka library listing as proven within the following code. For full directions, check with Configure purchasers for IAM entry management.
- Within the listing, create a file to configure a Kafka shopper to make use of IAM authentication for the Kafka console producer and customers:
- Create the Kafka matter, which you outlined within the connector config:
Configure the MSK Join plugin
Subsequent, create a {custom} plugin out there within the AMI at /decide/exactly/di/packages/sqdata-msk_connect_1.0.1.zip which accommodates the next:
- JDBC Sink Connector from Confluent
- MSK Config supplier
- AWS Mainframe Modernization – Knowledge Repication for IBM z/OS Customized SMT
Comply with these steps:
- Invoke the next to add the .zip file to an S3 bucket to which you could have entry:
- Copy the next JSON and paste it into a brand new file
create-custom-plugin.json. Substitute the placeholder strings with values that correspond to your bucket. - Invoke the next AWS CLI command within the folder the place you saved the JSON file within the earlier step:
- Confirm plugin standing by invoking the next AWS CLI command:
Configure the JDBC Sink Connector
To configure the JDBC Sink Connector, observe these steps:
- Copy the next JSON and paste it into a brand new file
create-connector.json. Substitute the placeholder strings with acceptable values: - Invoke the next AWS CLI command within the folder the place you saved the JSON file within the earlier step:
- Confirm connector standing by invoking the next AWS CLI command:
Arrange Db2 Seize/Writer on Mainframe
To ascertain the Db2 Seize/Writer on the mainframe for capturing adjustments to the DEPT desk, observe these structured steps that construct upon our earlier weblog publish, Unlock Mainframe Knowledge with Exactly Join and Amazon Aurora:
- Put together the supply desk. Earlier than configuring the Seize/Writer, make sure the DEPT supply desk exists in your mainframe Db2 system. The desk definition ought to match the construction outlined at
$SQDATA_VAR_DIR/templates/dept.ddl. If it’s worthwhile to create this desk in your mainframe, use the DDL from this file as a reference to make sure compatibility with the replication course of. - Entry the Interactive System Productiveness Facility (ISPF) interface. Register to your mainframe system and entry the AWS Mainframe Modernization – Knowledge Repication for IBM z/OS ISPF panels by the equipped ISPF software menu. Choose choice 3 (CDC) to entry the CDC configuration panels, as demonstrated in our earlier weblog publish.
- Add supply tables for seize:
- From the CDC Main Choice Menu, select choice 2 (Outline Subscriptions).
- Select choice 1 (Outline Db2 Tables) so as to add supply tables.
- On the (Add DB2 Supply Desk to CAB File panel), enter a wildcard worth (%) or the particular desk identify
DEPTwithin the (Desk Identify) area. - Press Enter to show the checklist of obtainable tables.
- Kind
Ssubsequent to theDEPTdesk to pick out it for replication, then press Enter to substantiate.
This course of is just like the desk choice course of proven in determine 3 and determine 4 of our earlier publish however now focuses particularly on the DEPT desk construction.
With the completion of each the Db2 Seize/Writer setup on the mainframe and the AWS atmosphere configuration (Amazon MSK, Apply Engine, and MSK Join JDBC Sink Connector), you now have a totally useful pipeline able to seize knowledge adjustments from the mainframe and stream them to the MSK matter. Inserts, updates, or deletions to the DEPT desk on the mainframe shall be robotically captured and pushed to the MSK matter in close to actual time. From there, the MSK Join JDBC Sink Connector and the {custom} SMT will course of these messages and apply the adjustments to the PostgreSQL database on Amazon RDS, finishing the end-to-end replication move.
Configure Apply Engine for Amazon MSK integration
Configure the AWS facet elements to obtain knowledge from the mainframe and ahead it to Amazon MSK. Comply with these steps to outline and handle a brand new CDC pipeline from DB2 z/OS to Amazon MSK:
- Use the next command to modify to the
joinconsumer: - Create the apply engine directories:
- Copy the pattern script from
dept.ddl: - Copy the next content material and paste it in a brand new file
$SQDATA_VAR_DIR/apply/DB2ZTOMSK/scripts/DB2ZTOMSK.sqd. Substitute the placeholder strings with values that correspond to the DB2z endpoint: - Create the working listing:
- Add the next to
$SQDATA_DAEMON_DIR/cfg/sqdagents.cfg: - After the previous code is added to the
sqdagents.cfgpart, reload for the adjustments to take impact: - Validate the apply engine job script through the use of the SQData parse command to create the compiled file anticipated by the SQData engine:
The next is an instance of the output that you simply get while you invoke the command efficiently:
- Copy the next content material and paste it in a brand new file
/var/exactly/di/sqdata_logs/apply/DB2ZTOMSK/sqdata_kafka_producer.conf. Substitute the placeholder strings with values that correspond to your bootstrap server and AWS Area. - Begin the apply engine utilizing the controller daemon through the use of the next command:
- Monitor the apply engine by the controller daemon through the use of the next command:
The next is an instance of the output that you simply get while you invoke the command efficiently:
Logs can be discovered at
/var/exactly/di/sqdata_logs/apply/DB2ZTOMSK.
Confirm knowledge within the MSK matter
Invoke the Kafka CLI command to confirm the JSON knowledge within the MSK matter:
Confirm knowledge within the PostgreSQL database
Invoke the next command to confirm the information within the PostgreSQL database:
With these steps accomplished, you’ve efficiently arrange end-to-end knowledge replication from DB2z to RDS for PostgreSQL, utilizing AWS Mainframe Modernization – Knowledge Replication for IBM z/OS AMI, Amazon MSK, MSK Join, and the Confluent JDBC Sink Connector.
Cleanup
Once you’re completed testing this resolution, you may clear up the sources to keep away from incurring further expenses. Comply with these steps in sequence to make sure correct cleanup.
Step 1: Delete the MSK Join elements
Comply with these steps:
- Checklist current connectors:
- Delete the sink connector:
- Checklist {custom} plugins:
- Delete the {custom} plugin:
Step 2: Delete the MSK cluster
Comply with these steps:
- Checklist MSK clusters:
- Delete the MSK serverless cluster:
Step 3: Delete the Aurora sources
Comply with these steps:
- Delete the Aurora DB occasion:
- Delete the Aurora DB cluster:
Conclusion
By capturing modified knowledge from DB2z and streaming it to AWS targets, organizations can modernize their legacy mainframe knowledge shops, enabling operational insights and AI initiatives. Companies can use this resolution to reap the benefits of cloud-based purposes with mainframe knowledge to offer scalability, cost-efficiency, and enhanced efficiency.
The combination of AWS Mainframe Modernization – Knowledge Replication for IBM z/OS AMI with Amazon MSK and RDS for PostgreSQL offers an enhanced framework for real-time knowledge synchronization that maintains knowledge integrity. This structure could be prolonged to assist further mainframe knowledge sources akin to VSAM and IMS, in addition to different AWS targets. Organizations can then tailor their knowledge integration technique to particular enterprise wants. Knowledge consistency and latency challenges could be successfully managed by AWS and Exactly’s monitoring capabilities. By adopting this structure, organizations hold their mainframe knowledge regularly out there for analytics, machine studying (ML), and different superior purposes.Streaming mainframe knowledge to AWS in close to actual time represents a strategic step towards modernizing legacy programs whereas unlocking new alternatives for innovation, with knowledge transfers occurring in subseconds. With Exactly and AWS, organizations can successfully navigate their modernization journey and keep their aggressive benefit.
Study extra about AWS Mainframe Modernization – Knowledge Replication for IBM z/OS AMI within the Exactly documentation. AWS Mainframe Modernization Knowledge Replication is offered for buy in AWS Market. For extra details about the answer or to see an illustration, contact Exactly.

