Apache HTTPD
Classes | Macros | Typedefs | Functions | Variables
mod_heartbeat.c File Reference
#include "httpd.h"
#include "http_config.h"
#include "http_log.h"
#include "apr_strings.h"
#include "ap_mpm.h"
#include "scoreboard.h"
#include "mod_watchdog.h"

Go to the source code of this file.

Classes

struct  hb_ctx_t
 

Macros

#define HEARTBEAT_INTERVAL   (1)
 
#define MSG_VERSION   (1)
 

Typedefs

typedef struct hb_ctx_t hb_ctx_t
 

Functions

static int hb_monitor (hb_ctx_t *ctx, apr_pool_t *p)
 
static int hb_watchdog_init (server_rec *s, const char *name, apr_pool_t *pool)
 
static int hb_watchdog_exit (server_rec *s, const char *name, apr_pool_t *pool)
 
static int hb_watchdog_step (server_rec *s, const char *name, apr_pool_t *pool)
 
static int hb_watchdog_need (server_rec *s, const char *name, int parent, int singleton)
 
static void hb_register_hooks (apr_pool_t *p)
 
static void * hb_create_config (apr_pool_t *p, server_rec *s)
 
static const charcmd_hb_address (cmd_parms *cmd, void *dconf, const char *addr)
 

Variables

static const charmsg_format = "v=%u&ready=%u&busy=%u"
 
static const command_rec hb_cmds []
 
static int *const aplog_module_index = &( heartbeat_module.module_index)
 

Macro Definition Documentation

◆ HEARTBEAT_INTERVAL

#define HEARTBEAT_INTERVAL   (1)

Definition at line 27 of file mod_heartbeat.c.

◆ MSG_VERSION

#define MSG_VERSION   (1)

Definition at line 43 of file mod_heartbeat.c.

Typedef Documentation

◆ hb_ctx_t

Function Documentation

◆ cmd_hb_address()

static const char * cmd_hb_address ( cmd_parms cmd,
void *  dconf,
const char addr 
)
static

< Forbidden in <VirtualHost>

< Forbidden in <Limit>

< Forbidden in <Directory>

< Forbidden in <Location>

< Forbidden in <Files> or <If>

< Forbidden in <Proxy>

Definition at line 166 of file mod_heartbeat.c.

◆ hb_create_config()

static void * hb_create_config ( apr_pool_t p,
server_rec s 
)
static

Definition at line 159 of file mod_heartbeat.c.

◆ hb_monitor()

static int hb_monitor ( hb_ctx_t ctx,
apr_pool_t p 
)
static

< UDP

< Module has handled this stage.

Definition at line 45 of file mod_heartbeat.c.

◆ hb_register_hooks()

static void hb_register_hooks ( apr_pool_t p)
static

Definition at line 151 of file mod_heartbeat.c.

◆ hb_watchdog_exit()

static int hb_watchdog_exit ( server_rec s,
const char name,
apr_pool_t pool 
)
static

< Module has handled this stage.

Definition at line 125 of file mod_heartbeat.c.

◆ hb_watchdog_init()

static int hb_watchdog_init ( server_rec s,
const char name,
apr_pool_t pool 
)
static

< Module has handled this stage.

Definition at line 115 of file mod_heartbeat.c.

◆ hb_watchdog_need()

static int hb_watchdog_need ( server_rec s,
const char name,
int  parent,
int  singleton 
)
static

< Module has handled this stage.

< Module declines to handle

Definition at line 140 of file mod_heartbeat.c.

◆ hb_watchdog_step()

static int hb_watchdog_step ( server_rec s,
const char name,
apr_pool_t pool 
)
static

< Module has handled this stage.

Definition at line 130 of file mod_heartbeat.c.

Variable Documentation

◆ aplog_module_index

int* const aplog_module_index = &( heartbeat_module.module_index)
static

Definition at line 220 of file mod_heartbeat.c.

◆ hb_cmds

const command_rec hb_cmds[]
static
Initial value:
= {
{ "HeartbeatAddress" , cmd_hb_address , NULL , 128 , TAKE1, "Address to send heartbeat requests" },
{NULL}
}
@ TAKE1
Definition http_config.h:51
static const char * cmd_hb_address(cmd_parms *cmd, void *dconf, const char *addr)
return NULL
Definition mod_so.c:359

Definition at line 214 of file mod_heartbeat.c.

◆ msg_format

const char* msg_format = "v=%u&ready=%u&busy=%u"
static

Definition at line 41 of file mod_heartbeat.c.