# and now, build the option pages
my (@names) = keys %option;
foreach $name (@names) {
+ next if $option{$name}->{'type'} eq "obsolete";
generate_page("${top}/${pagetemplate}", $option{$name});
}
foreach $name (sort keys %all_names) {
my ($data) = $all_names{$name};
+ next if $data->{'type'} eq "obsolete";
print $fh ' <li><a href="' . uriescape($data->{'name'}) . '.html" name="toc_' . htmlescape($name) . '">' . htmlescape($name) . "</a></li>\n";
}
static void default_all(void);
static void defaults_if_none(void);
static int parse_line(char *);
+static void parse_obsolete(const char *);
static void parseBytesLine(size_t * bptr, const char *units);
#if !USE_DNSSERVERS
static void parseBytesLineSigned(ssize_t * bptr, const char *units);
#endif
}
+/** Parse a line containing an obsolete directive.
+ * To upgrade it where possible instead of just "Bungled config" for
+ * directives which cannot be marked as simply aliases of the some name.
+ * For example if the parameter order and content has changed.
+ * Or if the directive has been completely removed.
+ */
+void
+parse_obsolete(const char *name)
+{
+ // Directives which have been radically changed rather than removed
+ if (!strcmp(name, "url_rewrite_concurrency")) {
+ debugs(3, DBG_CRITICAL, "WARNING: url_rewrite_concurrency upgrade overriding url_rewrite_children settings.");
+ parse_int(&Config.redirectChildren.concurrency);
+ }
+}
+
/* Parse a time specification from the config file. Store the
* result in 'tptr', after converting it to 'units' */
static void
kb_size_t
logformat
memcachemode
+obsolete
onoff
peer
peer_access cache_peer acl
across all Squid processes.
COMMENT_END
+# Options Removed in 3.2
+NAME: ignore_expect_100
+TYPE: obsolete
+DOC_START
+ Remove this line. The HTTP/1.1 feature is now fully supported by default.
+DOC_END
+
+NAME: ftp_list_width
+TYPE: obsolete
+DOC_START
+ Remove this line. Configure FTP page display using the CSS controls in errorpages.css instead.
+DOC_END
+
+NAME: url_rewrite_concurrency
+TYPE: obsolete
+DOC_START
+ Remove this line. Set the 'concurrency=' option of url_rewrite_children instead.
+DOC_END
+
+# Options Removed in 3.1
+NAME: dns_testnames
+TYPE: obsolete
+DOC_START
+ Remove this line. DNS is no longer tested on startup.
+DOC_END
+
+NAME: extension_methods
+TYPE: obsolete
+DOC_START
+ Remove this line. All valid methods for HTTP are accepted by default.
+DOC_END
+
+# 2.7 Options Removed/Replaced in 3.1
+NAME: incoming_rate
+TYPE: obsolete
+DOC_NONE
+
+NAME: server_http11
+TYPE: obsolete
+DOC_START
+ Remove this line. HTTP/1.1 is supported by default.
+DOC_END
+
+NAME: upgrade_http0.9
+TYPE: obsolete
+DOC_START
+ Remove this line. ICY/1.0 streaming protocol is supported by default.
+DOC_END
+
+NAME: zph_local zph_mode zph_option zph_parent zph_sibling
+TYPE: obsolete
+DOC_START
+ Alter these entries. Use the qos_flows directive instead.
+DOC_END
+
+# Options Removed in 3.0
+NAME: header_access
+TYPE: obsolete
+DOC_START
+ Since squid-3.0 replace with request_header_access or reply_header_access
+ depending on whether you wish to match client requests or server replies.
+DOC_END
+
+NAME: httpd_accel_no_pmtu_disc
+TYPE: obsolete
+DOC_START
+ Since squid-3.0 use the 'disable-pmtu-discovery' flag on http_port instead.
+DOC_END
+
COMMENT_START
OPTIONS FOR AUTHENTICATION
-----------------------------------------------------------------------------
if (!strcmp(entry->name, "comment"))
continue;
+ if (!strcmp(entry->type, "obsolete"))
+ continue;
+
if (entry->loc == NULL) {
fprintf(stderr, "NO LOCATION FOR %s\n", entry->name);
rc |= 1;
for (entry = head; entry != NULL; entry = entry->next) {
assert(entry->name);
- assert(entry->loc);
+
+ if (!entry->loc)
+ continue;
if (entry->default_if_none == NULL)
continue;
{
fprintf(fp, "\tif (!strcmp(token, \"%s\")) {\n", name);
- if (strcmp(entry->loc, "none") == 0) {
+ if (strcmp(entry->type,"obsolete") == 0) {
+ fprintf(fp, "\t\tdebugs(0, DBG_CRITICAL, \"ERROR: Directive '%s' is obsolete.\");\n", name);
+ for (Line *line = entry->doc; line != NULL; line = line->next) {
+ // offset line to strip initial whitespace tab byte
+ fprintf(fp, "\t\tdebugs(0, opt_parse_cfg_only?0:1, \"%s : %s\");\n", name, &line->data[1]);
+ }
+ fprintf(fp, "\t\tparse_obsolete(token);\n");
+ } else if (!entry->loc || strcmp(entry->loc, "none") == 0) {
fprintf(fp,
"\t\tparse_%s();\n",
entry->type
EntryAlias *alias = entry->alias;
- assert (entry->loc);
-
bool more;
do {
);
for (entry = head; entry != NULL; entry = entry->next) {
- assert(entry->loc);
- if (strcmp(entry->loc, "none") == 0)
+ if (!entry->loc || strcmp(entry->loc, "none") == 0)
continue;
if (strcmp(entry->name, "comment") == 0)
);
for (entry = head; entry != NULL; entry = entry->next) {
- assert(entry->loc);
-
- if (strcmp(entry->loc, "none") == 0)
+ if (!entry->loc || strcmp(entry->loc, "none") == 0)
continue;
if (strcmp(entry->name, "comment") == 0)
if (!strcmp(entry->name, "comment"))
(void) 0;
+ else if (!strcmp(entry->name, "obsolete"))
+ (void) 0;
else if (verbose_output) {
fprintf(fp, "# TAG: %s", entry->name);
extern const char *external_acl_message; /* NULL */
extern int opt_send_signal; /* -1 */
extern int opt_no_daemon; /* 0 */
+ extern int opt_parse_cfg_only; /* 0 */
/// current Squid process number (e.g., 4).
/// Zero for SMP-unaware code and in no-SMP mode.
/** for error reporting from xmalloc and friends */
SQUIDCEXTERN void (*failure_notify) (const char *);
-static int opt_parse_cfg_only = 0;
static char *opt_syslog_facility = NULL;
static int icpPortNumOverride = 1; /* Want to detect "-u 0" */
static int configured_once = 0;