From 099665eb5e7e012f411e29c70c6e97718272f307 Mon Sep 17 00:00:00 2001 From: Leonid Bugaev Date: Tue, 24 Sep 2024 15:53:57 +0300 Subject: [PATCH] Merging to release-5-lts: [TT-13087] Adjust example gateway config, to have match preficing explicit by default (#6564) (#6572) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [TT-13087] Adjust example gateway config, to have match preficing explicit by default (#6564) ### **User description** ## Description TT-13087 Adjust example gateway config, to have match preficing explicit by default ## Motivation and Context Would be advised that Gateway users, would have by default explicit path matching settings enabled by default, as the wildcard behaviour of the path matching, can be challenging at times to configure properly. ## How This Has Been Tested ## Types of changes - [x] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [x] Breaking change (fix or feature that would cause existing functionality to change) - [x] Refactoring or add test (improvements in base code or adds test coverage to functionality) ## Checklist - [x] I ensured that the documentation is up to date - [x] I explained why this PR updates go.mod in detail with reasoning why it's required - [x] I would like a code coverage CI quality gate exception and have explained why ___ ### **PR Type** enhancement, configuration changes ___ ### **Description** - Added new configuration options in `tyk.conf.example` to enable strict routing and explicit path matching by default. - The changes aim to improve the default behavior for gateway users by making path matching settings explicit. ___ ### **Changes walkthrough** 📝
Relevant files
Configuration changes
tyk.conf.example
Add explicit path matching options to example gateway config

tyk.conf.example
  • Added http_server_options section.
  • Enabled enable_strict_routes.
  • Enabled enable_path_prefix_matching.
  • Enabled enable_path_suffix_matching.
  • +5/-0     
    ___ > 💡 **PR-Agent usage**: Comment `/help "your question"` on any pull request to receive relevant information [TT-13087]: https://tyktech.atlassian.net/browse/TT-13087?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ Co-authored-by: Laurentiu --- tyk.conf.example | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tyk.conf.example b/tyk.conf.example index 8f45ea12eec..67dfeb79cb9 100644 --- a/tyk.conf.example +++ b/tyk.conf.example @@ -30,6 +30,11 @@ "policies": { "policy_source": "file" }, + "http_server_options": { + "enable_strict_routes": true, + "enable_path_prefix_matching": true, + "enable_path_suffix_matching": true + }, "hash_keys": true, "hash_key_function": "murmur64", "suppress_redis_signal_reload": false,