You can use the WebSphere plug-in with an Apache web server to route HTTP requests to
applications running in Liberty servers. It is common to provide workload balancing and failover of
application requests by running the same application in multiple application server processes, a
pattern referred to as an application cluster. In such a topology, the web server
plug-in must share the requests across all the application servers in the cluster, and it can be
directed to do so by using a configuration that contains information about all of the application
servers. This is known as a merged plug-in configuration because it involves merging
routing information from multiple application servers. Liberty offers three ways to provide the
merged plug-in configuration to the web server.
Procedure
- Create the plug-in configuration for each application server, use a utility to merge these
configurations into a single file, and then copy the file to the web server installation. This
method can be used for Liberty servers from any edition of WebSphere; the servers do not need to be
managed in a Liberty collective.
See 自动生成 plugin-cfg.xml 文件, 生成 plugin-cfg.xml 文件, and 从命令行合并 Web 服务器插件配置文件.
- Manage the application server in a Liberty collective, and use the Dynamic Routing feature in
the collective controller process to provide the information from each application server to the web
server plug-in. For this method, the web server plug-in configuration only must contain information
about the collective controller process; the plug-in then contacts the controller to obtain
information about all the servers in the collective, and directs HTTP requests to all of the
applications in all the application servers. This method requires a multiple-server product such as
WebSphere Application Server Liberty Network Deployment or WebSphere Application Server Liberty for
z/OS for the collective controller host. But the application servers that run the applications can
be from any WebSphere edition.
See 为 Liberty 集合体设置动态路由选择.
- Organize the application servers into managed clusters within a Liberty collective, with the
clusterMember feature in each server. Then, use the ClusterManagerMBean in the controller process to
generate a merged plug-in configuration for all the servers in a given cluster. This method requires
a multiple-server product such as WebSphere Application Server Liberty Network Deployment or
WebSphere Application Server Liberty for z/OS for all the Liberty servers.
See 生成 Liberty 服务器集群插件配置.