Configuring the 3DOrchestrate Distribution Server as a Windows Service

You can use the deployment utility to set up the TomEE application server to run the 3DOrchestrate Distribution Server as a Windows Service.

A Windows Service is an application that starts automatically and runs in the background without a user interface, similar to a Linux daemon process.

Notes:
  • This functionality is not available for a 3DOrchestrate Distribution Server running on Linux.
  • Registering 3DOrchestrate as a Windows service registers only the Application Server. The 3DOrchestrate ActiveMQ server is excluded and must be started and stopped manually. For more information, see Starting and Stopping the 3DOrchestrate Distribution Server.


Before you begin:
  • The user account running the 3DOrchestrate deployment utility must have Administrator privileges or you must use the right-click option Run as administrator to start the utility.
  • The 3DOrchestrate Distribution Server software and the database must be installed, deployed, and running successfully.
  • You must have the 3DOrchestrate Distribution Server installed on a local physical disk on the computer for the Windows Service to work properly.
See Also
Installing the 3DOrchestrate Distribution Server
Deploying 3DOrchestrate in the Java Application Server
Starting and Stopping the 3DOrchestrate Distribution Server
  1. If the 3DOrchestrate Distribution Server application is running, stop it.

    You can use the Stop server action in the Deploy tab of the deployment utility or the shutdown[.bat|.sh] script to do this. For more information, see Starting and Stopping the 3DOrchestrate Distribution Server

  2. Create the ActiveMQ service.
    1. Open a command prompt with administrative privilages.
    2. Run the ActiveMQ Service Install Script.

      You can find the script in the 3DOrchestrate deployment directory - <3DOrchestrate Deploy Dir>\activemq-one\bin\win64\InstallService.bat

      This script expects the java used for 3DOrchestrate to be in the PATH variable. If Java is not in the path variable you will need to add the java path and command to the wrapper.conf file, located in <3DOrchestrate Deploy Dir>\activemq-one\bin\win64\wrapper.conf

      #Java Command
      wrapper.java.command=<JAVAPATH>\bin\java
      

    3. To check for the newly created service, open the Windows Services control panel by selecting Control Panel > Windows > Services.

      Look for the service name ActiveMQ. It will be installed with Startup Type Automatic, but it will not be running

    4. Start the ActiveMQ service by right mouse clicking on the service name and selecting start.

      You can see the log files in <3DOrchestrate Deploy Dir>\activemq-one\

  3. Restart the deployment utility with administrator privileges, if it is not running, and do the following:
    1. In the Deploy tab, select Create TomEE service (under Server Actions).
    2. Switch to the TomEE+ Settings tab. Enter a name for the Windows Service in TomEE Service Name. For example, you might want to change the name to "3DOrchestrate" for clarity.
    3. Enter the 3DOrchestrate version number in Version, for example "R2026x."
    4. Switch back to the Deploy tab, and click Execute.

    The Windows Service is created with Automatic start-up type, and the service is started immediately for the first time. Startup of the 3DOrchestrate Distribution Server Windows Service is almost instantaneous, but the 3DOrchestrate Distribution Server application within TomEE might take 3 to 5 minutes to fully initialize itself. During that initialization period, a 3DOrchestrate Station waits before connecting (or reconnecting).

    The service restarts the 3DOrchestrate Distribution Server in TomEE anytime the computer is restarted.

    You can see log files for the service creation under:

    <server_install_dir>\exe1\tomee\logs\

    To check for the newly created service, open the Windows Services control panel by selecting:

    Control Panel > System and Security > Administrative Tools > Services

  4. The ActiveMQ Server needs to be started before the TomEE Application Server. In order to guarantee this happens it is recommended to set a dependency on the TomEE Application Server.
    1. Open an administrative command prompt
    2. Shutdown the 3DOrchestrate TomEE Application Service stop <3DOrchestrate_ServiceName>.
    3. Add ActiveMQ Server dependency config <3DOrchestrate_ServiceName> depend= Tcpip/Afd/ActiveMQ
    4. Start the 3DOrchestrate TomEE Application Service start <3DOrchestrate_ServiceName>.

Result:

Important: You might want to adjust the Java memory settings after you set up the 3DOrchestrate Distribution Server as a Windows Service—see JVM Settings for 3DOrchestrate Distribution Server Configured as a Windows Service.