Docker Web Client Deployment for Scalability

About this task

The Docker Web Client’s installer has default configuration selections that are optimized for Linux machines of 32 GB RAM. With the default installation, the maximum number of concurrent clients / scalability will be limited to 10 or 12. If your scalability requirements are high and need to support over 100 concurrent client sessions, you must choose the target Linux server with 64-GB RAM. Also, before starting the installer you must perform following task.

Procedure

  1. Access the plantapps-web-docker.j2 file located in the installer folder path: \uc-ansible-installer\roles\installer\templates\
  2. Locate and replace the below lines of code...
    JAVA_OPTIONS_1000=-XX:MaxRAM=1000m -XX:MaxHeapSize=720m -XX:+UnlockExperimentalVMOptions -XX:CompressedClassSpaceSize=120m
    JAVA_OPTIONS_350=-XX:MaxRAM=350m -XX:MaxHeapSize=180m -XX:+UnlockExperimentalVMOptions -XX:CompressedClassSpaceSize=120m
    JAVA_OPTIONS_256=-XX:MaxRAM=350m -XX:MaxHeapSize=180m -XX:+UnlockExperimentalVMOptions -XX:CompressedClassSpaceSize=120m
    JAVA_OPTIONS_1024=-XX:MaxRAM=1024m -XX:MaxHeapSize=720m -XX:+UnlockExperimentalVMOptions -XX:CompressedClassSpaceSize=120m
    JAVA_OPTIONS_512=-XX:MaxRAM=512m -XX:MaxHeapSize=320m XX:+UnlockExperimentalVMOptions -XX:CompressedClassSpaceSize=120m
    ...with the following lines of code:
    JAVA_OPTIONS_1000=-XX:MaxRAM=1000m -XX:MaxHeapSize=720m -XX:+UnlockExperimentalVMOptions -XX:CompressedClassSpaceSize=250m
    JAVA_OPTIONS_350=-XX:MaxRAM=650m -XX:MaxHeapSize=500m -XX:+UnlockExperimentalVMOptions -XX:CompressedClassSpaceSize=250m
    JAVA_OPTIONS_256=-XX:MaxRAM=650m -XX:MaxHeapSize=500m -XX:+UnlockExperimentalVMOptions -XX:CompressedClassSpaceSize=250m
    JAVA_OPTIONS_1024=-XX:MaxRAM=1024m -XX:MaxHeapSize=720m -XX:+UnlockExperimentalVMOptions -XX:CompressedClassSpaceSize=250m
    JAVA_OPTIONS_512=-XX:MaxRAM=650m -XX:MaxHeapSize=500m -XX:+UnlockExperimentalVMOptions -XX:CompressedClassSpaceSize=250m
  3. Save and close the file.
  4. Access the plantapps-web-docker-yml.j2 file located in the following folder: \uc-ansible-installer\roles\installer\templates\
  5. Perform the following:
    1. Search for memory: 350M and replace it with memory: 650M
    2. Search for memory: 256M and replace it with memory: 650M
    3. Search for memory: 512M and replace it with memory: 650M
  6. Save and close the file.
  7. Follow Install Plant Applications Web Client Using Docker version of Web Client.
    You can now use Web Client on a machine with a 64GB RAM.

Post-Installation Repair or Upgrade for Scalability

About this task

For some reasons, if you have performed the installation with the default settings, that is, without making any changes to the plantapps-web-docker.j2 file as stated above and realized that the default installation is not supporting your scalibillity requirements , you can make the following changes to repair the installation to meet your scalability requirements to utilize RAM size of 64 GB.

Procedure

  1. Navigate to the plantapps-web-docker folder located in the Web Client installation path: /<installation_path>/PlantApplicationsDocker/plantapps-web-docker
  2. Open the .env file in a text editor. Locate and replace the below lines of code...
    JAVA_OPTIONS_1000=-XX:MaxRAM=1000m -XX:MaxHeapSize=720m -XX:+UnlockExperimentalVMOptions -XX:CompressedClassSpaceSize=120m
    JAVA_OPTIONS_350=-XX:MaxRAM=350m -XX:MaxHeapSize=180m -XX:+UnlockExperimentalVMOptions -XX:CompressedClassSpaceSize=120m
    JAVA_OPTIONS_256=-XX:MaxRAM=350m -XX:MaxHeapSize=180m -XX:+UnlockExperimentalVMOptions -XX:CompressedClassSpaceSize=120m
    JAVA_OPTIONS_1024=-XX:MaxRAM=1024m -XX:MaxHeapSize=720m -XX:+UnlockExperimentalVMOptions -XX:CompressedClassSpaceSize=120m
    JAVA_OPTIONS_512=-XX:MaxRAM=512m -XX:MaxHeapSize=320m XX:+UnlockExperimentalVMOptions -XX:CompressedClassSpaceSize=120m
    ...with the following lines of code:
    JAVA_OPTIONS_1000=-XX:MaxRAM=1000m -XX:MaxHeapSize=720m -XX:+UnlockExperimentalVMOptions -XX:CompressedClassSpaceSize=250m
    JAVA_OPTIONS_350=-XX:MaxRAM=650m -XX:MaxHeapSize=500m -XX:+UnlockExperimentalVMOptions -XX:CompressedClassSpaceSize=250m
    JAVA_OPTIONS_256=-XX:MaxRAM=650m -XX:MaxHeapSize=500m -XX:+UnlockExperimentalVMOptions -XX:CompressedClassSpaceSize=250m
    JAVA_OPTIONS_1024=-XX:MaxRAM=1024m -XX:MaxHeapSize=720m -XX:+UnlockExperimentalVMOptions -XX:CompressedClassSpaceSize=250m
    JAVA_OPTIONS_512=-XX:MaxRAM=650m -XX:MaxHeapSize=500m -XX:+UnlockExperimentalVMOptions -XX:CompressedClassSpaceSize=250m
    Note: Ensure that the spaces left in the original content/lines are not changed.
  3. Save and close the file.
  4. In the same folder location, open the env.yml file in a text editor.
  5. Perform the following:
    1. Search for memory: 350M and replace it with memory: 650M
    2. Search for memory: 256M and replace it with memory: 650M
    3. Search for memory: 512M and replace it with memory: 650M
    Note: Ensure that the spaces left in the original content/lines are not changed.
  6. Save and close the file.
    You can now use Web Client on a machine with a 64GB RAM.
  7. From the same folder location, run the following commands:
    1. $sudo docker stack rm PAServices
    2. $sudo docker stack rm PAContainer
      Note: If your application is not running, you might encounter errors that you can ignore.
    3. $sudo docker-compose -f env.yml config > PAServices.yml
    4. $sudo docker stack deploy -c PAServices.yml PAServices
      Note: The above command with deploy the Web Client's services stack which will take few minutes.
    5. $sudo docker-compose -f env.yml config > PAContainer.yml
    6. $sudo docker stack deploy -c PAContainer.yml PAContainer
      Note: The above command will deploy the Web Client's UI Applications stack that will take few minutes.
    The Web Client instance will be now running with the optimally utilized system memory and will support your scalability requirements up to 150 concurrent client sessions.