Hitachi

uCosminexus Application Server Expansion Guide


3.7.2 Replacing a J2EE application while the system is online

You can replace a J2EE application while the system is online.

This subsection provides an overview of replacement and describes the replacement procedure.

Organization of this subsection

(1) Overview of replacement

Replace a J2EE application after the CTM daemon closes the exit of the schedule queue. While the exit is closed, requests from clients can be added to the schedule queue. Therefore, system operation can continue without causing the requests for the relevant application to fail. However, if an attempt is made to add a request to the schedule queue when the schedule queue is full, an error is returned to the relevant client.

The following figure shows an overview of replacing a J2EE application while the system is online.

Figure 3‒16: Overview of replacing a J2EE application while the system is online

[Figure]

(2) Replacement procedure

Before you can replace a J2EE application while the system is online, the exit of the schedule queue for the J2EE application must be closed. To close the exit and replace the J2EE application, use the mngsvrutil management command.

In addition to replacing a specific J2EE application, you can also replace J2EE applications on a host basis or on a management domain basis.

To close the exit of a schedule queue, execute the mngsvrutil command with the hold subcommand specified. While the exit of a schedule queue is closed, requests from clients can be added to the schedule queue. However, if an attempt is made to add a request when the schedule queue is full, an error is returned to the relevant client.

When you have replaced a J2EE application, unlock the schedule queue. To unlock the schedule queue, execute the mngsvrutil command with the release subcommand specified. When the schedule queue is unlocked, the J2EE application restarts processing the queued requests.

The following procedure shows how to replace a J2EE application while the system is online by using CTM.

  1. Close the exit of the CTM schedule queue for the J2EE application that you want to replace.

    The following shows the format and an execution example of the mngsvrutil command that is executed when a J2EE application is replaced.

    Format:
    mngsvrutil -m Management-Server-host-name[:port-number] -u management-user-ID -p management-password -t CTM-name hold queue queue-name out
    Execution example:
    mngsvrutil -m mnghost -u user01 -p pw1 -t ctm01 hold queue App1 out
  2. Replace the J2EE application.

    Stop the J2EE application, and then replace it with a new one. After that, start the new J2EE application.

    For details about how to replace a J2EE application, 5.6.3 Replacing and Maintaining a J2EE Application in the uCosminexus Application Server Operation, Monitoring, and Linkage Guide.

  3. Unlock the CTM schedule queue by executing the mngsvrutil command with the release subcommand specified.

    The following shows the format and an execution example of the mngsvrutil command executed in this step.

    Format:
    mngsvrutil -m Management-Server-host-name[:port-number] -u management-user-ID -p management-password -t CTM-name release queue queue-name
    Execution example:
    mngsvrutil -m mnghost -u user01 -p pw1 -t ctm01 release queue App1

For details about the mngsvrutil command, see mngsvrutil (Management Server management command) in the uCosminexus Application Server Command Reference Guide.