#include "config.h"#include "loadbalancing.h"#include "appcfg.h"#include "list.h"#include "log.h"#include "request.h"#include "response.h"#include "shmem.h"#include <string.h>#include <stdlib.h>#include <time.h>

Classes | |
| struct | LoadAverageInfo |
Defines | |
| #define | instLoadAverageInfo(inst) ((LoadAverageInfo *)(&inst->loadBalancingInfo[0])) |
| #define | LOAD_AGE_FACTOR (60) |
Functions | |
| static int | effectiveLoad (LoadAverageInfo *info, time_t currentTime) |
| static void | la_appDidNotRespond (_WOInstance *inst) |
| static int | la_finalize (WOAppReq *req, WOInstanceHandle instHandle) |
| static int | la_initialize (strtbl *options) |
| static WOInstanceHandle | la_selectInstance (WOAppReq *req, _WOApp *app) |
| static void | la_WOAdaptorInfo (String *text, WOInstance *instance) |
Variables | |
| const scheduler | lb_loadaverage |
| #define instLoadAverageInfo | ( | inst | ) | ((LoadAverageInfo *)(&inst->loadBalancingInfo[0])) |
| #define LOAD_AGE_FACTOR (60) |
| static int effectiveLoad | ( | LoadAverageInfo * | info, | |
| time_t | currentTime | |||
| ) | [static] |
| static void la_appDidNotRespond | ( | _WOInstance * | inst | ) | [static] |
| static int la_finalize | ( | WOAppReq * | req, | |
| WOInstanceHandle | instHandle | |||
| ) | [static] |
| static int la_initialize | ( | strtbl * | options | ) | [static] |
| static WOInstanceHandle la_selectInstance | ( | WOAppReq * | req, | |
| _WOApp * | app | |||
| ) | [static] |
| static void la_WOAdaptorInfo | ( | String * | text, | |
| WOInstance * | instance | |||
| ) | [static] |
| const scheduler lb_loadaverage |
Initial value:
{
"loadaverage",
"send new requests to instance with fewest current users",
la_initialize,
la_selectInstance,
la_appDidNotRespond,
lb_beginTransaction,
la_finalize,
la_WOAdaptorInfo,
}
1.5.8