Technical data

7 Configuring WebLogic Server Web Components
7-8 Configuring and Managing WebLogic Server
For example, you can specify that a Web Application called books responds to
requests for the virtual host name
www.books.com, and that these requests are targeted
to WebLogic Servers A,B and C, while a Web Application called
cars responds to the
virtual host name
www.autos.com and these requests are targeted to WebLogic
Servers D and E. You can configure a variety of combinations of virtual host,
WebLogic Servers, clusters and Web Applications, depending on your application and
Web server requirements.
For each virtual host that you define you can also separately define HTTP parameters
and HTTP access logs. The HTTP parameters and access logs set for a virtual host
override those set for a server. You may specify any number of virtual hosts.
You activate virtual hosting by targeting the virtual host to a server or cluster of
servers. Virtual hosting targeted to a cluster will be applied to all servers in the cluster.
Virtual Hosting and the Default Web Application
You can also designate a default Web Application for each virtual host. The default
Web Application for a virtual host responds to all requests that cannot be resolved to
other Web Applications deployed on same server or cluster as the virtual host.
Unlike other Web Applications, a default Web Application does not use the Web
Application name (also called the context path) as part of the URI used to access
resources in the default Web Application.
For example, if you defined virtual host name
www.mystore.com andtargetedittoa
server on which you deployed a Web Application called
shopping, you would access
a JSP called
cart.jsp from the shopping Web Application with the following URI:
http://www.mystore.com/shopping/cart.jsp
If, however, you declared shopping as the default Web Application for the virtual host
www.mystore.com, you would access cart.jsp with the following URI:
http://www.mystore.com/cart.jsp
For more information, see “How WebLogic Server Resolves HTTP Requests” on page
7-10.