com.WebServiceEngine.ProcessServices

Specifies the wait period for an HTTP input request, to process an operation of one of the registered Web Services.

Syntax

com.WebServiceEngine.ProcessServices(
   timeout INTEGER )
  RETURNS INTEGER
  1. timeout defines the timeout in seconds.

Usage

The com.WebServiceEngine.ProcessServices() class method specifies the wait period for an HTTP input request, to process an operation of one of the registered Web Services.

The timeout parameter defines the wait period for an HTTP input request, to process an operation of one of the registered Web Services. The value -1 specifies an infinite waiting time.

The status returned by the method provides information about the execution of the last web operation. A return status of zero means OK. For a complete list of error codes, see Error codes of com.WebServicesEngine

A status of -8 or -10 is returned if an invalid or unsupported HTTP request is sent.

Even if the exception is trapped, the GWS HTTP server is not in a valid state anymore, and you must close the application properly before exiting the program.
Note: This is not an issue in production environments as the Genero Application Server (GAS) and GWSProxy will detect the ended DVM, return an HTTP error code to the client app, and any new request will start a new DVM in a clean state via GWS proxy and the pool configuration.

The execution status is typically handled in a CASE / END CASE block, to treat all possible execution cases. For a complete example of execution status handling, see Process the requests.

Note: If the com.WebServiceEngine.Flush() method is used, the return status handling must be done in the web operation function, while com.WebServiceEngine.ProcessServices() will return the code -31, to indicated that a flush was done.