Skip to content

File broker_shm.c

FileList > broker > broker_shm.c

Go to the source code of this file

  • #include <stdio.h>
  • #include <sys/types.h>
  • #include <errno.h>
  • #include <assert.h>
  • #include <sys/ipc.h>
  • #include <sys/shm.h>
  • #include <netdb.h>
  • #include "cas_common.h"
  • #include "broker_shm.h"
  • #include "broker_error.h"
  • #include "broker_filename.h"
  • #include "broker_util.h"
  • #include "host_lookup.h"
  • #include "error_code.h"
  • #include "system_parameter.h"

Public Functions

Type Name
T_SHM_APPL_SERVER * broker_shm_initialize_shm_as (T_BROKER_INFO * br_info_p, T_SHM_PROXY * shm_proxy_p)
T_SHM_BROKER * broker_shm_initialize_shm_broker (int master_shm_id, T_BROKER_INFO * br_info, int br_num, int acl_flag, char * acl_file, int acl_default_policy, char * admin_log_file)
int uw_sem_destroy (sem_t * sem)
int uw_sem_init (sem_t * sem)
int uw_sem_post (sem_t * sem)
int uw_sem_wait (sem_t * sem)
void * uw_shm_create (int shm_key, int size, int which_shm)
int uw_shm_destroy (int shm_key)
void uw_shm_detach (void * p)
void * uw_shm_open (int shm_key, int which_shm, T_SHM_MODE shm_mode)

Public Static Functions

Type Name
void broker_shm_set_as_info (T_SHM_APPL_SERVER * shm_appl, T_APPL_SERVER_INFO * as_info_p, T_BROKER_INFO * br_info_p, int as_index)
void get_access_log_file_name (char * access_log_file, char * access_log_path, char * broker_name, int len)
const char * get_appl_server_name (int appl_server_type)
void get_error_log_file_name (char * access_log_file, char * error_log_path, char * broker_name, int len)
int get_host_ip (unsigned char * ip_addr)
void shard_shm_set_shard_conn_info (T_SHM_APPL_SERVER * shm_as_p, T_SHM_PROXY * shm_proxy_p)

Macros

Type Name
define SHMODE 0644

Public Functions Documentation

function broker_shm_initialize_shm_as

T_SHM_APPL_SERVER * broker_shm_initialize_shm_as (
    T_BROKER_INFO * br_info_p,
    T_SHM_PROXY * shm_proxy_p
) 

function broker_shm_initialize_shm_broker

T_SHM_BROKER * broker_shm_initialize_shm_broker (
    int master_shm_id,
    T_BROKER_INFO * br_info,
    int br_num,
    int acl_flag,
    char * acl_file,
    int acl_default_policy,
    char * admin_log_file
) 

function uw_sem_destroy

int uw_sem_destroy (
    sem_t * sem
) 

function uw_sem_init

int uw_sem_init (
    sem_t * sem
) 

function uw_sem_post

int uw_sem_post (
    sem_t * sem
) 

function uw_sem_wait

int uw_sem_wait (
    sem_t * sem
) 

function uw_shm_create

void * uw_shm_create (
    int shm_key,
    int size,
    int which_shm
) 

function uw_shm_destroy

int uw_shm_destroy (
    int shm_key
) 

function uw_shm_detach

void uw_shm_detach (
    void * p
) 

function uw_shm_open

void * uw_shm_open (
    int shm_key,
    int which_shm,
    T_SHM_MODE shm_mode
) 

Public Static Functions Documentation

function broker_shm_set_as_info

static void broker_shm_set_as_info (
    T_SHM_APPL_SERVER * shm_appl,
    T_APPL_SERVER_INFO * as_info_p,
    T_BROKER_INFO * br_info_p,
    int as_index
) 

function get_access_log_file_name

static void get_access_log_file_name (
    char * access_log_file,
    char * access_log_path,
    char * broker_name,
    int len
) 

function get_appl_server_name

static const  char * get_appl_server_name (
    int appl_server_type
) 

function get_error_log_file_name

static void get_error_log_file_name (
    char * access_log_file,
    char * error_log_path,
    char * broker_name,
    int len
) 

function get_host_ip

static int get_host_ip (
    unsigned  char * ip_addr
) 

function shard_shm_set_shard_conn_info

static void shard_shm_set_shard_conn_info (
    T_SHM_APPL_SERVER * shm_as_p,
    T_SHM_PROXY * shm_proxy_p
) 

Macro Definition Documentation

define SHMODE

#define SHMODE `0644`


The documentation for this class was generated from the following file cubrid/src/broker/broker_shm.c