| # |
| # 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. |
| |
| # Deny the cache write lock to any request carrying X-Fail-Cache-Write. With no |
| # write retries left, HttpCacheSM::open_write() reports the write failure |
| # without going to the cache at all, which makes the write lock loss |
| # deterministic instead of dependent upon a race between two transactions. |
| cond %{REMAP_PSEUDO_HOOK} |
| cond %{CLIENT-HEADER:X-Fail-Cache-Write} =1 |
| set-config proxy.config.http.cache.max_open_write_retries 0 [L] |