#include <Config.h>

Inheritance diagram for Adaptation::Icap::Config:
Collaboration diagram for Adaptation::Icap::Config:

Public Types

typedef std::vector< ServiceConfigPointerServiceConfigs
 

Public Member Functions

 Config ()
 
 ~Config () override
 
time_t connect_timeout (bool bypassable) const
 
time_t io_timeout (bool bypassable) const
 
void parseService (void)
 
void freeService (void)
 
void dumpService (StoreEntry *, const char *) const
 
ServiceConfigPointer findServiceConfig (const String &)
 
virtual bool finalize ()
 

Static Public Member Functions

static void Finalize (bool enable)
 
static void ParseServiceSet (void)
 
static void ParseServiceChain (void)
 
static void ParseAccess (ConfigParser &parser)
 
static void FreeAccess (void)
 
static void DumpAccess (StoreEntry *, const char *)
 

Public Attributes

int default_options_ttl
 
int preview_enable
 
int preview_size
 
int allow206_enable
 
time_t connect_timeout_raw
 
time_t io_timeout_raw
 
int reuse_connections
 
char * client_username_header
 
int client_username_encode
 
acl_accessrepeat
 icap_retry ACL in squid.conf More...
 
int repeat_limit
 icap_retry_limit in squid.conf More...
 
int onoff
 
int service_failure_limit
 
time_t oldest_service_failure
 
int service_revival_delay
 
ServiceConfigs serviceConfigs
 

Static Public Attributes

static bool Enabled = false
 
static char * masterx_shared_name = nullptr
 
static int service_iteration_limit = 16
 
static int send_client_ip = false
 
static int send_username = false
 
static int use_indirect_client = true
 
static Notes metaHeaders
 The list of configured meta headers. More...
 
static bool needHistory = false
 HttpRequest adaptation history should recorded. More...
 

Protected Member Functions

virtual void clear ()
 Removes any reference to the services from configuration. More...
 
virtual ServiceConfignewServiceConfig () const
 creates service configuration object that will parse and keep cfg info More...
 
void removeService (const String &service)
 Removes the given service from all service groups. More...
 
void removeRule (const String &id)
 Removes access rules of the given service or group. More...
 

Private Member Functions

 Config (const Config &)
 
Configoperator= (const Config &)
 
Adaptation::ServicePointer createService (const ServiceConfigPointer &cfg) override
 

Static Private Member Functions

static void ParseServiceGroup (ServiceGroupPointer group)
 
static void FreeServiceGroups (void)
 
static void DumpServiceGroups (StoreEntry *, const char *)
 

Detailed Description

Definition at line 25 of file Config.h.

Member Typedef Documentation

◆ ServiceConfigs

Definition at line 62 of file Config.h.

Constructor & Destructor Documentation

◆ Config() [1/2]

Adaptation::Icap::Config::Config ( )

Definition at line 21 of file Config.cc.

◆ ~Config()

Adaptation::Icap::Config::~Config ( )
overridevirtual

Reimplemented from Adaptation::Config.

Definition at line 30 of file Config.cc.

◆ Config() [2/2]

Adaptation::Icap::Config::Config ( const Config )
private

Member Function Documentation

◆ clear()

void Adaptation::Config::clear ( )
protectedvirtualinherited

Definition at line 121 of file Config.cc.

References Adaptation::AllGroups(), Adaptation::AllRules(), debugs, and size.

◆ connect_timeout()

time_t Adaptation::Icap::Config::connect_timeout ( bool  bypassable) const

◆ createService()

Adaptation::ServicePointer Adaptation::Icap::Config::createService ( const ServiceConfigPointer cfg)
overrideprivatevirtual

Implements Adaptation::Config.

Definition at line 36 of file Config.cc.

◆ DumpAccess()

void Adaptation::Config::DumpAccess ( StoreEntry entry,
const char *  name 
)
staticinherited

◆ dumpService()

◆ DumpServiceGroups()

void Adaptation::Config::DumpServiceGroups ( StoreEntry entry,
const char *  name 
)
staticprivateinherited

◆ finalize()

bool Adaptation::Config::finalize ( )
virtualinherited

Creates and starts the adaptation services. In the case the adaptation mechanism is disabled then removes any reference to the services from access rules and service groups, and returns false.

Returns
true if the services are ready and running, false otherwise

Reimplemented in Adaptation::Ecap::Config.

Definition at line 184 of file Config.cc.

References Adaptation::AllServices(), DBG_CRITICAL, debugs, Adaptation::FindService(), and Adaptation::ServiceConfig::key.

Referenced by Adaptation::Ecap::Config::finalize(), mainInitialize(), and mainReconfigureFinish().

◆ Finalize()

void Adaptation::Config::Finalize ( bool  enable)
staticinherited

◆ findServiceConfig()

Adaptation::ServiceConfigPointer Adaptation::Config::findServiceConfig ( const String service)
inherited

Definition at line 91 of file Config.cc.

◆ FreeAccess()

void Adaptation::Config::FreeAccess ( void  )
staticinherited

