To Create a Live Recording with Enterprise Server Dynamic Debugging

Restriction: This topic applies only when the Enterprise Server feature is enabled.

Use these guidelines to create match criteria for a particular service or application. When the criteria are met, a live recording file is produced that you can play in your Eclipse IDE, for debugging purposes.

  1. Connect to Enterprise Server Administration.
  2. Enable dynamic debugging for the enterprise server region that should produce the live recording file.
  3. If you have not already done so, deploy the service or application to the server.
  4. If your program is a service (Web Service or J2EE), you need to create a client program to submit requests for that service.
  5. At the UNIX shell prompt, run the cobeslr utility, specifying the service or application details that you want to live record. It takes the following arguments:
    Argument Description Usage Applies to
    type Specify either CICS | JCL | WS | J2EE | IMS, depending on the type of application or service you want to debug. Mandatory All
    tranid=<transaction-id> The CICS or IMS transaction to debug Optional CICS, IMS
    termid=<terminal-id> Only debug CICS or IMS transactions started from terminal <terminal-id> Optional CICS, IMS
    userid=<user-id> Only debug CICS or IMS transactions started by <user-id> Optional CICS, IMS
    progid=<prog-id> Only debug CICS or IMS program <prog-id> Optional CICS, IMS
    jobname=<job-name> Only debug the JCL job <job-name> Optional JCL
    stepname=<step-name> Only debug the JCL step <step-name> Optional JCL
    jobnumber=<job-number> Only debug the JCL job <job-number> Optional JCL
    program=<program-name> Only debug the JCL program <program-name> Optional JCL
    ipaddress

    Specify the IP address of the client that will be used to request the web service you want to debug. Enter the address in the form

    xxx.xxx.xxx.xxx
    Optional Web service only
    servicename

    Specify the fully qualified name of the service. This is formed by taking the name of the service and appending a hash character (#) for Web Services, or a dot (.) for J2EE, followed by the name of the operation that you want to debug. For example, if the service name for the web service that you deployed is http://tempuri.org/wmapserv, and the operation to be debugged is Read, the fully qualified service name is:

    http://tempuri.org/wmapserv#Read
    Optional Web service and J2EE
    server Specify the enterprise server region running the services that you want to debug Mandatory All

    For example: cobeslr type=WS server=ESDEMO servicename=http://tempuri.org/wmapserv#Read

    cobeslr now passes the details to the enterprise server region specified by the server parameter.

  6. You can view the active match criteria that are in effect on the Dyn.Debug ESMAC page; see View the List of Attached Debuggers for more information.
  7. Run the client program and execute the required service, transaction, job, etc... that will trigger the Live Recorder.

    A live recording file (.mfr file) is created in the System Directory of the enterprise server region when the criteria triggers the Live Recorder. For example, the example above triggers a recording when the client submits a request; CICS criteria might live record when a particular transaction is run; or JCL criteria might live record when a particular step is executed.

    The match criteria remain in place, so the next time a match is met, it will also be Live Recorded. This could mean that many .mfr files get created in a short space of time (for example, a CICS transaction gets run multiple times). The name of the recording file includes the SEP, task, and PID details to ensure the file name is unique and helps you to identify a particular recording if many are created.

Tip: To remove the match criteria use cobeslr with the exact same criteria that were set, with the remove option added; for example:
cobeslr remove type=WS server=ESDEMO servicename=http://tempuri.org/wmapserv#Read

Alternatively, you can remove the criteria from the Dyn.Debug ESMAC page.

Now that you have a live recording file, you can debug it as you would any other generated native COBOL live recording; see To debug a live recording.