pazpar2
1.14.1
|
Go to the source code of this file.
Data Structures | |
struct | http_channel |
struct | http_proxy |
struct | http_header |
struct | http_argument |
struct | http_request |
struct | http_response |
Typedefs | |
typedef struct http_channel_observer_s * | http_channel_observer_t |
typedef struct http_server * | http_server_t |
typedef struct http_sessions * | http_sessions_t |
typedef void(* | http_channel_destroy_t) (void *data, struct http_channel *c, void *data2) |
typedef void(* http_channel_destroy_t) (void *data, struct http_channel *c, void *data2) |
typedef struct http_channel_observer_s* http_channel_observer_t |
typedef struct http_server* http_server_t |
typedef struct http_sessions* http_sessions_t |
http_channel_observer_t http_add_observer | ( | struct http_channel * | c, |
void * | data, | ||
http_channel_destroy_t | des | ||
) |
Definition at line 1430 of file http.c.
References http_channel_observer_s::chan, http_channel_observer_s::data, http_channel_observer_s::data2, http_channel_observer_s::destroy, http_channel_observer_s::next, and http_channel::observers.
Referenced by session_set_watch(), and show_record().
void http_addheader | ( | struct http_response * | r, |
const char * | name, | ||
const char * | value | ||
) |
Definition at line 282 of file http.c.
References http_response::channel, http_response::headers, http_header::name, name, http_header::next, http_channel::nmem, and http_header::value.
Referenced by http_command().
const char* http_argbyname | ( | struct http_request * | r, |
const char * | name | ||
) |
Definition at line 292 of file http.c.
References http_request::arguments, http_argument::name, name, http_argument::next, and http_argument::value.
Referenced by bytarget_response(), cmd_bytarget(), cmd_init(), cmd_search(), cmd_show(), cmd_termlist(), get_version(), http_command(), locate_session(), show_record(), show_records(), termlist_response(), and termlist_result_ready().
struct http_channel* http_channel_observer_chan | ( | http_channel_observer_t | obs | ) |
Definition at line 1455 of file http.c.
References http_channel_observer_s::chan.
Referenced by show_raw_record_error(), show_raw_record_ok(), and show_raw_record_ok_binary().
void http_close_server | ( | struct conf_server * | ser | ) |
Definition at line 1362 of file http.c.
References conf_server::http_server, and http_server::listener_socket.
Referenced by cmd_exit(), and config_stop_listeners().
void http_command | ( | struct http_channel * | c | ) |
Definition at line 1497 of file http_command.c.
References commands, error(), http_addheader(), http_argbyname(), http_create_response(), name, PAZPAR2_MALFORMED_PARAMETER_VALUE, PAZPAR2_MISSING_PARAMETER, http_channel::request, and http_channel::response.
Referenced by http_io().
struct http_response* http_create_response | ( | struct http_channel * | c | ) |
Definition at line 311 of file http.c.
References http_response::channel, http_response::code, http_response::content_type, http_response::headers, http_response::msg, http_channel::nmem, and http_response::payload.
Referenced by http_command(), http_error(), and http_parse_response_buf().
struct http_header* http_header_append | ( | struct http_channel * | ch, |
struct http_header * | hp, | ||
const char * | name, | ||
const char * | value | ||
) |
Definition at line 702 of file http.c.
References http_header::name, name, http_header::next, http_channel::nmem, and http_header::value.
Referenced by http_proxy().
const char* http_headerbyname | ( | struct http_header * | r, |
const char * | name | ||
) |
Definition at line 303 of file http.c.
References http_header::name, name, http_header::next, and http_header::value.
int http_init | ( | struct conf_server * | ser, |
const char * | record_fname | ||
) |
Definition at line 1238 of file http.c.
References CLOSESOCKET, error(), EVENT_EXCEPT, EVENT_INPUT, conf_server::host, http_accept(), conf_server::http_server, http_server_create(), iochan_add(), iochan_create(), iochan_destroy(), conf_server::iochan_man, iochan_setdata, http_server::listener_socket, conf_server::port, and http_server::record_file.
Referenced by config_start_listeners().
const char* http_lookup_header | ( | struct http_header * | header, |
const char * | name | ||
) |
Definition at line 119 of file http.c.
References http_header::name, name, http_header::next, and http_header::value.
Referenced by cmd_init(), cmd_settings(), http_parse_request(), and http_proxy().
void http_mutex_init | ( | struct conf_server * | server | ) |
Definition at line 1509 of file http.c.
References conf_server::http_server, http_server::http_sessions, http_sessions_create(), http_server::mutex, pazpar2_mutex_create(), and http_channel::server.
Referenced by config_process_events().
void http_observer_set_data2 | ( | http_channel_observer_t | obs, |
void * | data2 | ||
) |
Definition at line 1460 of file http.c.
References http_channel_observer_s::data2.
void http_remove_observer | ( | http_channel_observer_t | obs | ) |
Definition at line 1443 of file http.c.
References http_channel_observer_s::chan, http_channel_observer_s::next, and http_channel::observers.
Referenced by session_alert_watch(), show_raw_record_error(), show_raw_record_ok(), show_raw_record_ok_binary(), and show_record().
void http_send_response | ( | struct http_channel * | c | ) |
Definition at line 844 of file http.c.
References EVENT_OUTPUT, http_buf_enqueue(), http_channel_destroy(), http_serialize_response(), http_channel::iochan, iochan_getfd, iochan_setflag, http_channel::oqueue, http_request::path, http_channel::request, http_channel::response, http_request::search, http_channel::state, and http_channel::yt.
Referenced by error2(), http_error(), response_close(), show_raw_record_ok(), and show_raw_record_ok_binary().
void http_server_destroy | ( | http_server_t | hs | ) |
Definition at line 1479 of file http.c.
References http_server::http_sessions, http_sessions_destroy(), http_server::mutex, http_server::proxy_addr, http_server::record_file, and http_server::ref_count.
Referenced by http_channel_destroy(), and server_destroy().
http_sessions_t http_sessions_create | ( | void | ) |
Definition at line 98 of file http_command.c.
References http_sessions::log_level, http_sessions::mutex, pazpar2_mutex_create(), and http_sessions::session_list.
Referenced by http_mutex_init().
void http_sessions_destroy | ( | http_sessions_t | hs | ) |
Definition at line 108 of file http_command.c.
References iochan_destroy(), http_sessions::mutex, http_session::next, http_session::nmem, http_session::psession, session_destroy(), http_sessions::session_list, and http_session::timeout_iochan.
Referenced by http_server_destroy().
void http_set_proxyaddr | ( | const char * | url, |
struct conf_server * | ser | ||
) |
Definition at line 1375 of file http.c.
References conf_server::http_server, and http_server::proxy_addr.
Referenced by config_start_listeners().