JSMDirect Program Logic

LANSA Integrator

JSMDirect Program Logic
  • Remote client program using HTTP protocol connects to HTTP server.
  • HTTP server executes JSMDIRECT program. (Look for messages in HTTP server job log).
  • JSMDirect program checks for arguments, if no arguments sends an about HTML page to client program.
  • JSMDirect program calls exit program JSMDRTEXT (if present) with an EVENT parameter value of ENTRY.
  • JSMDirect program uses the service argument value and the SERVER_HOST and SERVER_PORT environment variable values to do a keyed lookup on DC@W29V1 to determine the LANSA function or 3GL program associated with the service. If no record is found then another keyed lookup is done using the service argument value and the host value of *DEFAULT. If no record is found then an error message is returned and logged via the JSMDRTEXT program with the EVENT parameter set to an ERRnnnn value. (Look for messages in HTTP server job log).
  • JSMDirect program reads standard input.
  • JSMDirect program calls exit program JSMLSAEXT (if present) or internally calls LANSA.
  • JSMDirect program waits for the LANSA function or the 3GL program to complete.
  • JSMDirect program writes function or program response to standard output.
  • JSMDirect program calls exit program JSMDRTEXT (if present) with an EVENT parameter value of EXIT.