IBM HTTP Server for Windows NT and Windows 2000 operating systems
contains a high-speed cache referred to as the Fast Response Cache Accelerator,
or cache accelerator. The Fast Response Cache Accelerator is available
on Windows NT and Windows 2000 operating systems and AIX platforms. However,
support to cache dynamic content is only available on Windows NT and Windows
2000 operating systems. You can enable cache accelerator to cache static and
dynamic content.
About this task
Enable cache accelerator for caching static content by adding
the following directives to the httpd.conf configuration file, located
in the IBM HTTP Server conf directory:
- AfpaEnable
- AfpaCache on
- AfpaLogFile "app_server_root\IBMHttpServer\logs\afpalog" V-ECLF
To enable cache accelerator for caching dynamic content, such as servlets
and JavaServer Pages (JSP) files, configure WebSphere Application Server and
IBM HTTP Server for distributed platforms:
Procedure
- Configure WebSphere Application Server to enable Fast Response
Cache Accelerator. It
is important to follow all of the steps for every application server in the
cluster.
Turn on
servlet caching for each application server that uses the cache accelerator.
- Configure an external cache group on the application server:
- Click Servers > Application servers > server_name >
Container services > Dynamic cache service > External cache groups.
- Click New on the External cache group administrative console page
to define an external cache group named afpa for each application
server that uses the cache accelerator.
- In the External cache group field, type afpa and apply
the changes.
- Add a member to the group with an adapter bean name of com.ibm.ws.cache.servlet.Afpa.
- Click Afpa > External cache group members.
- Click New on the External cache group members administrative console
page.
- In the AdapterBean name field, type com.ibm.ws.cache.servlet.Afpa.
- In the Address field, enter an unused port number.
- Add a cache policy in the cachespec.xml file for
the servlet or JSP file you want to cache. Add the following property to the
cache policy:
<property name="ExternalCache">afpa</property>
- Enable cache accelerator on IBM HTTP Server for distributed platforms:
- Add the following directives to the end of the httpd.conf file:
- AfpaEnable
- AfpaCache on
- AfpaLogFile "app_server_root\IBMHttpServer\logs\afpalog" V-ECLF
- IBM HTTP Server 1.3.x - LoadModule afpaplugin_module app_server_root\bin\afpaplugin.dll
- IBM HTTP Server 2.0 - LoadModule afpaplugin_20_module app_server_root\bin\afpaplugin_20.dll
- AfpaPluginHost WAS_Hostname:port, where WAS_Hostname is
the host name of the application server and port is the port
you specified in the Address field while configuring the external cache group
member
The LoadModule directive loads the IBM HTTP Server plug-in that connects
the Fast Response Cache Accelerator to the WebSphere Application Server fragment
cache. If multiple IBM HTTP Servers are routing requests to a
single application server, add the directives above to the httpd.conf file
of each of these IBM HTTP Servers for distributed platforms. If
one IBM HTTP Server is routing requests to a cluster of application servers,
add the AfpaPluginHost WAS_Hostname:port directive to the httpd.conf file
for each application server in the cluster. For example, if there are three
application servers in the cluster, add the following directives to the httpd.conf file:
- LoadModule afpaplugin_module app_server_root/bin/afpaplugin.dll
- AfpaPluginHost WAS1_Hostname:port1
- AfpaPluginHost WAS2_Hostname:port2
- AfpaPluginHost WAS3_Hostname:port3