Merged documentation changes

Merged the documentation changes between the 1.4.1 and 1.4.2 releases from
MaxScale-Documentation.
This commit is contained in:
Markus Makela
2016-04-25 14:19:56 +03:00
parent 3046b4a46e
commit 40ffc10120
7 changed files with 117 additions and 134 deletions

View File

@ -454,15 +454,23 @@ If not set, the default value is the server version of the embedded MySQL/MariaD
#### `weightby`
The weightby parameter is used in conjunction with server parameters in order to control the load balancing applied in the router in use by the service. This allows varying weights to be applied to each server to create a non-uniform distribution of the load amongst the servers.
The weightby parameter is used in conjunction with server parameters in order to
control the load balancing applied in the router in use by the service. This
allows varying weights to be applied to each server to create a non-uniform
distribution of the load amongst the servers.
An example of this might be to define a parameter for each server that represents the amount of resource available on the server, we could call this serversize. Every server should then have a serversize parameter set for the server.
An example of this might be to define a parameter for each server that represents
the amount of resource available on the server, we could call this serversize.
Every server should then have a serversize parameter set for the server.
```
serversize=10
```
The service would then have the parameter weightby set. If there are 4 servers defined in the service, serverA, serverB, serverC and serverD, with the serversize set as shown in the table below, the connections would balanced using the percentages in this table.
The service would then have the parameter `weightby=serversize`. If there are 4
servers defined in the service (serverA, serverB, serverC and serverD) with the
serversize set as shown in the table below, the connections would balanced
using the percentages in this table.
Server |serversize|% connections
---------|----------|-------------
@ -471,6 +479,46 @@ serverB | 15 | 27%
serverC | 10 | 18%
serverD | 20 | 36%
Here is an excerpt from an example configuration with the `serv_weight` parameter
used as the weighting parameter.
```
[server1]
type=server
address=127.0.0.1
port=3000
protocol=MySQLBackend
serv_weight=3
[server2]
type=server
address=127.0.0.1
port=3001
protocol=MySQLBackend
serv_weight=1
[Read Service]
type=service
router=readconnroute
servers=server1,server2
weightby=serv_weight
```
With this configuration and a heavy query load, the server _server1_ will get
most of the connections and about a third of the remaining queries are routed
to the second server. With server weights, you can assign secondary servers
that are only used when the primary server is under heavy load.
Without the weightby parameter, each connection counts as a single connection.
With a weighting parameter, a single connection received its weight from
the server's own weighting parameter divided by the sum of all weighting
parameters in all the configured servers.
If we use the previous configuration as an example, the sum of the `serv_weight`
parameter is 4. _Server1_ would receive a weight of `3/4=75%` and _server2_ would get
`1/4=25%`. This means that _server1_ would get 75% of the connections and _server2_
would get 25% of the connections.
#### `auth_all_servers`
This parameter controls whether only a single server or all of the servers are used when loading the users from the backend servers. This takes a boolean value and when enabled, creates a union of all the users and grants on all the servers.