Skip to content

Commit

Permalink
Merging to release-5.3.6: [TT-13087] Adjust example gateway config, t…
Browse files Browse the repository at this point in the history
…o have match preficing explicit by default (#6564) (#6568)

### **User description**
[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

<!-- Please describe in detail how you tested your changes -->
<!-- Include details of your testing environment, and the tests -->
<!-- you ran to see how your change affects other areas of the code,
etc. -->
<!-- This information is helpful for reviewers and QA. -->

## Types of changes

<!-- What types of changes does your code introduce? Put an `x` in all
the boxes that apply: -->

- [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

<!-- Go over all the following points, and put an `x` in all the boxes
that apply -->
<!-- If there are no documentation updates required, mark the item as
checked. -->
<!-- Raise up any additional concerns not covered by the 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** 📝
<table><thead><tr><th></th><th align="left">Relevant
files</th></tr></thead><tbody><tr><td><strong>Configuration
changes</strong></td><td><table>
<tr>
  <td>
    <details>
<summary><strong>tyk.conf.example</strong><dd><code>Add explicit path
matching options to example gateway config</code></dd></summary>
<hr>

tyk.conf.example

<li>Added <code>http_server_options</code> section.<br> <li> Enabled
<code>enable_strict_routes</code>.<br> <li> Enabled
<code>enable_path_prefix_matching</code>.<br> <li> Enabled
<code>enable_path_suffix_matching</code>.


</details>


  </td>
<td><a

href="https://github.com/TykTechnologies/tyk/pull/6564/files#diff-a6736b4b3cda1ee503675d7b725f6138f4eb83d7145f3afecf6087d219f2b23a">+5/-0</a>&nbsp;
&nbsp; &nbsp; </td>

</tr>                    
</table></td></tr></tr></tbody></table>

___

> 💡 **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


___

### **PR Type**
enhancement, configuration changes


___

### **Description**
- Added new configuration options in `tyk.conf.example` to enable
explicit path matching by default.
- Introduced `http_server_options` with `enable_strict_routes`,
`enable_path_prefix_matching`, and `enable_path_suffix_matching` set to
true.
- These changes aim to provide more predictable path matching behavior
and improve configuration clarity for gateway users.


___



### **Changes walkthrough** 📝
<table><thead><tr><th></th><th align="left">Relevant
files</th></tr></thead><tbody><tr><td><strong>Configuration
changes</strong></td><td><table>
<tr>
  <td>
    <details>
<summary><strong>tyk.conf.example</strong><dd><code>Add explicit path
matching options to example gateway config</code></dd></summary>
<hr>

tyk.conf.example

<li>Added <code>http_server_options</code> section.<br> <li> Enabled
<code>enable_strict_routes</code>.<br> <li> Enabled
<code>enable_path_prefix_matching</code>.<br> <li> Enabled
<code>enable_path_suffix_matching</code>.<br>


</details>


  </td>
<td><a
href="https://github.com/TykTechnologies/tyk/pull/6568/files#diff-a6736b4b3cda1ee503675d7b725f6138f4eb83d7145f3afecf6087d219f2b23a">+5/-0</a>&nbsp;
&nbsp; &nbsp; </td>

</tr>                    
</table></td></tr></tr></tbody></table>

___

> 💡 **PR-Agent usage**: Comment `/help "your question"` on any pull
request to receive relevant information

Co-authored-by: Laurentiu <laurentiu.ghiur@gmail.com>
  • Loading branch information
buger and lghiur authored Sep 24, 2024
1 parent e062a32 commit 1db1935
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions tyk.conf.example
Original file line number Diff line number Diff line change
Expand Up @@ -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,
Expand Down

0 comments on commit 1db1935

Please sign in to comment.