ChildConfig.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 1996-2017 The Squid Software Foundation and contributors
3  *
4  * Squid software is distributed under GPLv2+ license and includes
5  * contributions from numerous individuals and organizations.
6  * Please see the COPYING and CONTRIBUTORS files for details.
7  */
8 
9 #ifndef _SQUID_SRC_HELPER_CHILDCONFIG_H
10 #define _SQUID_SRC_HELPER_CHILDCONFIG_H
11 
12 namespace Helper
13 {
14 
22 {
23 public:
24  ChildConfig();
25  explicit ChildConfig(const unsigned int m);
26 
34  int needNew() const;
35  void parseConfig();
36 
43 
44  /* values from squid.conf */
45 public:
46 
48  unsigned int n_max;
49 
57  unsigned int n_startup;
58 
66  unsigned int n_idle;
67 
72  unsigned int concurrency;
73 
74  /* derived from active operations */
75 
80  unsigned int n_running;
81 
86  unsigned int n_active;
87 
91  unsigned int queue_size;
92 
97  };
100 
107 };
108 
109 } // namespace Helper
110 
111 /* Legacy parser interface */
112 #define parse_HelperChildConfig(c) (c)->parseConfig()
113 #define dump_HelperChildConfig(e,n,c) storeAppendPrintf((e), "\n%s %d startup=%d idle=%d concurrency=%d\n", (n), (c).n_max, (c).n_startup, (c).n_idle, (c).concurrency)
114 #define free_HelperChildConfig(dummy) // NO.
115 
116 #endif /* _SQUID_SRC_HELPER_CHILDCONFIG_H */
117 
unsigned int n_active
Definition: ChildConfig.h:86
kill the caller process (i.e., Squid worker)
Definition: ChildConfig.h:95
unsigned int n_max
Definition: ChildConfig.h:48
ChildConfig & updateLimits(const ChildConfig &rhs)
Definition: ChildConfig.cc:44
unsigned int n_idle
Definition: ChildConfig.h:66
unsigned int n_startup
Definition: ChildConfig.h:57
SubmissionErrorHandlingAction
how to handle a serious problem with a helper request submission
Definition: ChildConfig.h:94
unsigned int n_running
Definition: ChildConfig.h:80
SubmissionErrorHandlingAction onPersistentOverload
how to handle a new request for helper that was overloaded for too long
Definition: ChildConfig.h:99
drop the request and send an error to the caller
Definition: ChildConfig.h:96
unsigned int concurrency
Definition: ChildConfig.h:72
unsigned int queue_size
Definition: ChildConfig.h:91
int needNew() const
Definition: ChildConfig.cc:59

 

Introduction

Documentation

Support

Miscellaneous

Web Site Translations

Mirrors