z/OS TSO/E Guide to SRPI
Previous topic | Next topic | Contents | Contact z/OS | Library | PDF


What You Need to Do to Write Servers

z/OS TSO/E Guide to SRPI
SA32-0980-00

The following is an overview of the steps you need to follow when writing servers for MVSSERV. Subsequent chapters of the document give further details.

  1. Select or create a load module data set to contain the executable code for the server and initialization/termination program. If the server and initialization/termination program are in different load modules, the initialization/termination program must load the server (see Designing and Writing a Server Initialization/Termination Program for details).
  2. Write the server (see Designing and Writing a Server).
    • The server must:
      • Access the service request input in the CPRB.
      • Call the requested service function.
      • Perform the service, calling other servers if necessary.
      • Indicate the reply length in the CPRB.
      • Set the return code in register 15.
      • Return control to MVSSERV.
      • Provide recovery (optional).
    • Compile or assemble the server and link it to a load module.
  3. Write an initialization/termination program (see Designing and Writing a Server Initialization/Termination Program).
    • For initialization, the program must:
      • Load the server (if necessary).
      • Obtain resources (if necessary).
      • Define the server to MVSSERV and pass a parameter list (parmlist) pointing to any resources.
  4. For termination, the program must:
    • Free any resources.
    • Delete the server (if loaded).
    • Compile or assemble the initialization/termination program and link it to a load module.
  5. Install the server and initialization/termination program (see Installing Programs and Data Sets for Use with MVSSERV).
    • Install the programs in a STEPLIB or system library.
    • Define the initialization/termination program to MVSSERV in the input parameter data set.
    • Allocate diagnosis data sets (optional):
      • Trace data set
      • Dump data set
      • Dump suppression data set
  6. Invoke MVSSERV to test your server (see Testing and Diagnosis).

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014