This chapter takes you step by step through the process of configuring an enterprise server to run IMS applications, and then building and running an IMS application. This is intended both as an introduction to using IMS in Mainframe Transaction Option (MTO), and as an Installation Verification Procedure (IVP) to confirm that the IMS support is correctly installed.
The IVP is based around a demonstration program called Mfdemo, which is installed into $COBDIR/demo/MTO-IMS/IVP by default. Mfdemo is a system for capturing and maintaining table data. The tables are organized by table element within table name. The tables eliminate the program maintenance associated with traditional Data Division tables. The following source members are used by this application:
This section describes the steps you need to perform before you can run the IVP. These steps are split into three sections:
Although the Mfdemo application is supplied with Server Express, you need to perform a number of operations on the source files before you can run it. These operations are:
These operations are defined in the following sections.
To compile the COBOL programs that comprise the Mfdemo application:
cobol demo001b dialect(vsc24) noflag anim noobj charset(ascii) outdd"sysout 121 r e"; cobol cdlidemo dialect(mf) osvs cicsecm noflag charset(ascii) anim noobj; cobol execdemo dialect(mf) cicsecm execdli noflag charset(ascii) anim noobj; cobol demo001t dialect(vsc24) noflag charset(ascii) anim noobj; cobol rghtjust dialect(mf) charset(ascii) anim noobj;
This creates an intermediate code (.int) and dictionary (.idy) file for each COBOL program.
Mfdemo includes three MFS files (demo90.mfs, demo91.mfs and demo92.mfs) that you need to generate. To generate theses MFSs:
mfims mfsgen demo90.mfs nocls mfims mfsgen demo91.mfs nocls mfims mfsgen demo92.mfs nocls
Note: Because you are generating all of the MFSs in the current folder you could have used the Windows for command to simplify this operation:
for %i in (*.mfs) do mfims mfsgen %i nocls
In addition to the .mid, .mod, .dif and .dof files, generating the MFSs produces imsconfg.dat and imsconfg.idx. These files contain system configuration data and must not be edited, moved or deleted.
Mfdemo includes one DBD file (demo03dd.dbd) that you need to generate. To generate the DBD:
mfims dbdgen demo03dd.dbd nocls echo(enderr,0,50)
Creating the DBD gens produces the following files:
Note: If dbdgen2.dat does not exist when you generate a DBD you see message DBDUT0U35U ("File not found DBDGEN2.DAT"). This message is for information only, and dbdgen2.dat is created.
These files contain DBD source information that has been extracted and formatted into a smaller structure optimized for faster access during execution. These files are indexed files and can contain information for one or more generated DBD members. Do not edit, move or delete these files.
Once you have generated the DBD you need to generate the PSB. To generate Mfdemo's single PSB file (demo001t.psb):
mfims psbgen demo001t.psb nocls echo(enderr,0,50)
Generating the PSB produces the following file:
Note: If psbgen3.dat does not exist when you generate a PSB you see message DBDUT0U35U ("File not found PSBGEN3.DAT"). This message is for information only, and psbgen3.dat is created.
These files contain PSB source information that has been extracted and formatted into a smaller structure optimized for faster access during execution. These files are indexed files and can contain one or more generated PSB members. Do not edit, move or delete these files.
Next you need to load the databases that Mfdemo uses.
mfims imsdbu load demo03dd nocls
IMS support includes two new transactions, /CIC and /IMS, that you use to switch enterprise servers to CICS and IMS modes respectively. In order for these new transactions to be available you need to update your resource definition file using the caspcupg command as follows:
caspcupg
See the section Adding IMS-specific Resource Definitions in the chapter Configuring MTO-enabled Enterprise Servers for IMS in your Mainframe Transaction Option Configuration and Administration Guide for more information on the caspcupg command.
To enable IMS support in an enterprise server, you need to:
The sections below walk you through these tasks.
To create an MTO-enabled enterprise server:
To enable IMS support for the IMSIVP enterprise server:
This specifies that the IMSIVP enterprise server can use the IMS support. Don't click Apply yet as there is more to do on this page.
You need to specify the directory where the files produced by DBDGENs, IMSGENs, MFSGENs and PSBGENs are created, and where the application and database files are located.
JCL support is required for any IMS-enabled enterprise server that needs a message processing region to start whenever the enterprise server starts. You will define such a message processing region later, so you need to enable JCL support for IMSIVP.
To enable JCL support for the IMSIVP enterprise server:
You have now created the IMSIVP enterprise server and enabled it to use IMS and JCL, but you now need to specify that it uses a CICS SIT. You need to specify a SIT even though Mfdemo does not contain any CICS for two reasons:
To specify that the IMSIVP enterprise server uses the supplied SIT IMSSIT:
To run an IMS application in an enterprise server you need at least one specialized service execution process (SEP) called a message processing region (MPR). To specify that a message processing region starts each time an enterprise server starts you need to in a resource group that is specified by the startup list in the SIT used by the enterprise server.
In the section Specifying the SIT you specified that the IMSIVP enterprise server uses IMSSIT. IMSSIT specifies the IMSSTRT startup list, and the IMSSTRT startup list specifies the IMSGRP resource group, so you can add the MPR definition to IMSGRP. You use ESMAC to add the MPR definition to IMSGRP. ESMAC is only available when the enterprise server is running, so first you must start the IMSIVP enterprise server.
Field | Value |
---|---|
Name | IMSMPR |
Description | MPR |
Type | IMS MPR |
Classes | 001 |
To make the enterprise server pick up the configuration changes you made in ESMAC you have to stop it and restart it.
You can confirm that MTO and IMS are enabled by watching the startup messages in the Console Daemon window. Messages should also appear indicating that the message processing region has started.
To start the demonstration application:
Field | Value |
---|---|
Host name | The name of the computer the enterprise server is running on. This is localhost if it is the current machine. |
Port | The number you specified for the field using port in the section Creating an MTO-enabled Enterprise Server. |
The following sections describe the demonstration program and how you navigate through its screens.
For the screens which follow, enter the characters which are shown in green.
Note: Each table you add must have a unique table ID.
Figure 14-1: The "Add Testdept Table" Screen in Transaction MFDEMO
Press Enter when you have finished entering data on a screen.
On the screens that follow press Tab to move to the next field. Press Shift+Tab to move to the previous field.
Figure 14-2: The "Add Testdept Elements" Screen
Figure 14-3: The "Change Testdept Table" Screen
Figure 14-4: The "Change Testdept Elements" Screen
Figure 14-5: The "Add Testers Table" Screen
Figure 14-6: The "Add Testers Elements" Screen
Figure 14-7: The "End Transaction" Screen
Figure 14-8: The "MFDEMO - ENDED" Screen
Copyright © 2006 Micro Focus (IP) Ltd. All rights reserved.