#include <LogConfig.h>
Definition at line 108 of file LogConfig.h.
LogConfig::LogConfig | ( | ) |
Definition at line 527 of file LogConfig.cc.
LogConfig::~LogConfig | ( | ) |
Definition at line 550 of file LogConfig.cc.
References ats_free(), collation_host, collation_secret, common_log_header, common_log_name, extended2_log_header, extended2_log_name, extended_log_header, extended_log_name, hostname, hosts_config_file, logfile_dir, search_log_file_one, search_log_file_two, squid_log_header, squid_log_name, and xml_config_file.
bool LogConfig::am_collation_host | ( | ) | const [inline] |
Definition at line 129 of file LogConfig.h.
References collation_mode.
void LogConfig::display | ( | FILE * | fd = stdout |
) |
Definition at line 705 of file LogConfig.cc.
References auto_delete_rolled_files, collation_host, collation_host_tagged, collation_mode, collation_port, collation_preproc_threads, collation_secret, common_log_enabled, common_log_header, common_log_is_ascii, common_log_name, LogFormatList::count(), LogFilterList::count(), LogFormatList::display(), LogFilterList::display(), LogObjectManager::display(), extended2_log_enabled, extended2_log_header, extended2_log_is_ascii, extended2_log_name, extended_log_enabled, extended_log_header, extended_log_is_ascii, extended_log_name, file_stat_frequency, LogObjectManager::get_num_objects(), global_filter_list, global_format_list, hostname, hosts_config_file, log_buffer_size, log_object_manager, logfile_dir, logfile_perm, max_secs_per_buffer, max_space_mb_for_logs, max_space_mb_for_orphan_logs, max_space_mb_headroom, rolling_enabled, rolling_interval_sec, rolling_offset_hr, rolling_size_mb, sampling_frequency, separate_host_logs, separate_icp_logs, space_used_frequency, squid_log_enabled, squid_log_header, squid_log_is_ascii, squid_log_name, and xml_config_file.
int LogConfig::get_max_space_mb | ( | ) | [inline] |
Definition at line 143 of file LogConfig.h.
References max_space_mb_for_logs, and max_space_mb_for_orphan_logs.
Referenced by space_to_write(), and update_space_used().
bool LogConfig::has_api_objects | ( | ) | const [inline] |
Definition at line 151 of file LogConfig.h.
References LogObjectManager::has_api_objects(), and log_object_manager.
void LogConfig::increment_space_used | ( | int | bytes | ) | [inline] |
Definition at line 132 of file LogConfig.h.
References m_partition_space_left, and m_space_used.
void LogConfig::init | ( | LogConfig * | previous_config = 0 |
) |
Definition at line 642 of file LogConfig.cc.
References Debug, Log::error_log, Log::error_logging_enabled(), LogObjectManager::find_by_format_name(), LogObjectManager::get_num_collation_clients(), LogObjectManager::get_num_objects(), initialized, ink_assert, log_object_manager, MakePredefinedErrorLog(), max_space_mb_for_logs, max_space_mb_for_orphan_logs, LogObject::set_fmt_timestamps(), setup_log_objects(), Log::transaction_logging_enabled(), transfer_objects(), and update_space_used().
Referenced by Log::change_configuration(), and Log::init().
void LogConfig::read_configuration_variables | ( | ) |
Definition at line 172 of file LogConfig.cc.
References ascii_buffer_size, ats_free(), auto_delete_rolled_files, collation_host, collation_host_tagged, collation_max_send_buffers, collation_mode, collation_port, collation_preproc_threads, collation_retry_sec, collation_secret, common_log_enabled, common_log_header, common_log_is_ascii, common_log_name, custom_logs_enabled, extended2_log_enabled, extended2_log_header, extended2_log_is_ascii, extended2_log_name, extended_log_enabled, extended_log_header, extended_log_is_ascii, extended_log_name, file_stat_frequency, hostname, hosts_config_file, log_buffer_size, Log::LOG_MODE_FULL, logfile_dir, logfile_perm, Log::logging_mode, LogRollingEnabledIsValid(), max_line_size, max_secs_per_buffer, max_space_mb_for_logs, max_space_mb_for_orphan_logs, max_space_mb_headroom, REC_ConfigReadInteger(), REC_ConfigReadString(), RecConfigReadLogDir(), rolling_enabled, rolling_interval_sec, rolling_offset_hr, rolling_size_mb, sampling_frequency, search_log_enabled, search_log_filters, search_rolling_interval_sec, search_server_ip_addr, search_server_port, search_top_sites, search_url_filter, separate_host_logs, separate_icp_logs, space_used_frequency, squid_log_enabled, squid_log_header, squid_log_is_ascii, squid_log_name, val, Warning, and xml_config_file.
Referenced by Log::change_configuration(), and Log::init().
int LogConfig::reconfigure | ( | const char * | name, | |
RecDataT | data_type, | |||
RecData | data, | |||
void * | cookie | |||
) | [static] |
Definition at line 1100 of file LogConfig.cc.
References Log::config, Debug, and reconfiguration_needed.
Referenced by register_config_callbacks().
void * LogConfig::reconfigure_mgmt_variables | ( | void * | token, | |
char * | data_raw, | |||
int | data_len | |||
) | [static] |
Definition at line 163 of file LogConfig.cc.
References Log::config, Note, and roll_log_files_now.
Referenced by register_mgmt_callbacks().
void LogConfig::register_config_callbacks | ( | ) | [static] |
Definition at line 1116 of file LogConfig.cc.
References countof, REC_RegisterConfigUpdateFunc, and reconfigure().
static void LogConfig::register_configs | ( | ) | [static] |
void LogConfig::register_mgmt_callbacks | ( | ) | [static] |
Definition at line 1281 of file LogConfig.cc.
References REC_EVENT_ROLL_LOG_FILES, reconfigure_mgmt_variables(), and RecRegisterManagerCb().
void LogConfig::register_stat_callbacks | ( | ) | [static] |
Definition at line 1185 of file LogConfig.cc.
References log_rsb, log_stat_bytes_flush_to_disk_stat, log_stat_bytes_lost_before_flush_to_disk_stat, log_stat_bytes_lost_before_preproc_stat, log_stat_bytes_lost_before_sent_to_network_stat, log_stat_bytes_lost_before_written_to_disk_stat, log_stat_bytes_received_from_network_stat, log_stat_bytes_sent_to_network_stat, log_stat_bytes_written_to_disk_stat, log_stat_event_log_access_aggr_stat, log_stat_event_log_access_fail_stat, log_stat_event_log_access_full_stat, log_stat_event_log_access_ok_stat, log_stat_event_log_access_skip_stat, log_stat_event_log_error_aggr_stat, log_stat_event_log_error_fail_stat, log_stat_event_log_error_full_stat, log_stat_event_log_error_ok_stat, log_stat_event_log_error_skip_stat, log_stat_log_files_open_stat, log_stat_log_files_space_used_stat, log_stat_num_flush_to_disk_stat, log_stat_num_lost_before_flush_to_disk_stat, log_stat_num_lost_before_sent_to_network_stat, log_stat_num_received_from_network_stat, log_stat_num_sent_to_network_stat, RECD_COUNTER, RECD_INT, RECP_NON_PERSISTENT, RECP_PERSISTENT, RecRawStatSyncCount(), RecRawStatSyncSum(), RecRegisterRawStat, and RECT_PROCESS.
void LogConfig::setup_log_objects | ( | ) |
Definition at line 1011 of file LogConfig.cc.
References LogFilterList::clear(), countof, custom_logs_enabled, Debug, LogObjectManager::display(), global_filter_list, PreDefinedFormatList::init(), is_debug_tag_set, log_object_manager, LogObjectManager::open_local_pipes(), search_log_enabled, search_log_filters, and separate_host_logs.
Referenced by init().
bool LogConfig::space_is_short | ( | ) | [inline] |
Definition at line 130 of file LogConfig.h.
References LOG_MEGABYTE, max_space_mb_headroom, and space_to_write().
bool LogConfig::space_to_write | ( | int64_t | bytes_to_write | ) |
Definition at line 1294 of file LogConfig.cc.
References Debug, get_max_space_mb(), LOG_MEGABYTE, m_partition_space_left, m_space_used, and PARTITION_HEADROOM_MB.
Referenced by space_is_short(), and update_space_used().
void LogConfig::transfer_objects | ( | LogConfig * | old_config | ) | [inline] |
Definition at line 147 of file LogConfig.h.
References log_object_manager, and LogObjectManager::transfer_objects().
Referenced by init().
void LogConfig::update_space_used | ( | ) |
Definition at line 1337 of file LogConfig.cc.
References ats_free(), ats_malloc(), ats_strdup, auto_delete_rolled_files, Debug, delete_candidate_compare(), DISK_IS_ACTUAL_FULL_MESSAGE, DISK_IS_ACTUAL_LOW_MESSAGE, DISK_IS_CONFIG_FULL_MESSAGE, DISK_IS_CONFIG_LOW_MESSAGE, Error, get_max_space_mb(), ink_release_assert, LogUtils::LOG_ALARM_ERROR, log_buffer_size, LOG_MEGABYTE, log_rsb, log_stat_log_files_space_used_stat, logfile_dir, logging_space_exhausted, m_partition_space_left, m_space_used, LogUtils::manager_alarm(), max_space_mb_headroom, LogDeleteCandidate::mtime, LogDeleteCandidate::name, Note, RecSetRawStatCount(), RecSetRawStatSum(), LogFile::rolled_logfile(), LogDeleteCandidate::size, space_to_write(), and Warning.
Referenced by init().
Definition at line 208 of file LogConfig.h.
Referenced by read_configuration_variables().
Definition at line 191 of file LogConfig.h.
Referenced by display(), read_configuration_variables(), and update_space_used().
Definition at line 221 of file LogConfig.h.
Referenced by display(), read_configuration_variables(), and ~LogConfig().
Definition at line 183 of file LogConfig.h.
Referenced by display(), and read_configuration_variables().
Definition at line 186 of file LogConfig.h.
Referenced by read_configuration_variables(), and LogCollationClientSM::send().
Definition at line 181 of file LogConfig.h.
Referenced by am_collation_host(), display(), Log::init(), and read_configuration_variables().
Definition at line 182 of file LogConfig.h.
Referenced by Log::collate_thread_main(), display(), Log::init(), and read_configuration_variables().
Definition at line 184 of file LogConfig.h.
Referenced by display(), Log::init(), and read_configuration_variables().
Definition at line 185 of file LogConfig.h.
Referenced by read_configuration_variables().
Definition at line 222 of file LogConfig.h.
Referenced by Log::collate_thread_main(), display(), read_configuration_variables(), and ~LogConfig().
Definition at line 173 of file LogConfig.h.
Referenced by display(), PreDefinedFormatList::init(), and read_configuration_variables().
Definition at line 216 of file LogConfig.h.
Referenced by display(), PreDefinedFormatList::init(), read_configuration_variables(), and ~LogConfig().
Definition at line 174 of file LogConfig.h.
Referenced by display(), PreDefinedFormatList::init(), and read_configuration_variables().
Definition at line 215 of file LogConfig.h.
Referenced by display(), PreDefinedFormatList::init(), read_configuration_variables(), and ~LogConfig().
Definition at line 192 of file LogConfig.h.
Referenced by read_configuration_variables(), and setup_log_objects().
Definition at line 177 of file LogConfig.h.
Referenced by display(), PreDefinedFormatList::init(), and read_configuration_variables().
Definition at line 220 of file LogConfig.h.
Referenced by display(), PreDefinedFormatList::init(), read_configuration_variables(), and ~LogConfig().
Definition at line 178 of file LogConfig.h.
Referenced by display(), PreDefinedFormatList::init(), and read_configuration_variables().
Definition at line 219 of file LogConfig.h.
Referenced by display(), PreDefinedFormatList::init(), read_configuration_variables(), and ~LogConfig().
Definition at line 175 of file LogConfig.h.
Referenced by display(), PreDefinedFormatList::init(), and read_configuration_variables().
Definition at line 218 of file LogConfig.h.
Referenced by display(), PreDefinedFormatList::init(), read_configuration_variables(), and ~LogConfig().
Definition at line 176 of file LogConfig.h.
Referenced by display(), PreDefinedFormatList::init(), and read_configuration_variables().
Definition at line 217 of file LogConfig.h.
Referenced by display(), PreDefinedFormatList::init(), read_configuration_variables(), and ~LogConfig().
Definition at line 205 of file LogConfig.h.
Referenced by display(), and read_configuration_variables().
Definition at line 162 of file LogConfig.h.
Referenced by display(), and setup_log_objects().
Definition at line 163 of file LogConfig.h.
Referenced by display(), PreDefinedFormatList::init(), and MakePredefinedErrorLog().
char* LogConfig::hostname |
Definition at line 211 of file LogConfig.h.
Referenced by display(), read_configuration_variables(), and ~LogConfig().
Definition at line 224 of file LogConfig.h.
Referenced by display(), read_configuration_variables(), and ~LogConfig().
Definition at line 154 of file LogConfig.h.
Referenced by init().
Definition at line 165 of file LogConfig.h.
Referenced by display(), read_configuration_variables(), and update_space_used().
Definition at line 161 of file LogConfig.h.
Referenced by Log::access(), Log::change_configuration(), display(), has_api_objects(), init(), Log::match_logobject(), Log::preproc_thread_main(), setup_log_objects(), transfer_objects(), and TSTextLogObjectCreate().
char* LogConfig::logfile_dir |
Definition at line 212 of file LogConfig.h.
Referenced by display(), read_configuration_variables(), update_space_used(), and ~LogConfig().
Definition at line 170 of file LogConfig.h.
Referenced by display(), LogFile::open_file(), and read_configuration_variables().
Definition at line 156 of file LogConfig.h.
Referenced by update_space_used().
Definition at line 158 of file LogConfig.h.
Referenced by increment_space_used(), space_to_write(), and update_space_used().
int64_t LogConfig::m_space_used |
Definition at line 157 of file LogConfig.h.
Referenced by increment_space_used(), space_to_write(), and update_space_used().
Definition at line 209 of file LogConfig.h.
Referenced by read_configuration_variables().
Definition at line 166 of file LogConfig.h.
Referenced by display(), LogBuffer::LogBuffer(), and read_configuration_variables().
Definition at line 167 of file LogConfig.h.
Referenced by display(), get_max_space_mb(), init(), and read_configuration_variables().
Definition at line 168 of file LogConfig.h.
Referenced by display(), get_max_space_mb(), init(), and read_configuration_variables().
Definition at line 169 of file LogConfig.h.
Referenced by display(), read_configuration_variables(), space_is_short(), and update_space_used().
Definition at line 155 of file LogConfig.h.
Referenced by reconfigure().
Definition at line 159 of file LogConfig.h.
Referenced by reconfigure_mgmt_variables().
Definition at line 187 of file LogConfig.h.
Referenced by display(), and read_configuration_variables().
Definition at line 188 of file LogConfig.h.
Referenced by display(), and read_configuration_variables().
Definition at line 189 of file LogConfig.h.
Referenced by display(), and read_configuration_variables().
Definition at line 190 of file LogConfig.h.
Referenced by display(), and read_configuration_variables().
Definition at line 204 of file LogConfig.h.
Referenced by display(), and read_configuration_variables().
Definition at line 194 of file LogConfig.h.
Referenced by read_configuration_variables(), and setup_log_objects().
Definition at line 201 of file LogConfig.h.
Referenced by ~LogConfig().
Definition at line 202 of file LogConfig.h.
Referenced by ~LogConfig().
Definition at line 199 of file LogConfig.h.
Referenced by read_configuration_variables(), and setup_log_objects().
Definition at line 195 of file LogConfig.h.
Referenced by read_configuration_variables().
unsigned int LogConfig::search_server_ip_addr |
Definition at line 196 of file LogConfig.h.
Referenced by read_configuration_variables().
Definition at line 197 of file LogConfig.h.
Referenced by read_configuration_variables().
Definition at line 198 of file LogConfig.h.
Referenced by read_configuration_variables().
Definition at line 200 of file LogConfig.h.
Referenced by read_configuration_variables().
Definition at line 180 of file LogConfig.h.
Referenced by display(), read_configuration_variables(), and setup_log_objects().
Definition at line 179 of file LogConfig.h.
Referenced by display(), and read_configuration_variables().
Definition at line 206 of file LogConfig.h.
Referenced by display(), and read_configuration_variables().
Definition at line 171 of file LogConfig.h.
Referenced by display(), PreDefinedFormatList::init(), and read_configuration_variables().
Definition at line 214 of file LogConfig.h.
Referenced by display(), PreDefinedFormatList::init(), read_configuration_variables(), and ~LogConfig().
Definition at line 172 of file LogConfig.h.
Referenced by display(), PreDefinedFormatList::init(), and read_configuration_variables().
Definition at line 213 of file LogConfig.h.
Referenced by display(), PreDefinedFormatList::init(), read_configuration_variables(), and ~LogConfig().
Definition at line 223 of file LogConfig.h.
Referenced by display(), read_configuration_variables(), and ~LogConfig().