ChildConfig.h
Go to the documentation of this file.
1/*
2 * Copyright (C) 1996-2023 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
12namespace Helper
13{
14
22{
23public:
25 explicit ChildConfig(const unsigned int m);
26
34 int needNew() const;
35 void parseConfig();
36
43
44 /* values from squid.conf */
45public:
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
96 actErr
97 };
100
107
109 time_t reservationTimeout = 64; // reservation-timeout
110};
111
112} // namespace Helper
113
114/* Legacy parser interface */
115#define parse_HelperChildConfig(c) (c)->parseConfig()
116#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)
117#define free_HelperChildConfig(dummy) // NO.
118
119#endif /* _SQUID_SRC_HELPER_CHILDCONFIG_H */
120
unsigned int n_max
Definition: ChildConfig.h:48
unsigned int n_running
Definition: ChildConfig.h:80
unsigned int n_startup
Definition: ChildConfig.h:57
unsigned int n_idle
Definition: ChildConfig.h:66
unsigned int n_active
Definition: ChildConfig.h:86
unsigned int queue_size
Definition: ChildConfig.h:91
ChildConfig & updateLimits(const ChildConfig &rhs)
Definition: ChildConfig.cc:44
time_t reservationTimeout
older stateful helper server reservations may be forgotten
Definition: ChildConfig.h:109
unsigned int concurrency
Definition: ChildConfig.h:72
SubmissionErrorHandlingAction onPersistentOverload
how to handle a new request for helper that was overloaded for too long
Definition: ChildConfig.h:99
SubmissionErrorHandlingAction
how to handle a serious problem with a helper request submission
Definition: ChildConfig.h:94
@ actDie
kill the caller process (i.e., Squid worker)
Definition: ChildConfig.h:95
@ actErr
drop the request and send an error to the caller
Definition: ChildConfig.h:96
int needNew() const
Definition: ChildConfig.cc:59
helper protocol primitives
Definition: helper.h:39

 

Introduction

Documentation

Support

Miscellaneous

Web Site Translations

Mirrors