JMap Deployment Guide
Introduction
The purpose of this guide is to provide technical information regarding the deployment of JMap in different technology environments, considering performance, security and scalability aspects. The proposed architectures are general examples. Variations of these or different models are just as valid, depending on the technological context.
System Components
JMap Server
JMap Server is the main component of the system. Each installation of JMap includes an instance of JMap Server. JMap Server has its own integrated web server (Apache Tomcat).
JMap Server listens on a port (by default 7003) for requests from JMap Pro (direct connections) or JMap Proxy for applications deployed on external web servers (see below).
JMap Admin
JMap Admin is used to administer JMap Server and is always hosted directly in JMap Server.
JMap Proxy
JMap Proxy is a module that provides communication between JMap applications (Pro, Web, Mobile) deployed on an external web server and JMap Server. It is thanks to JMap Proxy that JMap applications can be moved to external web servers. JMap Proxy is automatically included with every JMap application and normally does not need any special configuration.
In the case of JMap Pro, the use of JMap Proxy also makes it possible to encapsulate HTTP requests between JMap Pro and JMap Server. HTTP encapsulation makes it possible to use JMap Pro on networks where firewalls can block native queries between JMap Pro and JMap Server.
When deploying applications in JMap Admin, the JMap Proxy module is automatically configured to connect to JMap Server by the IP address used by JMap Server. This address can be selected during the installation of JMap. In the case of a server with multiple IP addresses, it is recommended that during the installation of JMap, you select the correct IP address that should be used to connect to JMap Server. If you do not select any, JMap Server uses all available IP addresses, and JMap Proxy may use an IP address that does not allow it to connect to JMap Server. After an application deployment, the address used by JMap Proxy to connect to JMap Server is written to the WEB-INF/msconnections.xml file. It is possible to modify this file with a text editor to change this address.
GeoWebCache
GeoWebCache is an optional tile (images) cache service that speeds up the display of the map for JMap Web and JMap Mobile. In the case of JMap Mobile, GeoWebCache is required to use the offline mode.
When GeoWebCache is used, the JMap Web and JMap Mobile applications get the tiles directly from it instead of asking JMap Server to produce them each time.
Applications JMap (Pro, Web, Mobile)
JMap applications include the front-end part (what users see) and the back-end part which is the service that responds to requests made by the front-end part. The back-end part of each JMap application can be hosted in JMap Server directly (by default) or moved to an external web server compatible with Java servlets (Tomcat, Jetty, WebLogic, etc.). In the case where back-end services are moved to an external web server, the JMap Proxy component handles the communication between them and JMap Server.
Suggested Architectures
The following architectures are examples only. Other architectures can be used.
Architecture 1 - Simple
This architecture is as simple as possible where all applications communicate directly with JMap Server.
It is well suited for situations where JMap Server and all JMap users are on a private network.
Architecture 2 - Deploying Applications to an External Java Servlet Container
In this architecture, a container of Java servlets (Tomcat, Jetty, WebLogic, etc.) is installed in the DMZ and hosts the back-end services of JMap applications. JMap applications deployed using JMap Admin are manually moved to this server. JMap Proxy ensures communications to JMap Server on the internal segment of the network. Internal users can also connect directly to JMap Server if JMap applications are deployed on it. On the other hand, the performance gain is theoretical and negligible.
This architecture is well suited to situations where users are outside the private network and provides a good level of JMap Server isolation for the security aspect.
For more information on installing and configuring Tomcat, visit this website.
For more information on deploying JMap applications, see this section of the JMap Administrator's Guide.
Architecture 3 - Application Deployment on Java Servlet Container with External Web Server
In this architecture, a web server is placed in front of the Java servlet container. The web server receives all requests and redirects them to JMap back-end services using the AJP protocol (Tomcat, Apache Web Server and IIS only) or a Reverse Proxy configuration.
This architecture is well suited to situations where users are outside the private network and provides a good level of JMap Server isolation for the security aspect. It facilitates the integration of JMap applications into existing websites.
For more information on configuring AJP with Apache Web Server, visit this website.
For more information on setting up AJP with IIS, visit this website.
For more information on setting up Nginx in Reverse Proxy with Tomcat, check out this website.
Architecture 4 - Application Deployment on JMap Server with External Web Server
In this architecture, a web server is placed in front of JMap Server. The web server receives all requests and redirects them to the JMap Server back-end services using the AJP protocol or a Reverse Proxy configuration.
This architecture is well suited to situations where users are outside the private network. It is simple to implement and makes it easy to integrate JMap applications into existing websites.
For more information on configuring AJP with Apache Web Server, visit this website.
For more information on setting up AJP with IIS, visit this website.
For more information on setting up Nginx in Reverse Proxy with Tomcat, check out this website (Nginx documentation) and this website (tutorial).