mod_lbmethod_bytraffic.xml revision a6f5eeb5143ca0a2857af609084f6a325f437ac4
0N/A<?xml version="1.0"?>
2362N/A<!DOCTYPE modulesynopsis SYSTEM "/style/modulesynopsis.dtd">
0N/A<?xml-stylesheet type="text/xsl" href="/style/manual.en.xsl"?>
0N/A<!-- $LastChangedRevision$ -->
0N/A
0N/A<!--
2362N/A Licensed to the Apache Software Foundation (ASF) under one or more
0N/A contributor license agreements. See the NOTICE file distributed with
2362N/A this work for additional information regarding copyright ownership.
0N/A The ASF licenses this file to You under the Apache License, Version 2.0
0N/A (the "License"); you may not use this file except in compliance with
0N/A the License. You may obtain a copy of the License at
0N/A
0N/A http://www.apache.org/licenses/LICENSE-2.0
0N/A
0N/A Unless required by applicable law or agreed to in writing, software
0N/A distributed under the License is distributed on an "AS IS" BASIS,
0N/A WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
0N/A See the License for the specific language governing permissions and
0N/A limitations under the License.
2362N/A-->
2362N/A
2362N/A<modulesynopsis metafile="mod_lbmethod_bytraffic.xml.meta">
0N/A
0N/A<name>mod_lbmethod_bytraffic</name>
0N/A<description>Weighted Traffic Counting load balancer scheduler algorithm for <module
0N/A>mod_proxy_balancer</module></description>
0N/A<status>Extension</status>
0N/A<sourcefile>mod_lbmethod_bytraffic.c</sourcefile>
0N/A<identifier>lbmethod_bytraffic_module</identifier>
0N/A<compatibility>Split off from <module>mod_proxy_balancer</module> in 2.3</compatibility>
0N/A
0N/A<summary>
0N/A<p>This module does not provide any configuration directives of its own.
0N/AIt requires the services of <module>mod_proxy_balancer</module>, and
0N/Aprovides the <code>bytraffic</code> load balancing method..</p>
0N/A</summary>
0N/A<seealso><module>mod_proxy</module></seealso>
0N/A<seealso><module>mod_proxy_balancer</module></seealso>
0N/A
0N/A<section id="traffic">
0N/A <title>Weighted Traffic Counting Algorithm</title>
0N/A <p>Enabled via <code>lbmethod=bytraffic</code>, the idea behind this
0N/A scheduler is very similar to the Request Counting method, with
0N/A the following changes:</p>
0N/A
0N/A <p><dfn>lbfactor</dfn> is <em>how much traffic, in bytes, we want
0N/A this worker to handle</em>. This is also a normalized value
0N/A representing their "share" of the amount of work to be done,
0N/A but instead of simply counting the number of requests, we take
0N/A into account the amount of traffic this worker has either seen
0N/A or produced.</p>
0N/A
0N/A <p>If a balancer is configured as follows:</p>
0N/A
0N/A <table style="data">
0N/A <tr><th>worker</th>
0N/A <th>a</th>
0N/A <th>b</th>
0N/A <th>c</th></tr>
0N/A <tr><th>lbfactor</th>
0N/A <td>1</td>
0N/A <td>2</td>
0N/A <td>1</td></tr>
0N/A </table>
0N/A
0N/A <p>Then we mean that we want <var>b</var> to process twice the
0N/A amount of bytes than <var>a</var> or <var>c</var> should. It does
0N/A not necessarily mean that <var>b</var> would handle twice as
0N/A many requests, but it would process twice the I/O. Thus, the
178N/A size of the request and response are applied to the weighting
0N/A and selection algorithm.</p>
0N/A
0N/A <p>Note: input and output bytes are weighted the same.</p>
0N/A
0N/A</section>
0N/A
0N/A</modulesynopsis>
0N/A