Best Practices for Configuring Your Middle Tier |
Overview of Using an HTTP Server to Serve SAS Themes Web Application Static Content |
Your middle-tier deployment can use an HTTP server to handle requests for the static content in the SAS Themes Web application. This HTTP server can be configured as a reverse proxy to forward requests for dynamic content to your Web application server, or the content can be deployed on a standard HTTP server. This strategy makes efficient use of the HTTP server, and enables the Web application server to devote its resources to dynamic content. The performance benefits are particularly notable for large-scale deployments that include a cluster of Web application servers. For an overview of this configuration, see Sample Middle-Tier Deployment Scenarios.
Example: Use Apache HTTP Server to Serve SAS Themes Web Application Static Content |
This example describes how to configure Apache HTTP Server to server the SAS Themes Web application as static content on a Windows system. There is more than way one to configure Apache HTTP Server, and your configuration might differ from what is presented here.
Locate the EAR file for SAS Web Application Themes. The EAR file is named sas.themes.ear and is located in the SAS-configuration-directory\Levn\Web\Staging directory.
Unpack sas.themes.ear. On a Windows system, you can use the unzip utility.
The EAR archive contains several files, including sas.theme.default.war and application.xml.
Open the application.xml file in an editor.
In application.xml, the URL for the application is shown as sas.theme.default.war. The mapping shows that the name of the application (the context root) is SASTheme_default.
In the Apache document directory, create a directory that has the same name as the application (SASTheme_default). Here is an example:
D:\Apache2.2\htdocs\SASTheme_default
Extract the contents of sas.theme.default.war into the directory that you created in the previous step.
Stop and restart Apache HTTP Server.
On the Web application server, stop and uninstall the SAS Themes Web application.
Use SAS Management Console to change the connection properties for SAS Themes.
Select Application Management > Configuration Management.
Right-click SASTheme_default and select Properties.
Click the Connection tab, set Host Name and Port Number to the host name and port number of the Apache HTTP Server, and then click OK.
Restart each of the SAS Web applications, or restart the Web application server.
When you access a SAS Web application, the SAS Themes Web application content is served by Apache HTTP Server rather than the Web application Server. In the Apache HTTP Server access log, you can verify that the files from the SASTheme_default directory are being served by Apache HTTP Server.
Copyright © 2010 by SAS Institute Inc., Cary, NC, USA. All rights reserved.