Jump to: navigation, search

How to Start and Stop Applications and Solutions

With the control function of the Management Layer, you can start and stop individual applications with a single control function through Genesys Administrator. You can also use the control function to start and stop solutions, with one exception: you must use Genesys Administrator to start and stop a solution of type Default Solution Type or Framework.

Starting with release 8.0, you can also stop applications and solutions gracefully, also called Graceful Stop or graceful shutdown. See Graceful Stop for more information.

The control function requires the installation of:

  • Solution Control Server (SCS)
  • An instance of Local Control Agent (LCA) for each Genesys host computer
  • Genesys Administrator
Important
Genesys recommends that you start and stop entire solutions as opposed to starting and stopping single applications.

Starting and Stopping Applications and Solutions Manually

To manually start and stop applications and solutions, use the start and stop commands in Genesys Administrator, locate as follows:

  • Start, Stop, and Graceful Stop buttons on the toolbar
  • Start, Stop, and Graceful Stop commands in the Tasks panel

Genesys Administrator Help provides detailed instructions on how to start and stop solutions and applications.

Starting in Management Framework release 8.0, you can also use the mlcmd command-line utility to start and stop applications and solutions. For detailed information about this utility, and detailed instructions for using it, see How to Use the mlcmd Utility.

Starting Applications Automatically

Solution Control Server starts applications without a user command (that is, automatically) when:

  • SCS starts
  • The computer running the applications is restarted

If you do not modify an Application object as described in this section, SCS automatically starts the application only at the application’s host restart, given that the application has been running prior to the host restart.

To enable this, you must configure the autostart option for each application, as described in the following procedure. [+] Show steps

To disable an automatic application startup in scenarios in which SCS starts or in which an application was not running prior to its computer restart, either delete the autostart option or set its value to false.

What Happens During Start and Stop?

Processing the Start Command for Applications

When the Management Layer receives a request to start a particular application, SCS generates a command line and passes it to LCA, which executes the command. The command line contains:

  • The working directory of the application as specified in the Application object’s Properties.
  • The host name and port number of Configuration Server currently running in Primary mode.
    Important
    If you are using Configuration Server Proxy, SCS substitutes the host and port parameters of Configuration Server Proxy, where appropriate. For more information, see How to Manage Environments with Configuration Server Proxies
  • The application name as specified in the Application object’s Properties.

Be sure that the working directory, executable (or startup) file name, application name, and startup timeout parameters are specified correctly in the Application object’s Properties; otherwise, the Management Layer will be unable to start the application.

Unless an application is explicitly configured with a connection to Configuration Server Proxy, SCS starts the application against the Configuration Server to which SCS is currently connected. The port for connection to Configuration Server which SCS provides to the application is determined as follows:

  • If the application is configured with a connection to Configuration Server, SCS starts the application using the same PortID as that configured for the connection between the application and Configuration Server.
  • If the application is not configured with a connection to Configuration Server, SCS starts the application using PortID = default.

Processing the Start Command for Solutions

When the Management Layer receives a request to start a particular solution, SCS via LCA starts all applications included in the solution, in the order specified in the Solution object. The solution is considered Started when all mandatory applications that belong to it or their backup applications start successfully. When a mandatory solution component does not start, SCS determines if the solution configuration contains a backup server configured for this application. Then, one of the following happens:

  • If the solution configuration does not contain a backup server, SCS interrupts the solution startup procedure and the solution status remains Stopped.
  • If the solution configuration contains a backup server, SCS attempts to start the backup application:
    • If successful, the solution startup procedure continues through completion. Then, the Management Layer applies the restart mechanism to applications that could not start.
    • If unsuccessful, SCS interrupts the solution startup procedure and the solution status remains Stopped.

Note that after starting a mandatory application, SCS attempts to start a backup server configured for this application. This only happens when the backup server is included in the same solution. If the backup server application does not start while the primary server application is running, SCS proceeds by starting the next mandatory component.

At SCS Startup

When SCS starts, it:

  1. Establishes connections with all LCAs in the system and receives current statuses of all configured applications.
  2. Checks the applications’ configurations in the Configuration Database to determine whether you have enabled the autostart option.
  3. For applications that have Stopped status and have the autostart option enabled, SCS:
    1. Waits for the interval specified in the Startup Timeout property of a particular Application object.
    2. Checks whether the application’s status changes after the timeout has expired. If not, SCS starts the application as described in Processing the Start Command for Applications.

At Computer Restart

When a computer restarts, and on which Management Layer–controlled applications are installed, SCS:

  1. Establishes a connection with the LCA running on that computer.
  2. For applications that were running (that is, had Started or an equivalent status) prior to the computer restart, SCS:
    1. Waits for the interval specified in the Startup Timeout property of a particular Application object.
    2. Checks whether the application’s status changes after the timeout has expired. If not, SCS starts the application as described in Processing the Start Command for Applications.
  3. Identifies applications that were not running (that is, had Stopped status) prior to the computer restart.
  4. Checks the applications’ configurations in the Configuration Database to determine whether you have enabled the autostart option (using the procedure in Starting Applications Automatically).
  5. For applications that have Stopped status and have the autostart option enabled, SCS:
    1. Waits for the interval specified in the Startup Timeout property of a particular Application object.
    2. Checks whether the application’s status has changed after the timeout expires. If not, SCS starts the application as described in Processing the Start Command for Applications.

As a result, both the applications that were running prior to a computer restart and the applications that were not running but whose configuration contained the autostart option set to true are started automatically after you restart a computer.

Starting Third-Party Applications Automatically

Management Layer supports the automatic start-up and restart of third-party applications as described above. However, control and monitoring of third-party applications is performed in a different manner than that for Genesys applications. For details about how third-party applications are controlled, refer to How to Manage Third-Party Applications.

Graceful Stop

When you stop an application or a solution, it shuts down, ceasing all processing immediately. This can have a detrimental effect on the rest of the system. Starting with release 8.0, you can stop an application or a solution gracefully in a manner known as a graceful stop, or graceful shutdown.

Important
You must use Genesys Administrator to stop solutions of type Framework or Default Solution Type.

Applications that are being stopped gracefully refuse any new requests, but continue to process their current requests. Applications are stopped only after they have finished processing all of their requests.

The graceful stop command can be issued to any application. Applications that support this functionality process the command as described in the preceding paragraph. Applications that do not support the graceful stop functionality are stopped ungracefully.

For each application, you can specify a timeout with the suspending-wait-timeout configuration option in the Application object’s Annex. If the status of the application does not change to Suspending after the graceful stop command but before the timeout expires, the application is considered not to support graceful shutdown, and is stopped ungracefully.

Important
The Shutdown Timeout does not apply to third-party applications. See Stopping Third-Party Applications

For a solution to stop gracefully, the graceful stop command is issued to each of its composite applications. How each composite application handles the command depends on whether the application supports the graceful-stop functionality.

Important
Because a number of solutions can share the same applications, some solution components may continue to have a status of Started after you stop the solution.

For more information about graceful stop, refer to Genesys Administrator Help. For details about the suspending-wait-timeout configuration option, refer to the Framework Configuration Options Reference Manual.

This page was last modified on December 22, 2015, at 12:33.

Feedback

Comment on this article:

blog comments powered by Disqus