WebLogic 12c Dynamic Clusters: Power of Simplicity and Elasticity
By Gokhan Gungor on Sep 25, 2013
A WebLogic Server cluster consists of multiple WebLogic Servers running simultaneously and working together. It provides increased scalability and reliability.
WebLogic Server 12c has an exiting new feature called Dynamic Clustering. A dynamic cluster contains multiple dynamic servers that is based on a single server template. This template will be the basis for all the servers in the cluster so that each server does not need to be manually configured when expanding the cluster.
- Managed Server Name: Server Name prefix appended with server id. For example, if the prefix is set to imc-server-, then the dynamic servers will have the names imc-server-1, imc-server-2 and so on.
- Network ports (Optional): Port value starting value is either the default or is based on the value in the server template. Applies to listen port, SSL Listen port, Network access point and replication ports. If you explicitly define a listen port in the server template or the cluster configuration itself, that value will be used for the first generated server instance and appended by 1 for each additional server instance. If the default listen port is indicated, WebLogic Server increments the "hundreds" digit by one and continue from there.
- Machine mappings (Optional): The dynamic cluster CalculatedMachineNames and MachineNameMatchExpression attributes control how server instances in a dynamic cluster are assigned to a machine. This is important when using admin console/Node manager to start servers. Regular expression to match the machine names. Managed server prefix + server id (numerical order in which the server is defined)
- Cluster with Dynamic Servers
- Server template
- Machine mappings
- Listen address and port mappings
First we navigate the Clusters page and click on to create Dynamic cluster.
On the next page we enter the cluster name and leave the rest as defaults.
The next page allows us to set the maximum number of server instances allowed in our dynamic cluster along with the server name prefix. Server names are the specified prefix followed by the index number.
The next step allow us to control how server instances in a dynamic cluster are assigned to a machine. If we choose any machine configured for this domain, then assignments will be made using a round robin algorithm.
The next page allows settings in the server template and the dynamic cluster configuration determines the listen ports for the server instances in our dynamic cluster. This is where listen ports and machines assignments will be calculated using a round-robin algorithm. Please note WebLogic Server calculates listen ports by default. This calculation can also be disabled in the dynamic cluster configuration.
Finally we get the summary screen where we confirm to create the cluster with the attribute values we specified.
Now if we navigate the servers screen, we see that all the servers are created with the values we provided. We did not manually/individually created Managed Servers. When creating a dynamic cluster in the Administration Console, WebLogic Server creates the server template, dynamic cluster, and specified number of server instances for us. We don't have to create them individually.
We can also navigate the Cluster Server template and modify the default values there. Below you can see a screenshot where we can modify the default server log file names.
If you need more information about WebLogic Server 12c and exiting new features it provides, you can read the documentation here.