Debugging a local CICS transaction with TXSeries

You can debug a local CICS® transaction with TXSeries®.

Before you begin

To prepare for debugging, locate the process ID for your CICS application server and copy your program:

  1. Open the CICSTERM - CICS server selection window and select the correct CICS server for your CICS region.
  2. In the CICS Client 3270 Terminal Emulator, enter the following command in the CICS terminal:
    CEMT INQUIRE TASK
    Note: Make sure that you type CEMT in all capital letters. Otherwise, the command does not work.

    The output of this command is the process ID for your CICS application server. You attach to this process for debugging.

  3. To make a new copy of the program, enter the following command in the CICS Client 3270 Terminal Emulator:
    CEMT SET PROGRAM(TIMEZONE) NEW
    This command unloads TIMEZONE.ibmcob from the CICS application server.

Information specific to Linux Remote debugging does not support the following functions on the Linux® platform: bidirectional enablement, workstation-based debugging, local COBOL or PL/I builds, local preprocessors for PL/I files, local syntax check of PL/I files, or show dependencies for PL/I files.

About this task

Note: The process for debugging a PL/I CICS transaction is similar. The only difference is that the name of the PL/I program is PROGRAM_NAME.IBMPLI (where PROGRAM_NAME is the name of your program) instead of TIMEZONE.ibmcob.

Attaching to CICS servers

Procedure

  1. Open the z/OS Projects perspective.
  2. From the Run menu, select Debug.
  3. Select Attach to a Running Process and click New.
  4. Select the Main tab.
  5. In the Project field, select the project that you are working with.
  6. Click Browse next to the Process ID input field.
  7. Minimize any Windows console windows that open.
  8. Select the first cicsas.exe process listed.
  9. Click OK.
  10. Click Debug.
  11. Minimize any Windows console windows that open.
    If a window opens with the message No error message text available, click OK.
  12. Repeat these steps with new debug configurations until you attach to all the running instances of cicsas.exe.

Establishing a breakpoint on the load of the CICS executable program

Procedure

  1. Select the first running cicsas.exe process that you attached to.
  2. Right-click the Breakpoints view and select Add Breakpoint, then Load.
  3. Specify TIMEZONE.ibmcob for the library name and click Finish.

Resuming the cicsas.exe processes

Procedure

  1. Expand the first running cicsas.exe process that is listed, if it is not already expanded.
  2. Right-click the line of text that starts with State:.
  3. Select Resume.
  4. Repeat these steps for all the cicsas.exe processes that you are attached to.

Running the transaction

Procedure

  1. When the CICS terminal starts, type TMZN.
  2. Press Ctrl (the 3270 terminal Return key).
    The CICS terminal execution stops. (No arrow or time is displayed.)

Selecting the module

Procedure

  1. Select the Modules view.
  2. Find and expand TIMEZONE.ibmcob.
  3. Expand TIMEZONE.obj.
  4. Expand TIMEZONE.cbl.
    Under TIMEZONE.cbl, a picture of two gears shows next to TIMEZONE.
  5. Double-click the picture.
    The TIMEZONE.cbl source is displayed.

Changing to the preprocessed source

Procedure

  1. Right-click the TIMEZONE.cbl source code and select Change Text File.
  2. Select the TIMEZONE.ppr file from the BuildOutput subdirectory of your project.
  3. Click OK.
    A preprocessed version of your COBOL source file is displayed with all the EXEC CICS lines expanded.

Setting the breakpoint

Procedure

  1. In the TIMEZONE.cbl source, set a breakpoint at the first executable line of COBOL source.
  2. Click Run > Resume.
    You can now step through and debug your program.