[trafficserver] branch 9.0.x updated: Finished upgrading release notes for ATS 9.0.0
This is an automated email from the ASF dual-hosted git repository. bcall pushed a commit to branch 9.0.x in repository https://gitbox.apache.org/repos/asf/trafficserver.git The following commit(s) were added to refs/heads/9.0.x by this push: new 77e60f9 Finished upgrading release notes for ATS 9.0.0 77e60f9 is described below commit 77e60f901325170ad2a10283154373bf9a098a64 Author: Bryan Call AuthorDate: Thu Jan 14 16:30:57 2021 -0800 Finished upgrading release notes for ATS 9.0.0 --- doc/release-notes/upgrading.en.rst | 58 -- 1 file changed, 43 insertions(+), 15 deletions(-) diff --git a/doc/release-notes/upgrading.en.rst b/doc/release-notes/upgrading.en.rst index 6c8306f..4ad9f4f 100644 --- a/doc/release-notes/upgrading.en.rst +++ b/doc/release-notes/upgrading.en.rst @@ -51,7 +51,7 @@ Configuration Settings: records.config These are the changes that are most likely to cause problems during an upgrade. Take special care making sure you have updated your configurations accordingly. -Connection management +Connection Management ~ The old settings for origin connection management included the following settings: @@ -69,7 +69,13 @@ These are all gone, and replaced with the following set of configurations: * :ts:cv:`proxy.config.http.per_server.connection.queue_delay` * :ts:cv:`proxy.config.http.per_server.connection.min` -Removed records.config settings + +Renamed records.config Settings +~~~ +* `proxy.config.http.proxy_protocol_whitelist` was renamed to :ts:cv:`proxy.config.http.proxy_protocol_allowlist` +* `proxy.config.net.max_connections_active_in` was renamed to :ts:cv:`proxy.config.net.max_requests_in` + +Removed records.config Settings ~~~ The following settings are simply gone, and have no purpose: @@ -95,7 +101,11 @@ longer a special case and are handled the same as a response with a non-zero len * `proxy.config.http.cache.allow_empty_doc` -Deprecated records.config settings + +* `proxy.config.ssl.client.verify.server` was deprecated for ATS 8.x and has been removed. Use +:ts:cv:`proxy.config.ssl.client.verify.server.properties` instead. + +Deprecated records.config Settings ~~ The following configurations still exist, and functions, but are considered deprecated and will be removed in a future release. We @@ -113,7 +123,7 @@ The following configurations still exist, and functions, but are considered depr * ``proxy.config.cache.volume_filename`` * ``proxy.config.dns.splitdns.filename`` -Settings with new defaults +Settings With New Defaults ~~ The following settings have changed from being `on` by default, to being off: @@ -124,9 +134,16 @@ The following settings have changed from being `on` by default, to being off: * :ts:cv:`proxy.config.ssl.client.TLSv1_1` The default cipher list has changed: - * :ts:cv:`proxy.config.ssl.server.cipher_suite` +* :ts:cv:`proxy.config.exec_thread.autoconfig.scale` went from a value of 1.5 to 1. This controls the number of worker threads and +the ratio is now worker thread 1 to 1 processing thread on the CPU or CPUs. + + +Settings with new behavior +~~ +* :ts:cv:`proxy.config.http.connect_attempts_max_retries_dead_server` specifies the exact number of times a dead server will be +retried for each new request. Before ATS tried 1 time more than this setting making it impossible to set the retry value to 0. Metrics --- @@ -183,14 +200,15 @@ Our APIs are guaranteed to be compatible within major versions, but we do make c Removed APIs -* ``TSHttpTxnRedirectRequest()`` +* :func:`TSHttpTxnRedirectRequest` -Renamed or modified APIs +Renamed or Modified APIs -* ``TSVConnSSLConnectionGet()`` is renamed to be :c:func:`TSVConnSslConnectionGet` - -* ``TSHttpTxnServerPush()`` now returns a :c:type:`TSReturnCode` +* :func:`TSVConnSSLConnectionGet` is renamed to be :func:`TSVConnSslConnectionGet` +* :func:`TSHttpTxnServerPush` now returns a :c:type:`TSReturnCode` +* :func:`TSContSchedule` and :func:`TSContScheduleAPI` by default will run on the same thread from which they are called. +* :func:`TSFetchUrl` and :func:`TSFetchCreate` now return a :c:type:`TSFetchSM` Cache @@ -243,13 +261,23 @@ Header Rewrite * `header-rewrite-expansion` was removed and replaced with `header-rewrite-concatenations` -Library Dependencies - -TCL is no longer required to build ATS. +Cache Key +~ +* `--ua-blacklist` was renamed to `--ua-blocklist` and `--ua-whitelist` was renamed to `--ua-allowlist` + +Logging +--- +* cqhv has been deprecated and cqpv should be used instead. -The minium OpenSSL version to build ATS is now 1.0.2. +Library Dependencies and Builds +--- +* TCL is no longer required to build ATS.
[trafficserver] branch 9.0.x updated: Updated ChangeLog
This is an automated email from the ASF dual-hosted git repository. zwoop pushed a commit to branch 9.0.x in repository https://gitbox.apache.org/repos/asf/trafficserver.git The following commit(s) were added to refs/heads/9.0.x by this push: new 93e22f4 Updated ChangeLog 93e22f4 is described below commit 93e22f40dac4be6689af3787b9850729d3e34bee Author: Leif Hedstrom AuthorDate: Wed Jan 20 11:09:41 2021 -0700 Updated ChangeLog --- CHANGELOG-9.0.1 | 2 ++ 1 file changed, 2 insertions(+) diff --git a/CHANGELOG-9.0.1 b/CHANGELOG-9.0.1 index 11d1240..3f6177f 100644 --- a/CHANGELOG-9.0.1 +++ b/CHANGELOG-9.0.1 @@ -3,6 +3,8 @@ Changes with Apache Traffic Server 9.0.1 #6860 - Make format specifier for time_t portable #6919 - slice: clean up 502 header/body generation. #7257 - slice: default to throttling, fixes to manufactured 416 responses. + #7287 - option to disable compression for range request's response + #7347 - Allow for regex_remap of pristine URL. #7377 - Addresses some of the lock contention with HostStatus. #7395 - Replace ::exit() with _exit() to avoid secondary cleanup cores #7414 - Remove the warning messages
[trafficserver] branch 9.0.x updated: Allow for regex_remap of pristine URL. (#7347)
This is an automated email from the ASF dual-hosted git repository. zwoop pushed a commit to branch 9.0.x in repository https://gitbox.apache.org/repos/asf/trafficserver.git The following commit(s) were added to refs/heads/9.0.x by this push: new 3a87ac1 Allow for regex_remap of pristine URL. (#7347) 3a87ac1 is described below commit 3a87ac14437c5f7526dc4e1dd5156f86081056b1 Author: Walt Karas AuthorDate: Mon Nov 30 09:54:44 2020 -0600 Allow for regex_remap of pristine URL. (#7347) Adds a new optional pparam "pristine" to the regex_remap core plugin. When present, this pparam causes regex_remap to match on the pristine URL, and to use the pristine URL for $ substitutions. (cherry picked from commit fee5ba1f96dc1fd0838eecaaff045970c76edcd6) --- doc/admin-guide/plugins/regex_remap.en.rst | 10 + plugins/regex_remap/regex_remap.cc | 49 +- .../pluginTest/regex_remap/regex_remap.test.py | 15 ++- 3 files changed, 62 insertions(+), 12 deletions(-) diff --git a/doc/admin-guide/plugins/regex_remap.en.rst b/doc/admin-guide/plugins/regex_remap.en.rst index 312a608..a7030f7 100644 --- a/doc/admin-guide/plugins/regex_remap.en.rst +++ b/doc/admin-guide/plugins/regex_remap.en.rst @@ -54,6 +54,16 @@ profile dump, you can do :: $ sudo touch remap.config $ sudo traffic_ctl config reload +By default, this plugin operates on the post-remap URL (including any +remappings done by preceding plugins in the remap rule). This behavior +can be modified with the optional parameter :: + +@pparam=[no-]pristine[default: off] + +With ``@pparam=pristine``, the plugin will operate on the pre-remap, or +pristine, URL. (But, if no regular expression in the config file is +matched, the resulting URL will still be the post-remap URL.) + By default, only the path and query string of the URL are provided for the regular expressions to match. The following optional parameters can be used to modify the plugin instance behavior :: diff --git a/plugins/regex_remap/regex_remap.cc b/plugins/regex_remap/regex_remap.cc index 2720140..76aaa0a 100644 --- a/plugins/regex_remap/regex_remap.cc +++ b/plugins/regex_remap/regex_remap.cc @@ -78,14 +78,14 @@ struct UrlComponents { UrlComponents() = default; void - populate(TSRemapRequestInfo *rri) + populate(TSMBuffer bufp, TSMLoc url) { -scheme = TSUrlSchemeGet(rri->requestBufp, rri->requestUrl, _len); -host = TSUrlHostGet(rri->requestBufp, rri->requestUrl, _len); -path = TSUrlPathGet(rri->requestBufp, rri->requestUrl, _len); -query = TSUrlHttpQueryGet(rri->requestBufp, rri->requestUrl, _len); -matrix = TSUrlHttpParamsGet(rri->requestBufp, rri->requestUrl, _len); -port = TSUrlPortGet(rri->requestBufp, rri->requestUrl); +scheme = TSUrlSchemeGet(bufp, url, _len); +host = TSUrlHostGet(bufp, url, _len); +path = TSUrlPathGet(bufp, url, _len); +query = TSUrlHttpQueryGet(bufp, url, _len); +matrix = TSUrlHttpParamsGet(bufp, url, _len); +port = TSUrlPortGet(bufp, url); url_len = scheme_len + host_len + path_len + query_len + matrix_len + 32; } @@ -626,6 +626,7 @@ struct RemapInstance { RemapRegex *first = nullptr; RemapRegex *last = nullptr; + bool pristine_url = false; bool profile = false; bool method= false; bool query_string = true; @@ -726,6 +727,10 @@ TSRemapNewInstance(int argc, char *argv[], void **ih, char * /* errbuf ATS_UNUSE ri->host = true; } else if (strncmp(argv[i], "no-host", 7) == 0) { ri->host = false; +} else if (strcmp(argv[i], "pristine") == 0) { + ri->pristine_url = true; +} else if (strcmp(argv[i], "no-pristine") == 0) { + ri->pristine_url = false; } else { TSError("[%s] invalid option '%s'", PLUGIN_NAME, argv[i]); } @@ -913,12 +918,36 @@ TSRemapDoRemap(void *ih, TSHttpTxn txnp, TSRemapRequestInfo *rri) TSDebug(PLUGIN_NAME, "Falling back to default URL on regex remap without rules"); return TSREMAP_NO_REMAP; } + RemapInstance *ri = static_cast(ih); + + struct SrcUrl { +TSMBuffer bufp; +TSMLoc loc; +bool bad; + }; + + const SrcUrl src_url([=]() -> SrcUrl { +SrcUrl u; + +if (ri->pristine_url) { + u.bufp = rri->requestBufp; + u.loc = rri->requestUrl; + u.bad = false; + +} else { + u.bad = TSHttpTxnPristineUrlGet(txnp, , ) != TS_SUCCESS; +} +return u; + }()); + + if (src_url.bad) { +return TSREMAP_NO_REMAP; + } // Populate the request url UrlComponents req_url; - req_url.populate(rri); + req_url.populate(src_url.bufp, src_url.loc); - RemapInstance *ri = static_cast(ih); int ovector[OVECCOUNT]; int lengths[OVECCOUNT / 2 + 1]; int dest_len; @@ -1061,7 +1090,7 @@ TSRemapDoRemap(void *ih, TSHttpTxn txnp, TSRemapRequestInfo *rri) const char *start = dest; // Setup the new
[trafficserver] branch 9.0.x updated: option to disable compression for range request's response (#7287)
This is an automated email from the ASF dual-hosted git repository. zwoop pushed a commit to branch 9.0.x in repository https://gitbox.apache.org/repos/asf/trafficserver.git The following commit(s) were added to refs/heads/9.0.x by this push: new 1b37031 option to disable compression for range request's response (#7287) 1b37031 is described below commit 1b37031319cc04ca0b1c8c5a9a09bfc74e32a8f5 Author: Vijay Mamidi AuthorDate: Wed Jan 20 08:45:49 2021 -0800 option to disable compression for range request's response (#7287) * option to disable compression for range request's response * option to disable compression for range request's response (cherry picked from commit 34ead16508ce01eec6a80e44d7dd52cce64b39ff) --- doc/admin-guide/plugins/compress.en.rst | 6 ++ plugins/compress/compress.cc| 14 +- plugins/compress/configuration.cc | 7 +++ plugins/compress/configuration.h| 12 4 files changed, 38 insertions(+), 1 deletion(-) diff --git a/doc/admin-guide/plugins/compress.en.rst b/doc/admin-guide/plugins/compress.en.rst index 41cf6a6..f58454e 100644 --- a/doc/admin-guide/plugins/compress.en.rst +++ b/doc/admin-guide/plugins/compress.en.rst @@ -103,6 +103,12 @@ versions of the content as :term:`alternates `. When set to ``false``, |TS| will cache only the compressed or decompressed variant returned by the origin. Enabled by default. +range-request +- + +When set to ``true``, causes |TS| to compress responses to Range Requests. +Disabled by default. Setting this to true while setting cache to false leads to delivering corrupted content. + compressible-content-type - diff --git a/plugins/compress/compress.cc b/plugins/compress/compress.cc index b7efe6d..066bee5 100644 --- a/plugins/compress/compress.cc +++ b/plugins/compress/compress.cc @@ -629,7 +629,7 @@ transformable(TSHttpTxn txnp, bool server, HostConfiguration *host_configuration /* Client request header */ TSMBuffer cbuf; TSMLoc chdr; - TSMLoc cfield; + TSMLoc cfield, rfield; const char *value; int len; @@ -661,6 +661,17 @@ transformable(TSHttpTxn txnp, bool server, HostConfiguration *host_configuration return 0; } + // check if Range Requests are cacheable + bool range_request = host_configuration->range_request(); + rfield = TSMimeHdrFieldFind(cbuf, chdr, TS_MIME_FIELD_RANGE, TS_MIME_LEN_RANGE); + if (rfield != TS_NULL_MLOC && !range_request) { +debug("Range header found in the request and range_request is configured as false, not compressible"); +TSHandleMLocRelease(cbuf, chdr, rfield); +TSHandleMLocRelease(cbuf, TS_NULL_MLOC, chdr); +TSHandleMLocRelease(bufp, TS_NULL_MLOC, hdr_loc); +return 0; + } + // the only compressible method is currently GET. int method_length; const char *method = TSHttpHdrMethodGet(cbuf, chdr, _length); @@ -668,6 +679,7 @@ transformable(TSHttpTxn txnp, bool server, HostConfiguration *host_configuration if (!(method_length == TS_HTTP_LEN_GET && memcmp(method, TS_HTTP_METHOD_GET, TS_HTTP_LEN_GET) == 0)) { debug("method is not GET, not compressible"); TSHandleMLocRelease(cbuf, TS_NULL_MLOC, chdr); +TSHandleMLocRelease(bufp, TS_NULL_MLOC, hdr_loc); return 0; } diff --git a/plugins/compress/configuration.cc b/plugins/compress/configuration.cc index b6211a4..f582b71 100644 --- a/plugins/compress/configuration.cc +++ b/plugins/compress/configuration.cc @@ -105,6 +105,7 @@ enum ParserState { kParseRemoveAcceptEncoding, kParseEnable, kParseCache, + kParseRangeRequest, kParseFlush, kParseAllow, kParseMinimumContentLength @@ -347,6 +348,8 @@ Configuration::Parse(const char *path) state = kParseEnable; } else if (token == "cache") { state = kParseCache; +} else if (token == "range-request") { + state = kParseRangeRequest; } else if (token == "flush") { state = kParseFlush; } else if (token == "supported-algorithms") { @@ -379,6 +382,10 @@ Configuration::Parse(const char *path) current_host_configuration->set_cache(token == "true"); state = kParseStart; break; + case kParseRangeRequest: +current_host_configuration->set_range_request(token == "true"); +state = kParseStart; +break; case kParseFlush: current_host_configuration->set_flush(token == "true"); state = kParseStart; diff --git a/plugins/compress/configuration.h b/plugins/compress/configuration.h index 67e81ff..ffc1840 100644 --- a/plugins/compress/configuration.h +++ b/plugins/compress/configuration.h @@ -48,6 +48,7 @@ public: : host_(host), enabled_(true), cache_(true), + range_request_(false), remove_accept_encoding_(false), flush_(false), compression_algorithms_(ALGORITHM_GZIP), @@ -66,6 +67,16 @@ public:
[trafficserver] branch master updated: PoolableSession (#6828)
This is an automated email from the ASF dual-hosted git repository. acanary pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/trafficserver.git The following commit(s) were added to refs/heads/master by this push: new d4f202c PoolableSession (#6828) d4f202c is described below commit d4f202c808dd1b76255ce8991960ff83c07a9c46 Author: a-a-ron AuthorDate: Wed Jan 20 11:27:21 2021 -0600 PoolableSession (#6828) Http1ServerSessions now inherit from an abstract PoolableSession which adds following for outbound pooling: + linkage for intrusive dlist + KA status + OutboundConnTrack::Group Its is expected that H2 and H3 session will also need to inherit from this, or something similar. --- proxy/Makefile.am | 1 + proxy/PoolableSession.h | 192 ++ proxy/ProxySession.cc | 18 +- proxy/ProxySession.h | 15 +- proxy/ProxyTransaction.cc | 34 +++- proxy/ProxyTransaction.h | 57 ++- proxy/http/Http1ClientSession.cc | 37 ++--- proxy/http/Http1ClientSession.h | 19 ++- proxy/http/Http1ServerSession.cc | 110 + proxy/http/Http1ServerSession.h | 159 ++ proxy/http/Http1Transaction.cc| 52 -- proxy/http/Http1Transaction.h | 11 -- proxy/http/HttpSM.cc | 146 proxy/http/HttpSM.h | 14 +- proxy/http/HttpSessionManager.cc | 75 + proxy/http/HttpSessionManager.h | 14 +- proxy/http/HttpTransactHeaders.cc | 1 + proxy/http2/Http2ClientSession.cc | 10 +- proxy/http2/Http2ClientSession.h | 6 +- proxy/http2/Http2ConnectionState.cc | 2 +- proxy/http2/Http2Stream.h | 2 +- proxy/http3/Http3Session.cc | 8 +- proxy/http3/Http3Session.h| 8 +- src/traffic_server/InkAPI.cc | 54 +++--- tests/gold_tests/continuations/session_id.test.py | 15 +- 25 files changed, 563 insertions(+), 497 deletions(-) diff --git a/proxy/Makefile.am b/proxy/Makefile.am index 33a2ad1..4eec154 100644 --- a/proxy/Makefile.am +++ b/proxy/Makefile.am @@ -70,6 +70,7 @@ libproxy_a_SOURCES = \ ProtocolProbeSessionAccept.h \ ProxySession.cc \ ProxySession.h \ + PoolableSession.h \ ProxyTransaction.cc \ ProxyTransaction.h \ ReverseProxy.cc \ diff --git a/proxy/PoolableSession.h b/proxy/PoolableSession.h new file mode 100644 index 000..76946ef --- /dev/null +++ b/proxy/PoolableSession.h @@ -0,0 +1,192 @@ +/** @file + + PoolableSession - class that extends ProxySession so that they can be cataloged for reuse. + + @section license License + + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you under the Apache License, Version 2.0 (the + "License"); you may not use this file except in compliance + with the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + +#pragma once + +#include "ProxySession.h" + +class PoolableSession : public ProxySession +{ + using self_type = PoolableSession; + using super_type = ProxySession; + +public: + enum PooledState { +INIT, +SSN_IN_USE, // actively in use +KA_RESERVED, // stuck to client +KA_POOLED, // free for reuse + }; + + /// Hash map descriptor class for IP map. + struct IPLinkage { +self_type *_next = nullptr; +self_type *_prev = nullptr; + +static self_type *_ptr(self_type *); +static self_type *_ptr(self_type *); +static uint32_t hash_of(sockaddr const *key); +static sockaddr const *key_of(self_type const *ssn); +static bool equal(sockaddr const *lhs, sockaddr const *rhs); +// Add a couple overloads for internal convenience. +static bool equal(sockaddr const *lhs, PoolableSession const *rhs); +static bool equal(PoolableSession const *lhs, sockaddr const *rhs); + } _ip_link; + + /// Hash map descriptor class for FQDN map. + struct FQDNLinkage { +self_type *_next = nullptr; +self_type *_prev = nullptr; + +static
[trafficserver] branch master updated: option to disable compression for range request's response (#7287)
This is an automated email from the ASF dual-hosted git repository. vmamidi pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/trafficserver.git The following commit(s) were added to refs/heads/master by this push: new 34ead16 option to disable compression for range request's response (#7287) 34ead16 is described below commit 34ead16508ce01eec6a80e44d7dd52cce64b39ff Author: Vijay Mamidi AuthorDate: Wed Jan 20 08:45:49 2021 -0800 option to disable compression for range request's response (#7287) * option to disable compression for range request's response * option to disable compression for range request's response --- doc/admin-guide/plugins/compress.en.rst | 6 ++ plugins/compress/compress.cc| 14 +- plugins/compress/configuration.cc | 7 +++ plugins/compress/configuration.h| 12 4 files changed, 38 insertions(+), 1 deletion(-) diff --git a/doc/admin-guide/plugins/compress.en.rst b/doc/admin-guide/plugins/compress.en.rst index 41cf6a6..f58454e 100644 --- a/doc/admin-guide/plugins/compress.en.rst +++ b/doc/admin-guide/plugins/compress.en.rst @@ -103,6 +103,12 @@ versions of the content as :term:`alternates `. When set to ``false``, |TS| will cache only the compressed or decompressed variant returned by the origin. Enabled by default. +range-request +- + +When set to ``true``, causes |TS| to compress responses to Range Requests. +Disabled by default. Setting this to true while setting cache to false leads to delivering corrupted content. + compressible-content-type - diff --git a/plugins/compress/compress.cc b/plugins/compress/compress.cc index b7efe6d..066bee5 100644 --- a/plugins/compress/compress.cc +++ b/plugins/compress/compress.cc @@ -629,7 +629,7 @@ transformable(TSHttpTxn txnp, bool server, HostConfiguration *host_configuration /* Client request header */ TSMBuffer cbuf; TSMLoc chdr; - TSMLoc cfield; + TSMLoc cfield, rfield; const char *value; int len; @@ -661,6 +661,17 @@ transformable(TSHttpTxn txnp, bool server, HostConfiguration *host_configuration return 0; } + // check if Range Requests are cacheable + bool range_request = host_configuration->range_request(); + rfield = TSMimeHdrFieldFind(cbuf, chdr, TS_MIME_FIELD_RANGE, TS_MIME_LEN_RANGE); + if (rfield != TS_NULL_MLOC && !range_request) { +debug("Range header found in the request and range_request is configured as false, not compressible"); +TSHandleMLocRelease(cbuf, chdr, rfield); +TSHandleMLocRelease(cbuf, TS_NULL_MLOC, chdr); +TSHandleMLocRelease(bufp, TS_NULL_MLOC, hdr_loc); +return 0; + } + // the only compressible method is currently GET. int method_length; const char *method = TSHttpHdrMethodGet(cbuf, chdr, _length); @@ -668,6 +679,7 @@ transformable(TSHttpTxn txnp, bool server, HostConfiguration *host_configuration if (!(method_length == TS_HTTP_LEN_GET && memcmp(method, TS_HTTP_METHOD_GET, TS_HTTP_LEN_GET) == 0)) { debug("method is not GET, not compressible"); TSHandleMLocRelease(cbuf, TS_NULL_MLOC, chdr); +TSHandleMLocRelease(bufp, TS_NULL_MLOC, hdr_loc); return 0; } diff --git a/plugins/compress/configuration.cc b/plugins/compress/configuration.cc index b6211a4..f582b71 100644 --- a/plugins/compress/configuration.cc +++ b/plugins/compress/configuration.cc @@ -105,6 +105,7 @@ enum ParserState { kParseRemoveAcceptEncoding, kParseEnable, kParseCache, + kParseRangeRequest, kParseFlush, kParseAllow, kParseMinimumContentLength @@ -347,6 +348,8 @@ Configuration::Parse(const char *path) state = kParseEnable; } else if (token == "cache") { state = kParseCache; +} else if (token == "range-request") { + state = kParseRangeRequest; } else if (token == "flush") { state = kParseFlush; } else if (token == "supported-algorithms") { @@ -379,6 +382,10 @@ Configuration::Parse(const char *path) current_host_configuration->set_cache(token == "true"); state = kParseStart; break; + case kParseRangeRequest: +current_host_configuration->set_range_request(token == "true"); +state = kParseStart; +break; case kParseFlush: current_host_configuration->set_flush(token == "true"); state = kParseStart; diff --git a/plugins/compress/configuration.h b/plugins/compress/configuration.h index 67e81ff..ffc1840 100644 --- a/plugins/compress/configuration.h +++ b/plugins/compress/configuration.h @@ -48,6 +48,7 @@ public: : host_(host), enabled_(true), cache_(true), + range_request_(false), remove_accept_encoding_(false), flush_(false), compression_algorithms_(ALGORITHM_GZIP), @@ -66,6 +67,16 @@ public: enabled_ = x; } bool + range_request() + { +return
[trafficserver] branch 9.0.x updated: Updated ChangeLog
This is an automated email from the ASF dual-hosted git repository. zwoop pushed a commit to branch 9.0.x in repository https://gitbox.apache.org/repos/asf/trafficserver.git The following commit(s) were added to refs/heads/9.0.x by this push: new 0ae5a5c Updated ChangeLog 0ae5a5c is described below commit 0ae5a5c6244cd4b57082904f55f74f7f06d6f49a Author: Leif Hedstrom AuthorDate: Wed Jan 20 09:39:36 2021 -0700 Updated ChangeLog --- CHANGELOG-9.0.1 | 6 ++ 1 file changed, 6 insertions(+) diff --git a/CHANGELOG-9.0.1 b/CHANGELOG-9.0.1 index adfc818..11d1240 100644 --- a/CHANGELOG-9.0.1 +++ b/CHANGELOG-9.0.1 @@ -1,5 +1,11 @@ Changes with Apache Traffic Server 9.0.1 + #6691 - Slice plugin: self heal when asset etag/last-modified block mismatches + #6860 - Make format specifier for time_t portable + #6919 - slice: clean up 502 header/body generation. + #7257 - slice: default to throttling, fixes to manufactured 416 responses. #7377 - Addresses some of the lock contention with HostStatus. #7395 - Replace ::exit() with _exit() to avoid secondary cleanup cores #7414 - Remove the warning messages #7420 - Update documentation for TSSslSessionInsert + #7432 - Fix stall on outbound TLS handshake + #7435 - Slice: 9.0.x back port of self healing and throttle by default
[trafficserver] branch 9.0.x updated: Fix stall on outbound TLS handshake (#7432)
This is an automated email from the ASF dual-hosted git repository. zwoop pushed a commit to branch 9.0.x in repository https://gitbox.apache.org/repos/asf/trafficserver.git The following commit(s) were added to refs/heads/9.0.x by this push: new 61348c4 Fix stall on outbound TLS handshake (#7432) 61348c4 is described below commit 61348c42ffc25463f49e523b0eb6d830ed5a3ec6 Author: Masaori Koshiba AuthorDate: Wed Jan 20 09:13:03 2021 +0900 Fix stall on outbound TLS handshake (#7432) (cherry picked from commit 9a121730229ddf1b3a8dba962f318a5bfd3e8b0f) --- proxy/http/HttpSM.cc | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/proxy/http/HttpSM.cc b/proxy/http/HttpSM.cc index e263497..a247c47 100644 --- a/proxy/http/HttpSM.cc +++ b/proxy/http/HttpSM.cc @@ -6090,9 +6090,7 @@ HttpSM::attach_server_session(Http1ServerSession *s) // first tunnel was sometimes behind handled by the consumer of the // first tunnel instead of the producer of the second tunnel. // The real read is setup in setup_server_read_response_header() - // - // Keep the read disabled until setup_server_read_response_header - server_entry->read_vio = server_session->do_io_read(this, 0, nullptr); + server_entry->read_vio = server_session->do_io_read(this, 0, server_session->read_buffer); // Transfer control of the write side as well server_entry->write_vio = server_session->do_io_write(this, 0, nullptr);
[trafficserver] branch 9.0.x updated: Slice: 9.0.x back port of self healing and throttle by default (#7435)
This is an automated email from the ASF dual-hosted git repository. zwoop pushed a commit to branch 9.0.x in repository https://gitbox.apache.org/repos/asf/trafficserver.git The following commit(s) were added to refs/heads/9.0.x by this push: new 794f2c3 Slice: 9.0.x back port of self healing and throttle by default (#7435) 794f2c3 is described below commit 794f2c3effbb442cce55c3feb5d8f7e6951855d7 Author: Brian Olsen AuthorDate: Wed Jan 20 09:16:24 2021 -0700 Slice: 9.0.x back port of self healing and throttle by default (#7435) * Slice plugin: recover out of sync slices, better handling of non 206s (#6691) The very first slice is used as the reference slice to make recovery easiest. Recover asset where slices differ in content-length, etag, last-modified. autests included to cover basic functionality. Includes additions to include/ts/experimental.h: tsapi time_t TSMimeParseDate(char const *const value_str, int const value_len); tsapi TSReturnCode TSMimeFormatDate(time_t const value_time, char *const value_str, int *const value_len); These are derived from TSMimeHdrFieldValueDateSet/TSMimeHdrFieldValueDateGet. (cherry picked from commit 6dd31ebedaa30c2a8d971bb79dd0331d107a09c7) * Make format specifier for time_t portable (#6860) (cherry picked from commit dde389766fb54a775a91bdd6d814629eae83cacd) * autest whitespace * slice: clean up of created 502 response header (#6919) Change header debug to use TSHttpHdrPrint. Co-authored-by: Brian Olsen (cherry picked from commit 9d23ab6932102cb7741d256791c7c29fe436b138) * default to throttling and subsequently simplify the transfer code (#7257) slice: default to throttling, 416 changes and bug fix for downstream closing. (cherry picked from commit 4462484040e2f6ff6001002fb97bbbec367a95d9) Co-authored-by: Masakazu Kitajo --- .../plugins/cache_range_requests.en.rst| 8 +- doc/admin-guide/plugins/slice.en.rst | 103 -- include/ts/experimental.h | 10 + .../cache_range_requests/cache_range_requests.cc | 6 +- plugins/experimental/slice/Config.cc | 10 +- plugins/experimental/slice/Config.h| 5 +- plugins/experimental/slice/ContentRange.h | 8 +- plugins/experimental/slice/Data.cc | 65 plugins/experimental/slice/Data.h | 85 +++-- plugins/experimental/slice/HttpHeader.cc | 118 --- plugins/experimental/slice/HttpHeader.h| 8 + plugins/experimental/slice/Range.h | 4 +- plugins/experimental/slice/Stage.h | 9 - plugins/experimental/slice/client.cc | 66 ++-- plugins/experimental/slice/response.cc | 12 +- plugins/experimental/slice/response.h | 2 +- plugins/experimental/slice/server.cc | 370 +++ plugins/experimental/slice/slice.cc| 58 +-- plugins/experimental/slice/slice.h | 28 +- plugins/experimental/slice/transfer.cc | 106 ++ plugins/experimental/slice/util.cc | 41 ++- src/traffic_server/InkAPI.cc | 25 ++ tests/gold_tests/pluginTest/slice/curlsort.sh | 33 -- tests/gold_tests/pluginTest/slice/gold/aa.gold | 1 + tests/gold_tests/pluginTest/slice/gold/aaa.gold| 1 + tests/gold_tests/pluginTest/slice/gold/bb.gold | 1 + tests/gold_tests/pluginTest/slice/gold/bbb.gold| 1 + .../pluginTest/slice/gold/slice_200.stderr.gold| 2 +- .../pluginTest/slice/gold/slice_200.stdout.gold| 8 - .../pluginTest/slice/gold/slice_206.stderr.gold| 2 +- .../pluginTest/slice/gold/slice_206.stdout.gold| 9 - .../pluginTest/slice/gold/slice_first.stderr.gold | 2 +- .../pluginTest/slice/gold/slice_first.stdout.gold | 9 - .../pluginTest/slice/gold/slice_last.stderr.gold | 2 +- .../pluginTest/slice/gold/slice_last.stdout.gold | 9 - .../pluginTest/slice/gold/slice_mid.stderr.gold| 2 +- .../pluginTest/slice/gold/slice_mid.stdout.gold| 9 - .../slice/gold_error/contents.stderr.gold | 1 + .../pluginTest/slice/gold_error/crr.stderr.gold| 1 - .../pluginTest/slice/gold_error/crr.stdout.gold| 9 - .../pluginTest/slice/gold_error/etag.stderr.gold | 1 - .../pluginTest/slice/gold_error/etag.stdout.gold | 9 - .../pluginTest/slice/gold_error/lm.stderr.gold | 1 - .../pluginTest/slice/gold_error/lm.stdout.gold | 9 - .../pluginTest/slice/gold_error/non206.stderr.gold | 1 - .../pluginTest/slice/gold_error/non206.stdout.gold | 10 - tests/gold_tests/pluginTest/slice/slice.test.py| 141 .../pluginTest/slice/slice_error.test.py | 160 ++--- .../pluginTest/slice/slice_regex.test.py | 6 +-