Skip to main content
Skip table of contents

Controlled Shutdown of the X4 Server (via JMX)

A controlled shutdown of the X4 Server during runtime ensures that all processes currently running are completed and no new processes are started.

Prerequisites for shutting down

This requires that the Can Stop property is not set for processes that are not allowed to be stopped. Moreover, endless processes must be modeled in such a way that they interrupt processing at regular intervals so that they can be stopped.

Depending on the message queue adapter, this can be done as follows:

  • JMS and RequestReply Transfer: Specify a timeout in parameter timeout. If the adapter returns the status 0, the queue is empty and the process control goes back to the adapter, allowing the process to be halted.
  • MQ Series Transfer and WebSphere MQ: Enable the parameter MQGetMessageOptions.options.MQC.MQGMO_WAIT to activate waiting for a message, and specify in parameter MQGetMessageOptions.waitInterval a timeout in milliseconds that will be waited until an appropriate message can be received.
  1. Access the X4Management MBean 

    • Start the jconsole tool.

    • Open the MBean X4Management in a domain de.softproject.X4

  2. Invoke the MBean method setAllOutOfService().
    The OutOfService property will be set for all processes. This causes that no more processes can be started.

  3. Invoke the MBean method stopAllProcesses().
    All processes that are currently executed and are allowed to be stopped, will be terminated.

  4. Wait until the MBean method runningWorkflowCount() displays 0.
    No process is executed any longer.


    Alternatively, you can also invoke the shutdownAllProcesses(longtimeoutInMS)method. This causes the MBean methods setAllOutOfService(), stopAllProcesses(), and runningWorkflowCount() to be executed consecutively.

    • In ParamValue, specify a timeout in milliseconds, to be handed over to the method as parameter longtimeoutInMS.

    • Click Invoke to execute the method. This returns True if runningWorkflowCount() displays 0 before the timeout exceeds.

  5. Shut down the X4 Server.

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.