Definition at line 290 of file Config.cc.

References Adaptation::AllRules().

◆ freeService()

void Adaptation::Config::freeService ( void  )
inherited

◆ FreeServiceGroups()

void Adaptation::Config::FreeServiceGroups ( void  )
staticprivateinherited

Definition at line 261 of file Config.cc.

References Adaptation::AllGroups().

◆ io_timeout()

time_t Adaptation::Icap::Config::io_timeout ( bool  bypassable) const

Definition at line 49 of file Config.cc.

References Config, SquidConfig::read, and SquidConfig::Timeout.

Referenced by Adaptation::Icap::Xaction::updateTimeout().

◆ newServiceConfig()

Adaptation::ServiceConfig * Adaptation::Config::newServiceConfig ( ) const
protectedvirtualinherited

Reimplemented in Adaptation::Ecap::Config.

Definition at line 54 of file Config.cc.

◆ operator=()

Config & Adaptation::Icap::Config::operator= ( const Config )
private

◆ ParseAccess()

void Adaptation::Config::ParseAccess ( ConfigParser parser)
staticinherited

◆ parseService()

void Adaptation::Config::parseService ( void  )
inherited

◆ ParseServiceChain()

void Adaptation::Config::ParseServiceChain ( void  )
staticinherited

Definition at line 247 of file Config.cc.

References Adaptation::Config::ParseServiceGroup().

Referenced by parse_adaptation_service_chain_type().

◆ ParseServiceGroup()

void Adaptation::Config::ParseServiceGroup ( ServiceGroupPointer  group)
staticprivateinherited

◆ ParseServiceSet()

void Adaptation::Config::ParseServiceSet ( void  )
staticinherited

◆ removeRule()

void Adaptation::Config::removeRule ( const String id)
protectedinherited

Definition at line 103 of file Config.cc.

References Adaptation::AllRules(), debugs, and Adaptation::AccessRule::groupId.

◆ removeService()

void Adaptation::Config::removeService ( const String service)
protectedinherited

Member Data Documentation

◆ allow206_enable

int Adaptation::Icap::Config::allow206_enable

◆ client_username_encode

int Adaptation::Icap::Config::client_username_encode

Definition at line 37 of file Config.h.

Referenced by Adaptation::Icap::ModXact::makeUsernameHeader().

◆ client_username_header

char* Adaptation::Icap::Config::client_username_header

Definition at line 36 of file Config.h.

Referenced by Adaptation::Icap::ModXact::makeUsernameHeader().

◆ connect_timeout_raw

time_t Adaptation::Icap::Config::connect_timeout_raw

Definition at line 33 of file Config.h.

◆ default_options_ttl

int Adaptation::Icap::Config::default_options_ttl

Definition at line 29 of file Config.h.

Referenced by Adaptation::Icap::Options::ttl().

◆ Enabled

bool Adaptation::Config::Enabled = false
staticinherited

Definition at line 42 of file Config.h.

Referenced by Adaptation::AccessCheck::Start().

◆ io_timeout_raw

time_t Adaptation::Icap::Config::io_timeout_raw

Definition at line 34 of file Config.h.

◆ masterx_shared_name

◆ metaHeaders

◆ needHistory

bool Adaptation::Config::needHistory = false
staticinherited

◆ oldest_service_failure

◆ onoff

int Adaptation::Config::onoff
inherited

Definition at line 53 of file Config.h.

Referenced by mainInitialize(), and mainReconfigureFinish().

◆ preview_enable

int Adaptation::Icap::Config::preview_enable

Definition at line 30 of file Config.h.

Referenced by Adaptation::Icap::ModXact::decideOnPreview().

◆ preview_size

int Adaptation::Icap::Config::preview_size

Definition at line 31 of file Config.h.

◆ repeat

acl_access* Adaptation::Icap::Config::repeat

Definition at line 38 of file Config.h.

Referenced by Adaptation::Icap::Launcher::canRepeat().

◆ repeat_limit

int Adaptation::Icap::Config::repeat_limit

◆ reuse_connections

int Adaptation::Icap::Config::reuse_connections

◆ send_client_ip

int Adaptation::Config::send_client_ip = false
staticinherited

◆ send_username

int Adaptation::Config::send_username = false
staticinherited

Definition at line 48 of file Config.h.

Referenced by Adaptation::Icap::ModXact::makeRequestHeaders().

◆ service_failure_limit

int Adaptation::Config::service_failure_limit
inherited

◆ service_iteration_limit

int Adaptation::Config::service_iteration_limit = 16
staticinherited

Definition at line 46 of file Config.h.

Referenced by Adaptation::Iterator::step().

◆ service_revival_delay

int Adaptation::Config::service_revival_delay
inherited

◆ serviceConfigs

ServiceConfigs Adaptation::Config::serviceConfigs
inherited

Definition at line 63 of file Config.h.

◆ use_indirect_client

int Adaptation::Config::use_indirect_client = true
staticinherited

The documentation for this class was generated from the following files:

 

Introduction

Documentation

Support

Miscellaneous

Web Site Translations

Mirrors