Separating WebUI Hosting from Services

Separating WebUI Hosting from Services

When you install iDempiere on a single server, the application server supports two duties: (1) WebUI server and (2) Services server. The purpose of this section is to help you support growth beyond 100 concurrent users by separating these duties onto two or more different servers. The WebUI is what you see when you use iDempiere's web client. Services includes the processes that are needed to support the behind-the-scenes iDempiere operations. The most recognizable service is the accounting engine. As you approach or cross the 100 concurrent user threshold, the application becomes a significant single point of failure. You can minimize risk by spreading the WebUI load across multiple servers. Before you can create multiple WebUI servers, you must first isolate the services server. The below instructions only apply to iDempiere. To isolate services to a single server, perform the following:

Installation Script

When you install iDempiere with my installation script, you can also install a dedicated services instance using the -s option. A dedicated services instance is just another iDempiere server. The importing thing to note is that the database knows the IP of the services instance. Search the installation script for "if [[ $IS_SET_SERVICE_IP == "Y" ]]". This section tells you what statements get executed so that iDempiere knows what server to use for services.

Strategies for Modifying ADempiere's AdempiereServerMgr

This section only applies to ADempiere (not iDempiere). The class you modify is AdempiereServerMgr.java. How you conditionally start (or not start) the services depends on your skill level. Here are some options: I would recommend you reach out to Deepak if you want someone to code this for you. If you do implement this change, please email me the class as a reference implementation for the class.