1.5.2. eXo Chat installation into a dedicated server

Warning

You are looking at documentation for an older release. Not what you want? See the current release documentation.

eXo Platform provides the standalone mode to install eXo Chat into a dedicated server. In this mode, the backend of eXo Chat application is deployed in its own Tomcat application server while the frontend i.e. the portlets are deployed in eXo Platform instance.

This alternative architecture brings better scalability and performance since server resources are not shared between eXo Platform and eXo Chat. It allows to add more eXo Chat server nodes independently from eXo Platform nodes.

The schema below summaries the standalone mode architecture:

To install eXo Chat in standalone mode, follow this procedure:

  1. Ensure to uninstall eXo Chat from eXo Platform server if it is already installed by the Addon manager: addon uninstall exo-chat

  2. Download eXo Chat package: chat-standalone-server-packaging into a known location and rename it to chat_server_package.

    The package chat_server_package contains these files:

    • exo-chat-standalone-application-x.y.z.zip containing the files: chat-services.jar, chat-extension.war, chat-common.jar and chat.war.
    • exo-chat-standalone-server-x.y.z.zip containing the war chatServer.war
    • chat-sample.properties
  3. Install and configure MongoDB database by following this link.

  4. Configure chat server on Tomcat by following these steps:

    • Install the latest update of Apache Tomcat 7 and rename it to chat-server.

    • Change the server.xml file to use the port 8280:

      
      
      <Connector port="8280" protocol="HTTP/1.1"
                     connectionTimeout="20000"
                     redirectPort="8243" URIEncoding="UTF-8" />
                     ....

      Note

      Make sure there is no port conflicts between the eXo Chat server and other systems. If you deploy the eXo Chat server on the same host than eXo Platform, then, you should change all the ports as in the example above.

    • Deploy chat application in Apache tomcat by copying the following files:

      • Copy the war file chatServer.war from chat_server_package/exo-chat-standalone-server-x.y.z to chat-server/webapps/ folder.

      • Copy chat-sample.properties to chat-server/conf/ folder and rename it to chat.properties.

      • Adapt the configuration file chat.properties to fit with your environments by updating the following properties:

        standaloneChatServer=true
        dbServerHost=[MongoDB-Host]
        dbServerPort=[MongoDB-Port]
        dbName=chat
        dbAuthentication=false
        dbUser=admin
        dbPassword=pass
        chatPortalPage=/portal/intranet/chat
        chatPassPhrase=change-me
        
        
    • Start the chat server:

      cd  chat-server
      ./bin/catalina.sh run
      
  5. Install Chat application into eXo Platform server : ./addon install exo-chat-client

  6. Configure these properties in eXo_tomcat/conf/eXo_tomcat/conf/:

    standaloneChatServer=true 
    chatServerBase=http://[chat-server-IP-address]:8280
    chatPortalPage=/portal/intranet/chat
    chatIntervalSession=60000
    chatPassPhrase=change-me
    
  7. Start eXo Platform server:

    cd eXo_tomcat 
    ./start_eXo.sh
    		
  8. Install a frontal server and configure it to redirect Chat server requests to the right server. Below an example of an Apache2 configuration file (It should be adapted according to your environment):

    
    
    <VirtualHost *:80>
        ErrorLog /var/log/apache2/error.log
        CustomLog /var/log/apache2/access.log combined
        #Put your used ServerName 
        ServerName www.domainexo.com
         
         <Proxy *>
            Order deny,allow
            Allow from all
         </Proxy>

         <IfModule proxy_wstunnel_module>    

    ProxyPass /chatServer/cometd ws://localhost:8280/chatServer/cometd  max=100 acquire=5000   retry=5 disablereuse=on flushpackets=on 
    ProxyPass /cometd  ws://localhost:8080/cometd/ max=100 acquire=5000 retry=5  disablereuse=on flushpackets=on 

         </IfModule>
         
         ProxyPass /chatServer  http://localhost:8280/chatServer
         ProxyPassReverse /chatServer http://localhost:8280/chatServer
         ProxyPassReverse /chatServer/cometd/  ws://localhost:8280/chatServer/cometd/

        

         ProxyPassReverse /cometd  ws://localhost:8080/cometd/
         ProxyPass / http://localhost:8080/
         ProxyPassReverse / http://localhost:8080/  
       
         ProxyRequests Off
         ProxyPreserveHost On
    </VirtualHost>


            
  9. Login to the platform using this url http://www.domainexo.com:80/portal/intranet/, you should have the chat application in the top navigation menu.

Integrating Video Calls

If you want to allow users to make video calls within Chat:

Copyright ©. All rights reserved. eXo Platform SAS
blog comments powered byDisqus